Cosine function Algorithm Explanation: The function cos() is evaluated by reducing the argument to the domain [-pi/2,pi/2] and then using Chebyshev polynomials to evaluate the function over the restricted range. The sign of the result is then adjusted if the (reduced) input value is on quadrants 2 or 3. This approximation is accurate to 17 bits of mantissa. - x the input angle Return the cosine o
| 593 | // - x the input angle |
| 594 | // Return the cosine of the angle |
| 595 | inline __m128 sseCos(const __m128 x) |
| 596 | { |
| 597 | __m128 cos_x, xr, xr2, flip_sign_cos_x; |
| 598 | __sse_cos__(x, cos_x, xr, xr2, flip_sign_cos_x); |
| 599 | return cos_x; |
| 600 | } |
| 601 | |
| 602 | // Sine function |
| 603 | // |