Table of Contents
Fetching ...

Approximate Contraction of Arbitrary Tensor Networks with a Flexible and Efficient Density Matrix Algorithm

Linjian Ma, Matthew Fishman, Miles Stoudenmire, Edgar Solomonik

TL;DR

This work tackles the challenge of contracting arbitrary tensor networks efficiently by introducing partitioned_contract, a flexible framework that uses partial contraction trees and an embedding-tree representation to produce low-rank tree TNs. The method integrates an environment-aware density-matrix truncation (with memoization) and an embedding-tree construction that respects contraction paths, enabling scalable contractions across general graph structures beyond lattices. It generalizes boundary-based algorithms to arbitrary graphs and demonstrates favorable empirical performance, including substantial speedups over prior approaches while maintaining accuracy. The results indicate meaningful improvements in both the computational cost and contraction fidelity for lattice and nonlattice TNs, highlighting the practical impact for quantum physics, statistical mechanics, and related fields.

Abstract

Tensor network contractions are widely used in statistical physics, quantum computing, and computer science. We introduce a method to efficiently approximate tensor network contractions using low-rank approximations, where each intermediate tensor generated during the contractions is approximated as a low-rank binary tree tensor network. The proposed algorithm has the flexibility to incorporate a large portion of the environment when performing low-rank approximations, which can lead to high accuracy for a given rank. Here, the environment refers to the remaining set of tensors in the network, and low-rank approximations with larger environments can generally provide higher accuracy. For contracting tensor networks defined on lattices, the proposed algorithm can be viewed as a generalization of the standard boundary-based algorithms. In addition, the algorithm includes a cost-efficient density matrix algorithm for approximating a tensor network with a general graph structure into a tree structure, whose computational cost is asymptotically upper-bounded by that of the standard algorithm that uses canonicalization. Experimental results indicate that the proposed technique outperforms previously proposed approximate tensor network contraction algorithms for multiple problems in terms of both accuracy and efficiency.

Approximate Contraction of Arbitrary Tensor Networks with a Flexible and Efficient Density Matrix Algorithm

TL;DR

This work tackles the challenge of contracting arbitrary tensor networks efficiently by introducing partitioned_contract, a flexible framework that uses partial contraction trees and an embedding-tree representation to produce low-rank tree TNs. The method integrates an environment-aware density-matrix truncation (with memoization) and an embedding-tree construction that respects contraction paths, enabling scalable contractions across general graph structures beyond lattices. It generalizes boundary-based algorithms to arbitrary graphs and demonstrates favorable empirical performance, including substantial speedups over prior approaches while maintaining accuracy. The results indicate meaningful improvements in both the computational cost and contraction fidelity for lattice and nonlattice TNs, highlighting the practical impact for quantum physics, statistical mechanics, and related fields.

Abstract

Tensor network contractions are widely used in statistical physics, quantum computing, and computer science. We introduce a method to efficiently approximate tensor network contractions using low-rank approximations, where each intermediate tensor generated during the contractions is approximated as a low-rank binary tree tensor network. The proposed algorithm has the flexibility to incorporate a large portion of the environment when performing low-rank approximations, which can lead to high accuracy for a given rank. Here, the environment refers to the remaining set of tensors in the network, and low-rank approximations with larger environments can generally provide higher accuracy. For contracting tensor networks defined on lattices, the proposed algorithm can be viewed as a generalization of the standard boundary-based algorithms. In addition, the algorithm includes a cost-efficient density matrix algorithm for approximating a tensor network with a general graph structure into a tree structure, whose computational cost is asymptotically upper-bounded by that of the standard algorithm that uses canonicalization. Experimental results indicate that the proposed technique outperforms previously proposed approximate tensor network contraction algorithms for multiple problems in terms of both accuracy and efficiency.
Paper Structure (43 sections, 6 theorems, 15 equations, 26 figures, 2 tables, 6 algorithms)

This paper contains 43 sections, 6 theorems, 15 equations, 26 figures, 2 tables, 6 algorithms.

Key Result

theorem 6.1

Consider a given tensor network $G=(V,E)$, an embedding tree $T=(V_T,E_T)$, and an embedding $\phi$ that embeds $G$ into $T$. Let $\sigma : V_T\to \{1,\ldots, |V_T|\}$ be a post-order DFS traversal of $T$ that shows the the tensor update ordering. Assuming that changing a tree tensor network into it

Figures (26)

  • Figure 1: Illustration of the matrix product state (MPS), the (full) binary tree tensor network, and the tree tensor network state (TTNS). MPS is a maximally-unbalanced binary tree tensor network if contracting the tensor at one end with its neighbor. Both MPS and the binary tree tensor network are special cases of TTNS, where each tensor has an order of at most 3.
  • Figure 2: Illustration of the approximate contraction technique used in jermyn2020automaticpan2020contractingchubb2021general. Each intermediate is approximated as an MPS, which has an unbalanced binary tree structure. The left diagram is the tensor diagram of the input tensor network. Each dashed box denotes the part of the tensor network that is approximated as an MPS.
  • Figure 3: Illustration of different contraction trees. Each blue vertex denotes a tensor, and the green lines and dots denote the binary contraction tree. The contraction tree visualization has been adapted from gray2022hyper. In (b), each dotted box denotes a partition of the tensor network. The partial contraction sequence shown in (b) corresponds to a standard left-to-right boundary MPS contraction verstraete2004renormalization.
  • Figure 4: (a) Illustration of the partitoned_contract algorithm. The algorithm takes as inputs a tensor network, a partitioning of that tensor network, and a partial contraction tree. The algorithm proceeds by traversing the partial contraction tree and approximately contracting a pair of tensor network partitions into a binary tree tensor network. (b) Illustration of the process to approximate the input tensor network (left diagram) into a binary tree tensor network (right diagram). The embedding tree is a rooted binary tree that represents the output tree structure. The tree embedding step maps a partition of the input tensor network to each non-leaf (orange) vertex in the embedding tree. Finally, the density matrix algorithm (or the canonicalization-base algorithm) approximates the embedded tensor network into a binary tree tensor network. Each black dot in the diagrams represents an identity matrix.
  • Figure 5: Illustration of the matrix product operator (MPO), the projected entangled pair states (PEPS), and the $3 \times 3 \times 2$ 3D lattice tensor network.
  • ...and 21 more figures

Theorems & Definitions (17)

  • definition 1: Canonical form
  • definition 2: Density matrix
  • theorem 6.1
  • proof
  • definition 3
  • definition 4: MPS tree
  • definition 5: Embedding tree with an MPS structure
  • definition 6: Embedding tree with a comb structure
  • lemma E.1
  • theorem E.2
  • ...and 7 more