A256577 Sum_{k>=0} (d_k)^(k+1)*10^k, where Sum_{k>=0} (d_k)*10^k is the decimal expansion of n.
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 250, 251, 252, 253, 254, 255, 256, 257, 258, 259, 360, 361, 362, 363, 364, 365, 366, 367, 368, 369, 490
Offset: 0
Examples
a(19) = 1^2 * 10^1 + 9^1 * 10^0 = 19. a(20) = 2^2 * 10^1 + 0^1 * 10^0 = 40. a(40) = 4^2 * 10^1 + 0^1 * 10^0 = 160. a(199) = 1^3 * 10^2 + 9^2 * 10^1 + 9^1 * 10^0 = 100 + 810 + 9 = 919.
Links
- Michael De Vlieger, Table of n, a(n) for n = 0..10000
Programs
-
Mathematica
Array[Total@ MapIndexed[#1^(#2)*10^(#2 - 1) & @@ {#1, First[#2]} &, Reverse@ IntegerDigits[#]] &, 71, 0] (* Michael De Vlieger, Nov 16 2022 *)
-
PARI
vector(80, n, d = digits(n); sum(k=1, #d, d[k]^(#d-k+1)*10^(#d-k))) \\ Michel Marcus, Apr 09 2015
Extensions
Name and comments corrected by Paul Tek, Apr 11 2015
Comments