OFFSET
1,1
COMMENTS
This sequence is easily confused with A003586, which gives numbers of the form 2^i*3^j with i, j >= 0, and is one-sixth of the present sequence. . Don't simply say "numbers of the form 2^i*3^j", but specify which sequence you mean. - N. J. A. Sloane, May 26 2024
Solutions to phi(n)=n/3 [See J-M. de Koninck & A. Mercier, problème 733].
Numbers n such that Sum_{d prime divisor of n} 1/d = 5/6. - Benoit Cloitre, Apr 13 2002
Also n such that Sum_{d|n} mu(d)^2/d = 2. - Benoit Cloitre, Apr 15 2002
In the sieve of Eratosthenes, if one crosses numbers off multiple times, these numbers are crossed off twice, first for 2 and then for 3. - Alonso del Arte, Aug 22 2011
Subsequence of A051037. - Reinhard Zumkeller, Sep 13 2011
Solutions to the equation A001615(x) = 2x. - Enrique Pérez Herrero, Jan 02 2012
So these numbers are called Psi-perfect numbers [see J-M. de Koninck & A. Mercier, problème 654]. - Bernard Schott, Nov 20 2020
REFERENCES
J-M. de Koninck & A. Mercier, 1001 Problèmes en Théorie Classique des Nombres, Ellipses, 2004, Problème 733, page 94.
J-M. de Koninck & A. Mercier, 1001 Problèmes en Théorie Classique des Nombres, Ellipses, 2004, Problème 654, page 85.
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
FORMULA
Six times the 3-smooth numbers (A003586). - Ralf Stephan, Apr 16 2004
A143201(a(n)) = 2. - Reinhard Zumkeller, Sep 13 2011
Sum_{n>=1} 1/a(n) = 1/2. - Amiram Eldar, Oct 13 2020
MATHEMATICA
mx = 12000; Sort@ Flatten@ Table[2^i*3^j, {i, Log[2, mx]}, {j, Log[3, mx/2^i]}] (* Robert G. Wilson v, Aug 17 2012 *)
PROG
(Haskell)
import Data.Set (singleton, deleteFindMin, insert)
a033845 n = a033845_list !! (n-1)
a033845_list = f (singleton (2*3)) where
f s = m : f (insert (2*m) $ insert (3*m) s') where
(m, s') = deleteFindMin s
-- Reinhard Zumkeller, Sep 13 2011
(PARI) list(lim)=my(v=List(), N); for(n=0, log(lim\2)\log(3), N=6*3^n; while(N<=lim, listput(v, N); N<<=1)); vecsort(Vec(v)) \\ Charles R Greathouse IV, Jan 02 2012
(Python)
from sympy import integer_log
def A033845(n):
def bisection(f, kmin=0, kmax=1):
while f(kmax) > kmax: kmax <<= 1
while kmax-kmin > 1:
kmid = kmax+kmin>>1
if f(kmid) <= kmid:
kmax = kmid
else:
kmin = kmid
return kmax
def f(x): return n+x-sum((x//3**i).bit_length() for i in range(integer_log(x, 3)[0]+1))
return 6*bisection(f, n, n) # Chai Wah Wu, Sep 15 2024
(Python) # faster for initial segment of sequence
import heapq
from itertools import islice
def A033845gen(): # generator of terms
v, oldv, h, psmooth_primes, = 1, 0, [1], [2, 3]
while True:
v = heapq.heappop(h)
if v != oldv:
yield 6*v
oldv = v
for p in psmooth_primes:
heapq.heappush(h, v*p)
print(list(islice(A033845gen(), 50))) # Michael S. Branicky, Sep 18 2024
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
Edited by N. J. A. Sloane, Jan 31 2010 and May 26 2024.
STATUS
approved