pub fn newton<F: Fn(AD) -> AD>(
    f: F,
    initial_guess: f64,
    times: usize,
    tol: f64,
) -> Result<f64, RootError> {
    let mut root_finder = RootFinder::new(P(initial_guess), RootFind::Newton, f)?;
    root_finder.set_tol(tol);
    root_finder.set_times(times);
    root_finder.find_root()
}
Newton method to find root

# Usage
```
extern crate peroxide;
use peroxide::fuga::*;

fn main() -> Result<(), RootError> {
let x = newton(f, 2f64, 100, 1e-15)?;
assert!((x - 3f64).abs() < 1e-15);
Ok(())
}

fn f(x: AD) -> AD {
x.powi(2) - x * 2f64 - 3f64
}
```
src/grave/root.rs