MathNAbsTNumeric Method

Returns the absolute value of a number.

Definition

Namespace: Jodosoft.Numerics
Assembly: Jodosoft.Numerics (in Jodosoft.Numerics.dll) Version: 2.0
public static TNumeric Abs<TNumeric>(
	TNumeric value
)
where TNumeric : struct, new(), INumeric<TNumeric>

Parameters

value  TNumeric
A number that is greater than or equal to MinValueTNumeric, but less than or equal to MaxValueTNumeric.

Type Parameters

TNumeric

Return Value

TNumeric
A number, x, such that 0 ≤ x ≤ MaxValueTNumeric.

Remarks

This method may return NaN or Infinity. If NaN or Infinity cannot be represented by TNumeric, then this method may throw an ArithmeticException.

See Also