ArithmeticOps

Trait ArithmeticOps 

Source
pub trait ArithmeticOps {
Show 25 methods // Required methods fn add_tensor(&self, other: &Self) -> Self; fn add_tensor_assign(&mut self, other: &Self); fn sub_tensor(&self, other: &Self) -> Self; fn sub_tensor_assign(&mut self, other: &Self); fn mul_tensor(&self, other: &Self) -> Self; fn mul_tensor_assign(&mut self, other: &Self); fn div_tensor(&self, other: &Self) -> Self; fn div_tensor_assign(&mut self, other: &Self); fn add_f32(&self, other: f32) -> Self; fn add_f32_assign(&mut self, other: f32); fn sub_f32(&self, other: f32) -> Self; fn sub_f32_assign(&mut self, other: f32); fn mul_f32(&self, other: f32) -> Self; fn mul_f32_assign(&mut self, other: f32); fn div_f32(&self, other: f32) -> Self; fn div_f32_assign(&mut self, other: f32); fn pow_f32(&self, other: f32) -> Self; fn pow_f32_assign(&mut self, other: f32); fn greater_than(&self, other: &Self, make_binary: bool) -> Self; fn greater_than_f32(&self, other: f32, make_binary: bool) -> Self; fn less_than(&self, other: &Self, make_binary: bool) -> Self; fn less_than_f32(&self, other: f32, make_binary: bool) -> Self; fn sign(&self) -> Self; fn abs(&self) -> Self; fn abs_assign(&mut self);
}

Required Methods§

Source

fn add_tensor(&self, other: &Self) -> Self

Source

fn add_tensor_assign(&mut self, other: &Self)

Source

fn sub_tensor(&self, other: &Self) -> Self

Source

fn sub_tensor_assign(&mut self, other: &Self)

Source

fn mul_tensor(&self, other: &Self) -> Self

Source

fn mul_tensor_assign(&mut self, other: &Self)

Source

fn div_tensor(&self, other: &Self) -> Self

Source

fn div_tensor_assign(&mut self, other: &Self)

Source

fn add_f32(&self, other: f32) -> Self

Source

fn add_f32_assign(&mut self, other: f32)

Source

fn sub_f32(&self, other: f32) -> Self

Source

fn sub_f32_assign(&mut self, other: f32)

Source

fn mul_f32(&self, other: f32) -> Self

Source

fn mul_f32_assign(&mut self, other: f32)

Source

fn div_f32(&self, other: f32) -> Self

Source

fn div_f32_assign(&mut self, other: f32)

Source

fn pow_f32(&self, other: f32) -> Self

Source

fn pow_f32_assign(&mut self, other: f32)

Source

fn greater_than(&self, other: &Self, make_binary: bool) -> Self

Source

fn greater_than_f32(&self, other: f32, make_binary: bool) -> Self

Source

fn less_than(&self, other: &Self, make_binary: bool) -> Self

Source

fn less_than_f32(&self, other: f32, make_binary: bool) -> Self

Source

fn sign(&self) -> Self

Source

fn abs(&self) -> Self

Source

fn abs_assign(&mut self)

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.

Implementors§