A040115 Concatenate absolute values of differences between adjacent digits of n.
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 2, 1, 0, 1, 2, 3, 4, 5, 6, 7, 3, 2, 1, 0, 1, 2, 3, 4, 5, 6, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5, 5, 4, 3, 2, 1, 0, 1, 2, 3, 4, 6, 5, 4, 3, 2, 1, 0, 1, 2, 3, 7, 6, 5, 4, 3, 2, 1, 0, 1, 2, 8, 7, 6, 5, 4, 3, 2, 1, 0, 1, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 1
Offset: 0
Examples
a(371) = 46, for example. a(110) = 01 = 1, while A080465(110) = 10 - 1 = 9. - _M. F. Hasler_, Nov 09 2019
Links
- T. D. Noe, Table of n, a(n) for n = 0..10000
- E. Angelini, The Ghost Iteration, Personal blog "Cinquante signes", Nov 2019
- E. Angelini, The Ghost Iteration, Personal blog "Cinquante signes", Nov 2019 [Cached copy, pdf file, with permission]
Crossrefs
Programs
-
Mathematica
Table[FromDigits[Abs[Differences[IntegerDigits[n]]]],{n,110}] (* Harvey P. Dale, Dec 16 2021 *)
-
PARI
apply( A040115(n)=fromdigits(abs((n=digits(n+!n))[^-1]-n[^1])), [10..199]) \\ Works for all n >= 0. - M. F. Hasler, Nov 09 2019
Formula
a(n) = 0 iff n is a repdigit >= 11 (A010785). - Bernard Schott, May 09 2022
Extensions
Definition clarified by N. J. A. Sloane, Aug 19 2008
Name edited by M. F. Hasler, Nov 09 2019
Terms a(0) = a(1) = ... = a(9) = 0 prepended by Max Alekseyev, Jul 26 2024
Comments