pub fn brent_root(
lo: f64,
hi: f64,
f: impl FnMut(f64) -> f64,
tol: f64,
max_iter: usize,
) -> FinanceResult<f64>Expand description
Find a root of continuous f on bracket [lo, hi] (Brent 1973).
Requires opposite signs at the endpoints (or a zero on an endpoint).