Returns the cosine of its radian argument. Format #include <math.h> double cos (double x); float cosf (float x); (Integrity servers, Alpha) long double cosl (long double x); (Integrity servers, Alpha) double cosd (double x); (Integrity servers, Alpha) float cosdf (float x); (Integrity servers, Alpha) long double cosdl (long double x); (Integrity servers, Alpha)
1 – Argument
x A radian expressed as a real value.
2 – Description
The cos functions return the cosine of their argument, measured in radians. The cosd functions return the cosine of their argument, measured in degrees. |x| = Infinity is an invalid argument.
3 – Return Values
x The cosine of the argument. HUGE_VAL Indicates that the argument is too large; errno is set to ERANGE.