Peak coming at 50Hz in every data file. How to get rid of that

1 次查看(过去 30 天)
I have amplitude and time data with me. After doing FFT of the data I plot amplitude vs frequency graph and after calculating power I plotted power vs frequency graph but everytime in my graph there is a peak at 50hz. and it comes in every data file. Please help me how to get rid of that. I have attached pictures of graph for your reference
  1 个评论
Mathieu NOE
Mathieu NOE 2024-6-3
you probably have a signal pollution coming from the main supply
you either need a better supply, a better galvanic isolation or use in last option a notch filter centered at 50 Hz

请先登录,再进行评论。

回答(2 个)

Image Analyst
Image Analyst 2024-6-3
Find out what index the 50 Hz spike is in and zero it out. Something like
f = fft(signal)
[peakSignal, indexOfMax] = max(f)
f(indexOfMax) = 0;
% Back to time domain
signal = ifft(f);
That would be if the peak is always at 50 Hz. If it's not, then identify the 50 Hz index some other way.
Maybe use a lock-in amplifier to extract your signal -- separate it from the 50 Hz signal it's riding on or affecting it.

Star Strider
Star Strider 2024-6-3
If you have the Signal Processing Toolbox, use the bandstop function:
Fs = ...; % Sampling Frequency (Hz)
signal_filt = bandstop(signal, [48 52], Fs, 'ImpulseResponse','iir'); % Filter Signals
If all the signals have the same sampling frequency and length, you can combine them all column-wise in ‘signal’ and filter them all at once. Note that this will almost completely zero-out that frequency, so the signal in ‘Picture1’ (that is vanishingly small) might have to be interpolated (perhaps using the fillmissing function) to correct for that. It would be easier to illustrate this with your actual signals.
jpgs = dir('*.jpg');
for k = 1:numel(jpgs)
figure
imshow(imread(jpgs(k).name))
title(jpgs(k).name)
end
.

类别

Help CenterFile Exchange 中查找有关 Spectral Measurements 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by