| NumericClampToZero Method (Double, Double) |
Clamps near-zero values to zero.
Namespace: DigitalRune.MathematicsAssembly: DigitalRune (in DigitalRune.dll) Version: 1.20.0.0 (1.20.1.14552)
Syntax public static double ClampToZero(
double value,
double epsilon
)
Public Shared Function ClampToZero (
value As Double,
epsilon As Double
) As Double
public:
static double ClampToZero(
double value,
double epsilon
)
static member ClampToZero :
value : float *
epsilon : float -> float
Parameters
- value
- Type: SystemDouble
The value. - epsilon
- Type: SystemDouble
The tolerance value.
Return Value
Type:
Double
0 if the value is nearly zero (within the tolerance
epsilon) or the
original value otherwise.
See Also