0
$\begingroup$

I am trying to filter signal x(n), n = 150. I made a filter with few frequency points on the x axis , [-11., -9., -3., -2., -1., 1., 2., 3., 9., 11.]) I also defined linear magnitudes and phase in radian for corresponding frequencies. It would look as in the following: Frequency F, manitude H and phase in each column.

      ([[-11.    ,   3.1623,  -0.8203],
       [ -9.    ,   5.0119,  -1.3614],
       [ -3.    ,   2.5119,  -0.4014],
       [ -2.    ,   3.9811,  -0.9599],
       [ -1.    ,   1.5849,  -0.4363],
       [  1.    ,   1.5849,   0.4363],
       [  2.    ,   3.9811,   0.9599],
       [  3.    ,   2.5119,   0.4014],
       [  9.    ,   5.0119,   1.3614],
       [ 11.    ,   3.1623,   0.8203]])

The sample rate of the signal is srate = 1000. One can obtain the frequency of the real signal by doing, f_sig = np.fft.fftshift(np.fft.fftfreq(n,1/srate)).

How do i obtain the Transformation function of the signal ?

H(sig) = |H|x exp (ixphi)

I suppose i need to interpolate magnitude and the phase, but don't know how?

Do you have any idea, how i may implement this?

Many Thanks.

$\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.