BlackScholesReal

Trait BlackScholesReal 

Source
pub trait BlackScholesReal:
    Sized
    + Copy
    + Send
    + Sync
    + Default
    + Add<Output = Self>
    + Sub<Output = Self>
    + Mul<Output = Self>
    + Div<Output = Self>
    + Neg<Output = Self> {
    type Mask: Copy;

    // Required methods
    fn splat(val: f64) -> Self;
    fn abs(self) -> Self;
    fn sqrt(self) -> Self;
    fn ln(self) -> Self;
    fn exp(self) -> Self;
    fn cdf(self) -> Self;
    fn cdf_with_pdf(self) -> (Self, Self);
    fn mul_add(self, a: Self, b: Self) -> Self;
    fn recip_precise(self) -> Self;
    fn select(mask: Self::Mask, t: Self, f: Self) -> Self;
    fn cmp_gt(self, other: Self) -> Self::Mask;
}

Required Associated Types§

Required Methods§

Source

fn splat(val: f64) -> Self

Source

fn abs(self) -> Self

Source

fn sqrt(self) -> Self

Source

fn ln(self) -> Self

Source

fn exp(self) -> Self

Source

fn cdf(self) -> Self

Source

fn cdf_with_pdf(self) -> (Self, Self)

Source

fn mul_add(self, a: Self, b: Self) -> Self

Source

fn recip_precise(self) -> Self

Source

fn select(mask: Self::Mask, t: Self, f: Self) -> Self

Source

fn cmp_gt(self, other: Self) -> Self::Mask

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl BlackScholesReal for f32

Source§

type Mask = bool

Source§

fn splat(val: f64) -> Self

Source§

fn abs(self) -> Self

Source§

fn sqrt(self) -> Self

Source§

fn select(mask: bool, t: Self, f: Self) -> Self

Source§

fn cmp_gt(self, other: Self) -> bool

Source§

fn recip_precise(self) -> Self

Source§

fn mul_add(self, a: Self, b: Self) -> Self

Source§

fn ln(self) -> Self

Source§

fn exp(self) -> Self

Source§

fn cdf(self) -> Self

Source§

fn cdf_with_pdf(self) -> (Self, Self)

Implementors§