Repository navigation
The Fejer-York TT Pipeline to α: Minimal Repro
Deterministic “theoretical experiment” scripts that produce the key
certificates/constants referenced in the paper.
- No network access required
- CPU only, fast, fully reproducible
- Outputs written to
outputs/as JSON (strings for numerics; no Python floats)
What this is
This repo contains a multi-script, reproducible pipeline that ties together:
-
The TT–sector normalization (
$\kappa_\infty$ ) obtained by combining a signed ($\chi_{\mathrm{TT}}$ ) with the$\chi$ –free quantity ($\Delta := M_4/3-\mathbb{E}[u_x^4]$ ) (seekappa.py). The quantity ($M_4$ ) itself is computed via stabilized Bessel–Laplace integrals with a$\sqrt{X}$ tail extrapolation (seem4.py). -
The Fejér–York lock that produces the effective length (
$L_{\mathrm{eff}}$ ), reduced mass ($m_r=e^{L_{\mathrm{eff}}/m}$ ), and a prediction for
$$\alpha^{-1} = \frac{\kappa_\infty, m}{e^{2L_{\mathrm{eff}}/m}-1}, .$$ -
Explicit error control: absolutely convergent series/pieces with printed
remainder bounds, and bracketed/bisected lock solution. -
Ablations/diagnostics: dyadic gate & isolation at the EL lock, parity and
A1g factors assembled from small, auditable scripts.
Scope note: this minimal repro implements the baseline Bessel route for
$\kappa_\infty$ . There is no separate “Route A” continuum cross-check in
this repo, and no commutator$z_\chi$ experiments.
Components (src/)
-
xq.py— Fejér quarter-FWHM lock ($K(x_q)=8/15$ ) via rigorous bisection;
emitsx_q,L0=log(15/8), and derivativesfpp,f3,f4.
JSON carries high-precision decimal strings only (no float echoes). -
m.py— EL-lock isolation + dyadic gate over oddm; reports firstm
that passes: oddness, dyadic richness proxyord_m(2) ≥ 18, and Fejér isolation
atx_q. -
m4.py— Exact Bessel–Laplace evaluation of$M_4$ with identical kernel and
$\sqrt{X}$ tail model; prints round-by-round cutoffs and the width of recent$M_4$
values; emits tail-span stats in JSON. -
kappa.py— TT baseline certificate for$\kappa_\infty$ using$\chi_{\mathrm{TT}}$
and the$\chi$ –free$\Delta$ (orM4+E[u^4]), with optional propagation of a supplied
$|\delta \Delta|$ into$|\delta \kappa|$ . -
h4.py— Exact$S^2$ moments for the cubic$A_{1g}$ quartic harmonic
$H_4$ :$\langle H_4^2\rangle$ ,$\langle H_4^3\rangle$ ,$\langle H_4^4\rangle$
(Dirichlet moments; rationals + high-precision echoes). -
cq.py— York–quartic constant:
Monte‑Carlo certificate for$C_{\hat Q}$ constancy and the exact canonical
$C_Q = 11/780$ . -
chitt.py— Linear-response scale$\chi_{\mathrm{TT}} = 3,C_Q$ (exact-fraction aware). -
j2.py— Quarter-hop Jacobian$^2$ certificate at mid-edge: emitsJ2 = 4/3
(with small surgical checks; JSON carries the rational). -
zparity.py— Parity factor$\zeta_{\text{parity}} = 8,\mathbb{E}[u_x^2 u_y^2 u_z^2]$
via separated mp.mpf quadratures (reconstructs1/105→8/105). -
edge_parity.py— Mid-edge parity/Jacobian quotient$\gamma_{\text{edge}}=15/16$ ,
also records the Fejér lock condition$K(x_q)=8/15$ . -
num_orbits.py— “Five equal mid-edge sectors”: enumerate 12 edge directions,
collapse to 6 antipodal classes, and group into 5 parity sectors (canonical paper
partition). -
zdir.py— Directional share from internal split:
$\zeta_{\text{dir}} = 8/25$ and$\zeta_{\text{wedge}} = \zeta_{\text{dir}}/N$ (K‑independent). -
a1g_xi_tt.py— A1g/normalization helper used in the amplitude chain
(emits the A1g projection coefficient consumed bygamma.py). -
gamma.py— Unified mid-edge amplitude
$\Gamma = \zeta_{\text{parity}} \cdot J_2 \cdot \zeta_{\text{dir}} \cdot C_{A1g}$
(CLI-only product; exact reconstruction when possible). -
dL2.py— Quadratic correction
$\Delta L^{(2)} = \tfrac12 f''(x_q),\langle H_4^2\rangle,(\chi_{\mathrm{TT}}\Gamma)^2$ . -
alpha.py— Final assembly of$L_{\mathrm{eff}}$ ,$m_r=e^{L_{\mathrm{eff}}/m}$ ,
and$\alpha^{-1}$ ; propagates Fejér-series remainders and a supplied absolute
$\delta\kappa$ into errors. -
hypothesis.py— Protocol/window helper. -
utils.py— Shared helpers: CLI parsing (parse_number), JSON writers, ledger
printing, rational reconstruction, deterministic output filenames, etc.
Runner (dependency-aware)
A lightweight orchestrator lives at the repo top-level:
run.py— infers dependencies from a single target and from the
inputs/outputs mapping; pulls required values from prior JSON artifacts; builds
the exact CLI for each dependency; and runs only the missing pieces.
Usage
python run.py <script_name.py> [--force]<script_name.py>must be one of the scripts declared inCONFIG["scripts"]
insiderun.py(see the list above).--forcere-runs the target even if its default JSON already exists.
Typical invocations
# End-to-end observables. Will run everything needed for alpha.json in order.
python run.py alpha.py
# Baseline κ∞ certificate (pulls χ_TT and E[u^4] from deps)
python run.py kappa.py
# Amplitude Γ (pulls z_parity, J2, z_dir, C_A1g)
python run.py gamma.py
# Freshen just the lock & curvature (and anything it depends on)
python run.py xq.py --forceWhat the runner actually does
- Infers deps by scanning the target’s declared
inputsfor variables whose
producer is another script (e.g.,alpha.pyneedsm_first→ produced bym.py). - Extracts values from the producers’ JSON using dot paths and optional
type components (e.g.,kappa_infty.float:24,m_first.int,
C_Q.rational,kappa_infty.bounds.abs.float). - Builds flags from the mapping and executes
python src/<script>.py .... - Caches per-script JSON at
outputs/<script>.json. If present, deps are
skipped unless--forceis supplied for the target (deps are still reused
from cache).
Requirements
- Python 3.11 recommended
mpmath(and any other packages listed inrequirements.txt)
Install once:
python -m pip install -r requirements.txtQuick start (macOS / Linux)
python3 -m venv .venv
source .venv/bin/activate
python -m pip install -r requirements.txt
# One command to generate final observables (and all prerequisites)
python run.py alpha.pyManual pipeline (advanced / explicit)
# 1) Lock & curvature
python src/xq.py --auto-bracket --dps 80
# 2) Dyadic/isolation gate (pass the x_q decimal from outputs/xq.json)
python src/m.py --xq "<x_q_decimal>"
# 3) Core scalars
python src/h4.py
python src/cq.py
python src/chitt.py
python src/j2.py
python src/zparity.py
python src/edge_parity.py
python src/num_orbits.py
python src/zdir.py --num-sectors 5
python src/gamma.py --z-parity 8/105 --j2 4/3 --z-dir 8/25 --c-a1g "<C_A1g>"
# 4) κ∞ and corrections
python src/m4.py --E-u4 1/5
python src/kappa.py --chi-tt 11/260 --E-u4 1/5
python src/dL2.py --fpp "<fpp>" --H4-sq 16/525 --chi-tt 11/260 --Gamma "<Gamma>"
# 5) Final observables (supply J2 or s=√J2, plus H4^3,H4^4 from h4.py)
python src/alpha.py --m 19 --kappa "<kappa>" --dkappa "<dkappa_abs>" --x-q "<x_q>" --L0 "<L0>" --deltaL2 "<ΔL2>" --Gamma "<Gamma>" --f3 "<f3>" --f4 "<f4>" --H4-m3 384/125125 --H4-m4 22784/10635625 --J2 4/3Windows (PowerShell)
Activate with. .\.venv\Scripts\Activate.ps1then:python run.py alpha.pyA convenience wrapper is also provided:
run_all.cmd.
Expected checks (sanity)
After a successful pass with defaults you should typically see:
-
outputs/m.json⇒"m_first": 19(row form=19showsord2: 18,
dyadic_pass: true,isolation_pass: true). -
outputs/xq.json⇒x_q ≈ 1.3297024653…,L0 = log(15/8),
and high-precision decimals forfpp,f3,f4(no float fields). -
outputs/kappa.json⇒ a stableκ_∞value with a printed tail-span bound. -
outputs/alpha.json⇒$m_r$ ,$\alpha^{-1}$ , and an error breakdown
consistent with Fejér tails +$\delta\kappa$ .
How things plug together
-
xq.py→x_q,L0,fpp,f3,f4 -
m.py→ validates odd-mdyadic/isolation atx_q -
h4.py,cq.py,chitt.py,j2.py,zparity.py,edge_parity.py,
num_orbits.py,zdir.py,a1g_xi_tt.py,midedge_blend_ratio_mc.py→ small audited factors -
gamma.py→ combines parity/Jacobian/direction/A1g into$\Gamma$ -
m4.py→ computes$M_4$ $\to$ tail-span -
kappa.py→ combines$\chi_{\mathrm{TT}}$ and$\Delta$ to get$\kappa_\infty$ -
dL2.py→ quadratic lock correction$\Delta L^{(2)}$ -
alpha.py→ assembles$L_{\mathrm{eff}}$ , propagates errors, outputs$m_r$ ,$\alpha^{-1}$ -
run.py→ give it a target (e.g.,alpha.py) and it will infer and run all prerequisites.
All scripts follow the same CLI contract and the shared helpers in utils.py.
Re-running & cache
- Each script writes
outputs/<script>.json. run.pyreuses those artifacts; to recompute a target from scratch, pass--force:python run.py xq.py --force
Troubleshooting
- Module not found: activate the venv and (re)install requirements.
- Precision: raise
--dps(forxq.py) or tighten tolerances if you need finer brackets/series tails. - Runner says “Missing required value”: ensure the producer script for that value has written its JSON (or just invoke the higher-level target so
run.pyruns deps automatically). - Help/usage:
python run.pywith wrong args prints the usage banner.
License
See LICENSE for code licensing.