login
A117306
Numbers k such that the counts of 0's, 1's and 2's are the same in the ternary expansion of 2^k.
3
66, 227, 903, 17574, 40102, 462260, 5930999
OFFSET
1,1
COMMENTS
From Pontus von Brömssen, Feb 06 2026: (Start)
Numbers k such that A104320(k) = A036461(k) = A260683(k).
A020915(a(n)) is divisible by 3.
(End)
EXAMPLE
2^66 = {2, 0, 0, 0, 1, 2, 1, 2, 1, 0, 2, 1, 1, 2, 1, 0, 2, 1, 1, 2, 1, 0, 2, 1, 2, 2, 2, 1, 0, 0, 0, 2, 0, 0, 2, 0, 1, 0, 1, 2, 0, 1}
Count of 1 = count of 2 = count of 0 = 14, so 66 is member
Occurrences of digits 0,1,2 in 2^k:
{k, {#0,#1,#2}}
{66,{14,14,14}}
{227,{48,48,48}}
{903,{190,190,190}}
{17574,{3696,3696,3696}}
{40102,{8434,8434,8434}}
{462260,{97218,97218,97218}}. [Willy Van den Driessche, Jul 21 2011]
MATHEMATICA
Do[If[DigitCount[2^n, 3, 0]==DigitCount[2^n, 3, 1]==DigitCount[2^n, 3, 2], Print[n]], {n, 1, 60000}]
Select[Range[41000], Length[Union[DigitCount[2^#, 3, {0, 1, 2}]]]==1&] (* The program generates the first 5 terms of the sequence. To generate more, increase the Range constant, but the program may take a long time to run. *) (* Harvey P. Dale, Aug 05 2021 *)
CROSSREFS
KEYWORD
nonn,base,more,changed
AUTHOR
Mohammed Bouayoun (Mohammed.bouayoun(AT)sanef.com), Apr 24 2006
EXTENSIONS
a(6) from Willy Van den Driessche, Jul 21 2011.
a(7) from Donovan Johnson, Jul 25 2011
STATUS
approved