Interface 2015年4月号 第1部 第7章のプログラム

Dependencies:   USBDevice mbed

Information

FftTest - Interface 2015年4月号 第1部 第7章 のソフトウェア

Program for Section 7 in April 2015 issue of Interface
(Japanese electronics magazine)

概要

このプログラムは、

  • ハイパスフィルタ、ローパスフィルタ、ノッチフィルタ
    を行うFilterTestクラス、
  • FFT (256点)
    を行うFftTestクラス、
    波形をUSBシリアル通信でホストへ送信するmain関数で構成されています。

FilterTest.h, FilterTest.cpp

  • A-Dサンプリング - 1 kSPS
  • ハイパスフィルタ(遮断周波数 0.5 Hz、1次バターワース)
  • ローパスフィルタ(遮断周波数 30 Hz、2次バターワース)
  • ノッチフィルタ(中心周波数 50 Hz、2次)

FftTest.h, FftTest.cpp

  • 256点FFT演算 - クーリー-テューキー アルゴリズム 基数-2 時間間引き
  • ハン窓(ハニング窓)適用
  • パワー値計算
  • 振幅値計算
  • 振幅値正規化(実効値にスケーリング)

main.cpp

  • データ送信レート - 200 SPS
  • メインループ - ポーリングにより、サンプリング、フィルタ処理完了フラグがセットされたら、
    また、FFT完了フラグがセットされたらUSBシリアル通信経由で、ホストへ送信する

シリアル通信フォーマット

 (※)誌面ではパケットサイズ 64 byteとなっていますが、
    64 byteでは、PCのUSBドライバが 4096 byteまで保持し、波形が滑らかに描画できないため、
    Ver.1.0.2で、32 byteに変更しています。

  • 34byte固定長パケット方式
  • 波形データパケット、FFTパケットの2種類
波形データパケットFFTパケット
0x00パケットヘッダ(固定値0xAA)パケットヘッダ(固定値0xAA)
0x01データ種別ID(0x01: 波形データ)(0x02: FFTデータ)
0x02パケット番号(0 - 99繰り返し)レンジ(0: DC - 23 Hz, 1: 23 - 46 Hz, 2: 46 - 70 Hz)
0x03ペイロードサイズ(固定値30)ペイロードサイズ(固定値30)
0x04 - 0x21波形データ(short, big endian)FFTデータ(unsigned short, big endian)

Description

This contains FilterTest class, FftTest class and main function.

FilterTest class:

  • High pass filter, Low pass, Notch filter

FftTest class:

  • FFT (256 points)

Main function:

  • Send waveform and FFT data to host via USB serial class.

FilterTest.h, FilterTest.cpp

  • A-D sampling - 1 kSPS
  • High pass filter - Cut off frequency 0.5 Hz, first order butterworth
  • Low pass filter - Cut off frequency 30 Hz, second order butterworth
  • Notch filter - Center frequency 50 Hz, second order

FftTest.h, FftTest.cpp

  • 256 points FFT - Cooley-Tukey algorithm Radix-2 Decimation-In-Time
  • Apply Hann window
  • Calculate power spectrum
  • Calculate amplitude spectrum
  • Normalize amplitude

main.cpp

  • Data sending rate - 200 SPS
  • Main loop - sending waveform and FFT data via USB serial interface when detecting ready flag.

Packet format for USB serial interface

  • Packet size: 34 bytes(fixed)
  • Two types of packet, waveform packet and FFT packet
Waveform packetFFT packet
0x00Packet header (0xAA (fixed))Packet header (0xAA (fixed))
0x01Data type ID (0x01: Waveform ID)(0x02: FFT ID)
0x02Packet number (0 - 99)Range (0: DC - 23 Hz, 1: 23 - 46 Hz, 2: 46 - 70 Hz)
0x03Payload size (30 (fixed))Payload size (30 (fixed))
0x04 - 0x21Waveform data (short, big endian)FFT data (unsigned short, big endian)
Committer:
t_tatsuoka
Date:
Thu Jul 30 10:26:38 2015 +0000
Revision:
1:537eb14c5332
Parent:
0:9779b89a8820
Notch filter 60 Hz version

Who changed what in which revision?

UserRevisionLine numberNew contents of line
t_tatsuoka 0:9779b89a8820 1 /**
t_tatsuoka 0:9779b89a8820 2 * @file FftTest.cpp
t_tatsuoka 0:9779b89a8820 3 * @brief Calculate 256 point FFT with Hann window
t_tatsuoka 0:9779b89a8820 4 * Cooley-Tukey algorithm Radix-2 Decimation-In-Time
t_tatsuoka 0:9779b89a8820 5 * @date 2015.02.24
t_tatsuoka 0:9779b89a8820 6 * @version 1.0.2
t_tatsuoka 0:9779b89a8820 7 */
t_tatsuoka 0:9779b89a8820 8 #include "FftTest.h"
t_tatsuoka 0:9779b89a8820 9
t_tatsuoka 0:9779b89a8820 10 /** Constructor
t_tatsuoka 0:9779b89a8820 11 */
t_tatsuoka 0:9779b89a8820 12 FftTest::FftTest()
t_tatsuoka 0:9779b89a8820 13 {
t_tatsuoka 0:9779b89a8820 14 init();
t_tatsuoka 0:9779b89a8820 15 }
t_tatsuoka 0:9779b89a8820 16
t_tatsuoka 0:9779b89a8820 17 /** Destructor
t_tatsuoka 0:9779b89a8820 18 */
t_tatsuoka 0:9779b89a8820 19 FftTest::~FftTest()
t_tatsuoka 0:9779b89a8820 20 {
t_tatsuoka 0:9779b89a8820 21 }
t_tatsuoka 0:9779b89a8820 22
t_tatsuoka 0:9779b89a8820 23 /** Apply window fucntion
t_tatsuoka 0:9779b89a8820 24 * @param in_data[] Input data
t_tatsuoka 0:9779b89a8820 25 * @param out_data[] Output data
t_tatsuoka 0:9779b89a8820 26 */
t_tatsuoka 0:9779b89a8820 27 void FftTest::apply_window(float in_data[], float out_data[])
t_tatsuoka 0:9779b89a8820 28 {
t_tatsuoka 0:9779b89a8820 29 int i;
t_tatsuoka 0:9779b89a8820 30 for(i = 0; i < _dat_len; i++) {
t_tatsuoka 0:9779b89a8820 31 out_data[i] = in_data[i] * _window_array[i];
t_tatsuoka 0:9779b89a8820 32 }
t_tatsuoka 0:9779b89a8820 33 }
t_tatsuoka 0:9779b89a8820 34
t_tatsuoka 0:9779b89a8820 35 /** Calculate FFT
t_tatsuoka 0:9779b89a8820 36 * @param in_data Input data
t_tatsuoka 0:9779b89a8820 37 * @param out_re_data Output real data
t_tatsuoka 0:9779b89a8820 38 * @param out_im_data Output imaginary data
t_tatsuoka 0:9779b89a8820 39 */
t_tatsuoka 0:9779b89a8820 40 void FftTest::calc_fft(float in_data[], float out_re_data[], float out_im_data[])
t_tatsuoka 0:9779b89a8820 41 {
t_tatsuoka 0:9779b89a8820 42 int i, stage, phase, block, upper_idx, lower_idx;
t_tatsuoka 0:9779b89a8820 43 int32_t block_dist, butterfly_num;
t_tatsuoka 0:9779b89a8820 44 float w_re, w_im, u_re, u_im, temp_re, temp_im, temp_w_re, temp_w_im;
t_tatsuoka 0:9779b89a8820 45
t_tatsuoka 0:9779b89a8820 46 /* Bit reversal */
t_tatsuoka 0:9779b89a8820 47 for (i = 0; i < _dat_len; i++) {
t_tatsuoka 0:9779b89a8820 48 out_re_data[i] = in_data[_br_idx_array[i]];
t_tatsuoka 0:9779b89a8820 49 out_im_data[i] = 0.0f;
t_tatsuoka 0:9779b89a8820 50 }
t_tatsuoka 0:9779b89a8820 51
t_tatsuoka 0:9779b89a8820 52 /* Butterfly */
t_tatsuoka 0:9779b89a8820 53 for (stage = 1; stage <= _digit_len; stage++) {
t_tatsuoka 0:9779b89a8820 54 block_dist = 1 << stage;
t_tatsuoka 0:9779b89a8820 55 butterfly_num = block_dist >> 1;
t_tatsuoka 0:9779b89a8820 56
t_tatsuoka 0:9779b89a8820 57 w_re = 1.0f;
t_tatsuoka 0:9779b89a8820 58 w_im = 0.0f;
t_tatsuoka 0:9779b89a8820 59 u_re = cosf(PI / butterfly_num);
t_tatsuoka 0:9779b89a8820 60 u_im = -sinf(PI / butterfly_num);
t_tatsuoka 0:9779b89a8820 61
t_tatsuoka 0:9779b89a8820 62 for (phase = 0; phase < butterfly_num; phase++) {
t_tatsuoka 0:9779b89a8820 63 for (block = phase; block < _dat_len; block += block_dist) {
t_tatsuoka 0:9779b89a8820 64 upper_idx = block;
t_tatsuoka 0:9779b89a8820 65 lower_idx = upper_idx + butterfly_num;
t_tatsuoka 0:9779b89a8820 66 temp_re = out_re_data[lower_idx] * w_re - out_im_data[lower_idx] * w_im;
t_tatsuoka 0:9779b89a8820 67 temp_im = out_re_data[lower_idx] * w_im + out_im_data[lower_idx] * w_re;
t_tatsuoka 0:9779b89a8820 68 out_re_data[lower_idx] = out_re_data[upper_idx] - temp_re;
t_tatsuoka 0:9779b89a8820 69 out_im_data[lower_idx] = out_im_data[upper_idx] - temp_im;
t_tatsuoka 0:9779b89a8820 70 out_re_data[upper_idx] += temp_re;
t_tatsuoka 0:9779b89a8820 71 out_im_data[upper_idx] += temp_im;
t_tatsuoka 0:9779b89a8820 72 }
t_tatsuoka 0:9779b89a8820 73 temp_w_re = w_re * u_re - w_im * u_im;
t_tatsuoka 0:9779b89a8820 74 temp_w_im = w_re * u_im + w_im * u_re;
t_tatsuoka 0:9779b89a8820 75 w_re = temp_w_re;
t_tatsuoka 0:9779b89a8820 76 w_im = temp_w_im;
t_tatsuoka 0:9779b89a8820 77 }
t_tatsuoka 0:9779b89a8820 78 }
t_tatsuoka 0:9779b89a8820 79 }
t_tatsuoka 0:9779b89a8820 80
t_tatsuoka 0:9779b89a8820 81 /** Calculate Power spectrum
t_tatsuoka 0:9779b89a8820 82 * @param re_data[] Input real data
t_tatsuoka 0:9779b89a8820 83 * @param im_data[] Input imaginary data
t_tatsuoka 0:9779b89a8820 84 * @param pow_data[] Power data
t_tatsuoka 0:9779b89a8820 85 * @param len Data length
t_tatsuoka 0:9779b89a8820 86 */
t_tatsuoka 0:9779b89a8820 87 void FftTest::calc_power(float re_data[], float im_data[], float pow_data[], int32_t len)
t_tatsuoka 0:9779b89a8820 88 {
t_tatsuoka 0:9779b89a8820 89 int i;
t_tatsuoka 0:9779b89a8820 90 int32_t d_len = (len > _dat_len)? _dat_len : len;
t_tatsuoka 0:9779b89a8820 91 for(i = 0; i < d_len; i++) {
t_tatsuoka 0:9779b89a8820 92 pow_data[i] = re_data[i] * re_data[i] + im_data[i] * im_data[i];
t_tatsuoka 0:9779b89a8820 93 }
t_tatsuoka 0:9779b89a8820 94 }
t_tatsuoka 0:9779b89a8820 95
t_tatsuoka 0:9779b89a8820 96 /** Calculate Amplitude spectrum
t_tatsuoka 0:9779b89a8820 97 * @param pow_data[] Input power data
t_tatsuoka 0:9779b89a8820 98 * @param amp_data[] Output amplitude data
t_tatsuoka 0:9779b89a8820 99 * @param len Data length
t_tatsuoka 0:9779b89a8820 100 */
t_tatsuoka 0:9779b89a8820 101 void FftTest::calc_amplitude(float pow_data[], float amp_data[], int32_t len)
t_tatsuoka 0:9779b89a8820 102 {
t_tatsuoka 0:9779b89a8820 103 int i;
t_tatsuoka 0:9779b89a8820 104 int32_t d_len = (len > _dat_len)? _dat_len : len;
t_tatsuoka 0:9779b89a8820 105 for(i = 0; i < d_len; i++) {
t_tatsuoka 0:9779b89a8820 106 amp_data[i] = sqrtf(pow_data[i]);
t_tatsuoka 0:9779b89a8820 107 }
t_tatsuoka 0:9779b89a8820 108 }
t_tatsuoka 0:9779b89a8820 109
t_tatsuoka 0:9779b89a8820 110 /** Normalize Amplitude spectrum
t_tatsuoka 0:9779b89a8820 111 * @param pow_data[] Input power data
t_tatsuoka 0:9779b89a8820 112 * @param amp_data[] Output amplitude data
t_tatsuoka 0:9779b89a8820 113 * @param len Data length
t_tatsuoka 0:9779b89a8820 114 */
t_tatsuoka 0:9779b89a8820 115 void FftTest::norm_amplitude(float amp_data[], int32_t len)
t_tatsuoka 0:9779b89a8820 116 {
t_tatsuoka 0:9779b89a8820 117 int i;
t_tatsuoka 0:9779b89a8820 118 int32_t d_len = (len > _dat_len)? _dat_len : len;
t_tatsuoka 0:9779b89a8820 119 amp_data[0] = amp_data[0] / (float)_dat_len;
t_tatsuoka 0:9779b89a8820 120 for(i = 1; i < d_len; i++) {
t_tatsuoka 0:9779b89a8820 121 amp_data[i] = amp_data[i] * SQRT_2F / (float)_dat_len;
t_tatsuoka 0:9779b89a8820 122 }
t_tatsuoka 0:9779b89a8820 123 }
t_tatsuoka 0:9779b89a8820 124
t_tatsuoka 0:9779b89a8820 125 /** Initialization
t_tatsuoka 0:9779b89a8820 126 */
t_tatsuoka 0:9779b89a8820 127 void FftTest::init()
t_tatsuoka 0:9779b89a8820 128 {
t_tatsuoka 0:9779b89a8820 129 _digit_len = get_digit_len(DATA_LENGTH);
t_tatsuoka 0:9779b89a8820 130 _dat_len = (1 << _digit_len);
t_tatsuoka 0:9779b89a8820 131
t_tatsuoka 0:9779b89a8820 132 #ifdef _LARGE_RAM
t_tatsuoka 0:9779b89a8820 133 _window_array = new float[_dat_len];
t_tatsuoka 0:9779b89a8820 134 _br_idx_array = new int32_t[_dat_len];
t_tatsuoka 0:9779b89a8820 135 set_hann_window();
t_tatsuoka 0:9779b89a8820 136 set_bit_reversal();
t_tatsuoka 0:9779b89a8820 137 #endif /* LARGE_RAM */
t_tatsuoka 0:9779b89a8820 138 }
t_tatsuoka 0:9779b89a8820 139
t_tatsuoka 0:9779b89a8820 140 /** Get digit length
t_tatsuoka 0:9779b89a8820 141 * @param val Source value
t_tatsuoka 0:9779b89a8820 142 * @return Digit length
t_tatsuoka 0:9779b89a8820 143 */
t_tatsuoka 0:9779b89a8820 144 int32_t FftTest::get_digit_len(int32_t val)
t_tatsuoka 0:9779b89a8820 145 {
t_tatsuoka 0:9779b89a8820 146 int32_t ret_val = 0;
t_tatsuoka 0:9779b89a8820 147 while( val > 1 ) {
t_tatsuoka 0:9779b89a8820 148 ret_val++;
t_tatsuoka 0:9779b89a8820 149 val >>= 1;
t_tatsuoka 0:9779b89a8820 150 }
t_tatsuoka 0:9779b89a8820 151 return ret_val;
t_tatsuoka 0:9779b89a8820 152 }
t_tatsuoka 0:9779b89a8820 153
t_tatsuoka 0:9779b89a8820 154 /** Calculate Hann window function
t_tatsuoka 0:9779b89a8820 155 */
t_tatsuoka 0:9779b89a8820 156 void FftTest::set_hann_window()
t_tatsuoka 0:9779b89a8820 157 {
t_tatsuoka 0:9779b89a8820 158 #ifdef _LARGE_RAM
t_tatsuoka 0:9779b89a8820 159 int i;
t_tatsuoka 0:9779b89a8820 160 for(i = 0; i < _dat_len; i++) {
t_tatsuoka 0:9779b89a8820 161 _window_array[i] = (1.0f - cosf(2.0f * PI * i / (_dat_len - 1.0f))) / 2.0f;
t_tatsuoka 0:9779b89a8820 162 }
t_tatsuoka 0:9779b89a8820 163 #endif /* LARGE_RAM */
t_tatsuoka 0:9779b89a8820 164 }
t_tatsuoka 0:9779b89a8820 165
t_tatsuoka 0:9779b89a8820 166 /** Calculate bit reversal index
t_tatsuoka 0:9779b89a8820 167 */
t_tatsuoka 0:9779b89a8820 168 void FftTest::set_bit_reversal()
t_tatsuoka 0:9779b89a8820 169 {
t_tatsuoka 0:9779b89a8820 170 #ifdef _LARGE_RAM
t_tatsuoka 0:9779b89a8820 171 int i, j;
t_tatsuoka 0:9779b89a8820 172 int32_t reversed_max_bit = (_dat_len >> 1);
t_tatsuoka 0:9779b89a8820 173
t_tatsuoka 0:9779b89a8820 174 _br_idx_array[0] = 0;
t_tatsuoka 0:9779b89a8820 175 for (i = 1; i < _dat_len; i <<= 1) {
t_tatsuoka 0:9779b89a8820 176 for (j = 0; j < i; j++) {
t_tatsuoka 0:9779b89a8820 177 _br_idx_array[j + i] = _br_idx_array[j] + reversed_max_bit;
t_tatsuoka 0:9779b89a8820 178 }
t_tatsuoka 0:9779b89a8820 179 reversed_max_bit >>= 1;
t_tatsuoka 0:9779b89a8820 180 }
t_tatsuoka 0:9779b89a8820 181 #endif /* LARGE_RAM */
t_tatsuoka 0:9779b89a8820 182 }
t_tatsuoka 0:9779b89a8820 183
t_tatsuoka 0:9779b89a8820 184 #ifndef _LARGE_RAM
t_tatsuoka 0:9779b89a8820 185 /* Const */
t_tatsuoka 0:9779b89a8820 186 const float FftTest::_window_array[] = {
t_tatsuoka 0:9779b89a8820 187 0.0f, 0.000151774f, 0.0006070039f, 0.001365413f, 0.002426542f,
t_tatsuoka 0:9779b89a8820 188 0.003789745f, 0.005454196f, 0.007418883f, 0.009682614f, 0.01224402f,
t_tatsuoka 0:9779b89a8820 189 0.01510153f, 0.01825343f, 0.02169779f, 0.02543253f, 0.02945537f,
t_tatsuoka 0:9779b89a8820 190 0.03376389f, 0.03835545f, 0.04322727f, 0.0483764f, 0.05379971f,
t_tatsuoka 0:9779b89a8820 191 0.0594939f, 0.06545553f, 0.07168096f, 0.07816643f, 0.08490799f,
t_tatsuoka 0:9779b89a8820 192 0.09190154f, 0.09914286f, 0.1066275f, 0.114351f, 0.1223086f,
t_tatsuoka 0:9779b89a8820 193 0.1304955f, 0.1389068f, 0.1475372f, 0.1563817f, 0.1654347f, 0.1746908f, 0.1841445f, 0.1937899f, 0.2036212f, 0.2136324f,
t_tatsuoka 0:9779b89a8820 194 0.2238175f, 0.2341703f, 0.2446844f, 0.2553535f, 0.2661712f, 0.2771308f, 0.2882257f, 0.2994492f, 0.3107945f, 0.3222546f,
t_tatsuoka 0:9779b89a8820 195 0.3338226f, 0.3454915f, 0.3572542f, 0.3691036f, 0.3810324f, 0.3930334f, 0.4050995f, 0.4172231f, 0.4293969f, 0.4416136f,
t_tatsuoka 0:9779b89a8820 196 0.4538658f, 0.466146f, 0.4784467f, 0.4907605f, 0.50308f, 0.5153975f, 0.5277057f, 0.5399971f, 0.5522642f, 0.5644996f,
t_tatsuoka 0:9779b89a8820 197 0.5766958f, 0.5888455f, 0.6009412f, 0.6129757f, 0.6249415f, 0.6368315f, 0.6486384f, 0.6603551f, 0.6719745f, 0.6834894f,
t_tatsuoka 0:9779b89a8820 198 0.6948929f, 0.7061782f, 0.7173382f, 0.7283663f, 0.7392558f, 0.75f, 0.7605925f, 0.7710267f, 0.7812964f, 0.7913953f,
t_tatsuoka 0:9779b89a8820 199 0.8013173f, 0.8110564f, 0.8206066f, 0.8299623f, 0.8391176f, 0.848067f, 0.8568051f, 0.8653266f, 0.8736263f, 0.8816991f,
t_tatsuoka 0:9779b89a8820 200 0.8895403f, 0.897145f, 0.9045085f, 0.9116265f, 0.9184946f, 0.9251086f, 0.9314645f, 0.9375585f, 0.9433869f, 0.948946f,
t_tatsuoka 0:9779b89a8820 201 0.9542326f, 0.9592435f, 0.9639755f, 0.9684259f, 0.9725919f, 0.976471f, 0.9800608f, 0.9833592f, 0.9863641f, 0.9890738f,
t_tatsuoka 0:9779b89a8820 202 0.9914865f, 0.9936009f, 0.9954156f, 0.9969296f, 0.9981418f, 0.9990517f, 0.9996585f, 0.999962f, 0.999962f, 0.9996585f,
t_tatsuoka 0:9779b89a8820 203 0.9990517f, 0.9981418f, 0.9969296f, 0.9954156f, 0.9936009f, 0.9914865f, 0.9890738f, 0.9863641f, 0.9833592f, 0.9800608f,
t_tatsuoka 0:9779b89a8820 204 0.976471f, 0.9725919f, 0.9684259f, 0.9639755f, 0.9592435f, 0.9542326f, 0.948946f, 0.9433869f, 0.9375585f, 0.9314645f,
t_tatsuoka 0:9779b89a8820 205 0.9251086f, 0.9184946f, 0.9116265f, 0.9045085f, 0.897145f, 0.8895403f, 0.8816991f, 0.8736263f, 0.8653266f, 0.8568051f,
t_tatsuoka 0:9779b89a8820 206 0.848067f, 0.8391176f, 0.8299623f, 0.8206066f, 0.8110564f, 0.8013173f, 0.7913953f, 0.7812964f, 0.7710267f, 0.7605925f,
t_tatsuoka 0:9779b89a8820 207 0.75f, 0.7392558f, 0.7283663f, 0.7173382f, 0.7061782f, 0.6948929f, 0.6834894f, 0.6719745f, 0.6603551f, 0.6486384f,
t_tatsuoka 0:9779b89a8820 208 0.6368315f, 0.6249415f, 0.6129757f, 0.6009412f, 0.5888455f, 0.5766958f, 0.5644996f, 0.5522642f, 0.5399971f, 0.5277057f,
t_tatsuoka 0:9779b89a8820 209 0.5153975f, 0.50308f, 0.4907605f, 0.4784467f, 0.466146f, 0.4538658f, 0.4416136f, 0.4293969f, 0.4172231f, 0.4050995f,
t_tatsuoka 0:9779b89a8820 210 0.3930334f, 0.3810324f, 0.3691036f, 0.3572542f, 0.3454915f, 0.3338226f, 0.3222546f, 0.3107945f, 0.2994492f, 0.2882257f,
t_tatsuoka 0:9779b89a8820 211 0.2771308f, 0.2661712f, 0.2553535f, 0.2446844f, 0.2341703f, 0.2238175f, 0.2136324f, 0.2036212f, 0.1937899f, 0.1841445f,
t_tatsuoka 0:9779b89a8820 212 0.1746908f, 0.1654347f, 0.1563817f, 0.1475372f, 0.1389068f, 0.1304955f, 0.1223086f, 0.114351f, 0.1066275f, 0.09914286f,
t_tatsuoka 0:9779b89a8820 213 0.09190154f, 0.08490799f, 0.07816643f, 0.07168096f, 0.06545553f,
t_tatsuoka 0:9779b89a8820 214 0.0594939f, 0.05379971f, 0.0483764f, 0.04322727f, 0.03835545f,
t_tatsuoka 0:9779b89a8820 215 0.03376389f, 0.02945537f, 0.02543253f, 0.02169779f, 0.01825343f,
t_tatsuoka 0:9779b89a8820 216 0.01510153f, 0.01224402f, 0.009682614f, 0.007418883f, 0.005454196f,
t_tatsuoka 0:9779b89a8820 217 0.003789745f, 0.002426542f, 0.001365413f, 0.0006070039f, 0.000151774f,
t_tatsuoka 0:9779b89a8820 218 0.0f
t_tatsuoka 0:9779b89a8820 219 };
t_tatsuoka 0:9779b89a8820 220
t_tatsuoka 0:9779b89a8820 221 const int FftTest::_br_idx_array[] = {
t_tatsuoka 0:9779b89a8820 222 0, 128, 64, 192, 32, 160, 96, 224, 16, 144,
t_tatsuoka 0:9779b89a8820 223 80, 208, 48, 176, 112, 240, 8, 136, 72, 200,
t_tatsuoka 0:9779b89a8820 224 40, 168, 104, 232, 24, 152, 88, 216, 56, 184,
t_tatsuoka 0:9779b89a8820 225 120, 248, 4, 132, 68, 196, 36, 164, 100, 228,
t_tatsuoka 0:9779b89a8820 226 20, 148, 84, 212, 52, 180, 116, 244, 12, 140,
t_tatsuoka 0:9779b89a8820 227 76, 204, 44, 172, 108, 236, 28, 156, 92, 220,
t_tatsuoka 0:9779b89a8820 228 60, 188, 124, 252, 2, 130, 66, 194, 34, 162,
t_tatsuoka 0:9779b89a8820 229 98, 226, 18, 146, 82, 210, 50, 178, 114, 242,
t_tatsuoka 0:9779b89a8820 230 10, 138, 74, 202, 42, 170, 106, 234, 26, 154,
t_tatsuoka 0:9779b89a8820 231 90, 218, 58, 186, 122, 250, 6, 134, 70, 198,
t_tatsuoka 0:9779b89a8820 232 38, 166, 102, 230, 22, 150, 86, 214, 54, 182,
t_tatsuoka 0:9779b89a8820 233 118, 246, 14, 142, 78, 206, 46, 174, 110, 238,
t_tatsuoka 0:9779b89a8820 234 30, 158, 94, 222, 62, 190, 126, 254, 1, 129,
t_tatsuoka 0:9779b89a8820 235 65, 193, 33, 161, 97, 225, 17, 145, 81, 209,
t_tatsuoka 0:9779b89a8820 236 49, 177, 113, 241, 9, 137, 73, 201, 41, 169,
t_tatsuoka 0:9779b89a8820 237 105, 233, 25, 153, 89, 217, 57, 185, 121, 249,
t_tatsuoka 0:9779b89a8820 238 5, 133, 69, 197, 37, 165, 101, 229, 21, 149,
t_tatsuoka 0:9779b89a8820 239 85, 213, 53, 181, 117, 245, 13, 141, 77, 205,
t_tatsuoka 0:9779b89a8820 240 45, 173, 109, 237, 29, 157, 93, 221, 61, 189,
t_tatsuoka 0:9779b89a8820 241 125, 253, 3, 131, 67, 195, 35, 163, 99, 227,
t_tatsuoka 0:9779b89a8820 242 19, 147, 83, 211, 51, 179, 115, 243, 11, 139,
t_tatsuoka 0:9779b89a8820 243 75, 203, 43, 171, 107, 235, 27, 155, 91, 219,
t_tatsuoka 0:9779b89a8820 244 59, 187, 123, 251, 7, 135, 71, 199, 39, 167,
t_tatsuoka 0:9779b89a8820 245 103, 231, 23, 151, 87, 215, 55, 183, 119, 247,
t_tatsuoka 0:9779b89a8820 246 15, 143, 79, 207, 47, 175, 111, 239, 31, 159,
t_tatsuoka 0:9779b89a8820 247 95, 223, 63, 191, 127, 255
t_tatsuoka 0:9779b89a8820 248 };
t_tatsuoka 0:9779b89a8820 249 #endif /* LARGE_RAM */