A062028 a(n) = n + sum of the digits of n.
Examples
a(34) = 34 + 3 + 4 = 41, a(40) = 40 + 4 = 44.
Links
- Harry J. Smith and N. J. A. Sloane, Table of n, a(n) for n = 0..10000 (first 1000 terms were computed by Harry J. Smith)
- Index entries for Colombian or self numbers and related sequences
Crossrefs
Programs
-
Haskell
a062028 n = a007953 n + n -- Reinhard Zumkeller, Oct 11 2013
-
Maple
with(numtheory): for n from 1 to 100 do a := convert(n,base,10): c := add(a[i],i=1..nops(a)): printf(`%d,`,n+c); od: A062028 := n -> n+add(i,i=convert(n,base,10)) # M. F. Hasler, Nov 08 2018
-
Mathematica
Table[n + Total[IntegerDigits[n]], {n, 0, 100}]
-
PARI
A062028(n)=n+sumdigits(n) \\ M. F. Hasler, Jul 19 2015
-
Python
def a(n): return n + sum(map(int, str(n))) print([a(n) for n in range(71)]) # Michael S. Branicky, Jan 09 2023
Comments