Function sequant::antisymm::max_similarity

Function Documentation

ExprPtr sequant::antisymm::max_similarity(const std::vector<Index> &original_upper, const std::vector<Index> &original_lower, ExprPtr expression)

for the mnemonic rules of spin summing to work, each individual tensor/FNOperator needs to maximally resemble the original tensor, so indices may need to be swapped (and the sign changed). this does not matter for spin-orbital expressions, but the rules become incredibly simple if things stay maximally the same.

Parameters:
  • original_upper – original upper indices

  • original_lower – original lower indices

  • expression – starting expression