OFFSET
1,1
COMMENTS
Squarefree numbers k imply rad(k) - core(k) = k - k = 0.
Perfect squares k^2 such that rad(k) = m^2+1 and k > 1 imply rad(k^2) - core(k^2) = (m^2+1) - 1 = m^2, with integers k, m.
Generally, if there exists a minimal d such that d | k, k/d = m^2, and rad(k) - d = m^2, then k is in the sequence.
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..3170 (all terms less than 2^28.)
EXAMPLE
a(1) = 4 since rad(4) = 1+1; rad(4) - core(4) = 2 - 1 = 1, a nonzero square.
a(2) = 18 since 18/2 = 9, and rad(18) - core(18) = 6 - 2 = 4, a nonzero square, etc.
MATHEMATICA
Select[Range[6000], And[IntegerQ[#], # > 0] &[Sqrt[Times @@ FactorInteger[#][[All, 1]] - (Sqrt[#] /. (c_ : 1)*a_^(b_ : 0) :> (c*a^b)^2)] ] &]
PROG
(PARI) isok(k) = my(s=factorback(factorint(k)[, 1])-core(k)); (s>0) && issquare(s); \\ Michel Marcus, Sep 18 2023
(Python)
from itertools import count, islice
from sympy.ntheory.primetest import is_square
from sympy import factorint
def A363084_gen(startvalue=1): # generator of terms >= startvalue
for k in count(max(startvalue, 1)):
a, b = 1, 1
for p, e in factorint(k).items():
if e&1:
a *= p
else:
b *= p
if b>1 and is_square(a*(b-1)):
yield k
CROSSREFS
KEYWORD
nonn
AUTHOR
Michael De Vlieger, Sep 05 2023
STATUS
approved
