VI_fsum | VBI_fsum | VSI_fsum | VLI_fsum | VQI_fsum | |
VU_fsum | VUB_fsum | VUS_fsum | VUL_fsum | VUQ_fsum | VUI_fsum |
|
Function | sum of the elements of an integer vector, returned in floating-point |
|
Syntax C/C++ | #include <VIstd.h>
double VI_fsum( iVector X, ui size );
(similarly VBI_, VSI_, VLI_, VU_, VUB_, VUS_, VUL_, VUI_)
extended VQI_fsum( qiVector X, ui size ); |
C++ VecObj | #include <OptiVec.h>
double vector<int>::fsum();
extended vector<quad>::fsum(); |
Pascal/Delphi | uses VIstd;
function VI_fsum( X:iVector; size:UIntSize ): Double;
(similarly VBI_, VSI_, VLI_, VU_, VUB_, VUS_, VUL_)
function VQI_fsum( X:qiVector; size:UIntSize ): Extended; |
|
CUDA function C/C++ | #include <cudaVIstd.h>
int cudaVI_fsum( double *h_RetVal, iVector d_X, ui size );
int cusdVI_fsum( double *d_RetVal, iVector d_X, ui size );
double VIcu_fsum( iVector h_X, ui size );
int cudaVQI_fsum( double *h_RetVal, qiVector d_X, ui size );
int cusdVQI_fsum( double *d_RetVal, qiVector d_X, ui size );
double VQIcu_fsum( qiVector h_X, ui size );
|
CUDA function Pascal/Delphi | uses VIstd;
function cudaVI_fsum( var h_RetVal:Double; d_X:iVector; size:UIntSize ): IntBool;
function cusdVI_fsum( d_RetVal:PDouble; d_X:iVector; size:UIntSize ): IntBool;
function VIcu_fsum( h_X:iVector; size:UIntSize ): Double;
function cudaVQI_fsum( var h_RetVal:Double; d_X:qiVector; size:UIntSize ): IntBool;
function cusdVQI_fsum( d_RetVal:PDouble; d_X:qiVector; size:UIntSize ): IntBool;
function VQIcu_fsum( h_X:qiVector; size:UIntSize ): Double;
|
|
Description | The elements of X are summed up. In order to avoid possible overflow, the sum is accumulated in a floating-point number. The 8, 16, and 32 bit variants return the result in double precision, whereas the 64 bit variant, VQI_fsum, returns an extended. |
|
|
Return value | the sum in floating-point format |
|
|