OFFSET
0,2
COMMENTS
The walks counted are all those directly along and x, y or z axes, and all walks whose final (x,y,z) lattice point is a solution to the Pythagorean quadruple x^2 + y^2 + z^2 = t^2. The first such solution with all coordinates > 0 is 1^2 + 2^2 + 2^2 = 3^2, which explains the large increase in the number of walks from a(4) to a(5).
LINKS
EXAMPLE
a(3) = 30 as, in the first octant, there is one 3-step SAW whose end-to-end distance is an integer (1 unit):
.
X---.
|
X---.
.
This can be walked in 24 different ways on a 3D cubic lattice. There are also the six walks directly along the x, y and z axes, giving a total of 24 + 6 = 30 walks.
CROSSREFS
KEYWORD
nonn,walk,more
AUTHOR
Scott R. Shannon, Jan 12 2023
STATUS
approved