Some posts have code included to help demonstrate the concepts. You can check them out under the post with code tag. Enjoy!
Thinking about complex sinusoids, , the unit circle, phase, negative frequency and using instead of can all be confusing when the material is first encountered. Have you asked yourself the following questions? I certainly have:
- Why do we need the complex plane?
- Why can’t we just use degrees instead of radians?
- Why is the unit circle useful?
Unfortunately many of the mathematical tools encountered in the first and second years of an undergraduate EE degree are abstract and their value may not seem practical until graduate school or your first job as an engineer. The hope is that the following post will connect these concepts into a real world situation using the face of a clock in an attempt to build some intuition.
A prior post described how sinusoids came to be used in DSP and RF due to physical properties of the universe. A follow up gave some mathematical rules about complex sinusoids on how sine, cosine and all related to one another in terms of Euler’s triangle. This blog will continue by including time in complex sinusoids, describe how phase and frequency relate to one another, how a negative frequency arises and demonstrates the concepts using the unit circle. It may be useful to review some complex math before jumping into this post.
You know after you cut a lemon and try to get the juice out by hand you get to the point where you need a lemon squeezer to get every last drop? This blog is going to squeeze out every little bit of efficiency in the polyphase half band filter.
What story do you tell yourself about your life?
Do you have one?
You need one.
The last post on half band filters (HBF) referenced the use of a polyphase filter bank structure with a half band filter of length N can be reduced to N/8 multiplies per input sample. This is a huge efficiency gain and why they are used in large sample rate change [harris2021, p.234]. The polyphase filter bank will be used to efficiently implement a decimation by 2 within the HBF with additional savings coming from folding the filter weights. A polyphase filterbank is characterized by multiple branches which represent multiple phases of the signal (the prefix poly- meaning “many”.)
You’ve heard the cliche: you’re stranded on a desert island, what survival item do you take with you? The question focuses your attention and forces you to separate the wheat from the chaff. What is high quality, dependable and useful in many scenarios? The half band filter (HBF) needs to be in your DSP survival bag.
I’m particularly fond of two pieces of wisdom from Conan O’Brien.
Band pass filters are characterized by having attenuation at both high frequency and low frequency with a pass-band in between. Band-pass filters can designed to have real coefficients which have an even-symmetric response or they can be upconverted to complex band-pass to have non-symmetric response which is useful in channelization or in applying a Hilbert transform.
While low-pass filtering (LPF) is ubiquitous high pass filters (HPF) can be needed depending on the RF environment or for specific algorithms. The previous post FIR Low Pass Filter Design with Remez demonstrated how to use the remez() function in the SciPy package to design LPF filter weights. The following blog will demonstrate how to use remez() to design HPFs as well as designing LPF filters and upconverting them.