updated package versions
[minix.git] / include / math.h
blob264fe0f738af83910925ec0805a8d2758c7fe427
1 /* The <math.h> header contains prototypes for mathematical functions. */
3 #ifndef _MATH_H
4 #define _MATH_H
6 #ifndef _ANSI_H
7 #include <ansi.h>
8 #endif
10 #define INFINITY (__infinity())
11 #define NAN (__qnan())
12 #define HUGE_VAL INFINITY
14 /* Function Prototypes. */
15 _PROTOTYPE( double __infinity, (void) );
16 _PROTOTYPE( double __qnan, (void) );
18 _PROTOTYPE( double acos, (double _x) );
19 _PROTOTYPE( double asin, (double _x) );
20 _PROTOTYPE( double atan, (double _x) );
21 _PROTOTYPE( double atan2, (double _y, double _x) );
22 _PROTOTYPE( double ceil, (double _x) );
23 _PROTOTYPE( double cos, (double _x) );
24 _PROTOTYPE( double cosh, (double _x) );
25 _PROTOTYPE( double exp, (double _x) );
26 _PROTOTYPE( double fabs, (double _x) );
27 _PROTOTYPE( double fabsf, (float _x) );
28 _PROTOTYPE( double floor, (double _x) );
29 _PROTOTYPE( double fmod, (double _x, double _y) );
30 _PROTOTYPE( double frexp, (double _x, int *_exp) );
31 _PROTOTYPE( double ldexp, (double _x, int _exp) );
32 _PROTOTYPE( double log, (double _x) );
33 _PROTOTYPE( double log10, (double _x) );
34 _PROTOTYPE( double modf, (double _x, double *_iptr) );
35 _PROTOTYPE( double pow, (double _x, double _y) );
36 _PROTOTYPE( double rint, (double _x) );
37 _PROTOTYPE( double scalbn, (double _x, int _exp) );
38 _PROTOTYPE( float scalbnf, (float _x, int _exp) );
39 _PROTOTYPE( double scalbln, (double _x, long _exp) );
40 _PROTOTYPE( float scalblnf, (float _x, long _exp) );
41 _PROTOTYPE( double sin, (double _x) );
42 _PROTOTYPE( double sinh, (double _x) );
43 _PROTOTYPE( double sqrt, (double _x) );
44 _PROTOTYPE( double tan, (double _x) );
45 _PROTOTYPE( double tanh, (double _x) );
46 _PROTOTYPE( double hypot, (double _x, double _y) );
48 #ifdef _POSIX_SOURCE /* STD-C? */
49 #include <mathconst.h>
51 #define FP_INFINITE 1
52 #define FP_NAN 2
53 #define FP_NORMAL 3
54 #define FP_SUBNORMAL 4
55 #define FP_ZERO 5
57 _PROTOTYPE( int fpclassify, (double x) );
58 _PROTOTYPE( int isfinite, (double x) );
59 _PROTOTYPE( int isinf, (double x) );
60 _PROTOTYPE( int isnan, (double x) );
61 _PROTOTYPE( int isnormal, (double x) );
62 _PROTOTYPE( int signbit, (double x) );
63 _PROTOTYPE( int isgreater, (double x, double y) );
64 _PROTOTYPE( int isgreaterequal, (double x, double y) );
65 _PROTOTYPE( int isless, (double x, double y) );
66 _PROTOTYPE( int islessequal, (double x, double y) );
67 _PROTOTYPE( int islessgreater, (double x, double y) );
68 _PROTOTYPE( int isunordered, (double x, double y) );
69 _PROTOTYPE( double nearbyint, (double x) );
70 _PROTOTYPE( double remainder, (double x, double y) );
71 _PROTOTYPE( double trunc, (double x) );
72 #endif
74 #endif /* _MATH_H */