FunctionSum of the absolute deviations of the elements of one vector from the corresponding elements of another
Syntax C/C++#include <VFstd.h>
float VF_sumdevV( fVector X, fVector Y, ui size );
float VF_sumdevVwSaturation( fVector X, fVector Y, ui size );
C++ VecObj#include <OptiVec.h>
T vector<T>::sumdevV( const vector<T>& Y );
T vector<T>::sumdevVwSaturation( const vector<T>& Y );
Pascal/Delphiuses VFstd;
function VF_sumdevV( X, Y:fVector; size:UIntSize ): Single;
function VF_sumdevVwSaturation( X, Y:fVector; size:UIntSize ): Single;
CUDA function C/C++#include <cudaVFstd.h>
int cudaVF_sumdevV( float *h_RetVal, fVector X, fVector Y, ui size );
int cusdVF_sumdevV( float *d_RetVal, fVector X, fVector Y, ui size );
float VFcu_sumdevV( fVector h_X, fVector h_Y, ui size );
CUDA function Pascal/Delphiuses VFstd;
function cudaVF_sumdevV( var h_RetVal:Single; d_X, d_Y:fVector; size:UIntSize ): IntBool;
function cusdVF_sumdevV( d_RetVal:PSingle; d_X, d_Y:fVector; size:UIntSize ): IntBool;
function VFcu_sumdevV( h_X, h_Y:fVector; size:UIntSize ): Single;
DescriptionsumdevV = sum( |Xi - Yi| )

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

Error handlingnone
Return valuesum of the absolute deviations.
See alsoVF_sum,   VF_sumdevC,   VF_avdevV,   VF_ssqdevV

VectorLib Table of Contents  OptiVec home