Recently there has been a number of studies of single-layer and double-layer arrays of small resonant particles made of a noble metal. The intense interest to these structures is caused by their promising properties for near-field enhancement and subwavelength imaging applications, especially in the optical range. They have substantial advantages over the structures containing DNG (double negative) materials as they are easier in fabrication and may mitigate the problem of losses. So far the super-resolution properties were theoretically investigated only for the arrays of a finite extent. In this work we consider single-layer and multilayer infinite arrays. This formulation allows to build a highly effective algorithm and to consider both the problem of excitation of a periodic structure by a single dipole and the modal properties of the structure. The field produced by a single dipole source is effectively described by using the array scanning method, accelerated by the Ewald method. Each subwavelength sphere is represented as an electric dipole scatterer. Special attention is given to the investigation of the number of layers influence on local field enhancement and to the study of the field distribution between the layers.