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-4 of 4 results.

A334318 Number T(n,k) of integers in base n having exactly k distinct digits such that the number formed by the consecutive subsequence of the initial j digits is divisible by j for all j in {1,...,k}; triangle T(n,k), n>=1, 1<=k<=n, read by rows.

Original entry on oeis.org

1, 2, 1, 3, 1, 0, 4, 5, 5, 2, 5, 6, 6, 1, 0, 6, 13, 18, 8, 7, 2, 7, 15, 33, 34, 16, 7, 0, 8, 25, 50, 58, 52, 21, 8, 3, 9, 28, 67, 98, 101, 57, 30, 7, 0, 10, 41, 115, 168, 220, 88, 51, 9, 4, 1, 11, 45, 134, 275, 398, 315, 220, 126, 32, 10, 0, 12, 61, 206, 428, 690, 568, 503, 158, 32, 5, 1, 0
Offset: 1

Views

Author

Alois P. Heinz, Apr 22 2020

Keywords

Examples

			T(4,3) = 5: 102, 120, 201, 123, 321 (written in base 4):
T(7,2) = 15: 13, 15, 20, 24, 26, 31, 35, 40, 42, 46, 51, 53, 60, 62, 64 (written in base 7)
T(10,1) = 10: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9.
T(10,10) = 1: 3816547290.
Triangle T(n,k) begins:
   1;
   2,  1;
   3,  1,   0;
   4,  5,   5,   2;
   5,  6,   6,   1,   0;
   6, 13,  18,   8,   7,   2;
   7, 15,  33,  34,  16,   7,   0;
   8, 25,  50,  58,  52,  21,   8,   3;
   9, 28,  67,  98, 101,  57,  30,   7,  0;
  10, 41, 115, 168, 220,  88,  51,   9,  4,  1;
  11, 45, 134, 275, 398, 315, 220, 126, 32, 10, 0;
  12, 61, 206, 428, 690, 568, 503, 158, 32,  5, 1, 0;
  ...
		

Crossrefs

Columns k=1-4 give: A000027, A334320, A333405, A333469.
Row sums give A334319.
Bisection of main diagonal (even part) gives A181736.
Cf. A111456.

Programs

  • Maple
    b:= proc(n, s, w) option remember; `if`(s={}, 0, (k-> add((t->
          `if`(t=0, x, `if`(irem(t, k)=0, b(n, s minus {j}, t)
              +x^k, 0)))(w*n+j), j=s)))(1+n-nops(s))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=1..n))(b(n, {$0..n-1}, 0)):
    seq(T(n), n=1..14);
  • Mathematica
    b[n_, s_, w_] := b[n, s, w] = If[s == {}, 0, With[{k = 1+n-Length[s]}, Sum[With[{t = w*n + j}, If[t == 0, x, If[Mod[t, k] == 0, b[n, s ~Complement~ {j}, t] + x^k, 0]]], {j, s}]]];
    T[n_] := PadRight[CoefficientList[b[n, Range[0, n-1], 0]/x, x], n];
    Array[T, 14] // Flatten (* Jean-François Alcover, Feb 11 2021, after Alois P. Heinz *)

A181736 The number of integers in base 2n such that all digits are used exactly once (so length is 2n) and for each m<=2n the base 2n integer consisting of the first m digits is divisible by m.

Original entry on oeis.org

1, 2, 2, 3, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 1

Views

Author

Keywords

Comments

The unique base 10 number is 3816547290: so 3 is divisible by 1, 38 by 2, 381 by 3, 3816 by 4 and so on. Of course the last digit must be 0. It isn't too hard to show that there are none when the base is odd, and not too hard to show that there are none when the base is of the form 2m(2m-1), for m>1. A computer search found the unique number in base 14 and showed that there were no more up to base 28. 30=6*5 is, of course, of the form 2m(2m-1). I do not know whether there are any more.
According to the comment to A111456, no other such numbers up to base 40.

Examples

			a(1)=1 because the only number base 2 satisfying the condition is 10. a(2)=2 because the two in base 4 are 1230 and 3210.
		

Crossrefs

The numbers are listed in A111456.

A256112 Pandigitals in some base b (A061845) with an extra property: each number formed by the first i digits is divisible by i (digits in the pandigital base b) for 1 <= i <= b-1.

Original entry on oeis.org

2, 19, 75, 99, 108, 135, 228, 2102, 8525, 10535, 13685, 13710, 26075, 31835, 44790, 203367, 247215, 477543, 518703, 576495, 620343, 743823, 3850399, 6996535, 6996871, 6996920, 7375543, 8947631, 11128712, 12306056, 78473956, 89789620, 156414388, 222029284, 306600196
Offset: 1

Views

Author

Chai Wah Wu, Jun 07 2015

Keywords

Comments

A111456 is the subsequence of terms divisible by the considered base (which is the least b such b^b > a(n)).
Is it true that there are no terms for base b > 16 and b even?

Examples

			247215 = 2046513[7] (i.e., in base 7) is pandigital and 20[7] = 14 is even, 204[7] = 102 is divisible by 3, etc. up to 204651[7] = 35316 which is divisible by 6.
In contrast to A111456, the number as a whole does not need to be divisible by the considered base. - _M. F. Hasler_, May 27 2020
		

Crossrefs

Cf. A111456.

Programs

  • Python
    def dgen(n,b):
        if n == 1:
            t = list(range(b))
            for i in range(1,b):
                u = list(t)
                u.remove(i)
                yield i, u
        else:
            for d, v in dgen(n-1,b):
                for g in v:
                    k = d*b+g
                    if not k % n:
                        u = list(v)
                        u.remove(g)
                        yield k, u
    A256112_list = lambda n: [a*k+b[0] for k in range(2, n) for a, b in dgen(k-1, k)]
    print(A256112_list(10))

Extensions

Edited by M. F. Hasler, May 27 2020

A324016 N-digit substring of 81654327 taken from the left.

Original entry on oeis.org

8, 81, 816, 8165, 81654, 816543, 8165432, 81654327
Offset: 1

Views

Author

Seiichi Manyama, Sep 01 2019

Keywords

Comments

A sequence q of length k is strictly pandigital if it is a permutation of {1,2,...,k}. Consider a strictly pandigital sequence q such that Sum_{i=1..m} 10^(m - i) * q_i is a multiple of m+1 for all 1 <= m <= k. Except for 21 and 81654327, there is no such sequence for k <= 30.

Examples

			8        = 2 * 4.
81       = 3 * 27.
816      = 4 * 204.
8165     = 5 * 1633.
81654    = 6 * 13609.
816543   = 7 * 116649.
8165432  = 8 * 1020679.
81654327 = 9 * 9072703.
		

Crossrefs

Showing 1-4 of 4 results.