The class
StrictMath
contains methods for performing basic
numeric operations such as the elementary exponential, logarithm,
square root, and trigonometric functions.
The class
StrictMath
contains methods for performing basic
numeric operations such as the elementary exponential, logarithm,
square root, and trigonometric functions.
To help ensure portability of Java programs, the definitions of
some of the numeric functions in this package require that they
produce the same results as certain published algorithms. These
algorithms are available from the well-known network library
netlib
as the package "Freely Distributable Math
Library," fdlibm
. These
algorithms, which are written in the C programming language, are
then to be understood as executed with all floating-point
operations following the rules of Java floating-point arithmetic.
The Java math library is defined with respect to
fdlibm
version 5.3. Where fdlibm
provides
more than one definition for a function (such as
acos
), use the "IEEE 754 core function" version
(residing in a file whose name begins with the letter
e
). The methods which require fdlibm
semantics are sin
, cos
, tan
,
asin
, acos
, atan
,
exp
, log
, log10
,
cbrt
, atan2
, pow
,
sinh
, cosh
, tanh
,
hypot
, expm1
, and log1p
.