OFFSET
1,1
COMMENTS
There is no constraint on which of the three primes is the largest or smallest.
EXAMPLE
360=2^3*3^2*5. 504=2^3*3^2*7. 1188=2^2*3^3*11.
MATHEMATICA
f[n_]:=Sort[Last/@FactorInteger[n]]=={1, 2, 3}; Select[Range[5000], f]
PROG
(PARI) list(lim)=my(v=List(), t1, t2); forprime(p=2, (lim\12)^(1/3), t1=p^3; forprime(q=2, sqrt(lim\t1), if(p==q, next); t2=t1*q^2; forprime(r=2, lim\t2, if(p==r||q==r, next); listput(v, t2*r)))); vecsort(Vec(v)) \\ Charles R Greathouse IV, Jul 20 2011
(Python)
from math import isqrt
from sympy import primepi, primerange, integer_nthroot
def A163569(n):
def bisection(f, kmin=0, kmax=1):
while f(kmax) > kmax: kmax <<= 1
kmin = 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(primepi(x//(p**3*q**2)) for p in primerange(integer_nthroot(x, 3)[0]+1) for q in primerange(isqrt(x//p**3)+1))+sum(primepi(integer_nthroot(x//p**3, 3)[0]) for p in primerange(integer_nthroot(x, 3)[0]+1))+sum(primepi(isqrt(x//p**4)) for p in primerange(integer_nthroot(x, 4)[0]+1))+sum(primepi(x//p**5) for p in primerange(integer_nthroot(x, 5)[0]+1))-(primepi(integer_nthroot(x, 6)[0])<<1)
return bisection(f, n, n) # Chai Wah Wu, Mar 27 2025
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Joseph Stephan Orlovsky, Jul 31 2009
STATUS
approved
