NOT accepted into the proposed rule by the stop rule: under the projection the flat families are already budget-bound (CHA 3220 -> 3198 only) while the false flags on APS cost 2806 -> 3029 (Z2 fails); with G2 both sets fail. The per-problem edge over Chandrupatla on APS turns into 26/72/55. Guarantee intact in every cell. Next candidate, not pre-registered: require the promise to fail twice in a row. Regression on the branch: 918 pass (twice); the one red test is the paper-number check awaiting the paper update. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
54 lines
2.8 KiB
Python
54 lines
2.8 KiB
Python
"""Verdicts Z1-Z5 of PREREG_flat_regime_2026-09-21.md (stage 2) from sweep_flat.json.
|
|
|
|
python -u analyze_flat.py
|
|
"""
|
|
from __future__ import annotations
|
|
|
|
import json
|
|
|
|
from analyze_extrap import FAMILY, FLAT, fam_sum, h2h, load, sign_p
|
|
|
|
|
|
def main():
|
|
rows = load("sweep_flat.json")
|
|
cha = {r["label"]: r for r in load("sweep_full.json")}["chandrupatla"]
|
|
cell = {}
|
|
for r in rows:
|
|
s = r["spec"]
|
|
cell[(s[1], s[3], s[9], s[5])] = r
|
|
print("tent, 3-point, pairs (no gate -> flat gate) APS CHA both flat fun3-6")
|
|
for gu in ("none", "step", "bracket", "both", "project", "safe", "credit"):
|
|
for ext in ("none", "pattern"):
|
|
a, b = cell[("ratio", gu, ext, "none")], cell[("ratio", gu, ext, "flat")]
|
|
print(f" {gu:<8} {'+G2' if ext == 'pattern' else ' '} "
|
|
f"{a['APS']['total']:5d}->{b['APS']['total']:<5d} {a['CHA']['total']:5d}->"
|
|
f"{b['CHA']['total']:<5d} {a['APS']['total'] + a['CHA']['total']:5d}->"
|
|
f"{b['APS']['total'] + b['CHA']['total']:<5d} {fam_sum(a, FLAT):5d}->"
|
|
f"{fam_sum(b, FLAT):<5d} solved {b['APS']['solved'] + b['CHA']['solved']} "
|
|
f"over {b['APS']['over'] + b['CHA']['over']}")
|
|
print("\nVERDICTS")
|
|
for ext, name in (("none", "proposed rule"), ("pattern", "proposed rule + G2")):
|
|
a, b = cell[("ratio", "project", ext, "none")], cell[("ratio", "project", ext, "flat")]
|
|
fam = [r for k, r in cell.items() if k[3] == "flat" and k[1] in FAMILY]
|
|
viol = sum(r["APS"]["over"] + r["CHA"]["over"] for r in fam)
|
|
low = sum(1 for r in fam if r["APS"]["solved"] + r["CHA"]["solved"] < 193)
|
|
z1 = b["CHA"]["total"] < a["CHA"]["total"]
|
|
z2 = b["APS"]["total"] <= a["APS"]["total"]
|
|
z3 = viol == 0 and low == 0
|
|
z4 = fam_sum(b, FLAT) < fam_sum(a, FLAT)
|
|
w, t, l = h2h(b, cha, "APS")
|
|
print(f" {name:<20} APS {a['APS']['total']}->{b['APS']['total']} (Z2 {'✓' if z2 else '✗'}) "
|
|
f"CHA {a['CHA']['total']}->{b['CHA']['total']} (Z1 {'✓' if z1 else '✗'}) "
|
|
f"Z3 {'✓' if z3 else '✗'} ({viol} viol, {low} cells <193) Z4 {'✓' if z4 else '✗'} "
|
|
f"both {b['APS']['total'] + b['CHA']['total']} vs Chandrupatla APS {w}/{t}/{l} "
|
|
f"p={sign_p(w, l):.2g}" + (" ACCEPTED" if z1 and z2 and z3 else " not accepted"))
|
|
print("\nnine functions, projection, no gate -> flat gate, both sets:")
|
|
for sim in sorted({k[0] for k in cell}):
|
|
a, b = cell[(sim, "project", "none", "none")], cell[(sim, "project", "none", "flat")]
|
|
print(f" {sim:<11} {a['APS']['total'] + a['CHA']['total']:6d} -> "
|
|
f"{b['APS']['total'] + b['CHA']['total']:6d}")
|
|
|
|
|
|
if __name__ == "__main__":
|
|
main()
|