OFFSET
1,1
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
MATHEMATICA
seq[lim_] := Union[Table[m^(2*k) - 1, {k, 2, Log2[lim + 1]/2}, {m, 2, Surd[lim + 1, 2*k], 2}] // Flatten]; seq[10^7]
PROG
(PARI) list(lim) = {my(s = List()); for(k = 2, logint(lim+1, 2)\2, forstep(m = 2, sqrtnint(lim+1, 2*k), 2, listput(s, m^(2*k) - 1))); Set(s); }
(Python)
from math import isqrt
from sympy import mobius, integer_nthroot
from oeis_sequences.OEISsequences import bisection
def A389956(n): return bisection(lambda x:int(n+x+sum(mobius(k)*(integer_nthroot(isqrt(x+1), k)[0]>>1) for k in range(2, isqrt(x+1).bit_length()))), n, n) # Chai Wah Wu, Oct 21 2025
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Amiram Eldar, Oct 20 2025
STATUS
approved
