$\newcommand{\erf}{\operatorname{erf}}$ $\newcommand{\const}{\mathrm{const}}$

1D Heat equation

  1. 1D Heat equation on half-line
  2. Inhomogeneous boundary conditions
  3. Inhomogeneous right-hand expression

1D Heat equation on half-line

In the previous lecture we considered heat equation \begin{equation} u_t=ku_{xx} \label{eq-1} \end{equation} with $x\in \mathbb{R}$ and $t>0$ and derived formula \begin{equation} u(x,t)=\int _{-\infty}^\infty G(x,y,t) g(y)\,dy. \label{eq-2} \end{equation} with \begin{equation} G(x,y,t)=G_0(x-y,t):=\frac{1}{2\sqrt{k\pi t}}e^{-\frac{(x-y)^2}{4kt}} \label{eq-3} \end{equation} for solution of IVP $u|_{t=0}=g(x)$.

Recall that $G(x,y,t)$ quickly decays as $|x-y|\to \infty$ and it tends to $0$ as $t\to +0$ for $x\ne y$, but $\int G(x,y,t)\,dy=1$.

In the Home assignment 3 there are problems to solve by the method of continuation equation (\ref{eq-1}) on half-line or a segment with the homogeneous Dirichlet or Neumann boundary condition at $x=0$: \begin{align} &u_D|_{x=0}=0,\tag{D}\label{eq-D}\\[3pt] &u_{N\,x}|_{x=0}=0\tag{N}.\label{eq-N} \end{align} This solution also has a form (\ref{eq-2}) but with different function $G(x,y)$ (and obviously with the different domain of integration $[0,\infty)$): \begin{align} &G=G_D|=G_0(x-y,t)-G_0(x+y,t),\label{eq-4}\\[3pt] &G=G_N|=G_0(x-y,t)+G_0(x+y,t)\label{eq-5}\\[3pt] \end{align} for (\ref{eq-D}) and (\ref{eq-N}) respectively.

Both these functions satisfy equation (\ref{eq-1}) with respect to $(x,t)$, \begin{align} &G_D|_{x=0}=0,\label{eq-6}\\[3pt] &G_{N\,x}|_{x=0}=0.\label{eq-7} \end{align} tend to $0$ as $t\to +0$, \begin{align} &\int_0^\infty G_D(x,y,t)\,dx\to 1 \qquad \text{as }t\to+0,\label{eq-8}\\[3pt] &\int_0^\infty G_D(x,y,t)\,dx= 1.\label{eq-9} \end{align} Further, \begin{equation} G(x,y,t)=G(y,x,t) \label{eq-10} \end{equation}

Inhomogeneous boundary conditions

Consider now inhomogeneous boundary conditions \begin{align} &u_D|_{x=0}=p(t),\label{eq-11}\\[3pt] &u_{N\,x}|_{x=0}=q(t).\label{eq-12} \end{align} Consider \begin{equation*} 0=\int_\Pi G(x,y,t-\tau) \bigl(-u_{\tau}(y,\tau)+ku_{yy}(y,\tau)\bigr) d\tau'dy \end{equation*} with $\Pi=\{x>0, 0<\tau <t-\epsilon\}$. Integrating by parts with respect to $\tau$ in the first term and twice with respect to $y$ in the second one we get \begin{align*} 0=&\int_\Pi \bigl( -G_t (x,y,t-\tau) + k G_{yy}(x,y,t-\tau)\bigr)u(y,\tau) d\tau'dy\\ -& \int_0^\infty G (x,y,\epsilon) u(y,t-\epsilon)\, dy + \int _0^\infty G (x,y,t) u(y,0)\, dy+ \\ & k \int_0^{t-\epsilon} \bigl( -G(x,y,t-\tau)u_y(y,\tau) + G_y(x,y,t-\tau)u(y,\tau)\bigr)_{y=0}\,d\tau. \end{align*} Note that, since $G$ satisfies (\ref{eq-1}) with respect to $(y,t)$ as well due to symmetry, the first line is $0$.

In the second line the first term tends to $-u(x,t)$ because of properties of $G(x,y,t)$ (really, tends everywhere but for $x=y$ to $0$ and its integral from $0$ to $\infty$ tends to $1$).

So we get \begin{multline} u(x,t)=\int_0^\infty G(x,y,t)\underbrace{u(y,0)}_{=g(y)}\,dy+\\ \int_0^{t} \bigl( -G(x,y,t-\tau)u_y(y,\tau) + G_y(x,y,t-\tau)u(y,\tau)\bigr)_{y=0}\,d\tau. \qquad \label{eq-13} \end{multline} The first line gives in the r.h.e. us solution of the IBVP with $0$ boundary condition. Let us consider the second line.

In the case of Dirichlet boundary condition $G(x,y,t)=0$ as $y=0$ and therefore we get here \begin{equation*} k \int_0^{t} G_y(x,y,t-\tau)\underbrace{u(0,\tau)}_{=p(\tau)}\,d\tau; \end{equation*} In the case of Dirichlet boundary condition $G(x,y,t)=0$ as $y=0$ and therefore we get here \begin{equation*} -k \int_0^{t} G(x,y,t-\tau)\underbrace{u(0,\tau)}_{=q(\tau)}\,d\tau. \end{equation*} So, (\ref{eq-13}) becomes \begin{equation} u_D(x,t)=\int_0^\infty G_D(x,y,t)g(y)\,dy+k \int_0^{t} G_{D\,y}(x,0,t-\tau)p(\tau) \,d\tau; \qquad \label{eq-14} \end{equation} and \begin{equation} u_N(x,t)=\int_0^\infty G_N(x,y,t)g(y)\,dy-k \int_0^{t} G_{N\,y}(x,0,t-\tau)q(\tau) \,d\tau.\qquad \label{eq-15} \end{equation}

Remark.

  1. If we consider a half-line $(-\infty,0)$ rather than $(0,\infty)$ then the same terms appear on the right end ($x=0$) albeit with the opposite sign;
  2. If we consider a finite interval $(a,b)$ then there will be contributions from both ends;
  3. If we consider Robin boundary condition $(u_x-\alpha u)|_{x=0}=q(t)$ then formula (\ref{eq-15}) would work but $G$ should satisfy the same Robin condition and we cannot consruct $G$ by a method of continuation.

Inhomogeneous right-hand expression

Consider equation \begin{equation} u_t-ku_{xx}=f(x,t). \label{eq-16} \end{equation} Either by Duhamel principle or just using the same calculations as above one can prove that its contribution would be \begin{equation} \int_0^t \int G(x,y,t-\tau) f(y,\tau)\,dydt \label{eq-17} \end{equation} with the same $G$ as was used for equation (\ref{eq-1}).

References

  1. erf function
  2. erf derivative