This commit is contained in:
root
2026-09-19 20:21:47 +02:00
commit 0798933b05
62 changed files with 7658 additions and 0 deletions
+48
View File
@@ -0,0 +1,48 @@
package fixed
// Generated with arbitrary-precision arithmetic; atan(2^-i) in Q2.62.
var atanTable = [...]int64{
3622009729038561421,
2138197195906305896,
1129764675555192497,
573486189672913777,
287855953345232184,
144068303048368714,
72051730834756821,
36028064038054492,
18014306884351854,
9007187801521083,
4503598195715549,
2251799634728302,
1125899884473003,
562949950625109,
281474976361130,
140737488311637,
70368744172202,
35184372088149,
17592186044330,
8796093022197,
4398046511102,
2199023255551,
1099511627775,
549755813887,
274877906943,
137438953471,
68719476735,
34359738367,
17179869183,
8589934591,
4294967295,
2147483647,
1073741823,
536870911,
268435455,
134217727,
67108863,
33554431,
16777215,
8388607,
}
// cordicInvK is 1/K (the CORDIC gain compensation) in Q2.62.
const cordicInvK int64 = 2800459870029452953