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.

A339960 Number of Hamiltonian circuits within parallelograms of size 8 X n on the triangular lattice.

Original entry on oeis.org

1, 1676, 183521, 20842802, 3061629439, 418172485806, 56203566442908, 7621726574570613, 1033232532941136255, 139934009951521872490, 18955155770535463735959, 2567688102114635009977537, 347811042296785583958285788, 47113523803568895604053871759, 6381875340326645360658645942215
Offset: 2

Views

Author

Seiichi Manyama, Dec 25 2020

Keywords

Crossrefs

Row 8 of A339849.
Cf. A145418.

Programs

  • Python
    # Using graphillion
    from graphillion import GraphSet
    def make_T_nk(n, k):
        grids = []
        for i in range(1, k + 1):
            for j in range(1, n):
                grids.append((i + (j - 1) * k, i + j * k))
                if i < k:
                    grids.append((i + (j - 1) * k, i + j * k + 1))
        for i in range(1, k * n, k):
            for j in range(1, k):
                grids.append((i + j - 1, i + j))
        return grids
    def A339849(n, k):
        universe = make_T_nk(n, k)
        GraphSet.set_universe(universe)
        cycles = GraphSet.cycles(is_hamilton=True)
        return cycles.len()
    def A339960(n):
        return A339849(8, n)
    print([A339960(n) for n in range(2, 8)])