Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #20 Nov 17 2024 15:04:49
%S 1,4,9,10,40,90,100,400,900,1000,1111,1224,1242,1339,1393,1422,1933,
%T 2124,2142,2214,2241,2412,2421,3139,3193,3319,3391,3913,3931,4000,
%U 4122,4212,4221,4444,4669,4696,4966,6469,6496,6649,6694,6946,6964,9000,9133,9313
%N Numbers such that the sum, sum of the squares, and sum of the cubes of the decimal digits are each a perfect square.
%C Each number > 90 contains at least two identical digits because the sequence A197125 contains a subset of numbers all of whose digits are distinct and are all the permutations of 1567890. But 1^3 + 5^3 + 6^3 + 7^3 + 8^3 + 9^3 = 1926 is not square. Consequently, it is impossible to find numbers > 90 with distinct digits in this sequence.
%H Charles R Greathouse IV, <a href="/A197129/b197129.txt">Table of n, a(n) for n = 1..10000</a>
%F A028839 INTERSECT A175396 INTERSECT A197039.
%e 4669 is in the sequence because:
%e 4 + 6 + 6 + 9 = 25 = 5^2;
%e 4^2 + 6^2 + 6^2 + 9^2 = 169 = 13^2;
%e 4^3 + 6^3 + 6^3 + 9^3 = 1225 = 35^2.
%p for n from 1 to 10000 do:l:=evalf(floor(ilog10(n))+1):n0:=n:s1:=0:s2:=0:s3:=0:for m from 1 to l do:q:=n0:u:=irem(q, 10):v:=iquo(q, 10): n0:=v :s1:=s1+u:s2:=s2+u^2:s3:=s3+u^3:od:if sqrt(s1)=floor(sqrt(s1)) and sqrt(s2)=floor(sqrt(s2)) and sqrt(s3)=floor(sqrt(s3))then printf(`%d, `, n): else fi:od:
%t sdQ[n_]:=Module[{idn=IntegerDigits[n]},IntegerQ[Sqrt[Total[idn]]] && IntegerQ[Sqrt[Total[idn^2]]]&&IntegerQ[Sqrt[Total[idn^3]]]]; Select[ Range[ 10000],sdQ] (* _Harvey P. Dale_, Oct 25 2011 *)
%t psQ[n_]:=With[{idn=IntegerDigits[n]},AllTrue[{Sqrt[Total[idn]],Sqrt[Total[idn^2]],Sqrt[Total[idn^3]]},IntegerQ]]; Select[Range[10000],psQ] (* _Harvey P. Dale_, Nov 17 2024 *)
%o (PARI) is(n)=my(v=eval(Vec(Str(n))));issquare(sum(i=1,#v,v[i]))&&issquare(sum(i=1,#v,v[i]^2))&&issquare(sum(i=1,#v,v[i]^3)) \\ _Charles R Greathouse IV_, Oct 10 2011
%Y Cf. A028839, A175396, A197039, A197125.
%K nonn,base
%O 1,2
%A _Michel Lagneau_, Oct 10 2011