pub trait DualNum:
NumOps
+ for<'r> NumOps<&'r Self>
+ Signed
+ NumOps<Self::Primitive>
+ NumAssignOps
+ NumAssignOps<Self::Primitive>
+ Clone
+ Inv<Output = Self>
+ Sum
+ Product
+ FromPrimitive
+ From<Self::Primitive>
+ DualStruct<Real = Self::Primitive>
+ Mappable<Self>
+ Display
+ PartialOrd
+ PartialOrd<Self::Primitive>
+ Debug
+ 'static {
type Primitive: DualNumFloat;
type InnerDual: DualNum;
const NDERIV: usize;
Show 33 methods
// Required methods
fn from_re(re: Self::InnerDual) -> Self;
fn recip(&self) -> Self;
fn powi(&self, n: i32) -> Self;
fn powf(&self, n: Self::Primitive) -> Self;
fn sqrt(&self) -> Self;
fn cbrt(&self) -> Self;
fn exp(&self) -> Self;
fn exp2(&self) -> Self;
fn exp_m1(&self) -> Self;
fn ln(&self) -> Self;
fn log(&self, base: Self::Primitive) -> Self;
fn log2(&self) -> Self;
fn log10(&self) -> Self;
fn ln_1p(&self) -> Self;
fn sin(&self) -> Self;
fn cos(&self) -> Self;
fn tan(&self) -> Self;
fn sin_cos(&self) -> (Self, Self);
fn asin(&self) -> Self;
fn acos(&self) -> Self;
fn atan(&self) -> Self;
fn atan2(&self, other: Self) -> Self;
fn sinh(&self) -> Self;
fn cosh(&self) -> Self;
fn tanh(&self) -> Self;
fn asinh(&self) -> Self;
fn acosh(&self) -> Self;
fn atanh(&self) -> Self;
fn sph_j0(&self) -> Self;
fn sph_j1(&self) -> Self;
fn sph_j2(&self) -> Self;
// Provided methods
fn mul_add(&self, a: Self, b: Self) -> Self { ... }
fn powd(&self, exp: Self) -> Self { ... }
}Expand description
A generalized (hyper) dual number.
Required Associated Constants§
Required Associated Types§
Sourcetype Primitive: DualNumFloat
type Primitive: DualNumFloat
The underlying primitive data type (mostly f64 or f32)
Required Methods§
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".