Module math

Source
Expand description

Pure-math functions supporting physics calculations.

Functionsยง

cartesian_to_cylindrical
Convert a point from cartesian to cylindrical coordinates.
cross3
Evaluate the cross products for each axis component separately using mul_add which would not be assumed usable in a more general implementation.
cylindrical_to_cartesian
Convert a point in cylindrical coordinates to cartesian.
decompose_filament
Decompose two filament endpoints into a midpoint and a length vector
dot3
Scalar dot product using mul_add.
ellipe
Complete elliptic integral of the second kind.
ellipk
Complete elliptic integral of the first kind.
rss3
3D $(x^2 + y^2 + z^2)^{1/2}$ using mul_add to perform all addition in extended registers.