Skip to content

Repository files navigation

A commutant gate for spectral fitting through symmetry forced degeneracy

Code and frozen reference runs for the paper of the same name.

Learned spectral models break at symmetry forced degeneracies in two distinct ways. On a forced multiplet the per level observable is not well defined, since every unit vector spanning the multiplet is an eigenvector. Near a symmetry protected crossing the eigenvector observable gradient carries a factor 1/(lambda_i - lambda_j) that is genuinely singular as the gap closes. This repository contains the pipeline that demonstrates a gate which reads the symmetry structure from the observed operators alone, distinguishes forced multiplets from accidental coincidences, and switches the fitting objective accordingly.

Everything here is synthetic by design: the symmetry is known to the experiment but withheld from the method, which is what makes each verdict checkable against an answer key.

Requirements

Python 3, NumPy, SciPy. Nothing else.

pip install numpy scipy

The exact versions used for the reference runs are recorded in environment.txt.

Files

file what it is
symmetry_gate_pipeline_v3_2.py the main artifact, eight stages, produces almost every number in the paper
probe_d.py diagnostic for the dimension estimator of Section 3.2
diag_familyB.py diagnostic locating the single family B failure at the noise ceiling
section4_measurements.py dispersion, pair spread, initial condition sweep, and misclassification cost for Section 4

Each has a frozen reference output committed alongside it, named reference_*.txt. Run any script with no arguments; none takes options.

python3 symmetry_gate_pipeline_v3_2.py

The main pipeline takes a few minutes on one core. The diagnostics take under a minute each.

Where each claim in the paper comes from

paper claim produced by stage or section of output
block identification, S3, 15/15 at eps = 0.1, 0.2, 0.3 pipeline Stage 1
gate is structural, two dimension one blocks share an energy and stay separate pipeline Stage 2
symmetric regime fit reaches theta = 0.400000 pipeline Stage 3
per level fit lands at 0.196 or 1.123 depending on eigensolver basis pipeline Stage 3
breaking regime fit returns (0.30000, -0.000000) pipeline Stage 4
gradient scaling over five decades, exponents -0.856 naive and +1.000 gated pipeline Stage 4
bias table at eps = 0.02 and 0.05 pipeline Stage 5
S4 block identification at n = 24 pipeline Stage 6
non regular families A and B, 15/15 and 14/15 pipeline Stage 7
dimension estimator lands on a divisor in 145 of 147 components probe_d.py verdict block
the two exceptions follow an upstream sector split failure probe_d.py per component detail, eps = 0.3 rows
family B's 14/15 is a sector split failure on seed 14 diag_familyB.py noise sweep
family B has two components of equal size with different irrep dimension diag_familyB.py noiseless block
standard deviations in the bias table section4_measurements.py item 1
pair spread 0.203 section4_measurements.py item 2
fit converges from seven initial conditions section4_measurements.py item 4
misclassification onset at eps = 0.4 and its cost section4_measurements.py item 5

Reproducibility, and two things that do not reproduce

Every gauge invariant quantity in the paper reproduces across machines. That includes the gated fits, the bias table, the block identification verdicts, the gated gradient column and its fitted exponent, and all diagnostic output.

Two categories do not, and both are expected rather than defects.

Gauge dependent quantities. The per level and naive baseline outcomes depend on which basis the eigensolver happens to return inside a degenerate subspace. That choice is arbitrary and differs between LAPACK builds, so these numbers differ between machines. This is not a numerical accident; it is the content of Proposition 1 appearing in the build system. The affected quantities are the per level fit results in Stage 3, the naive fit in Stage 4, and the naive column of the gradient sweep. On the machines used during development, the naive gradient column differed by roughly a decade while the gated column agreed to every digit.

Counts at a classification boundary. Where a reported number counts seeds falling on one side of a decision boundary, and the noise level places that boundary near the seeds themselves, last bit differences move a small number of seeds across it. This affects only the misclassification counts at eps = 0.4 in section4_measurements.py, which the paper therefore reports as an onset rather than as a fraction.

If you run these and get different numbers in exactly these places, that is the expected behaviour and is itself a small demonstration of the paper's argument.

Scope

The demonstrated object is a gated estimator with a low dimensional trained parameter. A full parametric matrix model, in which the matrices themselves are learned, is not demonstrated here. The commutant dimension and the sector count are supplied to the recovery rather than read from the data; see the load bearing assumptions section of the paper for why. All robustness figures use independent Gaussian unitary ensemble noise on the generators, and no claim is made for correlated noise.

Citation

If you use this, please cite the paper and the archived release DOI rather than the repository URL.

About

A commutant based gate that distinguishes symmetry forced from accidental degeneracies and keeps spectral parameter fitting well posed through both. Code and frozen reference runs for the paper.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages