help-octave
[Top][All Lists]
Advanced

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

RE: save and load bug.


From: Sergei Steshenko
Subject: RE: save and load bug.
Date: Sun, 28 Dec 2008 02:47:42 -0800 (PST)



--- On Sat, 12/27/08, GARY FORBIS <address@hidden> wrote:

> From: GARY FORBIS <address@hidden>
> Subject: RE: save and load bug.
> To: address@hidden
> Cc: "help-octave" <address@hidden>
> Date: Saturday, December 27, 2008, 5:50 PM
> a> I tried a simple version> > a = -rand (1,
> 500);> save -text test.txt a> clear all> load
> test.txt> whos a> > Running both 3.0.3 and the
> developers sources load() appears to work.> > I you
> are unable to produce a simple example which demonstrates
> the > problem, can you attach a file that doesn't
> load so that it may be > examined?> > Ben
> I thought I gave it.  Here it is again:
>  
> a=-0.03597396637549816
> b=[]for x=1:500b=[b,a]save stest bload stestend
> Here it is running:
>  
> octave-3.0.3.exe:13> a=-0.03597396637549816a =
> -0.035974octave-3.0.3.exe:14>octave-3.0.3.exe:14>
> b=[]b = [](0x0)octave-3.0.3.exe:15> for x=1:500>
> b=[b,a]> save stest b> load stest> enderror: load:
> failed to load matrix constanterror: load: trouble reading
> ascii file `stest'error: load: reading file stesterror:
> evaluating for command near line 15, column
> 1octave-3.0.3.exe:15>

I have slightly modified you code - added ';' to make it non-interactive:

a=-0.03597396637549816
b=[]
for x=1:500
b=[b,a];
save stest b;
load stest;
end

, and it runs just fine on my Linux box:

"
octave:1> a=-0.03597396637549816
a = -0.035974
octave:2> b=[]
b = [](0x0)
octave:3> for x=1:500
> b=[b,a];
> save stest b;
> load stest;
> end
octave:4> version
ans = 3.0.3
octave:5>   
"

Regards,
  Sergei.


      


reply via email to

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