Raised cosine FIR filter design
b = firrcos(n,Fc,df)
b = firrcos(n,Fc,df,Fs)
b = firrcos(n,Fc,df,Fs,'bandwidth')
b = firrcos(n,Fc,df,Fs,'type')
b = firrcos(...,'type',delay)
b = firrcos(...,'type',delay,window)
b = firrcos(n,Fc,r,Fs,'rolloff')
b = firrcos(...,'rolloff','type')
[b,a] = firrcos(...)
b = firrcos(n,Fc,df,Fs,'bandwidth') returns an order n lowpass linear-phase FIR filter with a raised cosine transition band. The order n must be even. The filter has cutoff frequency Fc, transition bandwidth df, and sampling frequency Fs, all in hertz. df must be small enough so that Fc ± df/2 is between 0 and Fs/2. The coefficients in b are normalized so that the nominal passband gain is always equal to 1.
'normal', for a regular raised cosine filter. This is the default, and is also in effect when the 'type' argument is left empty, , or unspecified.
'sqrt', for a square root raised cosine filter.
b = firrcos(...,'type',delay,window) applies a length n+1 window to the designed filter to reduce the ripple in the frequency response. window must be a length n+1 column vector. If no window is specified, a rectangular (rectwin) window is used. Care must be exercised when using a window with a delay other than the default.
b = firrcos(...,'rolloff','type') specifies the type of raised cosine filter.
Design an order 20 raised cosine FIR filter with cutoff frequency 0.25 of the Nyquist frequency and a transition bandwidth of 0.25:
h = firrcos(20,0.25,0.25); freqz(h,1)