Computes a rounded integer value in the current rounding mode for each vector element with inexact result exception raised for each changed value.
FORTRAN:
call vsrint( n, a, y )
call vmsrint( n, a, y, mode )
call vdrint( n, a, y )
call vmdrint( n, a, y, mode )
C:
vsRint( n, a, y );
vmsRint( n, a, y, mode );
vdRint( n, a, y );
vmdRint( n, a, y, mode );
Name |
Type |
Description |
---|---|---|
n |
FORTRAN 77: INTEGER Fortran 90: INTEGER, INTENT(IN) C: const int |
Specifies the number of elements to be calculated. |
a |
FORTRAN 77: REAL for vsrint, vmsrint DOUBLE PRECISION for vdrint, vmdrint Fortran 90: REAL, INTENT(IN) for vsrint, vmsrint DOUBLE PRECISION, INTENT(IN) for vdrint, vmdrint C: const float* for vsRint, vmsrint const double* for vdRint, vmdrint |
FORTRAN: Array that specifies the input vector a. C: Pointer to an array that contains the input vector a. |
mode |
FORTRAN 77: INTEGER*8 Fortran 90: INTEGER(KIND=8), INTENT(IN) C: const MKL_INT64 |
Overrides global VML mode setting for this function call. See vmlSetMode for possible values and their description. |
Name |
Type |
Description |
---|---|---|
y |
FORTRAN 77: REAL for vsrint, vmsrint DOUBLE PRECISION for vdrint, vmdrint Fortran 90: REAL, INTENT(OUT) for vsrint, vmsrint DOUBLE PRECISION, INTENT(OUT) for vdrint, vmdrint C: float* for vsRint, vmsrint double* for vdRint, vmdrint |
FORTRAN: Array that specifies the output vector y. C: Pointer to an array that contains the output vector y. |
The v?Rint function computes a rounded floating-point integer value using the current rounding mode for each vector element.
The resulting mode affects the results computed for inputs that fall half-way between consecutive integres. For example:
f(0.5) = 0, for rounding modes set to round to nearest round toward zero or to minus infinity.
f(0.5) = 1, for rounding modes set to plus infinity.
f(-1.5) = -2, for rounding modes set to round to nearest or to minus infinity.
f(-1.5) = -1, for rounding modes set to round toward zero or to plus infinity.