The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A337519 Length of the shortest walk in an n X n grid graph that starts in one corner and visits every edge. 1
4, 15, 28, 47, 68, 95, 124, 159, 196, 239, 284, 335, 388, 447, 508, 575, 644, 719, 796, 879, 964, 1055, 1148, 1247, 1348, 1455, 1564, 1679, 1796, 1919, 2044, 2175, 2308, 2447, 2588, 2735, 2884, 3039, 3196, 3359, 3524, 3695, 3868, 4047, 4228, 4415, 4604, 4799, 4996 (list; graph; refs; listen; history; text; internal format)
OFFSET
2,1
COMMENTS
Nodes and edges can be revisited.
LINKS
Dmitry Kamenetsky, A robot visiting every edge of a 3x3 grid, Puzzling StackExchange, August 2020.
Dmitry Kamenetsky, A robot visiting every edge of a 4x4 grid, Puzzling StackExchange, August 2020.
Wikipedia, Eulerian Path.
FORMULA
When n is even, a(n) = A332044(n) = 2*n^2 - 4, otherwise a(n) = A332044(n) - 1 = 2*n^2 - 3.
From Stefano Spezia, Sep 18 2020: (Start)
G.f.: (-4 + 7*x + 6*x^2 - x^3)/((1 - x)^3*(1 + x)).
a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4) for n > 5. (End)
EXAMPLE
See examples in links.
CROSSREFS
Cf. A332044.
Sequence in context: A030553 A304567 A154493 * A031012 A349428 A188075
KEYWORD
nonn,easy
AUTHOR
Dmitry Kamenetsky, Aug 30 2020
EXTENSIONS
More terms from Stefano Spezia, Sep 18 2020
STATUS
approved

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 June 8 09:36 EDT 2024. Contains 373217 sequences. (Running on oeis4.)