0
$\begingroup$

My question is about the action of a bandpass filter. First, I have a temporal signal. I convert it in a spectral signal via a FFT. Now, I want to apply a bandpass filter on that spectral signal. But my question is : how to do it ?

My temporal signal is a real signal so, I understand how to multiplicate by a coefficient. But my spectral signal is complex so, what do I have to do ? Multiplicate the real part and the imaginary part by the coefficient ?

Thank you for your answers,

Dr_Click

$\endgroup$
1
  • $\begingroup$ You are really asking a question that can be answered better someplace else, like the online MIT courses that are free and open to everyone. If you can describe how you want to do your processing like in C or C++ on a laptop, or using tools like MATLAB or Octave, or R, or Python, someone can point you in the right direction where there are examples and tutorials. $\endgroup$
    – user28715
    Jun 19, 2018 at 16:08

1 Answer 1

3
$\begingroup$

You're wanting the magnitude of your spectrum to decrease in certain areas (since you're trying to filter out those frequencies). So, yes, you could just multiply your real and imaginary components by your coefficient. For example, if you have a number $5 -5i$, the magnitude is $\sqrt{5^2 + (-5)^2} = 5\sqrt{2}$. If you want to decrease this magnitude by 50% you would just multiply your real and imaginary numbers by .5. This can be seen by $\sqrt{(5*.5)^2 + (-5*.5)^2} = 2.5\sqrt{2}$.

Note that if you're wanting to filter your signal in the frequency domain, and then transform it back to the time domain, you probably don't want to do a rectangular window, where you multiply the frequencies you want to filter out by 0, and everything else by 1. This would create some wide band noise in the time domain.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.