ENع
←From s-plane to z-plane
Lesson 38 · The Z-transform

From the s-plane to the z-plane

16 min10 steps5 questionsAdvanced
About this lesson

Analog systems keep their poles in the s-plane; digital systems keep them in the z-plane. Sampling joins the two with one rule, z = e^(sT). Follow an RC filter (pole at −1000 s⁻¹) as it is sampled every 0.25 ms: its pole lands at z = 0.7788. Then watch the whole plane fold: decay becomes distance from the centre, frequency becomes angle, the jω axis wraps onto the unit circle, the stable left half-plane lands inside it, and points 2π/T apart collide (aliasing). The Laplace transform itself is taught in the Circuits lesson on Laplace analysis.

You'll learn to

Tick what you feel confident about. These self-checks do not affect your lesson score.

Fig 38 · Interactive
01 / 10

An analog filter has a pole

An RC low-pass filter with R = 1 kΩ and C = 1 µF has τ = RC = 1 ms. Its transfer function H(s) = 1/(1 + sτ) has one pole, s = −1/τ = −1000 s⁻¹, left of the jω axis: stable.

R = 1 kΩ,  C = 1 µF
τ = RC = 1000 Ω × 0.000001 F = 0.001 s = 1 ms

H(s) = 1 / (1 + s·τ)
pole: 1 + s·τ = 0  ->  s = −1/τ = −1000 s⁻¹

s = σ + jω   (a complex frequency)
σ = −1000 s⁻¹ < 0: left half-plane, stable

Laplace transforms and H(s): see the Circuits
lesson "Circuit analysis with the Laplace transform"
Loading figure…
or ← →
Read the lesson step by step
  1. An analog filter has a pole

    An RC low-pass filter with R = 1 kΩ and C = 1 µF has τ = RC = 1 ms. Its transfer function H(s) = 1/(1 + sτ) has one pole, s = −1/τ = −1000 s⁻¹, left of the jω axis: stable.

    R = 1 kΩ,  C = 1 µF
    τ = RC = 1000 Ω × 0.000001 F = 0.001 s = 1 ms
    
    H(s) = 1 / (1 + s·τ)
    pole: 1 + s·τ = 0  ->  s = −1/τ = −1000 s⁻¹
    
    s = σ + jω   (a complex frequency)
    σ = −1000 s⁻¹ < 0: left half-plane, stable
    
    Laplace transforms and H(s): see the Circuits
    lesson "Circuit analysis with the Laplace transform"
  2. Sample its impulse response

    Kick the filter with an impulse and it answers h(t) = (1/τ)·e^(−t/τ). A sampler reads it every T = 0.25 ms (4000 samples a second). Scaled by T, the samples are h[n] = T·h(nT) = 0.25·e^(−n/4).

    h(t) = (1/τ)·e^(−t/τ),  t > 0   (τ = 1 ms)
    T = 0.25 ms  ->  fs = 1/T = 4000 samples/s
    
    h[n] = T·h(nT) = (T/τ)·e^(−nT/τ) = 0.25·e^(−n/4)
     h[0] = 0.250
     h[1] = 0.195
     h[2] = 0.152
     h[3] = 0.118
     h[4] = 0.092
    
    this is "impulse invariance": the digital
    impulse response copies the analog one
  3. Each sample is r times the last

    Divide a sample by the one before: h[1]/h[0] = 0.1947/0.2500 = 0.7788. Every pair gives the same ratio r = e^(−T/τ). A list 0.25·rⁿ has H(z) = 0.25/(1 − r·z⁻¹): one pole, at z = 0.7788.

    h[n+1] / h[n] = e^(−T/τ) = e^(−0.25) = 0.7788
    
    h[n] = 0.25·rⁿ  (n ≥ 0),   r = 0.7788
    
    H(z) = Σ h[n]·z⁻ⁿ = 0.25 · Σ (r·z⁻¹)ⁿ
         = 0.25 / (1 − r·z⁻¹)      for |z| > r
    
    pole: z = r = 0.7788   (inside |z| = 1)
    zero: z = 0
    
    as a filter:  y[n] = 0.7788·y[n−1] + 0.25·x[n]
  4. The rule: z = e^(sT)

    The analog pole s = −1000 s⁻¹ became the digital pole z = e^(−1000 × 0.00025) = e^(−0.25) = 0.7788. Not by luck: sampling e^(st) every T gives (e^(sT))ⁿ. So each pole s lands at z = e^(sT).

    a pole s_k in H(s) gives a term e^(s_k·t) in h(t)
    sample it:  e^(s_k·nT) = (e^(s_k·T))ⁿ
    a geometric list with ratio e^(s_k·T)
    
    so the pole moves to   z_k = e^(s_k·T)
    
    here: s = −1000 s⁻¹, T = 0.00025 s
          z = e^(−0.25) = 0.7788
    
    every point of the s-plane has an image
    in the z-plane
  5. σ sets the distance from the centre

    Write s = σ + jω. Then z = e^(σT)·e^(jωT), so |z| = e^(σT). Slide σ from −3000 to +1000 s⁻¹ and z slides from 0.47 to 1.28. At σ = 0 it crosses the unit circle: |z| = 1.

    z = e^(sT) = e^(σT) · e^(jωT)
          |z| = e^(σT)      ∠z = ωT
    
    σ = −3000 s⁻¹  ->  |z| = e^(−0.75) = 0.47
    σ = −1000 s⁻¹  ->  |z| = e^(−0.25) = 0.7788
    σ =     0      ->  |z| = e^0       = 1
    σ = +1000 s⁻¹  ->  |z| = e^(+0.25) = 1.28
    
    faster decay (more negative σ)
    = closer to the centre z = 0
  6. ω sets the angle

    The angle of z is ωT radians. Climb the jω axis (σ = 0) from 0 to π/T = 12 566 rad/s, a frequency of 2000 Hz, half the sampling rate. z runs round the unit circle from 1 to −1.

    on the jω axis σ = 0, so |z| = 1 always:
    the jω axis maps onto the unit circle
    
    ∠z = ωT
    ω = 0              ->  z = 1      (DC)
    ω = π/(2T)         ->  z = j      (1000 Hz)
    ω = π/T            ->  z = −1     (2000 Hz)
       = 12 566 rad/s     = fs/2, the Nyquist frequency
    
    so H(z) on the circle is the frequency response
  7. Every 2π/T the map repeats

    Climb further at σ = −500 s⁻¹ and z circles at radius 0.8825. At ω = 2π/T (a jump of 4000 Hz) it is back where it started. Points 2π/T apart land on the same z: aliasing, seen in the plane.

    e^((s + j2π/T)·T) = e^(sT) · e^(j2π) = e^(sT)
    
    σ = −500 s⁻¹:  |z| = e^(−0.125) = 0.8825
    ω: 0 -> 2π/T = 25.13 krad/s  (0 -> 4000 Hz)
    ∠z: 0° -> 360°  (once round)
    
    one horizontal strip  −π/T < ω ≤ π/T
    already covers the whole z-plane;
    every other strip lands on top of it
    (the same reason sampling aliases frequencies)
  8. Stable stays stable

    A left-half-plane point has σ < 0, so |z| = e^(σT) < 1: the stable half-plane folds inside the unit circle, the right half outside. So a stable analog filter, sampled this way, gives a stable digital one.

    s-plane            ->  z-plane
    σ < 0 (left half)   ->  |z| < 1 (inside)
    σ = 0 (jω axis)     ->  |z| = 1 (unit circle)
    σ > 0 (right half)  ->  |z| > 1 (outside)
    
    analog stable:   every pole has σ < 0
    digital stable:  every pole has |z| < 1
    (see "Stability and the unit circle")
    
    RC pole: −1000 s⁻¹  ->  0.7788  stable both ways
  9. A ringing pole pair

    A pole pair s = −500 ± j2π·500 s⁻¹ decays and rings at 500 Hz. Its images sit at radius e^(−500 × 0.00025) = 0.8825 and angles ±2π·500 × 0.00025 = ±π/4 = ±45°. Decay sets the radius; ringing sets the angle.

    s = −500 ± j·3141.6 s⁻¹  (ω = 2π·500)
    
    |z| = e^(σT) = e^(−0.125)       = 0.8825
    ∠z  = ωT = 3141.6 × 0.00025     = π/4 = 45°
    
    z = 0.8825·e^(±jπ/4) = 0.624 ± j0.624
    
    the pair stays a mirror pair (conjugates),
    so the digital filter still has real coefficients
    500 Hz / 4000 Hz = 1/8 of a turn per sample
  10. The map in Python

    numpy's exp works on complex numbers, so the whole map is one line: z = np.exp(s*T). For the ringing pole it gives |z| = 0.8825 and an angle of 45.0°; for the RC pole s = −1000, 0.7788.

    import numpy as np
    T = 1/4000
    s = -500 + 2j*np.pi*500
    z = np.exp(s*T)
    
    >>> print(z.round(3))
    (0.624+0.624j)
    >>> print(abs(z).round(4), np.angle(z, deg=True).round(1))
    0.8825 45.0
    >>> print(np.exp(-1000*T).round(4))
    0.7788
    
    (Python 3 with numpy)

Quiz Unlocks after the last step.