v?Tanh

Computes hyperbolic tangent of vector elements.

Syntax

FORTRAN:

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 )

C:

vsTanh( n, a, y );

vmsTanh( n, a, y, mode );

vdTanh( n, a, y );

vmdTanh( n, a, y, mode );

vcTanh( n, a, y );

vmcTanh( n, a, y, mode );

vzTanh( n, a, y );

vmzTanh( n, a, y, mode );

Include Files

Input Parameters

Name

Type

Description

n

FORTRAN 77: INTEGER

Fortran 90: INTEGER, INTENT(IN)

C: const int

Specifies the number of elements to be calculated.

a

FORTRAN 77: REAL for vstanh, vmstanh

DOUBLE PRECISION for vdtanh, vmdtanh

COMPLEX for vctanh, vmctanh

DOUBLE COMPLEX for vztanh, vmztanh

Fortran 90: 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

C: const float* for vsTanh, vmsTanh

const double* for vdTanh, vmdTanh

const MKL_Complex8* for vcTanh, vmcTanh

const MKL_Complex16* for vzTanh, vmzTanh

FORTRAN: Array that specifies the input vector a.

C: Pointer to an array that contains the input vector a.

mode

FORTRAN 77: INTEGER*8

Fortran 90: INTEGER(KIND=8), INTENT(IN)

C: const MKL_INT64

Overrides global VML mode setting for this function call. See vmlSetMode for possible values and their description.

Output Parameters

Name

Type

Description

y

FORTRAN 77: REAL for vstanh, vmstanh

DOUBLE PRECISION for vdtanh, vmdtanh

COMPLEX for vctanh, vmctanh

DOUBLE COMPLEX for vztanh, vmztanh

Fortran 90: 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

C: float* for vsTanh, vmsTanh

double* for vdTanh, vmdTanh

MKL_Complex8* for vcTanh, vmcTanh

MKL_Complex16* for vzTanh, vmzTanh

FORTRAN: Array that specifies the output vector y.

C: Pointer to an array that contains the output vector y.

Description

The v?Tanh function computes hyperbolic tangent of vector elements.

Special Values for Real Function v?Tanh(x)
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.

Special Values for Complex Function v?Tanh(z)

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:


Submit feedback on this help topic