Skip to main content

velocity_from_momentum

Function velocity_from_momentum 

Source
pub fn velocity_from_momentum(momentum: f64, mass: f64) -> Option<f64>
Expand description

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

Returns None when mass is less than or equal to zero, when either input is not finite, or when the computed velocity is not finite.