Tutorial4 Solution PDE MA201 AY2024 25
Tutorial4 Solution PDE MA201 AY2024 25
One Dimensional Wave equation in infinite and semi-infinite string, Fourier Series, Separation of
variables method for Wave equation
11. Find D’Alembert’s solution of one-dimensional wave equation utt = uxx in infinite string with the following initial
conditions:
(a) u(x, 0) = x2 , ut (x, 0) = sin x.
(b) u(x, 0) = sin x, ut (x, 0) = cos x.
(
x if − 2 < x < 2
(c) u(x, 0) = and ut (x, 0) = 0 for x ∈ R.
0 everywhere else,
(
1 if − 1 < x < 2
(d) u(x, 0) = 0 for all x ∈ R and ut (x, 0) = .
0 everywhere else
Ans: Using D’Alembert’s formula, we obtain
Z x+t
1
u(x, t) = ϕ(x − t) + ϕ(x + t) + ψ(s) ds ,
2 x−t
1
where
S1 := {(x, t) : x + t = −1}
S2 := {(x, t) : x − t = 2}
S3 := {(x, t) : x + t = 2}
S4 := {(x, t) : x − t = −1},
and
12. Find the solution of the equation utt = c2 uxx , where x ∈ R and t > 0, given that
( πx
sin , if 0, ≤ x ≤ c
u(x, 0) = c , and ut (x, 0) = 0 ∀ x ∈ R.
0 if x < 0 and x > c
13. Solve the semi-infinite string problem utt = uxx , 0 < x < ∞, t > 0 subject to the boundary condition u(0, t) = 0
for t > 0 and initial conditions u(x, 0) = x2 , ut (x, 0) = 0 for 0 < x < ∞.
Ans : Applying modified D’Alembert’s formula, we obtain
Z x+ct
1 1
[ϕ(x + ct) + ϕ(x − ct)] + ψ(s) ds if x ≥ ct
2 2c Zx−ct
u(x, t) = ct+x ,
1 1
[ϕ(x + ct) − ϕ(ct − x)] − ψ(s) ds if 0 < x < ct
2 2c ct−x
14. Solve the semi-infinite string problem utt = uxx , 0 < x < ∞, t > 0 subject to the boundary condition u(0, t) = 0
for t > 0 and initial conditions u(x, 0) = 0, ut (x, 0) = ex for 0 < x < ∞.
Ans : Same as above. x
e
(et − e−t ) if x ≥ t
u(x, t) = e2t .
(ex − e−x ) if 0 < x < t
2
2
15. Find the Fourier series expansion for the function f (x) as given:
(a) f (x) = ex , −L < x < L.
(
0 if − π < x < 0
(b) f (x) = .
x if 0 < x < π
(c) f (x) is given by the line joining (−π, 0) and (0, 2) in (−π, 0) and given by the line f (x) = 2 in (0, π).
Ans: (a)
∞
a0 X nπx nπx
F S(f (x)) = + an cos + bn sin
2 n=1
L L
where Z L Z L
1 nπx 1 nπx
an = f (x) cos dx ; bn = f (x) sin dx
L −L L L −L L
for n = 1, 2, . . . . Therefore
eL − e−L
a0 =
L
L(−1)n L(−1)n
an = (eL − e−L ) ; bn = (e−L − eL ).
L2 + n2 π 2 L2 + n2 π 2
(b) We have as above Z π
1 π
a0 = f (x) dx =
π −π 2
(−1)n − 1 (−1)n+1
an = ; bn = .
n2 π n
(c) We have
2 (x + π) if − π < x < 0
f (x) = π
2 if 0 < x < π
Therefore as above
2 n 2(−1)n+1
a0 = 3 ; an = [1 − (−1) ] ; b n = .
n2 π 2 nπ
∞
X 1
16. Find the Fourier series of the function f (x) = x2 and using it to evaluate the infinite sum (−1)m+1 .
m=1
m2
Ans : Since f is even, the Fourier series of f will contain only cosine terms. We calculate
2π 2 4
a0 = ; an = (−1)n .
3 n2
Note that by Dirichlet’s theorem for convergence of Fourier series we get
∞
π2 X 4
f (x) = x2 = + 2
(−1)n cos nx.
3 n=1
n
Substituting x = 0 we get
∞
X (−1)n+1 π2
= .
n=1
n2 12
17. For the following functions find the Fourier cosine series and the Fourier sine series on the interval 0 < x < π.
(a) f (x) = x3 .
(b) f (x) = sin x.
∞
X
Ans : (a) Fourier sine series of f is bn sin nx where
n=1
π
2π 2
Z
2 12
bn = f (x) sin(nx) dx = (−1)n+1 + (−1)n 3
π 0 n n
∞
a0 X
Fourier cosine series of f is + an cos nx where
2 n=1
π
π3
Z
2 6 2 12
a0 = ; an = x3 cos(nx) dx = (−1)n π − + 4 .
2 π 0 n2 n2 π n π
3
∞
X
(b) Fourier sine series of f is bn sin nx where
n=1
b1 = 1 ; bn = 0 ∀ n ≥ 2.
∞
a0 X
Therefore, sine series f (x) := sin x. Fourier cosine series of f is + an cos nx where
2 n=1
π
−2
Z
4 2
a0 = , an = sin(x) cos(nx) dx = [(−1)n + 1] .
π π 0 π(n2 − 1)
18. Given the Fourier series for the function f (x) = x4 , −π < x < π as
∞
π 4 X 8(−1)n 2 2
x4 = + (π n − 6) cos nx.
5 n=1
n4
we get
∞ ∞
X (−1)n+1 X (−1)n 2 2
x5 = 2π 4 sin nx + 40 (π n − 6) sin nx.
n=1
n n=1
n5
19. Deduce the Fourier series for the function f (x) = eax , −π < x < π, a a real number. Hence find the values of the
following series:
∞
X (−1)n
(a) .
n=1
a2 + n2
∞
X (−1)n
(b) .
n=−∞
a 2 + n2
Ans: Fourier series of f (x) = eax , −π < x < π is
∞
( )
sinh(πa) 1 X (−1)n
+2 (a cos nx − n sin nx) .
π a n=1
a2 + n2
(−1)n 1
Now, adding the above two series and noting that 2 2
= 2 for n = 0, we get
a +n a
∞
X (−1)n 1 aπ − sinh(aπ)
2 2
= 2+ 2 .
n=−∞
a +n a a sinh(aπ)
4
20. A string is fixed at x = 0 and x = L and lies initially along the x-axis. If it is set in motion by giving all points
∂u
0 < x < L a constant transverse velocity = u0 at t = 0, then find the subsequent motion of the string.
∂t
Ans : The solution of the one-dimensional wave equation
21. A guitar string of length L = 1, is pulled in the middle so that it reaches height h. Assuming the position of the
string initially as (
2hx if 0 < x < 1/2
u(x, 0) =
2h(1 − x) if 1/2 < x < 1
what is the subsequent motion of the string if it is suddenly released?
(
2hx if 0 < x < 1/2
Ans: Here, L = 1, ϕ(x) = , and ψ(x) = 0. So, here the 1D wave equation is given
2h(1 − x) if 1/2 < x < 1
by
utt − c2 uxx = 0 , 0 < x < 1 , t > 0,
with ICs
u(x, 0) = ϕ(x) ; ut (x, 0) = 0 for 0 ≤ x ≤ 1,
and BCs
u(0, t) = 0 ; u(1, t) = 0 for t > 0
So as before Dn = 0 for all n, and
2 L
Z
nπx
Cn = ϕ(x) sin dx
L 0 L
Z 1/2 Z 1
=2 2hx sin nπx dx + 2 2h(1 − x) sin nπx dx
0 1/2
0 if n is even
= 8h(−1)k+1
if n = 2k − 1.
(2k − 1)2 π 2
Therefore,
∞
X
u(x, t) = Cn sin(nπx) cos(nπct)
n=1
∞
8h X (−1)n+1
= sin(2n − 1)πx cos(2n − 1)πct.
π 2 n=1 (2n − 1)2
5
Duhamel’s principle, Separation of variables method, Heat conduction equation, Laplace
equation: Solution using method of separation of variables, Properties of harmonic functions
Ans: To find the solution using Duhamel’s principle, we split the problem into two parts P1 + P2 as follows:
utt = uxx ; 0 < x < 1 , t > 0
P1 = u(x, 0) = x(1 − x) , ut (x, 0) = 0 ; 0 ≤ x ≤ 1 ,
u(0, t) = u(1, t) = 0 ; t > 0
and
utt = uxx + x sin t ; 0 < x < 1 , t > 0
P2 = u(x, 0) = 0 , ut (x, 0) = 0 ; 0 ≤ x ≤ 1 .
u(0, t) = u(1, t) = 0 ; t > 0
where Z L Z L
2 nπx 2 nπx
Cn = ϕ(x) sin dx, Dn = ψ(x) sin dx
L 0 L L 0 L
for n ∈ N. Let u1 (x, t) be a solution of P1 . Here, ϕ(x) := u(x, 0) = x(1 − x) and ψ(x) := ut (x, 0) = 0. Also c = 1
and L = 1.
Therefore, we have Dn = 0 for all n, and
2 L
Z
Cn = x(1 − x) sin nπx dx
L
0
0 if n is even
= 8 .
3 3
if n is odd
n π
Therefore,
∞
8 X 1
u1 (x, t) = sin(2n − 1)πx cos(2n − 1)πt.
π 3 n=1 (2n − 1)3
6
Therefore,
∞
X 2(−1)n+1
U (x, t, s) = sin s sin nπx sin nπct
n=1
n2 π 2
∞
X 2(−1)n+1
=⇒ U (x, t − s, s) = sin s sin nπx sin nπc(t − s).
n=1
n2 π 2
Therefore,
∞
X 2(−1)n+1 sin nπx(sin nπt − nπ sin t)
u2 (x, t) = .
n=1
n2 π 2 1 − n2 π 2
Hence,
u(x, t) = u1 (x, t) + u2 (x, t).
23. A metal bar 100 m long has ends x = 0 and x = 100 kept at 0 degrees. Initially half of the bar is at 60 degrees
while the other half is at 40 degrees. Assuming a thermal diffusivity of 0.16 cgs units and that the surface of the
bar is insulated, find the temperature everywhere in the bar at time t.
Ans: The solution of 1D heat equation
ut = αuxx ; 0 < x < L , t > 0
u(0, t) = 0 = u(L, t) ; t > 0
u(x, 0) = f (x)
is given by
∞
X nπx − αn22π2 t
u(x, t) = Bn sin e L
n=1
L
where
2 L
Z
nπx
Bn = f (x) sin dx.
L 0 L
(
60 ; 0 ≤ x ≤ 50
Here, α = 0.16 and L = 100 and f (x) = . Then
40 ; 50 < x ≤ 100
Z 100
1 nπx 1 h nπ i
Bn = f (x) sin dx = 120 − 40 cos − 80 cos nπ
50 0 L nπ 2
Ans : Let u(x, t) = v(x, t) + h(x). Substituting this into the given problem
subject to
7
and (
2h′′ (x) = 0 ; 0 < x < 1
P2 = .
h(0) = 0 , h(1) = 100
First we solve P2 . We get h(x) = 100x. Now we solve P1 with f (x) = v(x, 0) = x − 100x = −99x. Then
1
198(−1)n
Z
Bn = 2 (−99x) sin nπx dx =
0 nπ
Hence
∞
X (−1)n sin nπx −2n2 π2 t
u(x, t) = v(x, t) + h(x) = 100x + 198 e .
n=1
nπ
4es
Z π
2 if n is odd−
An = xes cos nx dx = n2 π
π 0 0 if n is even
Z π
2
A0 = xes dx = πes .
π 0
Therefore,
∞
4es X cos(2n − 1)x −(2n−1)2 t
v(x, t, s) = πes − e .
π n=1 (2n − 1)2
Hence,
t ∞ 2
cos(2n − 1)x et − e−(2n−1) t
Z X
t
u(x, t) = v(x, t − s, s) ds = π(e − 1) − 4 · .
0 n=1
(2n − 1)2 (2n − 1)2 + 1