from research import *
s=begin(1144,'Locate each capacity-loss step in the genealogy','Why does a shared350 loss affect some rows differently and shrink downstream?',{},['C1143','File18 §§2.1.3,3.1'])
d=json.loads((ROOT/'model/SP_capacity_slack_transfer.json').read_text());delta=d['capacity_reductions']
local=[delta[i]-(delta[i+1] if i+1<len(delta) else 0) for i in range(9)]
a=artifact('model/SP_capacity_step_locations.json',json.dumps({'row_order':['Adam','Seth','Enosh','Kenan','Mahalalel','Jared','Enoch','Methuselah','Lamech'],'local_begetting_losses':local,'suffix_cap_losses':delta,'nonzero_sites':[i for i,v in enumerate(local) if v],'interpretation':'same total350 does not determine the whole suffix field; placement of100,120,130 supplies the intermediate steps'},indent=2)+'\n')
finish(s,{'step_locations':a,'local_losses':local},'The350 loss is the cumulative effect of three located changes100,120,130. Its downstream levels350,250,130 follow their positions, so the complete cap response depends on an ordered source change vector, not just its total.','Test whether moving a fixed loss to a different source row preserves the cap output.',{'exact_locations':local==[0,0,0,0,0,100,0,120,130],'sum350':sum(local)==350})
