WOLFRAM SYSTEM MODELER
FIR_coefficientsCalculates the FIR-filter coefficient vector from filter design parameters |
SystemModel["Modelica_Synchronous.WorkInProgress.Incubate.Internal.FIR_coefficients"]
The FIR-filter synthesis based on the window method. The coefficients are calculated through a fourier series approximation of the desired amplitude characteristic. Due to the fact that the Fourier series is truncated, there will be discontinuities in the magnitude of the filter. Especial at the edge of the filter the ripple is concentrated (Gibbs-effect). To counteract this, the filter coefficients are convolved in the frequency domain with the spectrum of a window function, thus smoothing the edge transitions at any discontinuity. This convolution in the frequency domain is equivalent to multiplying the filter coefficients with the window coefficients in the time domain.
The filter equation
y(k) = a0*u(k) + a1*u(k-1) + a2*u(k-2) + ... + an*u(k-n)implies that the function outputs n+1 coefficients for a n-th order filter. The coefficients can be weightened with different kind of windows: Rectangle, Bartlett, Hann, Hamming, Blackman, Kaiser
filterType |
Default Value: Modelica_Synchronous.WorkInProgress.Incubate.Types.FIR_FilterType.LowPass Type: FIR_FilterType Description: Type of filter |
---|---|
order |
Default Value: 2 Type: Integer Description: Order of filter |
f_cut |
Default Value: 1 Type: Frequency Description: Cut-off frequency |
Ts |
Type: Time Description: Sampling period |
window |
Default Value: Modelica_Synchronous.WorkInProgress.Incubate.Types.FIR_Window.Rectangle Type: FIR_Window Description: Type of window |
beta |
Default Value: 2.12 Type: Real Description: Beta-Parameter for Kaiser-window |
a |
Type: Real[order + 1] Description: Filter coefficient vector |
---|