Question: DEplot for piecewise function

Hi! I was wondering about drawing phase plane for differential system with some conditions. For example how can we draw this for:

 

restart;
with(plots);
with(DEtools);

ode := piecewise(1 < abs(x(t)), diff(x(t), t $ 2) - 2 = 0, abs(x(t)) < 1, diff(x(t), t $ 2) = 0);
????????????

I wanted something similar to that:

DEplot({diff(x(t), t) = y(t), diff(y(t), t) = 8*x(t)*y(t)}, [x(t), y(t)], t = -2 .. 2, x = -1 .. 1, y = -4 .. 4);

or this:

ode1 := diff(x(t), t $ 2) + 2*diff(x(t), t) = 0

DEplot(ode1, x(t), t = -2 .. 10, [[x(1) = 0.2, D(x)(1) = -1.4]]);

Edit:

I rewrite that to make integral curves and this phase plot should look similar to this:


 

Please Wait...