📄 t000016.c
字号:
/*
* Copyright (C) ARM Limited 1998-2000. All rights reserved.
*
* t000016.c
*
* Tests for FFT's of size N=16
*/
#include "testfft.h"
static const comp ffttest_16_0_in[16] = {
{ 0.012879855101630106, 0.000000000000000000 },
{ 0.053330650030187159, 0.000000000000000000 },
{ 0.097403904206077682, 0.000000000000000000 },
{ 0.145099617629301680, 0.000000000000000000 },
{ 0.196417790299859150, 0.000000000000000000 },
{ 0.251358422217750070, 0.000000000000000000 },
{ 0.309921513382974470, 0.000000000000000000 },
{ 0.372107063795532270, 0.000000000000000000 },
{ 0.437915073455423630, 0.000000000000000000 },
{ 0.507345542362648390, 0.000000000000000000 },
{ 0.580398470517206610, 0.000000000000000000 },
{ 0.657073857919098340, 0.000000000000000000 },
{ 0.737371704568323570, 0.000000000000000000 },
{ 0.821292010464882210, 0.000000000000000000 },
{ 0.908834775608774350, 0.000000000000000000 },
{ 1.000000000000000000, 0.000000000000000000 }
};
static const comp ffttest_16_0_out[16] = {
{ 7.088750251559669200, 0.000000000000000000 },
{ -0.160245874305826150, 2.719558976621911900 },
{ -0.442011118337346350, 1.305978276445739500 },
{ -0.494009322954973680, 0.809594745430636920 },
{ -0.511974240289796660, 0.540953914268464510 },
{ -0.519994905647743640, 0.361453849613015850 },
{ -0.523978014284911530, 0.224070447908810530 },
{ -0.525890770506630360, 0.107602423730432860 },
{ -0.526464077279130580, 0.000000000000000033 },
{ -0.525890770506630360, -0.107602423730432790 },
{ -0.523978014284911530, -0.224070447908810500 },
{ -0.519994905647743640, -0.361453849613015580 },
{ -0.511974240289796660, -0.540953914268464290 },
{ -0.494009322954973680, -0.809594745430636920 },
{ -0.442011118337346460, -1.305978276445738800 },
{ -0.160245874305827600, -2.719558976621906600 }
};
static const comp ffttest_16_1_in[16] = {
{ 1.000000000000000000, 0.000000000000000000 },
{ 0.382683432365089840, -0.000000000000000000 },
{ -0.707106781186547460, -0.000000000000000008 },
{ -0.923879532511286850, -0.000000000000000013 },
{ -0.000000000000000184, 0.000000000000000000 },
{ 0.923879532511286520, 0.000000000000000001 },
{ 0.707106781186547680, 0.000000000000000011 },
{ -0.382683432365089890, 0.000000000000000015 },
{ -1.000000000000000000, 0.000000000000000000 },
{ -0.382683432365090560, 0.000000000000000011 },
{ 0.707106781186546570, 0.000000000000000008 },
{ 0.923879532511287400, -0.000000000000000007 },
{ 0.000000000000000551, 0.000000000000000000 },
{ -0.923879532511287070, 0.000000000000000012 },
{ -0.707106781186547350, 0.000000000000000007 },
{ 0.382683432365086280, 0.000000000000000014 }
};
static const comp ffttest_16_1_out[16] = {
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 8.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 8.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 }
};
static const comp ffttest_16_2_in[16] = {
{ 0.010765784565067413, 0.013627575398819510 },
{ 0.049885443194303672, 0.038732124453832326 },
{ 0.092837857404457921, 0.064986500183120535 },
{ 0.139623027195530160, 0.092390702586684151 },
{ 0.190240952567520380, 0.120944731664523160 },
{ 0.244691633520428580, 0.150648587416637560 },
{ 0.302975070054254840, 0.181502269843027360 },
{ 0.365091262168998950, 0.213505778943692520 },
{ 0.431040209864661130, 0.246659114718633140 },
{ 0.500821913141241250, 0.280962277167849110 },
{ 0.574436371998739310, 0.316415266291340480 },
{ 0.651883586437155380, 0.353018082089107230 },
{ 0.733163556456489670, 0.390770724561149470 },
{ 0.818276282056741740, 0.429673193707466930 },
{ 0.907221763237911820, 0.469725489528059980 },
{ 1.000000000000000000, 0.510927612022928360 }
};
static const comp ffttest_16_2_out[16] = {
{ 7.012954713863502200, 3.874490030576871500 },
{ -1.496620010784421400, 2.580473093760935900 },
{ -1.089653406735740200, 1.072311151336554400 },
{ -0.897075851981741560, 0.557616071102934650 },
{ -0.782086552138251620, 0.282295224386546310 },
{ -0.701038816473816610, 0.099596018612717122 },
{ -0.636726779723213570, -0.039551664075602101 },
{ -0.580656719372226290, -0.157050688989829740 },
{ -0.527591581565297290, -0.265226686199524720 },
{ -0.473313265316956890, -0.373038729876796200 },
{ -0.413195608246075650, -0.489323475775055580 },
{ -0.340454887656036430, -0.625942553311543800 },
{ -0.242434566344999130, -0.803549983391392280 },
{ -0.089429580209685069, -1.067466124220233700 },
{ 0.213181736327902910, -1.549151075918775700 },
{ 1.216393729398130600, -2.878439401636687700 }
};
static const comp ffttest_16_3_in[16] = {
{ 0.962756197956671000, 0.288826859387001310 },
{ 0.101589622537656880, 0.999999999999999780 },
{ -0.885002867065902140, 0.476540005343178360 },
{ -0.778941492181105980, -0.635272070191988950 },
{ 0.288826859387000760, -0.962756197956671220 },
{ 1.000000000000000000, -0.101589622537655970 },
{ 0.476540005343177420, 0.885002867065902700 },
{ -0.635272070191989390, 0.778941492181105640 },
{ -0.962756197956671440, -0.288826859387000150 },
{ -0.101589622537656560, -0.999999999999999780 },
{ 0.885002867065903030, -0.476540005343176640 },
{ 0.778941492181104200, 0.635272070191990950 },
{ -0.288826859387003030, 0.962756197956670450 },
{ -1.000000000000000000, 0.101589622537656240 },
{ -0.476540005343176420, -0.885002867065903140 },
{ 0.635272070191989950, -0.778941492181105200 }
};
static const comp ffttest_16_3_out[16] = {
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 15.404099167306736000, 4.621229750192021000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 },
{ 0.000000000000000000, 0.000000000000000000 }
};
static const tFFTTest FFTTest_16[4]={
{ 16, "parabola-real", (comp*)ffttest_16_0_in, (comp*)ffttest_16_0_out, 2 },
{ 16, "sinewave-real", (comp*)ffttest_16_1_in, (comp*)ffttest_16_1_out, 2 },
{ 16, "parabola-complex", (comp*)ffttest_16_2_in, (comp*)ffttest_16_2_out, 0 },
{ 16, "sinewave-complex", (comp*)ffttest_16_3_in, (comp*)ffttest_16_3_out, 0 }
};
extern const tFFTTests FFTTests_16;
const tFFTTests FFTTests_16 = {
4, 16, (tFFTTest*)FFTTest_16
};
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -