0% found this document useful (0 votes)
34 views13 pages

Mathematics 2 Chapter 3 2024

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views13 pages

Mathematics 2 Chapter 3 2024

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 13

University of Zimbabwe

ORDINARY DIFFERENTIAL EQUATIONS


Department:
Facilitator:
Mathematics and
Mr D. Muzadziwa
Computational Sciences

November 27, 2023


Introduction

We live in a world of inter-related changing entities. The position of the earth changes with time,
the velocity of a falling body changes with distance, the bending of a beam changes with the weight
of the load placed on it, the area of a circle changes with the size of the radius, the path of a
projectile changes with the velocity and angle at which it is fired.

In the language of mathematics, changing entities are called variables and the rate of change of
one variable with respect to another a derivative. Equations which express a relationship among
these variables and their derivatives are called differential equations. In both the natural and social
sciences many of the problems with which they are concerned give rise to such differential equations.
But what we are interested in knowing is not how the variables and their derivatives are related but
only how the variables themselves are related. For example, from certain facts about the variable
position of a particle and its rate of change with respect to time, we wish to determine how the
position of the particle is related to the time so that we can know where the particle was, is, or
will be at any time t. Differential equations thus originate whenever a universal law is expressed by
means of variables and their derivatives.

An ordinary differential equation is a relation containing one real independent variable


x ∈ R = (−∞, ∞), the real dependent variable y, and some of its derivatives i.e

F (x, y, y ′ , y ′′ , . . . , y (n) ) = 0,

The expressions y ′ , y ′′ , y ′′′ , y (4) , · · · , y (n) are often used to represent, respectively, the first, second,
third, fourth, . . . , nth derivatives of y with respect to the independent variable under consideration.
′′ d2 y d2 y
Thus y represents , if the independent variable is x, but represents if the independent
dx2 dp2
variable is p. Observe that parenthesis are used in y (n) to distinguish it from the nth power, y n .

For example,

xy ′ + 3y = 6x3
y ′2 − 4y = 0
x2 y ′′ − 3xy ′ + 3y = 0
2x2 y ′′ − y ′2 = 0.

1
The order of an ordinary differential equation is defined to be the order of the highest derivative
in the equation. Thus, first two equations are first order, whereas the last two are second order.

A functional relation between the dependent variable y and the independent variable x, that, in
some interval J, satisfies the given differential equation is said to be a solution of the equation.

Example 0.0.1. The function y(x) = 7ex + x2 + 2x + 2 is a solution of the differential equation
y ′ = y − x2 in J = R.

The general solution of an nth-order differential equation depends on n arbitrary constants, i.e.,
the solution y depends on x and the real constants c1 , c2 , . . . , cn .

Example 0.0.2. The function y(x) = x2 + cex is the general solution of the differential equation
y ′ = y − x2 + 2x in J = R.

c
The differential equation xy ′ + 3y = 6x3 has the general solution y(x) = x3 + . The function
x3
3
y(x) = x is a particular solution of the equation, and it can be obtained easily by taking the
particular value of c as 0 in the general solution.

′2 ′ 2 x2
For the differential equation y − xy + y = 0, the general solution is y(x) = cx − c and y(x) = ,
4
is a particular solution not included in the general solution. This “extra” solution, which cannot
be obtained by assigning particular values of the constants, is called a singular solution.

In the “general solution”, the word general must not be taken in the sense of complete. A totality
of all solutions of a differential equation is called a complete solution.

Consider the equation y ′′′2 − 2y ′ y ′′′ + 3y ′′3 . This is a third-order differential equation and we say
that this is of degree 2, whereas, the second order differential equation xy ′′ + 2y ′ + 3y − 6ex = 0 is
of degree 1. In general, if a differential equation has the form of an algebraic equation of degree k
in the highest derivative, then we say that the given differential equation is of degree k.

We shall assume the the differential equation

F (x, y, y ′ , y ′′ , . . . , y (n) ) = 0,

can be solved explicitly for y (n) in terms of the remaining (n + 1) quantities as

y (n) = f (x, y, y ′ , . . . , y (n−1) ),

where f is a known function.

Example 0.0.3. The differential equation y ′2 = 4y represents two differential equations,



y ′ = ±2 y.

2
Differential equations are classified into two groups : linear and non-linear. A differential equation
is said to be linear if its linear in y and all its derivatives. Thus, an nth-order linear differential
equation has the form

Pn [y] = p0 (x)y (n) + p1 (x)y (n−1) + · · · + pn (x)y = r(x).

Example 0.0.4. xy ′ + 3y = 6x3 and x2 y ′′ − 3xy ′ + 3y = 0 are linear and y ′2 − 4y = 0 and


2x2 y ′′ − y ′2 = 0 are non-linear.

If r(x) = 0, then it is called homogeneous differential equation, otherwise it is said to be a non-


homogeneous differential equation.

A differential equation along with subsidiary conditions on the unknown function and its derivatives,
all given at the same value of the independent variable, constitutes an initial-value problem. The
subsidiary conditions are initial conditions. If the subsidiary conditions are given at more than one
value of the independent variable, the problem is a boundary-value problem and the conditions
are boundary conditions.

Example 0.0.5. The problem y ′′ + 2y ′ = ex , y(π) = 1, y(π) = 2 is an initial value problem, because
the two subsidiary conditions are both given at x = π. The problem y ′′ +2y ′ = ex , y(0) = 1, y(1) = 2
is a boundary-value problem, because the two subsidiary conditions are given at x = 0 and x = 1.

A solution to an initial-value or boundary-value problem is a function y(x) that both solves the
differential equation and satisfies all given subsidiary conditions.

3
First Order Differential Equations

0.1 Standard and Differential Forms

Standard form for a first-order differential equation in the unknown function y(x) is
y ′ = f (x, y)
or in differential form
M (x, y)dx + N (x, y)dy = 0
where M (x, y) and N (x, y) are functions. If f (x, y) can be written as f (x, y) = −p(x)y + q(x), the
differential equation is linear. First-order linear differential equation can always be expressed as
y ′ + p(x)y = q(x).

0.2 Solutions of First Order Differential Equations

0.2.1 Separable Equations

The solution to the first-order separable differential equation


A(x)dx + B(y)dy = 0
is Z Z
A(x)dx + B(y)dy = c

where c is an arbitrary constant.


dy x2 + 2
Example 0.2.1. Solve = .
dx y

Solution: Can be written in the differential form


(x2 + 2)dx − ydy = 0

4
which is separable with A(x) = x2 + 2 and B(y) = −y. Its solution is
Z Z
2
(x + 2)dx − ydy = c

or
1 3 1
x + 2x − y 2 = c.
3 2
Example 0.2.2. Solve (1 + x)dy − ydx = 0.
dy dx
Solution: Dividing by (1 + x)y, we can write = , from which it follows that
y 1+x
Z Z
dy dx
=
y 1+x
ln |y| = ln |1 + x| + c1
y = eln |1+x|+c1
y = ec1 (1 + x) = c(1 + x).
dy x
Example 0.2.3. Solve the initial value problem = − , y(4) = −3.
dx y

Solution: Rewriting the equation as ydy = −xdx, we get


y2 x2
Z Z
ydy = − xdx or = − + c.
2 2
Now when x = 4, y = −3, so we have x2 + y 2 = 25.
Example 0.2.4. Solve y ′ = −2xy, y(0) = 1.8.

dy 2
Solition: By separation and integration, = −2xdx, ln y = −x2 + d or y = ce−x . This is the
y
general solution. From it and the initial condition y(0) = ce0 = c = 1.8. Hence the IVP has the
2
solution y = 1.8e−x .

0.3 Use of Substitutions : Homogeneous Equations

If a function f possess the property

f (tx, ty) = tα f (x, y)

for some real number α, then f is said to be a homogeneous function of degree α.


Example 0.3.1. The function f (x, y) = x3 + y 3 is homogeneous of degree 3 because

f (tx, ty) = (tx)3 + (ty)3 = t3 (x3 + y 3 ) = t3 f (x, y).

5
A differential equation of the form M (x, y)dx + N (x, y)dy = 0 is said to be homogeneous if both
coefficients M and N are homogeneous functions of the same degree. Such an equation can be
reduced to separable variables by either the substitution y = ux or x = vy, where u and v are new
dependent variables.
Example 0.3.2. Solve (x2 + y 2 )dx + (x2 − xy)dy = 0.

Solution: Inspection of M (x, y) = x2 + y 2 and N (x, y) = x2 − xy shows that these coefficients are
homogeneous functions of degree 2. If we let y = ux, then
dy = udx + xdu,
so that, after substituting, the given equation becomes
(x2 + u2 x2 )dx + (x2 − ux2 )[udx + xdu] = 0
x2 (1 + u)dx + x3 (1 − u)du = 0
1−u dx
du + = 0
 1 + u x
2 dx
−1 + du + = 0.
1+u x
After integrating, we have
−u + 2 ln |1 + u| + ln |x| = ln |c|
y y
− + 2 ln 1 + + ln |x| = ln |c|.
x x
Using the properties of logarithms, we can write the preceding solution as
(x + y)2 y
ln = .
cx x
y
The definition of a logarithm then yields (x + y)2 = cxe x .

0.4 Exact Equations

A differential equation
M (x, y)dx + N (x, y)dy = 0 (1)
is exact if there exists a function g(x, y) such that
dg(x, y) = M (x, y)dx + N (x, y)dy.

Test for Exactness

If M (x, y) and N (x, y) are continuous functions and have continuous first partial derivatives, then
Equation (1) is exact if and only if
∂M (x, y) ∂N (x, y)
= .
∂y ∂x

6
Example 0.4.1. Solve 2xydx + (x2 − 1)dy = 0.

∂M ∂N
Solution: With M (x, y) = 2xy and N (x, y) = x2 −1, we have = 2x = . Thus the equation
∂y ∂x
∂g ∂g
is exact and so there exists a function g(x, y) such that = 2xy and = x2 − 1. From the first
∂x ∂y
of the equations we obtain, after integrating g(x, y) = x2 y + h(y). Taking the partial derivative of
the last expression with respect to y and setting the result equal to N (x, y), gives

∂g
= x2 + h′ (y) = x2 − 1.
∂y

It follows h′ (y) = −1 and h(y) = −y. Hence g(x, y) = x2 y − y, so the solution of the equation is

x2 y − y = c.

Example 0.4.2. Determine whether the differential equation

(x + sin y)dx + (x cos y − 2y)dy = 0

is exact. If it is, solve it.

∂M ∂N
Solution: Here M (x, y) = x + sin y and N (x, y) = x cos y − 2y. Thus = = cos y, and the
∂y ∂x
differential equation is exact.

∂g
We seek a function g(x, y) such that = x + sin y. Integrating both sides of this equation with
∂x
respect to x, we find
Z Z
∂g
dx = (x + sin y)dy
∂x
1 2
g(x, y) = x + x sin y + h(y). (2)
2
∂g
Differentiating Equation (2) with respect to y, yields = x cos y + h′ (y) and we find that
∂y

x cos y + h′ (y) = x cos y − 2y or h′ (y) = −2y

from which it follows that h(y) = −y 2 + c1 . Substituting, we have


1
g(x, y) = x2 + x sin y − y 2 + c1 .
2
The solution of the differential equation is
1 2
x + x sin y − y 2 = c2 where c2 = c − c1 .
2

7
0.4.1 Linear Equations

A first-order linear differential equation has the form

y ′ + p(x)y = q(x). (3)

An integrating factor for Equation (3) is


R
p(x)dx
I(x) = e . (4)
 
′ 4
Example 0.4.3. Solve y + y = x4 .
x
4
Solution: The differential equation has the form of Equation (3), with p(x) = and q(x) = x4
x
and is linear. Here Z Z
4
p(x)dx = dx = 4 ln x = ln x4 ,
x
so Equation (4) becomes
4
R
p(x)dx
I(x) = e = eln x = x4 . (5)
Multiplying the differential equation by the integrating factor defined by (5), we obtain
d 4
x4 y ′ + 4x3 y = x8 or (x y) = x8 .
dx
Integrating both sides with respect to x of the last equation, we obtain
1 c x5
x4 y = x9 + c or y = + .
9 x4 9
dy
Example 0.4.4. Solve x − 4y = x6 ex .
dx

Solution: Dividing by x, we get the standard form


dy 4
− y = x5 ex .
dx x
4
From this we identify, p(x) = − and p(x) = x5 ex . Hence the integrating factor is
x
Z
dx
−4
e x = e−4 ln x = eln x−4 = x−4 .

Multiplying the differential equation by x−4 and rewrite


dy d −4
x−4 − 4x−4 y = xex or (x y) = xex .
dx dx
Integrating by parts we have

x−4 y = xex − ex + c or y = x5 ex − x4 ex + cx4 .

8
dy
Example 0.4.5. Solve + y = x, y(0) = 4.
dx

Solution:
R The equation is in standard form and p(x) = 1 and q(x) = x. The integrating factor
dx x
e = e , so integrating
d x
(e y) = xex
dx
gives
ex y = xex − ex + c or y = x − 1 + ce−x .
From the initial condition we know that y = 4 when x = 0, hence c = 5. Hence the solution is

y = x − 1 + 5e−x .

Example 0.4.6. Find the general solution of the following differential equation
dy
x + (1 + x)y = ex .
dx

Solution: This is a linear differential equation of first order


dy 1 + x ex
+ y= .
dx x x
The integrating factor is given by
1+x
R
dx
e x .
Z Z  
1+x 1
Since dx = + 1 dx = ln x + x, therefore integrating factor is eln x+x = xex . Multi-
x x
d
plying the differential equation with the integrating factor, we have [xex y] = e2x . Integrating we
dx
e2x e2x ce−x
have xyex = + c. Therefore y = + .
2 2x x

9
0.5 Applications of First Order Differential Equations

0.5.1 Growth and Decay Problems

Let N (t) denote the amount of substance (or population) that is either growing or decaying. If
dN
we assume that , the time rate of change of this amount of substance, is proportional to the
dt

10
amount of substance present, then
dN dN
= kN or − kN = 0,
dt dt
where k is the constant of proportionality.

0.5.2 Temperature Problems

Newton’s law of cooling, which is equally applicable to heating, states that the time rate of change
of the temperature of a body is proportional to the temperature difference between the body and its
surrounding medium. Let T denote the temperature of the body and let Tm denote the temperature
dT
of the surrounding medium. Then the time rate of change of the temperature of the body is ,
dt
dT
and Newton’s law of cooling can be formulated as = −k(T − Tm ), or as
dt
dT
+ kT = kTm ,
dt
where k is a positive constant of proportionality.
Example 0.5.1. A body cools in air of constant temperature Tm = 20◦ C. If the temperature of the
body changes from 100◦ C to 60◦ C in 20minutes, determine how much more time it will need for the
temperature to fall to 30◦ C.

Solution: Newton’s Law of Cooling requires that


dT
= −k(T − Tm ).
dt
The general solution is
Z Z
dT
= −k dt + C ⇒ ln |T − Tm | = −kt + ln C ∴ T = Tm + Ce−kt .
T − Tm
At t = 0, T = 100◦ C, then
100 = 20 + Ce−k·0 = 20 + C ⇒ C = 80.
At t = 20min, T = 60◦ C, then
 
−k·20 1 60 − 20
60 = 20 + 80e ⇒ k = − ln = 0.03466.
20 80
Hence  
−0.03466t 1 T − 20
T = 20 + 80e or t=− ln mins.
0.03466 80
When T = 30◦ C,  
1 30 − 20
t=− ln = 60mins.
0.03466 80
Hence, it will need another 60 − 20 = 40minutes for the temperature to fall to 30◦ C.

11
0.5.3 Falling Body Problems

Consider a vertically falling body of mass m that is being influenced only by gravity g and an air
resistance that is proportional to the velocity of the body. Assume that both gravity and mass
remain constant and, for convenience, choose the downward direction as the positive direction. For
the problem at hand, there are two forces acting on the body: the force due to gravity given by the
weight w of the body, which equals mg, and the force due to air resistance given by kv, where k ≥ 0
is a constant of proportionality. The minus sign is required because this force opposes the velocity;
that is, it acts in the upward, or negative, direction. The net force F on the body is, therefore,
dv
F = mg − kv. Substituting in Newton’s Second law, we obtain mg − kv = m or
dt
dv k
+ v = g,
dt m
as the equation of motion for the body.

0.5.4 Electrical Circuits

The basic equation governing the amount of current I (in amperes) in a simple RL circuit consisting
of a resistance R (in ohms), an inductor L (in henries), and an electromotive force (abbreviated
emf) E (in volts) is
dI R E
+ I= .
dt L L
For an RC circuit consisting of a resistance, a capacitance C (in farads), an emf, and no inductance,
the equation governing the amount of electrical charge q (in coulombs) on the capacitor is

dq 1 E
+ q= .
dt RC R

12

You might also like