MATLAB: How to design filters using Z transfer functions

filter designlow passtransfer functionz transform

I have a paper on ECG segmentation, and need to develop an algorithm using Matlab that involves among other things, developing 2 filters (a Low Pass Differentiator and a First-Order Low Pass Filter) that have the following transfer functions:
Gdiff(z)=1-z^(-6)
and
Gsmooth(z)=(1-z^(-8))/(1-z^(-1))
Any suggestions are welcome. Thank you.

Best Answer

It is straightforward to convert transfer function to filter (in theory) to filter coefficients, as shown in the following wiki
For example, you Gdiff is an FIR filter with coefficients of [1 0 0 0 0 0 -1]
Related Question