3 Lecture 3: First order Ordinary Differential Equations

advertisement
Mathematics for Physics 3: Dynamics and Differential Equations
3
32
Lecture 3: First order Ordinary Differential Equations
In the previous lecture we introduced the subject of ordinary differential equations, and solved a couple of simple
equations. Now we shall discuss a few more methods which will help us extend the range of equations we can handle.
In the first part of the lecture we will consider non-linear first-order equations, which nevertheless admit analytic
solutions. Using appropriate change of variables we will bring them into an easier form, either a linear ODE or
non-linear but separable ODE.
In the second part of the lecture we will develop a general method to solve linear first-order differential equations.
NON-LINEAR FIRST-ORDER ORDINARY DIFFERENTIAL EQUATIONS
Very often differential equations can be brought into a simpler form by an appropriate change of variables. Let
us demonstrate it here using a couple of examples.
Consider first a particular class of first order ODE involving homogeneous functions. Consider an equation of
the form
dx
= f (x, t)
(54)
dt
where f is an homogeneous function of degree zero. Homogeneous function f (x, t) of degree n is a function that
admits
f (λx, λt) = λn f (x, t) .
(55)
Homogeneous function of degree zero is therefore a function which is invariant under simultaneous rescaling of x and
t. So, if f in (54) is such a function one can make use of its rescaling-invariance to simplify the equation. This can
be done by defining a new dependent variable by y(t) = x(t)/t. The r.h.s. of (54) is then
f (x, t) = f (ty, t) = f (y, 1)
so it really does not depend explicitly on t (it depends on t only through y(t)). The l.h.s. of the equation can be
computed as a derivative of a product (using x(t) = y(t)t):
dx
dy
=t
+y
dt
dt
The equation then takes the form:
dy
+ y = f (y, 1)
dt
which we recognize as a separable equation: we can rewrite it as
t
(56)
dt
dy
=
t
f (y, 1) − y
(57)
and integrate. Finally we can revert to the original variable using x(t) = y(t)t.
Let us consider a simple explicit example of the above situation:
dx
xt
= 2
dt
t − x2
(58)
dy
y
+y =
dt
1 − y2
(59)
dt
dy(1 − y 2 )
=
t
y3
(60)
Defining y(t) = x(t)/t the equation becomes:
t
which is a separable equation. We can write it as:
and perform the integration to get:
ln(t) + C = −
1 1
− ln(y)
2 y2
(61)
Reverting to the original variable we finally have:
ln(t) + C = −
1 t2
− ln(x/t)
2 x2
=⇒
C=−
1 t2
− ln(x)
2 x2
(62)
Mathematics for Physics 3: Dynamics and Differential Equations
33
Note that this is an implicit solution: there is no explicit solution in this case.
Another example for changing variables in a non-linear equation is following first-order rational ODE:
dx
a 1 t + b1 x + c 1
=
dt
a 2 t + b2 x + c 2
(63)
Now it is convenient to first shift both the dependent and independent variables, so as to bring the r.h.s. to a form
of a homogeneous function of degree zero. Define
t̃ = t + τ ;
x̃ = x + η
such that
a1 t + b1 x + c1 = a1 t̃ + b1 x̃
(64)
a2 t + b2 x + c2 = a2 t̃ + b2 x̃
Since for this change of variables
dx̃ = dx + 0,
dt̃ = dt + 0
the equations get transformed into
dx̃
a1 t̃ + b1 x̃
=
dt̃
a2 t̃ + b2 x̃
(65)
Here the r.h.s. is an homogeneous function of degree zero so we can rescale x̃ by t̃, defining y(t̃) = x̃(t̃)/t̃, and getting
a separable equation for y(t̃):
dy
a 1 + b1 y
t̃
+y =
.
(66)
a 2 + b2 y
dt̃
According to (64), in order to determine the shift constants τ and η one simply has to solve:
c 1 = a 1 τ + b1 η
(67)
c 2 = a 2 τ + b2 η
which has a solution unless a1 b2 − a2 b1 = 0 (vanishing determinant). In the latter case a change of variables such as
y = a1 t + b1 x would yield a separable equation.
Another example of non-linear equations which can be solved by a change of variables is the Bernoulli Differential Equations, which take the form:
dx
+ p(t) x = q(t) xn
(68)
dt
where p(t) and q(t) are functions of t and n is a real constant (we assume n �= 1 and n �= 0, cases where the equation
is readily linear). Dividing by xn we obtain:
x−n
dx
+ p(t) x1−n = q(t) .
dt
(69)
Next define the following change of dependent variable:
x1−n ≡ y ,
=⇒
(1 − n) x−n
dx
dy
=
dt
dt
which implies that
dy
+ (1 − n) p(t) y = (1 − n) q(t) .
(70)
dt
This is a linear ODE, which is straightforward to solve. We now develop a general strategy to solve such equations.
First order LINEAR equations and Integrating Factors:
Consider now the simple case of first order linear ODE,
dx(t)
+ P (t) x(t) = Q(t)
dt
This class of equations can always be solved using the following technique.
(71)
Mathematics for Physics 3: Dynamics and Differential Equations
34
The starting point is the observation that by multiplying the equation by an appropriate Integrating factor
I(t),
dx(t)
I(t)
+ I(t) P (t) x(t) = I(t) Q(t)
(72)
dt
the l.h.s. can be brought to the form of a full derivative of a product of functions,
�
d�
dx(t) dI(t)
I(t)x(t) = I(t)
+
x(t) .
(73)
dt
dt
dt
Comparing (73) to (72) we see that this is achieved if I(t) admits:
dI(t)
= I(t) P (t)
dt
which is a separable equation, which we can directly integrate:
�� t
�
� I(t)
� t
dI
=
dτ P (τ )
=⇒
I(t) = I(0) exp
dτ P (τ )
I(0) I
0
0
(74)
(75)
It is clear that we have the freedom of choosing to multiply I(t) by a constant. In other words, we are free to fix the
integration constant I(0) as we wish.
Having determined I(t) let us return to our equation, which now takes the form:
�
d�
I(t)x(t) = I(t) Q(t)
(76)
dt
which we can readily integrate to get:
�
�
� t
1
x(t) =
I(0)x(0) +
dτ I(τ ) Q(τ ) .
(77)
I(t)
0
As a simple example consider the equation
ẋ(t) − 2
x(t)
= (t + 1)3
t+1
subject to the initial condition x(1) = 0. Let us multiply the equation by I(t) such that
I(t)ẋ(t) − 2I(t)
We wish to have on the l.h.s. the form:
so we require that I(t) would admit
x(t)
= I(t) (t + 1)3
t+1
�
d�
˙
I(t)x(t) = I(t)ẋ(t) + I(t)x(t)
dt
˙ = −2I(t) 1
I(t)
t+1
This integrated to
I(t)
1
= −2 ln(1 + t)
=⇒ I(t) = I(0)
I(0)
(1 + t)2
Using this result for I(t), the equation takes the form:
�
�
d
x(t)
= (t + 1)
dt (1 + t)2
ln
which we integrate to get between τ = 1 and t (the choice to integrate in this range is dictated by the fact that the
initial condition is given at t = 1) getting:
�
�
� t
� t
d
x(τ )
dτ
=
dτ (τ + 1)
dτ (1 + τ )2
1
1
which yields
and finally, using x(1) = 0,
�
x(t)
x(1)
1�
−
= (t + 1)2 − (1 + 1)2
2
2
(1 + t)
(1 + 1)
2
x(t) =
�
(1 + t)2 �
(t + 1)2 − 4 .
2
Download