Function | Purposes |
ceil(x) | Rounds x to the smallest integer not less than x ceil (8.1) = 9.0 and ceil (-8.8) = -8.0 |
cos(x) | Trigonometric cosine of x (x in radians) |
exp(x) | Exponential function ex |
fabs(x) | Absolute value of x If x>0 then abs(x) is x If x=0 then abs(x) is 0.0 If x<0 then abs(x) is -x |
floor(x) | Rounds x to the largest integer not greater than x floor (8.2) = 8.0 and floor (-8.8 = -9.0) |
log(x) | Natural logarithm of x(base e) |
log10(x) | Logarithm of x (base 10) |
pow(x,y) | x raised to power y (xy) |
sin(x) | Trigonometric sine of x (x in radians) |
sqry(x) | Square root of x |
tan(x) | Trigonometric tangent of x (x in radians) |
Friday, May 27, 2011
Commonly used Math library functions.
Labels:
Library Functions (C++)
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment