enbw
Equivalent noise bandwidth
Description
Examples
Equivalent Noise Bandwidth of Hamming Window
Determine the equivalent noise bandwidth of a Hamming window 1000 samples in length.
bw = enbw(hamming(1000))
bw = 1.3638
Equivalent Noise Bandwidth of Flat Top Window
Determine the equivalent noise bandwidth in Hz of a flat top window 10000 samples in length. The sample rate is 44.1 kHz.
bw = enbw(flattopwin(10000),44.1e3)
bw = 16.6285
Equivalent Rectangular Noise Bandwidth
Obtain the equivalent rectangular noise bandwidth of a Von Hann window and overlay the equivalent rectangular bandwidth on the window's magnitude spectrum. The window is 1000 samples in length and the sampling frequency is 10 kHz.
Set the sampling frequency, create the window, and obtain the discrete Fourier transform of the window with 0 frequency in the center of the spectrum.
Fs = 10000; win = hann(1000); windft = fftshift(fft(win));
Obtain the equivalent (rectangular) noise bandwidth of the Von Hann window.
bw = enbw(hann(1000),Fs)
bw = 15.0150
Plot the squared-magnitude DFT of the window and use the equivalent noise bandwidth to overlay the equivalent rectangle. The two-sided bandwidth is split evenly across the spectrum.
freq = -(Fs/2):Fs/length(win):Fs/2-(Fs/length(win)); maxgain = 20*log10(abs(windft(length(win)/2+1))); plot(freq,20*log10(abs(windft))) hold on plot(bw/2*[-1 -1 1 1],[-40 maxgain maxgain -40],'--') hold off xlabel('Hz') ylabel('dB') axis([-60 60 -40 60])
Input Arguments
window
— Window vector
real-valued row or column vector
Uniformly sampled window vector, specified as a row or column vector with real-valued elements.
Example: hamming(1000)
Data Types: double
| single
fs
— Sampling frequency
positive scalar
Sampling frequency, specified as a positive scalar.
Output Arguments
bw
— Equivalent noise bandwidth
positive scalar
Equivalent noise bandwidth, specified as a positive scalar.
Data Types: double
| single
More About
Equivalent Noise Bandwidth
The equivalent noise bandwidth of a window is the width of a rectangle whose area contains the same total power as the window. The height of the rectangle is the peak squared magnitude of the window’s Fourier transform.
Assuming a sampling interval of 1, the total energy for the window, w(n), can be expressed in the frequency or time-domain as
The peak magnitude of the window’s spectrum occurs at f = 0. This is given by
To find the width of the equivalent rectangular bandwidth, divide the area by the height.
See Equivalent Rectangular Noise Bandwidth for an example that plots the equivalent rectangular bandwidth over the magnitude spectrum of a von Hann window.
Extended Capabilities
C/C++ Code Generation
Generate C and C++ code using MATLAB® Coder™.
Version History
Ouvrir l'exemple
Vous possédez une version modifiée de cet exemple. Souhaitez-vous ouvrir cet exemple avec vos modifications ?
Commande MATLAB
Vous avez cliqué sur un lien qui correspond à cette commande MATLAB :
Pour exécuter la commande, saisissez-la dans la fenêtre de commande de MATLAB. Les navigateurs web ne supportent pas les commandes MATLAB.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)