pub trait VectorOps {
type Element;
// Required methods
fn elwise_scalar_mul(
&self,
out: &mut [Self::Element],
a: &[Self::Element],
b: &Self::Element,
);
fn elwise_mul(
&self,
out: &mut [Self::Element],
a: &[Self::Element],
b: &[Self::Element],
);
fn elwise_add_mut(&self, a: &mut [Self::Element], b: &[Self::Element]);
fn elwise_sub_mut(&self, a: &mut [Self::Element], b: &[Self::Element]);
fn elwise_mul_mut(&self, a: &mut [Self::Element], b: &[Self::Element]);
fn elwise_scalar_mul_mut(&self, a: &mut [Self::Element], b: &Self::Element);
fn elwise_neg_mut(&self, a: &mut [Self::Element]);
fn elwise_fma_mut(
&self,
a: &mut [Self::Element],
b: &[Self::Element],
c: &[Self::Element],
);
fn elwise_fma_scalar_mut(
&self,
a: &mut [Self::Element],
b: &[Self::Element],
c: &Self::Element,
);
}Required Associated Types§
Required Methods§
Sourcefn elwise_scalar_mul(
&self,
out: &mut [Self::Element],
a: &[Self::Element],
b: &Self::Element,
)
fn elwise_scalar_mul( &self, out: &mut [Self::Element], a: &[Self::Element], b: &Self::Element, )
Sets out as out[i] = a[i] * b
fn elwise_mul( &self, out: &mut [Self::Element], a: &[Self::Element], b: &[Self::Element], )
fn elwise_add_mut(&self, a: &mut [Self::Element], b: &[Self::Element])
fn elwise_sub_mut(&self, a: &mut [Self::Element], b: &[Self::Element])
fn elwise_mul_mut(&self, a: &mut [Self::Element], b: &[Self::Element])
fn elwise_scalar_mul_mut(&self, a: &mut [Self::Element], b: &Self::Element)
fn elwise_neg_mut(&self, a: &mut [Self::Element])
Sourcefn elwise_fma_mut(
&self,
a: &mut [Self::Element],
b: &[Self::Element],
c: &[Self::Element],
)
fn elwise_fma_mut( &self, a: &mut [Self::Element], b: &[Self::Element], c: &[Self::Element], )
inplace mutates a: a = a + b*c