pub struct TensorRank1<const D: usize, const I: usize>(/* private fields */);
Expand description
A d-dimensional tensor of rank 1.
D
is the dimension, I
is the configuration.
Implementations§
Trait Implementations§
Source§impl<const D: usize, const I: usize> Add<&TensorRank1<D, I>> for TensorRank1<D, I>
impl<const D: usize, const I: usize> Add<&TensorRank1<D, I>> for TensorRank1<D, I>
Source§impl<const D: usize, const I: usize> Add<TensorRank1<D, I>> for &TensorRank1<D, I>
impl<const D: usize, const I: usize> Add<TensorRank1<D, I>> for &TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
+
operator.Source§impl<const D: usize, const I: usize> AddAssign<&TensorRank1<D, I>> for TensorRank1<D, I>
impl<const D: usize, const I: usize> AddAssign<&TensorRank1<D, I>> for TensorRank1<D, I>
Source§fn add_assign(&mut self, tensor_rank_1: &Self)
fn add_assign(&mut self, tensor_rank_1: &Self)
Performs the
+=
operation. Read moreSource§impl<const D: usize, const I: usize> AddAssign for TensorRank1<D, I>
impl<const D: usize, const I: usize> AddAssign for TensorRank1<D, I>
Source§fn add_assign(&mut self, tensor_rank_1: Self)
fn add_assign(&mut self, tensor_rank_1: Self)
Performs the
+=
operation. Read moreSource§impl<const D: usize, const I: usize> Clone for TensorRank1<D, I>
impl<const D: usize, const I: usize> Clone for TensorRank1<D, I>
Source§fn clone(&self) -> TensorRank1<D, I>
fn clone(&self) -> TensorRank1<D, I>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<const D: usize, const I: usize, const J: usize, const K: usize, const L: usize> ContractSecondFourthIndicesWithFirstIndicesOf<&TensorRank1<D, J>, &TensorRank1<D, L>> for TensorRank4<D, I, J, K, L>
impl<const D: usize, const I: usize, const J: usize, const K: usize, const L: usize> ContractSecondFourthIndicesWithFirstIndicesOf<&TensorRank1<D, J>, &TensorRank1<D, L>> for TensorRank4<D, I, J, K, L>
type Output = TensorRank2<D, I, K>
fn contract_second_fourth_indices_with_first_indices_of( &self, tensor_rank_1_a: &TensorRank1<D, J>, tensor_rank_1_b: &TensorRank1<D, L>, ) -> Self::Output
Source§impl<const D: usize, const I: usize, const J: usize> Convert<TensorRank1<D, J>> for TensorRank1<D, I>
impl<const D: usize, const I: usize, const J: usize> Convert<TensorRank1<D, J>> for TensorRank1<D, I>
Source§fn convert(&self) -> TensorRank1<D, J>
fn convert(&self) -> TensorRank1<D, J>
Converts this type into the (usually inferred) input type.
Source§impl<const D: usize, const I: usize> Div<&f64> for &TensorRank1<D, I>
impl<const D: usize, const I: usize> Div<&f64> for &TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
/
operator.Source§impl<const D: usize, const I: usize> Div<&f64> for TensorRank1<D, I>
impl<const D: usize, const I: usize> Div<&f64> for TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
/
operator.Source§impl<const D: usize, const I: usize, const J: usize> Div<TensorRank2<D, I, J>> for TensorRank1<D, I>
impl<const D: usize, const I: usize, const J: usize> Div<TensorRank2<D, I, J>> for TensorRank1<D, I>
Source§type Output = TensorRank1<D, J>
type Output = TensorRank1<D, J>
The resulting type after applying the
/
operator.Source§impl<const D: usize, const I: usize> Div<f64> for &TensorRank1<D, I>
impl<const D: usize, const I: usize> Div<f64> for &TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
/
operator.Source§impl<const D: usize, const I: usize> Div<f64> for TensorRank1<D, I>
impl<const D: usize, const I: usize> Div<f64> for TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
/
operator.Source§impl<const D: usize, const I: usize> DivAssign<&f64> for TensorRank1<D, I>
impl<const D: usize, const I: usize> DivAssign<&f64> for TensorRank1<D, I>
Source§fn div_assign(&mut self, tensor_rank_0: &TensorRank0)
fn div_assign(&mut self, tensor_rank_0: &TensorRank0)
Performs the
/=
operation. Read moreSource§impl<const D: usize, const I: usize> DivAssign<f64> for TensorRank1<D, I>
impl<const D: usize, const I: usize> DivAssign<f64> for TensorRank1<D, I>
Source§fn div_assign(&mut self, tensor_rank_0: TensorRank0)
fn div_assign(&mut self, tensor_rank_0: TensorRank0)
Performs the
/=
operation. Read moreSource§impl<const D: usize, const I: usize, const J: usize> From<&TensorRank1<D, I>> for TensorRank1<D, J>
impl<const D: usize, const I: usize, const J: usize> From<&TensorRank1<D, I>> for TensorRank1<D, J>
Source§fn from(tensor_rank_1: &TensorRank1<D, I>) -> Self
fn from(tensor_rank_1: &TensorRank1<D, I>) -> Self
Converts to this type from the input type.
Source§impl<const D: usize, const I: usize, const W: usize> FromIterator<TensorRank1<D, I>> for TensorRank1List<D, I, W>
impl<const D: usize, const I: usize, const W: usize> FromIterator<TensorRank1<D, I>> for TensorRank1List<D, I, W>
Source§fn from_iter<Ii: IntoIterator<Item = TensorRank1<D, I>>>(
into_iterator: Ii,
) -> Self
fn from_iter<Ii: IntoIterator<Item = TensorRank1<D, I>>>( into_iterator: Ii, ) -> Self
Creates a value from an iterator. Read more
Source§impl<const D: usize, const I: usize> FromIterator<TensorRank1<D, I>> for TensorRank1Vec<D, I>
impl<const D: usize, const I: usize> FromIterator<TensorRank1<D, I>> for TensorRank1Vec<D, I>
Source§fn from_iter<Ii: IntoIterator<Item = TensorRank1<D, I>>>(
into_iterator: Ii,
) -> Self
fn from_iter<Ii: IntoIterator<Item = TensorRank1<D, I>>>( into_iterator: Ii, ) -> Self
Creates a value from an iterator. Read more
Source§impl<const D: usize, const I: usize, const J: usize> FromIterator<TensorRank1<D, J>> for TensorRank2<D, I, J>
impl<const D: usize, const I: usize, const J: usize> FromIterator<TensorRank1<D, J>> for TensorRank2<D, I, J>
Source§fn from_iter<Ii: IntoIterator<Item = TensorRank1<D, J>>>(
into_iterator: Ii,
) -> Self
fn from_iter<Ii: IntoIterator<Item = TensorRank1<D, J>>>( into_iterator: Ii, ) -> Self
Creates a value from an iterator. Read more
Source§impl<const D: usize, const I: usize> FromIterator<f64> for TensorRank1<D, I>
impl<const D: usize, const I: usize> FromIterator<f64> for TensorRank1<D, I>
Source§fn from_iter<Ii: IntoIterator<Item = TensorRank0>>(into_iterator: Ii) -> Self
fn from_iter<Ii: IntoIterator<Item = TensorRank0>>(into_iterator: Ii) -> Self
Creates a value from an iterator. Read more
Source§impl<const D: usize, const I: usize> Mul<&TensorRank1<D, I>> for TensorRank1<D, I>
impl<const D: usize, const I: usize> Mul<&TensorRank1<D, I>> for TensorRank1<D, I>
Source§impl<const D: usize, const I: usize, const J: usize> Mul<&TensorRank1<D, J>> for &TensorRank2<D, I, J>
impl<const D: usize, const I: usize, const J: usize> Mul<&TensorRank1<D, J>> for &TensorRank2<D, I, J>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
*
operator.Source§impl<const D: usize, const I: usize, const J: usize> Mul<&TensorRank1<D, J>> for TensorRank2<D, I, J>
impl<const D: usize, const I: usize, const J: usize> Mul<&TensorRank1<D, J>> for TensorRank2<D, I, J>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
*
operator.Source§impl<const D: usize, const I: usize> Mul<&f64> for &TensorRank1<D, I>
impl<const D: usize, const I: usize> Mul<&f64> for &TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
*
operator.Source§impl<const D: usize, const I: usize> Mul<&f64> for TensorRank1<D, I>
impl<const D: usize, const I: usize> Mul<&f64> for TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
*
operator.Source§impl<const D: usize, const I: usize> Mul<TensorRank1<D, I>> for &TensorRank1<D, I>
impl<const D: usize, const I: usize> Mul<TensorRank1<D, I>> for &TensorRank1<D, I>
Source§impl<const D: usize, const I: usize, const J: usize> Mul<TensorRank1<D, J>> for &TensorRank2<D, I, J>
impl<const D: usize, const I: usize, const J: usize> Mul<TensorRank1<D, J>> for &TensorRank2<D, I, J>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
*
operator.Source§impl<const D: usize, const I: usize, const J: usize> Mul<TensorRank1<D, J>> for TensorRank2<D, I, J>
impl<const D: usize, const I: usize, const J: usize> Mul<TensorRank1<D, J>> for TensorRank2<D, I, J>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
*
operator.Source§impl<const D: usize, const I: usize> Mul<f64> for &TensorRank1<D, I>
impl<const D: usize, const I: usize> Mul<f64> for &TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
*
operator.Source§impl<const D: usize, const I: usize> Mul<f64> for TensorRank1<D, I>
impl<const D: usize, const I: usize> Mul<f64> for TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
*
operator.Source§impl<const D: usize, const I: usize> MulAssign<&f64> for TensorRank1<D, I>
impl<const D: usize, const I: usize> MulAssign<&f64> for TensorRank1<D, I>
Source§fn mul_assign(&mut self, tensor_rank_0: &TensorRank0)
fn mul_assign(&mut self, tensor_rank_0: &TensorRank0)
Performs the
*=
operation. Read moreSource§impl<const D: usize, const I: usize> MulAssign<f64> for TensorRank1<D, I>
impl<const D: usize, const I: usize> MulAssign<f64> for TensorRank1<D, I>
Source§fn mul_assign(&mut self, tensor_rank_0: TensorRank0)
fn mul_assign(&mut self, tensor_rank_0: TensorRank0)
Performs the
*=
operation. Read moreSource§impl<const D: usize, const I: usize> Sub<&TensorRank1<D, I>> for TensorRank1<D, I>
impl<const D: usize, const I: usize> Sub<&TensorRank1<D, I>> for TensorRank1<D, I>
Source§impl<const D: usize, const I: usize> Sub<TensorRank1<D, I>> for &TensorRank1<D, I>
impl<const D: usize, const I: usize> Sub<TensorRank1<D, I>> for &TensorRank1<D, I>
Source§type Output = TensorRank1<D, I>
type Output = TensorRank1<D, I>
The resulting type after applying the
-
operator.Source§impl<const D: usize, const I: usize> SubAssign<&TensorRank1<D, I>> for TensorRank1<D, I>
impl<const D: usize, const I: usize> SubAssign<&TensorRank1<D, I>> for TensorRank1<D, I>
Source§fn sub_assign(&mut self, tensor_rank_1: &Self)
fn sub_assign(&mut self, tensor_rank_1: &Self)
Performs the
-=
operation. Read moreSource§impl<const D: usize, const I: usize> SubAssign for TensorRank1<D, I>
impl<const D: usize, const I: usize> SubAssign for TensorRank1<D, I>
Source§fn sub_assign(&mut self, tensor_rank_1: Self)
fn sub_assign(&mut self, tensor_rank_1: Self)
Performs the
-=
operation. Read moreSource§impl<const D: usize, const I: usize> Tensor for TensorRank1<D, I>
impl<const D: usize, const I: usize> Tensor for TensorRank1<D, I>
Source§fn full_contraction(&self, tensor_rank_1: &Self) -> TensorRank0
fn full_contraction(&self, tensor_rank_1: &Self) -> TensorRank0
Returns the full contraction with another tensor.
Source§fn iter_mut(&mut self) -> impl Iterator<Item = &mut Self::Item>
fn iter_mut(&mut self) -> impl Iterator<Item = &mut Self::Item>
Returns an iterator that allows modifying each value. Read more
Source§fn get_at(&self, _indices: &[usize]) -> &TensorRank0
fn get_at(&self, _indices: &[usize]) -> &TensorRank0
Returns a reference to the entry at the specified indices.
Source§fn get_at_mut(&mut self, _indices: &[usize]) -> &mut TensorRank0
fn get_at_mut(&mut self, _indices: &[usize]) -> &mut TensorRank0
Returns a mutable reference to the entry at the specified indices.
Source§fn norm(&self) -> TensorRank0
fn norm(&self) -> TensorRank0
Returns the tensor norm.
Source§fn norm_squared(&self) -> TensorRank0
fn norm_squared(&self) -> TensorRank0
Returns the tensor norm squared.
Source§fn normalized(self) -> Self
fn normalized(self) -> Self
Returns the tensor normalized.
Source§impl<const D: usize, const I: usize> TensorArray for TensorRank1<D, I>
impl<const D: usize, const I: usize> TensorArray for TensorRank1<D, I>
Auto Trait Implementations§
impl<const D: usize, const I: usize> Freeze for TensorRank1<D, I>
impl<const D: usize, const I: usize> RefUnwindSafe for TensorRank1<D, I>
impl<const D: usize, const I: usize> Send for TensorRank1<D, I>
impl<const D: usize, const I: usize> Sync for TensorRank1<D, I>
impl<const D: usize, const I: usize> Unpin for TensorRank1<D, I>
impl<const D: usize, const I: usize> UnwindSafe for TensorRank1<D, I>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more