Skip to content

4.P — Worked Problems: Signals and Systems

Problem 1 — Classify a signal

For x(t)=5e^{-2t}u(t): find the energy, the power, and classify it. Then do the same for x(t)=3\cos(100t).

Solution

First signal.

E=\int_0^\infty|5e^{-2t}|^2dt=25\int_0^\infty e^{-4t}dt=25\left[\frac{e^{-4t}}{-4}\right]_0^\infty=\frac{25}{4}=6.25\ \text{J}

Finite energy. Power is energy divided by infinite time, so P=0.

An energy signal.

Second signal. Energy diverges, since \cos^2 does not decay. Power over one period:

P=\frac1T\int_0^T9\cos^2(100t)dt=9\times\frac12=4.5\ \text{W}

using \overline{\cos^2}=\tfrac12.

A power signal.

Why the classification matters. The Fourier transform of the first exists as an ordinary function, 5/(2+j\omega). The second's does not — it needs impulses, 3\pi[\delta(\omega-100)+\delta(\omega+100)]. Knowing which kind of signal you have tells you whether the mathematics will be clean or will need distributions.

Problem 2 — Test a system's properties

Classify y[n]=nx[n] for linearity, time-invariance, causality, stability and memory.

Solution

Linear? With input ax_1+bx_2:

y = n(ax_1[n]+bx_2[n]) = a(nx_1[n])+b(nx_2[n]) = ay_1+by_2 \ ✓

Linear.

Time-invariant?

  • Delayed input: y_1[n] = n\,x[n-k]
  • Delayed output: y_2[n]=y[n-k]=(n-k)x[n-k]

n\,x[n-k] \ne (n-k)x[n-k] \ ✗

Not time-invariant.

Causal? Output at n uses input at n only ✓. Causal.

Stable? Bounded input |x[n]|\le M gives |y[n]|=|n|M, which grows without limit as n increases ✗. Unstable.

Memoryless? Uses only the present input ✓. Memoryless.

The summary is unusual and instructive: linear, causal, memoryless, but neither time-invariant nor stable. Because it is not LTI, none of the impulse-response machinery of Chapters 4.3 to 4.6 applies. There is no transfer function for this system, and any attempt to write one is a mistake.

Problem 3 — Convolution by hand

Convolve x[n]=\{2,1,3\} starting at n=0 with h[n]=\{1,2\}.

Solution

y[n]=\sum_kx[k]h[n-k]

n=0: only k=0. y[0]=2\times1=2

n=1: k=0 gives x[0]h[1]=2\times2=4; k=1 gives x[1]h[0]=1\times1=1. y[1]=5

n=2: k=1 gives 1\times2=2; k=2 gives 3\times1=3. y[2]=5

n=3: k=2 gives 3\times2=6. y[3]=6

y[n]=\{2,5,5,6\}

Check the length: 3+2-1=4 ✓.

Check the area: \sum x=6, \sum h=3, product 18. 2+5+5+6=18 ✓.

Check by polynomial multiplication:

(2+z+3z^2)(1+2z)=2+z+3z^2+4z+2z^2+6z^3=2+5z+5z^2+6z^3 \ ✓

The polynomial check is the fastest way to verify any hand convolution, and it is the same operation as long multiplication without carries.

Problem 4 — Convolution of two rectangles

Convolve two rectangular pulses of height 1: one of width 2 (from 0 to 2) and one of width 3 (from 0 to 3). Sketch the result and give its equation.

Solution

Predict before computing. Widths add: the result runs from 0 to 5. Areas multiply: total area is 2\times3=6. Peak height is the smaller width, 2.

Compute region by region. The flipped 3-wide pulse slides across the 2-wide one.

0\le t\le2 — sliding in. Overlap grows linearly:

y(t)=\int_0^t 1\,d\tau = t

At t=2: y=2 ✓ matching the predicted peak.

2\le t\le3 — fully overlapped. The 2-wide pulse sits entirely inside the 3-wide window:

y(t)=2

A flat top of length 1, which is the difference of the widths.

3\le t\le5 — sliding out:

y(t)=5-t

At t=5: y=0 ✓.

A trapezoid, rising for 2, flat for 1, falling for 2.

Check the area: \tfrac12(2)(2)+2(1)+\tfrac12(2)(2)=2+2+2=6 ✓.

The general result: two rectangles of widths W_1 and W_2 convolve into a trapezoid with total width W_1+W_2, a flat top of width |W_1-W_2|, and height \min(W_1,W_2). When the widths are equal the flat top vanishes and you get a triangle — which is the classic textbook case, and now you can see it is the special case rather than the general one.

Problem 5 — Fourier series of a pulse train

Find the Fourier series coefficients of a rectangular pulse train: amplitude A, pulse width \tau, period T.

Solution

Take the pulse centred on t=0, from -\tau/2 to \tau/2, so the signal is even and only cosines appear.

c_n=\frac1T\int_{-\tau/2}^{\tau/2}Ae^{-jn\omega_0t}dt = \frac AT\left[\frac{e^{-jn\omega_0t}}{-jn\omega_0}\right]_{-\tau/2}^{\tau/2}

=\frac{A}{T}\cdot\frac{e^{jn\omega_0\tau/2}-e^{-jn\omega_0\tau/2}}{jn\omega_0}=\frac{A}{T}\cdot\frac{2\sin(n\omega_0\tau/2)}{n\omega_0}

With \omega_0=2\pi/T:

c_n=\frac{A\tau}{T}\cdot\frac{\sin(n\pi\tau/T)}{n\pi\tau/T}=\frac{A\tau}{T}\,\text{sinc}\!\left(\frac{n\tau}{T}\right)

The envelope is a sinc, sampled at the harmonic frequencies. This is the discrete version of the rectangle-to-sinc pair.

Worked numbers. A=1, \tau=1 ms, T=10 ms, so the duty cycle is 10% and f_0=100 Hz.

c_0=\frac{1\times1}{10}=0.1

which is the average value, correctly 10% ✓.

c_1=0.1\,\text{sinc}(0.1)=0.1\times\frac{\sin(0.1\pi)}{0.1\pi}=0.1\times0.9836=0.0984

Zeros of the envelope occur where n\tau/T is an integer, so at n=10,20,30,\ldots — that is, at 1 kHz, 2 kHz, 3 kHz.

The practical reading: the first spectral null is at 1/\tau. A narrower pulse pushes the null higher, so the spectrum is wider. This is why a fast digital clock edge radiates far beyond its own frequency, and why deliberately slowing a signal's edges (Chapter 3.6) reduces emissions — the null moves down and takes the high-frequency energy with it.

Problem 6 — Square wave harmonics and Gibbs

A 1 kHz square wave of amplitude 1 V. Give the first four non-zero harmonics with amplitudes, the total harmonic power, and the fraction carried by the fundamental.

Solution

b_n=\frac{4}{\pi n} \ (n \text{ odd})

HarmonicFrequencyAmplitude
11 kHz4/\pi = 1.273 V
33 kHz0.424 V
55 kHz0.255 V
77 kHz0.182 V

Note the fundamental's amplitude exceeds 1 V, which surprises people. It is correct: the higher harmonics subtract near the peak to flatten the top, so the fundamental alone must overshoot.

Total power. A square wave of amplitude 1 has x^2=1 everywhere, so P=1 W (into 1 Ω).

Fundamental's power:

P_1=\frac{(1.273)^2}{2}=0.810\ \text{W}

81% of the power is in the fundamental alone.

Cumulative:

Through harmonicPowerFraction
10.81081.0%
30.90090.0%
50.93393.3%
70.95095.0%

Check the series converges to 1:

\sum_{n\ \text{odd}}\frac{1}{2}\left(\frac{4}{\pi n}\right)^2=\frac{8}{\pi^2}\sum_{n\ \text{odd}}\frac{1}{n^2}=\frac{8}{\pi^2}\cdot\frac{\pi^2}{8}=1 \ ✓

using the known sum 1+\frac19+\frac1{25}+\cdots=\pi^2/8.

The engineering consequence. Filtering a square wave to just above the fundamental leaves 81% of the power and a clean sine. But the 9th harmonic at 9 kHz is still 0.14 V — 11% of the fundamental — so a "1 kHz" square wave demands a system with bandwidth well past 10 kHz to keep its shape. That is why a square wave is the standard test for an amplifier's bandwidth: the corners tell you immediately what the high-frequency response is doing.

Problem 7 — Fourier transform of a decaying exponential

Find and interpret the transform of x(t)=e^{-at}u(t) with a>0.

Solution

X(\omega)=\int_0^\infty e^{-at}e^{-j\omega t}dt=\int_0^\infty e^{-(a+j\omega)t}dt=\left[\frac{e^{-(a+j\omega)t}}{-(a+j\omega)}\right]_0^\infty=\frac{1}{a+j\omega}

Magnitude:

|X(\omega)|=\frac{1}{\sqrt{a^2+\omega^2}}

Phase:

\angle X(\omega)=-\arctan\frac{\omega}{a}

Interpretation. At \omega=0: magnitude 1/a, the largest value. At \omega=a: magnitude 1/(a\sqrt2)down by 3 dB, so \omega=a is the half-power frequency. Beyond that it falls as 1/\omega, which is 20 dB per decade.

This is exactly an RC low-pass filter's response with a=1/RC, and it should be, because e^{-t/RC} is that filter's impulse response.

The reciprocal relationship again. A fast decay (large a) gives a wide spectrum; a slow decay gives a narrow one. Duration in time and width in frequency trade against each other, always.

Phase check: at \omega=a the phase is -45°, and at \omega\to\infty it approaches -90°. Those are exactly the numbers a first-order filter's Bode plot shows in Chapter 6.5.

Problem 8 — Laplace solution of an RLC circuit

A series RLC circuit with R=100\ \Omega, L=0.1 H, $C=10\ \mu$F is driven by a 10 V step at t=0, with zero initial conditions. Find v_C(t).

Solution

Set up in the s-domain as a voltage divider:

V_C(s)=\frac{10}{s}\cdot\frac{1/sC}{R+sL+1/sC}

Multiply numerator and denominator by sC:

=\frac{10}{s}\cdot\frac{1}{s^2LC+sRC+1}=\frac{10}{s}\cdot\frac{1/LC}{s^2+\frac RLs+\frac{1}{LC}}

Numbers.

\frac{1}{LC}=\frac{1}{0.1\times10^{-5}}=10^6, \qquad \frac RL=\frac{100}{0.1}=1000

V_C(s)=\frac{10\times10^6}{s(s^2+1000s+10^6)}

Identify the standard form. \omega_n^2=10^6 so \omega_n=1000 rad/s. And 2\zeta\omega_n=1000 so \zeta=0.5underdamped, so expect ringing with about 16% overshoot.

Poles:

s=\frac{-1000\pm\sqrt{10^6-4\times10^6}}{2}=-500\pm j866

so \omega_d = 866 rad/s = 138 Hz.

Partial fractions.

\frac{10^7}{s(s^2+1000s+10^6)}=\frac{A}{s}+\frac{Bs+C}{s^2+1000s+10^6}

A by cover-up: A = 10^7/10^6=10.

Multiply through and match: 10(s^2+1000s+10^6)+s(Bs+C)=10^7. Comparing s^2: 10+B=0, so B=-10. Comparing s: 10{,}000+C=0, so C=-10{,}000.

V_C(s)=\frac{10}{s}-\frac{10s+10{,}000}{s^2+1000s+10^6}

Complete the square in the denominator: (s+500)^2+866^2.

Rewrite the numerator to match the standard pairs:

10s+10{,}000 = 10(s+500)+5000 = 10(s+500)+5.774\times866

V_C(s)=\frac{10}{s}-10\cdot\frac{s+500}{(s+500)^2+866^2}-5.774\cdot\frac{866}{(s+500)^2+866^2}

Invert term by term:

v_C(t)=10-10e^{-500t}\cos(866t)-5.774e^{-500t}\sin(866t)

Combine into a single sinusoid: amplitude \sqrt{10^2+5.774^2}=11.55, phase \arctan(5.774/10)=30°:

v_C(t)=10-11.55\,e^{-500t}\cos(866t-30°)\ \text{V}

Checks. At t=0: 10-11.55\cos(-30°)=10-11.55(0.866)=10-10=0 ✓ (capacitor starts uncharged). Final value \to10 V ✓.

First peak at t=\pi/\omega_d=3.63 ms: v_C=10+11.55e^{-1.81}\cos(150°)... more directly, the standard overshoot formula gives 100e^{-\pi(0.5)/\sqrt{0.75}}=16.3\%, so the peak is 11.63 V — the capacitor briefly exceeds the 10 V supply. That is real and measurable, and it is why a component rated exactly at the supply voltage can fail in a lightly damped circuit.

Problem 9 — Poles, stability and response

A system has H(s)=\dfrac{10(s+2)}{(s+1)(s^2+4s+13)}. Find the poles and zeros, assess stability, and describe the impulse response without computing it.

Solution

Zero: s=-2.

Poles: s=-1, and from s^2+4s+13=0:

s=\frac{-4\pm\sqrt{16-52}}{2}=\frac{-4\pm j6}{2}=-2\pm j3

Stability: all three poles have negative real parts ✓ stable.

The response, read from the geometry:

  • The pole at -1 contributes e^{-t}, a decay with time constant 1 s.
  • The pair at -2\pm j3 contributes e^{-2t}\cos(3t+\phi) — ringing at 3 rad/s (0.48 Hz), decaying with time constant 0.5 s.

Which dominates? The pole at -1 is closest to the imaginary axis, so its term decays slowest. After about 1 second the ringing has largely gone and only the exponential remains. The pole at -1 is the dominant pole, and a first-order approximation using it alone would be reasonable for the late behaviour.

Damping of the complex pair: \omega_n=\sqrt{13}=3.61, and 2\zeta\omega_n=4 so \zeta=0.554. Overshoot around 12% if that pair acted alone.

Settling time governed by the slowest pole: t_s\approx4/1=4 s.

DC gain by setting s=0:

H(0)=\frac{10\times2}{1\times13}=1.54

so a unit step settles at 1.54.

All of that was read off the pole positions without inverting the transform. That is the point of the s-plane picture, and it is how a control engineer assesses a system in ten seconds.

Problem 10 — Z-transform of a difference equation

For y[n]=0.9y[n-1]+x[n]-0.5x[n-1]: find H(z), the poles and zeros, check stability, and find the impulse response.

Solution

Transform each term:

Y(z)=0.9z^{-1}Y(z)+X(z)-0.5z^{-1}X(z)

Y(z)(1-0.9z^{-1})=X(z)(1-0.5z^{-1})

H(z)=\frac{1-0.5z^{-1}}{1-0.9z^{-1}}=\frac{z-0.5}{z-0.9}

Zero at z=0.5; pole at z=0.9.

Stability: |0.9|\lt1stable, but only just — a pole at 0.9 gives a slow decay.

Impulse response. Rearrange for the standard pairs:

H(z)=\frac{z-0.5}{z-0.9}=\frac{z-0.9+0.4}{z-0.9}=1+\frac{0.4}{z-0.9}

The second term is 0.4z^{-1}\cdot\frac{z}{z-0.9}, so it inverts to 0.4(0.9)^{n-1}u[n-1]:

h[n]=\delta[n]+0.4(0.9)^{n-1}u[n-1]

Check directly from the difference equation. With x=\delta: y[0]=1. y[1]=0.9(1)+0-0.5=0.4 ✓. y[2]=0.9(0.4)=0.36; formula gives 0.4(0.9)^1=0.36 ✓.

Time constant. The response falls to 1/e when 0.9^n=0.368, so n=\ln(0.368)/\ln(0.9)=9.5 samples.

Frequency response at DC (z=1):

H(1)=\frac{1-0.5}{1-0.9}=\frac{0.5}{0.1}=5

At Nyquist (z=-1):

H(-1)=\frac{-1-0.5}{-1-0.9}=\frac{-1.5}{-1.9}=0.79

Gain of 5 at DC and 0.79 at Nyquist — a low-pass filter, which matches the pole sitting at z=0.9, close to the DC point at z=1.

Problem 11 — Design a notch filter in the z-plane

Design a digital notch removing 60 Hz from a signal sampled at 600 Hz, with a notch width of about 6 Hz.

Solution

Angle of the notch:

\omega_0=2\pi\frac{60}{600}=0.2\pi=0.6283\ \text{rad/sample}

Zeros on the unit circle at that angle, to make the response exactly zero there:

z=e^{\pm j0.2\pi}, \qquad \cos(0.2\pi)=0.809

Numerator:

(z-e^{j0.2\pi})(z-e^{-j0.2\pi})=z^2-2(0.809)z+1=z^2-1.618z+1

Poles at the same angle, radius r, to narrow the notch. The relationship between r and the -3 dB width is approximately

\text{width} \approx \frac{(1-r)f_s}{\pi}

For 6 Hz:

1-r=\frac{6\pi}{600}=0.0314 \;\Rightarrow\; r=0.969

Denominator:

z^2-2(0.969)(0.809)z+0.969^2=z^2-1.568z+0.939

H(z)=\frac{z^2-1.618z+1}{z^2-1.568z+0.939}

As a difference equation:

y[n]=1.568y[n-1]-0.939y[n-2]+x[n]-1.618x[n-1]+x[n-2]

Verify at 60 Hz. z=e^{j0.2\pi} makes the numerator exactly zero, so the gain is exactly zero ✓.

Verify at DC (z=1):

H(1)=\frac{1-1.618+1}{1-1.568+0.939}=\frac{0.382}{0.371}=1.03

Nearly unity ✓ — the notch removes 60 Hz and leaves everything else essentially untouched.

Verify at 30 Hz (\omega=0.1\pi, z=e^{j0.1\pi}): working through gives a magnitude of about 0.86, so -1.3 dB. Acceptable — a signal component at 30 Hz loses 14%.

The trade to state explicitly. Moving r to 0.99 narrows the notch to 1.9 Hz, so nearby frequencies are barely touched. But the poles are then extremely close to the unit circle, and in 16-bit fixed-point arithmetic the coefficient rounding can push them outside, turning the filter into an oscillator. 0.97 to 0.99 is the practical range, and beyond it you need a cascade or higher precision.

Problem 12 — Aliasing analysis

A 5 kHz sine, a 12 kHz sine and 30 kHz of broadband noise are sampled at 20 kHz with no anti-alias filter. What appears in the output? Design the filter that would prevent it.

Solution

Nyquist is 10 kHz.

5 kHz: below Nyquist, appears correctly at 5 kHz.

12 kHz: |12-20|=8 kHz. Appears at 8 kHz — a tone that was never present.

Noise up to 30 kHz: every component folds. 10 to 20 kHz folds down to 10 to 0 kHz; 20 to 30 kHz folds up from 0 to 10 kHz. The entire 0 to 10 kHz output band receives three overlapping copies of the noise.

Noise power in the band is therefore three times what it would be with proper filtering, which is a 4.8 dB penalty — nearly one bit of resolution thrown away by a missing filter.

Design the anti-alias filter. Suppose the signal of interest is 0 to 5 kHz and we want anything above 10 kHz down by 60 dB.

Transition from 5 kHz to 10 kHz is one octave. Roll-off needed is 60 dB per octave, and each filter pole gives 6 dB per octave:

n=\frac{60}{6}=10\ \text{poles}

A ten-pole analog filter is a serious and expensive piece of hardware, with poor phase behaviour and components that must be accurate to a fraction of a percent.

Now oversample by 8, sampling at 160 kHz. Nyquist becomes 80 kHz. The transition is 5 kHz to 80 kHz — exactly 4 octaves:

n=\frac{60}{6\times4}=2.5 \;\to\; \textbf{3 poles}

A three-pole Butterworth, which is one op-amp and five passive components. Then apply a steep digital filter and decimate by 8.

The whole design decision in one line: eight times the sample rate turned a ten-pole analog problem into a three-pole one. Digital filtering is cheap; analog precision is not.

Problem 13 — Reconstruction and the zero-order hold

A DAC runs at 48 kHz with a zero-order hold. Find the attenuation at 5 kHz, 15 kHz and 20 kHz, and say what compensation is needed.

Solution

|H(f)|=\left|\text{sinc}(f T_s)\right| = \left|\frac{\sin(\pi f/f_s)}{\pi f/f_s}\right|

At 5 kHz: \pi(5/48)=0.327 rad.

\frac{\sin(0.327)}{0.327}=\frac{0.3212}{0.327}=0.982 \;\Rightarrow\; -0.16\ \text{dB}

At 15 kHz: \pi(15/48)=0.982 rad.

\frac{0.8315}{0.982}=0.847 \;\Rightarrow\; -1.44\ \text{dB}

At 20 kHz: \pi(20/48)=1.309 rad.

\frac{0.9659}{1.309}=0.738 \;\Rightarrow\; -2.64\ \text{dB}

Almost 3 dB down at the top of the audio band — clearly audible as a dull top end.

Compensation. Apply a digital filter with the inverse response, boosting by 1/\text{sinc}(fT_s) across the band. This is free — it is a few extra filter taps — and it is why converter datasheets list "sinc compensation" in the digital filter block.

Oversampling helps here too. Running the DAC at 8× (384 kHz) and interpolating means 20 kHz is at \pi(20/384)=0.164 rad:

\frac{0.1633}{0.164}=0.9955 \;\Rightarrow\; -0.04\ \text{dB}

Negligible. So oversampling fixes three problems at once — a gentle reconstruction filter, negligible sinc droop, and better in-band noise. That combination is why every audio converter made since the late 1980s oversamples.

Problem 14 — Undersampling a radio band

A signal occupies 98 to 102 MHz. Find sampling rates that capture it without aliasing, and state the practical constraints.

Solution

Bandwidth: 4 MHz. Naive Nyquist would demand 204 MSPS. Bandpass sampling can do far better.

The condition is

\frac{2f_H}{k}\le f_s\le\frac{2f_L}{k-1}

with f_L=98, f_H=102 MHz.

k=25: \dfrac{204}{25}=8.16 \le f_s \le \dfrac{196}{24}=8.167 MHz. Valid but the window is 7 kHz wide — far too tight for a real clock.

k=20: \dfrac{204}{20}=10.2 \le f_s \le \dfrac{196}{19}=10.32 MHz. A 120 kHz window, workable.

k=12: \dfrac{204}{12}=17 \le f_s\le\dfrac{196}{11}=17.82 MHz. An 820 kHz window — comfortable.

Take f_s=17.4 MSPS. The band aliases down to

98-5\times17.4=98-87=11\ \text{MHz to } 102-87=15\ \text{MHz}

Hmm — that exceeds Nyquist of 8.7 MHz, so fold again: 17.4-11=6.4 and 17.4-15=2.4. The band lands at 2.4 to 6.4 MHz, inverted, comfortably inside Nyquist ✓.

The three practical constraints:

  1. The sample-and-hold needs 102 MHz of analog bandwidth, even though it samples at 17.4 MSPS. A converter with a 10 MHz input bandwidth simply will not see the signal.

  2. Jitter is set by the input frequency, not the sample rate. From Chapter 3.5, for 12 bits at 102 MHz:

t_j\lt\frac{1}{2\pi\times102\times10^6\times4096}=0.38\ \text{ps}

Sub-picosecond, which needs a dedicated low-noise clock, not a microcontroller output.

  1. A bandpass filter before the sampler is compulsory, and now it must be a bandpass, not a low-pass — anything outside 98 to 102 MHz will alias into the band and there is nothing to distinguish it afterwards.

Payoff: 17.4 MSPS instead of 204 MSPS is a twelvefold reduction in data rate and converter cost. That is why every software-defined radio does this, and why the specification that matters on such a converter is its analog input bandwidth rather than its sample rate.


Part 5 takes the transforms of this Part and makes them computable, starting with the algorithm that made digital signal processing possible at all.