MATH_316_HW6_RF
MATH_316_HW6_RF
Rhein Ferdous
MATH 316
March 13, 2025
1
ut = uxx , 0 < x < 2, t>0 (1)
4
u(0, t) = 0, u(2, t) = 0, t>0 (2)
πx
u(x, 0) = 2 sin − sin(πx) + 4 sin(2πx), 0 ≤ x ≤ 2. (3)
2
1
We will determine u(x, t) using the method of separation of variables. Consider α2 = 4
and L = 2.
We assume a solution of the form
Divide by α2 X(x)T (t), and equate the equations to a separation constant −λ, we obtain
X ′′ 1 T ′′
= 2 = −λ (8)
X α T
Hence we obtain the following ordinary differential equations X(x) and T (t):
1
X ′′ + λX = 0, (9)
T ′′ + α2 λT = 0. (10)
By substituting from equation (4) for u(x, t) in the boundary equation at x = 0, we find
that X(x), we obtain
If equation (11) is satisfied by choosing T (t) to be zero for all t, then u(x, t) is zero for
all x and t, and we have already rejected this possibility. Therefore, equation (11) must be
satisfied by requiring that
X(x), T (t), and λ by solving equation (30) subject to the boundary and initial conditions.
c2 sin(µL) = 0. (14)
n2 π 2 nπx
λn = , Xn (x) = sin , n = 1, 2, 3... (15)
L2 L
n2 π 2
Turning now equation (10) for T (t) and substituting L2
for λ, we have
n2 π 2 α 2
T′ + T =0 (16)
L2
2 2
Thus, T (t) is proportional to e− nLπ2 . Hence, multiplying solutions of equations (9) and
(10) together, we conclude that the functions
∞
X n2 π 2 nπx
un (x, t) = e− 2 sin , n = 1, 2, 3, ... (17)
n=1
L L
2
or, with values for α and L substituted:
∞ nπx
n2 π 2
X
un (x, t) = e− 4 sin , n = 1, 2, 3, ... (18)
n=1
2
satisfy the partial differential equation (1) and the boundary conditions (2) for each pos-
itive integer value of n.
πx
u(x, 0) = 2 sin − sin(πx) + 4 sin(2πx), 0 ≤ x ≤ 2. (20)
2
We assume that
∞ ∞ nπx
X X nπat
u(x, t) = cn un (x, t) = cn sin cos (21)
n=1 n=1
L L
where the coefficients cn are as yet undetermined. The individual terms in the series
(21) satisfy the differential equation (1) and boundary conditions (2). We will assume that
the infinite series of equation (21) converges and also satisfies the equations (1) and (2). To
satisfy the initial condition (3), we must have
∞
X nπx
u(x, 0) = cn sin = f (x) (22)
n=1
L
Z L Z L
1 nπx 2 nπx
cn = f (x) sin dx = f (x) sin dx, n = 1, 2, 3... (23)
L −L L L 0 L
Z L
2 πx nπx
cn = 2 sin − sin(πx) + 4 sin(2πx) sin dx, n = 1, 2, 3... (24)
L 0 2 L
Substituting L = 2, we get
3
Z 2 πx nπx
cn = 2 sin − sin(πx) + 4 sin(2πx) sin dx, n = 1, 2, 3... (25)
0 2 2
So the final solution is:
∞ ∞ nπx
X X nπat
u(x, t) = cn un (x, t) = cn sin cos , n = 1, 2, 3, ... (26)
n=1 n=1
2 2
4
Problem 2.1. The problem is stated as follows:
It follows that
X ′′ T
= = −λ (31)
X T
Thus, we obtain again the two ordinary differential equations
For any value of λ, a product of solutions of equations (30) and (31) is a solution of the
partial differential equation (25). However, we are interested only in those solutions that
also satisfy the boundary conditions (26).
If we substitute u(x, t) from equation (28) in the boundary condition at x = 0, we obtain
X ′ (0)T (t) = 0. We cannot permit T (t) to be zero for all t, since then u(x, t) would be zero
for all t. Hence we must have
X ′ (0) = 0 (34)
Proceeding in the same way with the boundary condition at x =, we find that
X ′ (L) = 0 (35)
Thus we wish to solve equation (30) subject to the boundary conditions (32) and (33).
It is possible to show that nontrivial solutions of this problem can exist only if λ is real. We
will assume that λ is real and will consider the three cases λ < 0, λ > 0, and λ = 0.
Case 1: If λ < 0, we let λ = −µ2 , where µ is real and positive, so that equation (30)
becomes X ′′ − µ2 X = 0. Its general solution is
5
In this case, the boundary conditions can only be satisfied by choosing k1 = k2 = 0.
Since this forces the solution to be the trivial solution u(x, t) = 0, it follows that λ cannot
be negative.
Case 2: If λ = 0, then equation (30) is X ′′ = 0, and therefore
X(x) = k1 x + k2 (37)
The boundary conditions (32) and (33) require that k1 = 0, but do not determine k2 .
Thus λ = 0 is an eigenvalue, corresponding to the eigenfunction X(x) = 1. For λ = 0, it
follows from equation (31) that T (t) is also constant, which can be combined with k2 , Hence,
for λ = 0, we obtain the constant solution u0 (x, t) = 1.
Case 3: Finally, if λ > 0, let λ = µ2 , where µ is real and positive. Then equation (30)
X ′′ + µ2 X = 0, and consequently,
The boundary condition (32) requires that k1 = 0, and the boundary condition (33)
requires that µ = nπ L
dor n = 1, 2, 3, ..., but leaves k2 arbitrary. Thus the problem (30),
2 2
(31), and (32) has infinite sequence of positive eigenvalues λn = nLπ2 with the corresponding
eigenfunctions Xn (x) = cos(nπx/L). For the eigenvalue λn , the solution Tn (t) of equation
2 2 2
(31) is proportional to e−n π t/L .
Combining these results, we have the following fundamental solutions for the problem
(25), (26), and (27):
u0 (x, t) = 1, (39)
nπx
−n2 π 2 t/L2
un (x, t) = e cos , n = 1, 2, 3, .. (40)
L
To satisfy the initial condition and assuming that this solution works for an infinite linear
combinations of fundamental solutions, we assume that u(x, t) has the form
∞
c0 X
u(x, t) = u0 (x, t) + cn un (x, t) (41)
2 n=1
∞
c0 X 2 2 2
nπx
= u0 (x, t) + cn e−n π t/L cos . (42)
2 n=1
L
∞
c0 X nπx
u(x, 0) = + cn cos = f (x) (43)
2 n=1
L
Thus the unknown coefficients in equation (41) must be the coefficients in the Fourier
cosine series of period 2L for f . Hence
6
Z L
2 nπx
cn = f (x) cos( )dx, n = 0, 1, 2, 3, ... (44)
L 0 L
Substituting f (x):
Z L
2 nπx
cn = x(1 − x) cos( )dx, n = 0, 1, 2, 3, ... (45)
L 0 L
Substituting L = 1:
Z 1
cn = 2 x(1 − x) cos(nπx)dx, n = 0, 1, 2, 3, ... = (46)
0
∞
c0 X 2 2
u(x, t) = u0 (x, t) + cn e−n π t cos (nπx). (47)
2 n=1