Question: How to use data in a matrix

 of solution to plot a function?

with(DEtools):

sys := {diff(x(t), t) = y(t), diff(y(t), t) = -(1+(1/100)*t)^2*x(t), x(0) = -1, y(0) = 2};

sys := {diff(x(t), t) = y(t), diff(y(t), t) = -(1+(1/100)*t)^2*x(t), x(0) = -1, y(0) = 2}

dsn := dsolve(sys, numeric);

dsn:=proc(x_rkf45) ... end proc

 

My question is how to use dsn to plot functions E(t) and I(t) with respect to t in a given interval [t1,t2].

E(t)=0.5*(diff(x(t),t)^2+w^2*x(t)^2), w=1+t/100.  I(t)=E(t)/w.

 

Many thanks to everyone helping me : )

Please Wait...