A334100 Square array where the row n lists all numbers k for which A329697(k) = n, read by falling antidiagonals.
1, 2, 3, 4, 5, 7, 8, 6, 9, 19, 16, 10, 11, 21, 43, 32, 12, 13, 23, 47, 127, 64, 17, 14, 27, 49, 129, 283, 128, 20, 15, 29, 57, 133, 301, 659, 256, 24, 18, 31, 59, 139, 329, 817, 1319, 512, 34, 22, 33, 63, 141, 343, 827, 1699, 3957, 1024, 40, 25, 35, 67, 147, 347, 839, 1787, 4079, 9227, 2048, 48, 26, 37, 69, 161, 361, 849, 1849, 4613, 9233, 21599
Offset: 1
Examples
The top left corner of the array: n\k | 1 2 3 4 5 6 7 8 9 10 ------+---------------------------------------------------------------- 0 | 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, ... 1 | 3, 5, 6, 10, 12, 17, 20, 24, 34, 40, ... 2 | 7, 9, 11, 13, 14, 15, 18, 22, 25, 26, ... 3 | 19, 21, 23, 27, 29, 31, 33, 35, 37, 38, ... 4 | 43, 47, 49, 57, 59, 63, 67, 69, 71, 77, ... 5 | 127, 129, 133, 139, 141, 147, 161, 163, 171, 173, ... 6 | 283, 301, 329, 343, 347, 361, 379, 381, 383, 387, ... 7 | 659, 817, 827, 839, 849, 863, 883, 889, 893, 903, ... 8 | 1319, 1699, 1787, 1849, 1977, 1979, 1981, 2021, 2039, 2083, ... 9 | 3957, 4079, 4613, 4903, 5097, 5179, 5361, 5377, 5399, 5419, ... etc. Note that the row 9 is the first one which begins with composite, as 3957 = 3*1319. The next such rows are row 15 and row 22. See A334099.
Crossrefs
Programs
-
Mathematica
Block[{nn = 16, s}, s = Values@ PositionIndex@ Array[-1 + Length@ NestWhileList[# - #/FactorInteger[#][[-1, 1]] &, #, # != 2^IntegerExponent[#, 2] &] &, 2^nn]; Table[s[[#, k]] &[m - k + 1], {m, nn - Ceiling[nn/4]}, {k, m, 1, -1}]] // Flatten (* Michael De Vlieger, Apr 30 2020 *)
-
PARI
up_to = 105; \\ up_to = 1081; \\ = binomial(46+1,2) A329697(n) = if(!bitand(n,n-1),0,1+A329697(n-(n/vecmax(factor(n)[, 1])))); memoA334100sq = Map(); A334100sq(n, k) = { my(v=0); if(!mapisdefined(memoA334100sq,[n,k-1],&v),if(1==k, v=0, v = A334100sq(n, k-1))); for(i=1+v,oo,if(A329697(i)==(n-1),mapput(memoA334100sq,[n,k],i); return(i))); }; A334100list(up_to) = { my(v = vector(up_to), i=0); for(a=1,oo, for(col=1,a, i++; if(i > up_to, return(v)); v[i] = A334100sq(col,(a-(col-1))))); (v); }; v334100 = A334100list(up_to); A334100(n) = v334100[n];
Comments