Fourier transform and filter application

3 ビュー (過去 30 日間)
Baptelet
Baptelet 2019 年 6 月 21 日
編集済み: Baptelet 2019 年 6 月 21 日
Hello everyone,
I'm quite new on Matlab and I would like to perform a Fourier transformation on a time serie.
I'm working with some water table level measurments. In order to perform further analysis, I want to remove a precise frequency wich is associated with a phenomenon occuring every ~12:30. My time serie extends on 6 years for groundwater level measurements sampled every 15 minutes.
The purpose here is to remove with a filter in the spectral domain, the precise frequencies between (12h15 and 12h45)^-1.
To do so, I planned to use the FFT function in Matlab, put zeros to the frequencies between (12h15 and 12h45)^-1 and then apply an IFFT to get back my signal in temporal dimension.
My problem is directly on the first step: when I use the FFT function, plot it and get nothing to interprete. Only some lines that are certainly not good (Cfr. Fig). I'm sure I'm using this function the wrong way but I don't understand how to deal with it (despite documentation that I read of course).
Here you are my time serie and my code, as you can see I'have barely nothing so If someone can tell me some tips with the fft function it would be really appreciated. Thank you everyone.
load ('data')
%WL stands for 'water level'
%t stands for time: one water level measured every 15 minutes
%% Interpolation to enable FFT (fill NaN with values)
% shape-preserving piecewise cubic spline interpolation
[A,TFa]=fillmissing(WL,'pchip','SamplePoints',t);
plot(t,A,'.',t(TFa),A(TFa),'r.')
%% Fourier transformation
Y=fft(A);
plot(Y)
%% Put zeros to frequencies to remove
%% Inverse FFT

回答 (0 件)

カテゴリ

Help Center および File ExchangeFourier Analysis and Filtering についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by