OFFSET
1,1
COMMENTS
Powerful numbers (A001694) that are not squares of cubefree numbers (A004709), cubes of squarefree numbers (A062838), or 6th powers of primes (A030516). - Amiram Eldar, Feb 07 2023
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
FORMULA
Sum_{n>=1} 1/a(n) = 1 + ((zeta(2)-1)*(zeta(3)-1)-1)/zeta(6) - P(6) = 0.12806919584708298724..., where P(s) is the prime zeta function. - Amiram Eldar, Feb 07 2023
MATHEMATICA
With[{max = 5000}, Union[Table[i^2*j^3, {j, 2, max^(1/3)}, {i, 2, Sqrt[max/j^3]}] // Flatten]] (* Amiram Eldar, Feb 07 2023 *)
PROG
(PARI) list(lim)=my(v=List()); for(b=2, sqrtnint(lim\4, 3), for(a=2, sqrtint(lim\b^3), listput(v, a^2*b^3))); Set(v) \\ Charles R Greathouse IV, Jan 03 2014
(Python)
from math import isqrt
from sympy import mobius, integer_nthroot, primepi
def A216427(n):
def squarefreepi(n): return int(sum(mobius(k)*(n//k**2) for k in range(1, isqrt(n)+1)))
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):
j, b = isqrt(x), integer_nthroot(x, 6)[0]
l, c = 0, n+x-1+primepi(b)+sum(mobius(k)*(j//k**3) for k in range(1, b+1))
while j>1:
k2 = integer_nthroot(x//j**2, 3)[0]+1
w = squarefreepi(k2-1)
c -= j*(w-l)
l, j = w, isqrt(x//k2**3)
return c+l
return bisection(f, n, n) # Chai Wah Wu, Sep 13 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
V. Raman, Sep 07 2012
STATUS
approved