资源简介
C语言实现cordic sinx的算法。
理论上速度比 math.h 中的sinx应该快很多,
VC6编译,代码绝对OK!
代码片段和文件信息
#include
#include
#include
typedef __int64 INT64;
/*
float tbl_arctan[] =
{
.785398163397448 .463647609000806 .244978663126864
.124354994546761 .624188099959573e-1 .312398334302683e-1
.156237286204768e-1 .781234106010111e-2 .390623013196697e-2
.195312251647882e-2 .976562189559319e-3 .488281211194898e-3
.244140620149362e-3 .122070311893670e-3 .610351561742088e-4
.305175781155261e-4 .152587890613158e-4 .762939453110197e-5
.381469726560650e-5 .190734863281019e-5 .953674316405961e-6
.476837158203089e-6 .238418579101557e-6 .119209289550780e-6
.596046447753905e-7 .298023223876953e-7 .149011611938477e-7
.745058059692383e-8 .372529029846191e-8 .186264514923096e-8
.931322574615479e-9 .465661287307739e-9 .232830643653870e-9
.116415321826935e-9 .582076609134674e-10 .291038304567337e-10
.145519152283669e-10 .727595761418343e-11 .363797880709171e-11
.181898940354586e-11 .909494701772928e-12 .454747350886464e-12
.227373675443232e-12 .113686837721616e-12 .568434188608080e-13
.284217094304040e-13 .142108547152020e-13 .710542735760100e-14
.355271367880050e-14 .177635683940025e-14 .888178419700125e-15
};
float tbl_cos[] =
{
.707106781186550 .894427190999916 .970142500145332
.992277876713667 .998052578482889 .999512076087081
.999877952034693 .999969483818786 .999992370692778
.999998092656822 .999999523163180 .999999880790732
.999999970197680 .999999992549423 .999999998137356
.999999999534336 .999999999883586 .999999999970898
.999999999992723 .999999999998181 .999999999999549
.999999999999888 .999999999999972 .999999999999997
.999999999999996 .999999999999996 1.00000000000000
1.00000000000000 .999999999999999 1.00000000000000
1.00000000000000 .999999999999999 1.00000000000000
1.00000000000000 .999999999999996 1.00000000000000
1.00000000000000 1.00000000000000 .999999999999999
.999999999999999 1.00000000000000 1.00000000000000
1.00000000000000 1.00000000000000 1.00000000000000
1.00000000000000 1.00000000000000 1.00000000000000
1.00000000000000 1.00000000000000 .999999999999996
};
float tbl_sin[] =
{
.707106781186550 .447213595499957 .242535625036332
.124034734589208 .062378286155180 .031234752377721
.015623093000542 .007812261592334
};
float f_tbl_arctan[] =
{
.785398163397448 .463647609000806 .244978663126864
.124354994546761 .624188099959573e-1 .312398334302683e-1
.156237286204768e-1 .781234106010111e-2 .390623013196697e-2
.19531225
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 188480 2009-04-09 19:11 cordic_sinx\Debug\my_sinx.exe
文件 229516 2009-04-09 19:11 cordic_sinx\Debug\my_sinx.ilk
文件 184836 2009-04-02 19:44 cordic_sinx\Debug\my_sinx.pch
文件 500736 2009-04-09 19:11 cordic_sinx\Debug\my_sinx.pdb
文件 7626 2009-04-09 19:11 cordic_sinx\Debug\sinx.obj
文件 33792 2009-04-09 19:11 cordic_sinx\Debug\vc60.idb
文件 45056 2009-04-09 19:11 cordic_sinx\Debug\vc60.pdb
文件 4291 2009-04-02 19:37 cordic_sinx\my_sinx.dsp
文件 537 2009-04-02 19:26 cordic_sinx\my_sinx.dsw
文件 41984 2009-06-03 12:31 cordic_sinx\my_sinx.ncb
文件 53760 2009-06-03 12:31 cordic_sinx\my_sinx.opt
文件 9819 2009-04-09 19:11 cordic_sinx\my_sinx.plg
文件 10905 2009-04-09 19:11 cordic_sinx\sinx.c
目录 0 2009-06-10 15:06 cordic_sinx\Debug
目录 0 2009-06-10 15:06 cordic_sinx
文件 351 2009-06-10 15:11 readme.txt
----------- --------- ---------- ----- ----
1311689 16
评论
共有 条评论