A257484 Numbers k such that lambda(sum of divisors of k that are congruent to 0 mod 3) = lambda(sum of divisors of k that are congruent to 1 mod 3) = lambda(sum of divisors of k that are congruent to 2 mod 3) where lambda is the Carmichael function (A002322).
78, 222, 234, 294, 312, 366, 375, 438, 582, 618, 666, 834, 876, 882, 888, 936, 942, 1086, 1095, 1098, 1125, 1158, 1176, 1236, 1314, 1464, 1482, 1536, 1545, 1662, 1746, 1752, 1842, 1878, 2013, 2022, 2028, 2094, 2166, 2274, 2316, 2328, 2382, 2472, 2502, 2526
Offset: 1
Keywords
Examples
78 is in the sequence because the divisors of 78 are {1,2,3,6,13,26,39,78} and the divisors congruent to 0 mod 3 are {3,6,39,78} => sum=126, the divisors congruent to 1 mod 3 are {1,13} => sum=14, the divisors congruent to 2 mod 3 are {2,26} => sum=28, and lambda(126)=lambda(14)=lambda(28) = 6.
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Programs
-
Maple
with(numtheory):nn:=2600: for n from 1 to nn do: s0:=0:s1:=0:s2:=0: x:=divisors(n):n0:=nops(x): for i from 1 to n0 do: q:=x[i]: if irem(q,3)=0 then s0:=s0+q: else if irem(q,3)=1 then s1:=s1+q: else s2:=s2+q: fi:fi: od: if lambda(s0)=lambda (s1) and lambda(s1)=lambda(s2) then printf(`%d, `,n): else fi: od:
-
Mathematica
lst={}; f[x_] := Plus @@ Select[Divisors[x], Mod[#,3]==0 &]; g[x_] := Plus @@ Select[Divisors[x], Mod[#,3]==1 &];h[x_] := Plus @@ Select[Divisors[x], Mod[#,3]==2 &]; Do[If[CarmichaelLambda[f[n]]== CarmichaelLambda[g[n]]&& CarmichaelLambda[f[n]]== CarmichaelLambda[h[n]], AppendTo[lst, n]], {n, 1, 2600}]; lst
-
PARI
lambda(n)=lcm(znstar(n)[2]); isok(n) = {my(sd0=sumdiv(n, d, d*((d % 3)==0))); my(sd1=sumdiv(n, d, d*((d % 3)==1))); my(sd2=sumdiv(n, d, d*((d % 3)==2))); sd0 && sd1 && sd2 && (lambda(sd0) == lambda(sd1)) && (lambda(sd0)==lambda(sd2));} lista(nn) = for (n=1, nn, if (isok(n), print1(n, ", "))); \\ Michel Marcus, May 02 2015
Comments