MATLAB Answers

how to remove/reduce power line noise from a short signal?

58 views (last 30 days)
Roshanak Yazdanpour
Roshanak Yazdanpour on 22 Jan 2021
hello all,
I am trying to reduce / remove power line noise and its harmonic from a short signal. The frequency resolution of the fft of the signal is 40 Hz which makes using the notch filter very challenging, Is there any method that I can apply to reduce powerline noise without hurting the signal iteslef?
  7 Comments
Roshanak Yazdanpour
Roshanak Yazdanpour on 22 Jan 2021
Thanks for the message and code, the signal you created has enough length (5000 points sampled at 1000 Hz). This makes the notch filter easy. The data I am working with has been sampled at 19200 Hz and the length of data I have for filtering is only 480 samples. So inorder to design a notch filter and due to frequency bin (40 Hz) I should remove all frequencies between 40 and 80 Hz which is not desireable.

Sign in to comment.

Answers (1)

Star Strider
Star Strider on 22 Jan 2021
... the sampling rate I have is 19200 Hz but the data is cut in epochs of 480 samples(non continous) and as such makes the frequency bin size 40 Hz.’
That is entirely different. You can use the approach in How to apply three notch filters of 3rd order? to create your filter. It will filter the original 50 Hz mains noise and selected harmonics harmonics of it. It is straightforward to adapt it to your problem.
The sampling intervals must be constant for this (or any signal processing) approach to work. If they are not, use the Signal Processing Toolbox resample function to interpolate your signal to constant sampling intervals. Then, design the filter to work with your selected sampling frequency in the resampled signal vector.
  2 Comments
Star Strider
Star Strider on 22 Jan 2021
My pleasure!
I will need more information (preferably the signal as well) to adapt this filter to your needs.

Sign in to comment.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!