login
A178224
Numbers k such that d(1)^1 + d(2)^2 +... + d(p)^p is a square, where d(i), i=1..p, are the decimal digits of k.
1
0, 1, 4, 9, 10, 31, 40, 52, 73, 81, 90, 94, 100, 102, 142, 144, 148, 163, 211, 247, 301, 310, 345, 352, 400, 421, 422, 466, 520, 523, 526, 562, 573, 631, 643, 679, 711, 712, 730, 772, 785, 801, 802, 810, 813, 816, 832, 834, 838, 841, 865, 874, 877, 900, 903, 906, 937, 940, 982, 983, 986, 1000, 1020, 1022, 1042, 1082, 1111, 1172, 1420
OFFSET
1,3
LINKS
EXAMPLE
8762 is in the sequence because 8 + 7^2 + 6^3 + 2^4 = 289 = 17^2.
MAPLE
with(numtheory):for n from 0 to 1500 do:l:=length(n):n0:=n:s:=0:for m from
1 to l do:q:=n0:u:=irem(q, 10):v:=iquo(q, 10):n0:=v :s:=s+u^(l-m+1):od:if type(sqrt(s), integer)=true then printf(`%d, `, n):else fi:od:
MATHEMATICA
sqQ[n_]:=Module[{idn=IntegerDigits[n]}, IntegerQ[Sqrt[Total[idn^Range[ Length[ idn]]]]]]; Select[Range[0, 1500], sqQ] (* Harvey P. Dale, Jun 22 2011 *)
PROG
(Sage) is_A178224 = lambda x: is_square(sum(d**i for i, d in enumerate(reversed(x.digits()), 1))) # D. S. McNeil, Dec 20 2010
CROSSREFS
Sequence in context: A236024 A141395 A121215 * A102985 A112401 A178360
KEYWORD
nonn,base
AUTHOR
Michel Lagneau, Dec 20 2010
EXTENSIONS
Offset corrected by Robert Israel, Feb 19 2024
STATUS
approved