FRCMPID_R8_LANE_C1_STATIONARY_BOUNDARY_MAPPING_v1_1_FINAL_RUN_APPROVED.ipynb
FRCMΠD — R8 Lane C.1 Stationary-Boundary Mapping v1.1 — Final Numbered Copy Guide
FINAL AUDIT-CORRECTED / PREFLIGHT VALIDATED / RESEARCHER-RUN APPROVED / NOT EXPERIMENTALLY EXECUTED.
https://colab.research.google.com/drive/1xZsJn2wUjInjSpfH3NWc2SMjjDMy25uZ#scrollTo=5rnwhDsBX1jI
Published on
11/11/26 6:43 AM
Notebook: FRCMPID_R8_LANE_C1_STATIONARY_BOUNDARY_MAPPING_v1_1_FINAL_RUN_APPROVED.ipynb
Important: Run the numbered cells in order. Only Cell 17 begins NEW R8 recurrence trajectories.
Audit fixes: unified direct/reduced q, pointwise exact trace-zero lemma, per-track tolerance, single shared helpers, stationary-branch roundoff guard, added conserved-C precision comparisons, complete handoff list, and corrected representation claim.
Math proves math, not reality. Exact stationary states are not automatically open basins. No physical ontology is inferred from this experiment.
CELL 01 — MARKDOWN — SCOPE, NAME, EXECUTION BOUNDARY
### CELL 01 — MARKDOWN — SCOPE, NAME, EXECUTION BOUNDARY
# FRCMΠD — R8 Lane C.1: Stationary-Boundary Mapping v1.1 — Final Audit-Corrected
**STATUS: FINAL AUDIT-CORRECTED DESIGN / PREFLIGHT-VALIDATED / APPROVED FOR RESEARCHER COLAB RUN / NOT YET EXPERIMENTALLY EXECUTED.**
**Notebook name:** `FRCMPID_R8_LANE_C1_STATIONARY_BOUNDARY_MAPPING_v1_1_FINAL_RUN_APPROVED.ipynb`.
This is the **audit-corrected v1.1** Lane C.1 experiment, separate from the successful Lane C v1.0 small-perturbation study. It explores a **one-dimensional, exact-decimal path** from the frozen R8 baseline toward the stationary state at \(\epsilon=0.5\), with dense sampling around another *exact* stationary point at \(\epsilon=0.07\).
**Question:** Which nearby nonstationary states exhibit candidate logarithmic scaling near 5 and \(Y/X\) near 1/2? Do the exact stationary points isolate other regimes? What changes on either side?
**No extra files required to run.** The original `results.json` is **optional** for a historical baseline comparison; original `per_index_full_states.jsonl` is not required. The original R8 source is not imported or modified.
**Only Cell 17 executes new R8 trajectories.** Cells 01–16 perform setup, symbolic/rational checks, and preflight; Cells 18–25 summarize, export, and optionally request individual downloads. The researcher decides when to execute Cell 17.
*THE MATH PROVES THE MATH, NOT REALITY.* The saturated-core hypothesis motivates exploration; nothing in this notebook certifies a physical mechanism.
CELL 02 — MARKDOWN — TWO DISTINCT EXACT STATIONARY ROOTS
### CELL 02 — MARKDOWN — TWO DISTINCT EXACT STATIONARY ROOTS
With the original \(G_0\) unchanged, define the path
\[
P_0(\epsilon)=\begin{pmatrix}2-\epsilon&\frac12-\epsilon\\-\frac12+\epsilon&1+\epsilon\end{pmatrix},\quad
b_0(\epsilon)=\begin{pmatrix}\frac32+\epsilon&\frac25+\epsilon\\-\frac3{10}-\epsilon&\frac45-\epsilon\end{pmatrix}.
\]
The frozen recurrence is unchanged. The initial matrix \(G_0\) remains SPD, \(\operatorname{tr}G_0=7/2\), \(\operatorname{tr}P_0=3\), and \(b_0+P_0\) remains exactly constant along this path.
The **exact rational identities** derived from the original 2×2 formula are
\[
a_0(\epsilon)=\frac{(1-2\epsilon)(7-100\epsilon)}{44},\qquad
Z_0(\epsilon)=\frac54(1-2\epsilon).
\]
Consequences:
- **\(\epsilon=7/100=0.07\):** \(a_0=0\), \(Z_0=43/40=1.075\). The frozen R8 update is the identity even though \(Z\ne0\).
- **\(\epsilon=1/2=0.5\):** \(a_0=0\), \(Z_0=0\). The frozen update is also the identity; \(Y=\log_{10}|Z|\) is *undefined*.
Both are **exact stationary initial states**, not necessarily open attracting basins. Nearby points must be investigated rather than assumed to behave similarly.
**Numerical safeguard:** decimal `0.07` is not an exactly representable binary fraction. The notebook derives stationarity using Python rational arithmetic and applies the *exact zero-update branch* at these certified states; it never interprets a tiny floating-point residue as motion.
CELL 03 — CODE — IMPORTS, FROZEN INPUTS, NEW EXPERIMENT SETTINGS
# CELL 03 — CODE — IMPORTS, FROZEN INPUTS, NEW EXPERIMENT SETTINGS
from __future__ import annotations
from pathlib import Path
from fractions import Fraction as Fr
from dataclasses import dataclass
from datetime import datetime, timezone
import csv, hashlib, json, os, traceback
import mpmath as mp
# Configurable experiment settings; not physical parameters.
LAST_UPDATE_N = 12 # n=0,...,12
DPS_TRACKS = (480, 960)
DIRECT_N0_MATRIX_AUDIT = True
PRINT_EACH_TRANSITION = False # True for detailed, longer console output
SELECT_CANDIDATE_IDS = None # None => entire path
INCLUDE_BEYOND_050 = False # Optional later extension beyond epsilon=0.5
LAMBDA_R8, MU_R8, TAU_R8 = '0.5', '0.5', '0.1' # FROZEN
EXPERIMENT_ID = 'FRCMPID_R8_LANE_C1_STATIONARY_BOUNDARY_MAPPING_v1_1'
BASE = Path('/content') if Path('/content').is_dir() else Path.cwd()
RESULTS_PATH = BASE / 'results.json' # OPTIONAL only
EXPECTED_RUN_ID = '20261109T031335059891Z'
EXPECTED_VERSION = 'FRCMPID_R8_INDEPENDENT_COMPLEX_TRANSPORT_V2_1_FINAL'
EXPECTED_RESULTS_SHA256 = 'be9c4a2e8ab874cfeb9113127115e6157f9efb4a28120ef1d813d62e9e7af2e0'
FROZEN = {
'G': [['2','0.5'],['0.5','1.5']],
'b': [['1.5','0.4'],['-0.3','0.8']],
'P': [['2','0.5'],['-0.5','1']],
'lambda':LAMBDA_R8, 'mu':MU_R8, 'tau':TAU_R8,
}
assert (LAMBDA_R8,MU_R8,TAU_R8)==('0.5','0.5','0.1')
assert len(set(DPS_TRACKS))==len(DPS_TRACKS) and all(x>=120 for x in DPS_TRACKS)
assert isinstance(LAST_UPDATE_N,int) and LAST_UPDATE_N>=0
print('R8 LANE C.1:',EXPERIMENT_ID)
print('Working location:', BASE)
print('Planned n=0..', LAST_UPDATE_N, '| dps=',DPS_TRACKS)
print('No new recurrence has been executed.')
CELL 04 — MARKDOWN — FROZEN R8 RECURRENCE AND REPRESENTATION
### CELL 04 — MARKDOWN — FROZEN R8 RECURRENCE AND REPRESENTATION
Frozen R8 definitions, **not modified by the path parameter** \(\epsilon\):
\[
B=P-G^{-1}P^TG,\quad S=B+B^T,\quad a=\mathrm{tr}[(b-P)B],\quad c=\tau a,
\]
\[
\rho=\rho(G^{-1}S)\ge0,\quad v=|c|\rho,\quad q=c/(1+v),
\]
\[
G'=G-qS,\qquad b'=b-\lambda aB,\qquad P'=P+\mu aB,
\quad\lambda=\mu=1/2,\ \tau=1/10.
\]
**Trace-zero lemma (pointwise, not an unproved dynamical assumption).** For every real symmetric invertible \(G\), put \(B=P-G^{-1}P^T G\), \(S=B+B^T\), and \(H=G^{-1}\). Since \(H^T=H\), cyclicity of trace and transpose symmetry give
\[
\operatorname{tr}(HB)=\operatorname{tr}(HP)-\operatorname{tr}(H^2P^TG)
=\operatorname{tr}(HP)-\operatorname{tr}(HP^T)=0,
\]
because \(\operatorname{tr}(HP)=\operatorname{tr}(HP^T)\). Likewise,
\[
\operatorname{tr}(HB^T)=\operatorname{tr}(BH)
=\operatorname{tr}(HB)=0.
\]
Thus \(\operatorname{tr}(G^{-1}S)=0\) **for every admissible state**, without invoking an invariant-preservation argument. Since \(G\) is SPD and \(S=S^T\), the generalized eigenvalues of \((S,G)\) are real and sum to zero; they are \(\pm\rho\) for \(\rho\ge0\). Therefore the direct-matrix and reduced definitions must use the **same** rule \(q=c/(1+|c|\rho)\); the direct comparator additionally checks the numerical trace-zero residual.
The exact determinant ratio is \(d'/d=(1+2v)/(1+v)^2>0\), for finite \(v\ge0\). No determinant floor or clipping is used.
**Exact identity branch:** If rational arithmetic certifies \(a_0=0\), then the exact recurrence has \(c=q=0\) and \(G'=G,b'=b,P'=P\). The identity then repeats by induction for all finite steps: after the first step the entire state is unchanged, hence the same exact zero-mismatch certificate applies again. The notebook records these analytic identity steps separately from ordinary numerical transport steps. It does **not** impose this branch on merely *small* nonzero values of \(a\).
Reduced transport requires symmetric \(G\succ0\) and \(r^2=T^2/4-d>0\). Failure of the reduced direction parameterization is not automatically a failure of the matrix recurrence.
CELL 05 — CODE — OPTIONAL HISTORICAL REFERENCE — NEVER A VETO
# CELL 05 — CODE — OPTIONAL HISTORICAL REFERENCE — NEVER A VETO
def sha256_file(path):
h=hashlib.sha256()
with path.open('rb') as f:
for block in iter(lambda:f.read(1024*1024),b''):
h.update(block)
return h.hexdigest()
reference_status='NOT_SUPPLIED_OPTIONAL'
reference_actual_sha=None
raw_saved={}
if RESULTS_PATH.is_file():
reference_actual_sha=sha256_file(RESULTS_PATH)
if reference_actual_sha!=EXPECTED_RESULTS_SHA256:
reference_status='HASH_DIFFERS_COMPARISON_DISABLED'
else:
try:
ref=json.loads(RESULTS_PATH.read_text(encoding='utf-8'))
if (ref.get('run_id')!=EXPECTED_RUN_ID or ref.get('version')!=EXPECTED_VERSION
or ref.get('frozen_decimal_inputs')!=FROZEN):
reference_status='PINNED_SCHEMA_DIFFERENT_COMPARISON_DISABLED'
else:
rows=ref['raw_observations']
slots={(int(r['dps']),int(r['n'])):r for r in rows}
if len(slots)!=len(rows):
reference_status='DUPLICATE_SLOTS_COMPARISON_DISABLED'
else:
raw_saved=slots
reference_status='PINNED_REFERENCE_AVAILABLE'
except Exception as exc:
reference_status='REFERENCE_PARSE_UNRESOLVED_'+type(exc).__name__
print('Historical reference:',reference_status)
print('Usable saved slots:',len(raw_saved))
print('Only read historical data; no numerical recurrence executed.')
CELL 06 — MARKDOWN — SAMPLED PATH — NOT A PROVEN BASIN BOUNDARY
### CELL 06 — MARKDOWN — SAMPLED PATH — NOT A PROVEN BASIN BOUNDARY
The path is **one selected line through the admissible initial-condition domain**. Sampling it cannot by itself establish the full geometry of any basin of attraction; the exact stationary points do not imply open stationary neighborhoods.
Default sample values (20 cases):
`0, .02, .05, .06, .065, .069, .0699, .07, .0701, .071, .075, .08, .1, .2, .3, .4, .45, .49, .4999, .5`.
These include points **on both sides of \(0.07\)** and points **approaching \(0.5\)** from below. The exact stationary cases are separate, explicit categories. If later desired, set `INCLUDE_BEYOND_050=True` to include `0.5001, 0.51, 0.55`; those are disabled by default and do not change any recurrence coefficients.
**Controlled invariants along the entire path:** \(G_0\) is unchanged and SPD with \(d_0=11/4\); \(\operatorname{tr}P=3\); \(b+P\) is the original constant matrix. This is not a parameter sweep of \(\lambda,\mu,\tau\).
The study should record exact stationary identities, finite-scale ratios, missing/undefined logarithms, numerical disagreement, departures, and unexpected regimes without forcing a 5-regime classification.
CELL 07 — CODE — EXACT RATIONAL INITIAL-STATE CERTIFICATES AND PATH INVENTORY
# CELL 07 — CODE — EXACT RATIONAL INITIAL-STATE CERTIFICATES AND PATH INVENTORY
# Exact, independent 2x2 rational arithmetic — no mpmath rounding.
def fm(rows): return [[Fr(str(x)) for x in row] for row in rows]
def fadd(A,B): return [[A[i][j]+B[i][j] for j in range(2)] for i in range(2)]
def fsub(A,B): return [[A[i][j]-B[i][j] for j in range(2)] for i in range(2)]
def fmul(A,B): return [[sum(A[i][k]*B[k][j] for k in range(2)) for j in range(2)] for i in range(2)]
def ft(A): return [[A[j][i] for j in range(2)] for i in range(2)]
def fdet(A): return A[0][0]*A[1][1]-A[0][1]*A[1][0]
def finv(A):
d=fdet(A)
if d==0: raise ZeroDivisionError('Fractional G is not invertible')
return [[A[1][1]/d,-A[0][1]/d],[-A[1][0]/d,A[0][0]/d]]
def ftrace(A): return A[0][0]+A[1][1]
F_G0,F_B0,F_P0=fm(FROZEN['G']),fm(FROZEN['b']),fm(FROZEN['P'])
F_C0=fadd(F_B0,F_P0)
def path_rational(epsilon):
e=Fr(epsilon)
G=[row[:] for row in F_G0]
P=[[Fr(2)-e,Fr(1,2)-e],[-Fr(1,2)+e,Fr(1)+e]]
b=[[Fr(3,2)+e,Fr(2,5)+e],[-Fr(3,10)-e,Fr(4,5)-e]]
return G,b,P
def certify_initial(epsilon):
e=Fr(epsilon)
G,b,P=path_rational(e)
B=fsub(P,fmul(fmul(finv(G),ft(P)),G))
a=ftrace(fmul(fsub(b,P),B))
Z=fsub(fmul(G,P),fmul(ft(P),G))[0][1]
formula_a=(1-2*e)*(7-100*e)/44
formula_Z=Fr(5,4)*(1-2*e)
assert (a,Z)==(formula_a,formula_Z), 'EXACT initial identities fail'
assert G==F_G0 and fdet(G)==Fr(11,4)
assert ftrace(G)==Fr(7,2) and ftrace(P)==3 and fadd(b,P)==F_C0
assert G[0][0]>0 and fdet(G)>0
return {'epsilon':str(epsilon),'a_fraction':str(a),'Z_fraction':str(Z),
'is_exact_stationary':a==0,'is_exact_Z_zero':Z==0,
'stationary_reason':'A0_EXACT_ZERO_RATIONAL' if a==0 else 'NONSTATIONARY_INITIAL'}
EPSILON_VALUES=['0','0.02','0.05','0.06','0.065','0.069','0.0699','0.07',
'0.0701','0.071','0.075','0.08','0.1','0.2','0.3','0.4',
'0.45','0.49','0.4999','0.5']
if INCLUDE_BEYOND_050: EPSILON_VALUES+=['0.5001','0.51','0.55']
assert len(EPSILON_VALUES)==len(set(EPSILON_VALUES))
CANDIDATES=[]
for s in EPSILON_VALUES:
e=Fr(s)
units=e*10000
assert units.denominator==1, 'Use a <=4-decimal place epsilon ID'
record=certify_initial(s)
record.update({'id':f'PATH_E_{int(units):04d}', 'family':'B_P_OPPOSITE_PATH',
'initial_d':'2.75', 'epsilon':s})
CANDIDATES.append(record)
if SELECT_CANDIDATE_IDS is None:
selected_specs=list(CANDIDATES)
else:
wanted=set(SELECT_CANDIDATE_IDS)
if wanted-set(c['id'] for c in CANDIDATES):
raise ValueError('Unknown selected candidate ID')
selected_specs=[c for c in CANDIDATES if c['id'] in wanted]
if not selected_specs: raise ValueError('Empty candidate selection')
assert len(set(s['id'] for s in selected_specs))==len(selected_specs)
# Numerical initial states are derived only from the frozen decimal specification.
def original_matrix(rows):
return mp.matrix([[mp.mpf(x) for x in row] for row in rows])
def matrix_from_spec(spec):
e=mp.mpf(spec['epsilon'])
G=original_matrix(FROZEN['G'])
P=mp.matrix([[mp.mpf('2')-e,mp.mpf('0.5')-e],
[-mp.mpf('0.5')+e,mp.mpf('1')+e]])
b=mp.matrix([[mp.mpf('1.5')+e,mp.mpf('0.4')+e],
[-mp.mpf('0.3')-e,mp.mpf('0.8')-e]])
return G,b,P
def tr2(M): return M[0,0]+M[1,1]
def det2(M): return M[0,0]*M[1,1]-M[0,1]*M[1,0]
def max_matrix_diff(A,B): return max(abs(A[i,j]-B[i,j]) for i in range(2) for j in range(2))
for dps in DPS_TRACKS:
with mp.workdps(dps):
for spec in selected_specs:
G,b,P=matrix_from_spec(spec)
assert G[0,1]==G[1,0] and G[0,0]>0 and det2(G)>0
assert tr2(G)==mp.mpf('3.5') and tr2(P)==mp.mpf('3')
# Compare within a tolerance derived from THIS precision track.
# The exact invariant is separately certified above by Fraction arithmetic.
C0=original_matrix(FROZEN['b'])+original_matrix(FROZEN['P'])
scale=max([mp.mpf(1)]+[abs(C0[i,j]) for i in range(2) for j in range(2)])
tol_C=mp.mpf(512)*mp.eps*scale
if max_matrix_diff(b+P,C0)>tol_C:
raise ArithmeticError(f'INITIAL_C_NUMERICAL_DRIFT_{spec["id"]}_DPS_{dps}')
print('EXACT rational candidates certified:',len(selected_specs))
print('Two exact stationary epsilons on default path: 0.07 (Z!=0), 0.5 (Z=0).')
for s in selected_specs:
print(f"{s['id']:<13} eps={s['epsilon']:<7} a0={s['a_fraction']:<15} Z0={s['Z_fraction']:<10} {s['stationary_reason']}")
print('No R8 successor states computed.')
CELL 08 — MARKDOWN — REDUCED TRANSPORT, PRECISION, AND EXACT-ROOT SAFEGUARDS
### CELL 08 — MARKDOWN — REDUCED TRANSPORT, PRECISION, AND EXACT-ROOT SAFEGUARDS
A **separately written numerical implementation of the documented v2.1 reduced complex transport equations** is used; historical source is not executed. Agreement with one direct n=0 matrix step is a consistency test, not independent source-to-execution certification. Let \(T=\operatorname{tr}G\), \(d=\det G\), \(r^2=T^2/4-d\), \(u=(x+ih)/r\) with \(x=(G_{00}-G_{11})/2\), \(h=G_{01}\), and \(Q=Z+iW\).
For nonstationary cases:
\[
w=Z/d,\qquad a=w(F+2Z),\qquad \rho=2|w|r/\sqrt d,\qquad v=|\tau a|\rho,
\]
with \(d'=d(1+2v)/(1+v)^2\) evaluated as **positive factors**, avoiding the dangerous \(1-q\rho\) subtraction.
**Special exact-zero policy:** Only where the independent rational certificate shows \(a_0=0\) is the mathematically exact identity applied explicitly. We **never** clip small nonzero \(a\), never replace a small positive determinant by a floor, and never turn an undefined logarithm into zero. Report identity steps distinctly from numerical reduced updates.
`mpmath` can represent exponents far below \(-480\); significant-digit cancellation, not a small exponent by itself, is the numerical concern. Use 480 and 960 dps tracks and compare saved high-precision *states*, not just rounded CSV displays.
CELL 09 — CODE — REDUCED STATE, RECONSTRUCTION, FULL-PRECISION SERIALIZATION
# CELL 09 — CODE — REDUCED STATE, RECONSTRUCTION, FULL-PRECISION SERIALIZATION
@dataclass(frozen=True)
class R8Reduced:
T: object
d: object
direction: object # mpc, |direction|=1 numerically
A: object
Q: object # mpc, real=Z, imag=W
C: tuple # b+P, row-major
p: object # tr(P)/2
def reduced_from_matrix(G,b,P):
T=tr2(G); d=det2(G)
if not (G[0,1]==G[1,0] and G[0,0]>0 and d>0 and T>0):
raise ArithmeticError('INITIAL_G_NOT_SPD')
x=(G[0,0]-G[1,1])/2
h=G[0,1]
r2=x*x+h*h
if not (r2>0): raise ArithmeticError('INITIAL_R2_ZERO_REPRESENTATION_LIMIT')
r=mp.sqrt(r2)
Z=G[0,0]*P[0,1]-G[1,1]*P[1,0]+h*(P[1,1]-P[0,0])
W=x*(P[0,0]-P[1,1])+h*(P[0,1]+P[1,0])
A=(P[0,1]-P[1,0])/2
C=b+P
return R8Reduced(T,d,mp.mpc(x,h)/r,A,mp.mpc(Z,W),
tuple(C[i,j] for i in range(2) for j in range(2)),tr2(P)/2)
def reconstruct_matrix(st):
r2=st.T*st.T/4-st.d
if not (r2>0): raise ArithmeticError('RECONSTRUCTION_R2_UNAVAILABLE')
r=mp.sqrt(r2)
x,h=r*st.direction.real,r*st.direction.imag
G=mp.matrix([[st.T/2+x,h],[h,st.T/2-x]])
# Z = 2*x*s - 2*h*t + T*A; W = 2*h*s + 2*x*t
k1=(st.Q.real-st.T*st.A)/2
k2=st.Q.imag/2
s=(x*k1+h*k2)/r2
t=(-h*k1+x*k2)/r2
P=mp.matrix([[st.p+t,s+st.A],[s-st.A,st.p-t]])
b=mp.matrix([[st.C[0],st.C[1]],[st.C[2],st.C[3]]])-P
return G,b,P
def state_strings(st,dps):
digits=dps+12
asstr=lambda val:mp.nstr(val,digits)
return {'T':asstr(st.T),'d':asstr(st.d),
'direction':[asstr(st.direction.real),asstr(st.direction.imag)],
'A':asstr(st.A),'Q':[asstr(st.Q.real),asstr(st.Q.imag)],
'C':[asstr(v) for v in st.C], 'p':asstr(st.p), 'dps':int(dps)}
def finite_all(*xs): return all(mp.isfinite(x) for x in xs)
CELL 10 — CODE — FROZEN REDUCED R8 STEP + EXACT STATIONARY IDENTITY BRANCH
# CELL 10 — CODE — FROZEN REDUCED R8 STEP + EXACT STATIONARY IDENTITY BRANCH
def r8_reduced_step(st):
# The researcher invokes this only via the separate execution cell below.
T,d,A,C,p=st.T,st.d,st.A,st.C,st.p
if not (finite_all(T,d) and T>0 and d>0):
raise ArithmeticError('NONFINITE_OR_NONPOSITIVE_PREDETERMINANT')
r2=T*T/4-d
if not (r2>0 and finite_all(r2)):
raise ArithmeticError('REDUCED_POLAR_R2_UNAVAILABLE')
r=mp.sqrt(r2)
u=st.direction
if not finite_all(u.real,u.imag,st.Q.real,st.Q.imag,st.A,*C):
raise ArithmeticError('NONFINITE_REDUCED_STATE')
x,h=r*u.real,r*u.imag
g,k=T/2+x,T/2-x
Z,W=st.Q.real,st.Q.imag
w=Z/d
F=h*(C[0]-C[3])-g*C[1]+k*C[2]
a=w*(F+2*Z)
c=mp.mpf(TAU_R8)*a
rho=2*abs(w)*r/mp.sqrt(d)
v=abs(c)*rho
if not (finite_all(a,c,rho,v) and rho>=0 and v>=0):
raise ArithmeticError('NONFINITE_OR_NEGATIVE_UPDATE_CONTROL')
margin=1/(1+v)
second=(1+2*v)/(1+v)
d_next=d*margin*second # always use positive factors; no 1-q*rho cancellation
q=c/(1+v)
omega=2*q*w
alpha=mp.mpf(MU_R8)*a*w
rotation=mp.mpc(1,omega)
direction_pre=u*rotation/mp.sqrt(1+omega*omega)
direction_length=mp.sqrt(direction_pre.real**2+direction_pre.imag**2)
if not (direction_length>0 and finite_all(direction_length)):
raise ArithmeticError('DIRECTION_RENORMALIZATION_UNAVAILABLE')
direction_next=direction_pre/direction_length
A_next=A+alpha*T/2
Q_next=rotation*st.Q+2*alpha*d-mp.mpc(0,omega*T*A+2*alpha*omega*r2)
if not finite_all(d_next,q,omega,alpha,A_next,Q_next.real,Q_next.imag):
raise ArithmeticError('NONFINITE_NEXT_REDUCED_STATE')
if not (d_next>0 and d_nextroot_tolerance:
raise ArithmeticError('CERTIFIED_STATIONARY_STATE_FLOATING_REPRESENTATION_INCONSISTENT')
# Induction: unchanged state reproduces a=0 at every subsequent index.
# Exact recurrence consequence: c=q=omega=alpha=v=0, successor=predecessor.
z=mp.mpf(0)
obs={'a':z,'F':F,'Z':Z,'W':W,'c':z,'rho':2*abs(w)*r/mp.sqrt(d),
'v':z,'q':z,'omega':z,'alpha':z,'r':r,'r2':r2,
'd_next':d,'direction_norm_pre':mp.mpf(1),
'z_next':Z,'d_ratio':mp.mpf(1),
'update_kind':'EXACT_RATIONAL_IDENTITY'}
return st,obs
def certified_r8_step(st,spec):
if spec['is_exact_stationary']:
return exact_stationary_identity_step(st,spec)
nxt,obs=r8_reduced_step(st)
obs['update_kind']='NUMERICAL_REDUCED_TRANSPORT'
return nxt,obs
CELL 11 — MARKDOWN — DIRECT-MATRIX CHECK — HANDLING THE EXACT ROOTS
### CELL 11 — MARKDOWN — DIRECT-MATRIX CHECK — HANDLING THE EXACT ROOTS
For every candidate and precision, a literal 2×2 matrix calculation at n=0 provides an **observational comparator** to the reduced representation.
For \(\epsilon=0.07\), direct `mpmath` arithmetic can produce an extremely tiny nonzero residual from the rational exact zero. The exact **Fraction** certificate has priority for the *mathematical zero assertion*, while direct arithmetic remains diagnostic. We do **not** report relative error versus zero as though it calibrated an unstable division.
For all candidates, the direct comparator uses the same \(q=c/(1+|c|\rho)\) definition as the reduced engine and checks \(\operatorname{tr}(G^{-1}S)\) against the current precision. For other candidates, report direct/reduced differences as before. Direct checks do not overwrite successfully evolved reduced states or silently hide disagreements.
CELL 12 — CODE — DIRECT N=0 MATRIX FORMULAS AND SAFE COMPARISON
# CELL 12 — CODE — DIRECT N=0 MATRIX FORMULAS AND SAFE COMPARISON
def direct_one_step(G,b,P):
if G[0,1]!=G[1,0] or G[0,0]<=0 or det2(G)<=0:
raise ArithmeticError('DIRECT_INITIAL_G_NOT_SPD')
B=P-(G**-1)*P.T*G
S=B+B.T
a=tr2((b-P)*B)
M=(G**-1)*S
tM=tr2(M)
# Pointwise lemma: trace(G^-1 S)=0 exactly. Allow only rounding-scale drift.
Mscale=max([mp.mpf(1)]+[abs(M[i,j]) for i in range(2) for j in range(2)])
if abs(tM)>mp.mpf(1024)*mp.eps*Mscale:
raise ArithmeticError('DIRECT_TRACE_ZERO_LEMMA_NUMERICALLY_UNRESOLVED')
disc=(M[0,0]-M[1,1])**2+4*M[0,1]*M[1,0]
if disc<0: raise ArithmeticError('DIRECT_DISCRIMINANT_NEGATIVE')
rho=mp.sqrt(disc)/2 # generalized eigenvalue magnitude, ±rho in exact algebra
if rho<0: raise ArithmeticError('DIRECT_EIGEN_SIGN_UNRESOLVED')
c=mp.mpf(TAU_R8)*a
q=c/(1+abs(c)*rho) # EXACTLY the same q rule as the reduced transport
G1=G-q*S
b1=b-mp.mpf(LAMBDA_R8)*a*B
P1=P+mp.mpf(MU_R8)*a*B
return (G1,b1,P1),{'a':a,'d_next':det2(G1),
'C_drift':max_matrix_diff(b1+P1,b+P),
'trG_drift':tr2(G1)-tr2(G),
'generalized_trace_zero_residual':tM}
# Shared presentation and comparison helpers are defined exactly once in CELL 14.
# Direct-matrix calculation here does not depend on them.
CELL 13 — MARKDOWN — DIAGNOSTICS, UNDEFINED VALUES, AND NONFORCED CLASSIFICATION
### CELL 13 — MARKDOWN — DIAGNOSTICS, UNDEFINED VALUES, AND NONFORCED CLASSIFICATION
Record for each update: \(X_n=-\log_{10}d_n\), \(Y_n=\log_{10}|Z_n|\), \(\log_{10}|a_n|\), \(\log_{10}v_n\), successor magnitudes, scaling ratios when defined, and the exact/leading-order correction diagnostics.
**Three distinct outputs must not be conflated:**
- `NUMERICAL_REDUCED_TRANSPORT` — ordinary R8 computation at a nonstationary initial state.
- `EXACT_RATIONAL_IDENTITY` — proved identity step of the frozen recurrence; it is **not evidence of an open dead basin**.
- `UNRESOLVED` — a numerical, representation, serialization, or comparison issue, with its own reason.
At \(Z=0\), write `Y_STATUS=UNDEFINED_Z_ZERO`; never store `0` or a fabricated finite value for \(Y\). At certified exact stationary points, **do not** evaluate a nonstationary leading-order approximation as if its small-correction assumptions held. Output separate `NOT_APPLICABLE_EXACT_IDENTITY` statuses.
The scaling matrix \(M=\begin{pmatrix}7/2&3\\1&3\end{pmatrix}\) has eigenvalues 5 and 3/2; that exact statement does not assert every admissible initial state enters its dominant regime.
CELL 14 — CODE — PER-INDEX DIAGNOSTICS AND SERIALIZATION HELPERS
# CELL 14 — CODE — PER-INDEX DIAGNOSTICS AND SERIALIZATION HELPERS
def nformat(val,digits=25):
return 'UNDEFINED' if val is None else mp.nstr(val,digits)
def safe_log10_abs(val):
return None if val==0 else mp.log10(abs(val))
def sym_rel_difference(x,y):
scale=max(abs(x),abs(y))
return mp.mpf(0) if scale==0 else abs(x-y)/scale
def diagnostic_row(spec,dps,n,st,nxt,obs):
X=-mp.log10(st.d); X_next=-mp.log10(nxt.d)
Y=safe_log10_abs(obs['Z']); Y_next=safe_log10_abs(nxt.Q.real)
a=obs['a']; v=obs['v']; Z=obs['Z']
row={'id':spec['id'],'epsilon':spec['epsilon'],'dps':dps,'n':n,
'status':'COMPUTED_EXPLORATORY_UNCERTIFIED',
'update_kind':obs['update_kind'],
'Y_status':'DEFINED' if Y is not None else 'UNDEFINED_Z_ZERO',
'Y_next_status':'DEFINED' if Y_next is not None else 'UNDEFINED_Z_ZERO',
'log10_d':mp.nstr(mp.log10(st.d),36),
'X_n':mp.nstr(X,36),'Y_n':nformat(Y,36) if Y is not None else '',
'X_next':mp.nstr(X_next,36),'Y_next':nformat(Y_next,36) if Y_next is not None else '',
'X_growth':mp.nstr(X_next/X,36) if X!=0 else '',
'Y_growth':mp.nstr(Y_next/Y,36) if Y is not None and Y!=0 and Y_next is not None else '',
'post_Y_over_X':mp.nstr(Y_next/X_next,36) if Y_next is not None and X_next!=0 else '',
'log10_abs_a':nformat(safe_log10_abs(a),36) if a!=0 else '',
'log10_v':nformat(safe_log10_abs(v),36) if v!=0 else '',
'direction_norm_error':mp.nstr(abs(obs['direction_norm_pre']-1),30),
'z_correction_status':'','log10_z_correction_over_lead':'',
'd_lead_status':'','log10_d_exact_over_leading':'',
'diagnostic_error':''}
if obs['update_kind']=='EXACT_RATIONAL_IDENTITY':
row['z_correction_status']='NOT_APPLICABLE_EXACT_IDENTITY'
row['d_lead_status']='NOT_APPLICABLE_EXACT_IDENTITY'
return row
F,W,omega=obs['F'],obs['W'],obs['omega']
z_lead=2*Z**3/st.d
corr_terms=(F*Z**2/st.d,Z,-omega*W)
z_corr=sum(corr_terms)
if z_lead==0:
row['z_correction_status']='UNDEFINED_LEADING_ZERO'
elif z_corr==0 and any(t!=0 for t in corr_terms):
row['z_correction_status']='UNRESOLVED_AT_WORKING_PRECISION'
elif z_corr==0:
row['z_correction_status']='ZERO_TERMS_AT_WORKING_PRECISION'
else:
row['z_correction_status']='FINITE_NONZERO'
row['log10_z_correction_over_lead']=mp.nstr(mp.log10(abs(z_corr))-mp.log10(abs(z_lead)),36)
if v>0 and Z!=0 and F+2*Z!=0:
geom=st.T*abs(Z)/(obs['r']*abs(F+2*Z))
finite=v*(1+2*v)/(2*(1+v)**2)
row['log10_d_exact_over_leading']=mp.nstr(mp.log10(geom)+mp.log10(finite),36)
row['d_lead_status']='FINITE_RATIO_DIAGNOSTIC'
else:
row['d_lead_status']='UNDEFINED_ZERO_DENOMINATOR'
return row
def write_csv(path,rows,fieldnames=None):
if fieldnames is None: fieldnames=list(rows[0]) if rows else []
with path.open('w',encoding='utf-8',newline='') as f:
w=csv.DictWriter(f,fieldnames=fieldnames,extrasaction='ignore')
w.writeheader(); w.writerows(rows)
def write_json(path,obj):
path.write_text(json.dumps(obj,ensure_ascii=False,sort_keys=True,indent=2)+'\n',encoding='utf-8')
DIAGNOSTIC_COLS=['id','epsilon','dps','n','status','update_kind',
'Y_status','Y_next_status','log10_d','X_n','Y_n','X_next','Y_next','X_growth',
'Y_growth','post_Y_over_X','log10_abs_a','log10_v','direction_norm_error',
'z_correction_status','log10_z_correction_over_lead',
'd_lead_status','log10_d_exact_over_leading','diagnostic_error']
CELL 15 — MARKDOWN — EXPERIMENT BOUNDARY — READ THIS BEFORE EXECUTION
### CELL 15 — MARKDOWN — EXPERIMENT BOUNDARY — READ THIS BEFORE EXECUTION
Up to and including Cell 16, **no new R8 successor states have been evaluated**. The completed preflight will calculate the number of planned candidates, tracks, and attempted update indices.
The very next execution cell — **Cell 17** — starts a NEW Lane C.1 R8 experiment when run by the researcher. At default settings this is **20 candidates × 2 precision tracks × 13 update indices = 520 steps**, of which **52 are analytically certified identity steps** at the two exact stationary candidates; the remaining 468 steps are numerical reduced transport attempts.
Each track has a separate outcome; it never quietly changes a failed case into a successful one. Disk or serialization errors are recorded **separately from recurrence errors**. Original inputs are not overwritten. There is no forced \(5\) classification and no arbitrary physical saturation floor.
This is a new experiment using a draft reimplementation of the documented v2.1 formulas, not an independent source-to-execution certificate. If `results.json` is present and matches the pinned historical file, the epsilon-zero baseline can be compared to saved v2.1 summary fields; otherwise the study proceeds without that optional comparison.
CELL 16 — CODE — FINAL NON-EXECUTING PREFLIGHT
# CELL 16 — CODE — FINAL NON-EXECUTING PREFLIGHT
if (LAMBDA_R8,MU_R8,TAU_R8)!=('0.5','0.5','0.1'):
raise RuntimeError('STOP: frozen R8 coefficients changed')
stationary=[s for s in selected_specs if s['is_exact_stationary']]
for s in stationary:
cert=certify_initial(s['epsilon'])
if cert['a_fraction']!='0': raise RuntimeError('STOP: stationary certificate invalid')
expected_attempts=len(selected_specs)*len(DPS_TRACKS)*(LAST_UPDATE_N+1)
expected_identity=len(stationary)*len(DPS_TRACKS)*(LAST_UPDATE_N+1)
expected_numeric=expected_attempts-expected_identity
# Independent STARTING-STATE preflight only: no successor updates.
# The exact rational stationarity and invariant checks are already in CELL 07.
preflight_roundtrips=0
for dps in DPS_TRACKS:
with mp.workdps(dps):
for spec in selected_specs:
G,b,P=matrix_from_spec(spec)
st=reduced_from_matrix(G,b,P)
G2,b2,P2=reconstruct_matrix(st)
scale=max([mp.mpf(1)]+[abs(G[i,j]) for i in range(2) for j in range(2)]
+[abs(b[i,j]) for i in range(2) for j in range(2)]
+[abs(P[i,j]) for i in range(2) for j in range(2)])
tol=mp.mpf(4096)*mp.eps*scale
if max(max_matrix_diff(G,G2),max_matrix_diff(P,P2),max_matrix_diff(b,b2))>tol:
raise ArithmeticError('INITIAL_RECONSTRUCTION_ROUNDTRIP_FAILED: '+spec['id'])
B=P-(G**-1)*P.T*G
S=B+B.T
M=(G**-1)*S
Mscale=max([mp.mpf(1)]+[abs(M[i,j]) for i in range(2) for j in range(2)])
if abs(tr2(M))>mp.mpf(4096)*mp.eps*Mscale:
raise ArithmeticError('INITIAL_TRACE_ZERO_LEMMA_CHECK_FAILED: '+spec['id'])
preflight_roundtrips+=1
print('PREFLIGHT COMPLETE — NO NEW R8 SUCCESSOR STATES')
print('Initial reduced/full roundtrips and trace-zero checks:',preflight_roundtrips,'PASS')
print('Candidates:',len(selected_specs),'| precision tracks:',DPS_TRACKS)
print('Planned R8 steps:',expected_attempts,'| analytically exact identities:',expected_identity,
'| numerical transport attempts:',expected_numeric)
print('Certified exact stationary cases:',[(s['epsilon'],s['Z_fraction']) for s in stationary])
print('Optional historical comparison:',reference_status)
print('NEXT: CELL 17 IS THE LIVE EXPERIMENT. Proceed only when YOU decide to run it.')
CELL 17 — CODE — RESEARCHER-RUN LANE C.1 EXPERIMENT — NEW R8 SUCCESSOR STATES
# CELL 17 — CODE — RESEARCHER-RUN LANE C.1 EXPERIMENT — NEW R8 SUCCESSOR STATES
# This is the ONLY cell that computes NEW R8 successor trajectories.
run_stamp=datetime.now(timezone.utc).strftime('%Y%m%dT%H%M%S%fZ')
OUT=BASE/(EXPERIMENT_ID+'_'+run_stamp)
OUT.mkdir(parents=True,exist_ok=False)
all_diagnostics=[]; track_outcomes=[]; direct_checks=[]; control_checks=[]; output_events=[]
ledger_path=OUT/'per_index_full_states_lane_c1.jsonl'
with ledger_path.open('w',encoding='utf-8') as ledger:
for spec in selected_specs:
for dps in DPS_TRACKS:
last_success=-1; status='INITIALIZING'; error_text=''; analytic_count=0; numeric_count=0
print('START',spec['id'],'epsilon',spec['epsilon'],'dps',dps,flush=True)
with mp.workdps(dps):
try:
G,b,P=matrix_from_spec(spec)
st=reduced_from_matrix(G,b,P)
try:
ledger.write(json.dumps({'id':spec['id'],'epsilon':spec['epsilon'],
'dps':dps,'n':-1,'state_kind':'INITIAL',
'state':state_strings(st,dps)},ensure_ascii=False)+'\n')
ledger.flush()
except Exception as exc:
output_events.append({'id':spec['id'],'dps':dps,'n':-1,
'stage':'INITIAL_STATE_OUTPUT','error':repr(exc)})
for n in range(LAST_UPDATE_N+1):
previous=st
nxt,obs=certified_r8_step(previous,spec)
# Core R8 successor committed BEFORE diagnosis or disk serialization.
st=nxt; last_success=n
if obs['update_kind']=='EXACT_RATIONAL_IDENTITY': analytic_count+=1
else: numeric_count+=1
try:
ledger.write(json.dumps({'id':spec['id'],'epsilon':spec['epsilon'],
'dps':dps,'n':n,'state_kind':'POST_UPDATE',
'update_kind':obs['update_kind'],
'state':state_strings(st,dps)},ensure_ascii=False)+'\n')
ledger.flush()
except Exception as exc:
output_events.append({'id':spec['id'],'dps':dps,'n':n,
'stage':'POST_UPDATE_STATE_OUTPUT','error':repr(exc)})
try:
all_diagnostics.append(diagnostic_row(spec,dps,n,previous,st,obs))
except Exception as exc:
all_diagnostics.append({'id':spec['id'],'epsilon':spec['epsilon'],
'dps':dps,'n':n,'status':'DIAGNOSTIC_UNRESOLVED_'+type(exc).__name__,
'update_kind':obs['update_kind'],'diagnostic_error':repr(exc)})
# Saved-v2.1 baseline comparison is optional; only for epsilon=0.
if spec['epsilon']=='0':
historical=raw_saved.get((dps,n))
if historical:
try:
control_checks.append({'dps':dps,'n':n,
'comparison_scope':'SAVED_DISPLAY_PRECISION_ONLY',
'rel_a':mp.nstr(sym_rel_difference(obs['a'],mp.mpf(historical['a'])),35),
'rel_d_next':mp.nstr(sym_rel_difference(st.d,mp.mpf(historical['d_next'])),35),
'status':'COMPARED'})
except Exception as exc:
control_checks.append({'dps':dps,'n':n,
'status':'COMPARISON_UNRESOLVED','error':repr(exc)})
if DIRECT_N0_MATRIX_AUDIT and n==0:
try:
(dg,db,dp),direct=direct_one_step(G,b,P)
rg,rb,rp=reconstruct_matrix(st)
record={'id':spec['id'],'epsilon':spec['epsilon'],
'dps':dps,'status':('EXACT_STATIONARY_VS_FINITE_PRECISION_DIRECT'
if spec['is_exact_stationary'] else 'OBSERVATIONAL_COMPUTED'),
'a_direct_log10_abs':nformat(safe_log10_abs(direct['a']),35),
'rel_a':('NOT_APPLICABLE_EXACT_RATIONAL_ZERO'
if spec['is_exact_stationary'] else
mp.nstr(sym_rel_difference(obs['a'],direct['a']),35)),
'rel_d1':mp.nstr(sym_rel_difference(st.d,direct['d_next']),35),
'abs_G1_error':mp.nstr(max_matrix_diff(dg,rg),35),
'abs_P1_error':mp.nstr(max_matrix_diff(dp,rp),35),
'abs_b1_error':mp.nstr(max_matrix_diff(db,rb),35),
'direct_C_drift':mp.nstr(direct['C_drift'],35),
'direct_trace0_residual':mp.nstr(direct['generalized_trace_zero_residual'],35)}
direct_checks.append(record)
except Exception as exc:
direct_checks.append({'id':spec['id'],'epsilon':spec['epsilon'],
'dps':dps,'status':'OBSERVATIONAL_UNRESOLVED',
'error':repr(exc)})
if PRINT_EACH_TRANSITION:
print(' ',n,obs['update_kind'],
'log10|a|=',nformat(safe_log10_abs(obs['a']),13),
'X_post=',mp.nstr(-mp.log10(st.d),15),flush=True)
status='COMPUTED_TO_DECLARED_HORIZON'
except (KeyboardInterrupt,SystemExit):
raise
except Exception as exc:
status='INITIALIZATION_OR_RECURRENCE_UNRESOLVED'
error_text=repr(exc)
print(' TRACK UNRESOLVED:',error_text,flush=True)
finally:
track_outcomes.append({'id':spec['id'],'epsilon':spec['epsilon'],
'dps':dps,'status':status,'last_success_n':last_success,
'analytic_identity_steps':analytic_count,
'numerical_transport_steps':numeric_count,'error':error_text})
try:
write_csv(OUT/'track_status_checkpoint.csv',track_outcomes)
write_csv(OUT/'per_index_diagnostics_checkpoint.csv',all_diagnostics,
fieldnames=DIAGNOSTIC_COLS)
except Exception as exc:
output_events.append({'id':spec['id'],'dps':dps,'n':last_success,
'stage':'CHECKPOINT_OUTPUT','error':repr(exc)})
print('CELL 17 DONE:',OUT)
print('Completed tracks:',sum(x['status']=='COMPUTED_TO_DECLARED_HORIZON' for x in track_outcomes),
'/',len(track_outcomes))
print('No 5-regime acceptance gate imposed. Output problems recorded separately.')
CELL 18 — MARKDOWN — POST-RUN INTERPRETATION — NO FORCED CLIFF
### CELL 18 — MARKDOWN — POST-RUN INTERPRETATION — NO FORCED CLIFF
The next cells inspect the new Lane C.1 outputs. In the **default** path, both stationary cases have an exact certificate, so an exact identity step is not a numerical “crash.”
Interpret \(\epsilon=0.07\) and \(\epsilon=0.5\) strictly as **exact stationary points**, not demonstrated stationary neighborhoods or attracting basins, on this one-dimensional path. Do not call either a “dead basin” or infer an open neighborhood of fixed points without additional mathematics. Equally, a finite trajectory near either root may take more than 13 updates to display its eventual behaviour.
The recorded \(X\) and \(Y\) growth ratios at early n may cross zero or be undefined; classify them by mathematical definition, not desired outcome. At \(Z=0\), \(Y\) is undefined, not zero. If a path member does not approach the candidate \(5,1/2\) regime, preserve that case as data.
CELL 19 — CODE — FINITE PATH SUMMARY AND STATIONARY/NONSTATIONARY DISTINCTION
# CELL 19 — CODE — FINITE PATH SUMMARY AND STATIONARY/NONSTATIONARY DISTINCTION
if 'OUT' not in globals() or not OUT.is_dir() or 'track_outcomes' not in globals():
raise RuntimeError('Run CELL 17 before summarizing')
summaries=[]
by_spec={s['id']:s for s in selected_specs}
for outcome in track_outcomes:
spec=by_spec[outcome['id']]
rows=sorted([r for r in all_diagnostics if r.get('id')==spec['id']
and r.get('dps')==outcome['dps']
and r.get('status')=='COMPUTED_EXPLORATORY_UNCERTIFIED'],key=lambda r:r['n'])
late=[r for r in rows if r['n']>=7]
def latest(key):
items=[r.get(key) for r in late if r.get(key) not in ('',None)]
return items[-1] if items else ''
record=dict(outcome)
record.update({'exact_stationary_certified':spec['is_exact_stationary'],
'initial_Z_exact_zero':spec['is_exact_Z_zero'],
'a0_exact_fraction':spec['a_fraction'],'Z0_exact_fraction':spec['Z_fraction'],
'computed_diagnostic_rows':len(rows),
'last_X_growth':latest('X_growth'), 'last_Y_growth':latest('Y_growth'),
'last_post_Y_over_X':latest('post_Y_over_X'),
'last_Z_correction_status':(rows[-1].get('z_correction_status','') if rows else ''),
'classification':('EXACT_STATIONARY_POINT' if spec['is_exact_stationary']
else 'FINITE_NONSTATIONARY_OBSERVATION_ONLY')})
summaries.append(record)
write_csv(OUT/'candidate_summary.csv',summaries)
print('SAVED: candidate_summary.csv — no imposed 5 scaling classification')
for r in summaries:
print(f"{r['id']:<13} eps={r['epsilon']:<7} {r['status']:<30} "
f"Xg={str(r['last_X_growth'])[:14]:<15} "
f"Yg={str(r['last_Y_growth'])[:14]:<15} "
f"Y/X={str(r['last_post_Y_over_X'])[:14]:<15} "
f"{r['classification']}")
CELL 20 — CODE — CROSS-PRECISION COMPARISON FROM SAVED FULL STATES
# CELL 20 — CODE — CROSS-PRECISION COMPARISON FROM SAVED FULL STATES
# Compare states at HIGH precision; never round both inputs to lower precision first.
if not ledger_path.is_file(): raise RuntimeError('Full-state ledger missing; see output events')
states={}
with ledger_path.open('r',encoding='utf-8') as f:
for ln in f:
if not ln.strip(): continue
entry=json.loads(ln)
key=(entry['id'],int(entry['n']),int(entry['dps']))
if key in states: raise RuntimeError('DUPLICATE_SAVED_STATE_KEY: '+repr(key))
states[key]=entry['state']
comparison=[]
with mp.workdps(max(DPS_TRACKS)+35):
for spec in selected_specs:
for n in range(-1,LAST_UPDATE_N+1):
for low,high in zip(DPS_TRACKS,DPS_TRACKS[1:]):
lo=states.get((spec['id'],n,low)); hi=states.get((spec['id'],n,high))
rec={'id':spec['id'],'epsilon':spec['epsilon'],'n':n,
'lower_dps':low,'higher_dps':high}
if lo is None or hi is None:
rec['status']='SAVED_STATE_MISSING'
else:
rec['status']='FULL_SAVED_STATES_COMPARED'
scalar_keys=['T','d','A','p']
for name in scalar_keys:
x,y=mp.mpf(lo[name]),mp.mpf(hi[name])
rec['relative_'+name]=mp.nstr(sym_rel_difference(x,y),38)
# Compare every conserved C entry as well: a constant can be
# correct algebraically but still differ in saved rounding.
for idx in range(4):
x,y=mp.mpf(lo['C'][idx]),mp.mpf(hi['C'][idx])
rec[f'relative_C_{idx}']=mp.nstr(sym_rel_difference(x,y),38)
for key in ['Q','direction']:
a=[mp.mpf(x) for x in lo[key]]
b=[mp.mpf(x) for x in hi[key]]
rec['relative_'+key+'_re']=mp.nstr(sym_rel_difference(a[0],b[0]),38)
rec['relative_'+key+'_im']=mp.nstr(sym_rel_difference(a[1],b[1]),38)
comparison.append(rec)
write_csv(OUT/'cross_precision_full_state.csv',comparison)
print('SAVED:',len(comparison),'high-precision full-state comparison records')
print('Zero discrepancy means equality at the recorded precision, not an infinite-index theorem.')
CELL 21 — MARKDOWN — INTERPRETING THE EXPERIMENT WITHOUT A PHYSICAL PROMOTION
### CELL 21 — MARKDOWN — INTERPRETING THE EXPERIMENT WITHOUT A PHYSICAL PROMOTION
Separate: **(a)** certified algebraic identities, **(b)** finite-precision trajectory results, **(c)** candidate leading-order scaling, **(d)** proposed conceptual/physical mappings.
A useful possible discovery is that many nonstationary initial states approach the finite 5-pattern, while exactly stationary states do not. But this notebook must be equally capable of recording delayed onset, departures, alternative scaling, or unresolved precision behaviour.
No result alone maps the R8 workbench matrix \(G_n\) to reconstructed \(G(\Pi)\), establishes \(\Theta_{FR}(\Pi)\), or proves a physical saturated core. These remain motivating hypotheses, **not blockers** to further mathematical exploration.
**Notebook-created files are independent of earlier Lane C outputs; no historical files are overwritten.**
CELL 22 — CODE — EXPORT MANIFEST, INVENTORY, STATUS, DIAGNOSTICS, SHA256
# CELL 22 — CODE — EXPORT MANIFEST, INVENTORY, STATUS, DIAGNOSTICS, SHA256
if 'OUT' not in globals() or not OUT.is_dir() or 'track_outcomes' not in globals():
raise RuntimeError('Run CELL 17 first')
write_csv(OUT/'candidate_inventory.csv',selected_specs)
write_csv(OUT/'direct_n0_comparison.csv',direct_checks,
fieldnames=['id','epsilon','dps','status','a_direct_log10_abs','rel_a',
'rel_d1','abs_G1_error','abs_P1_error','abs_b1_error',
'direct_C_drift','direct_trace0_residual','error'])
write_csv(OUT/'baseline_vs_v2_1_saved.csv',control_checks,
fieldnames=['dps','n','comparison_scope','rel_a','rel_d_next','status','error'])
write_csv(OUT/'per_index_diagnostics.csv',all_diagnostics,fieldnames=DIAGNOSTIC_COLS)
write_csv(OUT/'track_status.csv',track_outcomes)
successful=sum(max(0,x['last_success_n']+1) for x in track_outcomes)
analytic=sum(x['analytic_identity_steps'] for x in track_outcomes)
numeric=sum(x['numerical_transport_steps'] for x in track_outcomes)
manifest={
'experiment_id':EXPERIMENT_ID,
'run_timestamp_utc':run_stamp,
'status':'COMPUTED_EXPLORATORY_UNCERTIFIED',
'experiment_kind':'NEW_LANE_C1_RATIONAL_STATIONARY_BOUNDARY_PATH',
'notebook_design_execution_boundary':'CELL_17',
'frozen_coefficients':{'lambda':LAMBDA_R8,'mu':MU_R8,'tau':TAU_R8},
'frozen_baseline':FROZEN,
'path_formulas':{'a0':'(1-2epsilon)*(7-100epsilon)/44',
'Z0':'5*(1-2epsilon)/4',
'P0':'[[2-e,0.5-e],[-0.5+e,1+e]]',
'b0':'[[1.5+e,0.4+e],[-0.3-e,0.8-e]]'},
'exact_stationary_certificates':[s for s in selected_specs if s['is_exact_stationary']],
'candidate_count':len(selected_specs),'candidate_specs':selected_specs,
'last_attempted_update_n':LAST_UPDATE_N,'dps_tracks':list(DPS_TRACKS),
'steps_planned':expected_attempts,'steps_completed':successful,
'analytic_exact_identity_steps_completed':analytic,
'numerical_reduced_transport_steps_completed':numeric,
'all_tracks_computed_to_horizon':all(x['status']=='COMPUTED_TO_DECLARED_HORIZON' for x in track_outcomes),
'baseline_reference_status':reference_status,
'historical_reference_sha256_if_present':reference_actual_sha,
'representation':'draft_reimplementation_of_documented_v2_1_reduced_equations_with_exact_rational_zero_branch',
'design_release':'v1_1_FINAL_RUN_APPROVED_POST_META_DEEPSEEK_CROSS_AUDIT',
'trace_zero_lemma':'POINTWISE_EXACT_FOR_SYMMETRIC_INVERTIBLE_G',
'direct_n0_matrix_audit_enabled':DIRECT_N0_MATRIX_AUDIT,
'output_events':output_events,'output_integrity':('COMPLETE' if not output_events else 'INCOMPLETE_RECORDED'),
'track_outcomes':track_outcomes,
'not_established':['full_basin_boundary','universal_five_scaling','infinite_index_theorem',
'source_to_execution_certificate','mapping_to_G_of_Pi','physical_saturation_core'],
'output_sha256':{}
}
for p in sorted(OUT.iterdir()):
if p.is_file() and p.name not in ('run_manifest.json','SHA256SUMS.txt'):
manifest['output_sha256'][p.name]=sha256_file(p)
write_json(OUT/'run_manifest.json',manifest)
with (OUT/'SHA256SUMS.txt').open('w',encoding='utf-8') as f:
for p in sorted(OUT.iterdir()):
if p.is_file() and p.name!='SHA256SUMS.txt':
f.write(f'{sha256_file(p)} {p.name}\n')
print('EXPORT COMPLETE:',OUT)
print('Successful:',successful,'/',expected_attempts,
'| analytic exact identities:',analytic,'| numeric reduced updates:',numeric)
print('Files:',len([p for p in OUT.iterdir() if p.is_file()]))
print('Output warning count:',len(output_events))
print('Original source files remain unchanged.')
CELL 23 — MARKDOWN — INDIVIDUAL DOWNLOADS — NOT ZIPPED
### CELL 23 — MARKDOWN — INDIVIDUAL DOWNLOADS — NOT ZIPPED
The next optional cell requests **each result file individually**, without a ZIP. Set `SEND_INDIVIDUAL_DOWNLOADS=True` only after Cell 22 has created the manifest. Your browser may ask for permission to allow multiple downloads.
The new data are in a **uniquely timestamped** folder, separate from all Lane C and historical runs. The notebook does not extract or alter any old archive.
Save your **executed notebook with its outputs** separately using Colab `File → Download → Download .ipynb` for later independent code/output review.
CELL 24 — CODE — OPTIONAL INDIVIDUAL FILE DOWNLOADS — NO ZIP
# CELL 24 — CODE — OPTIONAL INDIVIDUAL FILE DOWNLOADS — NO ZIP
SEND_INDIVIDUAL_DOWNLOADS = False # Change to True only if you want the browser downloads.
if SEND_INDIVIDUAL_DOWNLOADS:
if 'OUT' not in globals() or not (OUT/'run_manifest.json').is_file():
raise RuntimeError('Run experimental and export cells first')
from google.colab import files
import time
paths=sorted(p for p in OUT.iterdir() if p.is_file())
print('Requesting',len(paths),'individual downloads; NO ZIP')
for i,p in enumerate(paths,1):
print(f'{i}/{len(paths)}: {p.name}',flush=True)
files.download(str(p))
time.sleep(2)
print('Download requests sent. Confirm browser saved all files.')
else:
print('Downloads OFF. No browser download requests sent.')
CELL 25 — MARKDOWN — RESEARCHER RUN LOG AND INDEPENDENT CROSS-AUDIT HANDOFF
### CELL 25 — MARKDOWN — RESEARCHER RUN LOG AND INDEPENDENT CROSS-AUDIT HANDOFF
## Complete after the actual Colab execution
- Colab run date/time: **PENDING**
- Candidate count, exact stationary roots: **PENDING**
- Precision-track completion and numerical unresolved statuses: **PENDING**
- Exact rational root outcomes: **PENDING**
- For \(\epsilon<0.07\), \(0.07<\epsilon<0.5\), and near \(0.5\), finite scaling behaviour: **PENDING**
- Evidence of delayed onset, different regimes, or potential boundary structures: **PENDING**
- Cross-precision full-state disagreement: **PENDING**
- Direct n=0 comparator notes, including tiny floating-point residue at exact roots: **PENDING**
- Outside audit corrections and open mathematical questions: **PENDING**
**Upload to AI for review:** `run_manifest.json`, `candidate_summary.csv`, `track_status.csv`, `per_index_diagnostics.csv`, `cross_precision_full_state.csv`, `direct_n0_comparison.csv`, `baseline_vs_v2_1_saved.csv`, `candidate_inventory.csv`, and `per_index_full_states_lane_c1.jsonl`. Include `track_status_checkpoint.csv` and `per_index_diagnostics_checkpoint.csv` if output recovery matters. `SHA256SUMS.txt` and the executed `.ipynb` provide further verification.
**Classification:** Finite sampled-path observations and two exact algebraic stationary identities. The full basin boundary, infinite-index behaviour, reconstructed physical geometry, and saturated-core interpretation remain open research questions.
**THE MATH PROVES THE MATH, NOT REALITY.**
**MATH PROVES THE MODEL**