LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to design a good 60Hz notch filter?

I tried to design a 60Hz notch filter(59-61 as stop band,tried different kind filters/orders,cont.true)But I can't have a stable output. When test on 60 Hz input,the output signal's amplitude will change in a repeated pattern,sometime the ripples is very small, but sometimes it's big, especially at the waveform beginning. The Fs is 5000, data is sampled every few seconds. Are there any refined 60Hz notch filter can be used, or any better way to design a notch filter?
Averaging is one way to remove the ripples after filtering,but I hope the filter can give a steady output.Thanks!
0 Kudos
Message 1 of 10
(16,878 Views)
When you first apply a filter to a signal, it has to settle before becomming stationary. This is a natural phenomenom and there is no way around that. If you are using the filter VI in a loop AND provide it with data blocks that are contiguous in time (that is the first sample of a data block naturally follows the last sample of the previous data block), then the filter will not have to settle since it "knows" the history from the previous block. So in that case you should only see the problem at the very beginning of the first block.

In your case where "the data is sampled every few seconds", it sounds to me like you are not providing contiguous data blocks and therefore the filter will reset itself every time (resulting in ripple at the beginning ofeach acquisi
tion). Try to run the filter VI in a (while) loop and provide it with correctly timestamped data at real time (it should not be a problem at Fs=5 kHz). This should fix your problem.

Goos luck
0 Kudos
Message 2 of 10
(16,878 Views)

does anybody have the VIs of ECG with DFD notch filter or hhow to use DFD notch filter to ecg?

from where i can connected the signal input to  DFD notch filter cause i can't find the filter input?

tanx

0 Kudos
Message 3 of 10
(16,407 Views)

Hi,

 

If you have Digital Filter Design Toolkit, there is an example to show how to apply Notch filter to ECG signals.

 

notch1.gif 

 

notch2.gif

 

Thanks!

0 Kudos
Message 4 of 10
(16,388 Views)

this example is not installed on labview 8

and i cant make setup

0 Kudos
Message 5 of 10
(15,659 Views)

Hi, This is an example from Digtial Filter Design Toolkit. You could download it in ni.com - http://sine.ni.com/nips/cds/view/p/lang/zhs/nid/14890. Thanks!

0 Kudos
Message 6 of 10
(15,631 Views)
this is not free
0 Kudos
Message 7 of 10
(15,597 Views)

 please if you have this example  or know about it ,send it 

thanks

0 Kudos
Message 8 of 10
(15,590 Views)

He can't send you an example from a toolkit that must be purchased. That would be illegal.

0 Kudos
Message 9 of 10
(15,563 Views)

@sfhj wrote:

 please if you have this example  or know about it ,send it 

thanks

 


@sfhj

 

Hijacking a old thread is never a good idea. I suggest you start your own. Also in order to get help you must explain better what you have done so far, why and how you struggle. The best way to do this, is to post your code, and some signals examples. I know a lot of tricks. And none of them need a fancy toolkit. But you must start your own thread in order to get help from me.  

Edit: I noticed you have started a new thread, do you want to move the discussion to that thread?

 



Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
(Sorry no Labview "brag list" so far)
0 Kudos
Message 10 of 10
(15,553 Views)