John Cagnol


Paris, France

Introduction au Calcul Scientifique
ESI CS 1402 - Printemps 2010

Simulations faites avec Maple dans le chapitre II, Paragraphe III

> g:=(x,y)->x+y-ln(x*y);
proc (x, y) options operator, arrow; `+`(x, y, `-`(ln(`*`(x, `*`(y))))) end proc
> plot3d({g(x,y),3},x=0.1..5,y=0.1..5,axes=BOXED);
Plot
> with(DEtools):
alpha:=.2;
equation1 := diff(u(t), t) = u(t)*(1-v(t));
equation2 := diff(v(t), t) = -alpha*v(t)*(1-u(t));
u0:=.5;
v0:=.5;
.2
diff(u(t), t) = `*`(u(t), `*`(`+`(1, `-`(v(t)))))
diff(v(t), t) = `+`(`-`(`*`(.2, `*`(v(t), `*`(`+`(1, `-`(u(t))))))))
.5
.5
> DEplot({equation1, equation2}, {u(t), v(t)}, t = 0 .. 40, u = 0 .. 8, v = 0 .. 5, [[u(0) = u0, v(0) = v0]], stepsize = 0.1e-2, numpoints = 7009, animatecurves = true);
Plot_2d
> Nplot:=DEplot({equation1, equation2}, {u(t), v(t)}, t = 0 .. 40, [[u(0) = u0, v(0) = v0]], scene=[t,u(t)], stepsize = 0.1e-2, linecolor=red):
Pplot:=DEplot({equation1, equation2}, {u(t), v(t)}, t = 0 .. 40, [[u(0) = u0, v(0) = v0]], scene=[t,v(t)], stepsize = 0.1e-2, linecolor=blue):
plots[display](Nplot,Pplot);
Plot_2d