SyTen

◆ sqrt()

STensor syten::STensorImpl::sqrt ( STensor  in)

Takes the square root of a diagonal rank-2 or rank-0 tensor after mapping it to matrix form (outgoing leg first, incoming leg second in fermionic order).

Does not change the tensor legs.

Remarks
This function is autodifferentiable.

References syten::STensorImpl::STensor::autodiff_enabled(), syten::STensorImpl::STensor::b(), change_fermionic_order(), syten::STensorImpl::STensor::copy(), syten::Cuda::copy(), syten::STensorImpl::SBasis::dir(), syten::STensorImpl::STensor::get_and_renew_autodiff(), syten::STensorImpl::Autodiff::ComputeNode::get_cached_tensors(), syten::STensorImpl::Autodiff::ComputeNode::get_output_adjoint(), hadamard(), if_constexpr, syten::Inc, invert_diagonal(), make_zero(), std::move(), syten::mve(), syten::STensorImpl::STensor::rank(), syten::STensorImpl::STensor::set_autodiff_node(), syten::sqrt(), SYTEN_ASSERT, SYTEN_TENSOR_RANK, and syten::STensorImpl::STensor::visit().

Referenced by syten::MPS::equiscale(), syten::MPS::norm(), syten::T3N::norm(), and norm().

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