MATLAB: Https://jp​.mathworks​.com/help/​matlab/exa​mples/usin​g-fft.html

fft matlab

サンプルについての質問なんですが、
1.関数 fft を使用して、チューリッヒ データのフーリエ変換を行うときに、データの和が保存されている、出力の最初の要素を削除していますが、実際に他のデータでFFTをかける場合にも最初のデータには和が保存されているのでしょうか。    y = fft(relNums);    y(1) = [];
2.以下の文章とソースの関係で質問なんですが、
2.1 より意味のある係数の尺度は振幅の二乗です。これはべき乗の尺度です。 これは、以下に該当する認識ですが正しいでしょうか。   power = abs(y).^2
2.2 係数の半分は振幅内で繰り返されるため、係数の半分のべき乗を計算するだけで済みます。   これは、以下に該当する認識ですが正しいでしょうか。 n/2
2.3 以下がどこからどういった経緯で出てきたのか教えていただけないでしょうか。   maxfreq = 1/2; % maximum frequency

Best Answer

I am not a signal processing expert, but here goes.
Regarding questions 1 and 2: The first element will contain information about the magnitude, as it is the 0 Hz component. This is true for all Fourier transformed data sets. If you have a relatively high mean value, your data may be easier to visually analyze if you remove the first value. Removing the first value should be more or less equivalent to data=data-mean(data) prior to the fft.
Regarding question 3: Yes.
Regarding question 4: As far as I am aware, yes. That is the reason why they combine these two steps in the example: n = length(y); power = abs(y(1:floor(n/2))).^2;
Regarding question 5: This drops out because of the Nyquist criterion. You can only meaningfully detect frequencies up to half of your sample frequency.
Hope this helps.