Computes the base 2 logarithm of vector elements.

Syntax

vsLog2 (n, a, y);

vmsLog2 (n, a, y, mode);

vdLog2 (n, a, y);

vmdLog2 (n, a, y, mode);

Include Files

  • mkl.h

Input Parameters

Name

Type

Description

n

const MKL_INT

Specifies the number of elements to be calculated.

a

const float* for vsLog2

const float* for vmsLog2

const double* for vdLog2

const double* for vmdLog2

Pointer to the array containing the input vector a.

mode

const MKL_INT64

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

Output Parameters

Name

Type

Description

y

float* for vsLog2

float* for vmsLog2

double* for vdLog2

double* for vmdLog2

Pointer to an array containing the output vector y.

Description

The v?Log2 function computes the base 2 logarithm of vector elements.

See Special Value Notations for the conventions used in this table:

Special values for Real Function v?Log2(x)
Argument Result VM Error Status Exception
+1 +0    
x < +0 QNAN VML_STATUS_ERRDOM INVALID
+0 - VML_STATUS_SING ZERODIVIDE
-0 - VML_STATUS_SING ZERODIVIDE
- QNAN VML_STATUS_ERRDOM INVALID
+ +    
QNAN QNAN    
SNAN QNAN   INVALID

See Also

有关编译器优化的更完整信息,请参阅优化通知
选择粘滞按钮颜色: 
Orange (only for download buttons)