Question 1 Solve the following initial-value problem using the method of undetermined
coefficients:
y ′′ − 8 y ′ + 16 y = 32 cos(4x) , y(0) = 1 , y ′(0) = a ∈ R .
Compute a so that the final solution only contains pure exponentials and/or trigonometric
functions. NOTE. The final solution of the ODE should be fully simplified.
Answer.
The ODE is linear (with constant coefficients) and non-homogeneous. Therefore, the
general solution of the non-homogeneous ODE is equal to the general solution of the homo-
geneous ODE plus a particular solution of the non-homogeneous ODE.
The characteristic polynomial of the homogeneous ODE is
x2 − 8x + 16 = (x − 4)2 = 0 ⇒ x = 4 (double.)
The general solution of the homogeneous ODE is given by
y = A e4x + B x e4x .
The particular solution of the non-homogeneous ODE has the form:
y = c cos(4x) + b sin(4x) .
Therefore,
y ′ = −4c sin(4x) + 4b cos(4x) ,
y ′′ = −16c cos(4x) − 16b sin(4x) .
If we substitute these expressions into the non-homogeneous ODE, we get
32 c sin(4x) − 32 b cos(4x) = 32 cos(4x) .
Then, c = 0 and b = −1, so that the particular solution is
y = − sin(4x) .
The general solution of the non-homogeneous ODE is given by
y = A e4x + B x e4x − sin(4x) .
If we impose the initial condition y(0) = A = 1, we get one constant. On the other hand,
y ′ = 4 e4x + 4B x e4x + B e4x − 4 cos(4x) .
Then, y ′(0) = 4 + B − 4 = B = a. Then the sought solution is given by
y = e4x + a x e4x − sin(4x) .
The only term that it is not an exponential nor a trigonometric function is a x e4x . It
vanishes when a = 0, and the solution becomes
y = e4x − sin(4x) .
Question 2 Solve the following initial-value problem
y (3) − 3y ′′ + 3y ′ − y = x , y ′′ (0) = y ′(0) = y(0) = 0 .
using the Laplace-transform method. NOTE. The final solution should be fully simplified.
Answer.
If I apply the Laplace-transform operator on the ODE and use the fact that this is a
linear operator, I obtain
L(y (3) ) − 3 L(y ′′ ) + 3 L(y ′) − L(y) = L(x) .
These Laplace transforms are easy to compute
1
p3 L(y) − 3p2 L(y) + 3p L(y) − L(y) = (1 − p)3 L(y) = .
p2
Then,
1
L(y) = .
p2 (p − 1)3
It is now more efficient to write this rational function for L(y) as a sum of simple fractions.
The result is
3 1 3 2 1
L(y) = − − 2 + − 2
+ .
p p p − 1 (p − 1) (1 − p)3
The inverse Laplace transforms are almost immediate (note that L(x2 ) = 2/p3 ):
x2
x
y(x) = −(3 + x) + e 3 − 2x + .
2
Question 3 Solve the following system of first-order ODE’s
′ 0 1
x = ·x
−4 0
1
with x(0) = . NOTE. The final solution should be fully simplified.
2
Answer.
This system is linear in x (with constant coefficients) and homogeneous.
If we assume that the solution is x = (A, B)T emt (where the superscript T means the
transpose), and introduce this form in that system, we find an eigenvalue problem:
−m 1
= 0.
−4 −m
The solution is simple
m2 + 4 = 0 , ⇒ m = ±2 i .
We now look for the eigenvectors for the corresponding eigenvalues. If m = 2 i, the
system we have to solve is
−2i 1 A 0
· = .
−4 −2i B 0
The solution is v = (1, 2 i)T .
The general solution for m = 2 i is
2it 1 cos(2t) sin(2t)
x = e = +i .
2i −2 sin(2t) 2 cos(2t)
The final solution is
cos(2t) sin(2t)
x = A +B .
−2 sin(2t) 2 cos(2t)
At t = 0, x = (1, 2)T , therefore:
A = 1, B = 1.
Therefore, the final solution is
cos(2t) + sin(2t)
x = .
2 cos(2t) − 2 sin(2t)