Function hagan_west_integral
fn hagan_west_integral<R: Scalar>(g0: R, g1: R, x: f64) -> RExpand description
∫₀ˣ G, where G is Hagan-West’s shape function on one segment with
G(0) = g0, G(1) = g1 and ∫₀¹ G = 0.
The four branches are the paper’s regions: the plain quadratic where it is
already monotone, and three repairs that flatten part of the segment and
bend the rest, meeting at an interior break η. The region is chosen on
the passive g0, g1; the chosen region, its break included, is
evaluated in the mode.