A348329 Numbers k such that k' = k'', where ' is the arithmetic derivative.
0, 1, 4, 27, 3125, 823543, 1647082, 2238771
Offset: 1
Programs
-
Maple
isA348329 := proc(n) local d ; d := A003415(n) ; if A003415(d) = d then true ; else false; end if; end proc: for n from 0 do if isA348329(n) then print(n) ; end if; end do: # R. J. Mathar, Oct 19 2021
-
Mathematica
d[0] = d[1] = 0; d[n_] := n * Plus @@ ((Last[#]/First[#]) & /@ FactorInteger[n]); Select[Range[0, 2.5*10^6], d[#] == d[d[#]] &] (* Amiram Eldar, Oct 13 2021 *)
-
PARI
ad(n) = vecsum([n/f[1]*f[2]|f<-factor(n+!n)~]); \\ A003415 isok(k) = ad(k) == ad(ad(k)); \\ Michel Marcus, Oct 18 2021
-
Python
from sympy import factorint from itertools import count, islice def ad(n): return 0 if n<2 else sum(n*e//p for p, e in factorint(n).items()) def agen(): yield from (k for k in count(0) if (adk:=ad(k)) == ad(adk)) print(list(islice(agen(), 5))) # Michael S. Branicky, Oct 12 2022
Comments