# Complex band pass filter

I'm trying to find some mathematical docs about the complex (analytic signal) band pass filtering in discrete time. I've read some text already but most of them describes the problem in real time only.

I would really appreciate some equations.

[EDIT:]

I found this coefficients' computation equation for real signals:

$$w_{bp}(n) = \begin{cases} \displaystyle\frac{\sin\left[2\pi f_{t2}\left(n-\frac M2\right)\right]}{\pi\left(n-\frac M2\right)}-\frac{\sin\left[2\pi f_{t1}\left(n-\frac M2\right)\right]}{\pi\left(n-\frac M2\right)}, & \text{if } n \ne \frac M2 \\[2ex] 2\left(f_{t2} - f_{t1}\right), & \text{if } n = \frac M2 \end{cases}$$

I know I have to specify the FIR filter order ($M$) which is approximately 4 / Normalised width of transition band. The application of the filer is a simple convolution of the coefficients computed by the equation above and real signal samples.

Now what I need to know is how to achieve this in complex plain. I also found a similar thread here, which describes the low pass filter design.

PS: I already have my complex $f_c = 5 \textrm{ kHz}$ signal sampled at $f_s = 32\textrm{ kHz}$ and I'm familiar with the complex plain problematics.

• Could you be a bit more concrete? What exactly do you want to know? You could post the relevant equations in continuous-time, and ask about their discrete-time equivalents. You could also look up "discrete-time Hilbert transformer". I think many people here could help you if you clarified your question a bit. – Matt L. Jan 7 '16 at 21:50
• @MattL. Thanks, i just did some update of the question. – r.a.m- Jan 7 '16 at 22:14
• Solution: I used a GNU radio implementation of FIR filter designer class, which can be found here > github.com/gnuradio/gnuradio/blob/… – r.a.m- Mar 6 '16 at 18:47

Take a (real-valued) low pass filter with impulse response $h_{LP}[n]$ and with cut-off frequency $(f_2-f_1)/2$, where $f_1$ and $f_2$ are the lower and upper band edges of the desired band pass filter. Define a center frequency $f_0=(f_1+f_2)/2$. Then a real-valued band pass filter is obtained by

$$h_{BP}[n]=2h_{LP}[n]\cos(2\pi f_0n)\tag{1}$$

Depending on the design of the low pass filter, the filter in $(1)$ can be identical to the one in your question.

If you want a complex-valued band pass filter with a pass band at positive frequencies (but not at negative frequencies), you simply have to modulate the low pass impulse response $h_{LP}[n]$ by a complex exponential instead of by a cosine:

$$h^c_{BP}=h_{LP}[n]e^{j2\pi f_0n}\tag{2}$$

perhaps the equation you need is the real-valued impulse response of, what is in the frequency domain, a one-sided BPF that is pushed up to $f_c$ (i think what Matt is calling "$f_0$").

i think more generally it is

$$h[n] = h_\text{re}[n] \cos(\omega_c n) - h_\text{im}[n] \sin(\omega_c n)$$

where

$$h_\text{im}[n] = \mathcal{H} \left\{ h_\text{re}[n] \right\}$$

so whatever is the frequency response of $h_\text{re}[n]$, the positive-frequency half of that frequency response is slide up from its left edge being at 0 (or $\omega=0$) to its left edge being at $\omega_c$.

• But your filter $h[n]$ is real-valued, so it can't be a "one-sided BPF", but its frequency response is (conjugate) symmetrical. Am I missing something? – Matt L. Jan 7 '16 at 23:27
• Now I see what you mean. If $h_L[n]=h_{re}[n]+jh_{im}[n]$ is an analytic low pass filter, where $h_{im}[n]$ is the Hilbert transform of $h_{re}[n]$, then the complex-valued one-sided BPF is $$h[n]=h_L[n]e^{jn\omega_c}=(h_{re}[n]\cos(n\omega_c)-h_{im}[n]\sin(n\omega_c))+j(h_{im}[n]\cos(n\omega_c)+h_{re}\sin(n\omega_c))$$. $\omega_c$ is the lower band edge of the analytic BPF. In my answer, $f_0$ is the center frequency of the BPF. – Matt L. Jan 7 '16 at 23:37
• your $f_0$ is the amount of frequency that the $H_{LP}(f)$ is translated. "center" is a more difficult thing to define if there happens to be no line of symmetry to base it on. but the amount something is translated is an fully objective thing to define. – robert bristow-johnson Jan 8 '16 at 3:43