DSP 101

Labs & Demos

Interactive pages for this course. Every number on them is computed in your browser — nothing is a recorded animation, and nothing calls out to a server.

9 labs · 9 interactive demos
How to read these. Each page states which of its numbers are computed, which come from a published figure, and which are illustrative. Several were generated with AI assistance and say so on the page. They are teaching instruments, not measurements of real hardware.

Labs

Demos

Convolution step-through

From lesson Convolution

Build your own x and h by dragging the stems, then walk the lag while h flips, shifts and multiplies. Every product is written out term by term, the algebraic properties are recomputed on your sequences, and a computed room response lets you hear what a convolution is for.

M3 · L3AI-generated

Spectrum analyzer

From lesson Why DFT is Slow

The window figures of merit, computed from the coefficients: equivalent noise bandwidth N·Σw²/(Σw)², coherent gain (Σw)/N, scalloping loss and peak sidelobe level, each shown beside the published Harris (1978) value. Put a tone (plus noise) through a windowed FFT, detect the peak, and read its frequency and its coherent-gain-corrected amplitude 2|X_peak|/Σw. Watch the analyzer's central trade: a narrow window resolves close tones but hides weak ones; a wide one sees the weak tone but merges the close pair.

M6 · L1AI-generated

Detect a signal in noise

Bury a known template in seeded Gaussian noise, run the matched filter (a cross-correlation with the template), and watch the peak stand out where the raw record shows nothing. The processing gain 10*log10(N), the output SNR, and the ROC -- P_d against P_fa -- are all computed, with an optional Monte-Carlo overlay that converges onto the analytic curve.

M10 · L1AI-generated

Resample audio

Convert a signal from one sample rate to another by a rational factor L/M -- upsample by L, lowpass, downsample by M. The reduced L/M (48000 → 44100 = 147/160), the new sample count N' = round(N·L/M), and the anti-alias cutoff min(f_s, f_s')/2 are all computed, and zero-order-hold, linear and windowed-sinc interpolation are ranked by their reconstruction error (sinc < linear < ZOH). Downsample a high tone with the anti-alias filter off and watch it fold.

M11 · L1AI-generated