306
double cos(double x);
float cosf(float x);
Cosine function
double cosh(double x);
float coshf(float x);
Hyperbolic cosine function,
cosh(x)=(e^x+e^(-x))/2
double exp(double x);
float expf(float x);
Exponent (e^x) of a nature data
double fabs(double x);
float fabsf(float x);
Absolute value of parameter x
double floor(double x);
float floorf(float x);
Return the largest double
integer which is smaller or
equals with
x
double fmod(double x,
double y);
float fmodf(float x, float y);
If
y
is not zero, return the
reminder of floating
x/y
double frexp(double val, int
_far *exp);
float frexpf(float val, int
_far *exp);
Break floating data
x
to be
mantissa and exponent
x
=
m*2^exp, return the mantissa
of m, save the logarithm into
exp
.
double ldexp(double x, int
exp);
float ldexpf(float x, int
exp);
X multiply the (two to the
power of n) is x*2^n.
double log(double x);
float logf(float x);
Nature logarithm logic
double log10(double x);
float log10f(float x);
logarithm (log10x)
double modf(double val,
double *pd);
float modff(float val, float
*pd);
Break floating data X to be
integral part and decimal part,
return the decimal part, save
the integral part into parameter
ip.
double pow(double x, double
y);
float powf(float x, float y);
Power value of parameter
y
(x^y)
double sin(double x);
float sinf(float x);
sine function
double sinh(double x);
float sinhf(float x);
Hyperbolic sine function,
sinh(x)=(e^x-e^(-x))/2
double sqrt(double x);
float sqrtf(float x);
Square root of parameter X
double tan(double x);
float tanf(float x);
Tangent function.
double tanh(double x);
float tanhf(float x);
hyperbolic tangent function
tanh(x)=(e^x-e^(-x))/(e^2+e^(-
x))
The using method of the functions in the table:
float asinf
(
float x
)
;
float asinf: float means the return value is float format;
float x: float means the function formal parameter is float format. In actual using, it do not
need to write the float. See line 14 in the following example: