void syten::transpose | ( | ConstSpan< Scalar > const | inp, |
MutSpan< Scalar > | out, | ||
[[maybe_unused] ] ConstSpan< Index > | in_perm, | ||
[[maybe_unused] ] ConstSpan< Index > | in_dim, | ||
[[maybe_unused] ] Conj | do_conj = Conj::n() , |
||
[[maybe_unused] ] bool | do_checks = true |
||
) |
Entry point for transposition of a continuous array into another array.
rank | maximal number of indices |
Scalar | underlying scalar type |
method | transposition method, default is heuristic based on tensor size |
Indices | helper argument to generate an index sequence (see syten::transpose_impl). |
inp | source array, row-major |
out | output array, row-major |
in_perm | permutation array, perm[i] = j says that the old leg j should be placed at position i+1 (all 1-indexed), at most size rank |
in_dim | input dimensions array, at most size rank |
do_conj | if Conj::y(), conjugate every element |
do_checks | if true, remove 1-dimensional indices and combine runs |
References syten::SpanImpl::MutSpan< T >::begin(), syten::Cuda::conj_copy(), std::copy(), if_constexpr, rank(), syten::SpanImpl::MutSpan< T >::size(), SYTEN_ASSERT_MSG, and syten::YesNo< struct _prod_conj >::y().
Referenced by syten::Delinearise::cols_only(), syten::Eigen::eigenGen(), syten::Eigen::eigenSym(), exponentialTensorSym(), syten::Krylov::SolverPolicies::Exponential::get_coeffs(), syten::IdentityDenseTensorImpl::merge(), syten::DenseProduct::one_times_many(), pseudo_inverse_svd(), syten::Delinearise::rows(), syten::MPS::DMRG::LBOWorker::singleUpdate(), syten::Krylov::ClassicImpl::ExponentialSolver< Solver >::solve(), syten::DenseSolve::solve(), syten::SVD::svd(), and syten::MPS::TDVP::LBOWorker::sweep_single().