/// <summary> /// 時間ドメイン値xを入力すると、N点DFTの周波数ドメイン値Xのm番目の周波数binの値を戻す。 /// </summary> /// <param name="m">周波数binの番号。0≦m<N</param> /// <param name="N">DFTサイズN。</param> public WWGoertzel(int m, int N) { if (N <= 0) { throw new ArgumentOutOfRangeException("N"); } mN = N; mDelay = new DelayT <WWComplex>(1); mDelay.Fill(WWComplex.Zero()); mOsc = new WWQuadratureOscillatorInt(-m, N); }
public SlidingDFTbin(int m, int N, double compensation) { if (N <= 0) { throw new ArgumentOutOfRangeException("N"); } if (m < 0 || N <= m) { throw new ArgumentOutOfRangeException("m"); } mN = N; mCompensation = compensation; mM = m; double θ = 2.0 * Math.PI * m / N; mE = new WWComplex(Math.Cos(θ), Math.Sin(θ)); mDelay = new DelayT <WWComplex>(1); mDelay.Fill(WWComplex.Zero()); }