From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: (yet unsolved) how to Solve coupled ODEs
Date: Wed, 13 Feb 2013 08:01:09 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 19
Message-ID: <kffh85$2p0$>
References: <keujnd$h64$> <kfb8m3$mom$> <kfdpbl$ke4$> <kfdtfb$719$> <kfe0cb$i20$> <kfe1ft$mlu$> <kfe78p$f5b$> <kfeavo$2f$>
Reply-To: <HIDDEN>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: 1360742469 2848 (13 Feb 2013 08:01:09 GMT)
NNTP-Posting-Date: Wed, 13 Feb 2013 08:01:09 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 3799640
Xref: comp.soft-sys.matlab:788919

"Henry" wrote in message <kfeavo$2f$>...
> I modified the code to:
> tspan = linspace(1, 2,100);
> y = 0.0001*ones(1,200);
> [T,sols] = ode45(@yprime, tspan,y);
> and
> dyds = [dyds1' ; dyds2']; 
> and it now runs, thanks. 
> But I have this question: My odes are time-independent, function of "s" which is a distance, but since the ode45 will not work without a tspan, I came up with an arbitrary tspan. It looks as if ode45 interprets that "s" is a time? I'm confused as to how interpret the result of the routine which has dimensions of 100x200. I was expecting 1 x 200, i.e. independent of time. 
> thanks

Just interpret your results for y(1) and y(2) as functions of distance, not of time.
So "tspan" in your case is a distance vector, not a time vector.

Best wishes