#!/usr/bin/env python3 """ The Neon Special Editions — Unified 250-Check Live Verification Runner & Atlas Auditor ====================================================================================== Zero-dependency Python 3 verifier for the 10-Edition, 50-Chamber Pure & Applied Mathematics Special Editions Constellation (SE I – SE X): 1. Verifies the 50-chamber registry & 36-bridge cross-mathematical constellation graph (uniqueness, completeness, connectivity across all 10 special editions, valid routes). 2. Fetches all 10 live Special Edition verifier scripts from GitLab Pages, computes exact byte lengths and SHA-256 receipts, executes every suite locally, parses exact PASSED/FAILED counts, and confirms 10/10 special editions and 250/250 individual mathematical theorems pass with 0 failures. Usage: python3 verify_specials.py # Topology audit + all 10 live verifiers (250 checks) python3 verify_specials.py --topology # Audit only the 50-chamber / 36-bridge graph python3 verify_specials.py --ed SE1 SE10 # Audit + selected editions (SE1..SE10) """ import argparse import collections import hashlib import os import re import subprocess import sys import tempfile import time import urllib.request SPECIAL_EDITIONS = [ { "num": "SE1", "roman": "I", "short": "Geometry", "title": "The Neon Discrete Differential Geometry & Polyhedral Curvature Atelier", "url": "https://the-neon-geometry-atelier-4c1aab.gitlab.io/", "verifier": "verify_geometry.py", "chambers": [ ("SE1.1", "descartes", "Descartes Angle Defect & Polyhedral Gauss–Bonnet"), ("SE1.2", "laplacian", "Cotangent Laplacian & Mean Curvature Flow"), ("SE1.3", "heat", "Crane–Weischedel–Wardetzky Heat Method Geodesics"), ("SE1.4", "curves", "Space Curves, Călugăreanu Twist/Writhe & Fáry–Milnor"), ("SE1.5", "delaunay", "Intrinsic Delaunay Flips, Voronoi Dual & Rippa"), ], }, { "num": "SE2", "roman": "II", "short": "Complex", "title": "The Neon Complex Analysis, Riemann Surfaces & Conformal Mapping Atelier", "url": "https://the-neon-complex-atelier-a6e6bf.gitlab.io/", "verifier": "verify_complex.py", "chambers": [ ("SE2.1", "domain", "Domain Coloring & Argument Principle"), ("SE2.2", "riemann", "Riemann Surfaces & Branch-Cut Monodromy"), ("SE2.3", "cauchy", "Cauchy Integral Formula & Residue Calculus"), ("SE2.4", "mobius", "Möbius Transformations, Cross-Ratio & Riemann Sphere"), ("SE2.5", "conformal", "Schwarz–Christoffel Mapping & Poisson Kernel"), ], }, { "num": "SE3", "roman": "III", "short": "Lie Groups", "title": "The Neon Lie Groups, Spinors & Symmetry Atelier", "url": "https://the-neon-lie-atelier-b0033d.gitlab.io/", "verifier": "verify_lie.py", "chambers": [ ("SE3.1", "spinors", "SU(2) → SO(3) Double Cover & 4π Dirac Belt Trick"), ("SE3.2", "roots", "Root Systems A₂, B₂, G₂, A₃ & Weyl Reflections"), ("SE3.3", "weights", "SU(3) Weight Diagrams, Gell-Mann & Eightfold Way"), ("SE3.4", "bracket", "Lie Bracket, BCH Expansion & SE(2) Parallel Parking"), ("SE3.5", "coadjoint", "Coadjoint Orbits, Dzhanibekov Flip & Poinsot Ellipsoid"), ], }, { "num": "SE4", "roman": "IV", "short": "Topology", "title": "The Neon Algebraic Topology, Homology & Vector Fields Atelier", "url": "https://the-neon-topology-atelier-68e9e6.gitlab.io/", "verifier": "verify_topology.py", "chambers": [ ("SE4.1", "homology", "Simplicial Homology (SNF over ℤ/𝔽₂) & Hodge Laplacian"), ("SE4.2", "poincare", "Poincaré–Hopf Index Theorem & Vector Field Surgery"), ("SE4.3", "persistence", "Vietoris–Rips Persistent Homology & Barcodes"), ("SE4.4", "covering", "Covering Spaces, F₂ Cayley Tree & Pochhammer Loop"), ("SE4.5", "morse", "Morse Theory, Critical Handlebodies & Reeb Graphs"), ], }, { "num": "SE5", "roman": "V", "short": "Game Theory", "title": "The Neon Game Theory, Evolutionary Dynamics & Social Choice Atelier", "url": "https://the-neon-gametheory-atelier-9e6f33.gitlab.io/", "verifier": "verify_gametheory.py", "chambers": [ ("SE5.1", "nash", "Exact Rational Nash Equilibria, Lemke–Howson & QRE"), ("SE5.2", "replicator", "Simplex Replicator Dynamics, RPS & Fisher Selection"), ("SE5.3", "auctions", "Myerson Revenue Equivalence, VCG & CRRA Bidding"), ("SE5.4", "matching", "Gale–Shapley Stable Matching, Shapley Value & Core"), ("SE5.5", "voting", "Social Choice Paradoxes, Arrow, Schulze & 2D Voronoi"), ], }, { "num": "SE6", "roman": "VI", "short": "Signal", "title": "The Neon Signal Processing, Wavelets & Spectral Analysis Atelier", "url": "https://the-neon-signal-atelier-88ddad.gitlab.io/", "verifier": "verify_signal.py", "chambers": [ ("SE6.1", "fourier", "Fourier Synthesis, Wilbraham–Gibbs & Fejér/Lanczos"), ("SE6.2", "sampling", "Whittaker–Shannon Sampling, Nyquist & Hilbert Envelope"), ("SE6.3", "zplane", "Z-Plane Poles/Zeros, Group Delay & Bilinear Butterworth"), ("SE6.4", "wavelets", "Daubechies D4 Wavelets, Morlet & Gabor Uncertainty"), ("SE6.5", "sensing", "Compressed Sensing L₁ vs L₂ Geometry & OMP/FISTA"), ], }, { "num": "SE7", "roman": "VII", "short": "Numerical", "title": "The Neon Numerical Analysis, Spectral Methods & Scientific Computing Atelier", "url": "https://the-neon-numerical-atelier-9ec360.gitlab.io/", "verifier": "verify_numerical.py", "chambers": [ ("SE7.1", "runge", "Runge Phenomenon, Chebyshev–Lobatto & Bernstein Ellipse"), ("SE7.2", "newton", "Newton/Halley Fractal Basins & Wilkinson Polynomial"), ("SE7.3", "quadrature", "Golub–Welsch Gauss–Legendre & Clenshaw–Curtis"), ("SE7.4", "svd", "SVD Geometry, Conjugate Gradient & Hilbert Conditioning"), ("SE7.5", "stiff", "Stability Islands, Dahlquist & Symplectic Shadow H"), ], }, { "num": "SE8", "roman": "VIII", "short": "Convex Opt", "title": "The Neon Convex Geometry, Optimization & Duality Atelier", "url": "https://the-neon-optimization-atelier-b6d30f.gitlab.io/", "verifier": "verify_optimization.py", "chambers": [ ("SE8.1", "simplex", "Exact Rational Simplex, Farkas Lemma & Klee–Minty"), ("SE8.2", "descent", "Gradient Descent, Nesterov Acceleration, Newton & BFGS"), ("SE8.3", "interior", "Log-Barrier Central Path, Dikin Ellipsoid & ADMM LASSO"), ("SE8.4", "svm", "Support Vector Machines, RBF Kernel & Mercer PSD"), ("SE8.5", "convex", "Polar Duality, Mahler Volume, Löwner–John & Fenchel"), ], }, { "num": "SE9", "roman": "IX", "short": "Combinatorics", "title": "The Neon Combinatorics, Graph Theory & Ramsey Atelier", "url": "https://the-neon-combinatorics-atelier-aaebbe.gitlab.io/", "verifier": "verify_combinatorics.py", "chambers": [ ("SE9.1", "ramsey", "Ramsey Numbers, Paley(17) Coloring & Turán Graphs"), ("SE9.2", "chromatic", "Chromatic Polynomials, Stanley Acyclic & Kempe Swaps"), ("SE9.3", "flows", "Max-Flow Min-Cut, Menger, Hall & Birkhoff–von Neumann"), ("SE9.4", "catalan", "Catalan 4-Way Bijection & 3D Tamari Associahedron"), ("SE9.5", "generating", "Euler Pentagonal, Hook-Length, Dyson Rank & Prüfer"), ], }, { "num": "SE10", "roman": "X", "short": "Probability", "title": "The Neon Probability, Martingales & Information Geometry Atelier", "url": "https://the-neon-probability-atelier-386db6.gitlab.io/", "verifier": "verify_probability.py", "chambers": [ ("SE10.1", "fisher", "Fisher–Rao Manifold (K = −½), e/m-Duality & Cramér–Rao"), ("SE10.2", "martingale", "Doob Optional Stopping, Wald Identities & Kelly Ruin"), ("SE10.3", "bayes", "Symplectic HMC vs RW-MH & Bernstein–von Mises"), ("SE10.4", "concentration", "Irwin–Hall Berry–Esseen & Cramér/Sanov Large Deviations"), ("SE10.5", "copulas", "Sklar Tail-Dependence Copulas & James–Stein Shrinkage"), ], }, ] # 36 curated cross-mathematical bridges uniting all 10 Special Editions BRIDGES = [ # Geometry & Topology bridges ("SE1.1", "SE4.2", "geometry", "Polyhedral Gauss–Bonnet Angle Defect ↔ Poincaré–Hopf Index Sum"), ("SE1.2", "SE4.1", "geometry", "Discrete Cotangent Laplacian ↔ Simplicial Hodge Laplacian L₁"), ("SE1.3", "SE4.5", "geometry", "Heat-Method Geodesic Distance ↔ Morse Level Sets & Reeb Graphs"), ("SE1.4", "SE3.1", "geometry", "Space-Curve Călugăreanu Twist/Writhe ↔ SU(2) 4π Dirac Belt Trick"), ("SE1.5", "SE5.5", "discrete", "Delaunay/Voronoi Intrinsic Dual ↔ 2D Spatial Voting Voronoi Cells"), ("SE1.1", "SE10.1", "geometry", "Discrete Gaussian Curvature K ↔ Fisher–Rao Hyperbolic Curvature K = −½"), ("SE1.2", "SE2.5", "analysis", "Discrete Harmonic Functions ↔ Conformal Poisson Kernel & Schwarz–Christoffel"), # Complex Analysis & Lie Groups bridges ("SE2.4", "SE3.1", "algebra", "PSL(2,ℂ) Möbius Sphere Automorphisms ↔ SU(2) → SO(3) Spinor Cover"), ("SE2.2", "SE4.4", "geometry", "Riemann Surface Branch Monodromy ↔ Covering-Space Deck Transformations"), ("SE2.3", "SE10.4", "analysis", "Cauchy Integral Residue Calculus ↔ Complex Contour CGF Cumulants κ₁…κ₄"), ("SE2.1", "SE7.2", "analysis", "Complex Argument Principle Zeros ↔ Newton & Halley Fractal Root Basins"), ("SE2.3", "SE6.3", "analysis", "Cauchy Poles & Residue Contour ↔ Z-Plane Transfer Poles & Stability"), ("SE2.5", "SE7.1", "analysis", "Conformal Map & Joukowsky/Ellipse ↔ Bernstein Ellipse Chebyshev Convergence"), # Lie Groups, Symmetry & Dynamics bridges ("SE3.2", "SE9.4", "algebra", "Weyl Reflection Coxeter Polytopes ↔ 3D Tamari Associahedron K₆"), ("SE3.3", "SE9.5", "algebra", "SU(3) Weight Multiplicity Diagrams ↔ Young Tableaux Hook-Length Formula"), ("SE3.4", "SE8.2", "optimization", "BCH Non-Commuting Vector Flows ↔ Curvature-Aware Optimization Steps"), ("SE3.5", "SE7.5", "analysis", "Coadjoint Symplectic Rigid-Body Flow ↔ Velocity Verlet Shadow Hamiltonian"), ("SE3.5", "SE10.3", "geometry", "Hamiltonian Phase-Space Conservation ↔ Symplectic HMC Leapfrog Volume"), # Topology & Combinatorics bridges ("SE4.1", "SE9.2", "discrete", "Simplicial Chain Complexes & Betti β₁ ↔ Graph Cycle Space & Chromatic Poly"), ("SE4.3", "SE9.1", "discrete", "Vietoris–Rips Clique Filtration ↔ Ramsey Cliques & Turán Extremal Density"), ("SE4.4", "SE9.3", "discrete", "F₂ Cayley Tree & Graph Coverings ↔ Menger Vertex-Disjoint Paths"), ("SE4.5", "SE8.2", "optimization", "Morse Critical Points & Saddle Index ↔ Non-Convex Himmelblau Landscape"), # Game Theory, Optimization & Combinatorics bridges ("SE5.1", "SE8.1", "optimization", "Minimax / Lemke–Howson Pivot Paths ↔ Simplex Vertex Pivoting & Farkas"), ("SE5.2", "SE10.1", "optimization", "Simplex Δ² Replicator Dynamics ↔ Shahshahani / Fisher–Rao Information Metric"), ("SE5.3", "SE8.5", "optimization", "Myerson Ironed Virtual Values ↔ Convex Conjugate & Fenchel–Young Duality"), ("SE5.4", "SE9.3", "discrete", "Gale–Shapley Stable Matching & Core ↔ Hall Marriage & Birkhoff Polytope"), ("SE5.1", "SE8.4", "optimization", "Zero-Sum Saddle Minimax Theorem ↔ Dual SVM Max-Margin Saddle Point"), # Signal Processing, Numerical Analysis & Convex Optimization bridges ("SE6.1", "SE7.1", "analysis", "Fourier Gibbs vs Fejér/Lanczos ↔ Runge Phenomenon & Chebyshev–Lobatto"), ("SE6.2", "SE7.3", "analysis", "Whittaker–Shannon Bandlimited Sinc ↔ Periodic Trapezoid & Gauss Quadrature"), ("SE6.4", "SE7.4", "analysis", "Orthonormal Daubechies D4 Basis ↔ Orthogonal SVD Spectral Decomposition"), ("SE6.5", "SE8.3", "optimization", "Compressed Sensing L₁ Diamond Recovery ↔ ADMM LASSO & Interior-Point Path"), ("SE6.1", "SE10.4", "analysis", "Fourier Characteristic Functions ↔ Central Limit Convolution & Berry–Esseen"), # Numerical, Optimization, Combinatorics & Probability bridges ("SE7.4", "SE8.2", "optimization", "Ill-Conditioned Spectral Ellipse κ(A) ↔ Conjugate Gradient vs Steepest Descent"), ("SE8.5", "SE10.4", "optimization", "Legendre–Fenchel Convex Conjugate f* ↔ Cramér Large-Deviation Rate I(x)"), ("SE9.3", "SE8.1", "discrete", "Birkhoff Doubly Stochastic Polytope ↔ Exact Rational Linear Programming"), ("SE10.2", "SE9.4", "discrete", "André Reflection Principle Walks ↔ Catalan Dyck Paths & Ballot Theorem"), ] def audit_topology(): print("=" * 78) print("THE NEON SPECIAL EDITIONS ATLAS — CONSTELLATION TOPOLOGY AUDIT (SE I–X)") print("=" * 78) assert len(SPECIAL_EDITIONS) == 10, f"Expected 10 editions, got {len(SPECIAL_EDITIONS)}" chamber_map = {} url_routes = set() for ed in SPECIAL_EDITIONS: assert len(ed["chambers"]) == 5, f"{ed['num']} must have 5 chambers" for cid, slug, title in ed["chambers"]: assert cid not in chamber_map, f"Duplicate chamber ID {cid}" route = f"{ed['url']}#{slug}" assert route not in url_routes, f"Duplicate URL route {route}" url_routes.add(route) chamber_map[cid] = (ed["num"], slug, title) assert len(chamber_map) == 50, f"Expected 50 chambers, got {len(chamber_map)}" seen_edges = set() ed_adj = collections.defaultdict(set) cross_count = 0 for a, b, theme, desc in BRIDGES: assert a in chamber_map, f"Unknown bridge endpoint {a}" assert b in chamber_map, f"Unknown bridge endpoint {b}" assert a != b, f"Self-loop bridge {a}" key = tuple(sorted((a, b))) assert key not in seen_edges, f"Duplicate bridge {key}" seen_edges.add(key) ea, eb = chamber_map[a][0], chamber_map[b][0] if ea != eb: cross_count += 1 ed_adj[ea].add(eb) ed_adj[eb].add(ea) # BFS connectivity across all 10 editions visited = set() q = collections.deque(["SE1"]) visited.add("SE1") while q: u = q.popleft() for v in ed_adj[u]: if v not in visited: visited.add(v) q.append(v) assert len(visited) == 10, f"Special Editions bridge graph disconnected: reached {len(visited)}/10" min_deg = min(len(ed_adj[e["num"]]) for e in SPECIAL_EDITIONS) assert min_deg >= 4, f"Minimum cross-edition degree too low: {min_deg}" print(" [PASS] Registry integrity: 10 Special Editions · 50 Chambers · 50 unique #hash routes") print(f" [PASS] Bridge graph: {len(BRIDGES)} unique bridges ({cross_count} cross-edition), 0 duplicates") print(f" [PASS] Connectivity: 10/10 special editions connected (min cross-edition degree = {min_deg})") return True def run_live_verifiers(selected_eds): print("\n" + "=" * 78) print("LIVE GITLAB PAGES 250-CHECK VERIFICATION SWEEP (ALL 10 SPECIAL EDITIONS)") print("=" * 78) results = [] total_chambers = 0 total_bytes = 0 total_checks_pass = 0 total_checks_fail = 0 t_all = time.time() with tempfile.TemporaryDirectory(prefix="neon_specials_") as tmpdir: for ed in SPECIAL_EDITIONS: if selected_eds and ed["num"] not in selected_eds: continue script_url = ed["url"] + ed["verifier"] t0 = time.time() req = urllib.request.Request( script_url, headers={"User-Agent": "Neon-Specials-Unified-Verifier/1.0"}, ) status, raw = None, None for attempt in range(4): try: with urllib.request.urlopen(req, timeout=30) as resp: status = resp.status raw = resp.read() break except Exception: if attempt == 3: raise time.sleep(0.5 * (attempt + 1)) assert status == 200, f"HTTP {status} for {script_url}" sha = hashlib.sha256(raw).hexdigest() local_path = os.path.join(tmpdir, f"{ed['num']}_{ed['verifier']}") with open(local_path, "wb") as fh: fh.write(raw) proc = subprocess.run( [sys.executable, local_path], capture_output=True, text=True, timeout=120, ) dt = time.time() - t0 out = (proc.stdout or "") + "\n" + (proc.stderr or "") passed = proc.returncode == 0 m = re.search(r"(\d+)\s+PASSED,\s+(\d+)\s+FAILED", out) if m: n_p, n_f = int(m.group(1)), int(m.group(2)) else: n_p = len(re.findall(r"\[PASS\]", out)) n_f = len(re.findall(r"\[FAIL\]", out)) if n_f > 0: passed = False status_tag = "PASS" if passed else "FAIL" print( f" [{status_tag}] {ed['num']:>4} {ed['short']:<13} | " f"{n_p:>2}/{n_p+n_f:<2} checks | {len(raw):>6,} B | " f"sha256:{sha[:12]} | {dt:4.2f}s" ) if not passed: lines = [ln.strip() for ln in out.splitlines() if ln.strip()] print(" STDERR/STDOUT tail:\n" + "\n".join(" " + l for l in lines[-12:])) results.append((ed["num"], passed, len(ed["chambers"]), len(raw), sha, n_p, n_f)) total_chambers += len(ed["chambers"]) total_bytes += len(raw) total_checks_pass += n_p total_checks_fail += n_f elapsed = time.time() - t_all n_pass = sum(1 for r in results if r[1]) n_fail = len(results) - n_pass print("-" * 78) print( f"SPECIAL EDITIONS CERTIFICATION: {n_pass}/{len(results)} EDITIONS · " f"{total_chambers} CHAMBERS · {total_checks_pass}/{total_checks_pass + total_checks_fail} CHECKS · " f"{total_bytes:,} BYTES · {elapsed:.2f}s · {n_fail} FAILURES" ) print("=" * 78) return n_fail == 0 and total_checks_fail == 0 def main(): parser = argparse.ArgumentParser( description="Verify The Neon Special Editions Constellation Atlas & all 10 live Special Editions (250 checks)." ) parser.add_argument("--topology", action="store_true", help="Run only the 50-chamber / 36-bridge topology audit.") parser.add_argument("--ed", nargs="+", help="Run only specific editions (e.g. --ed SE1 SE5 SE10).") args = parser.parse_args() audit_topology() if args.topology: sys.exit(0) selected = set(v.upper() for v in args.ed) if args.ed else None ok = run_live_verifiers(selected) sys.exit(0 if ok else 1) if __name__ == "__main__": main()