Equilibria
of
Linear 2-D Dynamical Systems

by
K. D.  Stroyan
University of Iowa

copyright 1997 by Academic Press, Inc. - All rights reserved.

Special Mathematica Functions: flow2D[.] & vectorFlow2D[.]

Off[General::spell];
Off[General::spell1];
Off[InterpolatingFunction::dmval];
Off[ParametricPlot::pptr];
Off[Graphics::gprim];
Off[Graphics::gptn];
Off[NDSolve::ndsz];

Needs["Graphics`Colors`"]
	
colorQ[a_]:=(Head[a]===RGBColor);
grayQ[a_]:=(Head[a]===GrayLevel);
thickQ[a_]:=(Head[a]===Thickness);
absthickQ[a_]:=(Head[a]===AbsoluteThickness);
notruleQ[u_] := !(Head[u]===Rule);
ruleQ[u_] := (Head[u]===Rule);

Norm::usage = "Norm[expr] returns the Euclidean length of the
		vector, 'expr'.";
Norm[a_?VectorQ] := Sqrt[a.a];

tol = .5*10^-6;

Vector2D[tail_,tip_,opts___]:=
	Module[{ntail,ntip,sopts,Punit,up,arrow},
	ntail = N[tail];
	ntip = N[tip];
	
	sopts = Join[Select[{opts},colorQ],Select[{opts},
				thickQ],Select[{opts},absthickQ],Select[{opts},grayQ]];

If[Chop[ntail.ntail+ntip.ntip,tol] == 0,
			(*too small to plot or not number*)
			Return[Graphics[Point[{0,0}]]];
	,						
If[Chop[(ntip-ntail).(ntip-ntail),tol] == 0,
		Return[Graphics[{Join[sopts,{Line[{ntail,ntip}]}]}]];
	,
	Punit = (.075 Norm[ntip-ntail]/Norm[ntip-ntail]) (ntip-ntail) ;
	up = 0.15 {-Punit[[2]],Punit[[1]]};
	arrow = Line[{ntail,ntip,ntip-Punit+up,ntip,ntip-Punit-up}];
	]];
Return[Graphics[{Join[{AbsoluteThickness[2]},Join[sopts,{arrow}]]}]];
];

		
uArrow[vec_,opts___]:= 
	Module[{a,b},
		If[Norm[N[vec]]<1,b = vec,b=vec/Norm[vec]];
				a=ToExpression["Tail"]/.Select[{opts},ruleQ]/.
					{ToExpression["Tail"]->{0,0}};
				Return[Vector2D[a,a+b,opts]]
				];

flow2D[{f_,g_},{x_,y_,t_},initVals_,tFinal_,dt_,opns___] :=
 Module[{soln,arr,pt,crv,tt},
soln = Flatten[Map[
	NDSolve[{x[0]==#[[1]],y[0]==#[[2]],
	x'[t] == f[x[t],y[t]],y'[t] == g[x[t],y[t]]},
	{x[t],y[t]},{t,0,tFinal}]&,
										initVals],1];
											
pt[tt_] := Map[Graphics[{Blue,AbsolutePointSize[4],Point[{#[[1]],#[[2]]}]}]&,
{x[t],y[t]}/.soln/.t->tt];
										
crv[tt_] := ParametricPlot[Evaluate[{x[t],y[t]}/.soln],{t,0,tt},opns,
			AspectRatio->1,DisplayFunction->Identity];
			
Show[{crv[dt/100],pt[0]},opns,AspectRatio->1,
DisplayFunction->$DisplayFunction];
Do[Show[{crv[tt],pt[tt]},DisplayFunction->$DisplayFunction];,
{tt,dt,tFinal,dt}];
	Return[soln];	
];

vectorFlow2D[{f_,g_},{x_,y_,t_},initVals_,tFinal_,dt_,opns___] :=
 Module[{soln,arr,pt,crv,tt},
soln = Flatten[Map[
	NDSolve[{x[0]==#[[1]],y[0]==#[[2]],
	x'[t] == f[x[t],y[t]],y'[t] == g[x[t],y[t]]},
	{x[t],y[t]},{t,0,tFinal}]&,
										initVals],1];
								
	arr[tt_] := Map[uArrow[{f[#[[1]],#[[2]]],g[#[[1]],#[[2]]]},Tail->#,Red]&,
	{x[t],y[t]}/.soln/.t->tt];
	
pt[tt_] := Map[Graphics[{Blue,AbsolutePointSize[4],Point[{#[[1]],#[[2]]}]}]&,
{x[t],y[t]}/.soln/.t->tt];
										
crv[tt_] := ParametricPlot[Evaluate[{x[t],y[t]}/.soln],{t,0,tt},opns,
			AspectRatio->1,DisplayFunction->Identity];
			
Show[{crv[dt/100],pt[0],arr[dt/100]},opns,AspectRatio->1,
DisplayFunction->$DisplayFunction];
Do[Show[{crv[tt],arr[tt],pt[tt]},DisplayFunction->$DisplayFunction];,
{tt,dt,tFinal,dt}];
	Return[soln];	
];

BeginPackage["Graphics`flow2D`"]
flow2D::usage =
"flow2D[{f,g},{x,y},initialValues,tFinal,dt,(options)]
	shows the flow solution of dx = f[x,y] dt, dy = g[x,y] dt 
	starting with the initial (x,y)-values = initialValues = {{a,b},{c,d},...}
	flowing up to time tFinal with animation frames every dt time units."

Begin["`Private`"]
stuff goes here 
End[]
EndPackage[]

Notebook Overview

This NoteBook shows the flow associated with 2-D linear systems in the main cases of "eigenvalues" or roots of the characertistic equation.

The "phase Variable" Trick

2-D systems like

(dx/dt) = (Subscript[a, 1]) x + (Subscript[a, 2]) y(dy/dt) = (Subscript[b, 1]) x + (Subscript[b, 2]) y

arise from second order scalar equations like the equation for an object of mass  m  suspended from a spring with constant  s  and damping constant  c:

m (( (d^2) x)/(dt^2)) + c (( dx)/dt) + s x = 0
<=>

(((d^2) x)/(dt^2)) = -(s/m) x - (c/m) (dx/( dt))
<=>

(dx/dt) = y(dy/dt) = -((s )/m) x - ((c )/m) y

In other words, the second order equation m (( (d^2) x)/(dt^2)) + c (( dx)/dt) + s x = 0 can be written as the 2-D system

(dx/dt) = (Subscript[a, 1]) x + (Subscript[a, 2]) y(dy/dt) = (Subscript[b, 1]) x + (Subscript[b, 2]) y

with  a1=0, a2=1, b1= -s/m, b2=-c/m.  Except in a few special cases (described in the text) a general linear 2-D system can also be re-written as a scalar second order equation.

The Characteristic Equation

See Chapter 23 to understand the role of the roots of the equation

(r^2) + (c/m) r + (s/m) == 0

or in the 2-D form

Det[(({{(Subscript[a, 1]) - r, (Subscript[b, 1])}, {(Subscript[a, 2]), (Subscript[b, 2]) - r}}))]= 
	(r^2) - ((Subscript[a, 1]) + (Subscript[b, 2])) r + ((Subscript[a, 1]) (Subscript[b, 2]) - (Subscript[a, 2]) (Subscript[b, 1]))  ==  0

The next cell solves these symbolically with Mathematica.

Clear[r, a1, a2, b1, b2, s, c, m]; charPoly=Det[(({{a1 - r, b1}, {a2, b2 - r}}))]charRoots = Solve[charPoly == 0, r]a1 = 0; a2 = 1; b1 = -(s/m); b2 = -(c/m); charPolycharRoots

The importance of these roots is that  x[t]  and  y[t]  are linear combinations of exponential functions  Exp[ r1 t]  and Exp[ r2 t].

\(Clear[x, y, t]; 
m = 1; 
\(c = 3; \)\)\(s = 1; 
charRoots\)\(DSolve[

      	{\(x'\)[t] == a1\ x[t] + b1\ y[t], 
		
        \(y'\)[t] == a2\ x[t]\  + \ b2\ y[t], 
		x[0] == 1, y[0] == 1}, {
        x[t], y[t]}, t]\)

References to the Text

This NoteBook goes with Chapters 23 and 24 of the text.  The second order equation is emphasized in Chapter 23 and the general system is emphasized in Chapter 24.

The Basic System

Clear[f, g, x, y, r, m, c, s]; f[x_, y_] := yg[x_, y_] := -((s x)/m) - ((c y)/m)Print["Solutions to:"]; Print["dx = ", f[x, y], " dt"]; \(Print["dy = ", g[x, y], " dt"]; 

    Print["with characteristic roots"]; 

    charRoots = Solve[r\^2 + \(c\ r\)\/m + s\/m == 0, r]\)

Negative Roots

m = 1; c = 3; s = 1; Print["Characteristic roots = ", charRoots]; Print["approximately ~", N[charRoots]];

\(Clear[x, y, t]; 

    genlSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]]}, {x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. genlSoln]; 

    Print["General Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 

    sampleSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]], 
		x[0] == 1, 
		y[0] == 0}, {
          x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. sampleSoln]; 

    Print["Specific Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 
initxys = Table[{x, x}, {x, \(-10\), 10, 2}]; 

    initxys = initxys ⋃ Table[{\(-y\), 10}, {y, 4, 10, 2}]; 

    initxys = initxys ⋃ Table[{y, \(-10\)}, {y, 4, 10, 2}]; 

    tfinal = 4.0; 
dt = 1; 

    flow2D[{f, g}, {x, y, t}, initxys, tfinal, dt, 
      PlotRange -> {{\(-10\), 10}, {\(-10\), 10}}, 
      AxesLabel -> {"x", "y"}, AxesOrigin -> {0, 0}]; \)

Repeated Roots

Clear[x, y, t]; m = 1; c = 2; s = 1; Print["Characteristic roots = ", charRoots]; Print["approximately ~", N[charRoots]];

\(Clear[x, y, t]; 

    genlSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]]}, {x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. genlSoln]; 

    Print["General Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 

    sampleSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]], 
		x[0] == 1, 
		y[0] == 0}, {
          x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. sampleSoln]; 

    Print["Specific Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 
initxys = Table[{0, x}, {x, \(-15\), 15, 3}]; 

    tfinal = 4.0; 
dt = 1; 

    flow2D[{f, g}, {x, y, t}, initxys, tfinal, dt, 
      PlotRange -> {{\(-10\), 10}, {\(-10\), 10}}, 
      AxesLabel -> {"x", "y"}, AxesOrigin -> {0, 0}]; \)

Opposite Roots

m = 1; c = 0; s = -1; Print["Characteristic roots = ", charRoots]; Print["approximately ~", N[charRoots]];

\(Clear[x, y, t]; 

    genlSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]]}, {x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. genlSoln]; 

    Print["General Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 

    sampleSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]], 
		x[0] == 1, 
		y[0] == 0}, {
          x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. sampleSoln]; 

    Print["Specific Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 
initxys = Table[{x, x}, {x, \(-4\), 4, 2}]; 

    \(initxys = initxys ⋃ Table[{\(-y\), y}, {y, \(-10\), 10, 5}]; 
    \)\)initxys = 
      initxys ⋃ Table[{-x + (1/2), x}, {x, -20, 20, 5}]; \(initxys = 
      initxys ⋃ Table[{\(-x\) - 1\/2, x}, {x, \(-20\), 20, 5}]; 

    tfinal = 4.0; 
dt = 1; 

    flow2D[{f, g}, {x, y, t}, initxys, tfinal, dt, 
      PlotRange -> {{\(-10\), 10}, {\(-10\), 10}}, 
      AxesLabel -> {"x", "y"}, AxesOrigin -> {0, 0}]; \)

Imaginary Roots

m = 4; c = 0; s = 1; Print["Characteristic roots = ", charRoots]; Print["approximately ~", N[charRoots]];

\(Clear[x, y, t]; 

    genlSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]]}, {x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. genlSoln]; 

    Print["General Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 

    sampleSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]], 
		x[0] == 1, 
		y[0] == 0}, {
          x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. sampleSoln]; 

    Print["Specific Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 
initxys = Table[{x, 0}, {x, \(-10\), 10, 2}]; 

    tfinal = 4.0; 
dt = 1; 

    flow2D[{f, g}, {x, y, t}, initxys, 4\ tfinal, dt, 
      PlotRange -> {{\(-10\), 10}, {\(-10\), 10}}, 
      AxesLabel -> {"x", "y"}, AxesOrigin -> {0, 0}]; \)

Complex Roots

m = 1; c = (1/2); s = 1; Print["Characteristic roots = ", charRoots]; Print["approximately ~", N[charRoots]];

\(Clear[x, y, t]; 

    sampleSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]], 
		x[0] == 1, 
		y[0] == 0}, {
          x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. sampleSoln]; 

    Print["Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

ParametricPlot[{x[t], y[t]}, {t, 0, 10}]

\(Clear[x, y, t]; 

    genlSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]]}, {x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. genlSoln]; 

    Print["General Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 
initxys = Table[{x, x}, {x, \(-10\), 10, 2}]; 

    tfinal = 4.0; 
dt = 1; 

    flow2D[{f, g}, {x, y, t}, initxys, 4\ tfinal, dt, 
      PlotRange -> {{\(-10\), 10}, {\(-10\), 10}}, 
      AxesLabel -> {"x", "y"}, AxesOrigin -> {0, 0}]; \)

Practice Exercise

Find the flow of
	dx/dt = y
	dy/dt = (-s/m) x + (-c/m) y
	m = 1;
	c = -1;
	s = -2;
HINT: Try the initial values in the Opposite Roots example.

The 2 X 2 General System: Step-by-Step

Clear[f, g, x, y, r, a1, b1, a2, b2]; mat = {{a1, a2}, {b1, b2}}; f[x_, y_] := a1 x + a2 y; g[x_, y_] := b1 x + b2 y; Print["Solutions to:"]; Print["dx = ", f[x, y], " dt"]; \(Print["dy = ", g[x, y], " dt"]; 

    Print["with characteristic roots"]; 

    charRoots = Solve[Det[mat - r\ IdentityMatrix[2]] == 0, r]\)

Example: a1 = -2; a2 = 0; b1 = 0; b2 = -1

a1 = -2; a2 = 0; b1 = 0; b2 = -1; Print["Characteristic roots = ", charRoots]; Print["approximately ~", N[charRoots]];

\(Clear[x, y, t]; 

    genlSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]]}, {x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. genlSoln]; 

    Print["General Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 

    sampleSoln\  = \ 
      DSolve[
	{\(x'\)[t] == f[x[t], \ y[t]], 
		
          \(y'\)[t] == g[x[t], y[t]], 
		x[0] == 1, 
		y[0] == 1}, {
          x[t], y[t]}, t]; 
    
{x[t_], y[t_]} = Flatten[{x[t], y[t]} /. sampleSoln]; 

    Print["Specific Solution:"]; 
Print["x[t] = ", x[t]]; 

    Print["y[t] = ", y[t]]; \)

\(Clear[x, y, t]; 
initxys = Table[{x, x}, {x, \(-10\), 10, 2}]; 

    initxys = initxys ⋃ Table[{\(-y\), y}, {y, \(-10\), 10, 2}]; 

    tfinal = 4.0; 
dt = 1; 

    vectorFlow2D[{f, g}, {x, y, t}, initxys, tfinal, dt, 
      PlotRange -> {{\(-10\), 10}, {\(-10\), 10}}, 
      AxesLabel -> {"x", "y"}, AxesOrigin -> {0, 0}]; \)

Practice Exercise: a1 = 1; a2 = 0; b1 = 0; b2 = -1;

Find the flow of
	dx/dt = a1 x + b1 y
	dy/dt = a2 x + b2 y
when a1 = 1; b1 = 0; a2 = 0; b2 = -1;

A 2 X 2 System with its Invariant Directions

\(Clear[f, g, u, v, r, a1, b1, a2, b2, t]; 
mat = {{a1, a2}, {b1, b2}}; 
    
f[u_, v_] := a1\ u + a2\ v; 
g[u_, v_] := b1\ u + b2\ v; 
    
{{a1, a2}, {b1, b2}} = {{\(-1\), \(-1\)}, {\(-2\)/3, \(-1\)/3}}; 

    Print["Solutions to:"]; 
Print["du = ", f[u, v], " dt"]; 

    Print["dv = ", g[u, v], " dt"]; 

    Print["with characteristic roots:"]; 

    charRoots = Solve[Det[mat - r\ IdentityMatrix[2]] == 0, r]\)Print["approximately ~", N[charRoots]];

Print["and invariant directions:"]; Eigenvectors[mat]N[%]

\(tfinal = 4.0; 
dt = 1; 
inituvs = Table[{x, x}, {x, \(-3\), 3, 1}]; 

    inituvs = inituvs ⋃ Table[{y, y/6}, {y, \(-3\), 3, 1}]; 

    AppendTo[inituvs, {\ \((1 + \@7)\), 2}]; 

    AppendTo[inituvs, \(-{\ \((1 + \@7)\), 2}\)]; 

    AppendTo[inituvs, {\ \((1 - \@7)\), 2}/9]; 

    AppendTo[inituvs, \(-{\ \((1 - \@7)\), 2}\)/9]; 

    flow2D[{f, g}, {u, v, t}, inituvs, \ tfinal, dt, 
      PlotRange -> {{\(-4\), 4}, {\(-4\), 4}}, 
      AxesLabel -> {"u", "v"}, AxesOrigin -> {0, 0}]; \)

Exercises

Exercise 23.7.1 Extended

Use the phase variable trick to write the second order equation

a x''[t] + b x'[t] + c x[t] == 0

as a 2 X 2 system

dx/dt = f[x,y] = ??
	dy/dt = g[x,y] = ???

and then find the flow:

For a = 1; b = 0; c = -4;

For a = 1; b = 3; c = 2;

For a = 1; b = 2; c = 2;

For a = 1; b = 2; c = 1;

Exercises 24.2.1 &  24.3.1  Nonlinear and Linear Equilibria

Equilibria of general autonomous systems are characterized by local behavior that "looks like" the linear behavior under a microscope.  Compare the flow of

dx/dt = 2x(1 - x/4 - y/4)
	dy/dt =  y(1 - x/3 - y/6)

\(Clear[f, g, x, y, t]; 

    f[x_, y_]\  := \ 2  x \((1\  - \ x/4\  - \ y/4)\); 

    g[x_, y_]\  := \ \ y \((1\  - \ x/3\  - \ y/6)\); 
tfinal = 4.0; 

    dt = 1; 
initxys = Table[{10, x}, {x, \(-2\), 10, 2}]; 

    initxys = initxys ⋃ Table[{\(-1\)/2, y}, {y, \(-3\)/2, 5/2, 1}]; 

    initxys = initxys ⋃ Table[{1/2, y}, {y, \(-5\)/2, 5/2, 1}]; 

    initxys = 
      initxys ⋃ {{1/6, 0}, {\(-1\)/6, 0}, {0, 1/6}, {0, \(-1\)/6}}; 

    flow2D[{f, g}, {x, y, t}, initxys, \ 2  tfinal, dt, 
      PlotRange -> {{\(-4\), 10}, {\(-4\), 10}}, 
      AxesLabel -> {"x", "y"}, AxesOrigin -> {0, 0}]; \)

Near the nonlinear equilibrium  (0,0) with the flow of the linearization
	du/dt = 2 u 
	dv/dt = v
and compute the characterisitc roots of the linearization at (0,0).

\(
\)

Near the nonlinear equilibrium (2,2) with the flow of the linearization
	du/dt =  -u  - v
	dv/dt = -2u/3 - v/3
and compute the characterisitc roots of the linearization at (2,2).

\(
\)

Near the nonlinear equilibrium (4,0) with the flow of the linearization
	du/dt = -2u - 2v
	dv/dt = -v/3
and compute the characterisitc roots of the linearization at (4,0).

\(
\)

Near the nonlinear equilibrium (0,6) with the flow of the linearization
	du/dt = -u 
	dv/dt =-2u - v
and compute the characterisitc roots of the linearization at (0,6).

\(
\)

Exercise 24.3.2 Nonlinear and Linear Equilibria

Find the positive equilibrium of the system and compare the nonlinear flow near the equilibrium with the linearized system at the equilibrium.

a

dx/dt = x(1 - x/7 - y/7)
	dy/dt = y(1 - x/10 -y/5)

c

dx/dt = x(1 - x/10 -y/5)
	dy/dt = y(1 - x/7 - y/7)

Exercise 24.3.3 Magnification

Make a flow of the nonlinear system
	dx/dt = y
	dy/dt = -x - 15x^3 - 2y
on a large scale, say -10<x<10 & -10<y<10 for a long time.

Make a flow of the nonlinear system
	dx/dt = y
	dy/dt = -x - 15x^3 - 2y
on a medium scale, say -1<x<1 & -1<y<1 for the same time.

Make a flow of the linear system
	dx/dt = y
	dy/dt = -x  - 2y
on a small scale, say -0.01<x<0.01 & -0.01<y<0.01 for the same time.

Exercise 24.3.4 Nonlinear and Linear Equilibria

Find the equilibria of the system and compare the nonlinear flow near the equilibria with the linearized system at the equilibrium.

dx/dt = y(1 - x/10 -y/5)
	dy/dt = x(1 - x/7 - y/7)

Exercise 24.2.4 Time Reversal

The various kinds of equilibria of linear systems follow the cases above (with either positive or negative signs.)  Show that a system with characteristic roots - r1, -r2  has the same flow as that of a starting system where the time is reversed.  The flow can be seen by  clicking  (<-)  in the original flow animation.

For example, starting with
dx/dt = y
dy/dt = (-s/m) x + (-c/m) y
m = 1;
c = -1;
s = -2;
let  T = -t.  Then  dx/dT = dx/dt dt/dT, by the chain rule, so
dx/dT = -y
dy/dT = (s/m) x + (c/m) y
What are the old and new characteristic roots?

Make both flows and show that one is the same as the other with the direction of the animation reversed.