1. Introduction
The necessary and sufficient conditions for the moving average representation for second-order random fields was established in [Reference Soltani15]. Since then, second-order autoregressive random (AR) fields have received special attention, and their importance in modeling spatial data has been realized by different authors. Nevertheless, in contrast to the classical autoregressive processes, the derivation of the moving average (MA) coefficients for the autoregressive random fields appears to be a challenging task, theoretically and numerically, especially for spatial dimensions
$d\geq 3$
. This work is devoted to the theoretical and numerical derivation of the moving average coefficients for first-order autoregressive random fields.
A first-order mean-zero autoregressive random field, also called spatial autoregressive (SAR(1)), on
$\mathbb{Z}^d$
, where
$\mathbb{Z}$
is the set of integers, assumes the time-domain autoregressive formulation
where
$\mathbf{I}=\big\{\mathbf{i}=(i_1,\ldots,i_d);\, i_j=0 \text{ or }1;\,\, j=1,\ldots,d;\,1 \leq \sum_{j=1}^d i_j \leq d\big\}$
, and
$\mathbf{t}=(t_1,\ldots,t_d)\in\mathbb{Z}^d$
,
$W_{\mathbf{t}},\mathbf{t}\in\mathbb{Z}^d$
, is a purely random process subject to
$E(W_{\mathbf{t}})=0$
,
$\sigma_W^2=E(W_{\mathbf{t}})^2 <\infty$
,
$\mathbf{t}\in\mathbb{Z}^d$
. Under certain conditions on the coefficients
$\beta_\mathbf{i}$
,
$\mathbf{i}\in\mathbf{I}$
, the process
$X_\mathbf{t}$
assumes the non-anticipating moving average representation
where the coefficients
$b_{\mathbf{k}}$
are real numbers subject to
$\sum_{\mathbf{k}\in \mathbb{Z}^{d++}}{b}_{\mathbf{k}}^2 <\infty$
, and
$\mathbb{Z}^{d++}=\{\mathbf{k}=(k_1,\ldots,k_d)\in\mathbb{Z}^d$
,
$k_j\geq 0$
,
$j=1,\ldots,d\}$
. For more on the moving average representation for random fields, see [Reference Soltani15].
For
$d=1$
,
$b_s=\beta^{s}$
,
$0<|\beta |<1$
. For
$d>1$
, no general formulation has been given for the MA coefficients. In this article we present a formula in closed form for the MA coefficients of SAR(1),
$d>1$
, by developing a new time-domain approach. The method is indeed a short cut. It reads the MA coefficients as the solution to a certain system of difference equations. We also develop an algorithm for the numerical derivation of the MA coefficients.
We provide certain applications, including the formulation for the autocorrelation function
$\rho (\mathbf{k})=E(X_{\mathbf{t}}X_{\mathbf{t}+\mathbf{k}})/\sigma_{X}^2$
; formulations for the forecast recipe and error in forecasting
$X_{\mathbf{t}+\mathbf{n}}$
, based on
$\{X_{\mathbf{s}},\,\mathbf{s}\leq \mathbf{t}\}$
,
$\mathbf{n}\in \mathbb{Z}^{d++}$
; and a sufficient condition for causality, namely, whether
$\sum_{\mathbf{k}\in\mathbb{Z}^{d++}}|b_\mathbf{k}| <\infty$
. Indeed the MA coefficients are the Fourier coefficients of the outer factor of the spectral density, which are absolutely summable under causality. Hence, causality ensures that the spectral density can be retained from the MA coefficients.
The literature on stationary random fields is quite rich. Following the work in [Reference Helson and Lowdenslager9] on extrapolation came the seminal works [Reference Cheng2–Reference Cheng4] on the convergence of the best linear predictor, the prediction error, and the spectral measure. Certain prediction problems for the random fields were considered in [Reference Kohli and Pourahmadi11]. Interpolation for stationary random fields is discussed in [Reference Mafakheri, Soltani and Shishebor12]. Random fields are basic probability models to explain spatial data; see [Reference Basu and Reinsel1] on spatial ARMA(1,1) models, where the parameter estimation of the model is established. For recent work on modeling random fields to spatial data, see [Reference Guo, Dias, Carvajal, Peyras and Breul7] and the references therein. For the estimation of spatial autoregressive models see [Reference Zhi, Ding, Hui, Welsh and Zou18].
See also [Reference Salehi13, Reference Soltani and Mohammadpour16, Reference Soltani and Yaghmaee17] for basic work on numerical derivations concerning stationary processes. Hilbert-space periodically correlated AR(1) processes indexed by
$\mathbb{Z}^2$
are discussed in detail in [Reference Haghbin, Shishebor and Soltani8].
This article is organized as follows. In Section 2, we provide our method for the formulation of the MA coefficients for the case of
$d=2$
. In Section 3, we develop the derivations in Section 2 to the general case
$d\geq 2$
. The forecast recipe, forecast error, autocorrelation formulation, and sufficient condition for causality are also provided in this section. In Section 4, an algorithm for numerical derivation of the MA coefficients together with graphical illustrations for the forecast error and causality are given. The article is concluded in Section 5. The corresponding Wolfram Mathematica
$^\mathrm{\circledR}$
programs are provided in the Appendix.
2. The case
$d=2$
In the following lemma, we present a new method for deriving the solutions to the recursive equations involving the MA coefficients.
Lemma 2.1. Let
$\mathbf{b}=\{b=b_{k_1,k_2},\,(k_1,k_2)\in\mathbb{Z}^{2++}\}$
,
$b_{(0,0)}=1$
,
$b_{(k_1,k_2)}=0$
for
$k_1<0$
or
$k_2<0$
, be a sequence of real numbers. Also assume that
$\alpha,\beta,\theta$
and real numbers that are not all zero. Then
$\mathbf{b}$
satisfies the system of the recursive equations
if and only if
\begin{equation} b_{k_1,k_2}c = c\sum^{\min(k_1,k_2)}_{r=0}{\frac{(k_1+k_2-r)!}{(k_1-r)!(k_2-r)!r!} {\alpha}^{k_1-r}{\beta}^{k_2-r}{\theta}^r}, \quad (k_1,k_2)\in\mathbb{Z}^{2++}. \end{equation}
A path from (0, 0) to (m, n).

Proof. Assume a point (m, n) on the lattice of integers
$\mathbb{Z}^{2++}$
, and that there is a particle that moves from (0,0) to (m, n) on
$\mathbb{Z}^{2++}$
. The direction of movement of the particle in each step is non-decreasing, i.e. the particle can move from (i, j) to either
$(i,j+1)$
(vertical),
$(i+1,\,j)$
(horizontal), or
$(i+1,j+1)$
(diagonal), as shown in Figure 1. The gain or reward for each vertical step is
$\beta$
, for the horizontal step is
$\alpha$
, and for the diagonal step is
$\theta$
. The gain is multiplicative, in the sense that for the totality of the z horizontal, v vertical, and a diagonal steps, the total gain for the particle will be
$T(z,v,a)=\alpha^z\beta^v\theta^a$
. Let
$b_{m,n}$
be the sum of all total gains that are available to the particle for going from (0,0) to (m, n) in this manner:
$b_{m,n}=\sum_{\text{possible paths}} T(z,v,a)$
. The quantity
$b_{m,n}$
is specified by either of the following two methods; the lemma follows from the equivalence of the two methods.
-
Method 1: According to the topology of Figure 1,
$b_{m,n}$
is calculated based on its values for the particle in either of the three preceding points
$(m-1,n)$
,
$(m,n-1)$
, or
$(m-1,n-1)$
. At
$(m-1,n)$
,
$b_{m-1,n}$
is the total sum, and when the particle moves from this point to (m, n), then
$\alpha b_{m-1,n}$
will be the total gain incurred by all paths from (0,0) to (m, n) passing through
$(m-1,n)$
. By applying the same reasoning to the points
$(m,n-1)$
and (m, n), it follows that
$b_{m,n}$
satisfies the recursive equation
$b_{m,n}=\alpha b_{m-1,n}+\beta b_{m,n-1}+\theta b_{m-1,n-1}$
. -
Method 2: Assume there are r diagonal steps in a path from (0,0) to (m, n). Therefore, on this path there will be
$m-r$
horizontal and
$n-r$
vertical steps. The gain for such a path is
$\alpha^{m-r}\beta^{n-r}\theta^r$
. There are paths of this sort. Thus, the sum of total possible gains is given by
\begin{align*}\frac{(m+n-r)!}{(m-r)!(n-r)!r!}\end{align*}
\[ b_{m,n} = \sum^{\min(m,n)}_{r=0}{\frac{(m+n-r)!}{(m-r)!(n-r)!r!}{\alpha}^{m-r}{\beta}^{n-r}{\theta}^r}. \]
It is clear that the values of
$b_{m,n}$
obtained in Method 1 and Method 2 are equal.
The following lemma gives insights into the MA coefficients of SAR(1) models.
Lemma 2.2. For real numbers
${\alpha}$
,
${\beta}$
, and
${\theta}$
, not all equal to zero,
\begin{equation} \frac{1}{1-\alpha Z_1-\beta Z_2-\theta Z_1Z_2} = \sum^{\infty}_{k_1=0}{\sum^{\infty}_{k_2=0}{b_{k_1,k_2}{{Z_1}^{k_1}}{{Z_2}^{k_2}}}} \end{equation}
for non-zero complex numbers
$Z_1$
and
$Z_2$
if and only if
and
$b_{0,0}=1$
and
$b_{k_1,k_2}=0$
for
$k_1<0$
or
$k_2 < 0 $
.
Proof. The result follows by equating the coefficients of
$Z_1^{k_1}Z_2^{k_2}$
on both sides of
\begin{align*} & (1-\alpha Z_1-\beta Z_2-\theta Z_1Z_2)\Bigg(\sum^{\infty}_{({k_1,k}_2)=(0,0)}{b_{k_1,k_2}{Z_1}^{k_1}{Z_2}^{k_2}}\Bigg) \\ & \qquad = \sum^{\infty}_{({k_1,k}_2)=(0,0)}{b_{k_1,k_2}{Z_1}^{k_1}{Z_2}^{k_2}} - \alpha\sum^{\infty}_{({k_1,k}_2)=(0,0)}{b_{k_1,k_2}{Z_1}^{k_1+1}{Z_2}^{k_2}} \\ & \qquad\quad - \beta\sum^{\infty}_{({k_1,k}_2)=(0,0)}{b_{k_1,k_2}{Z_1}^{k_1}{Z_2}^{k_2+1}} - \theta\sum^{\infty}_{({k_1,k}_2)=(0,0)}{b_{k_1,k_2}{Z_1}^{k_1+1}{Z_2}^{k_2+1}} \\ & \qquad = 1 - \sum^{\infty}_{({k_1,k}_2)>(0,0)}{{Z_1}^{k_1}{Z_2}^{k_2}(b_{k_1,k_2} - \alpha{b_{k_1-1,k_2}} - \beta{b_{k_1,k_2-1}} - \theta{b_{k_1-1,k_2-1}})} = 1. \end{align*}
Theorem 2.1. If a SAR(1) model given by
assumes the non-anticipating moving average representation in (1.2), then the MA coefficients are given by (2.2), where
${\alpha}$
,
${\beta}$
, and
${\theta}$
are real numbers not all equal to zero. Conversely, any spatial MA
$(\infty)$
process given in (1.2) with the MA coefficients as in (2.2) is SAR(1).
Proof. Let us begin with the representation of the SAR(1) model in (2.5). Then
where
$B_1$
and
$B_2$
are backward shift operators,
${B_1}^i{B_2}^jX_{(t_1,t_2)}=X_{(t_1-i,t_2-j)}$
. We let
$b_{k_1,k_2} =\alpha b_{k_1-1,k_2} + \beta b_{k_1,k_2-1} + \theta b_{k_1-1,k_2-1}$
, with
$k_1\geq 0$
,
$k_2\geq0$
,
$b_{0,0}=1$
, and
$b_{k_1,k_2}=0$
, for
$k_1<0$
or
$k_2<0$
. Then, by using Lemma 2.2, we obtain
\begin{equation*} X_{(t_1,t_2)} = \Bigg(\sum^{\infty}_{({k_1,k}_2)=(0,0)}{b_{k_1,k_2}{B_1}^{k_1}{B_2}^{k_2}}\Bigg){W}_{(t_1,t_2)} = \sum^{\infty}_{({k_1,k}_2)=(0,0)}{b_{k_1,k_2}{W}_{(t_1-k_1,t_2-k_2)}}. \end{equation*}
The desired result follows using Lemma 2.1.
In the following theorem we provide a sufficient condition for the causality of the SAR(1) process
$X_{(t_1,t_2)}$
in (2.5).
Theorem 2.2. Under the assumption that
the SAR(1) process in (2.5) is causal, i.e.
Proof. Clearly,
\begin{equation} \sum_{k_1\geq 0,\,k_2\geq 0}|b_{k_1,k_2}| \leq \sum_{k_1\geq 0,\,k_2\geq 0}\sum^{\min\!(k_1,k_2)}_{r=0}{\frac{(k_1+k_2-r)!}{(k_1-r)!(k_2-r)!r!} {|\alpha|}^{k_1-r}{|\beta|}^{k_2-r}{|\theta|}^r}. \end{equation}
Then, using (2.3) with
$\alpha$
,
$\beta$
, and
$\theta$
replaced by
$|\alpha|$
,
$|\beta|$
, and
$|\theta|$
, the right-hand side of (2.8) is equal to
under (2.6). The proof is complete.
Plots of
$S_{n+10}-S_n$
for
$n=80,\ldots,120$
. Left:
$\alpha=-0.6$
,
$\beta=-0.6$
,
$\theta =-0.3$
shows no evidence of causality. Right:
$\alpha=-0.4$
,
$\beta=-0.4$
,
$\theta =-0.3$
shows strong evidence of causality.

Remark 2.1. The sufficient condition for causality is given in Theorem 2.2. The ‘correct’ necessary and sufficient conditions for causality given in [Reference Shklya14] are not correct. For example, for
$\alpha=-0.6$
,
$\beta =-0.6$
,
$\theta =-0.3$
, the conditions
$1-\alpha-\beta-\theta>0$
,
$1-\alpha+\beta+\theta>0$
,
$1+\alpha-\beta+\theta>0$
, and
$1+\alpha+\beta-\theta>0$
given in [Reference Shklya14] as necessary and sufficient conditions for causality are satisfied. However, the behavior of
$S_{n+10}-S_n$
,
$n=80,\ldots,120$
, with
$S_n=\sum_{k_1=0}^n\sum_{k_2=0}^n|b_{k_1,k_2}|$
, depicted on the left in Figure 2, clearly exhibits
$S_n$
not converging as
$n\rightarrow\infty$
. For
$\alpha=-0.4$
,
$\beta=-0.4$
,
$\theta=-0.3$
, the condition in (2.6) is satisfied. Thus, by Theorem 2.2 the causality is confirmed, as exhibited on the right in Figure 2.
Visualizing
$S_n$
graphically gives a practical causality check.
Remark 2.2. In [Reference Drapatz5], it is reported from [Reference Fray and Roselle6] that for
$d=2$
,
\begin{equation*} \psi_{n,k} = \sum_{j=0}^n \binom{k}{ j}\binom{n+k-j}{ k}\phi_1^{n-j}\phi_2^{k-j}\phi_3^j, \quad n,k\in\mathbb{N}_0, \end{equation*}
where
$\psi_{n,k}$
are the MA coefficients and
$\phi_1,\phi_2,\phi_3$
are the AR coefficients. We note that since
$\binom{n}{k}=0$
for
$k>n$
,
$b_{n,k}[\alpha, \beta, \theta]=\psi_{n,k}[\beta, \alpha, \theta]$
.
3. MA coefficients for the general case
$d\geq 2$
Let
$\{X(\mathbf{t}),\,\mathbf{t}\in \mathbb{Z}^{d}\}$
be a SAR(1) process on
$\mathbb{Z}^d$
. We recall from (1.1) and (1.2) that
$\beta_{\mathbf{i}}$
,
$\mathbf{i}\in \mathbf{I}=\big\{\mathbf{i}=(i_1,\ldots,i_d);\, i_j=0 \text{ or }1;\,\,j=1,\ldots,d;\,1\leq \sum_{j=1}^d i_j \leq d\big\}$
, and
$b_{\mathbf{k}}$
,
$\mathbf{k}\in \mathbb{Z}^{d++}$
, are the autoregressive parameters and the MA coefficients, respectively. Similar to the case
$d=2$
, for the general case
$d\geq 2$
the MA coefficients satisfy the recursive equations
$b_{\mathbf{k}}=\sum_{\mathbf{i}\in \mathbf{I}}\beta_{\mathbf{i}}b_{\mathbf{k}-\mathbf{i}}$
,
$\mathbf{k}\in\mathbb{Z}^{d++}$
, with
$b_{\mathbf{k}}=0$
,
$\mathbf{k}\in \mathbb{Z}-\mathbb{Z}^{d++}$
, where
$\mathbf{I}=\big\{\mathbf{i}=(i_1,\ldots,i_d);\, i_j=0 \text{ or }1;\,\,j=1,\ldots,d;\,1\leq \sum_{j=1}^d i_j \leq d\big\}$
. In the following, we follow the same argument given in the proof of Lemma 2.1 to derive the MA coefficients
$b_{\mathbf{k}}$
that are indeed solutions to the recursive equations given above.
The idea goes back to the possible paths and the gain (reward) of each path for a particle with random motion that travels through the lattice points from
$\mathbf{0}=(0,\ldots,0)$
to
$\mathbf{k}=(k_1,\ldots,k_d)$
in
$\mathbb{Z}^{d++}$
step-wise, where only at most one step ahead towards each coordinate and cross coordinate is allowed. Indeed, in one step,
$\mathbf{k}=(k_1,\ldots,k_d)$
can be reached from any of the lattice points
$\mathbf{k}-\mathbf{i}$
,
$\mathbf{i}=(i_1,\ldots,i_d)\in \mathbf{I} $
. In this case the total gain at
$\mathbf{k}-\mathbf{i}$
is increased by
$\beta_{\mathbf{i}}b_{\mathbf{k}-\mathbf{i}}$
. Clearly the total gain
$b_{\mathbf{k}}$
does satisfy the recursive equation given above. Next, we determine the totality of gains incurred by all paths from
$\mathbf{0}=(0,\ldots,0) $
to
$\mathbf{k}=(k_1,\ldots,k_d)$
that go through the lattice points, as explained above.
The gain of reaching
$(k_1,\ldots,k_d)$
from
$\mathbf{k}-\mathbf{i} $
is
$ \beta_{\mathbf{i}} $
for
$\mathbf{i}\in\mathbf{I}$
. The gain of a path is multiplicative: the path total gain is the product of the path step gains. The following procedure provides the number of paths and corresponding gains of reaching
$\mathbf{k}=(k_1,\ldots,k_d)$
from
$\mathbf{0}=(0,\ldots,0) $
in
$\mathbb{Z}^{d++}$
.
We let
$\kappa\subset\{1,2,\ldots,d\}$
represent a set of distinct indices. The one-step neighboring lattice points are classified by the
$\kappa$
sets.
For
$\mathbf{k}=(k_1,\ldots,k_d)\in \mathbb{Z}^{d++}$
, let
$\ell\kappa$
to be non-negative integers subject to
Indeed, for each
$\kappa$
, with
$u\in\kappa$
then
$\ell\kappa$
is the number of one-step jumps of type
$\kappa$
towards the coordinate
$k_u$
for reaching
$\mathbf{k}=(k_1,\ldots,k_d)$
from
$\mathbf{0}=(0,\ldots,0)$
. There are d equations in (3.1). In every equation in that system of equations, exactly
$2^{d-1}$
set elements
$\kappa$
are involved. Indeed, for a fixed u,
$u=1,\ldots,d$
, the number of distinct subsets of
$\{1,2,\ldots,d\}$
that contain u is the same as the number of subsets of a set with
$d-1$
distinct elements, which is
$2^{d-1}$
. We let
$\jmath$
stand for the collection of distinct
$\kappa$
in the (3.1) equations. We also let
$\mathbf{L}$
represent the collection of possible choices for
$\ell=\{\ell\kappa,\, \kappa\in\jmath\}$
sets that satisfy the equations in (3.1). Note that since the number
$\ell\kappa$
of unknowns in the system of equations in (3.1) is more than the number of equations, the collection of the sets of the possible solutions to (3.1),
$\mathbf{L}$
, is well defined. Also, for a set of solutions for
$ \{\ell\kappa,\, \kappa\in\jmath\}$
, say
$\ell \in \mathbf{L}$
, we let
Indeed, this is the multinomial situation. The ratio
${C[\ell]}/{D[\ell]}$
is the number of paths from
$\mathbf{0}=(0,\ldots,0)$
to
$\mathbf{k}=(k_1,\ldots,k_d) $
with
$\ell\kappa$
the number of single steps in the direction
$\kappa$
,
$\ell\kappa \in \ell$
. The gain of such a path is
$\prod_{\kappa\in\jmath}\beta_{{\mathbf{i}_\kappa}}^{\ell\kappa}$
, where
$\mathbf{i}_\kappa\in\mathbf{I}$
,
$i_j=0$
,
$i_j\notin\kappa$
,
$i_j=1$
,
$i_j\in \kappa$
,
$j=1,\ldots,d$
. Therefore, the total of possible gains
$b_\mathbf{k}$
is incurred through
which satisfies the SAR(1) recursive equations given above.
The following theorem is the version of Theorem 2.1 for
$d\geq 2$
.
Theorem 3.1. Let
$X_{\mathbf{t}}$
,
$\mathbf{t}\in\mathbb{Z}^{d}$
, be the SAR(1) process given by (1.1) that assumes the MA representation in (1.2). Then the MA coefficients
$b_{\mathbf{k}}$
,
$\mathbf{k}\in\mathbb{Z}^{d++}$
, are given by (3.4).
Proof. We show that the MA coefficients assume the recursive property stated above. The result will follow from the details in deriving (3.4). We observe that
\begin{align*} X_{\mathbf{t}} = \sum_{\mathbf{i}\in\mathbf{I}}\beta_{\mathbf{i}}X_{\mathbf{t}-\mathbf{i}} + W_{\mathbf{t}} = \sum_{\mathbf{i}\in\mathbf{I}}\beta_{\mathbf{i}}\sum_{\mathbf{k}\in\mathbb{Z}^{d++}}b_{\mathbf{k}} W_{\mathbf{t}-\mathbf{i}-\mathbf{k}} + W_{\mathbf{t}} & = \sum_{\mathbf{i}\in\mathbf{I}}\beta_{\mathbf{i}}\sum_{\mathbf{k}\in\mathbb{Z}^{d++}+\mathbf{i}}b_{\mathbf{k}-\mathbf{i}} W_{\mathbf{t}-\mathbf{k}} + W_{\mathbf{t}} \\ & = \sum_{\mathbf{k}\in\mathbb{Z}^{d++}}\Bigg\{\sum_{\mathbf{i}\in\mathbf{I}}\beta_{\mathbf{i}}b_{\mathbf{k}-\mathbf{i}}\Bigg\} W_{\mathbf{t}-\mathbf{k}}. \end{align*}
The proof is complete.
The following theorem provides insights into the SAR(1) processes that admit the MA representation.
Theorem 3.2. Let
$X_{\mathbf{t}}$
,
$\mathbf{t}\in\mathbb{Z}^{d}$
, be the SAR(1) process given by (1.1) that assumes the MA representation in (1.2). Then
-
(i)
(3.5)where
\begin{equation} \dfrac{1}{1-\sum_{\mathbf{i}\in\mathbf{I}}\beta_{\mathbf{i}}\mathbf{Z}^{\mathbf{i}}} = \sum_{\mathbf{k}\in\mathbb{Z}^{d++}}b_{\mathbf{k}}\mathbf{Z}^{\mathbf{k}}, \end{equation}
$\mathbf{Z}^{\mathbf{k}}=\prod_{j=1}^d Z_j^{k_j}$
,
$\mathbf{Z}=(Z_1,\ldots,Z_d)$
,
$\mathbf{k}=(k_1,\ldots,k_d)$
, and the
$b_{\mathbf{k}}$
,
$\mathbf{k}\in\mathbb{Z}^{d++}$
, are the MA coefficients given in (3.4).
-
(ii) The process
$X_{\mathbf{t}}$
,
$\mathbf{t}\in\mathbb{Z}^{d}$
, is causal if
$\sum_{\mathbf{i}\in\mathbf{I}}|\beta_{\mathbf{i}}| < 1$
.
Proof. For (i), let
${\boldsymbol\Psi}(\mathbf{Z})$
denote the rational function in (3.5). Then
$X_{\mathbf{t}}= {\boldsymbol\Psi}(\mathbf{B})W_{\mathbf{t}}$
, where
$\mathbf{B}$
is the backward shift operator,
$\mathbf{B}^{\mathbf{k}}X_{\mathbf{t}}=X_{\mathbf{t}-\mathbf{k}}$
. Then assertion (i) follows from Theorem 3.1. Part (ii) is deduced by using (3.5) along the same lines as in the proof of Theorem 2.2. The proof is complete.
The following theorem is for the autocorrelation function of SAR(1) processes.
Theorem 3.3. Let
$\rho(\mathbf{u})=(1/\sigma_{X}^2)E(X_{\mathbf{t}-\mathbf{u}}X_{\mathbf{t}})$
,
$\mathbf{u}\in\mathbb{Z}^{d++}$
, denote the autocorrelation function of the SAR(1) process
$X_{\mathbf{t}}$
given in Theorem 3.1. Then
$\rho(\mathbf{u})=b(\mathbf{u})$
,
$\mathbf{u}\in\mathbb{Z}^{d++}$
.
Proof. It follows from the MA representation that the autocorrelation
$\rho(\mathbf{u})$
,
$\mathbf{u}\in\mathbb{Z}^{d++}$
, satisfies the same recursive equations as the MA coefficients. Hence, since
$\rho(\mathbf{0})=b_{\mathbf{0}}=1$
, it follows that
$\rho(\mathbf{u})=b(\mathbf{u})$
for every
$\mathbf{u}\in\mathbb{Z}^{d++}$
.
The MA representation leads to formulations for the forecast recipe and the forecast error. Indeed, in forecasting
$X_{\mathbf{t}+\mathbf{n}}$
based on
$\{X_\mathbf{s},\,\mathbf{s}\leq \mathbf{t}\}$
,
$\mathbf{n}\in \mathbb{Z}^{d++}$
,
$\hat{X}_{\mathbf{t}+\mathbf{n}}=E[X_{\mathbf{t}+\mathbf{n}}\,||\,X_\mathbf{s},\,\mathbf{s}\leq \mathbf{t}]$
, the notation
$\mathbf{s}\leq \mathbf{t}$
means
$s_j\leq t_j$
,
$j=1,\ldots,d$
. The corresponding forecast error is defined by
$e^2[\mathbf{n}]=\mathrm{Var}(X_{\mathbf{t}+\mathbf{n}}-\hat{X}_{\mathbf{t}+\mathbf{n}})$
,
$\mathbf{n}\in \mathbb{Z}^{d++}$
.
Theorem 3.4. Under the assumptions of Theorem 3.1,
Proof. Indeed,
\begin{align*} \hat{X}_{\mathbf{t}+\mathbf{n}} & = E[X_{\mathbf{t}+\mathbf{n}}\,||\,X_\mathbf{s},\,\mathbf{s}\leq\mathbf{t}] \\ & = E\bigg[\sum_{\mathbf{k}\in\mathbb{Z}^{d++}}\!b_{\mathbf{k}}W_{\mathbf{t}+\mathbf{n}-\mathbf{k}}\,||\,W_\mathbf{s},\, \mathbf{s}\leq\mathbf{t}\bigg] = E\bigg[\sum_{\mathbf{k}\in\mathbb{Z}^{d++}}\!b_{\mathbf{k}}W_{\mathbf{n}-\mathbf{k}}\,||\,W_\mathbf{s},\, \mathbf{s}\leq\mathbf{0}\bigg] = \! \sum_{\mathbf{k}\in[\mathbf{n},\mathbf{\infty}]}\!\!b_{\mathbf{k}}W_{\mathbf{n}-\mathbf{k}}. \end{align*}
The corresponding forecast error is given by
\begin{equation*} e^2[\mathbf{n}] = \mathrm{Var}\Bigg(\sum_{\mathbf{k}\in\mathbb{Z}^{d++}-[\mathbf{n},+\mathbf{\infty}]}b_{\mathbf{k}} W_{\mathbf{k}}\Bigg) = \Bigg(\sum_{\mathbf{k}\in\mathbb{Z}^{d++}-[\mathbf{n},+\mathbf{\infty}]}b_{\mathbf{k}}^2\Bigg)\sigma_W^2. \end{equation*}
4. Numerical computation and programming
This section details an algorithm and corresponding Mathematica programs for the numerical derivation of the MA coefficients. To clarify the procedure for evaluation of the MA coefficients given in (3.4), we provide the details for the cases of
$d=2$
and
$d=3$
here.
For
$d=2$
, the SAR(1) model
$X_{\mathbf{t}}$
is given by (2.5). Let
$\mathbf{k}=(k_1,k_2)\in \mathbb{Z}^{2++}$
. For
$k_1$
and
$k_2$
in (3.1), the corresponding indices and non-negative integers are
$\{\ell\{1\}, \ell\{1,2\}\}$
and
$\{\ell\{2\}, \ell\{1,2\}\}$
, subject to
$\ell\{1\} + \ell\{1,2\} = k_1$
and
$\ell\{2\} + \ell\{1,2\} = k_2$
. Also,
$\jmath=\{\{1\},\{2\}, \{1,2\}\}$
. For given
$k_1$
and
$k_2$
, if we let
$r=\ell\{1,2\}$
, then
$\ell\{1\}=k_1-r$
and
$\ell\{2\}=k_2-r$
; possible choices for
$\ell$
correspond to possible choices for r. Thus, for
$d=2$
, (3.2) is read as
$C[\ell]=[(k_1-r)+ (k_2-r) + r]!= (k_1 +k_2 -r)!$
and (3.3) becomes
$D[\ell]= (k_1-r)! (k_2-r)! r!$
. For given
$k_1, k_2$
, every index
$\ell\in\mathbf{L}$
is specified by an
$r \in \{0,\ldots,\min\{k_1,k_2\}\}$
. Therefore, (3.4) is read as
\begin{equation*} b_{\mathbf{k}} = \sum_{r=0}^{\min\{k_1,k_2\}}\frac{(k_1+k_2-r)!}{(k_1-r)!(k_2-r)!r!} \beta_1^{k_1-r}\beta_2^{k_2-r}\beta_{12}^r,\end{equation*}
giving (2.2):
$\beta_1\equiv\beta_{(1,0)}$
,
$\beta_2\equiv\beta_{(0,1)}$
,
$\beta_{12}\equiv\beta_{(1,1)}$
.
For
$d=3$
, the index set
$\mathbf{I}$
has
$2^d-1=7$
members. There are seven SAR(1) coefficients, denoted by
$\beta_1$
,
$\beta_2$
,
$\beta_3$
,
$\beta_{12}$
,
$\beta_{13}$
,
$\beta_{23}$
, and
$\beta_{123}$
. The SAR(1) model is given by
\begin{align*} X_{(t_1,t_2,t_3)} & = \beta_1X_{(t_1-1,t_2,t_3)} + \beta_2X_{(t_1,t_2-1,t_3)} + \beta_3X_{(t_1,t_2,t_3-1)} \\ & \quad + \beta_{12}X_{(t_1-1,t_2-1,t_3)} + \beta_{13}X_{(t_1-1,t_2,t_3-1)} + \beta_{23}X_{(t_1,t_2-1,t_3-1)} \\ & \quad + \beta_{123}X_{(t_1-1,t_2-1,t_3-1)} + {W}_{(t_1,t_2,t_3)}.\end{align*}
For
$d=3$
, the
$\jmath$
collection is
$\{\{1\},\{2\},\{3\},\{1,2\},\{1,3\},\{2,3\},\{1,2,3\}\}$
. The corresponding simultaneous equations in (3.1) are
\begin{align*} \ell\{1\} + \ell\{1,2\} + \ell\{1,3\} + \ell\{1,2,3\} & = k_1, \\ \ell\{2\} + \ell\{1,2\} + \ell\{2,3\} + \ell\{1,2,3\} & = k_2, \\ \ell\{3\} + \ell\{1,3\} + \ell\{2,3\} + \ell\{1,2,3\} & = k_3.\end{align*}
Again, if we replace
$\ell\{1\}$
,
$\ell\{2\}$
, and
$\ell\{3\}$
by their equivalent terms from these equations, then (3.2) becomes
\begin{align*} C[\ell] & = \big[(k_1 - \ell\{1,2\} - \ell\{1,3\} - \ell\{1,2,3\}) \\ & \qquad + (k_2 - \ell\{1,2\} - \ell\{2,3\} - \ell\{1,2,3\}) \\ & \qquad + (k_3 - \ell\{1,3\} - \ell\{2,3\} - \ell\{1,2,3\}) \\ & \qquad + \ell\{1,2\} + \ell\{1,3\} + \ell\{2,3\} + \ell\{1,2,3\}\big]! \\ & = [k_1 + k_2 + k_3 - \ell\{1,2\} - \ell\{1,3\} - \ell\{2,3\} - 2\ell\{1,2,3\}]!.\end{align*}
The corresponding
$D[\ell]$
term in (3.3) is
\begin{align*} D[\ell]] & = (k_1 - \ell\{1,2\} - \ell\{1,3\} - \ell\{1,2,3\})! \\ & \quad \times (k_2 - \ell\{1,2\} - \ell\{2,3\} - \ell\{1,2,3\})! \\ & \quad \times (k_3 - \ell\{1,3\} - \ell\{2,3\} - \ell\{1,2,3\})! \\ & \quad \times \ell\{1,2\}!\ell\{1,3\}!\ell\{2,3\}!\ell\{1,2,3\}!.\end{align*}
Therefore, the spatial MA coefficient
$b_{(k_1,k_2,k_3)}$
in (3.4) is given by
with
$\nu_1= k_1 - \ell\{1,2\} - \ell\{1,3\} - \ell\{1,2,3\}$
,
$\nu_2 = k_2 - \ell\{1,2\} - \ell\{2,3\} - \ell\{1,2,3\}$
, and
$\nu_3 = k_3 - \ell\{1,3\} - \ell\{2,3\} - \ell\{1,2,3\}$
. The possible
$\ell$
sets are specified by the possible values for
$\ell\{1,2\}$
,
$\ell\{1,3\}$
,
$\ell\{2,3\}$
, and
$\ell\{1,2,3\}$
. Indeed,
-
• possible values for
$\ell\{1,2,3\}$
are
$\{0,1,2,\ldots,\min\{k_1,k_2,k_3\}\}$
, -
• possible values for
$\ell\{2,3\}$
are
$\{0,1,2,\ldots,\min\{k_2-\ell\{1,2,3\}, k_3-\ell\{1,2,3\}\}$
, -
• possible values for
$\ell\{1,3\}$
are
$\{0,1,2,\ldots,\min\{k_1-\ell\{1,2,3\}, k_3-\ell\{1,2,3\}\}$
, and -
• possible values for
$\ell\{1,2\}$
are
$\{0,1,2,\ldots,\min\{k_1-\ell\{1,2,3\}-\ell\{1,3\}, k_2-\ell\{1,2,3\}-\ell\{2,3\}\}$
.
Therefore, for
$(k_1,k_2,k_3)\in \mathbb{Z}^{3++}$
,
\begin{align} b_{(k_1,k_2,k_3)} & = \sum_{r=0}^{\min\{k_1,k_2,k_3\}}\sum_{u=0}^{\min\{k_2-r,k_3-r\}}\sum_{v=0}^{\min\{k_1-r,k_3-r\}} \sum_{w=0}^{\min\{k_1-r-v,k_2-r-u\}} \nonumber \\ & \quad \times \frac{(k_1+k_2+k_3-v-w-u-2r)!}{(k_1-v-w-r)!(k_2-w-u-r)!(k_3-v-u-r)!v!u!w!r!} \nonumber \\ & \quad \times \beta_1^{k_1-v-w-r}\beta_2^{k_2-w-u-r}\beta_3^{k_3-v-u-r} \beta_{12}^{w}\beta_{13}^{v}\beta_{23}^{u}\beta_{123}^{r}. \end{align}
We note that, for general d, the collection
$\jmath$
has exactly
$2^d -1$
set elements
$\kappa$
. There are d equations in (3.1). In every equation in that system of equations, exactly
$2^{d-1}$
set elements
$\kappa$
are involved. We may consider
$\ell\{j\}$
,
$j=1,\ldots,d$
, as dependent variables that are specified by the remaining
$\ell\kappa$
and
$k_j$
,
$j=1,\ldots,d$
. More precisely,
The equations in (3.1) put restrictions on the possible values for the rest of the
$\ell\kappa$
. To deduce the correct range for each
$\ell\kappa$
, it will be more convenient to move backward, by removing the elements of
$\{1,\ldots,d\}$
one by one. We notice that:
-
•
$\ell\{1,\ldots,d\}\leq k_u$
,
$u=1,\ldots,d$
. -
• For
$j=1,\ldots,d$
,
$\ell\{1,\ldots,d\}_j + \ell\{1,\ldots,d\} \leq k_u$
,
$u=1,\ldots,d$
,
$u\neq j$
, where
$\{1,\ldots,d\}_{\,j}=\{1,\ldots,d\}-\{\,j\}$
. -
• For a given
$(k_1,\ldots,k_d)$
, in the ith equation
$\ell\{i\}$
is the dependent variable whose value is specified by
$k_i$
and all
$\ell\kappa$
for which
$i\in\kappa$
. -
• For
$\kappa=\{j_1,\ldots,j_k\}$
,
$k=1,\ldots,d$
, (4.4)
\begin{equation} \ell\{j_1,\ldots,j_k\} + \sum\ell_\kappa \leq k_{j_u}, \quad u=1,\ldots,k,\,\kappa\supset\{j_1,\ldots,j_k\}. \end{equation}
By taking these facts into consideration, in the following we provide an algorithm for the numerical evaluation of the MA coefficients
$b_\mathbf{k}$
,
$\mathbf{k}\in \mathbb{Z}^{d++}$
.
4.1. Algorithm for numerical computation of the MA coefficients
By using the notation in Section 3 and given above, the MA coefficient computation algorithm is as follows:
-
(i) The collection
$\jmath$
is formed. -
(ii) The integer-valued variables
$\ell\kappa$
,
$\kappa\in \jmath$
, are formed. -
(iii) For a given
$\mathbf{t}\in \mathbb{Z}^{d++}$
, the system of equations in (3.1) is solved, and the solutions for
$\ell\kappa$
,
$\kappa\in \jmath$
, are listed. -
(iv) The outputs in (iii) are used to calculate the corresponding quantities
$C[\ell]$
in (3.2) and
$D[\ell]$
in (3.4). -
(v) For given SAR(1) coefficients
$\beta_\kappa$
,
$\kappa\in \jmath$
, the MA coefficient
$b_\mathbf{t}$
is calculated using (3.4).
4.2. Mathematica programs
We programmed the algorithm given above using Wolfram Mathematica 11.3. The details are given below.
-
Program 1: In the first part of this program, for
$d=3$
the algorithm given above for the SAR(1) parameters was programmed to compute
\begin{align*} [\beta_1=0.2,\,\beta_2=0.3,\,\beta_3=0.1,\,\beta_{12}=0.15,\,\beta_{13}=0.05,\,\beta_{23}=0.07,\, \beta_{123}=0.08] \end{align*}
$b_{(k_1,k_2,k_3)}$
, giving
$b_{(4,2,1)}=0.031\,08$
. The second part of the program gives
$b_{(k_1,k_2,k_3)}$
using (4.2). The output is consistent with the output of the first part.
-
Program 2: For the SAR(1) parameters
the algorithm was programmed to compute the MA coefficients
\begin{align*} [\beta_1=0.15,\,\beta_2=0.15,\,\beta_3=0.2,\,\beta_{12}=0.05,\,\beta_{13}=0.12,\,\beta_{23}=0.1,\, \beta_{123}=0.17], \end{align*}
$b_{\mathbf{k}}$
,
$\mathbf{k}\in[\mathbf{0},\mathbf{n}]$
. Then,
$\sum b_{\mathbf{k}}^2$
,
$\mathbf{k}\in [\mathbf{0},\mathbf{n}]$
, and
$\sum|b_{\mathbf{k}}|$
,
$\mathbf{k}\in [\mathbf{0},\mathbf{n}]$
, for
$ \mathbf{n}=(1,1,1),\ldots,(n,n,n)$
,
$n=1,\ldots,40$
were plotted against n to exhibit the forecast error (stationarity) and the causality.
-
Program 3: This program is similar to Program 2. For
$d=2$
, the SAR(1) parameters were the program inputs. The corresponding SAR(1) model was presented in [Reference Basu and Reinsel1] on the data set from a regular grid presented in [Reference Kempton and Howes10] on the yield of barley (in kilograms) from an agricultural uniformity trial experiment at the Plant Breeding Institute, Cambridge, UK.
\begin{align*}[\beta_1=0.240,\;\beta_2=0.796,\;\beta_{12}=-0.108]\end{align*}
The plots for Programs 2 and 3 are depicted in Figure 3. Programs 1, 2, and 3 are given in the Appendix.
Plots for Programs 2 and 3. Left: The cumulative squared MA coefficients, stationarity (forecast error). Right: The cumulative absolute value MA coefficients, causality.

5. Discussion
The importance of the moving average representation for stationary processes is realized in time series. In this work, closed formulations and an algorithm for the evaluation of the moving average coefficients for the first-order spatial autoregressive processes indexed by
$\mathbb{Z}^d$
,
$d\geq 2$
, the d-dimensional lattice of integers, were established. The computational algorithm and the programming is provided as well, using Mathematica. Interesting applications for the computation of the moving average coefficients, namely, stationarity and the causality checking, the autocorrelation function, and forecast error numerical evaluations, are also given. A sufficient condition is given for the causality as well. Due to the rapid advances in computation, this work highlights the time domain analysis of spatial models by computing and using the moving average coefficients. Further research work can be followed in this direction.
Appendix A. Program files
The Wolfram Mathematica program files for Programs 1, 2 and 3 are given in this section.
Program 1

Program 2

Program 3

Acknowledgements
The author would like to thank the reviewer and the editor for providing constructive comments.
Funding information
This research is supported by the KU Research Administration, under Research Project SS02/22.
Competing interests
There were no competing interests to declare which arose during the preparation or publication process of this article.

















