Professional Documents
Culture Documents
VARIATION OF PARAMETERS
Consider a second-order linear differential equation
where y1 (x) and y2 (x) are linearly independent solutions of the the corre-
sponding homogeneous equation.
The general solution of the is given by
where
Z Z
y2 (x)f (x) y1 (x)f (x) y1 y2
u1 (x) = − dx, u2 (x) = dx and W (x) = det 0 .
W (x) W (x) y1 y20
e2x
y 00 − 4y 0 + 5y =
sin(x)
3. [8 marks] Solve the initial value problem using the method of unde-
termined coefficients
π π
y 00 − y 0 − 2y = 10 sin(x), y = −3, y 0 = −1.
2 2
x2 y 00 − 2xy 0 + 2y = 5x3 .
1
1. [7 marks] Consider the differential equation
e2x
y 00 − 4y 0 + 5y =
sin(x)
Find the general solution using the method of variation of parame-
ters.
Answer:
Characteristic equation and complementary solution
λ2 − 4λ + 5 = 0
(λ − 2)2 + 1 = 0
λ± = 2 ± i
Complementary solution
Wronskian
y 1 y 2
4x 2 2 4x
2y1 − y2 2y2 − y1 = e (cos(x) + sin(x) ) = e
Integrals
Z
u1 = − 1 dx = −x + c1
Z
cos(x)
u2 = dx = ln | sin(x)| + c2
sin(x)
General solution
y(x) = y1 u1 + y2 u2
= yc − xe2x cos(x) + e2x sin(x) ln | sin(x)|
y
2. [5 marks] Use the substitution v = to find the general solution y(x)
x
to
dy
xy = x2 + 6y 2 .
dx
2
Answer:
Initial set up
y 0 = v + xv 0
Answer:
Characteristic equation and complementary solution
λ2 − λ − 2 = 0
(λ − 2)(λ + 1) = 0, λ1 = 2, λ2 = −1
yc = c1 e2x + c2 e−x
Particular solution
yp = γ1 cos(x) + γ2 sin(x)
substitute into the ODE
−yp − yp0 − 2yp = 10 sin(x)
sin(x) (γ1 − 3γ2 ) + cos(x) (−γ2 − 3γ1 ) = 10 sin(x)
3
γ1 = 1, γ2 = −3
Applying the initial conditions
π
y = c1 eπ + c2 e−π/2 − 3 = −3
2
0 π
y = 2c1 eπ − c2 e−π/2 − 1 = −1
2
leads to c1 , c2 both equal 0.
Solution,
y = cos(x) − 3 sin(x)
4. [7 marks]
Given that y1 = ex is a solution of the differential equation
Solve u0 ODE
00 0 2
u +u =0
x+1
0
(x + 1)2 u0 =0
u = c1 −1(x + 1)−1 + c2
General solution
ex
y = c3 + c2 ex .
x+1
5. [6 marks]
Find the general solution of the differential equation
x2 y 00 − 2xy 0 + 2y = 5x3 .
4
Answer:
Change of variables x = et , y(x) = z(t)
z 00 − 3z 0 + 2z = 5e3t .
In original variables
5
y = Ax + Bx2 + x3 .
2