Intel® Math Kernel Library 2019 Developer Reference - Fortran

v?CopySign

Returns vector of elements of one argument with signs changed to match other argument elements.

Syntax

call vscopysign (n, a, y)

call vmscopysign (n, a, y, mode)

call vdcopysign (n, a, y)

call vmdcopysign (n, a, y, mode)

Include Files

Input Parameters

Name

Type

Description

n

INTEGER

Specifies the number of elements to be calculated.

a

REAL for vscopysign

REAL for vmscopysign

DOUBLE PRECISION for vdcopysign

DOUBLE PRECISION for vmdcopysign

Pointer to the array containing the input vector a.

mode

INTEGER (KIND=8)

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

Output Parameters

Name

Type

Description

y

REAL for vscopysign

REAL for vmscopysign

DOUBLE PRECISION for vdcopysign

DOUBLE PRECISION for vmdcopysign

Pointer to an array containing the output vector y.

Description

The v?CopySign function returns the first vector argument elements with the sign changed to match the sign of the second vector argument's corresponding elements.