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.

Showing 1-2 of 2 results.

A260263 a(n+1) = a(n) + largest digit not in a(n), starting with a(1) = 1.

Original entry on oeis.org

1, 10, 19, 27, 36, 45, 54, 63, 72, 81, 90, 98, 105, 114, 123, 132, 141, 150, 159, 167, 176, 185, 194, 202, 211, 220, 229, 237, 246, 255, 264, 273, 282, 291, 299, 307, 316, 325, 334, 343, 352, 361, 370, 379, 387, 396, 404, 413, 422, 431, 440, 449, 457, 466, 475
Offset: 1

Views

Author

Eric Angelini and M. F. Hasler, Jul 21 2015

Keywords

Comments

From a(16173532) = 123456798 on, the sequence becomes constant.
From a(324) = 2796 + 8 = 2804 on, this sequence becomes equal to sequence A260264, which has the same definition except for starting with a(0)=0.
a(10^k): 1, 81, 870, 8598, 84284, 823330, 8010205, 77737463. - Robert G. Wilson v, Jul 21 2015

Crossrefs

Cf. A045844.

Programs

  • Maple
    a[1]:= 1:
    for n from 2 to 100 do
      a[n]:= a[n-1] + max({$1..9} minus convert(convert(a[n-1],base,10),set));
    od:
    seq(a[n],n=1..100); # Robert Israel, Jul 22 2015
  • Mathematica
    a[n_] := a[n] = a[n - 1] + Max[ Complement[ Range[9], IntegerDigits[ a[n - 1]] ]]; a[1] = 1; Array[a, 55] (* Robert G. Wilson v, Jul 21 2015 *)
  • PARI
    {a=1;d=vector(9,d,d);for(n=1,100,print1(a",");a+=vecmax(setminus(d,Set(digits(a)))))}

A260351 In base n, a(n) is the largest (decimal equivalent) number reached when one sequentially adds to a sum, starting with zero, the largest digit not in that sum.

Original entry on oeis.org

1, 5, 30, 214, 1865, 22881, 342447, 6053444, 123456798, 2853116815, 73686782411, 2103299351346, 65751519678065, 2234152501943369, 81985529216487165, 3231407272993503256, 136146740744970718253, 6106233505124424781971, 290464265927977839351196
Offset: 2

Views

Author

Hans Havermann, Jul 23 2015

Keywords

Examples

			In base 4:
0 + 3 = 3 (= 3)
3 + 2 = 5 (= 11)
5 + 3 = 8 (= 20)
8 + 3 = 11 (= 23)
11 + 1 = 12 (= 30)
12 + 2 = 14 (= 32)
14 + 1 = 15 (= 33)
15 + 2 = 17 (= 101)
17 + 3 = 20 (= 110)
20 + 3 = 23 (= 113)
23 + 2 = 25 (= 121)
25 + 3 = 28 (= 130)
28 + 2 = 30 (= 132)
30 + 0 = 30 (repeat, therefore a(4) = 30)
		

Crossrefs

Programs

  • Mathematica
    Table[r=Range[0, b-1]; s=0; t=1; While[t!=0, t=Complement[r, IntegerDigits[s, b]][[-1]]; s=s+t]; s, {b, 2, 8}]
  • Python
    from gmpy2 import digits
    def A260351(n):
        r, c = set([digits(d,n) for d in range(n)]), 0
        dc = set(digits(c,n))
        while len(dc) < n-1 or '0' in dc:
            c += max([int(d,n) for d in r - dc])
            dc = set(digits(c,n))
        return c # Chai Wah Wu, Jul 24 2015

Extensions

a(13) from Giovanni Resta, Jul 23 2015
a(14) from Giovanni Resta, Jul 24 2015
a(15)-a(20) from Hiroaki Yamanouchi, Aug 01 2015
Showing 1-2 of 2 results.