〈〉 Cross-Correlation 〜 Wavelet Transform 📺 A-scan Processing
Technique 01

Cross-Correlation

Time-of-Flight Pulse-Echo TOFD Matched Filter

In pulse-echo UT you often receive two echoes — a reference (front wall) pulse and a back wall (or defect) pulse — and need to measure the time delay Δt between them precisely to size the reflector.

Simply reading the peak positions works for clean signals, but noise and waveform distortion make that unreliable. Cross-correlation slides one pulse over the other, computes their overlap (inner product) at every lag, and returns a correlation function whose peak sits exactly at Δt — even for noisy, clipped, or overlapping echoes.

Rxy(τ) = ∫ x(t) · y(t + τ) dt
τ = lag; peak of Rxy gives Δt → depth = v·Δt / 2
1
Capture the A-scan with two separated echoes (FW = reference, BW = target).
2
Window the back-wall echo as the search template y(t).
3
Slide y(t) across the full signal x(t), computing the overlap at each lag τ.
4
Find peak of Rxy(τ) — its position is the best estimate of Δt.
5
Compute depth: d = v · Δt / 2 (factor of 2 for round-trip).
A-scan signal
Correlation R(τ)
Δt offset: 110 samples Noise: 15%
💡

Why correlation beats peak-picking: Noise shifts an individual peak unpredictably. The correlation sums contributions over the entire pulse shape — making the peak location robust even at SNR < 10 dB. In TOFD, where lateral-wave and tip-diffraction echoes overlap, cross-correlation is essential for sub-sample Δt accuracy. In practice it's computed via FFT as Rxy = IFFT(FFT(x)* · FFT(y)) — an O(N log N) shortcut for what the formula above defines as an O(N²) sliding dot-product.

Technique 02

Wavelet Transform & Time–Frequency Analysis

CWT Morlet Wavelet Spectrogram Dispersion

A raw A-scan tells you what frequencies are present (via FFT) but not when they arrive. For broadband pulses, dispersive media (plates, composites), or overlapping modes, that distinction matters enormously.

Time-domain pulse
FFT — amplitude spectrum
⚠️

The FFT gives global frequency content — a flat average over the whole signal window. It cannot tell you that low frequencies arrived early and high frequencies arrived late, which is exactly what happens in dispersive Lamb wave propagation.

Enter the Wavelet Transform

Instead of sines (which extend to ±∞), the Continuous Wavelet Transform (CWT) uses a mother wavelet — a short, localized oscillating function — and slides it across the signal at every time position and every scale (∝ 1/frequency). The result is a 2-D map: time on one axis, frequency on the other.

W(a, b) = (1/√a) ∫ x(t) · ψ*((t − b)/a) dt
a = scale (∝ 1/f), b = time shift, ψ = mother wavelet (Morlet used here)

The Morlet wavelet is a Gaussian-windowed complex sinusoid — ideal for UT because its shape closely matches a bandlimited ultrasonic pulse, giving excellent time–frequency resolution balance.

Signal type:
CWT spectrogram (Morlet)
Signal, time-aligned

Inferno colormap — brighter = higher |W(a,b)|

Morlet ω₀: 6 Center freq: 4 MHz
🔍

Dispersive Lamb waves: Switch to "Two-mode (Lamb)" to see two wave packets with different group velocities. The FFT shows overlapping frequency bands — indistinguishable. The CWT spectrogram cleanly separates them in time, enabling individual mode analysis and group velocity measurement.

FFT vs. Wavelet — When to use which

FFT
Best for stationary signals where frequency content doesn't change over time. Fast (O(N log N)), gives exact frequency values. Use for: bandwidth characterization, transducer spectrum, pulse spectrum.
Wavelet CWT
Best for non-stationary signals: dispersive waves, multi-mode Lamb, AE transients. Reveals when each frequency arrives. Use for: Lamb wave mode separation, dispersion curve extraction, AE source characterization.
Technique 03

📺 A-scan Signal Processing

Envelope Detection TGC Pulse Compression SNR & Noise

The raw A-scan is a time-domain RF voltage waveform — a bipolar oscillating signal whose amplitude encodes reflector strength and whose timing encodes depth. Four processing steps convert that raw signal into a displayable, measurable, and imageable result.

Envelope Detection (Hilbert Transform)

Gated C-scans sample peak echo amplitude within a depth window. Sampling the raw RF signal directly produces a position-dependent artefact: a reflector sitting at a wave crest reads full amplitude; one at a zero-crossing reads zero — yet both are physically identical. The cure is the analytic signal:

z(t) = s(t) + j ℋ{s(t)}  ⟶  |z(t)| = envelope
ℋ = Hilbert transform; magnitude |z(t)| is smooth, non-negative, phase-independent

The Hilbert transform phase-shifts every frequency component by 90°, producing a quadrature imaginary part. The magnitude |z(t)| tracks peak echo amplitude regardless of RF phase. In practice: FFT → zero negative-frequency bins → inverse FFT.

IP Flaw Echo BW RF signal (bipolar) Hilbert envelope A-scan RF signal and its Hilbert envelope time →
💡

NDE example: Automated immersion UT of aerospace titanium forgings gates on the Hilbert envelope to flag embedded porosity. A −6 dB drop in gated amplitude marks a suspect region. Using raw RF instead would produce false positives every time the back wall shifts by a quarter wavelength — an artefact no threshold setting can suppress.

Time Gain Compensation (TGC)

Attenuation decays echo amplitude exponentially with depth, so identical reflectors at different depths return unequal signals. TGC applies a programmable depth-dependent gain matched to the material's attenuation law:

GTGC(t) = exp(+α · c · t/2)
dB-linear ramp compensating round-trip path loss; α set from step-wedge or DAC calibration

A properly compensated A-scan shows equal amplitude for equal-size reflectors at all depths, making the C-scan colour scale a direct indicator of reflectivity rather than a convolution of reflectivity and depth.

💡

NDE example: Corrosion mapping of a 6–20 mm carbon-steel pressure vessel at 5 MHz (α ≈ 1 dB/(mm·MHz)). Without TGC the back-wall echo from a 20 mm wall arrives 28 dB below a 6 mm wall reading. TGC recovers that loss, making the C-scan map actual wall-thinning geometry.

Pulse Compression (Chirp / Coded Excitation)

Conventional pulsed UT trades off resolution against SNR: shorter pulse → finer range resolution, but less energy → lower SNR. Pulse compression decouples these. A linear FM chirp of duration T and bandwidth B is transmitted; a matched filter compresses the received signal to ≈ 1/B while preserving the full transmitted energy:

SNR gain = T × B   (time–bandwidth product)
Resolution = 1/B; SNR equivalent to a CW burst of duration T

Sidelobe levels must be managed with amplitude weighting (Hann, Taylor) at the cost of slight resolution broadening.

💡

NDE example: Air-coupled UT of CFRP suffers 60–80 dB insertion loss at each air–composite interface. A 50 μs chirp with B = 200 kHz yields T×B = 10 (+10 dB) — often the difference between resolving a delamination and noise-floor burial.

SNR & Noise Sources

Three distinct noise mechanisms compete with flaw echoes and require different mitigation strategies:

Noise typeOriginFrequency scalingMitigation
Electronic noise Amplifier Johnson noise; preamplifier noise figure White (flat spectrum) Low-noise preamp; coherent averaging N shots → +10log₁₀(N) dB
Coherent grain noise Backscatter from grain boundaries; coherent with transmitted pulse; cannot be averaged away ∝ f² (stochastic) or f⁴ (Rayleigh, d « λ) Lower frequency; spatial compounding; FMC/TFM; frequency-dependent filtering
Geometric / structural noise Surface roughness, geometry re-entrant echoes, mode-converted arrivals Depends on geometry Time-gating; wedge design; surface preparation; TOFD lateral-wave subtraction
⚠️

Austenitic weld inspection: 316L stainless steel welds contain columnar grains 100–500 μm wide. At 5 MHz, coherent grain noise sits only 10–15 dB below a 1 mm side-drilled hole reference — well within typical flaw-detection thresholds. Because grain noise is coherent, waveform averaging does not suppress it. Remedies: (1) drop to 1–2 MHz, or (2) use phased-array spatial compounding / FMC-TFM to decorrelate grain noise while keeping coherent flaw signals in phase.