Question: How get plot of a function from the numeric solution of the differential equation system?

restart;
with(plots);
g := 32.2;
k := 0.1;
theta := Pi/5;
v := 50;


ode0 := diff(x(t), t $ 2) = 0, diff(y(t), t $ 2) = -g    

                                  
ode1 := diff(x(t), t $ 2) = -k*diff(x(t), t) - x(t) - 1/6*x(t)^3 + 1/120*x(t)^5, diff(y(t), t $ 2) = -g - k*diff(y(t), t) - y(t) - 1/6*y(t)^3 + 1/120*y(t)^5

ics := x(0) = 0, y(0) = 0, D(x)(0) = v*cos(theta), D(y)(0) = v*sin(theta)


dsolve([ode1, ics], numeric)

dsolve([ode0, ics])


display(plot([rhs(dsolve([ode0, ics])[1]), rhs(dsolve([ode0, ics])[2]), t = 0 .. 2], color = red), plot([rhs(dsolve([ode1, ics, numeric])[1]), rhs(dsolve([ode1, ics, numeric])[2]), t = 0 .. 2]), view = [0 .. 75, 0 .. 15])

 

Hi! Do you know maybe how to get this plot of ode1? I guess that computations are ok but I cannot get this plot.

Please Wait...