pub trait RootFindingProblem<const I: usize, const O: usize, T> {
// Required methods
fn function(&self, x: Pt<I>) -> Result<Pt<O>>;
fn initial_guess(&self) -> T;
// Provided methods
fn derivative(&self, x: Pt<I>) -> Result<Jaco<O, I>> { ... }
fn hessian(&self, x: Pt<I>) -> Result<Hess<O, I>> { ... }
}Expand description
Trait to define a root finding problem
§Type Parameters
I: Input type (e.g.f64,[f64; N], or etc.)O: Output type (e.g.f64,[f64; N], or etc.)T: State type (e.g.f64,(f64, f64), or etc.)
§Methods
function: Functioninitial_guess: Initial guessderivative: Derivative (optional)hessian: Hessian (optional)