login
Number n for which sigma(n)=sigma(n'), where sigma is the sum of divisors and n' the arithmetic derivative of n.
4

%I #16 Apr 22 2015 10:37:42

%S 4,27,60,84,132,140,204,220,228,260,270,340,372,378,444,492,564,572,

%T 580,620,644,702,708,740,804,812,820,836,860,884,918,945,1026,1068,

%U 1180,1242,1276,1284,1292,1308,1316,1364,1420,1460,1484,1485,1508,1564,1566

%N Number n for which sigma(n)=sigma(n'), where sigma is the sum of divisors and n' the arithmetic derivative of n.

%H Nathaniel Johnston, <a href="/A190403/b190403.txt">Table of n, a(n) for n = 1..10000</a>

%p with(numtheory);

%p P:=proc(i)

%p local f,n,p,pfs;

%p for n from 1 to i do

%p pfs:=ifactors(n)[2];

%p f:=n*add(op(2,p)/op(1,p),p=pfs);

%p if sigma(n)=sigma(f) then print(n); fi;

%p od;

%p end:

%p P(1000);

%t d[0] = d[1] = 0; d[n_] := n*Total[f = FactorInteger[n]; f[[All, 2]]/f[[All, 1]] ]; Reap[For[n = 1, n < 2000, n++, If[DivisorSigma[1, n] == DivisorSigma[1, d[n]], Sow[n]]]][[2, 1]] (* _Jean-François Alcover_, Apr 22 2015 *)

%o (Python)

%o from sympy import factorint, totient

%o A190402 = [n for n in range(2,10**3) if totient(int(sum([n*e/p for p,e in factorint(n).items()]))) == totient(n)] # _Chai Wah Wu_, Aug 21 2014

%Y Cf. A000203, A003415, A189057, A190402.

%K nonn,easy

%O 1,1

%A _Paolo P. Lava_, May 10 2011