From owner-help-octave at bevo dot che dot wisc dot edu Fri Dec 1 11:43:56 1995 Subject: Re: can i do ODE2 problems with lsode ? From: przemek at rrdjazz dot nist dot gov (Przemek Klosowski) To: help-octave at bevo dot che dot wisc dot edu, spaz@u.washington.edu Date: Fri, 01 Dec 1995 12:39:58 -0500 Here is the function that i want to try and solve first, since i think it is a "simple" example of what comes in the real stuff. d^2 x dx ----- + lambda*( x^2 - 1 )* -- + x = 0 dt^2 dt my problem is that this is a 2nd order eq and lsode looks like it only wants 1rst order eq's. Now, i *thought* that any nOrder ode can be represented as an Nsystem of 1rst order diffeq's. It is fairly trivial, and I am sure it must be covered somewhere in these texts: you simply introduce a pseudo-independent variable y = dx/dt and reformulate your equations as d ( x ) ( y ) -- ( ) = ( ) dt ( y ) ( lambda * (x^2-1)*y + x ) (a 2-D non-linear first-order equation).