Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

__sinpif(3) [osx man page]

__SINPI(3)						   BSD Library Functions Manual 						__SINPI(3)

NAME
__sinpi -- sine-pi function SYNOPSIS
#include <math.h> float __sinpif(float x); double __sinpi(double x); DESCRIPTION
The __sinpi() function returns the sine of pi times x (measured in radians). This can be computed more accurately than sin(M_PI * x), because it can implicitly use as many bits of pi as are necessary to deliver a well-rounded result, instead of the 53-bits to which M_PI is limited. For large x it may also be more efficient, as the argument reduction involved is significantly simpler. This function may be especially useful for working with degrees; whereas sin(M_PI * x / 180.0) cannot produce exact results for angles that naively "should" be exact, like 180 degrees, __sinpi(x / 180.0) can be computed exactly. SPECIAL VALUES
__sinpi(-x) is the same as - __sinpi(x) for any finite x. __sinpi(+-0) returns +-0. __sinpi(n) returns +0 for any positive integer n. __sinpi(n + 0.5) returns +1 for any even integer n. __sinpi(n + 0.5) returns -1 for any odd integer n. __sinpi(+-infinity) raises the invalid floating-point exception and returns NaN. VECTOR OPERATIONS
If you need to apply the __sinpi() function to SIMD vectors or arrays, using the following functions provided by the Accelerate.framework may be useful: #include <Accelerate/Accelerate.h> vFloat vsinpif(vFloat x); void vvsinpif(float *y, float *x, const int n); void vvsinpi(double *y, double *x, const int n); SEE ALSO
__cospi(3), __tanpi(3), __sincospi(3), math(3) BSD
December 15, 2012 BSD

Check Out this Related Man Page

__SINPI(3)						   BSD Library Functions Manual 						__SINPI(3)

NAME
__sinpi -- sine-pi function SYNOPSIS
#include <math.h> float __sinpif(float x); double __sinpi(double x); DESCRIPTION
The __sinpi() function returns the sine of pi times x (measured in radians). This can be computed more accurately than sin(M_PI * x), because it can implicitly use as many bits of pi as are necessary to deliver a well-rounded result, instead of the 53-bits to which M_PI is limited. For large x it may also be more efficient, as the argument reduction involved is significantly simpler. This function may be especially useful for working with degrees; whereas sin(M_PI * x / 180.0) cannot produce exact results for angles that naively "should" be exact, like 180 degrees, __sinpi(x / 180.0) can be computed exactly. SPECIAL VALUES
__sinpi(-x) is the same as - __sinpi(x) for any finite x. __sinpi(+-0) returns +-0. __sinpi(n) returns +0 for any positive integer n. __sinpi(n + 0.5) returns +1 for any even integer n. __sinpi(n + 0.5) returns -1 for any odd integer n. __sinpi(+-infinity) raises the invalid floating-point exception and returns NaN. VECTOR OPERATIONS
If you need to apply the __sinpi() function to SIMD vectors or arrays, using the following functions provided by the Accelerate.framework may be useful: #include <Accelerate/Accelerate.h> vFloat vsinpif(vFloat x); void vvsinpif(float *y, float *x, const int n); void vvsinpi(double *y, double *x, const int n); SEE ALSO
__cospi(3), __tanpi(3), __sincospi(3), math(3) BSD
December 15, 2012 BSD
Man Page

3 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Comparing Negative #'s in IF Statements

Hi, I am writing a BASH shell script. I would like to construct an IF statement that allows me to determine if a variable is between -180 and 180. Example: if ; then echo 'WEST NOT WITHIN BOUNDS' fi However, I believe the negative sign is causing errors. What is the proper BASH... (6 Replies)
Discussion started by: msb65
6 Replies

2. Shell Programming and Scripting

Formatting Help needed(Sed)

I have a file called abc.txt which has following contents. 10.180.8.231=31608 10.180.8.232=29011 10.180.8.233=31606 10.180.8.234=40501 10.180.8.235=32591 10.180.8.236=31605 10.180.8.237=30561 10.180.8.238=14231 How would i find a ip address having maximum number of ram available. Here... (2 Replies)
Discussion started by: pinga123
2 Replies

3. UNIX for Dummies Questions & Answers

[solved] Error Executing the script.

# cat SERVERNAMES 10.180.8.231 10.180.8.232 10.180.8.233 10.180.8.234 10.180.8.235 10.180.8.236 10.180.8.237 10.180.8.238 10.180.9.239 fn_Exit() { echo "Machine Doesnt exist" exit 1 #exit shell script } (2 Replies)
Discussion started by: pinga123
2 Replies