VF_absHugeVD_absHugeVE_absHuge
FunctionReplace negative poles (−HUGE_VAL) with positive ones (+HUGE_VAL)
Syntax C/C++#include <VFmath.h>
void VF_absHuge( fVector Y, fVector X, ui size );
C++ VecObj#include <OptiVec.h>
void vector<T>::absHuge( const vector<T>& X );
Pascal/Delphiuses VFmath;
procedure VF_absHuge( Y, X:fVector; size:UIntSize );
CUDA function C/C++#include <cudaVFmath.h>
int cudaVF_absHuge( fVector d_Y, fVector d_X, ui size );
void VFcu_absHuge( fVector h_Y, fVector h_X, ui size );
CUDA function Pascal/Delphiuses VFmath;
function cudaVF_absHuge( d_Y, d_X:fVector; size:UIntSize ): IntBool;
procedure VFcu_absHuge( h_Y, h_X:fVector; size:UIntSize );
DescriptionYi = Xi, if Xi > −HUGE_VAL
Yi = Max, if Xi ≤ −HUGE_VAL
(with HUGE_VAL being FLT_MAX, DBL_MAX, or LDBL_MAX)
Some mathematical functions like the inverse, the tangent, etc., have positive and negative poles (e.g., 1/+0 = +INF, but 1/−0 = −INF). In these cases, the slightest round-off error will decide between positive or negative infinity. For the sake of consistency, one may sometimes wish to treat 1/−0 as 1/+0 and replace negative poles by positive ones. This is what VF_absHuge does. Note that both −HUGE_VAL and −INF are changed into +HUGE_VAL, whereas +INF is left unchanged.
Error handlingnone
Return valuenone
See alsoVF_replaceNAN,   VF_maxC,   VF_minC,   VF_min,   VF_flush0,   VF_limit

VectorLib Table of Contents  OptiVec home