other aspects of the problem notwithstanding.

The physical essence of the problem is as follows. A sample of a periodic material is illuminated by incoming monochromatic electromagnetic waves at a given frequency $\omega$ and the corresponding free-space wavenumber $k_0 = \omega / c$. To sidestep the complicated problem of field behavior at corners, the sample is assumed to be a finite-thickness slab contained between the planes $z = 0$ and $z = L$, and infinite in the $x$ and $y$ directions. The periodic medium in the sample is to be replaced with a homogeneous material in such a way that the scattering wave pattern would be preserved as accurately as possible.

Following [@Tsukerman-PLA17; @Tsukerman-Markel14], let us define the problem more precisely. Assume that the intrinsic dielectric permittivity $\tilde{\epsilon}({\mathbf{r}})$ within the slab is lattice-periodic, and that all material constituents are nonmagnetic, $\tilde{\mu}({\bf r}) = 1$. Let all constitutive relationships be local and linear, and let the sample be illuminated by monochromatic waves with a given far-field pattern; these waves are reflected by the metamaterial.

The problem has two principal scales (levels). *Fine-level* fields are the exact solutions of Maxwell’s equations for given illumination conditions for a given sample. These fields are 