Flow Lab

Syllabus / Module 6: Laplace Transforms

Lesson 6.5

Convolution & Transfer Functions

Convolution integral, the convolution theorem, transfer functions, poles and zeros, and response to arbitrary inputs.

Written byClaude Sonnet

🌊
Why this matters for simulation: Transfer functions are the bridge to the Control Systems module and autopilot design.

By the end of this lesson you can…

  • Write the response to any input as the convolution $y = h * u$ of the input with the impulse response, and explain it as a sum of delayed, scaled impulse responses (the flip-and-slide picture).
  • State the convolution theorem $\mathcal L\{f*g\} = F(s)G(s)$, reproduce its proof sketch by swapping the order of integration, and say which step is sketched rather than proved.
  • Find the transfer function $H(s) = 1/P(s)$ of a linear ODE with zero initial conditions, and read the poles, the zeros and the mode each one contributes.
  • Decide BIBO stability from pole locations, including the honest cases of poles on the imaginary axis and of repeated poles.
  • Evaluate $H(i\omega)$ to get the gain and phase lag of a sine input, and check it against the forced-oscillation numbers.
  • Compute a convolution on a grid with np.convolve, scale it by the step, and measure its error against an ODE solver.
On this page
·
  1. Convolution: a stack of delayed blows
  2. The convolution theorem
  3. Impulse response and transfer function
  4. Stability from the poles
  5. The frequency response
  6. Block diagrams, a preview
  7. Sliding a kernel across an input
  8. A grid cannot be convolved naively
  9. Computing it
  10. Concept checks
  11. Problems
  12. Module recap: what Laplace gave us
  13. Key Takeaways

6.4 Impulses & the Dirac Delta ended with an integral, x(t)=∫0th(t−τ)F(τ) dτx(t) = \int_0^t h(t-\tau)F(\tau)\,d\tau: the response of a linear system to any force is built from its response to a single hammer blow. A flight simulator uses exactly this when it asks how an airframe answers a gust. This lesson names the integral (a convolution), shows that the Laplace transform turns it into a plain product, and uses that to define the transfer function H(s)H(s) with its poles and zeros. The product form is why 6.2 Solving Initial Value Problems was algebra, and it is the language of the Control module. Our running system is the one from 5.6 Forced Oscillations & Resonance: m=0.4m = 0.4, c=0.4c = 0.4, k=10k = 10.

▶ Video Flip and slide: the shaded product area builds the output, the convolution theorem, poles and zeros on the s-plane, stability, the frequency response, and discrete convolution on a gridcaptions only
Transcript
  1. Any input can be chopped into thin slices. The slice at time tau is a blow of strength u of tau d tau. It rings as the impulse response h, delayed by tau and scaled by the blow. A linear system adds all of these responses, and that sum is the convolution.
  2. Flip g about zero, slide it right by t, multiply by f and take the area. Here f is e to the minus t and g is e to the minus 2 t. The latest input meets the earliest part of g. At t equals 1 the area is 0.232544.
  3. The convolution theorem: the transform of f star g is F times G. Write it as a double integral over a triangle, slice the triangle the other way, and substitute sigma equals t minus tau. The swap is the sketched step. Block A: 0.232546 against 0.232544, and 0.166660 against 0.166667.
  4. With zero initial conditions, P of s times Y equals U, so Y equals H times U, where H is one over P of s. For our spring, h is e to the minus t over 2 times sine omega d t over m omega d, with omega d 4.974937 and one over m omega d 0.502519.
  5. Each pole is a mode of h. A real pole at minus a gives e to the minus a t, and a complex pair gives a decaying sine. Our poles are minus 0.5 plus or minus 4.974937 i, in the left half-plane, so the ringing dies out.
  6. A zero adds no mode, it reweights them. Take H equal to s plus 3 over s squared plus 2 s plus 5: the output is z prime plus 3 z. It has the same decay and frequency as e to the minus t sine 2 t, but a different phase and size.
  7. A system is BIBO stable when bounded inputs give bounded outputs, exactly when every pole has negative real part. A right half-plane pole makes h grow. A pole on the imaginary axis never decays, so it is not stable. A repeated one gives t to the j growth.
  8. How hard can a bounded input push a stable system? By the integral of absolute h: 0.638682 here, while a unit step settles at only H of 0, 0.1. The ratio is 6.387, about 6.4. The input sign of h of 10 minus t reaches y of 10 equal 0.634509, the integral up to 10.
  9. Drive the system with sine omega t. A stable system settles to a sine at the same frequency, scaled and shifted by H at s equals i omega. At omega 2, 5 and 10 the gain times k is 1.185114, 5, and 0.330409, with lags 0.094952, 1.570796 and 3.009041.
  10. On a grid, convolution is np.convolve of u and h, cut to n and scaled by dt. It counts both end terms in full; the trapezoid rule halves them. For a unit step the error is dt over 2 times h, largest at the peak 0.4313: 4.31, 2.16 and 1.08 times 10 to the minus 3.
  11. Against solve i v p, the plain errors are 4.23, 2.14 and 1.07 times 10 to the minus 3, ratios 1.98 and 1.99: first order. Halved end terms give 1.45 times 10 to the minus 4, 3.63 times 10 to the minus 5 and 9.08 times 10 to the minus 6, ratios 4.00: second order.
  12. A preview of block diagrams. Series blocks multiply: H2 times H1. In a feedback loop Y equals H times U minus G Y, so Y over U is H over 1 plus H G. The closed-loop poles are the roots of 1 plus H G, not of H, so feedback moves the poles.
  13. To sum up. A convolution stacks delayed, scaled impulse responses, and the transform turns it into a product. The transfer function one over P of s has poles that give the modes and the stability, and on the imaginary axis it is the frequency response. Next: systems of ODEs.

Convolution: a stack of delayed blows

Chop the input into thin slices of width dτd\tau. The slice at time τ\tau is a blow of strength u(τ) dτu(\tau)\,d\tau, which rings as u(τ) dτ  h(t−τ)u(\tau)\,d\tau\;h(t-\tau) at later time tt: the impulse response, scaled by the blow and delayed by τ\tau. A linear system adds these responses (the “repeated blows” of the last lesson, with a continuum of blows):

y(t)=∫0tu(τ) h(t−τ) dτ=:(u∗h)(t).y(t) = \int_0^t u(\tau)\,h(t-\tau)\,d\tau =: (u * h)(t) .

That is the definition of the convolution (f∗g)(t)=∫0tf(τ) g(t−τ) dτ(f*g)(t) = \int_0^t f(\tau)\,g(t-\tau)\,d\tau. It is the same integral as the Green’s function formula of 5.5 Variation of Parameters, which there came from a different derivation: for constant coefficients the kernel depends only on the elapsed time t−τt-\tau. We cut it at τ=0\tau = 0 because inputs start at t=0t = 0, and at τ=t\tau = t because h=0h = 0 for negative argument (a blow cannot ring before it lands, causality).

Flip and slide. To evaluate y(t0)y(t_0), flip hh about τ=0\tau = 0 to get h(−τ)h(-\tau), slide it right by t0t_0 to get h(t0−τ)h(t_0 - \tau), multiply by u(τ)u(\tau) pointwise and take the signed area. The flip is the whole mystery: the latest input gets the earliest part of hh, because the blow that just landed has barely begun to ring, while an old one is deep into its decay. In the sim, drag t0t_0: the shaded product is the integrand, and its signed area is the dot on the output curve.

Two things follow at once. Commutativity: substitute σ=t−τ\sigma = t - \tau and the integral becomes ∫0tf(t−σ)g(σ) dσ\int_0^t f(t-\sigma)g(\sigma)\,d\sigma, so f∗g=g∗ff * g = g * f (a full proof, one line). Input and system may swap roles. And, in the numerics below, the discrete version is exactly a loop you have written: yn=∑juj hn−j Δty_n = \sum_j u_j\,h_{n-j}\,\Delta t.

The convolution theorem

The step from integral to algebra is

L{f∗g}=F(s) G(s).\mathcal L\{f*g\} = F(s)\,G(s) .

Proof sketch. Write the transform of the convolution as a double integral over the triangle 0≤τ≤t0 \le \tau \le t:

∫0∞e−st∫0tf(τ)g(t−τ) dτ dt=∫0∞f(τ)∫τ∞e−st g(t−τ) dt dτ.\int_0^\infty e^{-st}\int_0^t f(\tau)g(t-\tau)\,d\tau\,dt = \int_0^\infty f(\tau)\int_\tau^\infty e^{-st}\,g(t-\tau)\,dt\,d\tau .

The right side is the same triangle sliced the other way (fix τ\tau, let tt run from τ\tau upward). In the inner integral put σ=t−τ\sigma = t - \tau: it becomes e−sτ∫0∞e−sσg(σ) dσ=e−sτG(s)e^{-s\tau}\int_0^\infty e^{-s\sigma}g(\sigma)\,d\sigma = e^{-s\tau}G(s). What remains is ∫0∞f(τ)e−sτG(s) dτ=F(s)G(s)\int_0^\infty f(\tau)e^{-s\tau}G(s)\,d\tau = F(s)G(s). The algebra and the substitution are fully proved. The swap of the order of integration is the sketched step: it is justified (Fubini) when ff and gg are piecewise continuous and of exponential order and ss is large enough that both integrals converge absolutely, a standard fact quoted here from memory, not proved.

Example. f=e−tf = e^{-t}, g=e−2tg = e^{-2t}. Then (f∗g)(t)=∫0te−τe−2(t−τ)dτ=e−2t∫0teτdτ=e−t−e−2t(f*g)(t) = \int_0^t e^{-\tau}e^{-2(t-\tau)}d\tau = e^{-2t}\int_0^t e^{\tau}d\tau = e^{-t} - e^{-2t}, and its transform 1s+1−1s+2=1(s+1)(s+2)=F G\frac{1}{s+1} - \frac{1}{s+2} = \frac{1}{(s+1)(s+2)} = F\,G. At t=1t = 1 the value is 0.2325440.232544. Block A of the lab computes it with the discrete sum, then takes the Laplace integral of the numerical f∗gf*g at s=1s = 1 and compares it with F(1)G(1)=1/6F(1)G(1) = 1/6.

Impulse response and transfer function

For P(D)y=uP(D)y = u with P(s)=ms2+cs+kP(s) = ms^2 + cs + k and zero initial conditions, the transform is P(s)Y(s)=U(s)P(s)Y(s) = U(s), so

Y(s)=H(s) U(s),H(s)=1P(s)=L{h}.Y(s) = H(s)\,U(s), \qquad H(s) = \frac{1}{P(s)} = \mathcal L\{h\} .

Two descriptions of one fact. In time, y=h∗uy = h * u; in the ss-domain, Y=H UY = H\,U; the convolution theorem links them, and L{δ}=1\mathcal L\{\delta\} = 1 shows HH is the output when the input is a delta. Zero initial conditions matter: initial data adds the zero-input part from 6.2 Solving Initial Value Problems, which the transfer function does not describe. For our system P(s)=0.4(s2+s+25)P(s) = 0.4(s^2 + s + 25), so h(t)=e−t/2sin⁡(ωdt)m ωdh(t) = \dfrac{e^{-t/2}\sin(\omega_d t)}{m\,\omega_d} with ωd=24.75=4.974937\omega_d = \sqrt{24.75} = 4.974937 and 1/(mωd)=0.5025191/(m\omega_d) = 0.502519.

Poles and zeros. A rational H(s)=N(s)/D(s)H(s) = N(s)/D(s) has poles where D=0D = 0 and zeros where N=0N = 0. Each pole gives a mode in hh: a real pole at −a-a gives e−ate^{-at}, a complex pair at −α±iβ-\alpha \pm i\beta gives e−αtsin⁡βte^{-\alpha t}\sin\beta t, as in the pole plot of 6.2 Solving Initial Value Problems. Our poles are −0.5±4.974937i-0.5 \pm 4.974937i. A zero does not add a mode. It reweights them. Try H=(s+3)/(s2+2s+5)H = (s+3)/(s^2+2s+5) in the sim (“with a zero”): H=(s+3)ZH = (s+3)Z with Z=1/(s2+2s+5)Z = 1/(s^2+2s+5), so y=z′+3zy = z' + 3z, where zz is the output of the zero-free system. The zero asks the output to include the velocity of zz, and h=e−t(cos⁡2t+sin⁡2t)h = e^{-t}(\cos 2t + \sin 2t) has the same decay and frequency as e−tsin⁡2te^{-t}\sin 2t with a different phase and size.

Stability from the poles

Call a system BIBO stable (bounded input, bounded output) if every bounded uu gives a bounded yy. Since ∣y(t)∣≤∫0t∣u(τ)∣∣h(t−τ)∣ dτ≤max⁡∣u∣∫0∞∣h∣|y(t)| \le \int_0^t |u(\tau)||h(t-\tau)|\,d\tau \le \max|u|\int_0^\infty |h|, the condition ∫0∞∣h∣ dt<∞\int_0^\infty |h|\,dt \lt \infty is sufficient. It is also necessary (choose u(τ)=sign⁡h(t−τ)u(\tau) = \operatorname{sign} h(t-\tau), which makes the integrand ∣h∣|h| exactly; the mechanism is in block B, and the “only if” step is stated here, not proved in general). For a rational HH in lowest terms the integral is finite exactly when every pole has negative real part: each mode tjeλtt^j e^{\lambda t} with Re⁡λ<0\operatorname{Re}\lambda \lt 0 is integrable and each with Re⁡λ≥0\operatorname{Re}\lambda \ge 0 is not. The honest cases:

  • Pole in the right half-plane (real part >0\gt 0): hh grows exponentially, the system is unstable. In the sim, H=1/(s−0.5)H = 1/(s - 0.5) has h=et/2h = e^{t/2}.
  • Simple pole on the imaginary axis: hh neither grows nor decays. The system is not BIBO stable, even though many inputs give bounded outputs. Push H=1/(s2+4)H = 1/(s^2+4) with sin⁡2t\sin 2t, at its own frequency, and the output at t=10t = 10 is −0.9061-0.9061 with an envelope growing like t/4t/4 (resonance, from 5.6 Forced Oscillations & Resonance); the sim shows it.
  • Repeated pole on the axis: even worse, tjt^j growth. 1/s21/s^2 is a double integrator; a bounded step makes a parabola.
  • Left half-plane: everything decays, the system is BIBO stable. How much a bounded input can excite it is the number ∫∣h∣\int|h|: for our spring it is 0.6386820.638682, while a unit step settles at only H(0)=0.1H(0) = 0.1, so the worst-case input beats the step by about 6.46.4.

One caveat, from memory: if a pole cancels a zero in N/DN/D, the transfer function hides that mode, but the mode can still be excited by initial data. “Lowest terms” in the statement above is doing real work, and it is one reason the state-space view of the next module matters.

The frequency response

Take u=sin⁡ωtu = \sin\omega t. The transform of the output has poles of HH and the poles ±iω\pm i\omega of UU. For a stable system the HH modes fade, and the response left at long times is a sine at the same frequency, scaled and shifted by HH evaluated at s=iωs = i\omega:

yss(t)=∣H(iω)∣ sin⁡(ωt−φ),φ=−arg⁡H(iω).y_{ss}(t) = |H(i\omega)|\,\sin\bigl(\omega t - \varphi\bigr), \qquad \varphi = -\arg H(i\omega) .

Mechanism: a sine is a combination of e±iωte^{\pm i\omega t}, and the response of a linear system to este^{st} is H(s)estH(s)e^{st} (put it into the convolution: ∫h(τ)es(t−τ)dτ=estH(s)\int h(\tau)e^{s(t-\tau)}d\tau = e^{st}H(s)), so the complex number H(iω)H(i\omega) is the gain and phase. For P(iω)=k−mω2+icωP(i\omega) = k - m\omega^2 + ic\omega:

∣H(iω)∣=1(k−mω2)2+(cω)2,tan⁡φ=cωk−mω2.|H(i\omega)| = \frac{1}{\sqrt{(k - m\omega^2)^2 + (c\omega)^2}}, \qquad \tan\varphi = \frac{c\omega}{k - m\omega^2} .

The forced-oscillations lesson scales gain by the static deflection, so its gain is k ∣H(iω)∣k\,|H(i\omega)|. At ω=2\omega = 2: P(2i)=8.4+0.8iP(2i) = 8.4 + 0.8i, ∣P∣=8.438|P| = 8.438, k∣H∣=10/8.438=1.185114k|H| = 10/8.438 = 1.185114 and φ=arctan⁡(0.8/8.4)=0.094952\varphi = \arctan(0.8/8.4) = 0.094952, which is the first row of that lesson’s table (gain 1.1851141.185114, lag 0.0949520.094952 at r=0.4r = 0.4). At ω=5\omega = 5: P=2iP = 2i, gain 55, lag π/2\pi/2. Block B simulates the ODE and fits the tail of the run, and the sim’s sine mode reads the same numbers off the live run. So H(s)H(s) along the imaginary axis is the amplitude and phase curves of that lesson. Control design in the frequency domain (Bode plots, from memory) plots exactly these two functions.

Block diagrams, a preview

The product form means that connecting systems means multiplying. Two blocks in series give H2H1H_2H_1 (their impulse responses convolve). In a feedback loop, the plant HH is driven by the input minus a fraction GG of its own output: Y=H(U−GY)Y = H(U - GY), so Y(1+HG)=HUY(1 + HG) = HU and

YU=H1+HG.\frac{Y}{U} = \frac{H}{1 + HG} .

The derivation is one line of algebra; what it means for poles is the Control module’s subject (13.1 Feedback & Block Diagrams and 13.2 Transfer Functions & Time Response). The closed-loop poles are the roots of 1+HG=01 + HG = 0, not of HH: feedback moves the poles, which is how an unstable airframe is stabilised.

Sliding a kernel across an input

◆ Interactive Slide t0 and watch the flipped impulse response build the output; read the poles and the live frequency response

Loading simulation…

The four panels are the flipped-and-slid product, the output it builds, the pole-zero map (green when every pole is in the left half-plane) and hh with its step response. The readout compares the convolution with an independent RK4 solution of the same ODE. For the spring with a step input at t0=1t_0 = 1 the area is 0.0901410.090141 against 0.0901450.090145 from RK4, a gap of 4×10−64\times10^{-6}, and the step response heads for H(0)=0.1H(0) = 0.1. In sine mode on the spring at ω=2\omega = 2 the live measurement agrees with the formula to six places and shows the gain and lag above. Switch to the pulse input: the gap grows to about 7×10−47\times10^{-4}, because a jump in uu costs a first-order error in both methods, a hint of what block C measures.

A grid cannot be convolved naively

In code, uu and hh become arrays sampled every Δt\Delta t and the integral is np.convolve(u, h)[:n] * dt, the loop above with the loop hidden. This is cheap to write and has two honest costs.

Accuracy. np.convolve computes Δt∑j=0nujhn−j\Delta t\sum_{j=0}^{n}u_jh_{n-j}, a Riemann sum that counts both end terms in full, where the trapezoid rule halves them. The extra half-terms are Δt2(u0hn+unh0)\tfrac{\Delta t}{2}(u_0h_n + u_nh_0), and h0=0h_0 = 0 for our system. So the error is first order in Δt\Delta t when u(0)≠0u(0) \ne 0 and second order when u(0)=0u(0) = 0. For the unit step, u0=1u_0 = 1 and the leading error is Δt2h(tn)\tfrac{\Delta t}{2}h(t_n), largest where ∣h∣|h| peaks at 0.43130.4313: a prediction of 4.31×10−34.31\times10^{-3}, 2.16×10−32.16\times10^{-3} and 1.08×10−31.08\times10^{-3} at Δt=0.02,0.01,0.005\Delta t = 0.02, 0.01, 0.005. Block C measures the maximum error over [0,10][0,10] against solve_ivp at tight tolerance: 4.23×10−34.23\times10^{-3}, 2.14×10−32.14\times10^{-3}, 1.07×10−31.07\times10^{-3}, observed ratios 1.981.98 and 1.991.99. Halve the end terms and the same run gives 1.45×10−41.45\times10^{-4}, 3.63×10−53.63\times10^{-5}, 9.08×10−69.08\times10^{-6}, ratios 4.004.00 and 4.004.00. For u=sin⁡3tu = \sin 3t, where u(0)=0u(0) = 0, plain np.convolve already gives 1.15×10−41.15\times10^{-4}, 2.88×10−52.88\times10^{-5}, 7.21×10−67.21\times10^{-6} (ratios 4.004.00, 4.004.00), the same as the corrected sum. At Δt=0.005\Delta t = 0.005 the plain step-input value y(1)y(1) is 0.0894050.089405 against 0.0901450.090145, off by −0.00074=Δt2h(1)-0.00074 = \tfrac{\Delta t}{2}h(1) with h(1)=−0.294348h(1) = -0.294348.

Cost. Direct convolution of two arrays of length NN costs O(N2)O(N^2) operations. From memory: the FFT turns convolution into pointwise multiplication (the discrete cousin of Y=HUY = HU) and costs O(Nlog⁡N)O(N\log N), which pays off for long signals; scipy.signal.fftconvolve does this. For a few thousand samples the direct form is fine.

Computing it

🐍 PythonLab: the convolution theorem and commutativity on a grid (block A)
⌘/Ctrl + Enter

Block A prints 0.2325460.232546 against 0.2325440.232544 (the difference is the discretisation), 0.1666600.166660 against 0.1666670.166667 for the transform check, and a commutativity gap at rounding level.

🐍 PythonLab: H(i w) against a simulation, and the worst-case bounded input (block B)
⌘/Ctrl + Enter

Block B prints gain 1.1851141.185114, 5.0000005.000000, 0.3304090.330409 and lags 0.0949520.094952, 1.5707961.570796, 3.0090413.009041 both ways (the ω=10\omega = 10 row is the last row of the forced-oscillations table), then ∫060∣h∣=0.638682\int_0^{60}|h| = 0.638682, ratio 6.3876.387 to H(0)=0.1H(0) = 0.1, and y(10)=0.634509=∫010∣h∣y(10) = 0.634509 = \int_0^{10}|h| for the input sign⁡h(10−t)\operatorname{sign}h(10 - t), the mechanism behind the necessity claim.

🐍 PythonLab: np.convolve against the ODE, for a step and a sine, with and without halving the end terms (block C)
⌘/Ctrl + Enter

Block C prints the table above, including the plain step-input y(1)=0.089405y(1) = 0.089405 against the ODE’s 0.0901450.090145 and Δt2h(1)=−0.000736\tfrac{\Delta t}{2}h(1) = -0.000736.

Now do it yourself: the convolution is a four-line function, the error is a measurement.

🧪 Coding exerciseExercise: build h, convolve a step with np.convolve, and measure the error against solve_ivp
⌘/Ctrl + Enter

Concept checks

✅ Concept check

Let $f = 1$ and $g = e^{-t}$. What is $\mathcal L\{f * g\}$ at $s = 1$? (Give a number.)

✅ Concept check

Which transfer function is BIBO stable?

✅ Concept check

For $H(s) = 2/(s+2)$ driven by $\sin 2t$, what is the steady-state amplitude? (Give a number.)

✅ Concept check

You sample $u$ and $h$ every $\Delta t$ into arrays. Which expression approximates $(u * h)(t_n)$ on the grid?

✅ Concept check

A plant $H = 1/(s+1)$ is wrapped in a feedback loop with $G = 4$. Where is the closed-loop pole? (Give a number.)

Problems

✏️ Pen & paperA convolution by hand●○○

Find (1∗e−2t)(t)(1 * e^{-2t})(t) directly and by the convolution theorem, and evaluate it at t=1t = 1.

Show worked solution

Directly, ∫0te−2(t−τ) dτ=∫0te−2σ dσ=12(1−e−2t)\int_0^t e^{-2(t-\tau)}\,d\tau = \int_0^t e^{-2\sigma}\,d\sigma = \tfrac12(1 - e^{-2t}). By the theorem, 1s⋅1s+2=12(1s−1s+2)\frac1s\cdot\frac{1}{s+2} = \frac12\bigl(\frac1s - \frac1{s+2}\bigr), which inverts to the same thing. At t=1t = 1 it is 12(1−e−2)=0.432332\tfrac12(1 - e^{-2}) = 0.432332 (a hand value; the sim’s “lag” system, 2e−2t2e^{-2t} driven by a step, shows twice this, 0.8646720.864672, at t0=1t_0 = 1).

✏️ Pen & paperTransfer function of an ODE●●○

For y′′+4y′+3y=uy'' + 4y' + 3y = u with rest initial conditions, find H(s)H(s), h(t)h(t) and the poles, then say whether it is BIBO stable and what a unit step settles to.

Show worked solution

H=1s2+4s+3=1(s+1)(s+3)=12(1s+1−1s+3)H = \dfrac{1}{s^2 + 4s + 3} = \dfrac{1}{(s+1)(s+3)} = \dfrac12\Bigl(\dfrac{1}{s+1} - \dfrac{1}{s+3}\Bigr), so h(t)=12(e−t−e−3t)h(t) = \tfrac12(e^{-t} - e^{-3t}). The poles are −1-1 and −3-3, both in the left half-plane, so the system is BIBO stable (and ∫0∞h dt=12(1−13)=13=H(0)\int_0^\infty h\,dt = \tfrac12(1 - \tfrac13) = \tfrac13 = H(0)). A unit step settles to H(0)=1/3H(0) = 1/3, the final value of h∗1=∫0thh * 1 = \int_0^t h.

✏️ Pen & paperA frequency response by hand●●○

For H(s)=2/(s+2)H(s) = 2/(s+2) driven by sin⁡2t\sin 2t, find the steady-state amplitude and the phase lag. Check against the sim’s “first-order lag” with the sine input at ω=2\omega = 2.

Show worked solution

H(2i)=22+2i=11+i=1−i2H(2i) = \dfrac{2}{2 + 2i} = \dfrac{1}{1 + i} = \dfrac{1 - i}{2}. The amplitude is ∣H∣=1/2=0.707107|H| = 1/\sqrt2 = 0.707107 and arg⁡H=−π/4\arg H = -\pi/4, so the output is 0.707107sin⁡(2t−π/4)0.707107\sin(2t - \pi/4): lag 0.7853980.785398 rad, a 18\tfrac18 cycle. The sim reads ∣H(iω)∣|H(i\omega)| and lag the same way and measures them from the live run. Mechanism: at s=2is = 2i the real and imaginary parts of s+2s + 2 are equal, which is a 45∘45^\circ angle and a factor 2\sqrt2 in magnitude.

✏️ Pen & paperFeedback moves a pole●●●

A plant H=1/(s−1)H = 1/(s - 1) is unstable. Put it in a loop with G=KG = K as in H/(1+HG)H/(1 + HG). Find the closed-loop pole, the range of KK that stabilises it, and the pole for K=3K = 3.

Show worked solution

H1+HG=1/(s−1)1+K/(s−1)=1s−1+K\dfrac{H}{1 + HG} = \dfrac{1/(s-1)}{1 + K/(s-1)} = \dfrac{1}{s - 1 + K}, with pole s=1−Ks = 1 - K. It lies in the left half-plane when K>1K \gt 1. For K=3K = 3 the pole is at −2-2. Feedback with a gain just shifts this pole, it does not change its type: this is the simplest stabilisation, and why an unstable airframe can be flown with a controller (see 13.1 Feedback & Block Diagrams).

Module recap: what Laplace gave us

The Laplace module turns calculus into algebra. 6.1 The Laplace Transform defined F(s)=∫0∞e−stf dtF(s) = \int_0^\infty e^{-st}f\,dt and its derivative rule, 6.2 Solving Initial Value Problems made an IVP into P(s)Y=…P(s)Y = \dots with poles that predict the response, 6.3 Step Functions & Discontinuous Forcing and 6.4 Impulses & the Dirac Delta covered switched and instantaneous forcing, and this lesson showed that composition is multiplication: y=h∗u↔Y=HUy = h * u \leftrightarrow Y = HU. The poles of HH tell you the modes, the stability, and, along the imaginary axis, the frequency response. The next module, 7.1 Systems & State Space, leaves the single-equation view: the poles you found here are eigenvalues of a matrix, and the matrix view works for systems far too large for partial fractions.

Key Takeaways

  • The convolution (f∗g)(t)=∫0tf(τ)g(t−τ) dτ(f*g)(t) = \int_0^t f(\tau)g(t-\tau)\,d\tau sums delayed, scaled copies of one function; flip gg, slide it, and take the area of the product. It commutes (substitute σ=t−τ\sigma = t - \tau).
  • For a linear time-invariant system, y=h∗uy = h * u, where hh is the impulse response. This is the Green’s function of variation of parameters for constant coefficients.
  • L{f∗g}=FG\mathcal L\{f*g\} = FG is proved by swapping the order of integration over the triangle 0≤τ≤t0 \le \tau \le t and substituting σ=t−τ\sigma = t - \tau; the swap itself needs exponential order and absolute convergence (quoted from memory).
  • The transfer function is H(s)=1/P(s)=L{h}H(s) = 1/P(s) = \mathcal L\{h\} for zero initial conditions, and Y=HUY = HU. Poles give modes; zeros reweight them.
  • BIBO stability means ∫∣h∣<∞\int|h| \lt \infty, i.e. all poles strictly in the left half-plane. Poles on the axis (simple or repeated) are not BIBO stable, and a pole-zero cancellation can hide an unstable mode.
  • H(iω)H(i\omega) is the frequency response: gain ∣H(iω)∣|H(i\omega)| and lag −arg⁡H(iω)-\arg H(i\omega), which reproduce the forced-oscillation numbers (1.1851141.185114 and 0.0949520.094952 at ω=2\omega = 2).
  • Series blocks multiply; a feedback loop gives H/(1+HG)H/(1+HG) and moves the poles.
  • On a grid, np.convolve(u, h)[:n] * dt approximates the integral. Its error is first order when u(0)≠0u(0) \ne 0 (observed ratios 1.981.98 and 1.991.99) and second order once the end terms are halved (ratios 4.004.00); the direct sum is O(N2)O(N^2), an FFT is O(Nlog⁡N)O(N\log N) (from memory).
Finished this lesson?

Mark it complete to track your progress (saved in this browser). Reading every section does this for you.

Where this leads

These later lessons build directly on this one: