Skip to content
Tutorials Center
My learning

Topics

Lesson 16 of 39 ยท Laplace Transforms

Inverse Laplace Transforms and Partial Fractions

Invert Laplace transforms by matching the table: partial fractions for distinct, repeated and complex poles, completing the square, with SymPy and NumPy residue checks.

After solving an ODE in the s domain you are left with a rational function Y(s) = P(s)/Q(s). The last step is the inverse Laplace transform y(t) = L^(-1){Y(s)}: find the time function whose transform is Y. In practice that means rewriting Y as a sum of the simple pieces in the transform table and reading off the answer. The tool is partial fraction decomposition, which you may know from integration.

Reading the table backwards

Some inversions are direct: L^(-1){1/(s - 3)} = e**(3*t), L^(-1){2/s**3} = t**2, L^(-1){5/(s**2 + 25)} = sin(5*t). Linearity lets you invert term by term. Keep two shortcuts in mind:

  • L^(-1){n!/(s - a)**(n+1)} = t**n*e**(a*t),
  • L^(-1){F(s - a)} = e**(a*t)*f(t) (first shift).

Case 1: distinct real poles

If Q(s) has distinct real roots r1, ..., rn and deg P < deg Q, write

P(s)/Q(s) = A1/(s - r1) + ... + An/(s - rn),

so y(t) = A1*e**(r1*t) + ... + An*e**(rn*t). The coefficients are found by the cover-up rule: Ak = P(rk)/Q'(rk), i.e. cover the factor (s - rk) and evaluate the rest at s = rk.

Example: Y = (3*s + 5)/((s + 1)*(s + 3)). A1 = (3*(-1) + 5)/(-1 + 3) = 1, A2 = (3*(-3) + 5)/(-3 + 1) = 2. So y = e**(-t) + 2*e**(-3*t).

Python Partial fractions and the cover-up rule

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Case 2: repeated poles

A pole of multiplicity m at r needs one term per power: A1/(s - r) + A2/(s - r)**2 + ... + Am/(s - r)**m. Each higher power inverts to a t**k*e**(r*t) term. Example: Y = 1/((s + 2)**2*(s - 1)). Decomposition: 1/9/(s - 1) - 1/9/(s + 2) - 1/3/(s + 2)**2. Inverse: y = (1/9)*e**t - (1/9)*e**(-2*t) - (1/3)*t*e**(-2*t).

Case 3: complex poles (completing the square)

An irreducible quadratic like s**2 + 2*s + 5 has complex roots -1 ยฑ 2i. Do not factor into complex linear terms; instead complete the square: s**2 + 2*s + 5 = (s + 1)**2 + 4. Then match

(s - a)/((s - a)**2 + w**2) -> e**(a*t)*cos(w*t) and w/((s - a)**2 + w**2) -> e**(a*t)*sin(w*t).

Example: Y = (2*s + 3)/(s**2 + 2*s + 5). Write the numerator as 2*(s + 1) + 1; then Y = 2*(s + 1)/((s + 1)**2 + 4) + (1/2)*2/((s + 1)**2 + 4), giving y = e**(-t)*(2*cos(2*t) + (1/2)*sin(2*t)).

In a partial fraction expansion with such a factor, use the numerator A*s + B: for Y = 1/(s*(s**2 + 4)) write A/s + (B*s + C)/(s**2 + 4). You find A = 1/4, B = -1/4, C = 0, so y = 1/4 - (1/4)*cos(2*t).

Python Complex poles: complete the square

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Poles tell you everything

The poles of Y(s) (roots of the denominator) control the long-term behavior:

  • a pole at s = r real gives e**(r*t);
  • a pair a ยฑ i*w gives e**(a*t)*(cos, sin)(w*t);
  • a repeated pole adds powers of t.

So the solution decays to zero if and only if all poles have negative real part: the stability criterion of control theory. You can read it from Q(s) without inverting at all.

Numerical partial fractions

For high-degree denominators use software. scipy.signal.residue returns residues r, poles p and the direct term for P/Q; each pair gives r*e**(p*t).

Python Residues with scipy.signal

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Strategy summary

  1. Check deg P < deg Q; otherwise divide first (a polynomial part corresponds to impulses).
  2. Factor Q(s) into linear factors and irreducible quadratics.
  3. Decompose; complete the square in each quadratic.
  4. Invert term by term using the table and shifts.
  5. Sanity check: y(0) should equal the limit s*Y(s) as s -> infinity (initial value theorem).

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. What is L^(-1){1/(s + 4)}?

    1/(s - a) corresponds to e**(a t); here a = -4.
  2. 2. To invert (s + 2)/(s**2 + 4s + 13), first

    The denominator has complex roots; writing it as (s+2)2 + 32 matches the shifted cos table entry, giving e**(-2t) cos 3t.
  3. 3. The inverse transform of 1/(s - 1)**2 is

    L{t e**(a t)} = 1/(s - a)**2, here with a = 1.
  4. 4. A solution decays to zero if all poles of Y(s) have

    Each pole a + ib contributes e**(a t) factors, which decay only if a < 0.

Summary

  • Invert by rewriting Y(s) into table forms using partial fractions.
  • Distinct real poles give exponentials (cover-up rule); repeated poles add powers of t.
  • Irreducible quadratics: complete the square and use shifted sine/cosine entries.
  • Poles in the left half-plane mean decaying solutions.
  • scipy.signal.residue and SymPy's apart and inverse_laplace_transform check your work.

Next: Solving ODEs with Laplace Transforms