IntegrateUnitary.jl: A Julia package for symbolic integration over Haar measures
Pith reviewed 2026-05-25 04:14 UTC · model grok-4.3
The pith
IntegrateUnitary.jl computes exact symbolic integrals of polynomials over Haar measures on compact groups.
A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.
Core claim
The package supplies a fully open-source realization of Weingarten calculus together with Wick contractions, equipped with broad symbolic-d support, that evaluates entry-wise and trace-polynomial integrals over U(d), O(d), Sp(d), SU(d) for balanced polynomials, circular and Gaussian ensembles, Ginibre ensembles, permutation groups, random pure states, and unitary t-designs; selected higher-trace and matrix-valued workflows accept concrete integer dimensions while automatic asymptotic expansions and a symbolic trace interface are also provided.
What carries the argument
Weingarten calculus and Wick contractions, which convert polynomial expectations over Haar measure into sums over permutations or partitions evaluated via the Murnaghan-Nakayama rule and symplectic-orthogonal duality.
If this is right
- High-degree moments of traces become available in closed symbolic form for both symbolic and concrete d.
- Quantum information quantities that require averaging polynomials over random unitaries can be obtained exactly.
- Tensor-network expectations over random unitaries are directly accessible through the ITensors.jl interface.
- Automatic large-d expansions are generated for any supported polynomial integral.
Where Pith is reading between the lines
- Routine access to these integrals may allow researchers to derive new closed-form relations among quantum metrics without manual case-by-case calculation.
- The same symbolic engine could be applied to verify conjectures about higher moments in random matrix ensembles.
- Integration with computer-algebra systems outside Julia would let users combine these results with other symbolic manipulations.
Load-bearing premise
The algorithms including the Murnaghan-Nakayama rule and symplectic-orthogonal duality are correctly implemented to return the claimed exact symbolic results.
What would settle it
Evaluating the known integral of |tr(U)|^2 over U(d) and obtaining any value other than 1.
Figures
read the original abstract
Symbolic integration over the Haar measure of compact groups is a computational cornerstone in quantum information science and random matrix theory. We present \texttt{IntegrateUnitary.jl}, a comprehensive Julia package for computing exact expectations of polynomial functions over a wide range of compact groups ($U(d)$, $O(d)$, $Sp(d)$, and $SU(d)$ for balanced polynomials), circular and Gaussian ensembles, Ginibre ensembles, permutation groups, random pure states, and unitary $t$-designs. The package provides a fully open-source implementation of the Weingarten calculus and Wick contractions with broad symbolic-$d$ support for entry-wise and trace-polynomial integrals, while selected workflows currently require concrete integer dimensions (including higher pure trace moments $|\mathrm{tr}(U)|^{2k}$ for $k > 1$ and HCIZ with \texttt{SymbolicMatrix} inputs, and direct matrix-valued integration of \texttt{SymbolicMatrix}/\texttt{SymbolicMatrixProduct} expressions), automatic asymptotic expansions, a high-level symbolic trace interface that reconstructs Weingarten graphs from index-free expressions, and a bridge to \texttt{ITensors.jl} for tensor network averaging. We discuss the underlying algorithms, including the Murnaghan-Nakayama rule and symplectic-orthogonal duality, and demonstrate that the package efficiently handles high-degree moments and quantum information metrics.
Editorial analysis
A structured set of objections, weighed in public.
Referee Report
Summary. The manuscript presents IntegrateUnitary.jl, a Julia package implementing Weingarten calculus, Wick contractions, and related combinatorial algorithms (including the Murnaghan-Nakayama rule and symplectic-orthogonal duality) to compute exact symbolic expectations of polynomial functions over Haar measures on U(d), O(d), Sp(d), SU(d) (balanced case), circular/Gaussian/Ginibre ensembles, permutation groups, random pure states, and unitary t-designs, with support for symbolic d in entry-wise and trace-polynomial integrals plus selected workflows for concrete d.
Significance. A verified, open-source implementation with broad symbolic-d support would be a useful addition to the quantum-information and random-matrix-theory toolkit, enabling reproducible exact computations of high-degree moments and metrics that are currently handled case-by-case in the literature.
major comments (2)
- [Abstract and algorithm sections] Abstract and algorithm-description sections: the central claim that the package produces exact symbolic results rests on the correctness of the Murnaghan-Nakayama implementation and the symplectic-orthogonal duality; the manuscript describes these algorithms but supplies no explicit cross-checks against independently known closed forms (e.g., the exact expression for E[|tr(U)|^{2k}] for small k or the HCIZ integral at low order).
- [Demonstration sections] Demonstration and results sections: while the text states that the package 'efficiently handles high-degree moments,' no concrete symbolic outputs, error checks, or comparisons with existing Weingarten-function tables or other implementations are reported, so the load-bearing assumption that the graph-reconstruction and character-evaluation routines are free of off-by-one or sign errors for symbolic d remains untested in the manuscript.
minor comments (2)
- [Abstract] Clarify which workflows require concrete integer d versus fully symbolic d, and list the precise polynomial classes supported for each group.
- [Results] Add a short table or appendix entry showing at least one low-order symbolic result together with the corresponding known closed form.
Simulated Author's Rebuttal
We thank the referee for the detailed and constructive report. We agree that the manuscript would be strengthened by the addition of explicit verification examples and concrete outputs. We will revise accordingly to address both major comments.
read point-by-point responses
-
Referee: [Abstract and algorithm sections] Abstract and algorithm-description sections: the central claim that the package produces exact symbolic results rests on the correctness of the Murnaghan-Nakayama implementation and the symplectic-orthogonal duality; the manuscript describes these algorithms but supplies no explicit cross-checks against independently known closed forms (e.g., the exact expression for E[|tr(U)|^{2k}] for small k or the HCIZ integral at low order).
Authors: We agree that explicit cross-checks are needed to support the claim of exact symbolic results. In the revised manuscript we will add a dedicated verification subsection that computes E[|tr(U)|^{2k}] for small k (k=1,2,3) and matches the outputs against the known closed-form expressions from the literature. We will likewise include low-order HCIZ integrals and compare them with independently tabulated results. These additions will directly test the Murnaghan-Nakayama rule and the symplectic-orthogonal duality implementations. revision: yes
-
Referee: [Demonstration sections] Demonstration and results sections: while the text states that the package 'efficiently handles high-degree moments,' no concrete symbolic outputs, error checks, or comparisons with existing Weingarten-function tables or other implementations are reported, so the load-bearing assumption that the graph-reconstruction and character-evaluation routines are free of off-by-one or sign errors for symbolic d remains untested in the manuscript.
Authors: We accept that the current demonstration sections do not contain the requested concrete outputs or comparisons. The revised version will include explicit symbolic results for selected high-degree moments, direct numerical comparisons against published Weingarten-function tables for both integer and symbolic d, and side-by-side checks with at least one other open implementation where available. These additions will confirm the correctness of the graph-reconstruction and character-evaluation routines. revision: yes
Circularity Check
No circularity: package description implements external algorithms
full rationale
The manuscript is a software package description presenting IntegrateUnitary.jl. It implements known methods (Weingarten calculus, Murnaghan-Nakayama rule, symplectic-orthogonal duality) drawn from prior literature rather than deriving new results. No predictions, fitted parameters, or self-referential derivations appear; the load-bearing assumption is correct implementation of externally documented combinatorial algorithms. This is self-contained against external benchmarks and receives the default non-circularity finding.
Axiom & Free-Parameter Ledger
axioms (1)
- domain assumption Weingarten calculus and the Murnaghan-Nakayama rule correctly compute the integrals over the listed Haar measures
Lean theorems connected to this paper
-
IndisputableMonolith/Cost/FunctionalEquation.leanwashburn_uniqueness_aczel unclear?
unclearRelation between the paper passage and the cited Recognition theorem.
Weingarten calculus... Murnaghan-Nakayama rule and symplectic-orthogonal duality... Wg^U(σ,d) via characters χ_λ and Schur polynomials s_λ(1^d)
-
IndisputableMonolith/Foundation/RealityFromDistinction.leanreality_from_one_distinction unclear?
unclearRelation between the paper passage and the cited Recognition theorem.
Integration over Haar measure of compact groups... unitary t-designs, Ginibre ensembles
What do these tags mean?
- matches
- The paper's claim is directly supported by a theorem in the formal canon.
- supports
- The theorem supports part of the paper's argument, but the paper may add assumptions or extra steps.
- extends
- The paper goes beyond the formal theorem; the theorem is a base layer rather than the whole result.
- uses
- The paper appears to rely on the theorem as machinery.
- contradicts
- The paper's claim conflicts with a theorem or certificate in the canon.
- unclear
- Pith found a possible connection, but the passage is too broad, indirect, or ambiguous to say the theorem truly supports the claim.
Reference graph
Works this paper leans on
-
[1]
Sylvester’s identity and multistep integer-preserving Gaussian elimination.Math. Comp.22, 103 (1968), 565–578. https: //doi.org/10.1090/S0025-5718-1968-0226829-0 Ingemar Bengtsson and Karol Życzkowski. 2017.Geometry of quantum states: an introduction to quantum entanglement(2 ed.). Cambridge University Press. Jeff Bezanson, Alan Edelman, Stefan Karpinski,...
-
[2]
Julia: A fresh approach to numerical computing.SIAM review59, 1 (2017), 65–98. https://doi.org/10.1137/141000671 Fernando GSL Brandao, Aram W Harrow, and Michał Horodecki
-
[3]
https://doi.org/10.1007/s00220-016-2706-8 Yanic Cardin, Hubert de Guise, and Nicolás Quesada
Local random quantum circuits are approximate polynomial-designs.Communica- tions in Mathematical Physics346, 2 (2016), 397–434. https://doi.org/10.1007/s00220-016-2706-8 Yanic Cardin, Hubert de Guise, and Nicolás Quesada
-
[4]
International Mathematics Research Notices2003, 17 (2003), 953–982
Moments and cumulants of polynomial random variables on unitary groups, the Itzykson-Zuber integral, and free probability. International Mathematics Research Notices2003, 17 (2003), 953–982. https://doi.org/10.1155/S107379280320917X Benoît Collins and Piotr Śniady
-
[5]
Integration with respect to the Haar measure on unitary, orthogonal and symplectic groups.Communications in Mathematical Physics264, 3 (2006), 773–795. https://doi.org/10.1007/s00220-006-1554-3 Manuscript submitted to ACM 26 Pawela and Puchała Christoph Dankert, Richard Cleve, Joseph Emerson, and Etera Livine
-
[6]
Exact and approximate unitary 2-designs and their application to fidelity estimation.Physical Review A80, 1 (2009), 012304. https://doi.org/10.1103/PhysRevA.80.012304 Alan Edelman, Tomás A Arias, and Steven T Smith
-
[7]
https://doi.org/10.1137/S089547989833276X Matthew Fishman, Steven R
The geometry of algorithms with orthogonality constraints.SIAM journal on Matrix Analysis and Applications20, 2 (1998), 303–353. https://doi.org/10.1137/S089547989833276X Matthew Fishman, Steven R. White, and E. Miles Stoudenmire
-
[8]
The ITensor Software Library for Tensor Network Calculations.SciPost Phys. Codebases(2022),
work page 2022
-
[9]
2010.Log-Gases and Random Matrices (LMS-34)
https://doi.org/10.21468/SciPostPhysCodeb.4 Peter J Forrester. 2010.Log-Gases and Random Matrices (LMS-34). Princeton University Press. Motohisa Fukuda, Robert König, and Ion Nechita
-
[10]
https://doi.org/10.1088/1751-8121/ab434b Jean Ginibre
RTNI—A symbolic integrator for Haar-random tensor networks.Journal of Physics A: Mathematical and Theoretical52, 42 (2019), 425303. https://doi.org/10.1088/1751-8121/ab434b Jean Ginibre
-
[11]
Statistical ensembles of complex, quaternion, and real matrices.J. Math. Phys.6, 3 (1965), 440–449. https://doi.org/10.1063/1.1704292 Shashi Gowda, Yingbo Ma, Alessandro Cheli, Maja Gwóźzdź, Viral B. Shah, Alan Edelman, and Christopher Rackauckas
-
[12]
https://doi.org/10.1145/3511528.3511535 David Gross, Koenraad Audenaert, and Jens Eisert
High-Performance Symbolic-Numerics via Multiple Dispatch.ACM Communications in Computer Algebra55, 3 (2022), 92–96. https://doi.org/10.1145/3511528.3511535 David Gross, Koenraad Audenaert, and Jens Eisert
-
[13]
Evenly distributed unitaries: On the structure of unitary designs.J. Math. Phys.48, 5 (2007), 052104. https://doi.org/10.1063/1.2716992 Harish-Chandra
-
[14]
https://doi.org/10.2307/ 2372786 Claude Itzykson and Jean-Bernard Zuber
Spherical Functions on a Semisimple Lie Group, I.American Journal of Mathematics80, 2 (1958), 241–310. https://doi.org/10.2307/ 2372786 Claude Itzykson and Jean-Bernard Zuber
work page 1958
-
[15]
The planar approximation. II.J. Math. Phys.21, 3 (1980), 411–421. https://doi.org/10.1063/1.524438 Giacomo Livan, Marcel Novaes, and Pierpaolo Vivo. 2018.Introduction to Random Matrices: Theory and Practice. SpringerBriefs in Mathematical Physics, Vol
-
[16]
https://doi.org/10.1007/978-3-319-70885-0 Madan Lal Mehta
Springer. https://doi.org/10.1007/978-3-319-70885-0 Madan Lal Mehta. 2004.Random matrices. Elsevier. Michael A Nielsen and Isaac L Chuang. 2010.Quantum computation and quantum information. Cambridge University Press. Don N Page
-
[17]
https://doi.org/10.1103/PhysRevLett.71.1291 Zbigniew Puchała and Jarosław Adam Miszczak
Average entropy of a subsystem.Physical Review Letters71, 9 (1993), 1291–1294. https://doi.org/10.1103/PhysRevLett.71.1291 Zbigniew Puchała and Jarosław Adam Miszczak
-
[18]
https://doi.org/10.1515/bpasts-2017-0003 John Watrous
Symbolic integration with respect to the Haar measure on the unitary group.Bulletin of the Polish Academy of Sciences: Technical Sciences65, 1 (2017), 21–27. https://doi.org/10.1515/bpasts-2017-0003 John Watrous. 2018.The theory of quantum information. Cambridge University Press. Don Weingarten
-
[19]
Asymptotic behavior of group integrals in the limit of infinite rank.J. Math. Phys.19, 5 (1978), 999–1001. https://doi.org/10.1063/ 1.523807 Gian Carlo Wick
work page 1978
-
[20]
https://doi.org/10.1103/PhysRev.80.268 Karol Życzkowski and Hans-Jürgen Sommers
The evaluation of the collision matrix.Physical Review80, 2 (1950), 268–272. https://doi.org/10.1103/PhysRev.80.268 Karol Życzkowski and Hans-Jürgen Sommers
-
[21]
https://doi.org/10.1088/0305-4470/34/35/335 Manuscript submitted to ACM
Induced measures in the space of mixed quantum states.Journal of Physics A: Mathematical and General34, 35 (2001), 7111–7125. https://doi.org/10.1088/0305-4470/34/35/335 Manuscript submitted to ACM
discussion (0)
Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.