Table of Contents
Fetching ...

TeMFpy: a Python library for converting fermionic mean-field states into tensor networks

Simon H. Hille, Attila Szabó

TL;DR

TeMFpy delivers a practical, open-source pipeline to convert fermionic mean-field states into MPS representations, enabling seamless integration with tensor-network techniques and DMRG/VUMPS workflows. By exploiting the Gaussian structure of Slater determinants and Pfaffian/Bogoliubov states, the library computes MPS entries from overlaps of entangled orbitals with favorable scaling, and extends naturally to infinite MPS for gapped, translation-invariant systems. Its core contributions include efficient Slater/Pfaffian Schmidt decompositions, fast overlap computations via determinant/Pfaffian formulas, and a modular design that supports iMPS construction and Gutzwiller projection to spin systems. This combination empowers robust initialization, variational studies, and exploration of spin liquids and other strongly correlated phases by fusing mean-field accuracy with tensor-network flexibility. The work thus provides a scalable, extensible toolkit bridging mean-field theory, VMC, and tensor networks for correlated electron systems.

Abstract

We introduce TeMFpy, a Python library for converting fermionic mean-field states to finite or infinite matrix product state (MPS) form. TeMFpy includes new, efficient, and easy-to-understand algorithms for both Slater determinants and Pfaffian states. Together with Gutzwiller projection, these also allow the user to build variational wave functions for various strongly correlated electron systems, such as quantum spin liquids. We present all implemented algorithms in detail and describe how they can be accessed through TeMFpy, including full example workflows. TeMFpy is built on top of TeNPy and, therefore, integrates seamlessly with existing MPS-based algorithms.

TeMFpy: a Python library for converting fermionic mean-field states into tensor networks

TL;DR

TeMFpy delivers a practical, open-source pipeline to convert fermionic mean-field states into MPS representations, enabling seamless integration with tensor-network techniques and DMRG/VUMPS workflows. By exploiting the Gaussian structure of Slater determinants and Pfaffian/Bogoliubov states, the library computes MPS entries from overlaps of entangled orbitals with favorable scaling, and extends naturally to infinite MPS for gapped, translation-invariant systems. Its core contributions include efficient Slater/Pfaffian Schmidt decompositions, fast overlap computations via determinant/Pfaffian formulas, and a modular design that supports iMPS construction and Gutzwiller projection to spin systems. This combination empowers robust initialization, variational studies, and exploration of spin liquids and other strongly correlated phases by fusing mean-field accuracy with tensor-network flexibility. The work thus provides a scalable, extensible toolkit bridging mean-field theory, VMC, and tensor networks for correlated electron systems.

Abstract

We introduce TeMFpy, a Python library for converting fermionic mean-field states to finite or infinite matrix product state (MPS) form. TeMFpy includes new, efficient, and easy-to-understand algorithms for both Slater determinants and Pfaffian states. Together with Gutzwiller projection, these also allow the user to build variational wave functions for various strongly correlated electron systems, such as quantum spin liquids. We present all implemented algorithms in detail and describe how they can be accessed through TeMFpy, including full example workflows. TeMFpy is built on top of TeNPy and, therefore, integrates seamlessly with existing MPS-based algorithms.

Paper Structure

This paper contains 41 sections, 61 equations, 5 figures, 1 algorithm.

Figures (5)

  • Figure 1: (a) In order to make the submatrix $A$ of $O$\ref{['eq: bigO']} that contains the overlaps of occupied orbitals, we may need to reclassify some occupied orbitals as entangled. The size $k$ of $A$ is the smaller of the number of occupied orbitals in the bra and the ket state. (b) The matrix $A$ appears in all overlap matrices \ref{['eq: block determinant']} that determine the elements of the left-canonical tensor $A^{n_i}_{\alpha \beta}$. The remaining blocks are subsets of the rows/columns of the submatrices $\mathcal{B}, \mathcal{C},$ and $\mathcal{D}$ (gray lines indicate the rows/columns left out), depending on the entangled orbitals in the respective bra (rows) and ket (columns) Schmidt vectors. To efficiently compute the tensor entries, we precompute $\det(A)$ and the matrix $\mathcal{S}$\ref{['eq: S matrix']} and select the appropriate rows and columns of $\mathcal{S}$ for each tensor element.
  • Figure 2: (a) One unit cell's worth of MPS tensors extracted from a finite MPS cannot be used directly as an iMPS unit cell due to the mismatched gauge choices $X$ and $Y$ on its two ends. Upon repeating such a naïve unit cell, these unequal gauge tensors do not cancel out but alter the wave function by inserting spurious unitaries $YX^{-1}$ (red) on the virtual legs connecting unit cells. (b) Suitable iMPS unit cells (yellow) can be constructed by contracting the first and last tensors of a unit cell extracted from the longer MPS (black) with unitary matrices $C_0, D_0$ obtained as the overlaps of the left and right environments $\ket{L^{(L,n)}}$ and $\ket{R^{(L, n+k)}}$ with their counterparts $\bra{L^{(L-k,n)}}$ and $\bra{R^{(L-k, n)}}$ in a shorter chain (purple). This transforms the Schmidt bases on both ends of the unit cell to that of the shorter chain at entanglement cut $n$ (free purple legs), thus making them consistent upon repeating. To obtain normalised Schmidt vectors in the environment, both chains must be in mixed canonical form (indicated by diagonal slashes in each tensor block).
  • Figure 3: Separating left and right entangled operators $d_L^\dagger, d_R^\dagger$ in one term of the Schmidt decomposition \ref{['eq: generalSlaterDet']}. Starting point is the entangled orbitals sorted in decreasing order of $\lambda$ (the magnitude of $\lambda$ or $(1-\lambda)$ is indicated by the sizes of the inner red or blue blobs, respectively). The right entangled operators are then swapped one by one to the right end, starting from the rightmost. The resulting fermionic anticommutation sign for each right entangled orbital is given by $(-1)^i$, where $i$ denotes the initial position in the list of entangled orbitals, counted from the right.
  • Figure 4: To include entangled orbitals that are in fact occupied in every Schmidt vector (dashed black border and partially filled) in the submatrix $A$ in \ref{['eq: block matrix determinant formula']}, all entangled operators $d_L^\dagger$(a) / $d_R^\dagger$(b) with mixed occupation (red/blue border) have to be moved past them. Starting from the entangled orbital with the smallest/largest eigenvalue (indicated by the size of the inner blob), they are moved one by one to the right/left, without changing their relative order. Therefore, each entangled orbital picks up a fermionic anticommutation sign determined by the number of reclassified orbitals to its right/left.
  • Figure 5: Overlap of the wave function $\ket\Psi$ on the longer chain of length $L$ and its reconstruction $\ket{\tilde{\Psi}}$ from MPS tensors of a shorter chain of length $L-k$ and a single iMPS unit cell of length $k$. Diagonal slashes indicate whether each tensor is left- or right-canonical. (a, b) Estimates of the overlap assuming that the reconstruction of the environment to the right (a) or to the left (b) of the iMPS unit cell is perfect.

Theorems & Definitions (3)

  • proof
  • proof
  • proof