Você está na página 1de 9

MA1102R CALCULUS

Lesson 22
Wang Fei

matwf@nus.edu.sg

Department of Mathematics
Office: S14-02-09
Tel: 6516-2937

Chapter 8: Ordinary Differential Equations 2


Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Simplest ODE. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
Separation of Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Homogenous Equations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
First Order Linear Equations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

1
Chapter 8: Ordinary Differential Equations 2 / 18

Introduction
• Recall that the derivative of a (differentiable) function determines the change of the function.
dy
More precisely, suppose = f (x) for all x.
dx
Z
◦ Then y = f (x) dx + C .

dy
So if is known, we can determine y up to a constant.
dx
• In general, if there is a relation

dn y
 
dy
F x, y, , . . . , n = 0,
dx dx
known as the ordinary differential equation (ODE), we want to determine the relation of of x and
y explicitly.

3 / 18

The Simplest Ordinary Differential Equations


Z
dy
• = f (x) ⇒ y = f (x) dx + C .
dx
◦ This is exactly the problem of integration.
• Examples.
dy √
◦ = 1 − x.
dx
√ 2
Z
• y = (1 − x) dx = x − x3/2 + C .
3
dy x
◦ =√ .
dx x2 − 1
Z
x √
• y = √ dx = x2 − 1 + C .
x2 − 1
d2 y dy
◦ 2
=0⇒ = C ⇒ y = Cx + D .
dx dx
4 / 18

2
The Simplest Ordinary Differential Equations
1 1
Z
dy dx
• = g(y) ⇒ = ⇒x= dy .
dx dy g(y) g(y)
dy dx 1
◦ = 1 + y2 ⇒ = ∴ y = tan(x − C).
dx dy 1 + y2
1
Z
• x =
2
dy = tan−1 y + C .
1+y
dy dx 1
◦ = ey ⇒ = y ∴ y = − ln(C − x).
dx dy e
Z
• x = e−y dy = −e−y + C .

dy dx
◦ = sec y ⇒ = cos y .
dx dy
Z
• x = cos y dy = sin y + C .

5 / 18

The Simplest Ordinary Differential Equations


dy
• Suppose = y . Find y in terms of x.
dx
1 1
Z
dx
◦ = ⇒x= dy = ln |y| + c. L99 Problem!
dy y y
x−c
• |y| = e . Then y = ±e−c ex = Cex .
However, y may be zero somewhere.
◦ Define z = ye−x . It is well-defined on R.
 
dz dy −x dy
• = e + y(−e−x ) = e−x −y = 0.
dx dx dx
So z = ye−x = C is constant on R, i.e., y = Cex .
• For computation purpose, we still use the non-rigorous method by ignoring the zeros of y .
We omit the detailed explanation of the existence and uniqueness of the solution in our course.

6 / 18

3
Separation of Variables
dy
• Consider a general problem: = f (x)g(y).
dx
f (x)g(y) is a product of a function in x and function in y .
The variables x and y in f (x)g(y) are separable.
1
◦ In differential forms: dy = f (x) dx.
g(y)
1
Z Z
• dy = f (x) dx.
g(y)
1 dy
◦ To be rigorous, = f (x).
g(y) dx
1 dy 1
Z Z Z
• f (x) dx = dx = dy .
g(y) dx g(y)
• This method is called separation of variables.

7 / 18

Examples
√ dy √ 2/3
• 2 xy = 1 (x, y > 0) ∴ y = 3 x + 32 C .
dx
√ 1 2 √
Z Z
◦ 2 y dy = √ dx ⇒ y 3/2 = 2 x + C .
x 3
dy
• sec x = ey+sin x ∴ y = − ln(−C − esin x ).
dx
Z Z
◦ e dy = esin x cos x dx ⇒ −e−y = esin x + C .
−y

dy y
• ln x = ∴ y = ±ec ln x = C ln x.
dx x
1 1
Z Z
◦ dy = dx ⇒ ln |y| = ln | ln x| + c.
y x ln x
8 / 18

4
Singular Solutions
dy √ √ √
• Example. = 3 xy = 3 x · 3 y .
dx
√ 3 3
Z Z
dy
◦ √ = 3
x dx ⇒ y 2/3 = x4/3 + C .
3 y
√ 2 4
◦ Note that 3 y = 0 ⇒ y = 0.
•y = 0 is also a solution to the equation.
dy
• Suppose = f (x)g(y).
dx
◦ If y = C is a solution to g(y) = 0,
dy
then it is a trivial solution to = f (x)g(y).
dx
◦ The trivial solution disappears if the equation is
1 dy
• = f (x).
g(y) dx
◦ We I GNORE these trivial solutions in our course.

9 / 18

Example
dy x+y 1 + xy
• = = . It is NOT separable.
dx x−y 1 − xy
y
◦ Let z = . Then y = zx.
x
dy dz 1+z
• =x +z = .
dx dx 1−z
dz 1+z 1 + z2
◦ x = −z = .
dx 1−z 1−z
1−z 1
Z Z

2
dz = dx.
1+z x
−1 1
• tan z − ln(1 + z 2 ) = ln |x| + C .
2
y 1
∴ tan−1 = ln(x2 + y 2 ) + C .
x 2
10 / 18

5
Homogeneous Equations
dy
• Consider = F (x, y).
dx
◦ Suppose F (x, y) is homogeneous of degree zero.
• i.e., F (tx, ty) = F (x, y) for all t ∈ R.
p
x + y xy + y 2 x2 + y 2
For example: , 2 , , ... .
x − y x + xy |x|
y
◦ Let z = . Then
x
dy dz
• y = xz and = x + z.
dx dx
x y
• F (x, y) = F ( , ) = F (1, z).
x x
◦ The equation becomes
dz
• x + z = F (1, z), which is separable.
dx
11 / 18

Examples
dy dy y
• x = y + 2xe−y/x ⇒ = + 2e−y/x .
dx dx x
y dy dz
◦ Let z = . Then y = xz and =x + z.
x dx dx
dz dz
• x + z = z + 2e−z ⇒ x = 2e−z .
Z dx dx
2
Z
• ez dz = dx ⇒ ez = 2 ln |x| + C .
x
∴ y = x(ln |2 ln |x| + C|).
2 dy 2 dy  y 2 y
• x = y + 2xy ⇒ = +2 .
dx dx x x
y dz
◦ Let z = . We have x + z = z 2 + 2z .
x dx
x2
Z Z
dz dx Exercise
• = ⇒ ··· ⇒ y = .
z(z + 1) x C−x
12 / 18

6
First Order Linear Equations
• The most important type of differential equation is the linear equation. For example,
dy
◦ = f (x)y + g(x).
dx
d2 y dy
◦ 2
+ a(x) = f (x)y + g(x).
dx dx
• How to solve the first order liner differential equation?
dy
◦ + p(x)y = q(x).
dx
Z
dy
• If p(x) = 0: = q(x) ⇒ y = q(x) dx.
dx
dy
• If q(x) = 0: + p(x)y = 0.
Z Z dx  Z 
dy
= p(x) dx, y = ± exp − p(x) dx .
−y
13 / 18

First Order Linear Equations


dy
• We evaluate + p(x)y = 0 rigorously.
dx
◦ Take P (x) such that P ′ (x) = p(x). It is expected:
 Z 
• y = ± exp − p(x) dx = C exp(−P (x)).

◦ Let z = yeP (x) . Then


dz d  dy P (x)
• = yeP (x) = e + yp(x)eP (x)
dx dx dx
 
dy
= + p(x)y eP (x) = 0.
dx
∴ yeP (x) = C , i.e., y = Ce−P (x) .
• eP (x) plays an important role in this integration.
It is called the integrating factor. We can use it to solve the the general case.

14 / 18

7
First Order Linear Equations
dy
• Consider + p(x)y = q(x).
dx
Z
◦ Evaluate P (x) = p(x) dx.
◦ Multiply an integrating factor v(x) = eP (x) :
dy
•eP (x) + eP (x) p(x)y = eP (x) q(x).
dx
d P (x) 
• e y = eP (x) q(x).
dx
◦ Integrate with respect to x:
Z
• e
P (x)
y = eP (x) q(x) dx.

1 1
Z Z
P (x)
∴ y = P (x) e q(x) dx = v(x)q(x) dx.
e v(x)
15 / 18

Examples
dy
• x = x2 + 3y , x > 0.
dx
1. Convert the equation to the standard form:
dy 3
◦ − · y = x.
dx x
2. Find an integrating factor v(x):
−3
Z
◦ dx = −3 ln x + c.
x
◦ Take v(x) = e−3 ln x = x−3 .
3. Solve the equation:
1 1
Z Z
◦ y= v(x)q(x) dx = −3 x−3 · x dx
v(x)  x 
1 −1
Z
= x3 dx = x3 + C = Cx3 − x2 .
x2 x
16 / 18

8
Examples
dy
• + (tan x)y = cos2 x, − π2 < x < π2 .
dx
1. The equation is already in the standard form.
2. Find an integrating factor v(x):
sin x
Z Z
◦ tan x dx = dx = − ln(cos x) + c.
cos x
◦ v(x) = e− ln(cos x) = (cos x)−1 = sec x.

3. Solve the equation:


1
Z
◦ y= sec x · cos2 x dx
sec x Z
= cos x cos x dx = cos x (sin x + C)
1
= sin 2x + C cos x.
2
17 / 18

Examples
dy
• (ey − 2xy) = y2.
dx
◦ It is not linear in y , but it is linear in x.
dx ey − 2xy ey 2x
• = 2
= 2
− .
dy y y y
dx 2 ey
• + · x = 2.
dy y y
◦ Find an integrating factor v(y):
2
Z
• dy = 2 ln |y| + c. v(y) = e2 ln |y| = y 2.
y
◦ Solve the equation:
y
1 1
Z Z
2 e
• x = 2 y · 2 dy = 2 ey dy
y y y
1 y
= 2 (e + C).
y
18 / 18

Você também pode gostar