The experiment using this program is introduced on "Interface" No.4, CQ publishing Co.,Ltd, 2015. 本プログラムを使った実験は,CQ出版社のインターフェース 2015年4月号で紹介しています.
Dependencies: DSProcessingIO mbed
Diff: fftReal.hpp
- Revision:
- 0:c740f515e0b7
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/fftReal.hpp Tue Jul 15 10:14:37 2014 +0000 @@ -0,0 +1,37 @@ +//------------------------------------------------------------------- +// FFT class for real data (Header) +// Copyright (c) 2014 MIKAMI, Naoki, 2014/06/29 +//------------------------------------------------------------------- + +#ifndef FFT_REAL_HPP +#define FFT_REAL_HPP + +#include "mbed.h" +#include <complex> // requisite + +namespace Mikami +{ + typedef complex<float> Complex; // define "Complex" + + class FftReal + { + private: + const int N_FFT_; + Complex* wTable_; // twiddle factor + uint16_t* bTable_; // for bit reversal + Complex* u_; // working area + + FftReal(const FftReal& ); + FftReal& operator=(const FftReal& ); + + public: + // Constructor + explicit FftReal(uint16_t n); + // Destructor + ~FftReal(); + // Execute FFT + void Execute(const float x[], Complex y[]); + }; +} +#endif // FFT_REAL_HPP +