Package-level declarations
Types
Type alias for CommutativeGroup, also known as an abelian group.
Describes a context that represents mathematical commutative group (a.k.a. abelian group).
Describes a context that represents mathematical commutative monoid (a.k.a. abelian monoid).
Describes a context that represents mathematical commutative ring.
Describes a context that represents mathematical commutative semigroup (a.k.a. abelian semigroup).
Describes a context that represents mathematical commutative semiring.
An operation context for Euclidean division (division with remainder).
Wrapper class for a result of Euclidean division (a.k.a. a division with remainder). See EuclideanSemiring's or EuclideanRing's docs for more.
Describes a context that represents Euclidean ring (a.k.a. Euclidean domain).
Describes a context that represents Euclidean semiring (i.e. Euclidean ring (a.k.a. Euclidean domain) but without subtraction).
Describes a context that represents "extended" mathematical semiring.
Describes a context that represents mathematical field.
An operation context for computing the reciprocal (multiplicative inverse).
Describes a context that represents mathematical ring.
Describes a context that represents mathematical semigroup.
Describes a context that represents mathematical semiring.
An operation context for the unary minus (negation) operator.
Functions
Returns absolute value of this number. I.e. if this number is non-negative it is returned, otherwise its negation is returned.
Returns the Byte commutative group context (a singleton implementing CommutativeGroup for Byte).
Returns the Double commutative group context (a singleton implementing CommutativeGroup for Double).
Returns the Float commutative group context (a singleton implementing CommutativeGroup for Float).
Returns the Int commutative group context (a singleton implementing CommutativeGroup for Int).
Returns the Long commutative group context (a singleton implementing CommutativeGroup for Long).
Returns the Short commutative group context (a singleton implementing CommutativeGroup for Short).
Returns the Byte commutative monoid context (a singleton implementing CommutativeMonoid for Byte).
Returns the Double commutative monoid context (a singleton implementing CommutativeMonoid for Double).
Returns the Float commutative monoid context (a singleton implementing CommutativeMonoid for Float).
Returns the Int commutative monoid context (a singleton implementing CommutativeMonoid for Int).
Returns the Long commutative monoid context (a singleton implementing CommutativeMonoid for Long).
Returns the Short commutative monoid context (a singleton implementing CommutativeMonoid for Short).
Returns the UByte commutative monoid context (a singleton implementing CommutativeMonoid for UByte).
Returns the UInt commutative monoid context (a singleton implementing CommutativeMonoid for UInt).
Returns the ULong commutative monoid context (a singleton implementing CommutativeMonoid for ULong).
Returns the UShort commutative monoid context (a singleton implementing CommutativeMonoid for UShort).
Returns the Byte commutative ring context (a singleton implementing CommutativeRing for Byte).
Returns the Double commutative ring context (a singleton implementing CommutativeRing for Double).
Returns the Float commutative ring context (a singleton implementing CommutativeRing for Float).
Returns the Int commutative ring context (a singleton implementing CommutativeRing for Int).
Returns the Long commutative ring context (a singleton implementing CommutativeRing for Long).
Returns the Short commutative ring context (a singleton implementing CommutativeRing for Short).
Returns the Byte commutative semigroup context (a singleton implementing CommutativeSemigroup for Byte).
Returns the Double commutative semigroup context (a singleton implementing CommutativeSemigroup for Double).
Returns the Float commutative semigroup context (a singleton implementing CommutativeSemigroup for Float).
Returns the Int commutative semigroup context (a singleton implementing CommutativeSemigroup for Int).
Returns the Long commutative semigroup context (a singleton implementing CommutativeSemigroup for Long).
Returns the Short commutative semigroup context (a singleton implementing CommutativeSemigroup for Short).
Returns the UByte commutative semigroup context (a singleton implementing CommutativeSemigroup for UByte).
Returns the UInt commutative semigroup context (a singleton implementing CommutativeSemigroup for UInt).
Returns the ULong commutative semigroup context (a singleton implementing CommutativeSemigroup for ULong).
Returns the UShort commutative semigroup context (a singleton implementing CommutativeSemigroup for UShort).
Returns the Byte commutative semiring context (a singleton implementing CommutativeSemiring for Byte).
Returns the Double commutative semiring context (a singleton implementing CommutativeSemiring for Double).
Returns the Float commutative semiring context (a singleton implementing CommutativeSemiring for Float).
Returns the Int commutative semiring context (a singleton implementing CommutativeSemiring for Int).
Returns the Long commutative semiring context (a singleton implementing CommutativeSemiring for Long).
Returns the Short commutative semiring context (a singleton implementing CommutativeSemiring for Short).
Returns the UByte commutative semiring context (a singleton implementing CommutativeSemiring for UByte).
Returns the UInt commutative semiring context (a singleton implementing CommutativeSemiring for UInt).
Returns the ULong commutative semiring context (a singleton implementing CommutativeSemiring for ULong).
Returns the UShort commutative semiring context (a singleton implementing CommutativeSemiring for UShort).
Creates a DivideRemainder instance from a lambda.
Throws ArithmeticException with message "Division by zero". Used when division by zero is attempted.
Returns the Byte euclidean ring context (a singleton implementing EuclideanRing for Byte).
Returns the Int euclidean ring context (a singleton implementing EuclideanRing for Int).
Returns the Long euclidean ring context (a singleton implementing EuclideanRing for Long).
Returns the Short euclidean ring context (a singleton implementing EuclideanRing for Short).
Returns the Byte euclidean semiring context (a singleton implementing EuclideanSemiring for Byte).
Returns the Int euclidean semiring context (a singleton implementing EuclideanSemiring for Int).
Returns the Long euclidean semiring context (a singleton implementing EuclideanSemiring for Long).
Returns the Short euclidean semiring context (a singleton implementing EuclideanSemiring for Short).
Returns the UByte euclidean semiring context (a singleton implementing EuclideanSemiring for UByte).
Returns the UInt euclidean semiring context (a singleton implementing EuclideanSemiring for UInt).
Returns the ULong euclidean semiring context (a singleton implementing EuclideanSemiring for ULong).
Returns the UShort euclidean semiring context (a singleton implementing EuclideanSemiring for UShort).
Throws ArithmeticException with message "Undefined subtraction result in extended semiring". Used when undefined subtraction is attempted.
Throws NumberFormatException with a message that the input's format is incorrect for the radix.
Throws OverflowException with message "Overflow happened". Used when overflow happened during arithmetic operation.
Creates a Reciprocal instance from a lambda.
Computes the reciprocal using the given Reciprocal context.
Returns the Byte reification context (a singleton implementing Reification for Byte).
Returns the Double reification context (a singleton implementing Reification for Double).
Returns the Float reification context (a singleton implementing Reification for Float).
Returns the Int reification context (a singleton implementing Reification for Int).
Returns the Long reification context (a singleton implementing Reification for Long).
Returns the Short reification context (a singleton implementing Reification for Short).
Returns the UByte reification context (a singleton implementing Reification for UByte).
Returns the UInt reification context (a singleton implementing Reification for UInt).
Returns the ULong reification context (a singleton implementing Reification for ULong).
Returns the UShort reification context (a singleton implementing Reification for UShort).
Returns the safe Double commutative group context (a singleton implementing CommutativeGroup for Double with NaN/Infinity validation).
Returns the safe Long commutative group context (a singleton implementing CommutativeGroup for Long with overflow checking).
Returns the safe Double commutative monoid context (a singleton implementing CommutativeMonoid for Double with NaN/Infinity validation).
Returns the safe Long commutative monoid context (a singleton implementing CommutativeMonoid for Long with overflow checking).
Returns the safe Double commutative ring context (a singleton implementing CommutativeRing for Double with NaN/Infinity validation).
Returns the safe Long commutative ring context (a singleton implementing CommutativeRing for Long with overflow checking).
Returns the safe Double commutative semigroup context (a singleton implementing CommutativeSemigroup for Double with NaN/Infinity validation).
Returns the safe Long commutative semigroup context (a singleton implementing CommutativeSemigroup for Long with overflow checking).
Returns the safe Double commutative semiring context (a singleton implementing CommutativeSemiring for Double with NaN/Infinity validation).
Returns the safe Long commutative semiring context (a singleton implementing CommutativeSemiring for Long with overflow checking).
Returns the safe Long Euclidean ring context (a singleton implementing EuclideanRing for Long with overflow checking).
Returns the safe Long Euclidean semiring context (a singleton implementing EuclideanSemiring for Long with overflow checking).
Returns the safe Double reification context (a singleton implementing Reification for Double with NaN/Infinity validation).
Returns the safe Long reification context (a singleton implementing Reification for Long with overflow checking).
fun Byte.Companion.setCommutativeGroup()
Registers the CommutativeGroup context for Byte in the given registry.
fun Double.Companion.setCommutativeGroup()
Registers the CommutativeGroup context for Double in the given registry.
fun Float.Companion.setCommutativeGroup()
Registers the CommutativeGroup context for Float in the given registry.
fun Int.Companion.setCommutativeGroup()
Registers the CommutativeGroup context for Int in the given registry.
fun Long.Companion.setCommutativeGroup()
Registers the CommutativeGroup context for Long in the given registry.
fun Short.Companion.setCommutativeGroup()
Registers the CommutativeGroup context for Short in the given registry.
fun BigIntegerCompanion.setCommutativeGroup()
fun Byte.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for Byte in the given registry.
fun Double.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for Double in the given registry.
fun Float.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for Float in the given registry.
fun Int.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for Int in the given registry.
fun Long.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for Long in the given registry.
fun Short.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for Short in the given registry.
fun UByte.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for UByte in the given registry.
fun UInt.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for UInt in the given registry.
fun ULong.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for ULong in the given registry.
fun UShort.Companion.setCommutativeMonoid()
Registers the CommutativeMonoid context for UShort in the given registry.
fun BigIntegerCompanion.setCommutativeMonoid()
fun Byte.Companion.setCommutativeRing()
Registers the CommutativeRing context for Byte in the given registry.
fun Double.Companion.setCommutativeRing()
Registers the CommutativeRing context for Double in the given registry.
fun Float.Companion.setCommutativeRing()
Registers the CommutativeRing context for Float in the given registry.
fun Int.Companion.setCommutativeRing()
Registers the CommutativeRing context for Int in the given registry.
fun Long.Companion.setCommutativeRing()
Registers the CommutativeRing context for Long in the given registry.
fun Short.Companion.setCommutativeRing()
Registers the CommutativeRing context for Short in the given registry.
fun BigIntegerCompanion.setCommutativeRing()
fun Byte.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for Byte in the given registry.
fun Double.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for Double in the given registry.
fun Float.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for Float in the given registry.
fun Int.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for Int in the given registry.
fun Long.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for Long in the given registry.
fun Short.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for Short in the given registry.
fun UByte.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for UByte in the given registry.
fun UInt.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for UInt in the given registry.
fun ULong.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for ULong in the given registry.
fun UShort.Companion.setCommutativeSemigroup()
Registers the CommutativeSemigroup context for UShort in the given registry.
fun BigIntegerCompanion.setCommutativeSemigroup()
fun Byte.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for Byte in the given registry.
fun Double.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for Double in the given registry.
fun Float.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for Float in the given registry.
fun Int.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for Int in the given registry.
fun Long.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for Long in the given registry.
fun Short.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for Short in the given registry.
fun UByte.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for UByte in the given registry.
fun UInt.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for UInt in the given registry.
fun ULong.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for ULong in the given registry.
fun UShort.Companion.setCommutativeSemiring()
Registers the CommutativeSemiring context for UShort in the given registry.
fun BigIntegerCompanion.setCommutativeSemiring()
fun Byte.Companion.setEquality()
fun Double.Companion.setEquality()
fun Float.Companion.setEquality()
fun Long.Companion.setEquality()
fun Short.Companion.setEquality()
fun UByte.Companion.setEquality()
fun UInt.Companion.setEquality()
fun ULong.Companion.setEquality()
fun UShort.Companion.setEquality()
fun Byte.Companion.setEuclideanRing()
Registers the EuclideanRing context for Byte in the given registry.
fun Int.Companion.setEuclideanRing()
Registers the EuclideanRing context for Int in the given registry.
fun Long.Companion.setEuclideanRing()
Registers the EuclideanRing context for Long in the given registry.
fun Short.Companion.setEuclideanRing()
Registers the EuclideanRing context for Short in the given registry.
fun BigIntegerCompanion.setEuclideanRing()
fun Byte.Companion.setEuclideanSemiring()
Registers the EuclideanSemiring context for Byte in the given registry.
fun Int.Companion.setEuclideanSemiring()
Registers the EuclideanSemiring context for Int in the given registry.
fun Long.Companion.setEuclideanSemiring()
Registers the EuclideanSemiring context for Long in the given registry.
fun Short.Companion.setEuclideanSemiring()
Registers the EuclideanSemiring context for Short in the given registry.
fun UByte.Companion.setEuclideanSemiring()
Registers the EuclideanSemiring context for UByte in the given registry.
fun UInt.Companion.setEuclideanSemiring()
Registers the EuclideanSemiring context for UInt in the given registry.
fun ULong.Companion.setEuclideanSemiring()
Registers the EuclideanSemiring context for ULong in the given registry.
fun UShort.Companion.setEuclideanSemiring()
Registers the EuclideanSemiring context for UShort in the given registry.
fun BigIntegerCompanion.setEuclideanSemiring()
fun Double.Companion.setHashing()
fun Float.Companion.setHashing()
fun Short.Companion.setHashing()
fun UByte.Companion.setHashing()
fun ULong.Companion.setHashing()
fun UShort.Companion.setHashing()
fun Double.Companion.setMonoid()
fun UShort.Companion.setMonoid()
fun Byte.Companion.setReification()
Registers the Reification context for Byte in the given registry.
fun Double.Companion.setReification()
Registers the Reification context for Double in the given registry.
fun Float.Companion.setReification()
Registers the Reification context for Float in the given registry.
fun Int.Companion.setReification()
Registers the Reification context for Int in the given registry.
fun Long.Companion.setReification()
Registers the Reification context for Long in the given registry.
fun Short.Companion.setReification()
Registers the Reification context for Short in the given registry.
fun UByte.Companion.setReification()
Registers the Reification context for UByte in the given registry.
fun UInt.Companion.setReification()
Registers the Reification context for UInt in the given registry.
fun ULong.Companion.setReification()
Registers the Reification context for ULong in the given registry.
fun UShort.Companion.setReification()
Registers the Reification context for UShort in the given registry.
fun BigIntegerCompanion.setReification()
fun Double.Companion.setSafeCommutativeGroup()
Registers the safe CommutativeGroup context for Double (with NaN/Infinity validation) in the given registry.
fun Long.Companion.setSafeCommutativeGroup()
Registers the safe CommutativeGroup context for Long (with overflow checking) in the given registry.
fun Double.Companion.setSafeCommutativeMonoid()
Registers the safe CommutativeMonoid context for Double (with NaN/Infinity validation) in the given registry.
fun Long.Companion.setSafeCommutativeMonoid()
Registers the safe CommutativeMonoid context for Long (with overflow checking) in the given registry.
fun Double.Companion.setSafeCommutativeRing()
Registers the safe CommutativeRing context for Double (with NaN/Infinity validation) in the given registry.
fun Long.Companion.setSafeCommutativeRing()
Registers the safe CommutativeRing context for Long (with overflow checking) in the given registry.
fun Double.Companion.setSafeCommutativeSemigroup()
Registers the safe CommutativeSemigroup context for Double (with NaN/Infinity validation) in the given registry.
fun Long.Companion.setSafeCommutativeSemigroup()
Registers the safe CommutativeSemigroup context for Long (with overflow checking) in the given registry.
fun Double.Companion.setSafeCommutativeSemiring()
Registers the safe CommutativeSemiring context for Double (with NaN/Infinity validation) in the given registry.
fun Long.Companion.setSafeCommutativeSemiring()
Registers the safe CommutativeSemiring context for Long (with overflow checking) in the given registry.
fun Double.Companion.setSafeEquality()
Registers the safe Equality context for Double (with NaN/Infinity validation) in the given registry.
fun Long.Companion.setSafeEquality()
fun Long.Companion.setSafeEuclideanRing()
Registers the safe EuclideanRing context for Long (with overflow checking) in the given registry.
fun Long.Companion.setSafeEuclideanSemiring()
Registers the safe EuclideanSemiring context for Long (with overflow checking) in the given registry.
fun Double.Companion.setSafeField()
fun Double.Companion.setSafeGroup()
fun Long.Companion.setSafeGroup()
fun Double.Companion.setSafeHashing()
fun Long.Companion.setSafeHashing()
fun Double.Companion.setSafeMonoid()
fun Long.Companion.setSafeMonoid()
fun Double.Companion.setSafeOrder()
fun Long.Companion.setSafeOrder()
fun Double.Companion.setSafeReification()
Registers the safe Reification context for Double (with NaN/Infinity validation) in the given registry.
fun Long.Companion.setSafeReification()
Registers the safe Reification context for Long (with overflow checking) in the given registry.
fun Double.Companion.setSafeRing()
fun Long.Companion.setSafeRing()
fun Double.Companion.setSafeSemigroup()
Registers the safe Semigroup context for Double (with NaN/Infinity validation) in the given registry.
fun Long.Companion.setSafeSemigroup()
fun Double.Companion.setSafeSemiring()
Registers the safe Semiring context for Double (with NaN/Infinity validation) in the given registry.
fun Long.Companion.setSafeSemiring()
fun Byte.Companion.setSemigroup()
fun Double.Companion.setSemigroup()
fun Float.Companion.setSemigroup()
fun Int.Companion.setSemigroup()
fun Long.Companion.setSemigroup()
fun Short.Companion.setSemigroup()
fun UByte.Companion.setSemigroup()
fun UInt.Companion.setSemigroup()
fun ULong.Companion.setSemigroup()
fun UShort.Companion.setSemigroup()
fun Byte.Companion.setSemiring()
fun Double.Companion.setSemiring()
fun Float.Companion.setSemiring()
fun Long.Companion.setSemiring()
fun Short.Companion.setSemiring()
fun UByte.Companion.setSemiring()
fun UInt.Companion.setSemiring()
fun ULong.Companion.setSemiring()
fun UShort.Companion.setSemiring()
Creates a UnaryMinus instance from a lambda.
Returns the negation of this sign.
operator fun <Input, Result> Input.unaryMinus(): Result
Applies unary minus using the given UnaryMinus context.