Computes tangent of vector elements.

Syntax

vsTan( n, a, y );

vmsTan( n, a, y, mode );

vdTan( n, a, y );

vmdTan( n, a, y, mode );

vcTan( n, a, y );

vmcTan( n, a, y, mode );

vzTan( n, a, y );

vmzTan( 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 vsTan, vmsTan

const double* for vdTan, vmdTan

const MKL_Complex8* for vcTan, vmcTan

const MKL_Complex16* for vzTan, vmzTan

Pointer to an array that contains the input vector a.

mode

const MKL_INT64

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

Output Parameters

Name

Type

Description

y

float* for vsTan, vmsTan

double* for vdTan, vmdTan

MKL_Complex8* for vcTan, vmcTan

MKL_Complex16* for vzTan, vmzTan

Pointer to an array that contains the output vector y.

Description

The v?Tan function computes tangent of vector elements.

Note that arguments abs(a[i]) ≤ 213 and abs(a[i]) ≤ 216 for single and double precisions respectively are called fast computational path. These are trigonometric function arguments for which VM provides the best possible performance. Avoid arguments that do not belong to the fast computational path in the VM High Accuracy (HA) and Low Accuracy (LA) functions. Alternatively, you can use VM Enhanced Performance (EP) functions that are fast on the entire function domain. However, these functions provide less accuracy.

Special Values for Real Function v?Tan(x)
Argument Result VM Error Status Exception
+0 +0    
-0 -0    
+ QNAN VML_STATUS_ERRDOM INVALID
- QNAN VML_STATUS_ERRDOM INVALID
QNAN QNAN    
SNAN QNAN   INVALID

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

Tan(z) = -i*Tanh(i*z).

Optimization Notice

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804

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