pub fn smoothstep(lo: f64, hi: f64, v: f64) -> f64
Smooth-step function: 3t² - 2t³ with t = (v - lo) / (hi - lo).
3t² - 2t³
t = (v - lo) / (hi - lo)