Function russell_lab::check::deriv2_approx_eq_fw
source · pub fn deriv2_approx_eq_fw<F, A>(
d2fdx2: f64,
at_x: f64,
args: &mut A,
tol: f64,
f: F
)
Expand description
Panics if the second derivative is not approximately equal to a numerical derivative (forward differences)
Checking:
d²f │
——— │
dx² │x=at_x
The numerical derivative is computed using a using forward differences with 8 points
§Panics
- Will panic if NAN, INFINITY, or NEG_INFINITY is found
- Will panic if the absolute difference of derivative values is greater than the tolerance
- Will panic if the function
f
returns an error