Template Struct LTRUncontractedIndices

Struct Documentation

template<typename T, typename Set = std::set<T>, typename Vec = std::vector<Set>>
struct LTRUncontractedIndices

Helper struct to hold indices for left-to-right binarization.

Template Parameters:
  • T – The type of the index (e.g., Index).

  • Set – The type of the set container (default: std::set<T>).

  • Vec – The type of the vector container (default: std::vector<Set>).

Public Members

Vec children

The relevant indices of the input tensors (leaves). These are indices that either participate in future contractions or are external. They correspond to [A, B, C] sub-expressions in a product Prod [A, B, C]. These sets are computed so that uncontracted indices can be utilized in the children’s binarization index computations.

Vec imed

The indices of the intermediate tensors. imed[i] contains the open indices after contracting the first (i+1) tensors. They correspond to [A, AB, ABC] intermediates when a product expression Prod [A, B, C] is to be evaluated left-to-right.