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.

A333652 Triangle T(n,k), n >= 2, 0 <= k <= floor(n^2/2)-n, read by rows, where T(n,k) is the number of 2*(k+n)-cycles in the n X n grid graph which pass through NW and SW corners.

Original entry on oeis.org

1, 1, 3, 1, 6, 17, 17, 6, 1, 10, 45, 167, 404, 570, 460, 186, 1, 15, 100, 506, 2164, 7726, 20483, 39401, 56015, 57632, 37450, 10340, 1072, 1, 21, 196, 1316, 7066, 33983, 147377, 546400, 1656592, 4099732, 8394433, 14227675, 19443270, 20239262, 14767415, 7007270, 1926990, 230440
Offset: 2

Views

Author

Seiichi Manyama, Apr 01 2020

Keywords

Examples

			T(3,0) = 1;
   +--*
   |  |
   *  *
   |  |
   +--*
T(3,1) = 3;
   +--*--*   +--*--*   +--*
   |     |   |     |   |  |
   *     *   *  *--*   *  *--*
   |     |   |  |      |     |
   +--*--*   +--*      +--*--*
Triangle starts:
====================================================================
n\k| 0   1    2     3      4 ...      7 ...  12 ...    17 ...    24
---|----------------------------------------------------------------
2  | 1;
3  | 1,  3;
4  | 1,  6,  17,   17,     6;
5  | 1, 10,  45,  167,   404, ... , 186;
6  | 1, 15, 100,  506,  2164, .......... , 1072;
7  | 1, 21, 196, 1316,  7066, .................. , 230440;
8  | 1, 28, 350, 3038, 20317, ............................ , 4638576;
		

Crossrefs

Programs

  • Python
    # Using graphillion
    from graphillion import GraphSet
    import graphillion.tutorial as tl
    def A333652(n):
        universe = tl.grid(n - 1, n - 1)
        GraphSet.set_universe(universe)
        cycles = GraphSet.cycles().including(1).including(n)
        return [cycles.len(2 * k).len() for k in range(n, n * n // 2 + 1)]
    print([i for n in range(2, 8) for i in A333652(n)])

Formula

T(n,0) = 1.
T(n,1) = A000217(n-1) for n > 2.

A333667 Triangle T(n,k), n >= 2, 0 <= k <= floor(n^2/2)-2*n+2, read by rows, where T(n,k) is the number of 2*(k+2*n-2)-cycles in the n X n grid graph which pass through NW and SE corners ((0,0),(n-1,n-1)).

Original entry on oeis.org

1, 3, 20, 16, 6, 175, 420, 562, 456, 186, 1764, 8064, 21224, 39500, 55376, 57248, 37586, 10260, 1072, 19404, 138600, 569768, 1717152, 4151965, 8371428, 14126846, 19364732, 20241450, 14759356, 6998166, 1927724, 230440
Offset: 2

Views

Author

Seiichi Manyama, Apr 01 2020

Keywords

Examples

			T(3,0) = 3;
   +--*--*   +--*--*   +--*
   |     |   |     |   |  |
   *--*  *   *     *   *  *--*
      |  |   |     |   |     |
      *--+   *--*--+   *--*--+
Triangle starts:
=======================================================================
n\k|      0        1         2 ...      4 ...   8 ...    12 ...     18
---|-------------------------------------------------------------------
2  |      1;
3  |      3;
4  |     20,      16,        6;
5  |    175,     420,      562, ... , 186;
6  |   1764,    8064,    21224, .......... , 1072;
7  |  19404,  138600,   569768, .................. , 230440;
8  | 226512, 2265120, 12922446, ............................ , 4638576;
		

Crossrefs

Row sums give A333323.

Programs

  • Python
    # Using graphillion
    from graphillion import GraphSet
    import graphillion.tutorial as tl
    def A333667(n):
        universe = tl.grid(n - 1, n - 1)
        GraphSet.set_universe(universe)
        cycles = GraphSet.cycles().including(1).including(n * n)
        return [cycles.len(2 * k).len() for k in range(2 * n - 2, n * n // 2 + 1)]
    print([i for n in range(2, 8) for i in A333667(n)])

Formula

T(n,0) = A000891(n-2).

A333668 Triangle T(n,k), n >= 2, 0 <= k <= floor(n^2/2)-2*n+2, read by rows, where T(n,k) is the number of 2*(k+2*n-2)-cycles in the n X n grid graph which pass through four corners ((0,0), (0,n-1), (n-1,n-1), (n-1,0)).

Original entry on oeis.org

1, 1, 1, 4, 6, 1, 12, 58, 156, 146, 1, 24, 244, 1416, 5435, 12976, 16654, 7108, 1072, 1, 40, 696, 7076, 47965, 236628, 873610, 2348664, 4335724, 4958224, 3407276, 1298704, 205792
Offset: 2

Views

Author

Seiichi Manyama, Apr 01 2020

Keywords

Examples

			T(4,1) = 4;
   +--*--*--+   +--*--*--+   +--*--*--+   +--*  *--+
   |        |   |        |   |        |   |  |  |  |
   *--*     *   *     *--*   *        *   *  *--*  *
      |     |   |     |      |        |   |        |
   *--*     *   *     *--*   *  *--*  *   *        *
   |        |   |        |   |  |  |  |   |        |
   +--*--*--+   +--*--*--+   +--*  *--+   +--*--*--+
Triangle starts:
=================================================================
n\k| 0   1     2      3       4 ...       8 ...    12 ...     18
---|-------------------------------------------------------------
2  | 1;
3  | 1;
4  | 1,  4,    6;
5  | 1, 12,   58,   156,    146;
6  | 1, 24,  244,  1416,   5435, ... , 1072;
7  | 1, 40,  696,  7076,  47965, ........... , 205792;
8  | 1, 60, 1590, 24960, 263770, ..................... , 4638576;
		

Crossrefs

Programs

  • Python
    # Using graphillion
    from graphillion import GraphSet
    import graphillion.tutorial as tl
    def A333668(n):
        universe = tl.grid(n - 1, n - 1)
        GraphSet.set_universe(universe)
        cycles = GraphSet.cycles()
        for i in [1, n, n * (n - 1) + 1, n * n]:
            cycles = cycles.including(i)
        return [cycles.len(2 * k).len() for k in range(2 * n - 2, n * n // 2 + 1)]
    print([i for n in range(2, 8) for i in A333668(n)])

Formula

T(n,0) = 1.
T(n,1) = A046092(n-3).
Showing 1-3 of 3 results.