23 September 2011

Make "phase plane" with maple

Assalamualaikum..
Hi blogger mania..how are you? I want to share how to make phase plane with maple. I make it because I was studying about maple alone, maybe it can be used in my department, IPB for mathematical modelling in second grade. Here the script :

restart:
> with(DEtools):
> with(plots):
>
> e1 := diff(x(t), t) = x(t)+y(t):
> e2 := diff(y(t), t) = 4*x(t)-2*y(t):
>
> sis := {e1, e2};
>
> nullcline := eval(sis, {x(t) = x, y(t) = y, diff(x(t), t) = 0, diff(y(t), t) = 0}):
> map(isolate, nullcline, y):
> window := x = -5 .. 5, y = -4 .. 4:
>
> A1 := DEplot(sis, [x(t), y(t)], t = -1 .. 1, window, arrows = medium):
> A2 := display(map(implicitplot, nullcline, window, color = GREEN, thickness = 3)):
>
> display({A1, A2});

And this is the phase plane..








Before I stopped it, I say thanks to Mr. Ali Kusnanto as my lecturer, for giving a good explanation about differential equation..

See you next time !!