login
A358932
a(n) is the smallest centered n-gonal number with binary weight n.
4
19, 85, 31, 469, 253, 2025, 5995, 4061, 15742, 48061, 8191, 220543, 384766, 3080161, 3272671, 6192631, 8385271, 31453021, 58159102, 249495467, 401469279, 268418041, 134193151, 2885548927, 1610563582, 8589393821, 33280753395, 83751780091, 171658174447
OFFSET
3,1
EXAMPLE
31 is the smallest centered pentagonal number with binary weight 5 (31_10 = 11111_2), so a(5) = 31.
MATHEMATICA
c[n_, k_] := n*k*(k + 1)/2 + 1; a[n_] := Module[{k = 1, ck}, While[DigitCount[ck = c[n, k], 2, 1] != n, k++]; ck]; Array[a, 25, 3] (* Amiram Eldar, Dec 09 2022 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Ilya Gutkovskiy, Dec 06 2022
STATUS
approved