Intel® Math Kernel Library 2019 Developer Reference - Fortran

v?Abs

Computes absolute value of vector elements.

Syntax

call vsabs( n, a, y )

call vmsabs( n, a, y, mode )

call vdabs( n, a, y )

call vmdabs( n, a, y, mode )

call vcabs( n, a, y )

call vmcabs( n, a, y, mode )

call vzabs( n, a, y )

call vmzabs( n, a, y, mode )

Include Files

Input Parameters

Name

Type

Description

n

INTEGER, INTENT(IN)

Specifies the number of elements to be calculated.

a

DOUBLE PRECISION for vdabs, vmdabs

COMPLEX for vcabs, vmcabs

DOUBLE COMPLEX for vzabs, vmzabs

REAL, INTENT(IN) for vsabs, vmsabs

DOUBLE PRECISION, INTENT(IN) for vdabs, vmdabs

COMPLEX, INTENT(IN) for vcabs, vmcabs

DOUBLE COMPLEX, INTENT(IN) for vzabs, vmzabs

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.

Output Parameters

Name

Type

Description

y

DOUBLE PRECISION for vdabs, vmdabs, vzabs, vmzabs

REAL, INTENT(OUT) for vsabs, vmsabs, vcabs, vmcabs

DOUBLE PRECISION, INTENT(OUT) for vdabs, vmdabs, vzabs, vmzabs

Array that specifies the output vector y.

Description

The v?Abs function computes an absolute value of vector elements.

Special Values for Real Function v?Abs(x)
Argument Result Exception
+0 +0  
-0 +0  
+ +  
- +  
QNAN QNAN  
SNAN QNAN INVALID

Specifications for special values of the complex functions are defined according to the following formula

Abs(z) = Hypot(RE(z),IM(z)).