From: 涛 洪 on 15 Jan 2010 03:17 Hi,everyone, I am new in Mathematica.When I try to sketch a phase portrait for the nonlinear system, I don't know how to plan the input values for the ODEs to get the right FIGURE. My example is from a book as follows: ode1[x0_,y0_]:=NDSolve[{x=E2=80=99[t]==y[t],y=E2=80=99[t]==x[t](1-(x[t])^2)+y[t],x[0]==x0,y[0]==y0},{x[t],y[t]},{t,-10,10}]; sol[1]=ode1[0.1,0.16];sol[2]=ode1[0.1,-0.06]; sol[3]=ode1[-0.1,-0.16];sol[4]=ode1[-0.1,0.06]; sol[5]=ode1[1.3,0];sol[6]=ode1[-1.3,0]; p=ParametricPlot[Evaluate[Table[{x[t],y[t]}/.sol[i],{i,6}]],{t,-10,10},PlotRange->{{-3,3},{-3,3}}]; Show[p,PlotRange->{{-3,3},{-3,3}},AxesLabel->{"x","y"}] Would you like to tell me why we choose the input values for the ODEs such as ode1[0.1,0.16]; ode1[0.1,-0.06];...? You see, when I tried to change the values ,I can't see the figure any more. Best Regards, hongtao
|
Pages: 1 Prev: Mac OS X hard disk space used up by virtual memory Next: help with finding solutions |