Function newton

Source
pub fn newton<'a, T, F>(
    function: F,
    x: impl Into<DVectorViewMut<'a, T>>,
    f: impl Into<DVectorViewMut<'a, T>>,
    dx: impl Into<DVectorViewMut<'a, T>>,
    settings: NewtonSettings<T>,
) -> Result<usize, NewtonError>
Expand description

Attempts to solve the non-linear equation F(u) = 0.

No heap allocation is performed. The solution is said to have converged if |F(u)|_2 <= tolerance.

If successful, returns the number of iterations performed.