Module num

Source
Expand description

Numerical types and math operations.
num::{geom, logic, niche, ord, quant, rand}

Extends: std::{cmp, num}


Modules§

geom
Geometric types and operations, spatial constructs and analysis.
geom::{linear, metric, shape}
logic
Logic related types and functionality.
niche
Specialized numeric types and behaviors.
ord
Comparing and ordering values.
quant
Quantification and periodicity.
rand
Random number generation.

Structs§

Castprim··
🌐 Provides const casting, joining and splitting operations between primitives.
Divisor
Faster divisor for division and modulo operations.
Float
🌐 Provides comprehensive floating-point operations for T, most of them const.
Frac
🌐 Provides comprehensive fractional operations on T, most of them const.
GcdReturn
⚖️ A return type for the calculated GCD and the Bézout coeficients.
Int
🌐 Provides comprehensive integer operations on T, most of them const.
Tp
The Triangle of Power

Enums§

FloatCategory
core A classification of floating point numbers.
NumError
🚩+ A numeric-related error.
Sign
Represents the sign of a number.
UnitBiunit
Binary unit prefixes.
UnitSiunit
SI (metric) unit prefixes.

Traits§

ExtFloat
🌐 Extension trait for floating-point types. Associated methods.
ExtFloatConst
🌐 Extension trait for floating-point types. Associated constants.
ExtNumConst
Fundamental numeric constants for both integer and floating-point types.
Num
Common trait for numeric types.
NumInt
Common trait for integer types.
NumRef
Common auto-trait for referenced numeric types.
NumRefInt
Common auto-trait for referenced integer types.
PrimitiveCastcast
Offers methods for casting between primitives.
PrimitiveJoinjoin
Offers methods to construct a primitive from an array or slice of smaller primitives.
PrimitiveSplitsplit
Offers methods to split a primitive into an array of smaller primitives.
Unitunit
Common trait for unit prefixes.

Functions§

prime_number_theoremstd or _float_f64
The prime number theorem formula.

Type Aliases§

NoNum
Represents the absence of a number.
NumResult
⚖️ A numeric-related result.
fsize
⚙️ A pointer-sized floating-point primitive.
isize_down
⚙️ A downcasted pointer-sized signed integer primitive.
isize_up
⚙️ An upcasted pointer-sized signed integer primitive.
usize_down
⚙️ A downcasted pointer-sized unsigned integer primitive.
usize_up
⚙️ An upcasted pointer-sized unsigned integer primitive.