MAT 142 - COLLEGE MATHEMATICS - Heat, Wave, and
Laplace Equations Practice Material - Set 4
1. Find the general solution to the heat equation
ut=kuxx,0< x < L, t > 0,
subject to the initial condition
u(x, 0) = f(x) = {0if 0≤x < a
x−aif a≤x≤L
and the boundary conditions
u(0, t) = u(L, t) = 0,
where k > 0is a constant representing the thermal diffusivity.
Ans. Solution:
1. We assume u(x, t) = X(x)T(t)and substitute into the heat equation to get
X(x)T′(t) = kX′′(x)T(t).
Dividing by kX(x)T(t)gives
T′(t)
kT (t)=X′′(x)
X(x)=−λ,
where λis a separation constant.
2. Solving the ODE for X(x)gives X(x) = c1cos(√λx)+c2sin(√λx). Applying the
boundary conditions u(0, t) = u(L, t) = 0 leads to λ=(nπ
L)2for n= 1,2,3, . . .. There-
fore, we have Xn(x) = Bnsin (nπx
L), where Bnare constants to be determined.
3. Solving the ODE for T(t) gives T(t) = Ae−kλt. Thus, the general solution is
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)e−k(nπ
L)2t.
4. To determine Bn, we apply the initial condition. Noting that the initial condition has odd
symmetry, we have
Bn=2
L∫L
a
(x−a)sin (nπx
L)dx.
5. After solving the integral, we find
Bn={2(−1)n
n2π2if nis odd,
0if nis even.
Therefore, the final solution is
u(x, t) = ∞
∑
n=1
nodd
2(−1)n
n2π2sin (nπx
L)e−k(nπ
L)2t.
2. Find the general solution to the heat equation
ut=c2uxx
subject to the boundary conditions
u(0, t) = u(L, t) = 0
and the initial condition
u(x, 0) = 4 sin (πx
L)
Ans. Solution:
We will solve the heat equation using the method of separation of variables.
1. Separation of Variables:
Let’s assume the solution can be written in the form
u(x, t) = X(x)T(t)
Substitute this form into the heat equation
ut=c2uxx
to get
XT ′=c2X′′T
Dividing by c2XT , we get
T′
c2T=X′′
X=−λ
where λis a constant.
Thus, we obtain two ordinary differential equations:
T′+c2λT = 0
X′′ +λX = 0
2. Solving the Time Component:
The time component differential equation has the solution
T(t) = Acos(c√λt)+Bsin(c√λt)
where Aand Bare constants.
3. Solving the Spatial Component:
The spatial component differential equation has the solution
X(x) = Ccos(√λx)+Dsin(√λx)
Applying the boundary conditions u(0, t) = u(L, t) = 0 gives us
X(0) = C= 0
X(L) = Dsin(√λL)= 0
For non-trivial solutions, we must have
sin(√λL)= 0
which implies √λL =nπ
for integer n.
Thus, λ=(nπ
L)2and
Xn(x) = Dnsin (nπx
L)
4. General Solution:
The general solution is given by the linear combination of the separated solutions:
u(x, t) = ∞
∑
n=1
Tn(t)Xn(x) = ∞
∑
n=1 (Ancos (cnπt
L)+Bnsin (cnπt
L))Dnsin (nπx
L)
where An,Bn, and Dnare constants to be determined by the initial condition.
5. Applying the Initial Condition:
Applying the initial condition u(x, 0) = 4 sin (πx
L), we have
u(x, 0) = ∞
∑
n=1
BnDnsin (nπx
L)= 4 sin (πx
L)
Thus, we have B1D1= 4 and BnDn= 0 for n= 1.
Therefore, the general solution to the heat equation satisfying the given boundary and initial
conditions is
u(x, t) = 4 sin (πx
L)e−c2π2t/L2
3. Find the general solution to the heat equation
ut= 4uxx
subject to the boundary conditions
u(0, t) = 0 and u(π, t) = 0
and the initial condition
u(x, 0) = x(π−x)
where 0< x < π and t > 0.
Ans. Solution: 1. First, we assume a separation of variables of the form u(x, t) = X(x)T(t)
and substitute it into the heat equation to obtain
T′(t)
4T(t)=X′′(x)
X(x)=−λ
Solving the ODE for T(t)gives
T(t) = c1e−4λt
and solving for X(x)gives
X′′(x) + λX(x) = 0
2. The boundary conditions u(0, t) = 0 and u(π, t) = 0 imply that X(0) = X(π) = 0. The
general solution to the ODE is
X(x) = c2sin(√λx)+c3cos(√λx)
Applying the boundary conditions gives
X(0) = 0 =⇒c3= 0
and
X(π) = 0 =⇒sin(√λπ)= 0 =⇒λ=n2, n ∈Z+
So, X(x)simplifies to
Xn(x) = cnsin(nx), n ∈Z+
3. Now we can rewrite the general solution as
u(x, t) = ∞
∑
n=1
Tn(t)Xn(x)
where
Tn(t) = cne−4n2t
Therefore, the general solution to the heat equation with the given boundary conditions and
initial condition is
u(x, t) = ∞
∑
n=1
cne−4n2tsin(nx)
where the coefficients cnneed to be determined based on the initial condition.
4. Question:
Consider the Heat Equation in one dimension given by ∂u
∂t =k∂2u
∂x2, where u(x, t)denotes the
temperature distribution at position xand time t, and kis a constant thermal diffusivity.
Given the initial condition u(x, 0) = 2xfor 0≤x≤π, and boundary conditions u(0, t) =
u(π, t) = 0 for t > 0, find the solution u(x, t).
Ans. Step-by-step solution:
1. We start by assuming a separation of variables solution of the form u(x, t) = X(x)T(t).
Substituting this into the Heat Equation, we get:
T′(t)
kT (t)=X′′(x)
X(x)=−λ2
2. Solving the time part of the equation gives T(t) = ce−λ2kt, where cis a constant.
3. Now we solve the spatial part X′′(x) + λ2X(x)=0subject to the boundary conditions
X(0) = 0 and X(π) = 0. The general solution is:
X(x) = Asin(λx)
4. Applying the boundary conditions gives us λ=nfor n= 1,2,3, ..., with the corresponding
eigenfunctions Xn(x) = sin(nx).
5. Therefore, the general solution u(x, t)can be expressed as:
u(x, t) = ∞
∑
n=1
Bne−n2kt sin(nx)
6. To find the coefficients Bn, we apply the initial condition u(x, 0) = 2x:
2x=∞
∑
n=1
Bnsin(nx)
7. By using the orthogonality of sine functions, we can determine that Bn=2
nπ .
8. Therefore, the final solution to the Heat Equation with the given initial and boundary
conditions is:
u(x, t) = ∞
∑
n=1
2
nπ e−n2kt sin(nx)
5. Question: Consider the following Heat Equation on the interval 0< x < π:
ut=uxx, u(0, t) = u(π, t) = 0, u(x, 0) = 2 sin(2x).
Find the solution u(x, t)to the Heat Equation using Separation of Variables.
Ans. Solution:
We seek a solution of the form u(x, t) = X(x)T(t). Substituting this into the Heat Equation,
we have:
X(x)T′(t) = X′′(x)T(t)
1. Solving the spatial part:
After separation, we get:
T′(t)
T(t)=X′′(x)
X(x)=−λ
where λis a separation constant.
Solving the ODE for X(x), we have:
X′′(x) + λX(x) = 0
with boundary conditions X(0) = X(π) = 0.
The general solution to the ODE is X(x) = c1sin(√λx)+c2cos(√λx).
Applying the boundary conditions, we find that λ=n2for n= 1,2,3, . . ., and Xn(x) =
sin(nx).
2. Solving the temporal part:
Now, we consider the ODE for T(t):
T′(t) + n2T(t) = 0
with initial condition T(0) = 2.
The solution to this ODE is Tn(t) = 2e−n2t.
3. Finding the solution:
Putting it all together, the solution u(x, t)is given by:
u(x, t) = ∞
∑
n=1
Xn(x)Tn(t) = ∞
∑
n=1
2sin(nx)e−n2t
u(x, t) = 2 ∞
∑
n=1
sin(nx)e−n2t
Therefore, the solution to the Heat Equation using Separation of Variables is u(x, t) =
2∑∞
n=1 sin(nx)e−n2t.
6. Question: Consider the following Heat Equation defined on a semi-infinite rod (x > 0,t > 0)
with initial condition u(x, 0) = 2xand boundary condition u(0, t) = 1. Solve the Heat Equation
subject to these conditions, i.e., find u(x, t).
Ans. Step-by-step solution: 1. The general form of the Heat Equation on a rod of length Lis
given by:
∂u
∂t =k∂2u
∂x2
where kis the thermal conductivity.
2. We are given the initial condition u(x, 0) = 2xwhich means the rod’s temperature
distribution at t= 0 is 2x.
3. We are also given the boundary condition u(0, t) = 1, which means the temperature at
x= 0 is always 1.
4. Let’s denote u(x, t)as a function of xand t. Given the initial condition, we have
u(x, 0) = 2x, which implies that for t= 0:u(x, 0) = 2x.
5. To solve the Heat Equation subject to the given conditions, we first need to find the
general solution of the Heat Equation:
u(x, t) = ∞
∑
n=1
Bne−(nπ
L)2kt sin (nπx
L)
6. Subsequently, we need to find the specific solution that satisfies the initial and boundary
conditions. From the initial condition u(x, 0) = 2x, we have:
∞
∑
n=1
Bnsin (nπx
L)= 2x
7. Now, we apply the Fourier sine series expansion on the RHS (2x) to solve for the coefficients
Bn.
8. Once we find the coefficients Bn, we finally substitute them back into the general solution
u(x, t)to get the solution.
The solution to the Heat Equation subject to the given initial and boundary conditions would
be quite involved, but the above steps outline the general approach to solve it.
7. Find the solution to the wave equation utt = 4uxx subject to the boundary conditions
u(0, t) = u(π, t) = 0 and the initial conditions u(x, 0) = sin(x)and ut(x, 0) = 2 sin(x).
Ans. Solution: 1. To solve the wave equation, we first assume a solution of the form
u(x, t) = X(x)T(t). 2. Substituting this into the wave equation, we get T′′
T= 4X′′
X. 3.
Rearranging terms gives us T′′
T= 4X′′
X=−λ2, where λis a constant. 4. Solving T′′+λ2T= 0 for
T(t)gives us T(t) = acos(2t)+bsin(2t), where aand bare constants. 5. Solving X′′+λ2X= 0
for X(x)gives us X(x) = ccos(2x) + dsin(2x), where cand dare constants. 6. Applying the
boundary conditions u(0, t)=0and u(π, t)=0gives us X(0)T(t)=0and X(π)T(t)=0. 7.
The boundary conditions imply that X(0) = X(π) = 0, which means ccos(0) + dsin(0) = 0 and
ccos(2π) + dsin(2π) = 0. 8. Solving the boundary conditions gives us c= 0 and dsin(2π) = 0.
Since d= 0, it follows that sin(2π)=0, which implies d= 0. 9. Therefore, the only solution
that satisfies the boundary conditions u(x, t) = 0 is the trivial solution u(x, t) = 0. 10. Finally,
the solution to the wave equation utt = 4uxx subject to the given boundary and initial conditions
is u(x, t) = 0.
8. Question: Consider the wave equation in one dimension, given by ∂2u
∂t2=c2∂2u
∂x2, where cis a
constant velocity. Solve the wave equation subject to the initial conditions u(x, 0) = sin(x)and
∂u
∂t (x, 0) = 0. Additionally, the boundary conditions are u(0, t) = u(π, t) = 0 for all t≥0.
Ans. Solution: We first apply separation of variables to solve the wave equation. Let u(x, t) =
X(x)T(t). Substituting this into the wave equation, we have:
1. T′′ (t)
c2T(t)=X′′ (x)
X(x)=−λ
Let’s solve the time equation first: T′′ (t)
c2T(t)=−λ=⇒T′′(t) + c2λT (t) = 0.
The general solution to this ordinary differential equation is T(t) = Acos(ct√λ)+Bsin(ct√λ).
Now let’s solve the spatial equation: X′′(x) + λX(x) = 0.
2. Applying the boundary conditions, we have X(0) = X(π) = 0.
This results in a discrete set of solutions:
3. For λ=n2where nis a positive integer, the eigenfunctions are Xn(x) = sin(nx).
Thus, the general solution to the PDE is:
4. u(x, t) = ∑∞
n=1(Ancos(ctn) + Bnsin(ctn)) sin(nx).
To find the coefficients, we impose the initial conditions:
5. u(x, 0) = sin(x) = ∑∞
n=1 Ansin(nx). We recognize this as the Fourier sine series for the
function f(x) = sin(x):An=2
π∫π
0sin(x)sin(nx)dx =2
π∫π
0sin(x)sin(nx)dx
Solving this integral we get An=2((−1)n−1)
π(n2−1) for n= 1 and A1= 0.
6. Therefore, the solution to the wave equation with the given initial conditions and boundary
conditions is: u(x, t) = ∑∞
n=1
2((−1)n−1)
π(n2−1) sin(nx)cos(cnt).
9. Question: Consider the heat equation in one dimension given by ∂u
∂t =k∂2u
∂x2, where kis a
positive constant. Solve the following initial-boundary value problem for u(x, t)subject to the
conditions:
PDE:∂u
∂t =k∂2u
∂x2
Initial condition:u(x, 0) = x(1 −x)
Boundary conditions:u(0, t) = u(1, t) = 0
Ans. Solution: We will use the method of separation of variables to solve the heat equation
with these initial and boundary conditions:
1. Separation of Variables:
Assume the solution has the form u(x, t) = X(x)T(t), where X(x)is a function of xonly
and T(t)is a function of tonly. Substitute this into the partial differential equation to get:
X(x)T′(t) = kX′′(x)T(t)
Divide both sides by kX(x)T(t)to separate variables:
T′(t)
kT (t)=X′′(x)
X(x)=−λ
This gives us two ordinary differential equations (ODEs):
T′(t) + kλT (t) = 0 and X′′(x) + λX(x) = 0
2. Solve the Time ODE:
The solution to the time ODE is of the form T(t) = Ae−λkt, where Ais a constant.
3. Solve the Space ODE:
The space ODE is a standard second-order homogeneous ODE with solutions depending on
the sign of λ:
For λ > 0, the general solution is X(x) = Bcos(√λx)+Csin(√λx).
For λ= 0, the general solution is X(x) = Bx +C.
For λ < 0, the general solution is X(x) = Be√−λx +Ce−√−λx.
4. Apply Boundary Conditions:
Since the boundary conditions are u(0, t) = 0 and u(1, t) = 0, we use the conditions X(0) =
X(1) = 0 to find the values of λand X(x).
For X(0) = 0, we have X(0) = B= 0.
For X(1) = 0, we have Csin(√λ)= 0. This gives us the condition λ=n2π2where nis a
positive integer.
5. Find the Eigenfunctions and Eigenvalues:
The eigenfunctions are Xn(x) = Cnsin(nπx)where nis a positive integer.
The corresponding eigenvalues are λn=n2π2.
6. Find the Solution:
The solution to the heat equation is the sum of the separated solutions:
u(x, t) = ∞
∑
n=1
Tn(t)Xn(x) = ∞
∑
n=1 (Ane−kλnt)Cnsin(nπx)
Applying the initial condition u(x, 0) = x(1 −x), we find the coefficients Anusing the
orthogonality of the eigenfunctions.
7. Final Solution:
The final solution to the initial-boundary value problem is given by:
u(x, t) = ∞
∑
n=1
e−k(nπ)2tbnsin(nπx)
where bnare the coefficients found using the initial condition.
10. Question: Consider the one-dimensional heat equation ∂u
∂t =k∂2u
∂x2on the interval 0< x < L,
subject to the boundary conditions u(0, t) = u(L, t) = 0, and the initial condition u(x, 0) = f(x).
Given that the initial condition is f(x) = x(L−x), find the solution u(x, t)using the method
of separation of variables.
Ans. Solution:
We assume the solution can be written as a product of functions u(x, t) = X(x)T(t), and
substitute this into the heat equation to obtain:
T′(t)
kT (t)=X′′(x)
X(x)=−λ2
This gives two ordinary differential equations:
T′(t) + kλ2T(t) = 0 and X′′(x) + λ2X(x) = 0
Solving the equation for T(t)gives T(t) = Aexp(−kλ2t).
For the spatial part, we have:
X′′(x) + λ2X(x) = 0 ⇒X(x) = Bcos(λx) + Csin(λx)
Applying the boundary conditions u(0, t) = u(L, t) = 0 gives X(x) = Csin (nπx
L).
Therefore, the solution can be expressed as:
u(x, t) = ∞
∑
n=1
cnsin (nπx
L)e−k(nπ
L)2t
To find the coefficients cn, we use the initial condition u(x, 0) = x(L−x):
f(x) = x(L−x) = ∞
∑
n=1
cnsin (nπx
L)
Multiplying both sides by sin (mπx
L)and integrating from 0to L, we get:
cm=2
L∫L
0
x(L−x)sin (mπx
L)dx
Evaluating this integral gives the final solution.
11. Question:
Consider the following heat equation on a rod of length L:
∂u
∂t =k∂2u
∂x2,0< x < L, t > 0
subject to the boundary conditions u(0, t)=0,u(L, t)=0for t > 0, and the initial condition
u(x, 0) = f(x), where
f(x) = {2xfor 0≤x < L
2
2(L−x)for L
2≤x≤L
Find the solution u(x, t)to this heat equation.
12. Find the solution to the heat equation on the interval 0<x<π, subject to the boundary
conditions u(0, t) = u(π, t) = 0, and the initial condition u(x, 0) = x(π−x).
Ans. Let’s denote the solution to the heat equation as u(x, t). To solve the problem, we will
use the method of separation of variables.
1. Separation of Variables: Assume the solution can be written as a product of functions
of xand t:u(x, t) = X(x)T(t).
Substitute u(x, t) = X(x)T(t)into the heat equation:
X(x)T′(t) = kX′′(x)T(t)
T′(t)
kT (t)=X′′(x)
X(x)=−λ
where λis a separation constant.
2. Solving the Time Component: From T′(t)
kT (t)=−λ, we have T′(t) + kλT (t) = 0. This
gives the exponential solution T(t) = Ce−kλt.
3. Solving the Space Component: From X′′ (x)
X(x)=−λ, we have X′′(x) + λX(x) = 0 with
boundary conditions X(0) = X(π) = 0.
The general solution to this ODE is X(x) = Csin(√λx). Applying the boundary conditions:
X(0) = 0 ⇒Csin(0) = 0 ⇒C= 0 (This is not interesting) X(π)=0⇒Csin(√λπ)= 0
For non-trivial solutions, we must have √λπ =nπ where n= 1,2,3, .... So, λ=n2.
4. Final Solution: The solution to the heat equation is then given by the sum of the infinite
series:
u(x, t) = ∞
∑
n=1
Cne−kλntsin(nx)
where Cnare coefficients that can be found using the initial condition.
Applying the initial condition u(x, 0) = x(π−x):
x(π−x) = ∞
∑
n=1
Cnsin(nx)
Multiplying both sides by sin(mx)and integrating from 0 to π:
∫π
0
x(π−x)sin(mx)dx =∫π
0(∞
∑
n=1
Cnsin(nx))sin(mx)dx
This will allow us to solve for the coefficients Cnand find the final solution to the heat
equation.
13. Find the general solution of the wave equation
utt(x, t) = 4uxx(x, t)
subject to the boundary conditions
u(0, t) = 0, u(π, t) = 0
and initial conditions
u(x, 0) = sin(x), ut(x, 0) = 2 cos(x)
Ans. To solve the wave equation, we first write down the general solution which is the sum of
a function moving to the right and a function moving to the left. Then, we apply the initial and
boundary conditions to find the specific solution.
1. Guess a general solution:
Let u(x, t) = f(x+ 4t) + g(x−4t)be a general solution to the wave equation.
2. Find partial derivatives:
Calculate the first and second partial derivatives of u(x, t)with respect to tand x:
ut(x, t) = f′(x+ 4t)4 + g′(x−4t)(−4) and uxx(x, t) = f′′(x+ 4t) + g′′(x−4t)
3. Substitute into the wave equation:
Plug u(x, t)and its derivatives into the wave equation:
(f′′(x+ 4t) + g′′(x−4t)) = 4(f′(x+ 4t)−g′(x−4t))
4. Simplify the equation:
Since f(x)and g(x)are arbitrary functions of x, the above equation is true if and only if
f′′(x)−4f′(x) = g′′(x)+4g′(x) = 0
This gives us the equations (D−4)2f= 0 and (D+ 4)2g= 0, where Dis the derivative
operator.
5. Solve the differential equations:
The solutions to these ordinary differential equations are
f(x) = c1e4x+c2xe4xand g(x) = c3e−4x+c4xe−4x
6. Apply the initial and boundary conditions:
Using the initial condition u(x, 0) = sin(x), we have
f(x) + g(x) = sin(x)=⇒c1e4x+c3e−4x=sin(x)
Using the initial condition ut(x, 0) = 2 cos(x), we have
4f′(x)−4g′(x) = 2 cos(x)
Applying the boundary conditions u(0, t) = 0 and u(π, t) = 0, we find
f(0) + g(0) = 0 and f(π) + g(π) = 0
7. Solve for the constants:
After solving the system of equations formed by the boundary and initial conditions, we can
find the constants c1, c2, c3, c4.
Hence, the general solution to the wave equation with the given boundary and initial conditions
is
u(x, t) = c1e4(x+4t)+c2(x+ 4t)e4(x+4t)+c3e−4(x−4t)+c4(x−4t)e−4(x−4t)
14. Question: Consider the one-dimensional heat equation with homogeneous Dirichlet bound-
ary conditions:
∂u
∂t =k∂2u
∂x2,0< x < 1, t > 0,
u(0, t) = u(1, t) = 0, t ≥0,
u(x, 0) = f(x),0≤x≤1.
Prove that if f(x)is piecewise continuous on [0,1], then the solution u(x, t)is continuous
for all x∈[0,1] and t > 0.
Ans. Solution: To prove the continuity of u(x, t)for all x∈[0,1] and t > 0, we will first show
that the solution satisfies the maximum principle. Then, we will use the maximum principle to
establish the continuity of u(x, t).
1. Maximum Principle: Let u(x, t)be the solution of the heat equation with the given
boundary and initial conditions. The maximum principle states that the maximum value of u(x, t)
over the spatial domain 0≤x≤1and time domain t > 0is attained on the boundary or the
initial condition.
To prove this, let M=max
0≤x≤1,t>0u(x, t). Suppose the maximum is attained at an interior
point (¯x, ¯
t). By contradiction, assume 0<¯x < 1and ¯
t > 0. Then, the function u(x, t)satisfies
the heat equation, which implies
∂u
∂t =k∂2u
∂x2.
Considering the point (¯x, ¯
t), the function u(x, t)attains a local maximum at this point, which
implies ∂u
∂t ≤0and ∂2u
∂x2≥0. Therefore, we have ∂u
∂t ≥0and ∂2u
∂x2≤0at the point (¯x, ¯
t), leading
to a contradiction. Hence, the maximum of u(x, t)must be attained at the boundary or the
initial condition.
2. Continuity of u(x, t):Since the maximum of u(x, t)is attained on the boundary or the
initial condition, u(x, t)is continuous for all x∈[0,1] and t > 0by the maximum principle.
Therefore, if f(x)is piecewise continuous on [0,1], the solution u(x, t)is continuous for all
x∈[0,1] and t > 0.
15. Question: Consider the one-dimensional heat equation
∂u
∂t = 2∂2u
∂x2
subject to the boundary conditions u(0, t) = u(1, t)=0for t > 0, and the initial condition
u(x, 0) = x(1 −x). Find the solution u(x, t)to this initial-boundary value problem.
Ans. Solution: 1. We will first seek a solution in the form of a Fourier series. Assume
u(x, t) = ∑∞
n=1 Bn(t)sin(nπx).
2. Plug this assumed solution into the PDE to obtain
∂
∂t (∞
∑
n=1
Bn(t)sin(nπx))= 2 ∂2
∂x2(∞
∑
n=1
Bn(t)sin(nπx))
3. Differentiate the assumed solution with respect to tand xand plug them back into the
PDE. This yields ∞
∑
n=1
dBn
dt sin(nπx) = −2π2∞
∑
n=1
Bn(t)n2sin(nπx)
4. Equating the coefficients of the sine functions on both sides gives a system of ordinary
differential equations:
dBn
dt =−2n2π2Bn
5. The solution to this ODE is
Bn(t) = cne−2n2π2t
6. Applying the boundary condition u(0, t) = 0 gives
∞
∑
n=1
Bn(t)sin(nπ ·0) = 0 =⇒Bn(t) = 0
7. Consequently, the solution to the PDE is u(x, t) = 0.
8. As for the initial condition, express it in terms of the assumed solution and compare
coefficients with the Fourier series expansion of the initial condition.
9. This comparison yields
cn=2∫1
0x(1 −x)sin(nπx)dx
∫1
0sin2(nπx)dx =4
n3π3((−1)n+1 −1)
10. Therefore, the solution to the initial-boundary value problem is
u(x, t) = ∞
∑
n=1
4
n3π3((−1)n+1 −1) sin(nπx)e−2n2π2t
16. Question 16:
Consider the following partial differential equation:
utt =c2uxx
Subject to the following boundary conditions and initial conditions:
Boundary conditions:
u(0, t) = 0
u(L, t) = 0
Initial conditions:
u(x, 0) = f(x)
ut(x, 0) = g(x)
where c, L are constants, and f(x), g(x)are given functions.
Find the solution u(x, t)to the partial differential equation with the given boundary and initial
conditions.
Ans. Solution:
We will use the method of separation of variables to solve the partial differential equation.
Let’s assume the solution has the form:
u(x, t) = X(x)T(t)
Substitute this into the partial differential equation:
X(x)T′′(t) = c2X′′(x)T(t)
Dividing both sides by X(x)T(t), we get:
T′′(t)
c2T(t)=X′′(x)
X(x)=−λ
where λis a constant.
1. Solving the time equation:
Solve the time part of the equation:
T′′(t) + c2λT (t) = 0
The general solution to this differential equation is:
T(t) = Acos(ct√λ)+Bsin(ct√λ)
2. Solving the spatial equation:
Solve the spatial part of the equation:
X′′(x) + λX(x) = 0
The general solution to this differential equation depends on the value of λ: - For λ= 0:
X(x) = Ax +B
- For λ < 0:
X(x) = Ccos(√−λx)+Dsin(√−λx)
- For λ > 0:
X(x) = Ecosh(√λx)+Fsinh(√λx)
3. Applying boundary conditions:
Since the boundary conditions are u(0, t)=0and u(L, t)=0, this implies that X(0) = 0
and X(L) = 0.
4. Applying initial conditions:
Given the initial conditions u(x, 0) = f(x)and ut(x, 0) = g(x), we can determine the
coefficients in the solution by matching with the initial conditions.
Finally, the solution to the partial differential equation with the given boundary and initial
conditions is:
u(x, t) = ∞
∑
n=1 (Ancos (nπc
Lt)+Bnsin (nπc
Lt))sin (nπ
Lx)
where the coefficients Anand Bnare determined by the initial conditions and the orthogonality
of the sine functions.
17. Question 17:
Consider the one-dimensional heat equation given by ∂u
∂t =k∂2u
∂x2, where u(x, t)is the temper-
ature distribution in a material at position xand time tand kis a constant thermal diffusivity.
If the material is initially at a temperature distribution u(x, 0) = f(x)for 0≤x≤L, subject
to boundary conditions u(0, t)=0and u(L, t)=0for t > 0, then find the solution for u(x, t)
using separation of variables.
Ans. Step-by-step solution:
1. Let’s assume that the solution u(x, t)can be written as a product of two functions, each
depending on a single variable:
u(x, t) = X(x)T(t)
2. Substituting this into the heat equation, we get:
X(x)T′(t) = kX′′(x)T(t)
3. Dividing both sides by kX(x)T(t):
T′(t)
kT (t)=X′′(x)
X(x)=−λ2
4. Solve the separated ODEs:
T′(t) + kλ2T(t) = 0
This gives us T(t) = Aexp{(−kλ2t)}
5. For the spatial part, we have:
X′′(x) + λ2X(x) = 0
This has the general solution X(x) = Bcos(λx) + Csin(λx)
6. Apply the boundary conditions u(0, t) = 0 and u(L, t) = 0 to find the specific values of λ:
X(0)T(t) = B= 0 ⇒B= 0
X(L)T(t) = Csin(λL) = 0 ⇒λ=nπ
L, n = 1,2,3, ...
7. Finally, the solution for u(x, t)can be expressed as a series:
u(x, t) = ∞
∑
n=1
cnsin (nπx
L)exp (−k(nπ
L)2
t)
where the coefficients cnare determined by the initial temperature distribution f(x).
18. Consider the Heat Equation in one dimension:
∂u
∂t =k∂2u
∂x2,0< x < 1, t > 0
subject to the boundary conditions:
u(0, t) = 0,
u(1, t) = 0,
and the initial condition:
u(x, 0) = 2x−x2
Find the solution u(x, t).
Ans. Solution: 1. First, we assume the solution can be written in the form of a separation of
variables: u(x, t) = X(x)T(t).
2. Substitute the separation of variables into the Heat Equation to get:
T′(t)
kT (t)=X′′(x)
X(x)=−λ
where λis a separation constant.
3. Solve the ODE for X(x)to obtain:
X′′(x) + λX(x) = 0
subject to the boundary conditions X(0) = 0 and X(1) = 0. The solutions will be of the
form Xn(x) = sin(nπx)for n= 1,2,3, . . ..
4. Solve the ODE for T(t)to obtain:
T′(t) = −kλT (t)=⇒T(t) = Ae−kλt
where Ais a constant.
5. The general solution is given by the sum of the products of the separated solutions:
u(x, t) = ∞
∑
n=1
Bnsin(nπx)e−k(nπ)2t
6. Apply the initial condition to find the coefficients Bn. Substitute u(x, 0) = 2x−x2into
the general solution to get:
2x−x2=∞
∑
n=1
Bnsin(nπx)
7. Multiply both sides by sin(mπx)and integrate from 0 to 1 to obtain:
Bm= 2 ∫1
0
xsin(mπx)dx −∫1
0
x2sin(mπx)dx
8. Therefore, the solution to the Heat Equation with the given initial and boundary conditions
is:
u(x, t) = ∞
∑
n=1
2∫1
0
xsin(nπx)sin(mπx)dx −∫1
0
x2sin(nπx)sin(mπx)dx sin(nπx)e−k(nπ)2t
19. Find the general solution to the heat equation
∂u
∂t =k∂2u
∂x2,
subject to the boundary conditions
u(0, t) = 0 and u(π, t) = 0,
and the initial condition
u(x, 0) = x(π−x).
Ans. The general solution to the given heat equation with specified boundary and initial
conditions is
u(x, t) = ∞
∑
n=1
Bne−kn2tsin(nx),
where
Bn=2
π∫π
0
x(π−x)sin(nx)dx =4(−1)n
n3.
Solution: 1. We begin by assuming the solution to the heat equation has the form
u(x, t) = X(x)T(t).
Plugging this into the heat equation gives
X(x)T′(t) = kX′′(x)T(t).
2. Dividing both sides by kX(x)T(t), we get
T′(t)
kT (t)=X′′(x)
X(x).
3. Since the left side depends only on tand the right side depends only on x, they must
both be equal to a constant. Let this constant be −λ2. This gives us two ordinary differential
equations to solve:
X′′(x) + λ2X(x) = 0 and T′(t) + kλ2T(t) = 0.
4. The boundary conditions u(0, t)=0and u(π, t)=0imply that X(0) = X(π)=0. This
means that the solutions to the Xdifferential equation are
Xn(x) = sin(nx),
where nis a positive integer.
5. Solving the Tdifferential equation, we find
Tn(t) = Bne−kn2t.
6. Therefore, the general solution to the heat equation is
u(x, t) = ∞
∑
n=1
Bne−kn2tsin(nx).
7. The initial condition u(x, 0) = x(π−x)implies that
u(x, 0) = ∞
∑
n=1
Bnsin(nx) = x(π−x).
8. Comparing coefficients on both sides, we have
Bn=2
π∫π
0
x(π−x)sin(nx)dx =4(−1)n
n3.
Hence, the general solution to the heat equation with the given boundary and initial conditions
is
u(x, t) = ∞
∑
n=1
4(−1)n
n3e−kn2tsin(nx).
20. Question: Consider the one-dimensional heat equation
∂u
∂t =k∂2u
∂x2,
subject to the initial condition
u(x, 0) = sin(x),
and boundary conditions
u(0, t) = u(π, t) = 0.
Determine the solution to the heat equation for u(x, t).
Ans. We will solve the one-dimensional heat equation using separation of variables. 1. We
assume a solution of the form u(x, t) = X(x)T(t). 2. Substituting this into the heat equation,
we get
XT ′=kX′′T
3. Dividing both sides by kXT , we have
T′
kT =X′′
X=−λ
where λis a constant that we will determine later. 4. Solving the time part of the equation, we
have
T′+kλT = 0
which has the solution
T(t) = Ae−kλt
5. Now, solving the spatial part of the equation, we have
X′′ +λX = 0
6. The general solution to this ordinary differential equation is
X(x) = Bsin(√λx)+Ccos(√λx)
7. Applying the boundary conditions u(0, t)=0and u(π, t)=0gives us X(0) = X(π)=0.
8. Thus, we have C= 0 from X(0) = 0 and √λπ =nπ, where nis a positive integer from
X(π) = 0. 9. This gives us the eigenvalues λn=n2. 10. Therefore, the solution to the heat
equation is
u(x, t) = ∞
∑
n=1
Bnsin(nx)e−kn2t
11. Finally, applying the initial condition u(x, 0) = sin(x)gives us Bn= 2 ∫π
0sin(x)sin(nx)dx.
21. Question 21: Consider the heat equation defined on a semi-infinite rod 0<x<∞with
initial temperature distribution u(x, 0) = x2and boundary condition u(0, t)=0. Solve the heat
equation for u(x, t).
Ans. To solve the heat equation for the given initial temperature distribution and boundary
condition, we will use the method of separation of variables.
1. Separation of Variables: Assume u(x, t) = X(x)T(t). Substitute this into the heat
equation ut=α2uxx to get T′
T=α2X′′
X, where αis a separation constant.
2. Solve the Time Component: Solve the time component by rearranging to get T′
T=
α2X′′
X. This leads to two ordinary differential equations: T′=α2λT and X′′ =λX.
3. Solve the Spatial Component: The spatial ODE X′′ =λX has eigenvalues λn=−β2
n
where βn=nπ
Land corresponding eigenfunctions Xn(x) = Bne−β2
nx. Apply the boundary
condition u(0, t) = 0 to get X(0) = 0.
4. Solve for the Time Function: The time ODE T′=−α2λT has solution T(t) =
Ce−α2λt.
5. Combine Spatial and Time Components: The general solution is u(x, t) = ∑∞
n=1 Cne−β2
nxe−α2β2
nt.
Apply the initial condition u(x, 0) = x2to determine the coefficients Cn.
6. Apply Initial Condition: Use the initial condition u(x, 0) = x2to find Cn=2∫∞
0x2Xn(x)dx
∫∞
0Xn(x)2dx .
Therefore, the final solution to the heat equation with the specified initial condition and
boundary condition is:
u(x, t) = ∞
∑
n=1
2∫∞
0x2Xn(x)dx
∫∞
0Xn(x)2dx e−β2
nxe−α2β2
nt
22. Question:
Consider the following heat equation with homogeneous Dirichlet boundary conditions in a
one-dimensional rod of length L:
∂u
∂t =k∂2u
∂x2,0< x < L, t > 0
Subject to the initial condition:
u(x, 0) = sin(πx
L),0≤x≤L
with boundary conditions:
u(0, t) = 0, u(L, t) = 0, t ≥0
Find the solution u(x, t)using the method of separation of variables.
(Hint: The solution can be written as an infinite sum of sine functions.)
Ans. Step-by-step solution:
1. We assume that the solution takes the form u(x, t) = X(x)T(t), and substitute it into
the heat equation.
2. This gives us:
X(x)T′(t) = kX′′(x)T(t)
3. Dividing both sides by kX(x)T(t)gives:
T′(t)
kT (t)=X′′(x)
X(x)=−λ2
4. Solving the ODE X′′ (x)
X(x)=−λ2with the boundary conditions X(0) = 0 and X(L) = 0
yields the eigenfunctions Xn(x) = √2
Lsin(nπx
L)with corresponding eigenvalues λn=nπ
Lfor
n= 1,2,3, ....
5. Next, solving the ODE T′(t)
kT (t)=−λ2gives Tn(t) = Cne−λ2kt for n= 1,2,3, ... where the
constants Cnwill be determined later.
6. The general solution to the heat equation is then given by:
u(x, t) = ∞
∑
n=1
Cn√2
Lsin(nπx
L)e−(nπ
L)2kt
7. Applying the initial condition u(x, 0) = sin(πx
L)to the solution gives:
sin(πx
L)=∞
∑
n=1
Cn√2
Lsin(nπx
L)
8. Using orthogonality of sine functions, we find:
Cn=√2
L∫L
0
sin(nπx
L)sin(πx
L)dx
9. The solution to the heat equation with the given boundary and initial conditions is then:
u(x, t) = ∞
∑
n=1 √2
Lsin(nπx
L)e−(nπ
L)2kt ∫L
0
sin(nπx
L)sin(πx
L)dx
23. Find the solution to the following Heat Equation with the given initial condition and
boundary conditions:
∂u
∂t =k∂2u
∂x2
u(x, 0) = 2x(1 −x)
u(0, t) = 0
u(1, t) = 0
Ans. Solution: We will use separation of variables to solve the Heat Equation. Let’s assume
the solution has the form u(x, t) = X(x)T(t).
1. Substitute u(x, t) = X(x)T(t)into the heat equation:
T′(t)
kT (t)=X′′(x)
X(x)=−λ
Thus, we have two ordinary differential equations:
T′(t) + kλT (t) = 0 and X′′(x) + λX(x) = 0
2. Solve the ODE for X(x)with the boundary conditions:
The general solution for X(x)is X(x) = Asin(nπx)where nis a positive integer. Applying
the boundary conditions u(0, t)=0and u(1, t)=0gives us A= 0 and n= 1 respectively.
Thus, the solution for X(x)is X(x) = sin(πx).
3. Solve the ODE for T(t):
The general solution for T(t)is T(t) = Bexp (−kλt). Assuming λ > 0, the solution for T(t)
is T(t) = Bexp (−kλt).
4. Combine X(x)and T(t):
The general solution to the heat equation is:
u(x, t) = ∞
∑
n=1
Cnsin(nπx)exp (−k(nπ)2t)
Where Cnare constants to be determined.
5. Apply the initial condition u(x, 0) = 2x(1 −x):
2x(1 −x) = ∞
∑
n=1
Cnsin(nπx)
Multiplying both sides by sin(mπx)and integrating from 0 to 1 gives:
Cm= 2 ∫1
0
x(1 −x)sin(mπx)dx
Solving this integral gives C1=8
π2and Cn= 0 for n= 1.
6. Final solution:
Therefore, the solution to the Heat Equation with the given initial and boundary conditions
is:
u(x, t) = 8
π2sin(πx)exp (−kπ2t)
24. Suppose a thin metal plate occupies the region R={(x, y)|0≤x≤2,0≤y≤1}and
its temperature is governed by the heat equation
∂u
∂t =k(∂2u
∂x2+∂2u
∂y2)
where u(x, y, t)is the temperature of the plate at position (x, y)and time t, and kis a
thermal conductivity constant.
The plate is insulated along the sides x= 0,x= 2, and y= 1, and initially the temperature
of the plate is given by u(x, y, 0) = 4xy(1 −x).
Determine the temperature u(x, y, t)throughout the plate Rat time t > 0.
Ans. Solution: 1. We begin by assuming a separation of variables of the form u(x, y, t) =
X(x)Y(y)T(t).
2. Substituting u(x, y, t)into the heat equation, we have
X(x)Y(y)T′(t) = k(X′′(x)Y(y)T(t) + X(x)Y′′(y)T(t))
3. Dividing both sides by kX(x)Y(y)T(t), we get
T′(t)
kT (t)=X′′(x)
X(x)+Y′′(y)
Y(y)=−λ
where λis a separation constant.
4. Solving the ODE for X(x)yields eigenfunctions Xn(x) = sin (nπx
2)and corresponding
eigenvalues λn=−(nπ
2)2.
5. Similarly, solving the ODE for Y(y)gives eigenfunctions Ym(y) = sin(mπy)and corre-
sponding eigenvalues λm=−(mπ)2.
6. Therefore, the general solution to the heat equation is
u(x, y, t) = ∞
∑
n=1
∞
∑
m=1
cnm sin (nπx
2)sin(mπy)e−(nπ
2)2kt
where cnm are constants to be determined from initial conditions.
7. Given the initial temperature distribution, we have
u(x, y, 0) = 4xy(1 −x) = ∞
∑
n=1
∞
∑
m=1
cnm sin (nπx
2)sin(mπy)
8. By orthogonality of sine functions, we can equate coefficients to obtain cnm.
9. Finally, we substitute back the determined values of cnm into the general solution to find
the temperature distribution u(x, y, t)throughout the plate at time t > 0.
25. Question 25:
Consider the one-dimensional heat equation on the interval 0< x < L with initial conditions
u(x, 0) = x(L−x)and boundary conditions u(0, t) = u(L, t) = 0.
(a) Find the steady-state solution uss(x).
(b) Find the solution u(x, t)at any time t > 0.
Ans. (a) To find the steady-state solution uss(x), we solve the heat equation with ∂u
∂t = 0. This
simplifies the heat equation to the Laplace equation ∂2uss
∂x2= 0 subject to the boundary conditions
uss(0) = uss(L) = 0.
1. The general solution to the Laplace equation is uss(x) = Ax +B, where Aand Bare
constants. Applying the boundary conditions, we find uss(0) = B= 0 and uss(L) = AL = 0,
which implies A= 0. Thus, the steady-state solution is uss(x) = 0.
(b) To find the solution u(x, t)at any time t > 0, we can use the method of separation of
variables, assuming u(x, t) = X(x)T(t).
1. Substitute u(x, t) = X(x)T(t)into the heat equation and divide by uto get 1
X
d2X
dx2=
1
k
1
T
dT
dt , where kis a separation constant.
2. Rearranging terms, we have 1
X
d2X
dx2=k1
T
dT
dt .
3. The left-hand side depends only on xwhile the right-hand side depends only on t. Since
they are equal to a constant −k, they must both be equal to −k.
4. Solve the ODE d2X
dx2+kX = 0 subject to X(0) = X(L) = 0 to find the spatial component
X(x).
5. Solve the ODE dT
dt +kα2T= 0 subject to T(0) = f(x)to find the temporal component
T(t).
Thus, the solution u(x, t)is given by the sum of the spatial and temporal components:
u(x, t) = ∑∞
n=1 [Ansin (nπx
L)][e−α2(kn)t], where Anare constants to be determined from the
initial condition.
26. Let u(x, t)satisfy the wave equation
utt =c2uxx
subject to the boundary conditions
u(0, t) = u(L, t) = 0, t > 0
and initial conditions
u(x, 0) = f(x), ut(x, 0) = g(x),
where f(x)and g(x)are given functions. Show that the solution can be written as
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)cos (nπct
L),
where
Bn=2
L∫L
0
f(x)sin (nπx
L)dx
is the Fourier sine series coefficient of f(x).
Ans. Solution: 1. We first assume a solution of the form
u(x, t) = X(x)T(t).
Substituting this into the wave equation, we have
X(x)T′′(t) = c2X′′(x)T(t).
2. Dividing by c2X(x)T(t), we get
T′′(t)
c2T(t)=X′′(x)
X(x).
3. Since the left-hand side depends only on tand the right-hand side depends only on x, they
must be equal to a constant −λ. So we have two ODEs to solve:
T′′(t) + c2λT (t) = 0 and X′′(x) + λX(x) = 0.
4. The boundary conditions and initial conditions imply that X(0) = X(L) = 0 and X(x)
has a Fourier sine series.
5. Solving the ODE X′′(x) + λX(x) = 0 with X(0) = X(L) = 0, we obtain the eigenvalues
λ=(nπ
L)2and the corresponding eigenfunctions sin (nπx
L).
6. The general solution to X(x)is then
X(x) = ∞
∑
n=1
Ansin (nπx
L),
where Anare constants to be determined.
7. Applying the Fourier sine series condition X(0) = 0 gives An= 0 for all n= 1, so
X(x) = A1sin (πx
L).
8. Now we solve the ODE T′′(t) + c2(nπ
L)2T(t) = 0 with initial conditions u(x, 0) = f(x)
and ut(x, 0) = g(x). The solution is
T(t) = Bncos (nπct
L),
where
Bn=2
L∫L
0
f(x)sin (nπx
L)dx
9. Combining the solutions for X(x)and T(t), we have
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)cos (nπct
L).
27. Question 27:
Consider the following heat equation on the domain 0< x < 1,t > 0:
ut=uxx, u(0, t) = 0, u(1, t) = 0, u(x, 0) = 4x(1 −x).
Find the solution to this heat equation subject to the given initial and boundary conditions.
Ans. Solution:
We will solve the heat equation using the method of separation of variables. Let’s assume a
solution of the form u(x, t) = X(x)T(t).
1. Separate Variables:
Substitute u(x, t) = X(x)T(t)into the heat equation and divide by uto get:
T′(t)
T(t)=X′′(x)
X(x)=−λ.
This leads to two ODEs:
T′=−λT, X′′ +λX = 0.
2. Solve the Time ODE:
The solution to T′(t) = −λT (t)is T(t) = c1e−λt.
3. Solve the Space ODE:
The general solution to X′′(x)+λX(x) = 0 is given by X(x) = c2cos(√λx)+c3sin(√λx).
4. Apply Boundary Conditions:
Applying the boundary conditions u(0, t) = 0 and u(1, t) = 0, we get X(0) = X(1) = 0:
X(0) = c2= 0, X(1) = c3sin(√λ)= 0.
This implies that √λ=nπ, where nis a positive integer.
5. Find the Eigenvalues and Eigenfunctions:
Therefore, we have λ= (nπ)2and Xn(x) = cnsin(nπx).
6. Find the Solution:
The solution to the heat equation is given by the sum of the terms corresponding to each
eigenvalue:
u(x, t) = ∞
∑
n=1
Tn(t)Xn(x) = ∞
∑
n=1
cne−(nπ)2tsin(nπx).
7. Apply Initial Condition:
To find the coefficients cn, we will use the initial condition u(x, 0) = 4x(1−x) = ∑∞
n=1 cnsin(nπx).
This leads to:
cn= 2 ∫1
0
4x(1 −x)sin(nπx)dx =8
n3π3((−1)n−1).
8. Final Solution:
Therefore, the solution to the heat equation with the given initial and boundary conditions is:
u(x, t) = ∞
∑
n=1
8
n3π3((−1)n−1)e−(nπ)2tsin(nπx).
28. Let u(x, t)satisfy the heat equation
∂u
∂t =c2∂2u
∂x2
where cis a positive constant. Additionally, let u(x, 0) = f(x)for 0<x<Land let
u(0, t) = u(L, t) = 0 for t > 0.
If f(x) = x(L−x), find the function u(x, t).
Ans. Let’s solve the heat equation using separation of variables: 1. We assume u(x, t) =
X(x)T(t), which leads to
X(x)T′(t) = c2X′′(x)T(t)
T′(t)
c2T(t)=X′′(x)
X(x)=−λ2
2. Solving T′(t) = −c2λ2T(t)with the boundary condition u(0, t) = u(L, t) = 0, we get Tn(t) =
Bne−(cλn)2t. 3. Solving X′′(x)+λ2X(x) = 0 with the boundary conditions u(0, t) = u(L, t) = 0,
we obtain Xn(x) = sin (nπ
Lx. 4. The solution of the heat equation is given by
u(x, t) = ∞
∑
n=1
Bne−(cλn)2tsin (nπ
Lx
5. To find Bn, we use the initial condition: u(x, 0) = f(x). Substituting f(x) = x(L−x)into
the formula and solving the integral, we find the final solution:
u(x, t) = ∞
∑
n=1 (2
nπ )2
(1 −(−1)n)e−(cλn)2tsin (nπ
Lx
29. Question: Consider the heat equation in one dimension given by ∂u
∂t =k∂2u
∂x2, subject to the
boundary conditions u(0, t) = 0 and u(L, t) = 0, and the initial condition u(x, 0) = f(x).
(a) Find the general solution u(x, t)of this heat equation in terms of the initial condition
f(x).
(b) Suppose the initial condition is given by f(x) = sin (3πx
L). Determine the specific solution
u(x, t)for this initial condition.
30. Find the general solution to the heat equation ∂u
∂t =k∂2u
∂x2subject to the boundary
conditions u(0, t) = 0 and u(L, t) = 0, where u(x, t)is the temperature distribution, kis a
constant, 0< x < L, and t > 0.
Ans. The general solution to the heat equation subject to the given boundary conditions is
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)e−(nπ
L)2kt
where Bnare constants determined by the initial condition.
Solution: 1. We start by separating variables in the heat equation: Let u(x, t) = X(x)T(t).
Substitute this into the heat equation to get
T′(t)
kT (t)=X′′(x)
X(x)=−λ
where λis a separation constant.
2. Solve the ODE for X(x): We have X′′(x)+λX(x) = 0 subject to the boundary conditions
X(0) = 0 and X(L) = 0. The solutions are
Xn(x) = sin (nπx
L)
3. Solve the ODE for T(t): We have T′(t) = −kλT (t), which gives T(t) = Ce−λkt. Since
λ=(nπ
L)2, we have Tn(t) = e−(nπ
L)2kt.
4. The general solution is the product of Xn(x)and Tn(t)for each n:
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)e−(nπ
L)2kt
5. Applying the initial condition u(x, 0) = f(x), the function representing the initial temper-
ature distribution, we can determine the constants Bn. This involves finding the Fourier series of
f(x)and matching coefficients.
6. The final solution will be
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)e−(nπ
L)2kt
where Bnare determined by the initial condition.
5. After solving the integral, we find
Bn={2(−1)n
n2π2if nis odd,
0if nis even.
Therefore, the final solution is
u(x, t) = ∞
∑
n=1
nodd
2(−1)n
n2π2sin (nπx
L)e−k(nπ
L)2t.
2. Find the general solution to the heat equation
ut=c2uxx
subject to the boundary conditions
u(0, t) = u(L, t) = 0
and the initial condition
u(x, 0) = 4 sin (πx
L)
Ans. Solution:
We will solve the heat equation using the method of separation of variables.
1. Separation of Variables:
Let’s assume the solution can be written in the form
u(x, t) = X(x)T(t)
Substitute this form into the heat equation
ut=c2uxx
to get
XT ′=c2X′′T
Dividing by c2XT , we get
T′
c2T=X′′
X=−λ
where λis a constant.
Thus, we obtain two ordinary differential equations:
T′+c2λT = 0
X′′ +λX = 0
2. Solving the Time Component:
The time component differential equation has the solution
T(t) = Acos(c√λt)+Bsin(c√λt)
where Aand Bare constants.
3. Solving the Spatial Component:
The spatial component differential equation has the solution
X(x) = Ccos(√λx)+Dsin(√λx)
Applying the boundary conditions u(0, t) = u(L, t) = 0 gives us
X(0) = C= 0
X(L) = Dsin(√λL)= 0
For non-trivial solutions, we must have
sin(√λL)= 0
which implies √λL =nπ
for integer n.
Thus, λ=(nπ
L)2and
Xn(x) = Dnsin (nπx
L)
4. General Solution:
The general solution is given by the linear combination of the separated solutions:
u(x, t) = ∞
∑
n=1
Tn(t)Xn(x) = ∞
∑
n=1 (Ancos (cnπt
L)+Bnsin (cnπt
L))Dnsin (nπx
L)
where An,Bn, and Dnare constants to be determined by the initial condition.
5. Applying the Initial Condition:
Applying the initial condition u(x, 0) = 4 sin (πx
L), we have
u(x, 0) = ∞
∑
n=1
BnDnsin (nπx
L)= 4 sin (πx
L)
Thus, we have B1D1= 4 and BnDn= 0 for n= 1.
Therefore, the general solution to the heat equation satisfying the given boundary and initial
conditions is
u(x, t) = 4 sin (πx
L)e−c2π2t/L2
3. Find the general solution to the heat equation
ut= 4uxx
subject to the boundary conditions
u(0, t) = 0 and u(π, t) = 0
and the initial condition
u(x, 0) = x(π−x)
where 0< x < π and t > 0.
Ans. Solution: 1. First, we assume a separation of variables of the form u(x, t) = X(x)T(t)
and substitute it into the heat equation to obtain
T′(t)
4T(t)=X′′(x)
X(x)=−λ
Solving the ODE for T(t)gives
T(t) = c1e−4λt
and solving for X(x)gives
X′′(x) + λX(x) = 0
2. The boundary conditions u(0, t) = 0 and u(π, t) = 0 imply that X(0) = X(π) = 0. The
general solution to the ODE is
X(x) = c2sin(√λx)+c3cos(√λx)
Applying the boundary conditions gives
X(0) = 0 =⇒c3= 0
and
X(π) = 0 =⇒sin(√λπ)= 0 =⇒λ=n2, n ∈Z+
So, X(x)simplifies to
Xn(x) = cnsin(nx), n ∈Z+
3. Now we can rewrite the general solution as
u(x, t) = ∞
∑
n=1
Tn(t)Xn(x)
where
Tn(t) = cne−4n2t
Therefore, the general solution to the heat equation with the given boundary conditions and
initial condition is
u(x, t) = ∞
∑
n=1
cne−4n2tsin(nx)
where the coefficients cnneed to be determined based on the initial condition.
4. Question:
Consider the Heat Equation in one dimension given by ∂u
∂t =k∂2u
∂x2, where u(x, t)denotes the
temperature distribution at position xand time t, and kis a constant thermal diffusivity.
Given the initial condition u(x, 0) = 2xfor 0≤x≤π, and boundary conditions u(0, t) =
u(π, t) = 0 for t > 0, find the solution u(x, t).
Ans. Step-by-step solution:
1. We start by assuming a separation of variables solution of the form u(x, t) = X(x)T(t).
Substituting this into the Heat Equation, we get:
T′(t)
kT (t)=X′′(x)
X(x)=−λ2
2. Solving the time part of the equation gives T(t) = ce−λ2kt, where cis a constant.
3. Now we solve the spatial part X′′(x) + λ2X(x)=0subject to the boundary conditions
X(0) = 0 and X(π) = 0. The general solution is:
X(x) = Asin(λx)
4. Applying the boundary conditions gives us λ=nfor n= 1,2,3, ..., with the corresponding
eigenfunctions Xn(x) = sin(nx).
5. Therefore, the general solution u(x, t)can be expressed as:
u(x, t) = ∞
∑
n=1
Bne−n2kt sin(nx)
6. To find the coefficients Bn, we apply the initial condition u(x, 0) = 2x:
2x=∞
∑
n=1
Bnsin(nx)
7. By using the orthogonality of sine functions, we can determine that Bn=2
nπ .
8. Therefore, the final solution to the Heat Equation with the given initial and boundary
conditions is:
u(x, t) = ∞
∑
n=1
2
nπ e−n2kt sin(nx)
5. Question: Consider the following Heat Equation on the interval 0< x < π:
ut=uxx, u(0, t) = u(π, t) = 0, u(x, 0) = 2 sin(2x).
Find the solution u(x, t)to the Heat Equation using Separation of Variables.
Ans. Solution:
We seek a solution of the form u(x, t) = X(x)T(t). Substituting this into the Heat Equation,
we have:
X(x)T′(t) = X′′(x)T(t)
1. Solving the spatial part:
After separation, we get:
T′(t)
T(t)=X′′(x)
X(x)=−λ
where λis a separation constant.
Solving the ODE for X(x), we have:
X′′(x) + λX(x) = 0
with boundary conditions X(0) = X(π) = 0.
The general solution to the ODE is X(x) = c1sin(√λx)+c2cos(√λx).
Applying the boundary conditions, we find that λ=n2for n= 1,2,3, . . ., and Xn(x) =
sin(nx).
2. Solving the temporal part:
Now, we consider the ODE for T(t):
T′(t) + n2T(t) = 0
with initial condition T(0) = 2.
The solution to this ODE is Tn(t) = 2e−n2t.
3. Finding the solution:
Putting it all together, the solution u(x, t)is given by:
u(x, t) = ∞
∑
n=1
Xn(x)Tn(t) = ∞
∑
n=1
2sin(nx)e−n2t
u(x, t) = 2 ∞
∑
n=1
sin(nx)e−n2t
Therefore, the solution to the Heat Equation using Separation of Variables is u(x, t) =
2∑∞
n=1 sin(nx)e−n2t.
6. Question: Consider the following Heat Equation defined on a semi-infinite rod (x > 0,t > 0)
with initial condition u(x, 0) = 2xand boundary condition u(0, t) = 1. Solve the Heat Equation
subject to these conditions, i.e., find u(x, t).
Ans. Step-by-step solution: 1. The general form of the Heat Equation on a rod of length Lis
given by:
∂u
∂t =k∂2u
∂x2
where kis the thermal conductivity.
2. We are given the initial condition u(x, 0) = 2xwhich means the rod’s temperature
distribution at t= 0 is 2x.
3. We are also given the boundary condition u(0, t) = 1, which means the temperature at
x= 0 is always 1.
4. Let’s denote u(x, t)as a function of xand t. Given the initial condition, we have
u(x, 0) = 2x, which implies that for t= 0:u(x, 0) = 2x.
5. To solve the Heat Equation subject to the given conditions, we first need to find the
general solution of the Heat Equation:
u(x, t) = ∞
∑
n=1
Bne−(nπ
L)2kt sin (nπx
L)
6. Subsequently, we need to find the specific solution that satisfies the initial and boundary
conditions. From the initial condition u(x, 0) = 2x, we have:
∞
∑
n=1
Bnsin (nπx
L)= 2x
7. Now, we apply the Fourier sine series expansion on the RHS (2x) to solve for the coefficients
Bn.
8. Once we find the coefficients Bn, we finally substitute them back into the general solution
u(x, t)to get the solution.
The solution to the Heat Equation subject to the given initial and boundary conditions would
be quite involved, but the above steps outline the general approach to solve it.
7. Find the solution to the wave equation utt = 4uxx subject to the boundary conditions
u(0, t) = u(π, t) = 0 and the initial conditions u(x, 0) = sin(x)and ut(x, 0) = 2 sin(x).
Ans. Solution: 1. To solve the wave equation, we first assume a solution of the form
u(x, t) = X(x)T(t). 2. Substituting this into the wave equation, we get T′′
T= 4X′′
X. 3.
Rearranging terms gives us T′′
T= 4X′′
X=−λ2, where λis a constant. 4. Solving T′′+λ2T= 0 for
T(t)gives us T(t) = acos(2t)+bsin(2t), where aand bare constants. 5. Solving X′′ +λ2X= 0
for X(x)gives us X(x) = ccos(2x) + dsin(2x), where cand dare constants. 6. Applying the
boundary conditions u(0, t)=0and u(π, t)=0gives us X(0)T(t)=0and X(π)T(t)=0. 7.
The boundary conditions imply that X(0) = X(π) = 0, which means ccos(0) + dsin(0) = 0 and
ccos(2π) + dsin(2π) = 0. 8. Solving the boundary conditions gives us c= 0 and dsin(2π) = 0.
Since d= 0, it follows that sin(2π)=0, which implies d= 0. 9. Therefore, the only solution
that satisfies the boundary conditions u(x, t) = 0 is the trivial solution u(x, t) = 0. 10. Finally,
the solution to the wave equation utt = 4uxx subject to the given boundary and initial conditions
is u(x, t) = 0.
8. Question: Consider the wave equation in one dimension, given by ∂2u
∂t2=c2∂2u
∂x2, where cis a
constant velocity. Solve the wave equation subject to the initial conditions u(x, 0) = sin(x)and
∂u
∂t (x, 0) = 0. Additionally, the boundary conditions are u(0, t) = u(π, t) = 0 for all t≥0.
Ans. Solution: We first apply separation of variables to solve the wave equation. Let u(x, t) =
X(x)T(t). Substituting this into the wave equation, we have:
1. T′′ (t)
c2T(t)=X′′ (x)
X(x)=−λ
Let’s solve the time equation first: T′′ (t)
c2T(t)=−λ=⇒T′′(t) + c2λT (t) = 0.
The general solution to this ordinary differential equation is T(t) = Acos(ct√λ)+Bsin(ct√λ).
Now let’s solve the spatial equation: X′′(x) + λX(x) = 0.
2. Applying the boundary conditions, we have X(0) = X(π) = 0.
This results in a discrete set of solutions:
3. For λ=n2where nis a positive integer, the eigenfunctions are Xn(x) = sin(nx).
Thus, the general solution to the PDE is:
4. u(x, t) = ∑∞
n=1(Ancos(ctn) + Bnsin(ctn)) sin(nx).
To find the coefficients, we impose the initial conditions:
5. u(x, 0) = sin(x) = ∑∞
n=1 Ansin(nx). We recognize this as the Fourier sine series for the
function f(x) = sin(x):An=2
π∫π
0sin(x)sin(nx)dx =2
π∫π
0sin(x)sin(nx)dx
Solving this integral we get An=2((−1)n−1)
π(n2−1) for n= 1 and A1= 0.
6. Therefore, the solution to the wave equation with the given initial conditions and boundary
conditions is: u(x, t) = ∑∞
n=1
2((−1)n−1)
π(n2−1) sin(nx)cos(cnt).
9. Question: Consider the heat equation in one dimension given by ∂u
∂t =k∂2u
∂x2, where kis a
positive constant. Solve the following initial-boundary value problem for u(x, t)subject to the
conditions:
PDE:∂u
∂t =k∂2u
∂x2
Initial condition:u(x, 0) = x(1 −x)
Boundary conditions:u(0, t) = u(1, t) = 0
Ans. Solution: We will use the method of separation of variables to solve the heat equation
with these initial and boundary conditions:
1. Separation of Variables:
Assume the solution has the form u(x, t) = X(x)T(t), where X(x)is a function of xonly
and T(t)is a function of tonly. Substitute this into the partial differential equation to get:
X(x)T′(t) = kX′′(x)T(t)
Divide both sides by kX(x)T(t)to separate variables:
T′(t)
kT (t)=X′′(x)
X(x)=−λ
This gives us two ordinary differential equations (ODEs):
T′(t) + kλT (t) = 0 and X′′(x) + λX(x) = 0
2. Solve the Time ODE:
The solution to the time ODE is of the form T(t) = Ae−λkt, where Ais a constant.
3. Solve the Space ODE:
The space ODE is a standard second-order homogeneous ODE with solutions depending on
the sign of λ:
For λ > 0, the general solution is X(x) = Bcos(√λx)+Csin(√λx).
For λ= 0, the general solution is X(x) = Bx +C.
For λ < 0, the general solution is X(x) = Be√−λx +Ce−√−λx.
4. Apply Boundary Conditions:
Since the boundary conditions are u(0, t) = 0 and u(1, t) = 0, we use the conditions X(0) =
X(1) = 0 to find the values of λand X(x).
For X(0) = 0, we have X(0) = B= 0.
For X(1) = 0, we have Csin(√λ)= 0. This gives us the condition λ=n2π2where nis a
positive integer.
5. Find the Eigenfunctions and Eigenvalues:
The eigenfunctions are Xn(x) = Cnsin(nπx)where nis a positive integer.
The corresponding eigenvalues are λn=n2π2.
6. Find the Solution:
The solution to the heat equation is the sum of the separated solutions:
u(x, t) = ∞
∑
n=1
Tn(t)Xn(x) = ∞
∑
n=1 (Ane−kλnt)Cnsin(nπx)
Applying the initial condition u(x, 0) = x(1 −x), we find the coefficients Anusing the
orthogonality of the eigenfunctions.
7. Final Solution:
The final solution to the initial-boundary value problem is given by:
u(x, t) = ∞
∑
n=1
e−k(nπ)2tbnsin(nπx)
where bnare the coefficients found using the initial condition.
10. Question: Consider the one-dimensional heat equation ∂u
∂t =k∂2u
∂x2on the interval 0< x < L,
subject to the boundary conditions u(0, t) = u(L, t) = 0, and the initial condition u(x, 0) = f(x).
Given that the initial condition is f(x) = x(L−x), find the solution u(x, t)using the method
of separation of variables.
Ans. Solution:
We assume the solution can be written as a product of functions u(x, t) = X(x)T(t), and
substitute this into the heat equation to obtain:
T′(t)
kT (t)=X′′(x)
X(x)=−λ2
This gives two ordinary differential equations:
T′(t) + kλ2T(t) = 0 and X′′(x) + λ2X(x) = 0
Solving the equation for T(t)gives T(t) = Aexp(−kλ2t).
For the spatial part, we have:
X′′(x) + λ2X(x) = 0 ⇒X(x) = Bcos(λx) + Csin(λx)
Applying the boundary conditions u(0, t) = u(L, t) = 0 gives X(x) = Csin (nπx
L).
Therefore, the solution can be expressed as:
u(x, t) = ∞
∑
n=1
cnsin (nπx
L)e−k(nπ
L)2t
To find the coefficients cn, we use the initial condition u(x, 0) = x(L−x):
f(x) = x(L−x) = ∞
∑
n=1
cnsin (nπx
L)
Multiplying both sides by sin (mπx
L)and integrating from 0to L, we get:
cm=2
L∫L
0
x(L−x)sin (mπx
L)dx
Evaluating this integral gives the final solution.
11. Question:
Consider the following heat equation on a rod of length L:
∂u
∂t =k∂2u
∂x2,0< x < L, t > 0
subject to the boundary conditions u(0, t)=0,u(L, t)=0for t > 0, and the initial condition
u(x, 0) = f(x), where
f(x) = {2xfor 0≤x < L
2
2(L−x)for L
2≤x≤L
Find the solution u(x, t)to this heat equation.
12. Find the solution to the heat equation on the interval 0<x<π, subject to the boundary
conditions u(0, t) = u(π, t) = 0, and the initial condition u(x, 0) = x(π−x).
Ans. Let’s denote the solution to the heat equation as u(x, t). To solve the problem, we will
use the method of separation of variables.
1. Separation of Variables: Assume the solution can be written as a product of functions
of xand t:u(x, t) = X(x)T(t).
Substitute u(x, t) = X(x)T(t)into the heat equation:
X(x)T′(t) = kX′′(x)T(t)
T′(t)
kT (t)=X′′(x)
X(x)=−λ
where λis a separation constant.
2. Solving the Time Component: From T′(t)
kT (t)=−λ, we have T′(t) + kλT (t) = 0. This
gives the exponential solution T(t) = Ce−kλt.
3. Solving the Space Component: From X′′ (x)
X(x)=−λ, we have X′′(x) + λX(x) = 0 with
boundary conditions X(0) = X(π) = 0.
The general solution to this ODE is X(x) = Csin(√λx). Applying the boundary conditions:
X(0) = 0 ⇒Csin(0) = 0 ⇒C= 0 (This is not interesting) X(π)=0⇒Csin(√λπ)= 0
For non-trivial solutions, we must have √λπ =nπ where n= 1,2,3, .... So, λ=n2.
4. Final Solution: The solution to the heat equation is then given by the sum of the infinite
series:
u(x, t) = ∞
∑
n=1
Cne−kλntsin(nx)
where Cnare coefficients that can be found using the initial condition.
Applying the initial condition u(x, 0) = x(π−x):
x(π−x) = ∞
∑
n=1
Cnsin(nx)
Multiplying both sides by sin(mx)and integrating from 0 to π:
∫π
0
x(π−x)sin(mx)dx =∫π
0(∞
∑
n=1
Cnsin(nx))sin(mx)dx
This will allow us to solve for the coefficients Cnand find the final solution to the heat
equation.
13. Find the general solution of the wave equation
utt(x, t) = 4uxx(x, t)
subject to the boundary conditions
u(0, t) = 0, u(π, t) = 0
and initial conditions
u(x, 0) = sin(x), ut(x, 0) = 2 cos(x)
Ans. To solve the wave equation, we first write down the general solution which is the sum of
a function moving to the right and a function moving to the left. Then, we apply the initial and
boundary conditions to find the specific solution.
1. Guess a general solution:
Let u(x, t) = f(x+ 4t) + g(x−4t)be a general solution to the wave equation.
2. Find partial derivatives:
Calculate the first and second partial derivatives of u(x, t)with respect to tand x:
ut(x, t) = f′(x+ 4t)4 + g′(x−4t)(−4) and uxx(x, t) = f′′(x+ 4t) + g′′(x−4t)
3. Substitute into the wave equation:
Plug u(x, t)and its derivatives into the wave equation:
(f′′(x+ 4t) + g′′(x−4t)) = 4(f′(x+ 4t)−g′(x−4t))
4. Simplify the equation:
Since f(x)and g(x)are arbitrary functions of x, the above equation is true if and only if
f′′(x)−4f′(x) = g′′(x)+4g′(x) = 0
This gives us the equations (D−4)2f= 0 and (D+ 4)2g= 0, where Dis the derivative
operator.
5. Solve the differential equations:
The solutions to these ordinary differential equations are
f(x) = c1e4x+c2xe4xand g(x) = c3e−4x+c4xe−4x
6. Apply the initial and boundary conditions:
Using the initial condition u(x, 0) = sin(x), we have
f(x) + g(x) = sin(x)=⇒c1e4x+c3e−4x=sin(x)
Using the initial condition ut(x, 0) = 2 cos(x), we have
4f′(x)−4g′(x) = 2 cos(x)
Applying the boundary conditions u(0, t) = 0 and u(π, t) = 0, we find
f(0) + g(0) = 0 and f(π) + g(π) = 0
7. Solve for the constants:
After solving the system of equations formed by the boundary and initial conditions, we can
find the constants c1, c2, c3, c4.
Hence, the general solution to the wave equation with the given boundary and initial conditions
is
u(x, t) = c1e4(x+4t)+c2(x+ 4t)e4(x+4t)+c3e−4(x−4t)+c4(x−4t)e−4(x−4t)
14. Question: Consider the one-dimensional heat equation with homogeneous Dirichlet bound-
ary conditions:
∂u
∂t =k∂2u
∂x2,0< x < 1, t > 0,
u(0, t) = u(1, t) = 0, t ≥0,
u(x, 0) = f(x),0≤x≤1.
Prove that if f(x)is piecewise continuous on [0,1], then the solution u(x, t)is continuous
for all x∈[0,1] and t > 0.
Ans. Solution: To prove the continuity of u(x, t)for all x∈[0,1] and t > 0, we will first show
that the solution satisfies the maximum principle. Then, we will use the maximum principle to
establish the continuity of u(x, t).
1. Maximum Principle: Let u(x, t)be the solution of the heat equation with the given
boundary and initial conditions. The maximum principle states that the maximum value of u(x, t)
over the spatial domain 0≤x≤1and time domain t > 0is attained on the boundary or the
initial condition.
To prove this, let M=max
0≤x≤1,t>0u(x, t). Suppose the maximum is attained at an interior
point (¯x, ¯
t). By contradiction, assume 0<¯x < 1and ¯
t > 0. Then, the function u(x, t)satisfies
the heat equation, which implies
∂u
∂t =k∂2u
∂x2.
Considering the point (¯x, ¯
t), the function u(x, t)attains a local maximum at this point, which
implies ∂u
∂t ≤0and ∂2u
∂x2≥0. Therefore, we have ∂u
∂t ≥0and ∂2u
∂x2≤0at the point (¯x, ¯
t), leading
to a contradiction. Hence, the maximum of u(x, t)must be attained at the boundary or the
initial condition.
2. Continuity of u(x, t):Since the maximum of u(x, t)is attained on the boundary or the
initial condition, u(x, t)is continuous for all x∈[0,1] and t > 0by the maximum principle.
Therefore, if f(x)is piecewise continuous on [0,1], the solution u(x, t)is continuous for all
x∈[0,1] and t > 0.
15. Question: Consider the one-dimensional heat equation
∂u
∂t = 2∂2u
∂x2
subject to the boundary conditions u(0, t) = u(1, t)=0for t > 0, and the initial condition
u(x, 0) = x(1 −x). Find the solution u(x, t)to this initial-boundary value problem.
Ans. Solution: 1. We will first seek a solution in the form of a Fourier series. Assume
u(x, t) = ∑∞
n=1 Bn(t)sin(nπx).
2. Plug this assumed solution into the PDE to obtain
∂
∂t (∞
∑
n=1
Bn(t)sin(nπx))= 2 ∂2
∂x2(∞
∑
n=1
Bn(t)sin(nπx))
3. Differentiate the assumed solution with respect to tand xand plug them back into the
PDE. This yields ∞
∑
n=1
dBn
dt sin(nπx) = −2π2∞
∑
n=1
Bn(t)n2sin(nπx)
4. Equating the coefficients of the sine functions on both sides gives a system of ordinary
differential equations:
dBn
dt =−2n2π2Bn
5. The solution to this ODE is
Bn(t) = cne−2n2π2t
6. Applying the boundary condition u(0, t) = 0 gives
∞
∑
n=1
Bn(t)sin(nπ ·0) = 0 =⇒Bn(t) = 0
7. Consequently, the solution to the PDE is u(x, t) = 0.
8. As for the initial condition, express it in terms of the assumed solution and compare
coefficients with the Fourier series expansion of the initial condition.
9. This comparison yields
cn=2∫1
0x(1 −x)sin(nπx)dx
∫1
0sin2(nπx)dx =4
n3π3((−1)n+1 −1)
10. Therefore, the solution to the initial-boundary value problem is
u(x, t) = ∞
∑
n=1
4
n3π3((−1)n+1 −1) sin(nπx)e−2n2π2t
16. Question 16:
Consider the following partial differential equation:
utt =c2uxx
Subject to the following boundary conditions and initial conditions:
Boundary conditions:
u(0, t) = 0
u(L, t) = 0
Initial conditions:
u(x, 0) = f(x)
ut(x, 0) = g(x)
where c, L are constants, and f(x), g(x)are given functions.
Find the solution u(x, t)to the partial differential equation with the given boundary and initial
conditions.
Ans. Solution:
We will use the method of separation of variables to solve the partial differential equation.
Let’s assume the solution has the form:
u(x, t) = X(x)T(t)
Substitute this into the partial differential equation:
X(x)T′′(t) = c2X′′(x)T(t)
Dividing both sides by X(x)T(t), we get:
T′′(t)
c2T(t)=X′′(x)
X(x)=−λ
where λis a constant.
1. Solving the time equation:
Solve the time part of the equation:
T′′(t) + c2λT (t) = 0
The general solution to this differential equation is:
T(t) = Acos(ct√λ)+Bsin(ct√λ)
2. Solving the spatial equation:
Solve the spatial part of the equation:
X′′(x) + λX(x) = 0
The general solution to this differential equation depends on the value of λ: - For λ= 0:
X(x) = Ax +B
- For λ < 0:
X(x) = Ccos(√−λx)+Dsin(√−λx)
- For λ > 0:
X(x) = Ecosh(√λx)+Fsinh(√λx)
3. Applying boundary conditions:
Since the boundary conditions are u(0, t)=0and u(L, t)=0, this implies that X(0) = 0
and X(L) = 0.
4. Applying initial conditions:
Given the initial conditions u(x, 0) = f(x)and ut(x, 0) = g(x), we can determine the
coefficients in the solution by matching with the initial conditions.
Finally, the solution to the partial differential equation with the given boundary and initial
conditions is:
u(x, t) = ∞
∑
n=1 (Ancos (nπc
Lt)+Bnsin (nπc
Lt))sin (nπ
Lx)
where the coefficients Anand Bnare determined by the initial conditions and the orthogonality
of the sine functions.
17. Question 17:
Consider the one-dimensional heat equation given by ∂u
∂t =k∂2u
∂x2, where u(x, t)is the temper-
ature distribution in a material at position xand time tand kis a constant thermal diffusivity.
If the material is initially at a temperature distribution u(x, 0) = f(x)for 0≤x≤L, subject
to boundary conditions u(0, t)=0and u(L, t)=0for t > 0, then find the solution for u(x, t)
using separation of variables.
Ans. Step-by-step solution:
1. Let’s assume that the solution u(x, t)can be written as a product of two functions, each
depending on a single variable:
u(x, t) = X(x)T(t)
2. Substituting this into the heat equation, we get:
X(x)T′(t) = kX′′(x)T(t)
3. Dividing both sides by kX(x)T(t):
T′(t)
kT (t)=X′′(x)
X(x)=−λ2
4. Solve the separated ODEs:
T′(t) + kλ2T(t) = 0
This gives us T(t) = Aexp{(−kλ2t)}
5. For the spatial part, we have:
X′′(x) + λ2X(x) = 0
This has the general solution X(x) = Bcos(λx) + Csin(λx)
6. Apply the boundary conditions u(0, t) = 0 and u(L, t) = 0 to find the specific values of λ:
X(0)T(t) = B= 0 ⇒B= 0
X(L)T(t) = Csin(λL) = 0 ⇒λ=nπ
L, n = 1,2,3, ...
7. Finally, the solution for u(x, t)can be expressed as a series:
u(x, t) = ∞
∑
n=1
cnsin (nπx
L)exp (−k(nπ
L)2
t)
where the coefficients cnare determined by the initial temperature distribution f(x).
18. Consider the Heat Equation in one dimension:
∂u
∂t =k∂2u
∂x2,0< x < 1, t > 0
subject to the boundary conditions:
u(0, t) = 0,
u(1, t) = 0,
and the initial condition:
u(x, 0) = 2x−x2
Find the solution u(x, t).
Ans. Solution: 1. First, we assume the solution can be written in the form of a separation of
variables: u(x, t) = X(x)T(t).
2. Substitute the separation of variables into the Heat Equation to get:
T′(t)
kT (t)=X′′(x)
X(x)=−λ
where λis a separation constant.
3. Solve the ODE for X(x)to obtain:
X′′(x) + λX(x) = 0
subject to the boundary conditions X(0) = 0 and X(1) = 0. The solutions will be of the
form Xn(x) = sin(nπx)for n= 1,2,3, . . ..
4. Solve the ODE for T(t)to obtain:
T′(t) = −kλT (t)=⇒T(t) = Ae−kλt
where Ais a constant.
5. The general solution is given by the sum of the products of the separated solutions:
u(x, t) = ∞
∑
n=1
Bnsin(nπx)e−k(nπ)2t
6. Apply the initial condition to find the coefficients Bn. Substitute u(x, 0) = 2x−x2into
the general solution to get:
2x−x2=∞
∑
n=1
Bnsin(nπx)
7. Multiply both sides by sin(mπx)and integrate from 0 to 1 to obtain:
Bm= 2 ∫1
0
xsin(mπx)dx −∫1
0
x2sin(mπx)dx
8. Therefore, the solution to the Heat Equation with the given initial and boundary conditions
is:
u(x, t) = ∞
∑
n=1
2∫1
0
xsin(nπx)sin(mπx)dx −∫1
0
x2sin(nπx)sin(mπx)dx sin(nπx)e−k(nπ)2t
19. Find the general solution to the heat equation
∂u
∂t =k∂2u
∂x2,
subject to the boundary conditions
u(0, t) = 0 and u(π, t) = 0,
and the initial condition
u(x, 0) = x(π−x).
Ans. The general solution to the given heat equation with specified boundary and initial
conditions is
u(x, t) = ∞
∑
n=1
Bne−kn2tsin(nx),
where
Bn=2
π∫π
0
x(π−x)sin(nx)dx =4(−1)n
n3.
Solution: 1. We begin by assuming the solution to the heat equation has the form
u(x, t) = X(x)T(t).
Plugging this into the heat equation gives
X(x)T′(t) = kX′′(x)T(t).
2. Dividing both sides by kX(x)T(t), we get
T′(t)
kT (t)=X′′(x)
X(x).
3. Since the left side depends only on tand the right side depends only on x, they must
both be equal to a constant. Let this constant be −λ2. This gives us two ordinary differential
equations to solve:
X′′(x) + λ2X(x) = 0 and T′(t) + kλ2T(t) = 0.
4. The boundary conditions u(0, t)=0and u(π, t)=0imply that X(0) = X(π)=0. This
means that the solutions to the Xdifferential equation are
Xn(x) = sin(nx),
where nis a positive integer.
5. Solving the Tdifferential equation, we find
Tn(t) = Bne−kn2t.
6. Therefore, the general solution to the heat equation is
u(x, t) = ∞
∑
n=1
Bne−kn2tsin(nx).
7. The initial condition u(x, 0) = x(π−x)implies that
u(x, 0) = ∞
∑
n=1
Bnsin(nx) = x(π−x).
8. Comparing coefficients on both sides, we have
Bn=2
π∫π
0
x(π−x)sin(nx)dx =4(−1)n
n3.
Hence, the general solution to the heat equation with the given boundary and initial conditions
is
u(x, t) = ∞
∑
n=1
4(−1)n
n3e−kn2tsin(nx).
20. Question: Consider the one-dimensional heat equation
∂u
∂t =k∂2u
∂x2,
subject to the initial condition
u(x, 0) = sin(x),
and boundary conditions
u(0, t) = u(π, t) = 0.
Determine the solution to the heat equation for u(x, t).
Ans. We will solve the one-dimensional heat equation using separation of variables. 1. We
assume a solution of the form u(x, t) = X(x)T(t). 2. Substituting this into the heat equation,
we get
XT ′=kX′′T
3. Dividing both sides by kXT , we have
T′
kT =X′′
X=−λ
where λis a constant that we will determine later. 4. Solving the time part of the equation, we
have
T′+kλT = 0
which has the solution
T(t) = Ae−kλt
5. Now, solving the spatial part of the equation, we have
X′′ +λX = 0
6. The general solution to this ordinary differential equation is
X(x) = Bsin(√λx)+Ccos(√λx)
7. Applying the boundary conditions u(0, t)=0and u(π, t)=0gives us X(0) = X(π)=0.
8. Thus, we have C= 0 from X(0) = 0 and √λπ =nπ, where nis a positive integer from
X(π) = 0. 9. This gives us the eigenvalues λn=n2. 10. Therefore, the solution to the heat
equation is
u(x, t) = ∞
∑
n=1
Bnsin(nx)e−kn2t
11. Finally, applying the initial condition u(x, 0) = sin(x)gives us Bn= 2 ∫π
0sin(x)sin(nx)dx.
21. Question 21: Consider the heat equation defined on a semi-infinite rod 0<x<∞with
initial temperature distribution u(x, 0) = x2and boundary condition u(0, t)=0. Solve the heat
equation for u(x, t).
Ans. To solve the heat equation for the given initial temperature distribution and boundary
condition, we will use the method of separation of variables.
1. Separation of Variables: Assume u(x, t) = X(x)T(t). Substitute this into the heat
equation ut=α2uxx to get T′
T=α2X′′
X, where αis a separation constant.
2. Solve the Time Component: Solve the time component by rearranging to get T′
T=
α2X′′
X. This leads to two ordinary differential equations: T′=α2λT and X′′ =λX.
3. Solve the Spatial Component: The spatial ODE X′′ =λX has eigenvalues λn=−β2
n
where βn=nπ
Land corresponding eigenfunctions Xn(x) = Bne−β2
nx. Apply the boundary
condition u(0, t) = 0 to get X(0) = 0.
4. Solve for the Time Function: The time ODE T′=−α2λT has solution T(t) =
Ce−α2λt.
5. Combine Spatial and Time Components: The general solution is u(x, t) = ∑∞
n=1 Cne−β2
nxe−α2β2
nt.
Apply the initial condition u(x, 0) = x2to determine the coefficients Cn.
6. Apply Initial Condition: Use the initial condition u(x, 0) = x2to find Cn=2∫∞
0x2Xn(x)dx
∫∞
0Xn(x)2dx .
Therefore, the final solution to the heat equation with the specified initial condition and
boundary condition is:
u(x, t) = ∞
∑
n=1
2∫∞
0x2Xn(x)dx
∫∞
0Xn(x)2dx e−β2
nxe−α2β2
nt
22. Question:
Consider the following heat equation with homogeneous Dirichlet boundary conditions in a
one-dimensional rod of length L:
∂u
∂t =k∂2u
∂x2,0< x < L, t > 0
Subject to the initial condition:
u(x, 0) = sin(πx
L),0≤x≤L
with boundary conditions:
u(0, t) = 0, u(L, t) = 0, t ≥0
Find the solution u(x, t)using the method of separation of variables.
(Hint: The solution can be written as an infinite sum of sine functions.)
Ans. Step-by-step solution:
1. We assume that the solution takes the form u(x, t) = X(x)T(t), and substitute it into
the heat equation.
2. This gives us:
X(x)T′(t) = kX′′(x)T(t)
3. Dividing both sides by kX(x)T(t)gives:
T′(t)
kT (t)=X′′(x)
X(x)=−λ2
4. Solving the ODE X′′ (x)
X(x)=−λ2with the boundary conditions X(0) = 0 and X(L) = 0
yields the eigenfunctions Xn(x) = √2
Lsin(nπx
L)with corresponding eigenvalues λn=nπ
Lfor
n= 1,2,3, ....
5. Next, solving the ODE T′(t)
kT (t)=−λ2gives Tn(t) = Cne−λ2kt for n= 1,2,3, ... where the
constants Cnwill be determined later.
6. The general solution to the heat equation is then given by:
u(x, t) = ∞
∑
n=1
Cn√2
Lsin(nπx
L)e−(nπ
L)2kt
7. Applying the initial condition u(x, 0) = sin(πx
L)to the solution gives:
sin(πx
L)=∞
∑
n=1
Cn√2
Lsin(nπx
L)
8. Using orthogonality of sine functions, we find:
Cn=√2
L∫L
0
sin(nπx
L)sin(πx
L)dx
9. The solution to the heat equation with the given boundary and initial conditions is then:
u(x, t) = ∞
∑
n=1 √2
Lsin(nπx
L)e−(nπ
L)2kt ∫L
0
sin(nπx
L)sin(πx
L)dx
23. Find the solution to the following Heat Equation with the given initial condition and
boundary conditions:
∂u
∂t =k∂2u
∂x2
u(x, 0) = 2x(1 −x)
u(0, t) = 0
u(1, t) = 0
Ans. Solution: We will use separation of variables to solve the Heat Equation. Let’s assume
the solution has the form u(x, t) = X(x)T(t).
1. Substitute u(x, t) = X(x)T(t)into the heat equation:
T′(t)
kT (t)=X′′(x)
X(x)=−λ
Thus, we have two ordinary differential equations:
T′(t) + kλT (t) = 0 and X′′(x) + λX(x) = 0
2. Solve the ODE for X(x)with the boundary conditions:
The general solution for X(x)is X(x) = Asin(nπx)where nis a positive integer. Applying
the boundary conditions u(0, t)=0and u(1, t)=0gives us A= 0 and n= 1 respectively.
Thus, the solution for X(x)is X(x) = sin(πx).
3. Solve the ODE for T(t):
The general solution for T(t)is T(t) = Bexp (−kλt). Assuming λ > 0, the solution for T(t)
is T(t) = Bexp (−kλt).
4. Combine X(x)and T(t):
The general solution to the heat equation is:
u(x, t) = ∞
∑
n=1
Cnsin(nπx)exp (−k(nπ)2t)
Where Cnare constants to be determined.
5. Apply the initial condition u(x, 0) = 2x(1 −x):
2x(1 −x) = ∞
∑
n=1
Cnsin(nπx)
Multiplying both sides by sin(mπx)and integrating from 0 to 1 gives:
Cm= 2 ∫1
0
x(1 −x)sin(mπx)dx
Solving this integral gives C1=8
π2and Cn= 0 for n= 1.
6. Final solution:
Therefore, the solution to the Heat Equation with the given initial and boundary conditions
is:
u(x, t) = 8
π2sin(πx)exp (−kπ2t)
24. Suppose a thin metal plate occupies the region R={(x, y)|0≤x≤2,0≤y≤1}and
its temperature is governed by the heat equation
∂u
∂t =k(∂2u
∂x2+∂2u
∂y2)
where u(x, y, t)is the temperature of the plate at position (x, y)and time t, and kis a
thermal conductivity constant.
The plate is insulated along the sides x= 0,x= 2, and y= 1, and initially the temperature
of the plate is given by u(x, y, 0) = 4xy(1 −x).
Determine the temperature u(x, y, t)throughout the plate Rat time t > 0.
Ans. Solution: 1. We begin by assuming a separation of variables of the form u(x, y, t) =
X(x)Y(y)T(t).
2. Substituting u(x, y, t)into the heat equation, we have
X(x)Y(y)T′(t) = k(X′′(x)Y(y)T(t) + X(x)Y′′(y)T(t))
3. Dividing both sides by kX(x)Y(y)T(t), we get
T′(t)
kT (t)=X′′(x)
X(x)+Y′′(y)
Y(y)=−λ
where λis a separation constant.
4. Solving the ODE for X(x)yields eigenfunctions Xn(x) = sin (nπx
2)and corresponding
eigenvalues λn=−(nπ
2)2.
5. Similarly, solving the ODE for Y(y)gives eigenfunctions Ym(y) = sin(mπy)and corre-
sponding eigenvalues λm=−(mπ)2.
6. Therefore, the general solution to the heat equation is
u(x, y, t) = ∞
∑
n=1
∞
∑
m=1
cnm sin (nπx
2)sin(mπy)e−(nπ
2)2kt
where cnm are constants to be determined from initial conditions.
7. Given the initial temperature distribution, we have
u(x, y, 0) = 4xy(1 −x) = ∞
∑
n=1
∞
∑
m=1
cnm sin (nπx
2)sin(mπy)
8. By orthogonality of sine functions, we can equate coefficients to obtain cnm.
9. Finally, we substitute back the determined values of cnm into the general solution to find
the temperature distribution u(x, y, t)throughout the plate at time t > 0.
25. Question 25:
Consider the one-dimensional heat equation on the interval 0< x < L with initial conditions
u(x, 0) = x(L−x)and boundary conditions u(0, t) = u(L, t) = 0.
(a) Find the steady-state solution uss(x).
(b) Find the solution u(x, t)at any time t > 0.
Ans. (a) To find the steady-state solution uss(x), we solve the heat equation with ∂u
∂t = 0. This
simplifies the heat equation to the Laplace equation ∂2uss
∂x2= 0 subject to the boundary conditions
uss(0) = uss(L) = 0.
1. The general solution to the Laplace equation is uss(x) = Ax +B, where Aand Bare
constants. Applying the boundary conditions, we find uss(0) = B= 0 and uss(L) = AL = 0,
which implies A= 0. Thus, the steady-state solution is uss(x) = 0.
(b) To find the solution u(x, t)at any time t > 0, we can use the method of separation of
variables, assuming u(x, t) = X(x)T(t).
1. Substitute u(x, t) = X(x)T(t)into the heat equation and divide by uto get 1
X
d2X
dx2=
1
k
1
T
dT
dt , where kis a separation constant.
2. Rearranging terms, we have 1
X
d2X
dx2=k1
T
dT
dt .
3. The left-hand side depends only on xwhile the right-hand side depends only on t. Since
they are equal to a constant −k, they must both be equal to −k.
4. Solve the ODE d2X
dx2+kX = 0 subject to X(0) = X(L) = 0 to find the spatial component
X(x).
5. Solve the ODE dT
dt +kα2T= 0 subject to T(0) = f(x)to find the temporal component
T(t).
Thus, the solution u(x, t)is given by the sum of the spatial and temporal components:
u(x, t) = ∑∞
n=1 [Ansin (nπx
L)][e−α2(kn)t], where Anare constants to be determined from the
initial condition.
26. Let u(x, t)satisfy the wave equation
utt =c2uxx
subject to the boundary conditions
u(0, t) = u(L, t) = 0, t > 0
and initial conditions
u(x, 0) = f(x), ut(x, 0) = g(x),
where f(x)and g(x)are given functions. Show that the solution can be written as
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)cos (nπct
L),
where
Bn=2
L∫L
0
f(x)sin (nπx
L)dx
is the Fourier sine series coefficient of f(x).
Ans. Solution: 1. We first assume a solution of the form
u(x, t) = X(x)T(t).
Substituting this into the wave equation, we have
X(x)T′′(t) = c2X′′(x)T(t).
2. Dividing by c2X(x)T(t), we get
T′′(t)
c2T(t)=X′′(x)
X(x).
3. Since the left-hand side depends only on tand the right-hand side depends only on x, they
must be equal to a constant −λ. So we have two ODEs to solve:
T′′(t) + c2λT (t) = 0 and X′′(x) + λX(x) = 0.
4. The boundary conditions and initial conditions imply that X(0) = X(L) = 0 and X(x)
has a Fourier sine series.
5. Solving the ODE X′′(x) + λX(x) = 0 with X(0) = X(L) = 0, we obtain the eigenvalues
λ=(nπ
L)2and the corresponding eigenfunctions sin (nπx
L).
6. The general solution to X(x)is then
X(x) = ∞
∑
n=1
Ansin (nπx
L),
where Anare constants to be determined.
7. Applying the Fourier sine series condition X(0) = 0 gives An= 0 for all n= 1, so
X(x) = A1sin (πx
L).
8. Now we solve the ODE T′′(t) + c2(nπ
L)2T(t) = 0 with initial conditions u(x, 0) = f(x)
and ut(x, 0) = g(x). The solution is
T(t) = Bncos (nπct
L),
where
Bn=2
L∫L
0
f(x)sin (nπx
L)dx
9. Combining the solutions for X(x)and T(t), we have
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)cos (nπct
L).
27. Question 27:
Consider the following heat equation on the domain 0< x < 1,t > 0:
ut=uxx, u(0, t) = 0, u(1, t) = 0, u(x, 0) = 4x(1 −x).
Find the solution to this heat equation subject to the given initial and boundary conditions.
Ans. Solution:
We will solve the heat equation using the method of separation of variables. Let’s assume a
solution of the form u(x, t) = X(x)T(t).
1. Separate Variables:
Substitute u(x, t) = X(x)T(t)into the heat equation and divide by uto get:
T′(t)
T(t)=X′′(x)
X(x)=−λ.
This leads to two ODEs:
T′=−λT, X′′ +λX = 0.
2. Solve the Time ODE:
The solution to T′(t) = −λT (t)is T(t) = c1e−λt.
3. Solve the Space ODE:
The general solution to X′′(x)+λX(x) = 0 is given by X(x) = c2cos(√λx)+c3sin(√λx).
4. Apply Boundary Conditions:
Applying the boundary conditions u(0, t) = 0 and u(1, t) = 0, we get X(0) = X(1) = 0:
X(0) = c2= 0, X(1) = c3sin(√λ)= 0.
This implies that √λ=nπ, where nis a positive integer.
5. Find the Eigenvalues and Eigenfunctions:
Therefore, we have λ= (nπ)2and Xn(x) = cnsin(nπx).
6. Find the Solution:
The solution to the heat equation is given by the sum of the terms corresponding to each
eigenvalue:
u(x, t) = ∞
∑
n=1
Tn(t)Xn(x) = ∞
∑
n=1
cne−(nπ)2tsin(nπx).
7. Apply Initial Condition:
To find the coefficients cn, we will use the initial condition u(x, 0) = 4x(1−x) = ∑∞
n=1 cnsin(nπx).
This leads to:
cn= 2 ∫1
0
4x(1 −x)sin(nπx)dx =8
n3π3((−1)n−1).
8. Final Solution:
Therefore, the solution to the heat equation with the given initial and boundary conditions is:
u(x, t) = ∞
∑
n=1
8
n3π3((−1)n−1)e−(nπ)2tsin(nπx).
28. Let u(x, t)satisfy the heat equation
∂u
∂t =c2∂2u
∂x2
where cis a positive constant. Additionally, let u(x, 0) = f(x)for 0<x<Land let
u(0, t) = u(L, t) = 0 for t > 0.
If f(x) = x(L−x), find the function u(x, t).
Ans. Let’s solve the heat equation using separation of variables: 1. We assume u(x, t) =
X(x)T(t), which leads to
X(x)T′(t) = c2X′′(x)T(t)
T′(t)
c2T(t)=X′′(x)
X(x)=−λ2
2. Solving T′(t) = −c2λ2T(t)with the boundary condition u(0, t) = u(L, t) = 0, we get Tn(t) =
Bne−(cλn)2t. 3. Solving X′′(x)+λ2X(x) = 0 with the boundary conditions u(0, t) = u(L, t) = 0,
we obtain Xn(x) = sin (nπ
Lx. 4. The solution of the heat equation is given by
u(x, t) = ∞
∑
n=1
Bne−(cλn)2tsin (nπ
Lx
5. To find Bn, we use the initial condition: u(x, 0) = f(x). Substituting f(x) = x(L−x)into
the formula and solving the integral, we find the final solution:
u(x, t) = ∞
∑
n=1 (2
nπ )2
(1 −(−1)n)e−(cλn)2tsin (nπ
Lx
29. Question: Consider the heat equation in one dimension given by ∂u
∂t =k∂2u
∂x2, subject to the
boundary conditions u(0, t) = 0 and u(L, t) = 0, and the initial condition u(x, 0) = f(x).
(a) Find the general solution u(x, t)of this heat equation in terms of the initial condition
f(x).
(b) Suppose the initial condition is given by f(x) = sin (3πx
L). Determine the specific solution
u(x, t)for this initial condition.
30. Find the general solution to the heat equation ∂u
∂t =k∂2u
∂x2subject to the boundary
conditions u(0, t) = 0 and u(L, t) = 0, where u(x, t)is the temperature distribution, kis a
constant, 0< x < L, and t > 0.
Ans. The general solution to the heat equation subject to the given boundary conditions is
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)e−(nπ
L)2kt
where Bnare constants determined by the initial condition.
Solution: 1. We start by separating variables in the heat equation: Let u(x, t) = X(x)T(t).
Substitute this into the heat equation to get
T′(t)
kT (t)=X′′(x)
X(x)=−λ
where λis a separation constant.
2. Solve the ODE for X(x): We have X′′(x)+λX(x) = 0 subject to the boundary conditions
X(0) = 0 and X(L) = 0. The solutions are
Xn(x) = sin (nπx
L)
3. Solve the ODE for T(t): We have T′(t) = −kλT (t), which gives T(t) = Ce−λkt. Since
λ=(nπ
L)2, we have Tn(t) = e−(nπ
L)2kt.
4. The general solution is the product of Xn(x)and Tn(t)for each n:
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)e−(nπ
L)2kt
5. Applying the initial condition u(x, 0) = f(x), the function representing the initial temper-
ature distribution, we can determine the constants Bn. This involves finding the Fourier series of
f(x)and matching coefficients.
6. The final solution will be
u(x, t) = ∞
∑
n=1
Bnsin (nπx
L)e−(nπ
L)2kt
where Bnare determined by the initial condition.