bag.math
This package defines design template classes.
Submodules
Package Contents
Functions
|
|
|
Converts the given floating point number to a string using SI prefix. |
|
Converts the given string with SI prefix to float. |
|
Compute greatest common divisor of two positive integers. |
|
Compute least common multiple of all numbers in the given list. |
- bag.math.float_to_si_string(num: float, precision: int = 6) str [source]
Converts the given floating point number to a string using SI prefix.
- bag.math.gcd(a: int, b: int) int [source]
Compute greatest common divisor of two positive integers.