Recursive filtering with given transfer function

12 views (last 30 days)
Hello everybody,
I'm working on my graduation project and I'm developing a filter (based on kalman filtering) in order to compensate a dynamometer's dynamic affecting high frequency measurements.
Following some other works I've been able to define the filter's continuous-time transfer function and it does exactly what it should. But now I'm facing problems applying it to measurements data.
I'll be honest, I do not know much about digital filtering and I'm quite new to matlab, but I've not been able to apply the filter with success.
In the works I've studied it's said to use the discrete equivalent of the continuous-time TF and apply it recursively at each time-step to the measurements data.
I've tried discretizing the TF with the c2d matlab's function and using the filter matlab's function to filter a simulated system-response in order to try to reconstruct the input signal, but it does not what it should.
This is the discrete-time TF that I've calculated to compensate a simple 1-dof system:
filter_discrete_tf =
-7.173 z^-1 + 7.846 z^-2
-------------------------------------------------
1 - 0.3269 z^-1 - 4.226e-20 z^-2 - 2.501e-40 z^-3
Is there a way to apply it "recursively at each time-step" to the measurements data?
Any help will be really appreciated.
I'm sorry for my bad english and my poor basis of digital filtering.

Answers (1)

Wayne King
Wayne King on 12 Nov 2012
Edited: Wayne King on 12 Nov 2012
I'll assume that your rational Z-transform above is correct. How did you use the above with filter? From the expression above, your numerator and denominator coefficient vectors should be:
B = [0 -7.173 7.846];
A = [1 -0.3269];
fvtool(B,A)
I did not use your z^{-2} and z^{-3} terms since those are 10^{-20} and 10^{-40} respectively.
It looks like a stable highpass filter. Is this what you are after?
  1 Comment
Lorenzo S
Lorenzo S on 12 Nov 2012
Edited: Lorenzo S on 12 Nov 2012
First of all thank you.
I'll try to be a bit more clear, if I can. I'll try to be as short as I can, hope it will be clear enough.
I'm working on a simple 1-dof system now, this is the transmissibility TF of the given system:
transmissibility =
44.72 s + 50000
---------------------
s^2 + 44.72 s + 50000
This is how the system amplifies or damps the force inputs.
Based on this I've calculated a filter continuous-time TF that "compensate" the system's transmissibility. This is the continuous-time TF of the filter:
filter_tf =
3.383e13 s^2 + 1.513e15 s + 1.692e18
------------------------------------------
s^3 + 5.501e07 s^2 + 1.513e15 s + 1.692e18
Now what I'm after is using this filter tf to compensate a signal that has been "distorted" by the system dynamics. I mean if I simulate the system response to a sinusoidal signal (e.g. using lsim function) I expect the system to amplify or damp the response depending on the input frequencies. What I need is to reconstruct the original signal given the system-response and the filter TF.
The aim of this filter should be to amplify or damp the system response depending on the frequency of the output-signal compensating what the system has "added" or "subtracted" to the input original signal.
I'm sorry if this is not clear enough, as I said I've studied different things so far and that's the first time I'm into signal processing.
I hope this can help and thank you again for your time.

Sign in to comment.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!