cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A258881 a(n) = n + the sum of the squared digits of n.

This page as a plain text file.
%I A258881 #41 Nov 27 2022 19:23:51
%S A258881 0,2,6,12,20,30,42,56,72,90,11,13,17,23,31,41,53,67,83,101,24,26,30,
%T A258881 36,44,54,66,80,96,114,39,41,45,51,59,69,81,95,111,129,56,58,62,68,76,
%U A258881 86,98,112,128,146,75,77,81,87,95,105,117,131,147,165,96,98,102
%N A258881 a(n) = n + the sum of the squared digits of n.
%H A258881 Carlos Rivera, <a href="http://www.primepuzzles.net/puzzles/puzz_776.htm">Puzzle 776. Ten consecutive integers such that...</a>, The Prime Puzzles and Problems Connection, March 2015.
%t A258881 Total[Flatten@ {#, IntegerDigits[#]^2}] & /@ Range[0, 61] (* _Michael De Vlieger_, Jul 20 2015 *)
%t A258881 Table[n+Total[IntegerDigits[n]^2],{n,0,100}] (* _Harvey P. Dale_, Nov 27 2022 *)
%o A258881 (PARI) A258881(n)=n+norml2(digits(n))
%o A258881 (Python)
%o A258881 def ssd(n): return sum(int(d)**2 for d in str(n))
%o A258881 def a(n): return n + ssd(n)
%o A258881 print([a(n) for n in range(63)]) # _Michael S. Branicky_, Jan 30 2021
%Y A258881 Cf. A003132, A062028, A259391, A259567, A033936, A076161 (indices of primes), A329179 (indices of squares).
%K A258881 nonn,base,easy
%O A258881 0,2
%A A258881 _M. F. Hasler_, Jul 19 2015