xujy 发表于 2006-5-23 17:03

求助,快疯了 !

用matlab编写的小程序求频率,大意如下:<BR>syms w<BR>tp=eye(4)<BR>for i=1:n<BR>t=[ w]%含w的矩阵<BR>tp=t*tp<BR>end<BR>我运行时当n大点时,提示:out of memory<BR>哪位教教我怎么弄呀,急呀,就这小玩意弄得快疯了!<BR>

edwardflr 发表于 2006-5-23 20:50

不知道你的n是多大,反正我的机器上n是1000还没问题,我查到了out of memory错误的说明:<BR>MEMORY Help for memory limitations.<BR>    If the OUT OF MEMORY error message is encountered, there is<BR>    no more room in memory for new variables. You must free up<BR>    some space before you may proceed. One way to free up space<BR>    is to delete some variables (see CLEAR). Another is to<BR>    issue the command PACK (See PACK). PACK compresses the data<BR>    in memory, opening up larger contiguous blocks.<BR> <BR>    Here are some additional system specific tips:<BR>    Windows:    Increase virtual memory by using System in the Control Panel.<BR>    Unix:       Ask your system manager to increase your Swap Space.<BR>大概是说你可以用clear来清理内存,或者用pack来压缩内存中的数据,你打help clear(pack)试试。<BR>或者提高虚拟内存。
页: [1]
查看完整版本: 求助,快疯了 !