TFPT scientific source excerpt Original repository path: experiments/theory-contracts/tfpt-unified-source-derivation-20261029/aps_source_review/check_regional_source_partner.py Original file SHA-256: 0d4b4979b85c955c9363839950d6209905f8107a7bc800d6e424f29cb1d45b00 Inclusive original lines: 1-90 Line numbers below refer to the original source. This bounded excerpt is source evidence; it is not a new proof/checker run. Conversation metadata and personal execution details are omitted where indicated. 000001 | """Support-resolved pairing in the actual free elliptic source. 000002 | No finite Fourier profile is called local; full occupied sea is analytic. 000003 | """ 000004 | from pathlib import Path 000005 | import json 000006 | import mpmath as mp 000007 | import numpy as np 000008 | import sympy as sy 000009 | from scipy.linalg import expm 000010 | HERE=Path(__file__).resolve().parent 000011 | checks=[] 000012 | def need(ok,label): 000013 | if not bool(ok):raise RuntimeError(label) 000014 | checks.append(dict(label=label,passed=True)) 000015 | 000016 | # Algebraic all-mode identities; support strictness is proved analytically. 000017 | z,c,x,a=sy.symbols('z c x a',real=True) 000018 | P=sy.Matrix([[1-z,x],[x,z]]);u=sy.Matrix([0,1]);t=sy.Matrix([x/a,(z-c)/a]) 000019 | def red(expr):return sy.factor(sy.expand(expr).subs(x*x,z*(1-z)).subs(a*a,c*(1-c))) 000020 | need(all(red(e)==0 for e in P*P-P),'Given original full two-face covariance is a projection for every spectral mode') 000021 | need(all(red(e)==0 for e in P*u-c*u-a*t),'Actual probe partner first projection equation, all Fourier modes') 000022 | need(all(red(e*a)==0 for e in P*t-a*u-(1-c)*t),'Actual probe partner second projection equation, all Fourier modes') 000023 | mx,c2=sy.symbols('mx c2',real=True) 000024 | need(sy.simplify(mx+c2-c*c-c*(1-c)).subs(c2,c-mx)==0,'Entire source-moment normalization of derived partner') 000025 | F=sy.Matrix([[0,1],[1,0]]) 000026 | need(P.subs(z,1-z)==F*P*F,'Actual geometric quarter complement requires transported face labels') 000027 | 000028 | mp.mp.dps=85;beta=4*mp.pi;cut=32 000029 | def ur2(r):return mp.mpf('.5') if r==0 else (2/(mp.pi*r)**2 if r%2 else mp.mpf(0)) 000030 | def occ(r,alpha):return 1/(1+mp.exp(beta*(r+alpha))) 000031 | def thermal(r,alpha): 000032 | q=mp.exp(beta*(r+alpha)) if r<0 else mp.exp(-beta*(r+alpha)) 000033 | return -q/(1+q) if r<0 else q/(1+q) 000034 | def cross(r,alpha):return 1/(2*mp.cosh(beta*(r+alpha)/2)) 000035 | def tail(alpha,half=False): 000036 | b=beta/2 if half else beta 000037 | return (mp.exp(-b*(cut+1+alpha))+mp.exp(-b*(cut+1-alpha)))/(1-mp.exp(-b)) 000038 | need(abs(mp.nsum(lambda n:2/(mp.pi*(2*n+1))**2,[0,mp.inf])-mp.mpf('.25'))>j)&1:A[k^(1<.1,'Actual partner restores pure covariance without modifying global source alpha='+str(alpha)) 000086 | rows.append(dict(alpha=str(alpha),actual_right_occupation=mp.nstr(cp,40),actual_physical_cross_word=mp.nstr(xp,40),derived_partner_cross_word=mp.nstr(ap,40),actual_four_field_word=mp.nstr(gap,40),derived_partner_four_field_word='0',outside_C_word=mp.nstr(yC,40),outside_X_word=mp.nstr(yX,40),full_interval_defect_lower_bound=mp.nstr(lower,40),derived_probe_partner_left_weight=mp.nstr(left,35),derived_probe_partner_right_remainder_weight=mp.nstr(right,35),derived_probe_partner_outside_weight_lower_bound=mp.nstr(lower/A2,35),occupation_tail_bound=mp.nstr(tail(alpha),14),cross_tail_bound=mp.nstr(tail(alpha,True),14),physical_pair_eigenvalues=vals.tolist())) 000087 | 000088 | out=dict(verdict='EXACT_SCOPED_REGIONAL_PARTNER_IN_ORIGINAL_FREE_SOURCE; PROPER_OTHER_FACE_ONLY_CANONICAL_PARTNER_EXCLUDED; PHYSICAL_ORIGIN_OPEN',all_passed=True,control_count=len(checks),checks=checks,original_beta='4*pi',rows=rows,scope='Full paired-proper-region exclusion and full interval polar map proved analytically using actual X smoothing and bounded polar decomposition. Numerical words use actual single supported L2 probe, entire negative sea and exponentially bounded correction; its one-mode T is not asserted equal to full interval T_I. Existing global GNS and general projection identity reused. No primitive P1 measure, full E8/4D source, local RP violation, physical signalling or Higgs Gaussianization claimed.') 000089 | (HERE/'REGIONAL-SOURCE-PARTNER.json').write_text(json.dumps(out,ensure_ascii=False,indent=2)+'\n') 000090 | print(json.dumps({k:v for k,v in out.items() if k!='checks'},ensure_ascii=False,indent=2))