image thumbnail

SPECTRAL WHITENING

version 1.0.0.0 (86.1 KB) by Dr. Erol Kalkan, P.E.
This function applies whitening to a given signal within user defined frequency band.

751 Downloads

Updated 08 Dec 2017

View License

FREQUENCY DOMAIN WHITENING OF DISCRETE TIME SIGNAL
This function generates flat Fourier spectrum for a given signal (which is originally not white) either for the full range of 0 Hz to the Nyquist frequency or for a user defined frequency band. This operation tends to sharpen signal, as well as the noise. The whitening process is often used for ambient vibration data before stacking waveforms for cross-correlation. The process is simple as Fourier transforming the signal after applying Hann window, then normalizing its magnitude, and then inverse Fourier transforming it.

Syntax:
xnew = whitening(x, Fs, freq, []) for the full range of 0 Hz to the Nyquist frequency
xnew = whitening(x, Fs, freq, [0.1, 20]) for 0.1 Hz to 20 Hz as an example

Input:
x = input signal (x must be a row vector)
Fs = sampling rate (e.g., 200)
freq = frequency limit for whitening in Hz (e.g., freq, [ ] or freq, [0.1, 20])

Output:
xnew = spectrally whitened signal for the full range of 0 Hz to the
Nyquist frequency or within a user defined frequency band

Example: See demo.m file

Cite As

Dr. Erol Kalkan, P.E. (2021). SPECTRAL WHITENING (https://www.mathworks.com/matlabcentral/fileexchange/65345-spectral-whitening), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2017b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!