1
$\begingroup$

And how can I solve this issue?

I designed a filter via bilinear transformation in order to obtein a high-pass filter of Butterworth. When I want to set initial conditions with filtic function, it does not give me what I expect. I have a signal with an offset, then I filter that with the designed filter. But the case is that the first values of the filtered signal are still remaining from the original offset.

PD: I expected that at the begginning the signal starts with value of 0. Not a transient as shown in the following image:

enter image description here

That is my code in order to apply the filter to my signal:

% PIOD is the sample period % F_c is the cut-off frecuency

[num_s, den_s] = butter(2, 1, 'high', 's');

    r = F_c*PIOD;
    F_a = 1/(2*pi);
    F_s = F_a/r;

[NUM_z, DEN_z] = bilinear(num_s, den_s, F_s, F_a);

newOffset = 0; % I set the parameter in that way because the filter removes all low-frecuency components of my signal.

iniConds = filtic(NUM_z, DEN_z, [newOffset newOffset]);

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.