You are on page 1of 5

Strauss PDEs 2e: Section 5.

1 - Exercise 9 Page 1 of 5

Exercise 9
Solve utt = c2 uxx for 0 < x < π, with the boundary conditions ux (0, t) = ux (π, t) = 0 and the
initial conditions u(x, 0) = 0, ut (x, 0) = cos2 x. (Hint: See (4.2.7).)

Solution

The PDE and its boundary conditions are linear and homogeneous, so the method of separation
of variables can be applied. Assume a product solution of the form u(x, t) = X(x)T (t) and plug it
into the PDE
utt = c2 uxx → XT 00 = c2 X 00 T
and the boundary conditions.

ux (0, t) = 0 → X 0 (0)T (t) = 0 → X 0 (0) = 0


ux (π, t) = 0 → X 0 (π)T (t) = 0 → X 0 (π) = 0

Now separate variables in the PDE: bring all functions of t and constants to the left side and all
functions of x to the right side. The final answer would be the same if all constants were brought
to the right side.
T 00 X 00
=
c2 T X
The only way a function of t on the left can be equal to a function of x on the right is if both
sides are equal to a constant λ.
T 00 X 00
= =λ
c2 T X
Values of λ for which X 0 (0) = 0 and X 0 (π) = 0 are satisfied are called the eigenvalues, and the
nontrivial functions X(x) associated with them are called the eigenfunctions.

Determination of Positive Eigenvalues: λ = µ2

Assuming λ is positive, the differential equation for X becomes

X 00
= µ2 .
X
Multiply both sides by X.
X 00 = µ2 X
The general solution can be written in terms of hyperbolic sine and hyperbolic cosine.

X(x) = C1 cosh µx + C2 sinh µx

Now use the boundary conditions to determine C1 and C2 .

X 0 (0) = µC2 = 0
X 0 (π) = µ(C1 sinh µπ + C2 cosh µπ) = 0

The first equation tells us that C2 = 0. Consequently, the only way the second equation can be
satisfied is if C1 = 0. Only the trivial solution X(x) = 0 results from considering positive values

www.stemjock.com
Strauss PDEs 2e: Section 5.1 - Exercise 9 Page 2 of 5

for λ, so there are no positive eigenvalues.

Determination of the Zero Eigenvalue: λ = 0

Assuming λ is zero, the differential equation for X becomes

X 00
= 0.
X
Multiply both sides by X.
X 00 = 0
The general solution is a linear function.

X(x) = C3 x + C4

Now use the boundary conditions to determine C3 and C4 .

X 0 (0) = C3 = 0
X 0 (π) = C3 = 0

We see that C4 remains arbitrary. The eigenfunction then is X(x) = C4 , so zero is in fact an
eigenvalue. The ODE for T (t) will now be solved.

T 00
=0
c2 T
Multiply both sides by c2 T .
T 00 = 0
The general solution to this equation is also a linear function.

T (t) = C5 t + C6

Determination of Negative Eigenvalues: λ = −γ 2

Assuming λ is negative, the differential equation for X becomes

X 00
= −γ 2 .
X
Multiply both sides by X.
X 00 = −γ 2 X
The general solution can be written in terms of sine and cosine.

X(x) = C7 cos γx + C8 sin γx

Apply the boundary conditions here to determine C7 and C8 .

X 0 (0) = γC8 = 0
X 0 (π) = γ(−C7 sin γπ + C8 cos γπ) = 0

www.stemjock.com
Strauss PDEs 2e: Section 5.1 - Exercise 9 Page 3 of 5

The first equation gives C8 = 0, so the second equation reduces to

−γC7 sin γπ = 0.

In order to avoid getting the trivial solution, we insist that C7 6= 0. The equation for γ is then

−γ sin γπ = 0

sin γπ = 0
γπ = nπ → γ = n.
The eigenfunctions associated with these eigenvalues are

X(x) = C7 cos γx → Xn (x) = cos nx.

The ODE for T (t) will now be solved.


T 00
= −γ 2
c2 T
Multiply both sides by c2 T .
T 00 = −c2 γ 2 T
The general solution can be written in terms of sine and cosine.

T (t) = C9 cos cγt + C10 sin cγt → Tn (t) = C9 cos cnt + C10 sin cnt

According to the principle of linear superposition, the solution to the PDE for u(x, t) is a linear
combination of all products Tn (t)Xn (x) over all the eigenvalues.

X
u(x, t) = A + Bt + (Dn cos cnt + En sin cnt) cos nx
n=1

Now we will use the provided initial conditions to determine the coefficients, A, B, Dn , and En .

X
u(x, 0) = A + Dn cos nx = 0
n=1

From this equation, we can say that A = 0 and Dn = 0. Take the derivative with respect to t of
the general solution to use the second initial condition.

X
ut (x, t) = B + (−cnDn sin cnt + cnEn cos cnt) cos nx
n=1

Plug in t = 0 and use the second initial condition.



X
ut (x, 0) = B + (cnEn ) cos nx = cos2 x (1)
n=1

To determine B, integrate both sides of equation (1) with respect to x over the domain the PDE
is defined. ˆ π" ˆ π

#
X
B+ (cnEn ) cos nx dx = cos2 x dx
0 n=1 0

www.stemjock.com
Strauss PDEs 2e: Section 5.1 - Exercise 9 Page 4 of 5

Split up the integral on the left side into two and use the trigonometric identity,
cos2 x = 12 (1 + cos 2x), on the right side.
ˆ π ˆ ∞
πX ˆ π
1
B dx + (cnEn ) cos nx dx = (1 + cos 2x) dx
0 0 0 2
n=1

Evaluate the first integral and bring the constants in front of the other integrals.
∞ ˆ π ˆ π
X 1
B·π+ (cnEn ) cos nx dx = (1 + cos 2x) dx
0 2 0
n=1

Evaluate the remaining integrals.


∞ π  π 
X 1 1 1
B·π+ (cnEn ) · sin nx =
π + sin 2x dx
n 2 2
n=1 | {z 0} | {z 0}
=0 =0

1
B · π = (π)
2
Consequently,
1
B= .
2
To determine En , multiply both sides of equation (1) by cos mx, where m is a positive integer.

X
B cos mx + (cnEn ) cos nx cos mx = cos2 x cos mx
n=1

Integrate both sides with respect to x over the domain the PDE is defined.
ˆ π" X∞
# ˆ π
B cos mx + (cnEn ) cos nx cos mx dx = cos2 x cos mx dx
0 n=1 0

Split up the integral on the left side into two and use the trigonometric identity,
cos2 x = 12 (1 + cos 2x), on the right side.
ˆ π ˆ ∞
πX ˆ π
1
B cos mx dx + (cnEn ) cos nx cos mx dx = (1 + cos 2x) cos mx dx
0 0 0 2
n=1

Bring the constants in front of the integrals.


ˆ π ∞ ˆ π ˆ π
X 1
B cos mx dx + (cnEn ) cos nx cos mx dx = (1 + cos 2x) cos mx dx
0 0 2 0
n=1

If n 6= m, then the second integral on the left is equal to 0 thanks to the orthogonality of the
trigonometric functions. This can be verified with the product-to-sum formula for cosine. When
n = m, the integrand becomes cos2 nx, and the result of the integral is π/2.
ˆ π ˆ
π 1 π
B cos nx dx + (cnEn ) · = (1 + cos 2x) cos nx dx
0 2 2 0

www.stemjock.com
Strauss PDEs 2e: Section 5.1 - Exercise 9 Page 5 of 5

Evaluate the integral on the left side and split up the integral on the right side. The first one is
the same as the integral on the left side.
π ˆ π ˆ π 
B π 1
sin nx +(cnEn ) · =
cos nx dx + cos 2x cos nx dx
n 0 2 2 0 0
| {z } | {z }
=0 =0

Multiply both sides by 2 and divide both sides by cnπ to solve for En .
ˆ π
1
En = cos 2x cos nx dx
cnπ 0

As noted before, the integral here is 0 for n 6= 2. Only when n = 2 is the integral nonzero (π/2).

0 n 6= 2
En = 1
 n=2
4c
The general solution for u(x, t) simplifies to
t
u(x, t) = + E2 sin 2ct cos 2x.
2
Therefore,
t 1
u(x, t) = + sin 2ct cos 2x.
2 4c

www.stemjock.com

You might also like