Re: help plot log[f[t]] vs a parameter using an ODE
- To: mathgroup at smc.vnet.net
- Subject: [mg81184] Re: help plot log[f[t]] vs a parameter using an ODE
- From: j.f.b.payne at tesco.net
- Date: Fri, 14 Sep 2007 03:50:30 -0400 (EDT)
- References: <fc85qt$liu$1@smc.vnet.net><fcb42d$fmp$1@smc.vnet.net>
Maybe what is wanted is a 3D plot of the solution to the differential equation, as a function of the dependent variable `t' and the parameter `a' In which case, a perhaps inelegant approach is tbl=Table[{a,y[t] /. First@First@NDSolve[{y'[t] == a (y[t]/((y[t])^2 + b )) - c y[t] + d /. {d -> 0.1 , c -> 1 , b -> 10 },y[0]==0},y,{t, 0,200}]},{a,5,40,5}] fn[tt_,a_]:=Interpolation[tbl /. t->tt][a] Plot3D[fn[t,a],{t,0,200},{a,5,40}] or Plot3D[Log[fn[t,a] ],{t,0,200},{a,10,40}] if the Log is wanted, but there seem to be negative values so this makes error messages (I don't have time to look into this) Regards John Payne