Post Go back to editing

# Filtering strength

Hi guyz, just a new problem, I connected microphones to my 1701 and decided to filter all the sound lower than 22khz. That is how I checked: from an external generator I generated a signal 19.56khz,  connected microphones to the input, then connected high pass second order butterworth filter with corner freq 22khz, then multiplied filtered signal on 20khz sine wave and listened to the output. If there was a signal coming through, it would be modulated and would come through the output as 440hz tone, if filter works then there will be no sound.

The problem is, the filter seems to filter almost nothing! When I switch it on, the 440hz tone becomes just a little tiny bit quieter. Then I tried a crossover, also with the same result. What is wrong guyz? Do filters work fine? Do I do something wrong? How to filter unwanted signal thoroughly?

• I'm a little lost understanding your configuration.

- Why do you multiply the filtered signal by 20kHz?

- Why are you using more than one microphone?

• Because my task is to mix down frequencies about 20.44 khz, if I multiply 20.44 on 20 I can hear a 440hz tone. At the same time I do not want frequencies lower than 20khz to be mixed down. Without a high pass filter 19.56khz will also produce 440hz tone. That is why I use filter. 2 microphones are used for 2-channel operation. I can not unfortunately upload the file now because I am at the Uni. But sure I will do it later, but I do hope that some solution may appear before that. Just the main question is how can I inhibit all the frequencies lower than, say 20khz, leaving everything higher intact (up to 96khz)?

•      Hi Skfir,

To separate your undesired image frequency of (20KHz - 440 Hz) from your desired signal frequency of 20.44KHz, you'll need to design a multi-section filter.  This is how it's done in radios from ordinary to fancy -- the theory actually goes back to tubes and industry pioneers (look up Chebyshev filter in Wikipedia), but can be easily implemented in SigmaStudio.  The filter might look like what's below:

It's four "General" (bi-quad) Hi-pass filters in series, each with its own cutoff frequency "f" and resonance "Q".  For the moment, ignore the numbers inside the filters, examining instead those in the blue comments.  Notice that as you go from input to output, the cutoff frequencies start well above the desired 20KHz cutoff frequency and head toward it (the last one is a little below).  The Q starts low and goes up.  The peaks and dips of the four sections cancel each other above 20KHz, but once you go below cutoff, they all fall together.  Thus the overall response stays more or less flat above 20KHz, then drops like a rock below.    The right way to figure the f and Q for each bi-quad section is to use a filter design program.  I have a good one on my iPod Touch, but I misplaced it yesterday so I set up the above filter by trial and error using the Stimulus and Probe simulation blocks. The response looks like this:

Since you're working with ultrasonics, no doubt you're running at a high sample rate such as 192KHz.  SigmaStudio's filter simulation is fun to use but only runs out to 22KHz even with projects built at 192KHz, so you'll need a workaround to use it here.  One way is to divide all frequencies by 4 (e.g., design the filter for a 5KHz cutoff frequency).  When you actually build the filter in a 192KHz system, enter the real (x4) frequencies.

Even a four-section (8 pole) filter may not be sufficient for your application – you may need to use another radio trick, a superhetrodyne circuit where you do your most selective filtering at an "intermediate frequency" such as 2KHz. That's a more complicated system with two filters, but neither as tough as the one you need here.

Bob

• Thank you very much, bob!

•      Hi Skfir,

AD has an excellent resource on their website -- the  book by Steven W. Smith, The Scientist & Engineer's Guide to DSP.  Chapter 20 provides theory and design procedures for  Chebyshev filters, the link is:

http://www.analog.com/static/imported-files/tech_docs/dsp_book_Ch20.pdf

I highly recommend the entire book.

Bob

• It is an amzing book! I know it, by now I just have been through the first 9 chapters. Thank you again heaps for your help. Will sure read.

•      Hi Skfir,

http://www.analog.com/designtools/en/filterwizard/#/type

Although it's primarily for building active op-amp filters, it provides the necessary fc and Q data to enter into a string of General (2nd Order) filters in SigmaStudio.  For example, you can specify a high-pass filter with 3dB point at 24KHz and a drop of -40dB at 10KHz, as shown below:

If the resulting design has too many stages for your liking, move the Filter Response slider to the left to choose a Chebyshev filter (by the way, this is the neatest selection method I've ever seen in such a program).  Then choose the Specifications tab, and pick Stages from the drop-down box to read out the fc and Q specs for each filter stage.  These go directly into three General (2nd Order) high-pass filter blocks.

If the wizard includes a first-order stage in its output, of course use a corresponding first-order stage filter in your SigmaStudio implementation.

Bob

• Wow, that is absolutely great, thanks!!

•      Hi Skfir,

Likely you know this already, yet for the benefit of others:  With recent versions of SigmaStudio, the Stimulus / Probe response window works for all supported sample rates.  Thus the workaround I described above is no longer necessary.

Bob

•      Hi all,

We now have an even better solution -- the Nth Order Filter -- see https://ez.analog.com/message/217919#217919