login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Position of 210^n among 7-smooth numbers A002473.
4

%I #21 Sep 23 2024 04:00:49

%S 1,68,547,2119,5817,13008,25412,45078,74409,116147,173379,249532,

%T 348375,474018,630922,823885,1058051,1338898,1672260,2064302,2521535,

%U 3050825,3659361,4354687,5144682,6037582,7041946,8166692,9421074,10814695,12357491,14059744,15932086,17985473

%N Position of 210^n among 7-smooth numbers A002473.

%C Also position of 210^(n+1) in A147571.

%F a(n) ~ c * n^4, where c = log(210)^4/(24*log(2)*log(3)*log(5)*log(7)) = 14.282278766622... - _Vaclav Kotesovec_ and _Amiram Eldar_, Sep 22 2024

%t Table[

%t Sum[Floor@ Log[7, 210^n/(2^i*3^j*5^k)] + 1,

%t {i, 0, Log[2, 210^n]},

%t {j, 0, Log[3, 210^n/2^i]},

%t {k, 0, Log[5, 210^n/(2^i*3^j)]}],

%t {n, 0, 12}]

%o (Python)

%o import heapq

%o from itertools import islice

%o from sympy import primerange

%o def A372401gen(p=7): # generator for p-smooth terms

%o v, oldv, psmooth_primes, = 1, 0, list(primerange(1, p+1))

%o h = [(1, [0]*len(psmooth_primes))]

%o idx = {psmooth_primes[i]:i for i in range(len(psmooth_primes))}

%o loc = 0

%o while True:

%o v, e = heapq.heappop(h)

%o if v != oldv:

%o loc += 1

%o if len(set(e)) == 1:

%o yield loc

%o oldv = v

%o for p in psmooth_primes:

%o vp, ep = v*p, e[:]

%o ep[idx[p]] += 1

%o heapq.heappush(h, (v*p, ep))

%o print(list(islice(A372401gen(), 15))) # _Michael S. Branicky_, Jun 05 2024

%o (Python)

%o from sympy import integer_log

%o def A372401(n):

%o c, x = 0, 210**n

%o for i in range(integer_log(x,7)[0]+1):

%o for j in range(integer_log(m:=x//7**i,5)[0]+1):

%o for k in range(integer_log(r:=m//5**j,3)[0]+1):

%o c += (r//3**k).bit_length()

%o return c # _Chai Wah Wu_, Sep 16 2024

%Y Cf. A002110, A002473, A022330, A147571, A202821, A372400, A372402.

%K nonn

%O 0,2

%A _Michael De Vlieger_, Jun 03 2024