VF_ssqdevVVD_ssqdevVVE_ssqdevV
VF_ssqdevVwSaturationVD_ssqdevVwSaturationVE_ssqdevVwSaturation
FunctionSum of the squares of the deviations of the elements of one vector from the corresponding elements of another
Syntax C/C++#include <VFstd.h>
float VF_ssqdevV( fVector X, fVector Y, ui size );
float VF_ssqdevVwSaturation( fVector X, fVector Y, ui size );
C++ VecObj#include <OptiVec.h>
T vector<T>::ssqdevV( const vector<T>& Y );
T vector<T>::ssqdevVwSaturation( const vector<T>& Y );
Pascal/Delphiuses VFstd;
function VF_ssqdevV( X, Y:fVector; size:UIntSize ): Single;
function VF_ssqdevVwSaturation( X, Y:fVector; size:UIntSize ): Single;
CUDA function C/C++#include <cudaVFstd.h>
int cudaVF_ssqdevV( float *h_RetVal, fVector X, fVector Y, ui size );
int cusdVF_ssqdevV( float *d_RetVal, fVector X, fVector Y, ui size );
float VFcu_ssqdevV( fVector h_X, fVector h_Y, ui size );
CUDA function Pascal/Delphiuses VFstd;
function cudaVF_ssqdevV( var h_RetVal:Single; d_X, d_Y:fVector; size:UIntSize ): IntBool;
function cusdVF_ssqdevV( d_RetVal:PSingle; d_X, d_Y:fVector; size:UIntSize ): IntBool;
function VFcu_ssqdevV( h_X, h_Y:fVector; size:UIntSize ): Single;
DescriptionssqdevV = sum( (Xi - Yi)2 )
The deviation of each element of X from the corresponding element of Y is calculated and the squares of the deviations summed up and returned.

V?_ssqdevVwSaturation is almost identical to V?_ssqdevV, except for the treatment of infinities and NAN values. While V?_ssqdevV may overflow to INF and will return NAN, if any input element is a NAN, V?_ssqdevVwSaturation will saturate possible overflow into HUGE_VAL and treats input values of ±NAN as ±HUGE_VAL.

Error handlingnone
Return valuesum of the squares of the deviations.
See alsoVF_ssq,   VF_ssqdevC,   VF_avdevV,   VF_sumdevV,   VF_chi2

VectorLib Table of Contents  OptiVec home