%I #114 Jan 31 2022 03:14:52
%S 1,7,97,4111,532269,212372937,263708907211,1013068026356375,
%T 11955420069208095719,432101605951906251627393,
%U 47778407166747833830058004149,16149888968763663448192636077980753,16675786862526496319891707194153887550751,52568166380872328447478940416604864445574575709
%N Number of self-avoiding closed paths on an n X n grid which pass through NW corner.
%F a(n) = A333439(n) - 1 for n > 1.
%e a(2) = 1;
%e +--*
%e | |
%e *--*
%e a(3) = 7;
%e +--* +--*--* +--*--* +--*
%e | | | | | | | |
%e *--* *--*--* * * * *
%e | | | |
%e *--*--* *--*
%e +--*--* +--*--* +--*
%e | | | | | |
%e * *--* *--* * * *--*
%e | | | | | |
%e *--* *--* *--*--*
%o (Python)
%o # Using graphillion
%o from graphillion import GraphSet
%o import graphillion.tutorial as tl
%o def A333246(n):
%o universe = tl.grid(n - 1, n - 1)
%o GraphSet.set_universe(universe)
%o cycles = GraphSet.cycles().including(1)
%o return cycles.len()
%o print([A333246(n) for n in range(2, 10)])
%Y Cf. A140517, A333247, A333323, A333438, A333439, A333466.
%K nonn
%O 2,2
%A _Seiichi Manyama_, Mar 23 2020
%E a(11), a(13) from _Seiichi Manyama_, Apr 07 2020
%E a(10), a(12), a(14)-a(15) from _Andrew Howroyd_, Jan 30 2022