MathGroup Archive 1997

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Help getting values from NDSolve

  • To: mathgroup at smc.vnet.net
  • Subject: [mg6820] Re: [mg6783] Help getting values from NDSolve
  • From: penny at suu.edu (Des Penny)
  • Date: Mon, 21 Apr 1997 02:02:55 -0400 (EDT)
  • Sender: owner-wri-mathgroup at wolfram.com

>I'm relatively new to Mathematica and need some help with the NDSolve
>function.  I have used it to solve an ordinary differential equation and got
>the expected interpolating function which I then plotted.  The plot is great
>but I would like a list of coordinates so that I can analyze them further
>and possibly import into a "prettier" graphing package.



Hi Chris:

Try:

sol=NDSolve[ etc.]
FullForm[sol]

This will give you the form of the solution.  Perhaps you can then abstract
the actual data from the lists that you see.  I plotted one of the inner
lists and saw the y values of the solution.

Of course the easiest way might be to reconstruct other data from the
interpolating function with a table command and then plot this or export
"data" to another package:

ysol[x_]=y[x] /. sol[[1]];
data=Table[{x,ysol[x]}, {x,0,2,0.1}];
ListPlot[data];


Cheers,

Des Penny


-------------------------------
Des Penny
Physical Science Dept.
Southern Utah University
Cedar City, UT 84720

VOICE: (Office): (801) 586-7708
       (Home)  : (801) 586-2286
FAX:    (801) 865-8051
e-mail: penny at suu.edu
-------------------------------




  • Prev by Date: Re: Including Functions and Variables from another Notebook
  • Next by Date: Re: Help getting values from NDSolve
  • Previous by thread: Re: Help getting values from NDSolve
  • Next by thread: Re: Help getting values from NDSolve