logo

Solution to the Initial Value Problem for the Heat Equation Given Dirichlet Boundary Conditions 📂Partial Differential Equations

Solution to the Initial Value Problem for the Heat Equation Given Dirichlet Boundary Conditions

Description

$$ \begin{cases} u_{t} = \gamma u_{xx} \\ u(t,0) = u(t,l) = 0 \\ u(0,x) = f(x) \end{cases} $$

The above equation is a Dirichlet boundary condition in a $1$-dimensional space with length of $l$ from Heat Equation

$$ \begin{cases} u(t,0) = \alpha (t) \\ u(t,l) = \beta (t) \end{cases} $$

This is given by $\alpha = \beta = 0$ with initial conditions for the heat distribution. Among such problem types, this is the simplest and easiest form. Here, $t$ represents time, $x$ represents position, and $u(t,x)$ represents the distribution of heat at time $t$. $\gamma$ is the thermal diffusivity, the larger it is, the faster the change in distribution. $f$ is the initial condition, specifically representing the distribution of heat when $t=0$.

Solution

Continued from Solution of Heat Equation.


  • Step 4. Check if $\lambda$ is an eigenvalue

    With the candidate solution being $u(t,x) = e^{-\lambda t} v(X)$, due to Dirichlet boundary condition, it follows that

    $$ e^{-\lambda t} v(0) = e^{-\lambda t} v(l) = 0 $$

    Hence, it’s necessary to verify whether the non-trivial solution $v$ satisfies $v(0) = v(l) = 0$.

    • Case 1. $\lambda < 0$ For some constant $c_{1} , c_{2} \in \mathbb{C}$,

      $$ v(x) = c_{1} e^{ \sqrt{ -{{\lambda} \over {\gamma}} } x } + c_{2 } e^{ - \sqrt{ -{{\lambda} \over {\gamma}} } x } $$

      Hence,

      $$ v(0) = 0 \implies c_{1} + c_{2} = 0 \\ v(l) = 0 \implies c_{1} e^{ \sqrt{ -{{\lambda} \over {\gamma}} } l } + c_{2 } e^{ - \sqrt{ -{{\lambda} \over {\gamma}} } l } = 0 $$

      The only thing satisfying this simultaneously is $c_{1} = c_{2} = 0$. Since $v(x) = 0$, $v$ becomes a trivial solution, making $\lambda$ not an eigenvalue.

    • Case 2. $\lambda = 0$

      For some constant $c_{1} , c_{2} \in \mathbb{C}$, since $\displaystyle v(x) = c_{1} + c_{2} x$,

      $$ v(0) = 0 \implies c_{1} = 0 \\ v(l) = 0 \implies c_{1} + c_{2 } l = 0 $$

      The only thing satisfying this simultaneously is $c_{1} = c_{2} = 0$. Since $v(x) = 0$, $v$ becomes a trivial solution, making $\lambda$ not an eigenvalue.

    • Case 4. $\lambda \notin \mathbb{R}$

      Let’s express it as $\lambda = r e^{i \theta}$. For some constant $c_{1} , c_{2} \in \mathbb{C}$,

      $$ v(x) = c_{1} \exp \left( \sqrt{ {{r} \over {\gamma}} } e^{ i {{ \theta } \over {2}} } x \right) + c_{2 } \exp \left( \sqrt{ {{r} \over {\gamma}} } e^{ i \left( {{ \theta } \over {2}} + \pi\right) } x \right) $$

      Hence, from $v(0) = v(l) = 0$,

      $$ \begin{bmatrix} 1 & 1 \\ \exp \left( \sqrt{ {{r} \over {\gamma}} } e^{i {{\theta} \over {2}} } l \right) & \exp \left( \sqrt{ {{r} \over {\gamma}} } e^{i \left( {{\theta} \over {2}} + \pi \right) } l \right) \end{bmatrix} \begin{bmatrix} c_{1} \\ c_{2} \end{bmatrix} = \begin{bmatrix} 0 \\ 0 \end{bmatrix} $$

      Here,

      $$ \begin{align*} && \det \begin{bmatrix} 1 & 1 \\ \exp \left( \sqrt{ {{r} \over {\gamma}} } e^{i {{\theta} \over {2}} } l \right) & \exp \left( \sqrt{ {{r} \over {\gamma}} } e^{i \left( {{\theta} \over {2}} + \pi \right) } l \right) \end{bmatrix} \\ =& \exp \left( \sqrt{ {{r} \over {\gamma}} } e^{i \left( {{\theta} \over {2}} + \pi \right) } l \right) - \exp \left( \sqrt{ {{r} \over {\gamma}} } e^{i {{\theta} \over {2}} } l \right) \\ &\ne& 0 \end{align*} $$

      Therefore, $c_{1} = c_{2} = 0$ and since $v(x) = 0$, $v$ becomes a trivial solution, making $\lambda$ not an eigenvalue.

    Hence, in Case 1., Case 2., and Case 4., $u(t,x) = 0$ is found.

    • Case 3. $\lambda > 0$

      For some constant $c_{1} , c_{2} \in \mathbb{C}$,

      $$ v(x) = c_{1} e^{ i \sqrt{ -{{\lambda} \over {\gamma}} } x } + c_{2 } e^{ - i \sqrt{ -{{\lambda} \over {\gamma}} } x } $$

      Hence, from $v(0) = v(l) = 0$,

      $$ \begin{bmatrix} 1 & 0 \\ \cos \left( \sqrt{ {{ \lambda } \over {\gamma}} } l \right) & \sin \left( \sqrt{ {{ \lambda } \over {\gamma}} } l \right) \end{bmatrix} \begin{bmatrix} c_{1} \\ c_{2} \end{bmatrix} = \begin{bmatrix} 0 \\ 0 \end{bmatrix} $$

      Here,

      $$ \det \begin{bmatrix} 1 & 0 \\ \cos \left( \sqrt{ {{ \lambda } \over {\gamma}} } l \right) & \sin \left( \sqrt{ {{ \lambda } \over {\gamma}} } l \right) \end{bmatrix} = \sin \left( \sqrt{ {{ \lambda } \over {\gamma}} } l \right) $$

      i.e., only $\displaystyle \lambda = \lambda_{n} : = \gamma \left( {{n \pi} \over {l}} \right)^2$ that make $\displaystyle \sin \left( \sqrt{ {{ \lambda } \over {\gamma}} } l \right) = 0$ happens are the eigenvalues. In Case 3., we move to Step 5..

  • Step 5.

    Let’s assume that $\displaystyle u(t,x) := \sum_{n=1}^{\infty} b_{n} u_{n} (t,X)$ converges for all $x \in [ 0 , l ]$ when

    $$ u_{n}(t,x) := \exp \left( - {{\gamma n^2 \pi^2 } \over {l^2}} t \right) \sin \left( {{ n \pi x } \over {l}} \right) \\ b_{n} := {{1 } \over {l}} \int_{-l}^{l} f(x) \sin \left( {{ n \pi x } \over {l}} \right) dx $$

    This solution satisfies the heat equation and meets the Dirichlet boundary conditions. Expanding this:

    $$ u(t,x) = \sum_{n=1}^{\infty} \left< f(x) , \sin \left( {{ n \pi x } \over {l}} \right) \right> \exp \left( - {{\gamma n^2 \pi^2 } \over {l^2}} t \right) \sin \left( {{ n \pi x } \over {l}} \right) $$

    When $t=0$,

    $$ u(0,x) = \sum_{n=1}^{\infty} \left< f(x) , \sin \left( {{ n \pi x } \over {l}} \right) \right> \sin \left( {{ n \pi x } \over {l}} \right) \sim f(x) $$

    Therefore, if it converges, the initial condition $f(x) = u(0,x)$ is also satisfied.


From a physical sense, it’s obvious that $\lambda$ only makes sense when positive during the solution process. Since $\lambda$ is a diffusion coefficient, if it could be negative, phenomena violating the Second Law of Thermodynamics would be rampant.

See Also