Main Content

chebwin

Chebyshev window

Description

w = chebwin(L) returns an L-point Chebyshev window.

example

w = chebwin(L,r) returns an L-point Chebyshev window using sidelobe magnitude factor r dB.

w = chebwin(___,typeName) specifies the option to return the window w with single or double precision.

Examples

collapse all

Create a 64-point Chebyshev window with 100 dB of sidelobe attenuation. Display the result using wvtool.

L = 64;
bw = chebwin(L);
wvtool(bw)

Figure Window Visualization Tool contains 2 axes objects and other objects of type uimenu, uitoolbar, uipanel. Axes object 1 with title Time domain, xlabel Samples, ylabel Amplitude contains an object of type line. Axes object 2 with title Frequency domain, xlabel Normalized Frequency (\times\pi rad/sample), ylabel Magnitude (dB) contains an object of type line.

Input Arguments

collapse all

Window length, specified as a positive integer.

Note

If you specify L as noninteger, the function rounds it to the nearest integer value.

Data Types: single | double | int8 | int16 | int32 | int64 | uint8 | uint16 | uint32 | uint64

Sidelobe attenuation in dB, specified as a positive integer. The Chebyshev window has a Fourier transform magnitude r dB below the mainlobe magnitude.

Data Types: single | double

Since R2024b

Output data type (class), specified as one of these:

  • "double" — Use this option to return a double-precision output w.

  • "single" — Use this option to return a single-precision output w.

Data Types: char | string

Output Arguments

collapse all

Chebyshev window, returned as a column vector.

Note

If you specify a one-point window (L = 1), the value 1 is returned.

Tips

An artifact of the equiripple design method used in chebwin is the presence of impulses at the endpoints of the time-domain response. The impulses are due to the constant-level sidelobes in the frequency domain. The magnitude of the impulses are on the order of the size of the spectral sidelobes. If the sidelobes are large, the effect at the endpoints may be significant. For more information on this effect, see [2].

The equivalent noise bandwidth of a Chebyshev window does not grow monotonically with increasing sidelobe attenuation when the attenuation is smaller than about 45 dB. For spectral analysis, use larger sidelobe attenuation values, or, if you need to work with small attenuations, use a Kaiser window.

References

[1] Digital Signal Processing Committee of the IEEE Acoustics, Speech, and Signal Processing Society, eds. Programs for Digital Signal Processing. New York: IEEE Press, 1979, program 5.2.

[2] harris, fredric j. Multirate Signal Processing for Communication Systems. Upper Saddle River, NJ: Prentice Hall PTR, 2004, pp. 60–64.

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using MATLAB® Coder™.

GPU Code Generation
Generate CUDA® code for NVIDIA® GPUs using GPU Coder™.

Version History

Introduced before R2006a

expand all

See Also

Apps

Functions