This function evaluates the arc hyperbolic tangent.
ATANH — Function value. (Output)
X — Argument for which the arc hyperbolic tangent is desired. (Input)
Generic: ATANH (X)
Specific: The specific interface names are ATANH, DATANH, CATANH, and ZATANH
Single: ATANH (X)
Double: The double precision function name is DATANH.
Complex: The complex name is CATANH.
Double Complex: The double complex name is ZATANH.
ATANH(X) computes the inverse hyperbolic tangent of x, tanh−1x. The argument x must satisfy
where ε = AMACH(4) is the machine precision. Note that |x| must not be so close to one that the result is less accurate than half precision.
Informational error
Type Code
3 2 Result of ATANH(X) is accurate to less than one-half precision because the absolute value of the argument is too close to 1.0.
In this example, tanh−1(−1/4) is computed and printed.
USE ATANH_INT
USE UMACH_INT
IMPLICIT NONE
! Declare variables
INTEGER NOUT
REAL VALUE, X
! Compute
X = -0.25
VALUE = ATANH(X)
! Print the results
CALL UMACH (2, NOUT)
WRITE (NOUT,99999) X, VALUE
99999 FORMAT (' ATANH(', F6.3, ') = ', F6.3)
END
ATANH(-0.250) = -0.255
In this example, tanh−1(1/2 + i/2) is computed and printed.
USE ATANH_INT
USE UMACH_INT
IMPLICIT NONE
! Declare variables
INTEGER NOUT
COMPLEX VALUE, Z
! Compute
Z = (0.5, 0.5)
VALUE = ATANH(Z)
! Print the results
CALL UMACH (2, NOUT)
WRITE (NOUT,99999) Z, VALUE
99999 FORMAT (' ATANH((', F6.3, ',', F6.3, ')) = (', &
F6.3, ',', F6.3, ')')
END
ATANH(( 0.500, 0.500)) = ( 0.402, 0.554)
PHONE: 713.784.3131 FAX:713.781.9260 |