Window Function Comparison
Compare window functions by computing the main-lobe width and peak sidelobe level of each, so the right trade-off can be chosen for a spectrum analyser.
Constraints
- Compare rectangular, Hann, Hamming and Blackman.
- Use heavy zero-padding to resolve the lobe shape.
- Report main-lobe width in bins and peak sidelobe in dB.
- Return a table or struct array.
- Normalise each window to unit peak before comparing.
- Sidelobe level must be negative in dB.
1function results = compare_windows(n)2% TODO3end