Trait num_prime::ExactRoots
source · pub trait ExactRoots: Roots + Pow<u32, Output = Self> + Clone {
// Provided methods
fn nth_root_exact(&self, n: u32) -> Option<Self> { ... }
fn sqrt_exact(&self) -> Option<Self> { ... }
fn cbrt_exact(&self) -> Option<Self> { ... }
fn is_nth_power(&self, n: u32) -> bool { ... }
fn is_square(&self) -> bool { ... }
fn is_cubic(&self) -> bool { ... }
}
Expand description
Extension on num_integer::Roots to support perfect power check on integers
Provided Methods§
fn nth_root_exact(&self, n: u32) -> Option<Self>
fn sqrt_exact(&self) -> Option<Self>
fn cbrt_exact(&self) -> Option<Self>
fn is_nth_power(&self, n: u32) -> bool
fn is_square(&self) -> bool
fn is_cubic(&self) -> bool
Object Safety§
This trait is not object safe.