OFFSET
1,1
COMMENTS
As n-> infinity, a(n) -> log_2(n)*log_3(n).
LINKS
Zak Seidov, Table of n, a(n) for n = 1..1000
MATHEMATICA
Join[{7, 29}, Table[m = 10^x; -4 + Floor [ Log[3, m ]] + Sum[Floor @ Log[2, m - 3^i], {i, 0, Log[3, m]}], {x, 3, 100}]]
PROG
(Python)
def a(n):
s, pow3, lim = set(), 1, 10**n
while pow3 < lim:
for j in range((lim-pow3).bit_length()):
s.add(2**j + pow3)
pow3 *= 3
return len(s)
print([a(n) for n in range(1, 46)]) # Michael S. Branicky, Jul 29 2021
CROSSREFS
KEYWORD
nonn
AUTHOR
Zak Seidov, Nov 29 2012
STATUS
approved