How Can We Solve Differential Equations Using Algebra? The Laplace Transform

From Recurrences to Differential Equations

In the first two articles of this series, the Z-transform helped us solve recurrences and understand digital filters. What if the unknown quantity changes continuously rather than one step at a time? Differential equations describe such changes, from cooling objects to electrical circuits and vibrating springs. The Laplace transform offers a remarkable shortcut: it turns differentiation into algebra.

Previously in the series: Finding the 100th Fibonacci Number Using the Z-Transform.

Three-step diagram showing how the Laplace transform converts a differential equation into an algebraic equation and then recovers the solution.
The Laplace transform in action: a differential equation becomes an algebraic equation. After solving using partial fractions, the inverse transform gives the solution.

1. The Main Idea

For a function defined for nonnegative time, its Laplace transform is

F(s)=\mathcal{L}\{f(t)\}(s)=\int_0^\infty e^{-st}f(t)\,dt.

The integral must converge; for example, it does for sufficiently large real s when f grows no faster than an exponential. The variable t represents time, while s is a new variable in which the equation becomes easier to solve.

Start with the constant function f(t)=1. For s>0,

\mathcal{L}\{1\}=\int_0^\infty e^{-st}\,dt=\frac1s.

Similarly, for s>a,

\mathcal{L}\{e^{at}\}=\int_0^\infty e^{-(s-a)t}\,dt=\frac1{s-a}.

Thus an exponential function becomes a simple fraction.

2. Why Derivatives Become Algebra

Suppose f is differentiable and sufficiently well behaved for integration by parts. Then

\begin{aligned}\mathcal{L}\{f'(t)\}&=\int_0^\infty e^{-st}f'(t)\,dt\\&=\left[e^{-st}f(t)\right]_0^\infty+s\int_0^\infty e^{-st}f(t)\,dt\\&=sF(s)-f(0).\end{aligned}

Here we assume e^{-st}f(t)\to0 as t\to\infty. Applying the rule again gives

\mathcal{L}\{f''(t)\}=s^2F(s)-sf(0)-f'(0).

This is the essential trick: derivatives are replaced by multiplication by s, together with terms containing the initial values.

3. Example One: A First-Order Equation

Consider

y'(t)+2y(t)=6,\qquad y(0)=1.

Write Y(s)=\mathcal{L}\{y(t)\}. Transforming both sides gives

sY(s)-1+2Y(s)=\frac6s.

Collect the terms containing Y(s):

(s+2)Y(s)=1+\frac6s,\qquad Y(s)=\frac{s+6}{s(s+2)}.

Partial fractions turn this into

Y(s)=\frac3s-\frac2{s+2}.

We already know the transforms of a constant and an exponential, so reversing the transform yields

\boxed{y(t)=3-2e^{-2t}.}

Check: y(0)=1, and y'(t)+2y(t)=4e^{-2t}+6-4e^{-2t}=6. The solution approaches the equilibrium value 3 as time increases.

4. Example Two: A Forced, Damped System

A simple model for a damped spring or electrical circuit is

y''(t)+3y'(t)+2y(t)=1,\qquad y(0)=0,\quad y'(0)=0.

The right-hand side is a constant input switched on at t=0. Applying the Laplace transform and inserting the initial conditions gives

(s^2+3s+2)Y(s)=\frac1s.

Factor the quadratic:

Y(s)=\frac1{s(s+1)(s+2)}.

Decomposing into partial fractions,

Y(s)=\frac1{2s}-\frac1{s+1}+\frac1{2(s+2)}.

Therefore

\boxed{y(t)=\frac12-e^{-t}+\frac12e^{-2t}=\frac12(1-e^{-t})^2.}

The response begins at rest and gradually approaches 1/2. The two decaying exponentials represent the system’s transient response. Notice that we solved a second-order differential equation by factoring a polynomial and performing partial fractions.

5. A Small Transform Table

Function f(t) Laplace transform F(s)
1 1/s
e^{at} 1/(s-a)
\sin(\omega t) \omega/(s^2+\omega^2)
\cos(\omega t) s/(s^2+\omega^2)
f'(t) sF(s)-f(0)

These formulas hold where the relevant integrals converge. Together with linearity and partial fractions, they already solve many elementary initial-value problems.

6. How Is This Related to the Z-Transform?

The Z-transform acts on sequences and turns shifts into algebraic expressions. The Laplace transform acts on functions of continuous time and turns derivatives into algebraic expressions. Both methods replace a problem about change with a problem about rational functions.

In digital signal processing we often study recurrences; in continuous-time models we often study differential equations. The common strategy is transform, solve algebraically, then transform back.

7. Try It Yourself

Use the Laplace transform to solve

y'(t)+3y(t)=9,\qquad y(0)=0.
Show solution

Taking transforms gives (s+3)Y(s)=9/s, so

Y(s)=\frac9{s(s+3)}=\frac3s-\frac3{s+3}.

Hence \boxed{y(t)=3(1-e^{-3t}).}

Earlier articles in the series Mathematical Transforms and Their Applications:

Continue exploring: The same transform can also add up an infinite series: Can a Laplace Transform Sum an Infinite Series?

Leave a Reply

Your email address will not be published. Required fields are marked *