Skip to main content

relative_speed

Function relative_speed 

pub fn relative_speed(velocity_a: f64, velocity_b: f64) -> Option<f64>
Expand description

Computes the relative speed between two one-dimensional bodies.

Formula: speed_rel = |v_a - v_b|