Skip to main content

Crate relp_num

Crate relp_num 

Source
Expand description

§relp-num

Number types for the RELP crate.

Modules§

fixed
Number types whose value is fixed at compile time.

Macros§

F
Helper macro for tests.
R8
Shorthand for creating a rational number in tests.
R16
Shorthand for creating a rational number in tests.
R32
Shorthand for creating a rational number in tests.
R64
Shorthand for creating a rational number in tests.
R128
Shorthand for creating a rational number in tests.
RB
Shorthand for creating a rational number in tests.

Structs§

NonZeroFactorization
Factorization of a nonzero integer or rational number.
NonZeroUbig
Non zero unsigned big integer.
Ubig
Unsigned big integer.

Enums§

NonZeroSign
Sign of a nonzero value.
Sign
Sign with a zero variant.

Traits§

Abs
Absolute value of a number.
Absorb
What a wide accumulator does with a narrow value.
AbsorbAll
A wide accumulator, together with the narrow values it reads.
EncodingSize
The size of a number’s representation, in bits.
FactorizationResidual
The part of a value that a factorization did not decompose.
Field
Basic field operations with Self and with references to Self.
FieldRef
A reference to a variable that is in a Field.
FromPrimitive
A generic trait for converting a number to a value.
Gcd
The greatest common divisor of two numbers, in the integer sense.
Narrow
Storing a value in a narrower type, exactly or not at all.
Negateable
A number that can be negated, that is, who’s sign can be flipped.
NonZero
Nonzero values
NonZeroFactorizable
Creating a factorization of an integer or rational number.
NonZeroSigned
A signed number that can have a nonzero value.
OrderedField
The simplex algorithm is defined over the ordered fields.
OrderedFieldRef
A reference to an ordered field.
Prime
Determining whether a number is a prime.
Signed
Signed numbers

Type Aliases§

Big
An arbitrary precision rational, with S words of its numerator and denominator held inline.
NonZeroBig
An arbitrary precision rational that is known not to be zero.
NonZeroRational8
Non zero rational number.
NonZeroRational16
Non zero rational number.
NonZeroRational32
Non zero rational number.
NonZeroRational64
Non zero rational number.
NonZeroRational128
Non zero rational number.
NonZeroRationalBig
A non zero arbitrary precision type.
NonZeroRationalUsize
Non zero rational number.
Rational8
A signed ratio between two small integers.
Rational16
A signed ratio between two small integers.
Rational32
A signed ratio between two small integers.
Rational64
A signed ratio between two small integers.
Rational128
A signed ratio between two small integers.
RationalBig
An arbitrary precision type.
RationalUsize
A signed ratio between two small integers.