ResearchPod Summary
A wide range of questions in quantum information science—such as bounding Bell inequality violations, state discrimination, dimension witnessing, and randomness certification—ultimately share a common mathematical core. They require determining whether a collection of numerical data can arise from physical operators subject to specific algebraic relations. Solving this directly is a hard, non-convex problem over an unbounded operator space. To make these problems tractable, researchers employ semidefinite programming (SDP) relaxations, such as the Navascués-Pironio-Acín (NPA) hierarchy, by optimizing over the moments of these operators arranged into a positive semidefinite moment matrix.
The central challenge in constructing these matrices is not writing down the moment entries, but managing the numerous structural equivalences—such as idempotency, orthogonality, and commutation relations—that make many matrix entries redundant. Hand-calculating these reduction rules becomes infeasible for large hierarchies, and incorrect handling can silently invalidate the relaxation. This paper presents MoMPy, a pure Python package designed to make the construction of moment matrices automatic, fast, verifiable, and unified across different physical scenarios.
MoMPy implements a declarative interface where the user defines operator labels along with a small set of structural relations. Rather than relying on hardcoded operator types or fixed notions of physical parties, the package treats the identification problem as a word-rewriting problem on tuples of integers.
Internally, MoMPy uses a memoized breadth-first closure coupled to a disjoint-set forest with a sticky zero class. This ensures that each distinct monomial is processed exactly once per build, regardless of how many matrix entries it ultimately labels. Furthermore, the core abstraction is designed to be independent of the physical scenario. By altering simple configuration flags, the same underlying object and monomial list can generate tracial moments, standard state (NPA) moments, or block-valued moments where the matrix entries themselves are operators.
To demonstrate its generality, the package is validated against an independent brute-force implementation and benchmarked across eight structurally distinct scenarios. These include:
The ability to handle block-valued moments—a recently introduced hierarchy—by simply changing a block size flag while keeping the declared relations and downstream modeling layer untouched serves as a rigorous test of the abstraction's flexibility.
AI-generated third-party summary by ResearchPod. Not official content or an endorsement by the paper authors or affiliated organizations.