help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: error: memory exhausted or requested size too large for range of Oct


From: Martin Helm
Subject: Re: error: memory exhausted or requested size too large for range of Octave's index type --
Date: Tue, 15 Mar 2011 19:43:16 +0100
User-agent: KMail/1.13.6 (Linux/2.6.34.7-0.7-desktop; KDE/4.5.5; x86_64; ; )

Am Dienstag, 15. März 2011, 18:05:44 schrieb nuncio m:
> Hi list,
>         Here is the code I am trying to do a PCA analysis
> 
>         filename='test_eof.txt';
>         oufile='pc.txt';
>         data=load(filename);
>         data1=reshape(data,25200,132);
>         data2=data1';
>         f=detrend(data2,0);
>         R=f'*f;
>         [C,L]=eig(R);
>         pc1=f*C(:,1);
>         pc2=f*C(:,2);
>         fid=fopen(oufile,"wt");
>         fprintf(fid,'%10.3f \n',pc1);
>         fclose(fid);
>        The code never completes the computation, it shows an error "error:
> memory exhausted or requested size too large for range of Octave's index
> type -- trying to return to prompt"
>        Can anyone suggest where it goes wrong.
>        Thanks
>        Nuncio

Not a problem at all with 32 bit octave if you use version 3.4 since only the 
index is limited to 2e9 not the bytesize of the array. An array can have up to 
16 GB (if you have enough RAM + Swap).
With version 3.2 of course this does not work for the 32 bit version.

Which version of octave is that what you are using and which operating system? 
It is probably easy to update.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]