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.

A337016 a(0) = 0. Successive terms are double the previous, then with their digits incremented by 1.

This page as a plain text file.
%I A337016 #35 Dec 21 2020 18:11:04
%S A337016 0,1,3,7,25,61,233,577,2265,5641,22393,55897,2228105,5567321,22245753,
%T A337016 555102617,2221316345,55537437101,222185985313,5554821081737,
%U A337016 222110753274585,5553326176510281,22217763464131673,555466371039374457,222110438531898591025
%N A337016 a(0) = 0. Successive terms are double the previous, then with their digits incremented by 1.
%C A337016 If 9 appears anywhere in the decimal expansion of 2*a(n-1), we replace that digit with 10 upon incrementing by 1. See a(12) of the Examples section and A216556 for more information.
%F A337016 a(n) = A216556(2*a(n-1)), a(0) = 0.
%e A337016 To calculate a(12), double 55897 to get 111794, then increment the digits by 1 to get 2228105.
%e A337016 To calculate a(13), double 2228105 to get 4456210, then increment the digits by 1 to get 5567321.
%p A337016 a:= proc(n) option remember; `if`(n=0, 0, (l-> parse(cat(seq(
%p A337016       l[-i]+1, i=1..nops(l)))))(convert(2*a(n-1), base, 10)))
%p A337016     end:
%p A337016 seq(a(n), n=0..25);  # _Alois P. Heinz_, Dec 12 2020
%t A337016 NestList[FromDigits[Flatten@ Map[IntegerDigits, IntegerDigits[2 #] + 1]] &, 0, 24] (* _Michael De Vlieger_, Dec 11 2020 *)
%o A337016 (PARI) digs(n) = if (n==0, [0], digits(n));
%o A337016 lista(nn) = {a = 0; print1(a, ", "); for (n=1, nn, a = eval(concat(apply(t->Str(t+1), digs(2*a)))); print1(a, ", "););} \\ _Michel Marcus_, Nov 28 2020
%Y A337016 Cf. A000079, A061511, A089718.
%K A337016 base,nonn
%O A337016 0,3
%A A337016 _Jamie Robert Creasey_, Nov 21 2020