Abstract: | When generating Gaussian stationary random fields, a standard method based on circulant matrix embedding usually fails because some of the associated eigenvalues are negative. The eigenvalues can be shown to be nonnegative in the limit of increasing sample size. Computationally feasible large sample sizes, however, rarely lead to nonnegative eigenvalues. Another solution is to extend suitably the covariance function of interest so that the eigenvalues of the embedded circulant matrix become nonnegative in theory. Though such extensions have been found for a number of examples of stationary fields, the method depends on nontrivial constructions in specific cases.In this work, the embedded circulant matrix is smoothed at the boundary by using a cutoff window or overlapping windows over a transition region. The windows are not specific to particular examples of stationary fields. The resulting method modifies the standard circulant embedding, and is easy to use. It is shown that this straightforward approach works for many examples of interest, with the overlapping windows performing consistently better. The method even outperforms in the cases where extending the covariance leads to nonnegative eigenvalues in theory, in the sense that the transition region is considerably smaller. The Matlab code implementing the method is included in the online supplementary materials and also publicly available at www.hermir.org. |