vec_rsqrtes

Purpose

Returns a vector containing estimates of the reciprocal square roots of the corresponding elements of the given vector.

Syntax

d=vec_rsqrtes(a)

Result and argument types

The following table describes the types of the returned value and the function arguments.

d a
vector4double vector4double

Result value

The double-precision elements of a are first truncated to single-precision values. An estimate of the reciprocal square root of each single-precision element of a is then converted to double precision and saved in the corresponding element of the result.

Note:

The precision guarantee is specified by the following expression, where x is the value of each element of a and r is the value of the corresponding element of the result value:

| (r-1/√x) / 1/√x | ≤ 1/32

Special operands

Special operands are handled as follows:

Operand Estimate Exception
-Infinity QNaN2 VXSQRT
<0 QNaN2 VXSQRT
-0 -Infinity1 ZX
+0 +Infinity1 ZX
+Infinity +0 None
SNaN QNaN2 VXSNAN
QNaN QNaN None
  1. No result if FPSCRZE = 1.
  2. No result if FPSCRVE = 1.

Formula

d[0] = (double) (1 / √ (float) a[0])
d[1] = (double) (1 / √ (float) a[1])
d[2] = (double) (1 / √ (float) a[2])
d[3] = (double) (1 / √ (float) a[3])

Example

a =  (4.0, 16.0, 25.0,  64.0)
d: (0.5, 0.25,  0.2, 0.125)