from fractions import Fraction as Q def run(load,check): reg=load('C286_DATA.json')['target_register'];rows=[] for f in load('C349_DATA.json')['fields']: records=f['records'];N=records['N']['center'] for u,v in f['maps']['E_N'].items(): p=N-600;x=records[u]['center']-600;y=records[v]['center']-600 matches={k:[z for z in reg if z['center']==v] for k,v in [('pivot',p),('input',x),('output',y)]} check('conjugated equality '+str(f['i'])+u,Q(p)+Q(25,23)*(x-p)==y) complete=all(matches.values());rows.append({'i':f['i'],'original_labels':[u,v],'original_pivot':records['N'],'translation':-600,'pivot':p,'input':x,'output':y,'matches':matches,'complete_source_triple':complete,'nontrivial':u!=v}) check('eight translated relations',len(rows)==8) nontrivial=[r for r in rows if r['nontrivial'] and r['complete_source_triple']] check('only M to S survives as nontrivial source relation',len(nontrivial)==2 and all(r['original_labels']==['M','S'] for r in nontrivial)) for r in nontrivial: check('typed Flood and death triple '+str(r['i']),any(x['tradition']=='SP' and x['role']=='Flood start' and x['Cainan']==0 and x['Terah60']==0 and x['full430']==1 for x in r['matches']['pivot']) and any(x['tradition']=='MT' and x['role']=='Flood start' and x['Cainan']==1 and x['Terah60']==1 and x['full430']==1 for x in r['matches']['input']) and any(x['tradition']=='SP' and x['role']=='Shem death' and x['rail']=='primary' and x['Cainan']==0 and x['Terah60']==0 and x['full430']==1 for x in r['matches']['output'])) check('translated460 to500 '+str(r['i']),r['pivot']-r['input']==460 and r['pivot']-r['output']==500) return {'step':'C355','translation':-600,'translation_origin':'Existing matched Shem600 lifespan; not a fitted scalar.','rows':rows,'nontrivial_complete':nontrivial,'formula':'T_-600 o E_N o T_+600 = E_(N-600)','counts':{'tested':8,'complete_with_fixed':sum(x['complete_source_triple'] for x in rows),'complete_nontrivial':len(nontrivial)},'scope':'The existing source field admits a translated arrow, not a total translation action. The650 birth-pair image does not translate as a complete input/output pair.','new_source_nodes':False}