Enhanced C#
Language of your choice: library documentation
|
Provides operations available on all unsigned integer types (byte, uint, etc.); see also IMath<T>, IIntMath<T>, and IFloatMath<T>. More...
Provides operations available on all unsigned integer types (byte, uint, etc.); see also IMath<T>, IIntMath<T>, and IFloatMath<T>.
Additional Inherited Members | |
Properties inherited from Loyc.Math.INumTraits< T > | |
T | MinValue [get] |
Minimum value of this type above negative infinity. More... | |
T | MaxValue [get] |
Maximum value of this type below infinity. More... | |
T | Epsilon [get] |
Smallest representable positive value of T (1 for integer types). More... | |
T | PositiveInfinity [get] |
Returns positive infinity, or MaxValue for types that cannot represent infinity. More... | |
T | NegativeInfinity [get] |
Returns negative infinity, or throws NotSupportedException if T is unsigned. More... | |
T | NaN [get] |
Not-a-number or null representation for this type. More... | |
bool | IsSigned [get] |
Returns true if T can represent negative values. More... | |
bool | IsFloatingPoint [get] |
Returns true if T is floating-point, meaning that it can represent very large and very small numbers, despite possibly limited precision. Returns false for fixed-point and integer-rational types. More... | |
bool | IsInteger [get] |
Returns true if the type represents only whole numbers. More... | |
bool | IsOrdered [get] |
Returns true for "normal" numbers, false for ones that aren't necessarily comparable (notably complex numbers). More... | |
int | SignificantBits [get] |
Returns the normal maximum number of significant (mantissa) bits for this type (not counting the sign bit), or int.MaxValue for unlimited-size types. More... | |
int | MaxIntPowerOf2 [get] |
Returns the maximum power-of-two-minus-one that can be represented by this type, e.g. for Int32 it's 31, and for UInt32 it's 32. More... | |
ulong | MaxInt [get] |
Returns the maximum integer that this type can represent. More... | |
long | MinInt [get] |
Returns the minimum integer that this type can represent. More... | |
Properties inherited from Loyc.Math.IZeroProvider< T > | |
T | Zero [get] |
Returns the "zero" or additive identity of this type. More... | |
Properties inherited from Loyc.Math.IOneProvider< T > | |
T | One [get] |
Returns the "one" or identity value of this type. More... | |
Public Member Functions inherited from Loyc.Math.ISignedMath< T > | |
T | Negate (T a) |
Public Member Functions inherited from Loyc.Math.INumTraits< T > | |
bool | IsInfinity (T value) |
Returns true if the given value is infinite. More... | |
bool | IsNaN (T value) |
Returns true if the given value is not a number (can only be true for floats). More... | |
T | Floor (T value) |
Gets the closest integer equal to or lower than the specified number. More... | |
T | Ceiling (T value) |
Gets the closest integer equal to or higher than the specified number. More... | |
Public Member Functions inherited from Loyc.Math.IConvertTo< T > | |
T | From (uint t) |
T | From (int t) |
T | From (ulong t) |
T | From (long t) |
T | From (double t) |
T | Clip (uint t) |
T | Clip (int t) |
T | Clip (ulong t) |
T | Clip (long t) |
T | Clip (double t) |
Public Member Functions inherited from Loyc.Math.IOrdered< T > | |
bool | IsLess (T a, T b) |
bool | IsLessOrEqual (T a, T b) |
T | Abs (T a) |
T | Max (T a, T b) |
T | Min (T a, T b) |
Public Member Functions inherited from Loyc.Math.IIncrementer< T > | |
T | AddOne (T a) |
Returns a + 1. More... | |
T | SubOne (T a) |
Returns a - 1. More... | |
T | NextHigher (T a) |
Returns the next representable number higher than a. More... | |
T | NextLower (T a) |
Returns the next representable number lower than a. More... | |
Public Member Functions inherited from Loyc.Math.IAdditionGroup< T > | |
T | Add (T a, T b) |
T | Add (T a, T b, T c) |
T | Sub (T a, T b) |
Public Member Functions inherited from Loyc.Math.IMultiply< T > | |
T | Mul (T a, T b) |
Public Member Functions inherited from Loyc.Math.IMultiplicationGroup< T > | |
T | Div (T a, T b) |
T | Shl (T a, int amount) |
T | Shr (T a, int amount) |
T | MulDiv (T a, T mulBy, T divBy) |
Public Member Functions inherited from Loyc.Math.IHasRoot< T > | |
T | Sqrt (T a) |
T | Square (T a) |
Public Member Functions inherited from Loyc.Math.IBinaryMath< T > | |
T | Shl (T a, int amount) |
Shifts 'a' left by the specified number of bits. More... | |
T | Shr (T a, int amount) |
Shifts 'a' right by the specified number of bits. More... | |
int | CountOnes (T a) |
Returns the number of '1' bits in 'a'. More... | |
int | Log2Floor (T a) |
Returns the floor of the base-2 logarithm of x. e.g. 1024 -> 10, 1000 -> 9 More... | |
Public Member Functions inherited from Loyc.Math.IBitwise< T > | |
T | And (T a, T b) |
T | Or (T a, T b) |
T | Xor (T a, T b) |
T | Not (T a) |