nuget server logo nuget api documents
↑

API Docs / Microsoft.VisualBasic.Math.SignalProcessing / TFftAlgorithm

TFftAlgorithm

Full name Microsoft.VisualBasic.Math.SignalProcessing.FFT.TFftAlgorithm Assembly Microsoft.VisualBasic.Math.SignalProcessing Members 11

Quick Fourier Transformation. Some ideas to make the Discrete Fourier Transformation a bit quicker and implemented a lean version of the DFT algorithm.

00 Remarks

http://www.codeproject.com/Articles/590638/Quick-Fourier-Transformation

离散傅里叶变换(discrete Fourier transform) 傅里叶分析方法是信号分析的最基本方法,傅里叶变换是傅里叶分析的核心, 通过它把信号从时间域变换到频率域,进而研究信号的频谱结构和变化规律。 在形式上,变换两端(时域和频域上)的序列是有限长的,而实际上这两组序列都应当被认为是离散周期信号的主值序列。 即使对有限长的离散信号作DFT,也应当将其看作其周期延拓的变换。在实际应用中通常采用快速傅里叶变换计算DFT。

下面给出离散傅里叶变换的变换对: 对于N点序列,它的离散傅里叶变换(DFT)为 其中是自然对数的底数,是虚数单位单位。 通常以符号表示这一变换,即 离散傅里叶变换的逆变换(IDFT)为: 可以记为: 实际上,DFT和IDFT变换式中和式前面的 归一化系数并不重要。有时会将这两个系数都改成。

The FFT produce frequency samples (or spectral bin). A frequency sample is a complex number with real and imaginary part. The imaginary part give the phase and the real part give the amplitude. We have to compute the magnitude in dB from this to produce a nice spectrogram. The magnitude of a spectral bin is simply the amount of energy for the corresponding frequency. (FFT产生对波形的频率的采样,一个频率采样是一个复数集合,虚数部分记录了相位,实数部分则记录了振幅。我们必须计算声贝的大小从而产生一个比较不错的分析数据)

01 Syntax

Microsoft.VisualBasic.Math.SignalProcessing.FFT.TFftAlgorithm

02 Methods

NameOverloadsSummary
.ctor 1 使用本构造函数所创建的FFT对象,需要在后续的代码之中手动设置TFftAlgorithm.y的值
FourierTransformation 1 Fourier transformation calculation of the Fourier components
InvDFT 1 invers Fourier transformation, rebuild the signal in real numbers

03 Fields

NameOverloadsSummary
a 2 The real value is the cosinus part
b 2 The imag value is the sinus part
y 1
xw 1
sine 1
cosine 1

04 Members

method .ctor #
#ctor(Int32)

使用本构造函数所创建的FFT对象,需要在后续的代码之中手动设置TFftAlgorithm.y的值

Parameters
NameTypeDescription
orderInt32

TFftAlgorithm.y的值的数目

method FourierTransformation #
FourierTransformation

Fourier transformation calculation of the Fourier components

method InvDFT #
InvDFT

invers Fourier transformation, rebuild the signal in real numbers

field a #
a

The real value is the cosinus part

Remarks

Compute magnitudes

Now we can compute the magnitude from complex values. This is done with the good old Pythagorean theorem. Each complex number can be represented in a two-dimensional space.

The real part is a, and the imaginary part is b.

Magnitudes are stored in a two dimentional array magnitudes[x,y] where x is the nth FFT performed by SampleTagger and y is the nth magnitude in range [0,fft_size/2]

field b #
b

The imag value is the sinus part

field y #
y
field xw #
xw
field a overload 2 #
a
field b overload 2 #
b
field sine #
sine
field cosine #
cosine