Skip to main content

10.5 Discrete wavelet transforms

Source: Ideas from Computational Physics (Landau, Páez, Bordeianu), §10.5. Rewritten in original wording — no textbook dwt.py dump. Continues 10.4b. Next: 10.5b.

Only NN independent coeffs​

With NN samples ymy_m you can keep only NN independent transform numbers and still hit the sample grid. Stay consistent with ΔωΔt≳2π\Delta\omega\Delta t\gtrsim 2\pi while doing so. Pick the dyadic lattice, the orthonormal reconstruction, and the Daub4 taps among lookalikes.

Then Yj,k≃∑mψj,k(tm) ym hY_{j,k}\simeq\sum_m\psi_{j,k}(t_m)\,y_m\,h. Orthonormality ∫ψj,k∗ψj′,k′=δjj′δkk′\int\psi_{j,k}^*\psi_{j',k'}=\delta_{jj'}\delta_{kk'} plus time localization ⇒ low correlation ⇒ good compression.

Figure 10.8 — equal-area time–frequency tiles.

Low ω\omega: few wide tiles (smooth outline). High ω\omega: many narrow tiles (detail). Same area ∼2π\sim 2\pi.

Filters instead of integrals​

Industrial DWTs use multiresolution analysis (Mallat): pass the signal through digital lowpass LL and highpass HH filters (convolutions = discrete wavelet overlaps), then ↓2 decimate. Recurse on the lowpass branch.

Figure 10.9 — L/H tree with factor-of-2 decimation.

Highpass outputs are details d(level)d^{(level)} (store). Lowpass outputs are smooth s(level)s^{(level)} (feed the next stage). Stop when two smooth and two detail numbers remain.

Figure 10.10 — pyramid downsampling.

Synthesis reverses the arrows: upsample, apply transpose filters, merge until length NN returns.

Daub4 coefficients​

Daubechies filters are defined by tap weights, not closed forms. Stack L=(c0,c1,c2,c3)L=(c_0,c_1,c_2,c_3) and H=(c3,−c2,c1,−c0)H=(c_3,-c_2,c_1,-c_0) (and shifted copies) into an orthogonal matrix — the cic_i you picked above. LL smooths (weighted average); HH differences (detail). Larger NN builds a banded filter matrix with wrap-around at the edges; pyramid reorders smooth/detail after each stage.

Figure 10.12 — Daub4 packets via inverse filtering (schematic).

Inverse-transform a unit impulse in coefficient space to see the time-domain Daub4 shape at different scales.

Practice checklist​

  1. Implement Daub4 forward/inverse on length 2n2^n (chirp sin⁡(60t2)\sin(60t^2) is the book’s demo).
  2. Stop the pyramid at different nend to watch ↓2 stages.
  3. Invert (sign flip) and match yy.
  4. Impulse → mother visualizations at growing widths.
# dwt_daub4_sketch.py — original structure (not a textbook dump)
c0, c1, c2, c3 = ... # Daub4 closed form
# forward: for each pair, s = L·y_local, d = H·y_local; ↓2; recurse on s
# inverse: upsample; apply transpose taps; merge
Quiz

Discrete wavelets

1 / 4

A dyadic DWT takes scales…

Pick an answer to see if you are right.

Next: 10.5b DWT labs.