import numpy as np
Mbar=2.435323e18; alpha=1/137.035999; s158=np.sqrt(158.0)
s0=2.2255e-38; rhoc=8.0992e-47; g=106.75
def Om(n,theta=1.0):
    m=s158*Mbar*alpha**(16-n); f=Mbar*alpha**n
    T=np.sqrt(m*Mbar/(3*np.sqrt(np.pi**2*g/90)))
    Y=(0.5*m*f**2*theta**2)/((2*np.pi**2/45)*g*T**3)
    return m, (m*Y*s0/rhoc)
print("Each candidate exponent n, its GEOMETRIC justification, and what it forces:")
print(f"{'n':>2} {'principle':<42}{'m_chi':>11}{'Omega h^2':>12}  verdict")
rows=[
 (0,"kinetic normalization f~Mbar (the TRUE f_a)"," KINETIC"),
 (1,"b_3 = 1  (cohomology dim of the harmonic 3-form)","COHOM"),
 (3,"dim S^3 = dim su(2)  (manifold / left-inv only)","MANIFOLD"),
 (5,"dim O^5 chiral channels  (corpus v3.4 coupling)","COUPLING"),
 (6,"dim so(4) = ISOMETRY of S^3  (== Higgs su(3)=8 rule)","ISOMETRY"),
]
for n,desc,tag in rows:
    m,O=Om(n)
    works = "0.01<O<2" if 0.005<O<3 else ("OVERCLOSE" if O>3 else "UNDERPRODUCE")
    v = "WORKS (theta~O(1))" if 0.02<O<3 else ("overcloses x%.0e"%(O/0.12) if O>3 else "fails, x%.0e short"%(0.12/O))
    print(f"{n:>2} {desc:<42}{m*1e9:>9.2g}eV{O:>12.2g}  {v}")
print()
print("THE consistency test: which principle does the Higgs (the ONE clean rung) use?")
print("  Higgs v = alpha^8, with 8 = dim su(3) = dim(ISOMETRY algebra of CP^2).")
print("  Apply the SAME principle to S^3:  dim(isometry so(4)) = 6  ->  n=6  ->  chi FAILS.")
print("  n=3 requires dim su(2)=3 = HALF the isometry (left only) -- NOT what the Higgs rule uses.")
print()
print("VERDICT: every consistent principle (isometry=6, coupling=5, cohomology=1, kinetic=0)")
print("gives a FAILING exponent. Only n=3 works, and n=3 is the ONE value no consistent")
print("principle forces. The theorem does NOT close at n=3.")
