pub struct MetricInv<const N: usize, S: Space<N>> {
pub value: Tensor<N, 2, Sym, S::SymStore>,
pub derivs: Tensor<N, 3, SymVec, S::SymVecStore>,
}Expand description
The inverse of a metric, along with partial derivatives.
Fields§
§value: Tensor<N, 2, Sym, S::SymStore>§derivs: Tensor<N, 3, SymVec, S::SymVecStore>Implementations§
Source§impl<const N: usize, S: Space<N>> MetricInv<N, S>
impl<const N: usize, S: Space<N>> MetricInv<N, S>
Sourcepub fn cotrace<I: TensorIndex<N, 2>, St: TensorStorageRef>(
&self,
matrix: &Tensor<N, 2, I, St>,
) -> f64
pub fn cotrace<I: TensorIndex<N, 2>, St: TensorStorageRef>( &self, matrix: &Tensor<N, 2, I, St>, ) -> f64
Computes the trace of a fully covariant 2-tensor.
Sourcepub fn raise_first<const R: usize, I: TensorIndex<N, R>, St: TensorStorageOwned + Default>(
&self,
tensor: &Tensor<N, R, I, St>,
) -> Tensor<N, R, I, St>
pub fn raise_first<const R: usize, I: TensorIndex<N, R>, St: TensorStorageOwned + Default>( &self, tensor: &Tensor<N, R, I, St>, ) -> Tensor<N, R, I, St>
Raises the first index of a general r-tensor.
Sourcepub fn raise_last<const R: usize, I: TensorIndex<N, R>, St: TensorStorageOwned + Default>(
&self,
tensor: &Tensor<N, R, I, St>,
) -> Tensor<N, R, I, St>
pub fn raise_last<const R: usize, I: TensorIndex<N, R>, St: TensorStorageOwned + Default>( &self, tensor: &Tensor<N, R, I, St>, ) -> Tensor<N, R, I, St>
Raises the last index of a general r-tensor.
Auto Trait Implementations§
impl<const N: usize, S> Freeze for MetricInv<N, S>
impl<const N: usize, S> RefUnwindSafe for MetricInv<N, S>where
Tensor<N, 2, Sym, <S as Space<N>>::SymStore>: RefUnwindSafe,
Tensor<N, 3, Compound<3, 2, 1, Sym, Gen>, <S as Space<N>>::SymVecStore>: RefUnwindSafe,
impl<const N: usize, S> Send for MetricInv<N, S>
impl<const N: usize, S> Sync for MetricInv<N, S>
impl<const N: usize, S> Unpin for MetricInv<N, S>
impl<const N: usize, S> UnsafeUnpin for MetricInv<N, S>where
Tensor<N, 2, Sym, <S as Space<N>>::SymStore>: UnsafeUnpin,
Tensor<N, 3, Compound<3, 2, 1, Sym, Gen>, <S as Space<N>>::SymVecStore>: UnsafeUnpin,
impl<const N: usize, S> UnwindSafe for MetricInv<N, S>where
Tensor<N, 2, Sym, <S as Space<N>>::SymStore>: UnwindSafe,
Tensor<N, 3, Compound<3, 2, 1, Sym, Gen>, <S as Space<N>>::SymVecStore>: UnwindSafe,
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