MATLAB Answers

How to find specific frequency in signal

21 views (last 30 days)
Ali Asghar
Ali Asghar on 11 Aug 2019
Commented: Star Strider on 16 Aug 2019
Dear
I have signal 30000x2 size.
i want to find out the specific reqency in signal like 50hz noise and band of 60-2000hz freq.
How can i do it?
untitled.jpg

  0 Comments

Sign in to comment.

Accepted Answer

Star Strider
Star Strider on 11 Aug 2019
If you have R2018a or later and the Signal Processing Toolbox, use the bandpass function to filter your signal.

  8 Comments

Show 5 older comments
Star Strider
Star Strider on 15 Aug 2019
1-Use a notch filter. You can use a FIR filter or the bandstop function. (You can find a link to bandstop in the bandpass documentation I linked to.)
2-Create a sine function with a 50 Hz frequency:
Fs = 1000; % Sampling Frequency
t = linspace(0, Fs, 500)/Fs; % Time Vector (Seconds)
Hz50 = sin(2*pi*t*50); % 50 Hz Sine
figure
plot(t, Hz50)
grid
Ali Asghar
Ali Asghar on 16 Aug 2019
to clean 50hz from the signal, can i use
bandstop(signal,[49 50],Fs); ??
Star Strider
Star Strider on 16 Aug 2019
I would use:
[signal_filtered, df] = bandstop(signal, [49 51], Fs);
You can then also use ‘df’ with filtfilt to filter other signals.

Sign in to comment.

More Answers (0)

Products


Release

R2018b