LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

butterworth Filter and Gain

Hallo. How can I avoid the changing of the magnitude of the signal after using a butterworth Filter- Thanks for ur Help.
0 Kudos
Message 1 of 4
(4,150 Views)
No filter is ideal, so your magnitude will always been affected somehow by the filter. A Butterworth filter will by definition attenuate your signal 3dB at its cut-off frequency but the attenuation becomes smaller the closer you get to 0 Hz (dc).

The passband attenuation (called ripple) depends on the filter type and order. If you want to minimize this ripple you can either increase the order of your Butterworth filter and move the cut-off to a higher frequency or consider, for example, an equi-ripple type filter (elliptic or equivalent).

Does this answer your question or is your "changing magnitude" an other problem? If not ... please explain your problem more precisely.
0 Kudos
Message 2 of 4
(4,150 Views)

Hello,

I am using a butterworth filter as a bandpass filter. Sampling frequency 10kHz, lower cutoff 390Hz and higher cutoff 420 Hz. The output of the filter is heavily attenuated. It should be around 0.4V but its 0.07. Does the filter have a gain?

0 Kudos
Message 3 of 4
(3,532 Views)

Filters have attenuation and can have gain when it is an active filter.

 

The effect you are seeing is in part due to the very narrow bandwidth.  Filters are usually specified in terms of normailzed bandwidth and the frequency scale is usually logarithmic.  From graph in a filter design book the attenuation of a normalized 3-pole Butterworth low pass filter is 3 dB at 1, 1 dB at 0.8, and about 18 dB at 2. Translating those figures to your frequencies gives: Center frequency = 404.72 Hz (geometric mean of upper and lower cutoffs). 390/404.72 = 0.964 normalized and 402/404.72 = 1.038 normalized. So your bandwidth in terms of fractional frequency is quite narrow.  It may also be due to the nature of your signal which I have not seen.

 

If you think in terms of overlapping lowpass and highpass filters with 3dB cutoffs at 390 and 420 Hz, the attenuation at the center frequency will be closer to 3 dB than to zero.

 

Tha actual filter implementation in LV works quite well. I removed your DAQmx VIs and used Sine Waveform.vi as a signal source. You can see the transient effects in the filters as the frequency of the signal is changed. Note that at 404.72 Hz the output signal is attenuated only a very small fraction of a decibel and that the attenuation is -3 dB at 390 and 420 Hz.

 

Lynn

Message 4 of 4
(3,514 Views)