Find the solution to the heat equation ∂u/∂t = α²∂²u/∂x² with boundary conditions u(0,t) = u(L,t) = 0 and initial condition u(x,0) = sin(πx/L).

Answer: u(x,t)=sin⁡(πxL)e−α2(π/L)2tu(x,t) = \sin\left(\frac{\pi x}{L}\right) e^{-\alpha^2 (\pi/L)^2 t}

Step-by-step solution

Step 1: Assume a Separable Solution

We begin by assuming a separable solution of the form u(x,t)=X(x)T(t)u(x,t) = X(x)T(t), where X(x)X(x) is a function of xx only and T(t)T(t) is a function of tt only. This method is commonly used for solving partial differential equations like the heat equation.

Step 2: Substitute into the Heat Equation

Substituting u(x,t)=X(x)T(t)u(x,t) = X(x)T(t) into the heat equation ∂u∂t=α2∂2u∂x2\frac{\partial u}{\partial t} = \alpha^2\frac{\partial^2 u}{\partial x^2} and separating variables leads to two ordinary differential equations. Since one side depends only on tt and the other only on xx, both must be equal to a constant, which we denote as −λ2-\lambda^2 for convenience in solving the resulting equations.

Step 3: Solve the Spatial Equation

The spatial equation X′′(x)+λ2X(x)=0X''(x) + \lambda^2 X(x) = 0 with boundary conditions X(0)=0X(0) = 0 and X(L)=0X(L) = 0 yields a general solution involving sines and cosines. Applying the boundary conditions forces C1=0C_1 = 0 and λ\lambda to be quantized as nπL\frac{n\pi}{L}, leading to eigenfunctions Xn(x)=Bnsin⁡(nπxL)X_n(x) = B_n \sin(\frac{n\pi x}{L}).

Step 4: Solve the Temporal Equation

The temporal equation T′(t)+α2λ2T(t)=0T'(t) + \alpha^2 \lambda^2 T(t) = 0 is a first-order linear differential equation. Its solution is an exponential decay function, where λ\lambda takes the values determined from the spatial problem.

Step 5: Form the General Solution

Combining the spatial and temporal solutions, and using the principle of superposition, we form the general solution as an infinite series. Each term in the series corresponds to a particular value of nn.

Step 6: Apply Initial Condition

To find the coefficients BnB_n, we apply the initial condition u(x,0)=sin⁡(πxL)u(x,0) = \sin(\frac{\pi x}{L}). This involves using the orthogonality of sine functions. For the given initial condition, only the n=1n=1 term will be non-zero.

Step 7: Determine Coefficients and Final Solution

Evaluating the integral for BnB_n, we find that B1=1B_1 = 1 and all other Bn=0B_n = 0. Substituting these coefficients back into the general solution gives the particular solution that satisfies all given conditions.

Solve your own maths question free →