login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A071317 a(n) = a(n-1) + sum of digits of n^2. 5
0, 1, 5, 14, 21, 28, 37, 50, 60, 69, 70, 74, 83, 99, 115, 124, 137, 156, 165, 175, 179, 188, 204, 220, 238, 251, 270, 288, 307, 320, 329, 345, 352, 370, 383, 393, 411, 430, 443, 452, 459, 475, 493, 515, 534, 543, 553, 566, 575, 582, 589, 598, 611, 630, 648, 658 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,3

LINKS

Reinhard Zumkeller, Table of n, a(n) for n = 0..10000

MATHEMATICA

s=0; Do[s=s+Apply[Plus, IntegerDigits[n^2]]; Print[s], {n, 1, 128}]

nxt[{n_, a_}]:={n+1, a+Total[IntegerDigits[(n+1)^2]]}; NestList[nxt, {0, 0}, 60][[All, 2]] (* Harvey P. Dale, Mar 09 2017 *)

FoldList[#1 + Total@ IntegerDigits[#2^2] &, 0, Range@ 55] (* Michael De Vlieger, Mar 25 2017 *)

Accumulate[Plus @@@ IntegerDigits[Range[0, 50]^2]] (* Giovanni Resta, Mar 25 2017 *)

PROG

(Haskell)

a071317 n = a071317_list !! n

a071317_list = scanl1 (+) a004159_list

-- Reinhard Zumkeller, Apr 12 2014

CROSSREFS

Cf. A007953, A037123, A000788, A051351.

Partial sums of A004159.

Sequence in context: A277351 A143707 A003248 * A167201 A269871 A323732

Adjacent sequences:  A071314 A071315 A071316 * A071318 A071319 A071320

KEYWORD

easy,nonn,base

AUTHOR

Labos Elemer, May 27 2002

EXTENSIONS

a(0) = 0 prepended by Reinhard Zumkeller, Apr 12 2014

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified February 19 21:59 EST 2019. Contains 320328 sequences. (Running on oeis4.)