Numeric Functions Inherited from C
C++ inherited many numeric functions from C. They need the header <cmath>
. The table below shows the names of these functions.
pow |
sin |
tanh |
asinh |
fabs |
exp |
cos |
asin |
aconsh |
fmod |
sqrt |
tan |
acos |
atanh |
frexp |
log |
sinh |
atan |
ceil |
ldexp |
log10 |
cosh |
atan2 |
floor |
modf |
Additionally, C++ inherits further mathematical functions from C. They are defined in the header <cstdlib>
. Once more, the names.
abs |
llabs |
ldiv |
srand |
labs |
div |
lldiv |
rand |
All functions for integers are available for the types int
, long
and long long
; all functions for floating point numbers are available for the types...