SyTen

◆ merge()

template<Rank irank>
Tensor< irank-1 > syten::MPS::TEBD::merge ( Tensor< irank > const &  itensor,
MergeConfig bases,
int const  merge_at = irank-1,
bool const  switch_bases = false 
)
inline

Takes a Tensor with rang irank and merges the legs with indices merge_at and merge_at+1 into a leg with index merge_at.

All indices greater than merge_at-1 will be shifted by -1.

Parameters
[in]itensorTensor of rank irank
[out]basesmerge configuration
[in]merge_atfirst index to be merged
[in]switch_baseswhether to switch order of bases
Returns
merged tensor

References syten::Basis::dir, syten::MPS::TEBD::MergeConfig::first(), syten::Basis::flipped(), syten::genFuse(), syten::genSplit(), syten::Tensor< rank >::getBasis(), syten::Inc, syten::MPS::TEBD::MergeConfig::second(), syten::MPS::TEBD::MergeConfig::switch_bases, and SYTEN_ASSERT_DEBUG.

Referenced by build_local_T().

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