cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A219835 Number of terms of 2^j + 3^k <= 10^n.

This page as a plain text file.
%I A219835 #18 Jul 30 2021 08:44:57
%S A219835 7,29,64,118,181,254,354,453,565,708,878,1033,1224,1403,1594,1828,
%T A219835 2046,2274,2553,2808,3139,3467,3765,4073,4443,4779,5124,5537,5911,
%U A219835 6294,6690,7266,7693,8129,8650,9114,9588,10153,10654,11167,11776,12449,13005,13662,14243
%N A219835 Number of terms of 2^j + 3^k <= 10^n.
%C A219835 As n-> infinity, a(n) -> log_2(n)*log_3(n).
%H A219835 Zak Seidov, <a href="/A219835/b219835.txt">Table of n, a(n) for n = 1..1000</a>
%t A219835 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}]]
%o A219835 (Python)
%o A219835 def a(n):
%o A219835     s, pow3, lim = set(), 1, 10**n
%o A219835     while pow3 < lim:
%o A219835         for j in range((lim-pow3).bit_length()):
%o A219835             s.add(2**j + pow3)
%o A219835         pow3 *= 3
%o A219835     return len(s)
%o A219835 print([a(n) for n in range(1, 46)]) # _Michael S. Branicky_, Jul 29 2021
%Y A219835 Cf. A004050 (numbers of the form 2^j + 3^k).
%K A219835 nonn
%O A219835 1,1
%A A219835 _Zak Seidov_, Nov 29 2012