# 6.5: Solving PDEs with the Laplace Transform

- Page ID
- 72470

The Laplace transform comes from the same family of transforms as does the Fourier series\(^{1}\), which we used in Chapter 4 to solve partial differential equations (PDEs). It is therefore not surprising that we can also solve PDEs with the Laplace transform.

Given a PDE in two independent variables \(x\) and \(t\), we use the Laplace transform on one of the variables (taking the transform of everything in sight), and derivatives in that variable become multiplications by the transformed variable \(s\). The PDE becomes an ODE, which we solve. Afterwards we invert the transform to find a solution to the original problem. It is best to see the procedure on an example.

Example \(\PageIndex{1}\)

Consider the first order PDE \[y_t = - \alpha y_x, \qquad \text{for } x > 0, \enspace t > 0,\] with side conditions \[y(0,t) = C, \qquad y(x,0) = 0 .\] This equation is called the *convection equation* or sometimes the *transport equation*, and it already made an appearance in Section 1.9, with different conditions. See Figure \(\PageIndex{1}\) for a diagram of the setup.

Figure \(\PageIndex{1}\): Transport equation on a half line.

A physical setup of this equation is a river of solid goo, as we do not want anything to diffuse. The function \(y\) is the concentration of some toxic substance.\(^{2}\) The variable \(x\) denotes position where \(x=0\) is the location of a factory spewing the toxic substance into the river. The toxic substance flows into the river so that at \(x=0\) the concentration is always \(C\). We wish to see what happens past the factory, that is at \(x > 0\). Let \(t\) be the time, and assume the factory started operations at \(t=0\), so that at \(t=0\) the river is just pure goo.

Consider a function of two variables \(y(x,t)\). Let us fix \(x\) and transform the \(t\) variable. For convenience, we treat the transformed \(s\) variable as a parameter, since there are no derivatives in \(s\). That is, we write \(Y(x)\) for the transformed function, and treat it as a function of \(x\), leaving \(s\) as a parameter. \[Y(x) = {\mathcal L} \bigl\{ y(x,t) \bigr\} = \int_0^\infty y(x,t) e^{-st} \,ds .\]

The transform of a derivative with respect to \(x\) is just differentiating the transformed function: \[{\mathcal L} \bigl\{ y_x(x,t) \bigr\} = \int_0^\infty y_x(x,t) e^{-st} \,ds = \frac{d}{dx} \left[\int_0^\infty y(x,t) e^{-st} \,ds \right] = Y'(x) .\]

To transform the derivative in \(t\) (the variable being transformed), we use the rules from Section 6.2: \[{\mathcal L} \bigl\{ y_t(x,t) \bigr\} = sY(x) - y(x,0) .\] In our specific case, \(y(x,0)=0\), and so \({\mathcal L} \bigl\{ y_t(x,t) \bigr\} = sY(x)\). We transform the equation to find \[sY(x) = -\alpha Y'(x) .\] This ODE needs an initial condition. The initial condition is the other side condition of the PDE, the one that depends on \(x\). Everything is transformed, so we must also transform this condition \[Y(0) = {\mathcal L} \bigl\{ y(0,t) \bigr\} = {\mathcal L} \bigl\{ C \bigr\} = \frac{C}{s} .\] We solve the ODE problem \(sY(x) = -\alpha Y'(x)\), \(Y(0) = \frac{C}{s}\), to find \[Y(x) = \frac{C}{s} e^{-\frac{s}{\alpha} x} .\] We are not done, we have \(Y(x)\), but we really want \(y(x,t)\). We transform the \(s\) variable back to \(t\). Let \[u(t) = \begin{cases} 0 & \text{if $t < 0$}, \\ 1 & \text{otherwise} \end{cases}\] be the Heaviside function. As \[{\mathcal L} \bigl\{ u(t-a) \bigr\} = \int_0^\infty u(t-a) \, e^{-st} \,dt = \int_a^\infty e^{-st} \,dt = \frac{e^{-as}}{s} ,\] then \[y(x,t) = {\mathcal L}^{-1} \left\{ \frac{C}{s} e^{-\frac{s}{\alpha} x} \right\} = C u\bigl(t-\frac{x}{\alpha}\bigr) .\] In other words, \[y(x,t) = \begin{cases} 0 & \text{if $t < \frac{x}{\alpha}$}, \\ C & \text{otherwise.} \end{cases}\]

See Figure \(\PageIndex{2}\) for a diagram of this solution. The line of slope \(\frac{1}{\alpha}\) indicates the wavefront of the toxic substance in the picture as it is leaving the factory. What the equation does is simply move the initial condition to the right at speed \(\alpha\).

Figure \(\PageIndex{2}\): Wavefront of toxic substance is a line of slope \(\frac{1}{a}\).

Shhh…\(y\) is not differentiable, it is not even continuous (nobody ever seems to notice). How could we plug something that’s not differentiable into the equation? Well, just think of a differentiable function very very close to \(y\). Or, if you recognize the derivative of the Heaviside function as the delta function, then all is well too: \[y_t (x,t) = \frac{\partial}{\partial t} \left[ C u\bigl(t-\frac{x}{\alpha}\bigr) \right] = C u'\bigl(t-\frac{x}{\alpha}\bigr) = C \delta\bigl(t-\frac{x}{\alpha}\bigr)\] and \[y_x (x,t) = \frac{\partial}{\partial x} \left[ C u\bigl(t-\frac{x}{\alpha}\bigr) \right] = - \frac{C}{\alpha} u'\bigl(t-\frac{x}{\alpha}\bigr) = - \frac{C}{\alpha} \delta\bigl(t-\frac{x}{\alpha}\bigr) .\] So \(y_t = - \alpha y_x\).

Laplace equation is very good with constant coefficient equations. One advantage of Laplace is that it easily handles nonhomogeneous side conditions. Let us try a more complicated example.

Example \(\PageIndex{2}\)

Consider \[\begin{align}\begin{aligned} & y_t + y_x + y = 0, \qquad \text{for } x > 0, \enspace t > 0, \\ & y(0,t) = \sin(t), \qquad y(x,0) = 0 .\end{aligned}\end{align}\] Again, we transform \(t\), and we write \(Y(x)\) for the transformed function. As \(y(x,0) = 0\), we find \[sY(x) + Y'(x) + Y(x) = 0, \qquad Y(0) = \frac{1}{s^2+1} .\] The solution of the transformed equation is \[Y(x) = \frac{1}{s^2+1} e^{-(s+1) x} = \frac{1}{s^2+1} e^{-xs} e^{-x} .\] Using the second shifting property (6.2.14) and linearity of the transform, we obtain the solution \[y(x,t) = e^{-x} \sin(t-x) u(t-x) .\]

We can also detect when the problem is in the sense that it has no solution. Let us change the equation to \[\begin{align}\begin{aligned} & -y_t + y_x = 0, \qquad \text{for } x > 0, \enspace t > 0, \\ & y(0,t) = \sin(t), \qquad y(x,0) = 0 .\end{aligned}\end{align}\]

Then the problem has no solution. First, let us see this in the language of Section 1.9. The characteristic curves are \(t=-x+C\). If \(\tau\) is the the characteristic coordinate, then we find the equation \(y_\tau = 0\) along the curve, meaning a solution is constant along characteristic curves. But these curves intersect both the \(x\)-axis and the \(t\)-axis. For example, the curve \(t=-x+1\) intersects at \((1,0)\) and \((0,1)\). The solution is constant along the curve so \(y(1,0)\) should equal \(y(0,1)\). But \(y(1,0) = 0\) and \(y(0,1) = \sin(1) \not= 0\). See Figure \(\PageIndex{3}\).

Figure \(\PageIndex{3}\): Ill-posed problem.

Now consider the transform. The transformed problem is \[-sY(x) + Y'(x) = 0, \enspace Y(0) = \frac{1}{s^2+1} ,\] and the solution ought to be \[Y(x) = \frac{1}{s^2+1} e^{sx} .\] Importantly, this Laplace transform does not decay to zero at infinity! That is, since \(x > 0\) in the region of interest, then \[\lim_{s \to \infty} \frac{1}{s^2+1} e^{sx} = \infty \not= 0 .\] It almost looks as if we could use the shifting property, but notice that the shift is in the wrong direction. Of course, we need not restrict ourselves to first order equations, although the computations become more involved for higher order equations.

Example \(\PageIndex{3}\)

Let us use Laplace for the following problem:

\[\begin{aligned} & y_t = y_{xx}, \qquad 0 < x < \infty, \enspace t > 0,\\ & y_x(0,t) = f(t), \\ & y(x,0) = 0 .\end{aligned}\] Really we also impose other conditions on the solution so that for example the Laplace transform exists. For example, we might impose that \(y\) is bounded for each fixed time \(t\). Transform the equation in the \(t\) variable to find \[sY(x) = Y''(x) .\] The general solution to this ODE is \[Y(x) = A e^{\sqrt{s}x} + B e^{-\sqrt{s} x} .\] First \(A=0\), since otherwise \(Y\) does not decay to zero as \(s \to \infty\). Now consider the boundary condition. Transform \(Y'(0) = F(s)\) and so \(-\sqrt{s}B = F(s)\). In other words, \[Y(x) = - F(s) \frac{1}{\sqrt{s}} e^{-\sqrt{s} x} .\]

If we look up the inverse transform in a table such as the one in Appendix B (or we spend the afternoon doing calculus), we find \[{\mathcal L}^{-1}\left[e^{-\sqrt{s} x}\right] = \frac{x}{\sqrt{4\pi t^3}} e^{\frac{-x^2}{4t}} ,\] or \[{\mathcal L}^{-1}\left[\frac{1}{\sqrt{s}} e^{-\sqrt{s} x}\right] = \frac{1}{\sqrt{\pi t}} e^{\frac{-x^2}{4t}} .\] So \[y(x,t) = {\mathcal L}^{-1} \left[ F(s) e^{-\sqrt{s} x}\right] = \int_0^t f(\tau) \frac{1}{\sqrt{\pi {(t-\tau)}}} e^{\frac{-x^2}{4(t-\tau)}} \, d\tau .\]

Laplace can solve problems where separation of variables fails. Laplace does not mind nonhomogeneity, but it is essentially only useful for constant coefficient equations.