SyTen

◆ normSqd()

STensor syten::STensorImpl::normSqd ( STensor const &  t,
SourceLocation const &  loc = SourceLocation::current() 
)

Returns the squared norm of a tensor.

Remarks
This function is autodifferentiable.

References syten::abs(), conj(), syten::STensorImpl::STensor::enable_autodiff(), syten::STensorImpl::Autodiff::ComputeNode::get_cached_tensors(), syten::STensorImpl::Autodiff::ComputeNode::get_output_adjoint(), if_constexpr, syten::Inc, make_zero(), syten::STensorImpl::STensor::move(), syten::mve(), syten::STensorImpl::Autodiff::new_id(), syten::normSqd(), prod(), syten::STensorImpl::STensor::set_autodiff_node(), and SYTEN_TENSOR_RANK.

Referenced by norm(), and snorm().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: