%I #27 Sep 23 2024 08:10:54
%S 3,6,9,12,15,18,21,24,27,30,36,42,45,48,54,60,63,72,75,81,84,90,96,
%T 105,108,120,126,135,144,147,150,162,168,180,189,192,210,216,225,240,
%U 243,252,270,288,294,300,315,324,336,360,375,378,384,405,420,432,441,450
%N Multiples of 3 which are members of A002473. Or multiples of 3 with the largest prime divisor < 10.
%H Michael S. Branicky, <a href="/A085126/b085126.txt">Table of n, a(n) for n = 1..10001</a> (first 1001 terms from Harvey P. Dale)
%F a(n) = 3*A002473(n). - _Chai Wah Wu_, Sep 18 2024
%F Sum_{n>=1} 1/a(n) = 35/24. - _Amiram Eldar_, Sep 23 2024
%t Select[3*Range[200],FactorInteger[#][[-1,1]]<10&] (* _Harvey P. Dale_, Apr 10 2019 *)
%o (Python)
%o from sympy import integer_log
%o def A085126(n):
%o def bisection(f,kmin=0,kmax=1):
%o while f(kmax) > kmax: kmax <<= 1
%o while kmax-kmin > 1:
%o kmid = kmax+kmin>>1
%o if f(kmid) <= kmid:
%o kmax = kmid
%o else:
%o kmin = kmid
%o return kmax
%o def f(x):
%o c = n+x
%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
%o return bisection(f,n,n)*3 # _Chai Wah Wu_, Sep 17 2024
%o (Python) # faster for initial segment of sequence
%o import heapq
%o from itertools import islice
%o def A085126gen(): # generator of terms
%o v, oldv, h, psmooth_primes, = 1, 0, [1], [2, 3, 5, 7]
%o while True:
%o v = heapq.heappop(h)
%o if v != oldv:
%o yield 3*v
%o oldv = v
%o for p in psmooth_primes:
%o heapq.heappush(h, v*p)
%o print(list(islice(A085126gen(), 65))) # _Michael S. Branicky_, Sep 17 2024
%Y Intersection of A008585 and A002473.
%Y Cf. A085125, A085127, A085128, A085129, A080194, A085131, A085132.
%K easy,nonn
%O 1,1
%A _Amarnath Murthy_, Jul 06 2003
%E More terms from _David Wasserman_, Jan 28 2005
%E Offset changed to 1 by _Michael S. Branicky_, Sep 17 2024