GFLIB_Sin12Tlr‌‌ Sample Clauses

GFLIB_Sin12Tlr‌‌. GFLIB_Sin12Tlr
GFLIB_Sin12Tlr‌‌. Because the x value is shifted one bit to the left the polynomial coefficients 'c' need to be scaled (shifted to the right): b1 = c1 / 21 = pi / 2 b3 = c3 / 23 = -pi3 / 3! / 23 b5 = c5 / 25 = pi5 / 5! / 25 b7 = c7 / 27 = -pi7 / 7! / 27 b9 = c9 / 29 = pi / 9! / 29 To avoid the saturation error during the polynomial calculation the coefficients 'b' are divided by 2. After the polynomial calculation the result is multiplied by 2 (shifted 1 bit to the left) to take the right result of the function sin(pi * x) in the range <-1; 1) of the given x. a1 = b1 / 2 = pi / 22 = 0.785398163 a3 = b3 / 2 = -pi3 / 3! / 24 = -0.322982049 a5 = b5 / 2 = pi5 / 5! / 26 = 0.039846313 a7 = b7 / 2 = -pi7 / 7! / 28 = -0.002340877 a9 = b9 / 2 = pi9 / 9! / 210 = 0.000080220 sin  x = x « 1a + x « 12a + x « 12a + x « 12a + x « 1a  « 1