To identify potentially interesting models, we have applied a similar search procedure as Bacher, Kauers, and Yatchak [1] did in their search for interesting models in 3D. The procedure can be summarized as follows:
Only Step Sets \(S\subseteq \{-1,0,1\}^4\setminus \{(0,0,0,0)\}\) with \(|S|\le 7\) or \(|S|\ge 73\) Were Considered
This restriction has no combinatorial motivation, but was only made to reduce the computational cost to a manageable amount, similar as it was done in [5, 8] for 3D. Note that the number
$$\begin{aligned} \sum _{k=0}^7\left( {\begin{array}{c}3^4-1\\ k\end{array}}\right) +\sum _{k=73}^{80}\left( {\begin{array}{c}3^4-1\\ k\end{array}}\right) =7005847194\approx 7\cdot 10^9 \end{aligned}$$
of remaining models is still quite big (though of course much smaller than \(2^{3^4-1}\approx 1.2\cdot 10^{24}\)).
Step Sets Containing Unused Steps were Discarded
Recall from [5] that an element s of S is called unused if it cannot appear in any walk of the model. For example, the step set \(S=\{(1,0,-1,0),(0,1,0,-1),(1,1,0,0)\}\) leads to the same generating function as the step set \(\{(1,1,0,0)\}\), because any use of \((1,0,-1,0)\) or \((0,1,0,-1)\) would lead the walk out of \({\mathbb {N}}^4\), which is not allowed.
To check whether a given step set \(S\subseteq \{-1,0,1\}^D\) contains unused steps, we successively determine the ‘not unused’ steps, i.e., the steps which can occur in a walk. We start with the elements of the step set that belong to \(\{0,1\}^D\). Any of these steps can be the first step of a walk in the model, and every walk in the model must start with one of these steps. The walks built only from these steps can proceed arbitrarily far into a certain direction \(d\in \{1,\dots ,D\}\) for which there is a step \((s_1,\dots ,s_D)\in S\cap \{0,1\}^D\) with \(s_d=1\). Set \(u_d=\mathrm {true}\) for these d and \(u_d=\mathrm {false}\) for all other d. We can next recognize all steps of S as ‘not unused’ which only have negative entries in coordinate d for which \(u_d\) is true. For example, if \(u_1\) is \(\mathrm {true}\), then \((-1,1,0,0)\) is not an unused step. For \(i=1,\dots ,D\), we update \(u_d\) to true if any of these additional steps has a positive dth coordinate. With the updated values of \(u_1,\dots ,u_D\), we can check whether further elements of S can be recognized as ‘not unused’. If so, we update \(u_1,\dots ,u_D\) again. We repeat the process until the step of recognized ‘not unused’ steps is saturated. The step set S contains unused steps if and only if the set of recognized ‘not unused’ steps is a proper subset of S.
Only One Step Set from Each Symmetry Class was Considered
Permuting the coordinates of the steps in a step set amounts to permuting the variables of the corresponding generating function. For example, if \(f(x_1,x_2,x_3,x_4,t)\) is the generating function of the model with step set \(\{(1,0,1,1),(-1,1,0,0),\) \((0,0,0,1)\}\), then \(f(x_2,x_4,x_1,x_3,t)\) is the generating function for the model with step set \(\{(0,1,1,1),(1,0,-1,0),\) \((0,1,0,0)\}\). Since permutation of variables preserves algebraicity and D-finiteness, it suffices to consider one model per equivalence class. This filter reduces the number of cases to be considered by roughly a factor of \(D!=24\).
For deciding whether two step sets \(\{s_1,\dots ,s_m\},\{s_1',\dots ,\)\(s_m'\}\subseteq \{-1,0,1\}^D\) are equivalent, we need to decide whether there is a permutation \(\pi \in S_D\), such that \(\{s_1,\dots ,s_m\}=\{\pi \cdot s_1',\dots ,\pi \cdot s_m'\}\), where \(\pi \cdot s_i'\) denotes the tuple obtained from \(s_i'\) by permuting its coordinates according to \(\pi \). Since D is small, we can simply test this by trying out all \(\pi \in S_D\). However, what we really need is not a method for checking whether two given step sets are equivalent: rather, when we go through all the step sets, we are rather in the situation that we have a single step set at hand and have to decide whether we should consider it or not. We do this by defining a total order on the step sets and rejecting a step set \(\{s_1,\dots ,s_m\}\) whenever there is a \(\pi \in S_D\), such that \(\{\pi \cdot s_1,\dots ,\pi \cdot s_m\}\) is smaller in the chosen order.
Step Sets Admitting a Hadamard Decomposition Were Discarded
Recall from [5] that a step set \(S\subseteq \{-1,0,1\}^D\) is said to admit a d-Hadamard decomposition for some \(d\in \{1,\dots ,D-1\}\) if it can be written as \(S=(V\times \{0\}^{D-d})\cup (U\times W)\) with \(V,U\subseteq {\mathbb {Z}}^{d}\) and \(W\subseteq {\mathbb {Z}}^{D-d}\setminus \{0\}\). If this is the case, the generating function for the lattice walk model for S can be expressed in terms of the Hadamard product of the generating functions associated with the lower dimensional models corresponding to W and a model with step set \((U\times \{0\})\cup (V\times \{1\})\). As the D-finiteness of models admitting a Hadamard decomposition can be easily explained (see the explanation in Sect. 5 of [5] for details), we discard them from consideration.
It is easy to decide whether a given step set S is d-Hadamard. Write \(\pi _1:{\mathbb {R}}^D\rightarrow {\mathbb {R}}^d\) for the projection on the first d coordinates and \(\pi _2:{\mathbb {R}}^D\rightarrow {\mathbb {R}}^{D-d}\) for the projection to the last \(D-d\) coordinates. Set \(V = \{s\in S:\pi _2(s)=0\}\), \(U = \pi _1(S\setminus V)\), \(W=\pi _2(S\setminus V)\) and check whether \(S=(V\times \{0\}^{D-d})\cup (U\times W)\). We need to observe however that the definition of Hadamard decomposition as quoted implicitly assumes a particular ordering of the coordinates. For example, while
$$\begin{aligned}&\{(1,0,0),(-1,0,0)\}\cup (\{-1,1\}\times \{(1,-1)\})\\&\quad =\{(1,0,0),(-1,0,0),(-1,1,-1),(1,1,-1)\} \end{aligned}$$
is 1-Hadamard, the equivalent step set \(\{(0,1,0),(0,-1,0),\)\((1,-1,-1),(1,1,-1)\}\) strictly speaking is not. Our program filters out all step sets which by a suitable permutation of coordinates can be mapped to a Hadamard model. It does so by simply carrying out the test sketched above for all elements in the orbit of the step set under consideration.
Step Sets with Dimension Less than Four Were Discarded
Recall from [5] that the dimension of a model is defined as the number of coordinates for which the non-negativity restriction is not redundant. For example, for the step set \(\{(1,1,1),(1,-1,0),(1,0,-1)\}\), the number of walks in \({\mathbb {N}}^3\) is the same as the number of walks in \({\mathbb {Z}}\times {\mathbb {N}}^2\), because there is no way to get a negative first coordinate with the available steps. As the restriction on the other two coordinates is essential, the dimension is 2 in this case. Since lattice walk models in \({\mathbb {N}}^4\) whose dimension is less than 4 are equivalent to models in \({\mathbb {N}}^3\) (possibly with multiple steps), it is fair to discard them.
Whether a given step set \(S=\{s_1,\dots ,s_m\}\subseteq \{-1,0,1\}^D\) has dimension less than D can be found out by linear programming. Writing \(s_{i,j}\) for the ith coordinate of the jth step, the requirement is that there is some \(i\in \{1,\dots ,D\}\), such that for all non-negative \(x_1,\dots ,x_m\in {\mathbb {R}}\) with \(\sum _{j=1}^m s_{k,j}x_j\ge 0\) for all \(k\ne i\), we also have \(\sum _{j=1}^m s_{i,j}x_j\ge 0\). Linear programming allows us to find the minimum value assumed by \(\sum _{j=1}^m s_{i,j}x_j\) when \(x_1,\dots ,x_m\) ranges over all non-negative real numbers with \(\sum _{j=1}^m s_{k,j}x_j\ge 0\) for all \(k\ne i\). If the minimum is 0, then the ith coordinate is redundant, and the model has dimension less than D and can be discarded. If none of the coordinates is recognized as redundant in this way, then the model has dimension D.
Step Sets Whose Associated Group Has More than 800 Elements Were Discarded
Recall from [5, 11] that to every model of maximal dimension, we can associate a certain group. Given a step set \(S\subseteq \{-1,0,1\}^D\setminus \{(0,\dots ,0)\}\), the group is constructed as follows. First, define the step set polynomial:
$$\begin{aligned} P_S:=\sum _{(s_1,\dots ,s_D)\in S} x_1^{s_1}\cdots x_D^{s_D} \end{aligned}$$
(also called the inventory by some authors). Then, for \(i=1,\dots ,D\), let \(\Phi _i\) be the rational map that sends \(x_j\) to itself for \(j\ne i\) and \(x_i\) to \(x_i^{-1}\frac{[x_i^{-1}]P_S}{[x_i]P_S}\), where \([x_i^{\pm 1}]P_S\) refers to the coefficient of \(x_i^{\pm 1}\) in \(P_S\) when \(P_S\) is viewed as a Laurent polynomial in \(x_i\) whose coefficients are Laurent polynomials in the remaining variables. The group associated to S is the group generated by \(\Phi _1,\dots ,\Phi _D\) under composition.
For example, for \(S=\{(-1,-1),(1,-1),(1,0),(-1,1), (1,1)\}\), we have \(P_S=x_1^{-1}x_2^{-1} + x_1x_2^{-1} + x_1 + x_1^{-1}x_2 + x_1x_2\) and get:
$$\begin{aligned}&\Phi _1 = \begin{pmatrix} x_1\\ x_2 \end{pmatrix}\mapsto \begin{pmatrix} x_1^{-1}\frac{x_2+x_2^{-1}}{x_2+1+x_2^{-1}} \\ x_2 \end{pmatrix}\qquad \text {and}\\&\Phi _2 = \begin{pmatrix} x_1\\ x_2 \end{pmatrix}\mapsto \begin{pmatrix} x_1 \\ x_2^{-1} \end{pmatrix}, \end{aligned}$$
and the group \(\langle \Phi _1,\Phi _2\rangle \) turns out to have only four elements: \(\mathrm {id},\Phi _1,\Phi _2\) and \(\Phi _1\circ \Phi _2\).
A main result about the case \(D=2\) is that for full-dimensional models, this group is finite if and only if the generating function is D-finite [5, 7, 11]. While the experimental results for \(D=3\) suggest that there may be non-D-finite cases with finite group, we are not aware of any (conjectured) D-finite case with an infinite group. For this reason, and also because a finite group gives the chance to apply the so-called orbit sum method for proving D-finiteness, we have decided to restrict the search to models with finite group.
Certain sufficient conditions have been used in 2D and 3D for proving that the groups for certain models are infinite [11, 14]. However, checking these conditions is expensive, and, as they are just sufficient but not necessary, carrying out these expensive calculations may not be conclusive. We have chosen a more pragmatic approach. Starting from \(H=\{\mathrm {id}\}\), we set \(H \leftarrow H \cup \bigcup _{i=1}^D \{\Phi _i\circ h:h\in H\}\) until either H stabilizes (then H is equal to the full group and the group is finite), or the size of H exceeds 800 (then we give up and discard the model). The bound 800 was chosen as a compromise between reasonable computing time and reasonable confidence that larger groups are in fact infinite.