Skip to main content

mass_from_momentum

Function mass_from_momentum 

pub fn mass_from_momentum(momentum: f64, velocity: f64) -> Option<f64>
Expand description

Computes mass from momentum and velocity using m = p / v.

Returns None when velocity is zero, when either input is not finite, when the computed mass is negative, or when the computed mass is not finite.