Section 1.3: Introduction - Systems of differential equations
Section 1.3: Introduction - Systems of differential equations
In this course we will start to look at some very simple, yet powerful tools for understanding dynamical systems.
The first thing that we’re going to have to look at it in detail is the language of mathematics that we will be using. I’ve already outlined above that we will be using differential equations, but these come in a variety of forms.
In this course we will almost entirely be using First order systems of differential equation. An example of this might be:
X'(t)=X(t)-Y(t)
Y'(t)=X(t)
This says that I have two variables, X and Y. They can both change with time. The rate of change of X at any given time is given by the difference between the values of X and Y at that time, and the rate of change of Y is given by the value of X at that time. In the following you can see the solution to these equations plotted as a function of t. As you change the initial values (ie. at time t=0) of X and Y, the solutions change. You don’t need to be able to solve these equations. This is for illustration purposes only. Click here for a version that where you can change the initial conditions.
In[]:=
{x[t],y[t]}/.DSolve[{x'[t]==x[t]-y[t],y'[t]==x[t],x[0]==c1,y[0]==c2},{x,y},t][[1]]Manipulate[Plot[%,{t,0,6},PlotRange->{-10,10},PlotStyle->{Red,Blue},PlotLabels{"X(t)","Y(t)"},AxesLabel{"t","X,Y"}],{{c1,0.5,"x[0]"},0,1},{{c2,0.5,"y[0]"},0,1},SaveDefinitions->True]
Out[]=
--3c1Cos-+2,3c2Cos+2-
1
3
t/2
3
t2
3
c1Sin3
t2
3
c2Sin3
t2
1
3
t/2
3
t2
3
c1Sin3
t2
3
c2Sin3
t2
OK, so that is one example of a first order system of two differential equations. We can be a bit more general. We can write down a system of n first-order differential equations:
x
1
f
1
x
1
x
2
x
n
(
0
.1
)x
2
f
2
x
1
x
2
x
n
(
0
.2
)....
x
n
f
n
x
1
x
2
x
n
(
0
.3
)where we have n variables to and their derivatives are given by n functions towhichmaybefunctionsofallofthevariables. These are called first order because we have only a single derivative.
x
1
x
n
f
1
f
n
These 'scould be many things. For instance if we were talking about a particle moving around in three dimensions then they might correspond to the coordinates so we would have that is the traditional x coordinate, is the y coordinate, and is the z coordinate. Here is a particle moving about in three dimensions with the 's changing in time.
x
i
x
1
x
2
x
3
x
i
In[]:=
frames=Table[ListPointPlot3D[{{Sin[t],Cos[t],Sin[t]*Cos[t]}}/.t->3,PlotRange->{{-1.5,1.5},{-1.5,1.5},{-1.5,1.5}},BoxRatios->1,PlotStyle->PointSize[0.02],PlotLabel->"{x="<>ToString[Sin[t]]<>", y="<>ToString[Cos[t]]<>", z="<>ToString[Sin[t]Cos[t]]<>"}"],{t,0,10,0.1}];ListAnimate[frames,SaveDefinitionsTrue]
The differential equation just says that however the thing is moving, the rate of change of the 's has some fixed relationship with the value of the 'sthemselves.
x
i
x
i
If we had second derivatives, these would be second order differential equations. Here is an example of a single, second order differential equation:
x''(t)+x'(t)+3sin(x(t))=0
Now comes some magic. It turns out that we can always take a second order differential equation and turn it into two first order differential equations. Let’s actually take this one above. The first thing that we will do...and this is what you should always do, is to define some new variable (let’s call it y) as the derivative of your first variable. So we are simply going to define:
y(t)=x'(t)
You agree that I can do that right? I can always have a new function which is simply defined as the derivative of our original one. OK, very good. Well, that means that the second derivative of x is the first derivative of y:
y'(t)=x''(t)
Now our job will be to eliminate all second derivatives using that last expression:
x''(t)+x'(t)+3sin(x(t))=0⟶y'(t)+x'(t)+3sin(x(t))=0
So now we could write:
y'(t)=-(x'(t)+3sin(x(t)))
x'(t)=y(t)
In fact we could do better than that. We would really like to have expressions as we had in our general case for the system of equations. So we can also get rid of the on the right hand side and just replace it with y(t). So now we have:
x'(t)
y'(t)=-(y(t)+3sin(x(t)))
x'(t)=y(t)
We have just converted our second order equation into two first order equations which fulfil the pattern that we defined above in equations 0.1 to 0.3.
OK, now your turn. Here are a series of second order equations. Try and put them into the form of systems of first order equations
x''(t)+x'(t)=3
(
1
)x''(t)+3x'(t)-4x(t)=sin(x(t))
(
2
)x''(t)+y(t)+x'(t)=y''(t)-y'(t)+x(t)=
2
x(t)
2
y(t)
(
3
)x'''(t)+x'(t)=x''
2
(t)
(
4
)
Hang on a minute. Why are we doing this? Well, it turns out to be really convenient to work with systems of first order equations in general.