Ode45 help

Muthiah Annamalai muthuspost at gmail.com
Sat Feb 14 15:45:21 CST 2009


Drop the .m in the function handle @gene.m

Brandon Pye wrote:
> Hey guys,
>
> I'm in a class where I need to use ode45. I keep getting an error  
> syntax when I copy the code from matlab to octave. The function that  
> contains the differential equations gets its values from a structure  
> defined in the master .m file. In matlab, when I call ode45 the code  
> looks like:
>
> [t,y] = ode45(@gene.m, [0 10], y0, [], info);
>
> Where the closed brackets are skipping the tolerance and 'info' is the  
> structure I need so that the function 'gene.m' can get the values  
> necessary for the differential equations. When I run that code in  
> octave, it can't find the values in the structure. Can anyone tell me  
> where I can put the structure in the code when I call ode45 in octave?  
> Also, I have matlab for windows. Should I just try to run it with wine?
>
> Thanks,
>
> Brandon
> _______________________________________________
> Help-octave mailing list
> Help-octave at octave.org
> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave
>
>   



More information about the Help-octave mailing list