fn roots<T:std::ops::Add<Output = T> +
std::ops::Sub<Output = T> +
std::ops::Div<Output = T> +
std::ops::Mul<Output = T> +
std::ops::Neg<Output = T> +
num_traits::FromPrimitive +
PartialOrd +
std::fmt::Debug +
Copy + Clone +
num_traits::Zero>(f:Polynomial<T>, left:T, right:T) -> Vec<T>
{
let rr = base_roots(f.clone(),left,right);
rr.into_iter().map(|x| { root_by_newton_raphson_near(x, f.clone())}).collect()
}
Comments