0% found this document useful (0 votes)
61 views

Chapter 1first - Order

1. The document defines ordinary differential equations (ODEs) and provides examples of first-order ODEs. It discusses the order and degree of ODEs. 2. Methods for solving first-order ODEs are presented, including the method of separable variables. Examples of using this method to solve first-order ODEs are shown. 3. The concepts of initial value problems and boundary value problems are introduced.

Uploaded by

Khant Si Thu
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)
61 views

Chapter 1first - Order

1. The document defines ordinary differential equations (ODEs) and provides examples of first-order ODEs. It discusses the order and degree of ODEs. 2. Methods for solving first-order ODEs are presented, including the method of separable variables. Examples of using this method to solve first-order ODEs are shown. 3. The concepts of initial value problems and boundary value problems are introduced.

Uploaded by

Khant Si Thu
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/ 22

Definition of ODE and Examples

Method of separable of variables


Homogeneous Differential Equations
Exact Differential Equation
Integrating factor
Linear first order Differential Equation
Bernoulli’s Equation
Riccatti’s equation
Reduction of Order
Application
Newton’s law of cooling
Mixtures
Electric Circuit

1 — Ordinary Differential Equations of the first order

1.1 Definition of ODE and Examples


Definition 1.1.1 A differential equation is an equation which involves derivatives.

� Example 1.1

dy d2y dy ∂z ∂z dy
a) = 2x + 5 b) x + 6 = −2y c) − x − z = 0 d) x + y = 3
dx dx2 dx ∂x ∂y dx

� 2 �2 � 2 �2 � �4
d3y d y dy d y dy 3 ∂ 2z ∂ 2z
e) + 2 + = cos x f ) + + 9y = x g) + = x2 + y
dx3 dx2 dx dx2 dx ∂ x 2 ∂ y2

A differential equation involving only ordinary derivatives (derivatives of functions of one


variable) is called ordinary differential equation.

� Example 1.2 Examples a, b, d, e, f are an example of ODE. �

If there are two or more independent variables, the derivatives are partial derivatives and the
equations are called a PDE.

� Example 1.3 Examples c,and g are an example of PDE. �

Order of a differential equation


Definition 1.1.2 The order of a differential equation is defined as the order of the highest
derivative which appears in the equation.

� Example 1.4 Examples a, c, d are of order one where as b, f, g are of order two and e is
of order three �
6 Ordinary Differential Equations of the first order
Definition 1.1.3 The degree of a differential equation is the highest power of the highest
derivative in the equation, after the differential equation is expressed as a polynomial of the
dependent variable and its derivatives.

� Example 1.5
(a) y�� − 2xy� + y = ex order 2, degree 1
(b) (y��� )4 + 5(y�� )5 − 2y� + y = x2 + 2 order 3, degree 4
3
(c) (y� ) 2 = y�� + 1.
First let us write the given differential equation as a polynomial of the dependent
variable and its derivatives, that is,
3
(y� ) 2 = y�� + 1 =⇒ (y� )3 = (y�� + 1)2 = (y�� )2 + 2y�� + 1.
Therefore, the degree of the given differential equation is 2.

Definition 1.1.4 A solution of ODE is free from derivatives and which satisfies the given
differential equation.

If a solution of a differential equation is given explicitly as y = f (x) we call it an explicit solution,


otherwise it is of the form h(x, y) = 0 called implicit solution.

� Example 1.6 Show that e2x and e3x are solution of y�� − 5y� + 6y = 0 �

Definition 1.1.5 A differential equation is said to be linear if it is linear in the dependent


variable and its derivatives, and those coefficients are a function of the independent variable.
That is, a differential equation is linear if the independent variable and its derivatives are not
multiplied together, not raised to powers, do not occur as the arguments of functions.
A differential equation which is not linear in some dependent variable is said to be non
linear.

R An nth order differential equation is linear if it can be written of the form


an (x)y(n) + an−1 (x)y(n−1) + · · · + a2 (x)y�� + a1 (x)y� + a0 (x)y = f (x)
where the coefficients ai (x) are function of x alone.

� Example 1.7 For example


Differential equation Linearity
1 y�� + 4xy� + 2y = cosx Is linear, ordinary and order 2
2 y�� + 4yy� + 2y = cosx Is nonlinear (∵ yy� ) �
2
∂ u ∂v
3 + + u + v = sin u Is linear in v and nonlinear in u (∵ sin u).
∂ x2 ∂t
The equation is nonlinear.

Initial value problem and Boundary Value Problem


In application one may be interested to find a solution to a differential equation satisfying certain
defined conditions and such conditions are called initial conditions. If all conditions are given at
one point of independent variable the conditions are called initial conditions and if the conditions
are given at more than one point of the independent variable the conditions are called boundary
conditions.

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.2 Method of separable of variables 7
Definition 1.1.6 An IVP is a problem which seeks to determine a solution to a differential
equation on the unknown functions and its derivatives specified at one value of the independent
variable.

d2y
� Example 1.8 Consider the differential equation = x + 1 subject to the condition
dx2

y(0) = 1, y (0) = 0. So the given problem is an IVP �

Definition 1.1.7 A BVP is a problem which seeks to determine a solution to a differential


equation subject to the boundary conditions on the unknown functions and its derivatives
specified at least at two different values of the independent variable.

� Example 1.9 Consider the differential equation y�� + y = 0 subject to the condition
y(0) = 0, y� ( π2 ) = 1. So the given problem is BVP �

1.2 Method of separable of variables


Definition 1.2.1 A differential equation of the form
dy
g(x) + h(y) =0
dx
is called separabel equation

The solution is obtained by integrating both sides with respaect to x


� �
h(y)dy + g(x)dx = c

is the general solution.

� Example 1.10 Solve the following differential equations by separation of variables

dy x2 dy
1. = 3. = y − y2
dx y dx
dy
dy x2 4. = 1 + y2 − 2x − 2xy2 , y(0) = 0
2. = dx
dx y(1 + x3 )

Solution:
dy x2
1. The ODE = becomes ydy = x2 dx
dx � y �
⇒ ydy = x2 dx
y2 x 3
⇒ = +c
2 �3
2x3
⇒ y= +c
3

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


8 Ordinary Differential Equations of the first order
dy x2 x2
2. The ODE = becomes ydy = dx
dx y(1 + x3 ) 1 + x3
� �
x2
⇒ ydy = dx
1 + x3
y2 1
⇒ = ln(1 + x3 ) + c
2 �3
2
⇒ y= ln(1 + x3 ) + c
3
dy 1
3. The ODE = y − y2 can be written as dy = dx
dx � �
y − y2
1
=⇒ dy = dx (Integrating both side w.r.t. x)
y − y2
� �
1
=⇒ dy = dx
y(1 − y)
� � � �
1 1
=⇒ − dy = dx ( integration by partial fraction)
y y−1
=⇒ ln(y) − ln(y − 1) = x + c
y y
=⇒ ln = x + c =⇒ = ex+c
y−1 y−1
y
=⇒ = Cex (where C = ec )
y−1
Cex
=⇒ y = (y − 1)Cex =⇒ y = x
Ce − 1
dy
4. The ODE can be written as = (1 − 2x) + y2 (1 − 2x)
dx
dy
=⇒ = (1 − 2x)(1 + y2 )
dx
1
=⇒ dy = (1 − 2x)dx
1 + y2
� �
1
=⇒ dy = (1 − 2x)dx ( integration by trignometric substitution let y = tan θ )
1 + y2
=⇒ tan−1 y = x − x2 + c
=⇒ y = tan(x − x2 + c) (The general solution)
From the initial condition y(0) = 0 , we obtain,
y(0) = tan(0 − 0 + c) =⇒ 0 = tan c =⇒ c = tan−1 0 = 0
Thus, the solution of the IVP is
y = tan(x − x2 )

Exercise 1.1 Solve


(a) y� + y2 sin x = 0
(b) y� = ex+y
2y dy 1
(c) 2 = 2
y + 1 dx x
(d) x2 y2 dx − (1 + x2 )dy = 0, y(0) = 1
dy
(e) (e2y − y) cos x = ey sin 2x, y(0) = 0
dx
(f) (xy + 2x + y + 2)dx + (x2 + 2x)dy = 0
dy π
(g) (x cos y + (x2 − 1) sin y = 0, y(0) = 3
dx

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.3 Homogeneous Differential Equations 9

1.3 Homogeneous Differential Equations


Definition 1.3.1 A function f (x, y) is called homogeneous of degree n if f (λ x, λ y) = λ n f (x, y)

� Example 1.11 a f (x, y) = x5 − x2 y3 is homogeneous of degree 5.


b f (x, y) = x3 + sin x cos y is not homogeneous because f (λ x, λ y) �= λ n f (x, y).
y y
c f (x, y) = e x + tan is homogeneous of degree 0.
x

Definition 1.3.2 The differential equation of the form

M(x, y)dx + N(x, y)dy = 0 (1.1)

is said to be homogeneous iff M(x, y) and N(x, y) are homogeneous functions of the same
degree.

Equation (1.1) can be written in the form


dy M(x, y)
= f (x, y) where f (x, y) = −
dx N(x, y)
which is homogeneous of degree 0.
1
⇒ f (λ x, λ y) = λ 0 f (x, y) = f (x, y), set λ =
x
y y
⇒ f (x, y) = f (1, ) = f (1, z), z =
x x
dy dz dz
⇒ y = zx ⇒ = z+x ⇒ z + x = f (1, z)
dx dx dx
xdz dz dx
⇒ = dx ⇒ − = 0 (which is separable)
f (1, z) − z f (1, z) − z x

� Example 1.12 Solve


(y2 + 2xy)dx − x2 dy = 0 �

Solution: Both terms (M(x, y) = y2 + 2xy, & N(x, y) = −x2 ) in the differential equation are
homogeneous of degree 2, so the equation itself is homogeneous. Differentiating the substitution
y = zx gives
dy dz
= z+x ⇒ dy = zdx + xdz
dx dx
dy y2 + 2xy y2 2y
The given differential equation (y2 + 2xy)dx − x2 dy = 0 becomes = = +
dx x2 x2 x
dy
Substituting y = zx and in the differential equation we obtain the variables separable equation,
dx
� �
dz dz dx dz dx
z+x = z2 + 2z ⇒ 2
= ⇒ 2
=
dx z +z x z +z x

dz
⇒ = ln x + ln c ⇒ ln z − ln(z + 1) = ln cx
z(z + 1)
y
z z x y
⇒ ln = ln cx ⇒ = cx ⇒ y ⇒ = cx
z+1 z+1 x +1 x+y

Therefore the general solution of the given differential equation is

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


10 Ordinary Differential Equations of the first order
cx2
y=
1 − cx
where C is an arbitrary constant. In this case the general solution is simple and y is determined
explicitly in terms of x.

� Example 1.13 Solve


y−x
y� = �
y+x

y−x
Solution: Let f (x, y) =
y+x
λy−λx y−x
f (λ x, λ y) = = = λ 0 f (x, y)
λy+λx y+x
Thus, f (x, y) is homogeneous function of degree 0, so the given differential equation itself is
homogeneous. Differentiating the substitution y = zx gives
dy dz
= z+x ⇒ dy = zdx + xdz
dx dx
dy
Substituting y = zx and in the differential equation we obtain ,
dx
dz zx − x dz z − 1 dz z − 1
z+x = =⇒ z+x = =⇒ x = −z
dx zx + x dx z + 1 dx 1 + z
dz −z2 − 1
=⇒ x =
dx z+1
� �
z+1 1 z+1 dx
=⇒ 2
dz = dx =⇒ 2
dz =
−z − 1 x −z − 1 x
� � � �
z 1 dx
=⇒ − 2 − dz =
(z + 1) z2 + 1 x
1
=⇒ − ln(z2 + 1) − tan−1 (z) = ln x + c
2
=⇒ ln(z2 + 1) + 2 tan−1 (z) = −2 ln x +C
�� � � �y�
y 2
=⇒ ln + 1 + 2 tan−1 = −2 ln x +C
x x
� 2 � � �
x + y2 −1 y
=⇒ ln + 2 tan = − ln x2 +C
x2 x
�y�
=⇒ ln(x2 + y2 ) − ln x2 + 2 tan−1 = − ln x2 +C
�y� x
=⇒ ln(x2 + y2 ) + 2 tan−1 =C (implicit solution)
x

Exercise 1.2 Solve

(a) x2 ydx − (x3 + y3 )dy = 0 (d) (y2 − x2 )dx + xydy = 0


(b) xy� = 2x + 3y (e) y2 dx − (x2 + xy)dy = 0
dy y y −1 x x x
(c) = + tan (f) sin dx + 2 sin dy = 0
dx x x y y y y

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.4 Exact Differential Equation 11

1.4 Exact Differential Equation


Definition 1.4.1 A differential equation of the form
M(x, y)dx + N(x, y)dy = 0
∂f ∂f
is said to be exact if there is a function f such that M(x, y) = and N(x, y) =
∂x ∂y

∂f ∂f
⇒ Mdx + Ndy = dx + dy = 0
∂x ∂y
∂ f ∂ f dy d
⇒ + =0 ⇒ f (x, y) = 0
∂x ∂ dx dx
∴ f (x, y) = c is the general solution.

R The partial derivatives of M and N exist and continuous.

Theorem 1.4.1 The differential equation

M(x, y)dx + N(x, y)dy = 0


∂N ∂M
is exact if and only if =
∂x ∂y

Proof. ( =⇒ ) Assume the given differential equation is exact. By definition, there exist a a
differentiable function f (x, y) such that
∂f ∂f
M(x, y) = and N(x, y) =
∂x ∂y
Therefore,
∂M ∂2 f ∂N
= =
∂y ∂ x∂ y ∂x
The equality of the mixed partials is a consequence of the continuity of the first partial derivatives
ofM(x, y) and N(x, y).
∂N ∂M
( ⇐= ) To prove the converse of the theorem, we assume that = . We need to show that
∂x ∂y
there is a function f such that
∂f
M(x, y) = and (1.2)
∂x
∂f
N(x, y) = (1.3)
∂y
Integrating equation (1.2) with respect to x, holding y fixed (this is a partial integration) to obtain

f (x, y) = M(x, y)dx + h(y) (1.4)

where h(y) is an arbitrary function of y (this is the integration "constant" that we must allow to
depend on y, since we held y fixed in performing the integration).
Differentiating (1.4) partially with respect to y yields

∂f ∂ dh
N= = M(x, y)dx +
∂y ∂y dy

dh ∂
= N(x, y) − M(x, y)dx (1.5)
dy ∂y

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


12 Ordinary Differential Equations of the first order
To see that there is such a function of y, it suffices to show that the right-hand side in (1.5) is a
function of y. We can find g(y) by integrating with respect to y. Because the right hand side in
(1.5) is defined on a rectangle, and hence on an interval as a function of x, it suffices to show that
the derivative with respect to x is identically zero. But
� � � �
∂ ∂ ∂N ∂ ∂
N(x, y) − M(x, y)dx = − M(x, y)dx
∂x ∂y ∂x ∂x ∂y

∂N ∂ ∂
= − M(x, y)dx
∂x ∂y ∂x
∂N ∂M
= − =0
∂x ∂y
by hypothesis. so we can find desired function h(y) by integrating eq. (1.5) with respect to y.
� � � �

h(y) = N(x, y) − M(x, y)dx dy
∂y
Substituting this in Eq. (1.4), f (x, y) becomes
� � � � �

f (x, y) = M(x, y)dx + N(x, y) − M(x, y)dx dy (1.6)
∂y
∂f ∂f
as the desired function with = M and =N �
∂x ∂y

� Example 1.14 Test the differential equation


a (9x2 + y − 1)dx − (4y − x)dy = 0
b ey dx + (xey + 2y)dy = 0
for exactness and solve it if it is exact. �

Solution:a) M(x, y) = 9x2 + y − 1, N(x, y) = −(4y − x) = x − 4y


∂N ∂M
⇒ =1=
∂x ∂y
Hence the given differential equation is exact.
By definition there exist a function f of two variables such that
∂f
= 9x2 + y − 1 (1.7)
∂x
∂f
= x − 4y (1.8)
∂y
Integrating equation (1.7) with respect to x we get,

f (x, y) = (9x2 + y − 1)dx

= 3x3 + xy + h(y)
where h(y) is constant with respect to x. Differentiate w.r.t y, we obtain
∂ f (x, y)
= x + h� (y)
∂y
compainge this with equation (1.8), we have
x + h� (y) = x − 4y ⇒ h� (y) = −4y ⇒ h(y) = −2y2
∴ f (x, y) = 3x2 + yx − x − 2y2 = c is the general solution of the given ODE.
b) Ans. f (x, y) = xey + y2 = c

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.4 Exact Differential Equation 13

� �
x+y
� Example 1.15 Solve (x + tan−1 y)dx + dy = 0 �
1 + y2

x+y
Solution: Here we have, M(x, y) = x + tan−1 y, N(x, y) =
1 + y2
∂N 1 ∂M
⇒ = =
∂x 1 + y2 ∂y
Hence the given differential equation is exact.
By definition there exist a function f of two variables such that
∂f
= x + tan−1 y (1.9)
∂x
∂f x+y
= (1.10)
∂y 1 + y2
Integrating equation (1.9) with respect to x we get,

1
f (x, y) = (x + tan−1 y)dx + h(y) = x2 + x tan−1 y + h(y)
2
where h(y) is constant with respect to x. Differentiate w.r.t y, we obtain
∂ f (x, y) x
= + h� (y)
∂y 1 + y2
comparing this with equation (1.10), we get
x x+y y
2
+ h� (y) = 2
=⇒ h� (y) =
1+y 1+y 1 + y2

y 1
=⇒ h(y) = 2
dy = ln(1 + y2 )
1+y 2
1 1
∴ f (x, y) = x2 + x tan−1 y + ln(1 + y2 )
2 2
The general solution of the given ODE is
1 2 1
x + x tan−1 y + ln(1 + y2 ) = c
2 2

Exercise 1.3 Determine which of the following equations are exact and solve it, if it is exact
(a) (ex sin y − 2y sin x)dx + (ex cos y + 2 cos x)dy = 0
(b) (y − x3 )dx + (x + y3 )dy = 0
(c) (sin x sin y − xey )dy = (ey + cos x cos y)dx
y x
(d) dx = 2 2
dx + dy
1−x y 1 − x 2 y2
−1 x x x
(e) sin dx + 2 sin dy = 0
y y y y
(f) (3x2 + y2 )dx + 2xydy = 0
(g) 3x2 ydx + x3 dy = 0
(h) 2x sin ydx + x2 cos ydy = 0
(i) (6xy − y3 )dx + (4y + 3x2 − 3xy2 )dy = 0

Answer: x 4 4 y
� a) e�sin y + 2y cos x = c b) 4xy − x + y = c c) xe + sin x sin y = c
1 + xy x x
d) ln − 2x = c e) cos = c or = c
1 − xy y y

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


14 Ordinary Differential Equations of the first order
1.5 Integrating factor
Definition 1.5.1 Let M(x, y)dx + N(x, y)dy = 0 is not exact, any function µ which makes
µ (M(x, y)dx + N(x, y)dy) = 0 exact is called integrating factor.

� Example 1.16 Show that µ = yex is an integrating factor for the differential equation
� � � �
sin y −x cos y + 2e−x cos x
− 2e sin x dx + dy = 0
y y
and use this fact to find a solution to the differential equation. �

Answer: f (x, y) = ex sin y + 2y cos x

Theorem 1.5.1 A differential equation of the form M(x, y)dx + N(x, y)dy = 0 has an integrat-
ing factor if it has a general solution

Proof. Let f (x, y) = c be the general solution. Then

∂f
df ∂ f ∂ f dy dy
= + =0 ⇒ = − ∂x
dx ∂ x ∂ y dx dx ∂f
∂y
∂f
dy M
⇒ = − = − ∂x
dx N ∂f
∂y
∂f ∂f
∂y
⇒ = ∂ x = µ (let)
N M
∂f ∂f
⇒ = µM and = µN
∂x ∂y
Multipling the given equation by µ

µM(x, y)dx + µN(x, y)dy = 0

which is exact. �

Finding the integrating factor

µM(x, y)dx + µN(x, y)dy = 0


∂ (µN) ∂ (µM)
⇒ =
∂x ∂y
∂N ∂µ ∂M ∂µ
⇒ µ +N =µ +M
∂x ∂x ∂y ∂y
� �
∂µ ∂µ ∂M ∂N
⇒ N −M =µ −
∂x ∂y ∂y ∂x
� �
1 ∂µ ∂µ ∂M ∂N
⇒ N −M = − (1.11)
µ ∂x ∂y ∂y ∂x

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.5 Integrating factor 15

Case 1: Let µ be a function of alone then (1.11) become


� �
1 ∂µ ∂M ∂N
N = −
µ ∂x ∂y ∂x
∂M ∂N

1 ∂µ ∂y ∂x d
⇒ = = g(x) ⇒ (ln µ) = g(x)
µ ∂x N dx
� �
g(x)dx
⇒ ln µ = g(x)dx ⇒ µ = e

Case 2: Similarly if µ is a function of y alone


∂M ∂N

1 ∂µ ∂y ∂x
= = h(y)
µ ∂y −M

h(y)dy
⇒ µ =e

� Example 1.17 Solve (3x2 y + 2xy + y3 )dx + (x2 + y2 )dy = 0 �

Solution: M(x, y) = 3x2 y + 2xy + y3 , N(x, y) = x2 + y2


∂M ∂N
= 3x2 + 2x + 3y2 = 2x
∂y ∂y
The differential equation is not exact
∂M ∂N
− = 3x2 + 2x + 3y2 − 2x = 3(x2 + y2 )
∂y ∂x
∂M ∂N

∂y ∂x x2 + y2
⇒ g(x) = =3 2 =3
N x + y2
� �
g(x)dx 3dx
µ =e =e = e3x
Thus the ODE is reduced in to
e3x (3x2 y + 2xy + y3 )dx + e3x (x2 + y2 )dy = 0
which is exact.
By definition there exist a function f such that
∂f ∂f
= e3x (3x2 y + 2xy + y3 ) and = e3x (x2 + y2 )
∂x ∂y
Integrating the second w.r.t. y,

y3
f (x, y) = e3x (x2 + y2 )dy = e3x (x2 y + + c(x))
3
∂f y3
⇒ = e3x (2xy) + 3e3x (x2 y + ) + c� (x)
∂x 3
= e3x (2xy + 3x2 y + y3 ) + c� (x)
By comparing the above equation, we have c� (x) = 0 ⇒ c(x) = c. Hence
y3
f (x, y) = e3x (x2 y + )=k
3
is the general solution.

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


16 Ordinary Differential Equations of the first order

� Example 1.18 Solve the initial value problem ydx + (2x − yey )dy = 0, y(0) = 1 �

∂M ∂N ∂M ∂N
Solution: M(x, y) = y, N(x, y) = 2x − yey ⇒ = 1, =2 ⇒ �=
∂y ∂x ∂y ∂x
The given differential equation is not exact.
∂M ∂N
− = 1 − 2 = −1
∂y ∂x
∂M ∂N

∂y ∂x −1 1
h(y) = = =
−M y y
� � 1
∴ µ =e h(y)dy
=e y dy = eln y = y
Thus the differential equation is reduced in to
y2 dx + y(2x − yey )dy = 0
which is exact.
By definition there exist a function f such that
∂f ∂f
= y2 and = y(2x − ye2 )
∂x ∂y
Integrating the first w.r.t. x, we get

∂f
f (x, y) = y2 dx = y2 x + g(y) =⇒ = 2xy + g� (y)
∂y
Comparing with the second equation, we have
g� (y) = −y2 ey =⇒ g(y) = ey (2 + 2y − y2 )
=⇒ f (x, y) = xy2 + ey (2 + 2y − y2 )
The general solution is xy2 + ey (2 + 2y − y2 ) = c
From the initial conditions, we get c = 3e and
xy2 + ey (2 + 2y − y2 ) = 3e
is the solution of the IVP.

� Example 1.19 Solve ydx + 3xdy = 0 �

∂M ∂N
Solution: M(x, y) = y, N(x, y) = 3x =⇒ = 1, =3
∂y ∂y
The differential equation is not exact
∂M ∂N
− = 1 − 3 = −2
∂y ∂x
∂M ∂N

∂y ∂x −2
=⇒ g(x) = =
N � 3x
−2
� dx −2 1
µ = e g(x)dx = e 3x = e 3 ln x =
(x)2/3
OR
∂M ∂N

∂y ∂x −2 2
h(y) = = =
−M −y y

2
� dy
µ =e h(y)dy
= e y = e2 ln y = y2

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.5 Integrating factor 17

Hence, for the given differential equation we have two integrating factor. This implies that,
integrating factor is not unique.
Thus the ODE is reduced in to
y
(x)2/3
dx + 3(x)1/3 dy = 0 Or y3 dx + 3xy2 dy = 0
which is exact.
By definition there exist a function f such that

∂f y
= (1.12)
∂x (x)2/3
∂f
= 3(x)1/3 (1.13)
∂y

Integrating equation (1.13) w.r.t. y,



1
f (x, y) = 3(x)1/3 dy = 3yx 3 + h(x)
∂f y
⇒ = + h� (x)
∂x (x) 2/3

By comparing the above equation with (1.12), we have h� (x) = 0 ⇒ h(x) = c. Hence
1
f (x, y) = 3yx 3
Hence, the general solution is given by
1
3yx 3 = c =⇒ xy3 = C

OR y3 dx + 3xy2 dy = 0
By definition there exist a function f such that

∂f
= y3 (1.14)
∂x
∂f
= 3xy2 (1.15)
∂y

Integrating equation (1.14) w.r.t. x,



f (x, y) = y3 dx = xy3 + g(y)
∂f
⇒ = 3y2 + g� (y)
∂y

By comparing the above equation with (1.15), we have g� (y) = 0 ⇒ g(y) = c. Hence
f (x, y) = xy3
Hence, the general solution is given by
xy3 = C

Exercise 1.4 Solve the following differential equation by finding an integrating factor
(a) (3xy + y2 ) + (x2 + xy)y� = 0
(b) (xy − 1)dx + (x2 − xy)dy = 0
2
(c) y� + 2xy = ex−x , y(0) = −1

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


18 Ordinary Differential Equations of the first order
1.6 Linear first order Differential Equation
The standard form of a first order differential equation is
dy
+ p(x)y = q(x) (1.16)
dx
where p(x) and q(x) are any function of x.
⇒ (p(x)y − q(x))dx + dy = 0 (1.17)
⇒ M(x, y) = p(x)y − q(x), N(x, y) = 1
Equation (1.17) is not exact, exactness would require My = Nx
∂M ∂N
− = p(x)
y x
∂M ∂N

y x p(x)
⇒ = = p(x)
N� 1
⇒ µ = e p(x)dx
Multiplying equation (1.16) by µ
� dy � �
e p(x)dx + e p(x)dx p(x) = e p(x)dx q(x)
dx
d � � p(x)dx � � dy � �
⇒ ye = e p(x)dx + e p(x)dx p(x) = e p(x)dx q(x)
dx � dx
� �
p(x)dx p(x)dx
⇒ ye = e q(x)dx + c

�� �

− p(x)dx p(x)dx
∴ y=e e q(x)dx + c (The general solution)

� Example 1.20 Solve the following differential equation


a y� + y cot x = sin x
b y� + 2xy = 4x
c xy� − y = x2 e−x

Solution:
a y� + y cot x = sin x is a linear
� first order differential
� equation with p(x) = cot x&q(x) = sin x
� � �
p(x)dx p(x)dx
y = e− e q(x)dx + c

�� �

− cot xdx cot xdx
= e e sin xdx + c
�� �
− ln sin x ln sin x
= e e sin xdx + c
�� �
1 2
= sin xdx + c
sin x
�� �
1 1 − cos 2x
= dx + c
sin x 2
� � � �
1 1 sin 2x 1 1 2 sin x cos x
= − +c = − +c
sin x 2x 4 sin x 2x 4
x cos x c
= − +
2 sin x 2 sin x

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.7 Bernoulli’s Equation 19
dy
b + 2xy = 4x, p(x) = 2x, q(x) = 4x
dx �� � �

− p(x)dx p(x)dx
y = e e q(x)dx + c

�� � � �� �
− 2xdx 2xdx −x2 x2
= e e 4xdx + c = e e 4xdx + c
2
� 2
� 2
= e−x 2ex + c = 2 + ce−x
1 1
c xy� − y = x2 e−x ⇒ y� − = xe−x , p(x) = − , q(x) = xe−x
x x
� 1 �� � �
− − dx 1
y = e x e − x dx xe−x dx + c
�� � �� �
ln x − ln x −x −x
= e e xe dx + c = x e dx + c

= x[−e−x + c] = −xe−x + cx

1.7 Bernoulli’s Equation


The differential equation
dy
+ p(x)y = q(x)yn (1.18)
dx
where n is any real number, is called Bernoulli’s equation. Note that for n = 0 and n = 1,
equation (1.18) is linear. For n �= 0 and n �= 1 the substitution z = y1−n reduces any equation of
form (1.18) to a linear equation.
dz dy dy yn dz
=⇒ = (1 − n)y−n =⇒ =
dx dx dx (1 − n) dx
Substitute in equation (??), we get
yn dz
=⇒ + p(x)y = q(x)yn
(1 − n) dx
1 dz
=⇒ + p(x)y1−n = q(x) (Divide both sides by yn )
(1 − n) dx
1 dz
=⇒ + p(x)z = q(x)
(1 − n) dx
dz
=⇒ + (1 − n)p(x)z = (1 − n)q(x) ( Linear first order differential equation)
dx
The general solution of the Bernoulli equation is
� � �
y1−n e (1−n)p(x)dx
= (1 − n)q(x)e (1−n)p(x)dx
dx + c

dy
� Example 1.21 Solve x + y = x 2 y2 �
dx

Solution: We first rewrite the equation as


dy 1
+ y = xy2
dx x

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


20 Ordinary Differential Equations of the first order
by dividing by x. With n = 2 we have z = y−1 . We then substitute
dy dz
= −y2
dx dx
into the given equation and simplify. The result is
dz 1 dz 1 −1
−y2 + y = xy2 =⇒ − y = −x
dx x dx x
dz 1 1
=⇒ − z = −x =⇒ P(x) = − , Q(x) = −x
dx x x
Hence,

�� �

− P(x)dx P(x)dx
z = e e Q(x)dx + c

�� � � �� �
− − 1x dx − 1x dx ln x − ln x
= e e (−x)dx + c = e −xe dx + c
� � �
= x − dx + c = x[−x + c] = −x2 + cx

=⇒ y−1 = −x2 + cx
1
=⇒ y = 2
−x + cx

Exercise 1.5 Solve

dy dy 2
(c) y� + xy = xe−x y−3
(a) x + y = x 4 y3 (b) 3y2 + xy3 = x
dx dx

1.8 Riccatti’s equation


A differential equation of the form
dy
+ p(x)y + q(x)y2 = r(x) (1.19)
dx
is a Riccatti differential equation.
• If q(x) = 0, then (1.19) is first order linear differential equation.
• If r(x) = 0, then (1.19) is Bernoulli’s differential equation
Riccati differential equation can be solved if at least one non-trivial particular solution is known.
Suppose that u = u(x) is a solution of (1.19) and make the change of variables y = u + v
to reduce the Riccati equation into Bernoulli equation. Then y� = u� + v� and the differential
equation (1.19) becomes
u� + v� + p(x) (u + v) + q(x) (u + v)2 = r(x)
� �
=⇒ u� + v� + p(x) (u + v) + q(x) u2 + 2uv + v2 = r(x)
=⇒ u� + p(x)u + q(x)u2 + v� + p(x)v + q(x)v2 + 2uvq(x) = r(x)
=⇒ v� + (p(x) + 2q(x)u)v + q(x)v2 = 0 Since u� + p(x)u + q(x)u2 = r(x)
=⇒ v� + (p(x) + 2q(x)u)v = −q(x)v2 (Bernoulli’s differential equation)

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.9 Reduction of Order 21

1 4 2
� Example 1.22 Solve y� + y − y2 = − 2 with u = a given solution. �
x x x

Solution: The given differential equation is Riccati’s differential equation.


2 2
Let y = + v is the general solution. Then y� = − 2 + v� . Substituting into the given
x x
differential equation:
� � � �2
2 � 1 2 2 4
− 2 +v + +v − +v = − 2
x x x x x
2 2 1 4 4 4
− 2 + v� + 2 + v − 2 − v − v2 = − 2
x x x x x x
3
v� − v = v2 Bernoulli equation with n = 2
x
dz dv dv dz
Let z = v−1 . Then, = −v−2 =⇒ = −v2
dx dx dx dx
Substituting:
3 dz 3
v� − v = v2 =⇒ −v2 − v = v2
x dx x
dz 3 1 dz 3
+ = −1 =⇒ + z = −1
dx x v � dx x �
� 3 � � 3
=⇒ z = e− x dx e x dx
(−1)dx + c
� � �
−3 ln x 3 ln x
=⇒ =e − e dx + c
� � � � �
1 1 1 4
=⇒ v−1 = 3 − x3 + c = 3 x +c
x x 4
1 1 c 4
x + c1
=⇒ = x+ 3 =
v 4 x 4x3
4x 3
=⇒ v= 4
x + c1
Therefore, the general solution for the given Riccati equation is
2 4x3
y= + 4
x x + c1

1.9 Reduction of Order


Some differential equation of the second order can be solved by reducing to a first order
differential equation.
The general second order differential equation has the from
F(x, y, y� , y�� ) = 0
To solve we consider two special cases
i Dependent variable missing
f (x, y� , y�� ) = 0
dp
Let y� = p and y�� = . Then
dx
dp
f (x, p, ) = 0 → (reduced to first order ODE in p)
dx

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


22 Ordinary Differential Equations of the first order

� Example 1.23 Solve xy�� − y� = 3x2 �

Solution: The differential equation reduced to


dp dp 1
x − p = 3x2 =⇒ − p = 3x
dx dx x
=⇒ p = y� = 3x2 + c1 x
1
=⇒ y = x3 + c1 x2 + c2
2
ii Independent variable missing
g(y, y� , y�� ) = 0
d p d p dy dp
Let y� = p and y�� = = = p . Then
dx dy dx dy
dp
g(y, p, p ) = 0 → (reduced to first order ODE in p)
dy

� Example 1.24 Solve 2yy�� − (y� )2 = 1 �

Solution: The given differential equation reduced to


dp dp
2yp − p2 = 1 =⇒ 2yp = p2 + 1
dy dy
� �
2p 1 2p 1
=⇒ 2
d p = dy =⇒ 2
d p = dy
p +1 y p +1 y
� dy 1
=⇒ p = c1 y − 1 = =⇒ dx = √ dy
dx c1 y − 1
1 �
=⇒ y = c1 x c1 y − 1 + c
2

� Example 1.25 Solve y�� + k2 y = 0 k is constant �

Solution: The differential equation reduced to


dp
p + k2 y = 0 =⇒ pd p + k2 ydy = 0
dy

=⇒ p2 + k2 y2 = k2 a2 =⇒ p = y� = ±k a2 − y2
dy y
=⇒ � = ±kdx =⇒ sin−1 = ±kx + b
a2 − y2 a
=⇒ y = a sin(±kx + b)
The general solution can be y = c1 sin kx + c2 cos kx ( by expanding sin(kx + B) & changing the
from of constant)

Exercise 1.6 Solve the following


(a) yy�� + (y� )2 = 0 (b) y�� − k2 y = 0 (c) (x2 + 2y� )y�� + 2xy� = 0, y(0) = 1, y� (0) = 0
d xy�� = y� + (y� )3 , (e) yy�� = y2 y� + (y� )2 , y(0) = −1 �
2 , y (0) = 1

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.10 Application 23

1.10 Application
1.10.1 Newton’s law of cooling
According to Newton’s empirical law of cooling, the rate at which the temperature of a body
changes is proportional to the difference between the temperature of the body and the temperature
of the surrounding medium. If T (t) represents the temperature of a body at time t, Tm the
dT
temperature of the surrounding medium, and the rate at which the temperature of the body
dt
changes, then

dT dT
∝ T − Tm or = k(T − Tm )
dt dt
where k is a constant of proportionality.

� Example 1.26 A pot of liquid is put on the stove to boil. The temperature of the liquid
reaches 1700 F and then the pot is taken off the burner and placed on a counter in the kitchen.
The temperature of the air in the kitchen is 760 F. After two minutes the temperature of the
liquid in the pot is 1230 F. How long before the temperature of the liquid in the pot will be
840 F? �

dT
Solution: Tm = 76, = k(T − 76), T (0) = 170.
dt
Solving this separable differential equation, we get
� �
dT dT
= kdt ⇒ = kdt ⇒ ln(T − 76) = kt + c1
T − 76 T − 76
⇒ T − 76 = Cekt ⇒ T (t) = Cekt + 76 ⇒ T (0) = 170 ⇒ C = 170 − 76 = 94
1 1
T (2) = 123 ⇒ 123 = 94e2k + 76 ⇒ 47 = 942k ⇒ k = ln = −0.3466
2 2
∴ T (t) = 94e−0.3466t + 76
⇒ 84 = 94e−0.3466t + 76 ⇒ 8 = 94e−0.3466t ⇒ −0.3466t = −2.4639 ⇒ t = 7.1088

When t = 7.1088 minutes the temperature of the liquid in the pot is 840 F

Exercise 1.7
1. An object with temperature 1500 c is placed in a freezer whose temperature is 300 c
assume that newtons law of cooling applies and that the temperature of the freezer
remains essentially constant. If this object is cooled to 1200 c after 8 minutes, what will
its temperature be after 16 minutes? When will its temperature be 600 c?
2. A thermometer is removed from a room where the temperature is 70o F and is taken
outside, where the air temperature is 10o F. After one-half minute the thermometer
reads 50o F. What is the reading of the thermometer at t = 1 min? How long will it take
for the thermometer to reach 15o F?
3. The rate at which a body loses temperature at any instant is proportional to the amount
by which the temperature of the body exceeds room temperature at the instant. A
container of hot liquid is placed in a room of temperature 190 c and in 8 minutes the
liquid cools from 830 c to 510 c. How long does it takes for the liquid to cool from
270 c to 250 c?

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


24 Ordinary Differential Equations of the first order
1.10.2 Mixtures
Mixing problem occur quite frequently in chemical industry. Mixture problems generally concern
a tank, or reservoir, containing a solution of some substance, being filled at a certain rate with
another solution of the same substance, instantaneously mixed with the solution in the tank, and
at the same time being drained at a certain rate.
The mixing of two salt solutions of differing concentrations gives rise to a first-order differential
equation for the amount of salt contained in the mixture.
Let A(t) denotes the amount of substance in the tank at time t, then the rate at which A(t) changes
is a net rate:
dA
= (input rate of salt) − (output rate of salt) = Rin − Rout
dt
where Rin = (Flow rate of the liquid entering )(Concentration of salt in it)
Rout = (Flow rate of the liquid leaving)(Concentration of salt in it)
A(t)
Concentration of salt in the tank at any time t =
volume of fluid in the tank at any time
But the volume of brine at time t is given by
(initial volume) + (net change in volume)
= (initial volume) + (flow rate entering − flow rate exit)t

� Example 1.27 A large tank holds 300 gallons of brine solution. Salt was entering and
leaving the tank;A concentration of 2 lbs/gal is pumped into the tank at a rate of 3 gal/min;
it mixed with the solution there, and then the mixture was pumped out at the rate of 3 gal/min.
If 50 pounds of salt were dissolved initially in the 300 gallons, how much salt is in the tank
after a long time? �

dA
Solution: = Rin − Rout
dt
� �� �
lbs gal lbs
Rin = 2 3 =6
gal min min
Now, since the solution is being pumped out of the tank at the same rate that it is pumped in, the
number of gallons of brine in the tank at time t is a constant 300 gallons. Hence the concentration
A(t)
of the salt in the tank as well as in the outflow is c(t) =
300 lb/gal
� �� �
A lbs gal A lbs
Rout = 3 =
300 gal min 100 min

dA A
= 6− , A(0) = 50
dt 100
dA A 1
+ = 6, p(t) = , q(t) = 6
dt 100 100

A(t) = 600 + ce−t/100 , A(0) = 50,


⇒ 600 + ce−0/100 = 50 ⇒ c = −550 × 107
Thus the amount of salt in the tank at time t is given by
A(t) = 600 − 550e−t/100
over a long time the number of pounds of salt in the solution must be 600 lb

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


1.10 Application 25

� Example 1.28 A large tank holds 300 gallons of brine solution with 40 lbs of salt. A
concentration of 2 lbs/gal is pumped in at a rate of 4 gal/min. The concentration leaving the
tank is pumped out at a rate of 3 gal/min. How much salt is in the tank after 12 min? �

dA
Solution: = Rin − Rout
dt
� �� �
lbs gal lbs
Rin = 2 4 =8
gal min min
� �� �
A lbs gal 3A lbs
Rout = 3 =
300 + t gal min 300 + t min

dA 3A
= 8− , A(0) = 40
dt 300 + t
dA 3 3
+ A = 8, p(t) = , q(t) = 8
dt 300 + t 300 + t
c
A(t) = 600 + 2t + , A(0) = 40,
(300 + t)3
c
⇒ 600 + = 40 ⇒ c = −1512 × 107
3003
How much salt is in the tank after 12 min?
1512 × 107
A(12) = 600 + 2(10) − ≈ 126.12 lbs of salt
(300 + 12)3

� Example 1.29 In an oil refinery, a storage tank contains 2000 gal of gasoline that initially
has 100 lb of an additive dissolved in it. In preparation for winter weather, gasoline containing
2 lb of additive per gallon is pumped into the tank at a rate of 40 gal/min. The well-mixed
solution is pumped out at a rate of 45 gal/min. How much of the additive is in the tank 20
min after the pumping process begins? �

Solution: Let A be the amount (in pounds) of additive in the tank at time t. We know that
A = 100 when t = 0. The number of gallons of gasoline and additive in solution in the tank at
any time t is
V (t) = 200 + (40 gal/min
� − 45 �gal/min)(t min) = (2000 − 5t) gal
A(t) A(t)
Therefore, Rout = × (Rate out f low) = 45,
� � � V (t) � 2000 − 5t
lb gal lb
Rin = 2 40 = 80
gal min min
The differential equation modeling the mixture process is
dA 45A
= Rin − Rout = 80 −
dt 2000 − 5t
in pounds per minute.
Thus the general solution is
3900
A = 2(2000 − 5t) +C(2000 − 5t)9 , A(0) = 100 ⇒ C = −
(2000)9
⇒ A(20) = 1342 lb

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III


26 Ordinary Differential Equations of the first order

Exercise 1.8 1. Consider a large tank holding 1000 L of pure water into which a brine
solution of salt begins to flow at a constant rate of 6 L/min. The solution inside the
tank is kept well stirred, and is flowing out of the tank at a rate of 6 L/min. If the
concentration of salt in the brine solution entering the tank is 0.1 Kg/L, determine
when the concentration of salt will reach 0.05 Kg/L.
2. Consider a tank in which 1 g of chlorine is initially present in 100m3 of a solution of
water and chlorine. A chlorine solution concentrated at 0.03g/m3 flows into the tank at
a rate of 1m3 /min, while the uniformly mixed solution exits the tank at 2m3 /min. At
what time is the maximum amount of chlorine present in the tank, and how much is
present?

1.10.3 Electric Circuit


A RL-Series circuit: Kirchoff’s second law states that the sum of the voltage, V (t) drop
dI
across the inductor, L( ) and across the resistor RI is the same as the impressed voltage
dt
V (t) in the circuit where I is current.
dI
V (t) = RI + L
dt
B RC-Series circuit: Kirchoff’s second law states that the sum of the voltage, V (t) drop
1
across the capacitor, q(t) and across the resistor RI is the same as the impressed voltage
C
V (t) in the circuit where q is the charge on the capacitor.
1
V (t) = RI + q
c

� Example 1.30 An RL-circuit has an electromotive force of 5 volts, a resistor of 50Ω an


inductance of 1 Henry and no initial current. Find the current in the circuit at any time. �

dI
Solution: V (t) = RI + L , V = 5, R = 50, L = 1
dt
dI 1 1
50I + = 5 ⇒ I(t) = − e−50t
dt 10 10

� Example 1.31 A 100-volt electromotive force is applied to an RC series circuit in which the

resistance is 200 ohms and the capacitance is 10−4 farad. Find the charge q(t) on the capacitor
if q(0) = 0. Find the current i(t). �

1 dq 1
Solution: V (t) = RI + q =⇒ V (t) = R + q ,
c dt c
V = 100, R = 200, C = 10−4
dq 1 dq 1
=⇒ 200 + −4 q = 100 =⇒ + 50q =
dt 10� � dt 2 � �
� �

− 50dt 1 �
50dt −50t 1 50t
=⇒ q = e e dt + c =⇒ q = e e dt + c
2 2
� �
1 50t 1
=⇒ q = e−50t e +c =⇒ q = ce−50t +
100 100
1
From the initial condition, q(0) = 0, we obtain c = − . Thus,
100
1 1 −50t dq 1 −50t
q= − e and I = = e
100 100 dt 2

Zena Sahlemariam @ ASTU, Oct. 2018 Applied Mathematics III

You might also like