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

A348648 Triangle T(n, k), n >= 0, 0 <= k <= n, read by rows; the even terms of Pascal's triangle (A007318) are clustered as wXwXw subtriangles with w = 2^s-1 for some s > 0; if A007318(n, k) is even then T(n, k) gives the corresponding s otherwise T(n, k) = 0.

Original entry on oeis.org

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

Views

Author

Rémy Sigrist, Oct 27 2021

Keywords

Comments

It is possible to build this triangle with the following procedure:
- T_0 is the 2X2X2 triangle with all 0's:
^
T_0 = /0\
/0 0\
+-----+
- for s > 0, T_s is obtained by arranging 3 copies of T_{s-1} and one wXwXw triangle (where w=2^s-1) will all s's as follows:
^
/ \
/ \
/ \
/T_{s-1}\
T_s = +---------+
/ \s ... s/ \
/ \. ./ \
/ \. ./ \
/T_{s-1}\s/T_{s-1}\
+---------+---------+
- the triangle {T(n, k)} is the limit of T_s as s tends to infinity.
For any n >= 0, A001316(n) gives the number of 1's in row 4*n + 2 (and there are no 1's elsewhere).

Examples

			Triangle T(n, k) begins (with dots instead of 0's):
                    .
                   . .
                  . 1 .
                 . . . .
                . 2 2 2 .
               . . 2 2 . .
              . 1 . 2 . 1 .
             . . . . . . . .
            . 3 3 3 3 3 3 3 .
           . . 3 3 3 3 3 3 . .
          . 1 . 3 3 3 3 3 . 1 .
         . . . . 3 3 3 3 . . . .
        . 2 2 2 . 3 3 3 . 2 2 2 .
       . . 2 2 . . 3 3 . . 2 2 . .
      . 1 . 2 . 1 . 3 . 1 . 2 . 1 .
     . . . . . . . . . . . . . . . .
		

Crossrefs

Programs

  • PARI
    T(n,k) = { if (n<=1, return (0)); my (s=#binary(n)-1); n-=2^s; if (k<=n, return (T(n,k)), k<2^s, return (s), return (T(n,k-2^s))) }

Formula

T(n, k) = 0 iff A047999(n, k) = 1.
2^T(n, 0) OR 2^T(n, 1) OR ... OR 2^T(n, n) = 1 + A129760(n+1) (where OR denotes the bitwise OR operator).

A348649 Odd numbers in the triangle of Stirling numbers of the second kind (A008277).

Original entry on oeis.org

1, 1, 1, 1, 3, 1, 1, 7, 1, 1, 15, 25, 1, 1, 31, 65, 15, 1, 1, 63, 301, 21, 1, 1, 127, 1701, 1, 1, 255, 3025, 6951, 1, 1, 511, 34105, 42525, 22827, 45, 1, 1, 1023, 28501, 179487, 63987, 1155, 55, 1, 1, 2047, 611501, 159027, 22275, 1705, 1, 1, 4095, 261625, 7508501, 39325, 2431, 1
Offset: 1

Views

Author

Rémy Sigrist, Oct 27 2021

Keywords

Comments

We take the odd values in A008277, as they appear, with duplicates.
For any n >= 1, the n-th row has A007306(n) terms.

Examples

			As an irregular table, the first rows are:
     1:    1;
     2:    1, 1;
     3:    1, 3, 1;
     4:    1, 7, 1;
     5:    1, 15, 25, 1;
     6:    1, 31, 65, 15, 1;
     7:    1, 63, 301, 21, 1;
     8:    1, 127, 1701, 1;
     9:    1, 255, 3025, 6951, 1;
    10:    1, 511, 34105, 42525, 22827, 45, 1;
    11:    1, 1023, 28501, 179487, 63987, 1155, 55, 1;
    ...
		

Crossrefs

See A014421, A014428, A014450, A014459 for similar sequences.
Cf. A007306, A008277, A348650 (even numbers).

Programs

  • PARI
    row(n) = select(v -> v%2==1, vector(n, k, stirling(n, k, 2)))

A014727 Squares of even elements in Pascal's triangle A007318.

Original entry on oeis.org

4, 16, 36, 16, 100, 100, 36, 400, 36, 64, 784, 3136, 4900, 3136, 784, 64, 1296, 7056, 15876, 15876, 7056, 1296, 100, 14400, 44100, 63504, 44100, 14400, 100, 108900, 213444, 213444, 108900, 144, 4356, 48400, 627264, 853776, 627264, 48400, 4356
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    Select[Flatten[Table[Binomial[n,k],{n,0,20},{k,0,n}]],EvenQ]^2 (* Harvey P. Dale, Apr 18 2020 *)

Formula

a(n) = A014428(n)^2. - Sean A. Irvine, Nov 18 2018

Extensions

More terms from Andrew J. Gacek (andrew(AT)dgi.net)
Showing 1-3 of 3 results.