login
Numbers whose digits sum to a perfect number.
0

%I #20 Mar 14 2023 15:42:28

%S 6,15,24,33,42,51,60,105,114,123,132,141,150,204,213,222,231,240,303,

%T 312,321,330,402,411,420,501,510,600,1005,1014,1023,1032,1041,1050,

%U 1104,1113,1122,1131,1140,1203,1212,1221,1230,1302,1311,1320,1401,1410,1500

%N Numbers whose digits sum to a perfect number.

%C This is the index of numbers in A007953 whose value is found in A000396.

%C The first 49 terms of this sequence sum to 6 (A052220). The first divergence is a(50)=1999; lengthy divergences occur for 131 consecutive values starting with a(120)=6499, and 248 consecutive values starting with a(595)=24499.

%e a(4)=33, because 3+3 is the perfect number 6.

%t Select[Range[1500],MemberQ[{6,28,496,8128},Total[IntegerDigits[#]]]&] (* _Harvey P. Dale_, Mar 14 2023 *)

%o (R) perf=c(6, 28, 496, 8128, 33550336, 8589869056, 137438691328, 2305843008139952128); i=6; psod=c(); while(length(psod)<1000) {x=which(sumod(i)==perf); if(length(x)) psod=c(psod,i+x/10); i=i+1}

%Y Cf. A052220, A007953, A000396.

%Y Superset of A048517

%K nonn,base

%O 1,1

%A _Kevin L. Schwartz_ and _Christian N. K. Anderson_, Mar 23 2013