Module math_lib

Source
Expand description
  • A collection of math functions

§Metadata

  • Copyright: © 2022-2023 CroftSoft Inc
  • Author: David Wallace Croft
  • Java created: 1998-12-27
  • Java updated: 2008-08-09
  • Rust created: 2022-08-24
  • Rust updated: 2023-03-20

§History

Structs§

Clip
Clips the value to a minimum and maximum range
CumulativeDistributionFunction
Cumulative Distribution Function (CDF)
PolarCoordinates
Coordinates specified as angle and radius from the origin
RectangularCoordinates
Cartesian (x, y) coordinates
Wrap
Wraps the value to [minimum, minimum + range)

Enums§

ClipError
FactorError
GreatestCommonFactorError
WrapError
WrapErrorFloatResolution
WrapErrorInvalidArgument

Functions§

factor
Factors a number into its primes
greatest_common_factor
Computes the greatest common factor for two positive integers
sigmoid
The sigmoid or logistic function
sigmoid_derivative
The derivative of the sigmoid function with respect to the argument