Sink
> A := matrix( [ [ -2, -2 ], [ -1, -3 ] ] );
>
> charpoly( A, lambda );
> eigenvals( A );
With two negative eigenvalues, the origin is a sink for this system.
>
> eigenvects( A );
>
The straight-line solutions are:
> Y1 := exp(-t) * matrix( 2, 1, [ -2, 1 ] );
> Y2 := exp(-4*t) * matrix( 2, 1, [ 1, 1 ] );
>
> ode1 := diff( x(t), t ) = -2*x(t) - 2*y(t);
> ode2 := diff( y(t), t ) = -x(t) - 3*y(t);
> MODEL := { ode1, ode2 }:
> VARS := { x(t), y(t) }:
> DOMAIN := t=0..1:
> RANGE := x=-2..2, y=-2..2:
> dirPLOT := DEplot( MODEL, VARS, DOMAIN, RANGE, arrows=MEDIUM ):
> dirPLOT;
>
>
IC := [ [ x(0)=1, y(0)=2 ], [ x(0)=0, y(0)=2 ], [ x(0)=-1, y(0)=2 ],
[ x(0)=1, y(0)=-2 ], [ x(0)=0, y(0)=-2 ], [ x(0)=-1, y(0)=-2 ],
[ x(0)=2, y(0)=1 ], [ x(0)=2, y(0)=0 ], [ x(0)=2, y(0)=-2 ],
[ x(0)=-2, y(0)=2 ], [ x(0)=-2, y(0)=0 ], [ x(0)=-2, y(0)=-1 ] ]:
> solPLOT := DEplot( MODEL, VARS, DOMAIN, RANGE, IC, arrows=NONE, stepsize=0.1, linecolor=GREEN ):
> #solPLOT;
>
>
ICline := [ [ x(0)=2, y(0)=2], [ x(0)=-2, y(0)=-2 ],
[ x(0)=2, y(0)=-1 ], [ x(0)=-2, y(0)=1 ] ]:
> linePLOT := DEplot( MODEL, VARS, DOMAIN, RANGE, ICline, arrows=NONE, linecolor=BLUE ):
> #linePLOT;
>
> display( [ dirPLOT, solPLOT, linePLOT ], title=`Example of Sink` );
Notice how the solutions converge towards the origin along paths that are tangent to the smaller eigenvalue. The different sizes of the eigenvalues can also be seen by noting the relative length of the two straight-line solutions.
>