using syten::STensor = typedef STensorImpl::STensor |
‘Smart’ tensor class.
Main features compared to the plain syten::Tensor:
Incoming indices are bras, outgoing indices are kets. Rank-2 tensors can always be contracted with a single leg of any other (even) tensor as long as their outgoing leg comes fermionically first and their incoming leg comes fermionically second.
STensor
, e.g. STensor[3;0]
signifies a rank-3 STensor with autodiff ID 0 (disabled), STensor[0;5]
signifies an STensor with rank 0 and autodiff ID 5. The address of the STensor in memory is given next as a hexadecimal number. Subsequently, for higher-rank tensors, the bases on the (arbitrarily numbered) legs and the fermionic order of those legs are given together with the nonzero blocks of the tensor. Rank-0 tensors are presented only by their numerical value, where the imaginary part is left off if it is non-zero.