login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A338532 Number of spanning trees in the n X 3 king graph. 2

%I #69 Dec 04 2020 12:01:02

%S 1,192,17745,1612127,146356224,13286470095,1206167003329,

%T 109497763028928,9940381426772625,902403667119137183,

%U 81921642989758089216,7436977302591050167695,675140651246077550931841,61290344237862763973468352,5564035123440571957929508305,505111975464406109413779799007

%N Number of spanning trees in the n X 3 king graph.

%H Seiichi Manyama, <a href="/A338532/b338532.txt">Table of n, a(n) for n = 1..500</a>

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/KingGraph.html">King Graph</a>

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/SpanningTree.html">Spanning Tree</a>

%F Empirical g.f.: x*(-15*x^3 - 111*x^2 + 97*x + 1) / (x^4 - 95*x^3 + 384*x^2 - 95*x + 1). - _Vaclav Kotesovec_, Dec 04 2020

%o (Python)

%o # Using graphillion

%o from graphillion import GraphSet

%o def make_nXk_king_graph(n, k):

%o grids = []

%o for i in range(1, k + 1):

%o for j in range(1, n):

%o grids.append((i + (j - 1) * k, i + j * k))

%o if i < k:

%o grids.append((i + (j - 1) * k, i + j * k + 1))

%o if i > 1:

%o grids.append((i + (j - 1) * k, i + j * k - 1))

%o for i in range(1, k * n, k):

%o for j in range(1, k):

%o grids.append((i + j - 1, i + j))

%o return grids

%o def A338029(n, k):

%o if n == 1 or k == 1: return 1

%o universe = make_nXk_king_graph(n, k)

%o GraphSet.set_universe(universe)

%o spanning_trees = GraphSet.trees(is_spanning=True)

%o return spanning_trees.len()

%o def A338532(n):

%o return A338029(n, 3)

%o print([A338532(n) for n in range(1, 20)])

%Y Column 3 of A338029.

%Y Cf. A006238.

%K nonn

%O 1,2

%A _Seiichi Manyama_, Nov 29 2020

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 30 19:58 EDT 2024. Contains 372141 sequences. (Running on oeis4.)