Intel® Math Kernel Library 2019 Developer Reference - Fortran
Computes hyperbolic tangent of vector elements.
call vstanh( n, a, y )
call vmstanh( n, a, y, mode )
call vdtanh( n, a, y )
call vmdtanh( n, a, y, mode )
call vctanh( n, a, y )
call vmctanh( n, a, y, mode )
call vztanh( n, a, y )
call vmztanh( n, a, y, mode )
Name |
Type |
Description |
|---|---|---|
n |
INTEGER, INTENT(IN) |
Specifies the number of elements to be calculated. |
a |
DOUBLE PRECISION for vdtanh, vmdtanh COMPLEX for vctanh, vmctanh DOUBLE COMPLEX for vztanh, vmztanh REAL, INTENT(IN) for vstanh, vmstanh DOUBLE PRECISION, INTENT(IN) for vdtanh, vmdtanh COMPLEX, INTENT(IN) for vctanh, vmctanh DOUBLE COMPLEX, INTENT(IN) for vztanh, vmztanh |
Array that specifies the input vector a. |
mode |
INTEGER(KIND=8), INTENT(IN) |
Overrides global VM mode setting for this function call. See vmlSetMode for possible values and their description. |
Name |
Type |
Description |
|---|---|---|
y |
DOUBLE PRECISION for vdtanh, vmdtanh COMPLEX for vctanh, vmctanh DOUBLE COMPLEX for vztanh, vmztanh REAL, INTENT(OUT) for vstanh, vmstanh DOUBLE PRECISION, INTENT(OUT) for vdtanh, vmdtanh COMPLEX, INTENT(OUT) for vctanh, vmctanh DOUBLE COMPLEX, INTENT(OUT) for vztanh, vmztanh |
Array that specifies the output vector y. |
The v?Tanh function computes hyperbolic tangent of vector elements.
| Argument | Result | Exception |
|---|---|---|
| +0 | +0 | |
| -0 | -0 | |
| +∞ | +1 | |
| -∞ | -1 | |
| QNAN | QNAN | |
| SNAN | QNAN | INVALID |
See Special Value Notations for the conventions used in the table below.
RE(z) i·IM(z) |
-∞
|
-X
|
-0
|
+0
|
+X
|
+∞
|
NAN
|
|---|---|---|---|---|---|---|---|
| +i·∞ | -1+i·0 |
QNAN+i·QNAN INVALID |
QNAN+i·QNAN INVALID |
QNAN+i·QNAN INVALID |
QNAN+i·QNAN INVALID |
+1+i·0 |
QNAN+i·QNAN |
| +i·Y | -1+i·0·Tan(Y) |
+1+i·0·Tan(Y) |
QNAN+i·QNAN |
||||
| +i·0 | -1+i·0 |
-0+i·0 |
+0+i·0 |
+1+i·0 |
QNAN+i·0 |
||
| -i·0 | -1-i·0 |
-0-i·0 |
+0-i·0 |
+1-i·0 |
QNAN-i·0 |
||
| -i·Y | -1+i·0·Tan(Y) |
+1+i·0·Tan(Y) |
QNAN+i·QNAN |
||||
| -i·∞ | -1-i·0 |
QNAN+i·QNAN INVALID |
QNAN+i·QNAN INVALID |
QNAN+i·QNAN INVALID |
QNAN+i·QNAN INVALID |
+1-i·0 |
QNAN+i·QNAN |
| +i·NAN | -1+i·0 |
QNAN+i·QNAN |
QNAN+i·QNAN |
QNAN+i·QNAN |
QNAN+i·QNAN |
+1+i·0 |
QNAN+i·QNAN |
Notes:
raises INVALID exception when real or imaginary part of the argument is SNAN
Tanh(CONJ(z))=CONJ(Tanh(z))
Tanh(-z)=-Tanh(z).