## 5 Conclusions  
This work has presented two near field models for the analysis of spatially fed array antennas, namely, reflectarrays and transmitarrays. The first model is based on the direct application of the radiation equations directly derived from the A and F vector potentials. The volumetric integrals are particularized for a planar array discretized into a number of rectangular unit cells, and thus they are reduced to a summation of a double integral over each unit cell. In turn, this integral is numerically evaluated by a quadrature method, for instance, the mid point quadrature. The second model is based on the superposition of the far field radiated by each array element. The far field is computed using [PERSON]'s principle of equivalence assuming a constant field at each unit cell. Both near field models were compared by computing the field radiated by a transmitarray antenna. For the model based on the radiation equations, the near field was also computed for several discretizations of the unit cell for the numerical computation of the double integrals. Both models provide very similar results. When the model based on the radiation equations is used as reference, the relative error in the radiated field obtained with the other model quickly drops as the field is computed further away from the array. With relative errors lower than 3% in the computed tangential near field at 13 \(\lambda\) or further from the array, the model is effectively validated for subsequent use in optimization algorithms for near field beam-shaping. Then, the model based on far field superposition was applied to perform near field beam-shaping. The considered scenario is aimed at providing indoor coverage in an office for mm-Wave 5G NR networks in the n257 band. The proposed wideband near field opti  
\begin{table}
\begin{tabular}{c c c c c c c c c} \hline \hline \multirow{2}{*}{**Frequency (GHz)**} & \multicolumn{4}{c}{**Polarization X**} & \multicolumn{4}{c}{**Polarization Y**} \\ \cline{2-9}  & **Ripple (dB)** & **1 dB (\%)** & **2 dB (\%)** & **3 dB (\%)** & **Ripple (dB)** & **1 dB (\%)** & **2 dB (\%)** & **3 dB (\%)** \\ \hline
26.5 & 1.30 & 80.89 & 100 & 100 & 0.82 & 100 & 100 & 100 \\
27.0 & 1.03 & 99.63 & 100 & 100 & 0.84 & 100 & 100 & 100 \\
27.5 & 1.08 & 95.63 & 100 & 100 & 0.96 & 100 & 100 & 100 \\
28.0 & 1.23 & 8 mization strategy is composed of several stages to facilitate convergence towards a suitable solution. First, a phase-only synthesis (POS) was carried out to obtain a reflectarray layout that provides coverage at central frequency (28 GHz). Due to the narrow bandwidth nature of spatially fed planar array antennas, poor compliance is achieved at other frequencies within the n257 band. Thus, a multi-frequency optimization was then carried out employing a method of moments based on local periodicity (MoM-LP) directly in the optimization loop along with the near field model. The cost function of the optimization algorithm was modified to include requirements at several frequencies in the near field region of interest. At the same time, the optimization was carried out in several stages, gradually increasing the number of DoF to improve convergence. Eventually, the optimized antenna complied with the imposed specifications, achieving a magnitude ripple equal or lower than 1.5 dB in the whole 5G NR n257 band, corresponding to a 10.7% relative bandwidth, showing the suitability of the proposed methodology for the wideband near field beam-shaping of spatially fed arrays. This work was supported in part by the Ministerio de Ciencia, Innovacion y Universidades under project IJC2018-035696-I; by the Ministerio de Ciencia e Innovacion and the Agencia Estatal de Investigacion within project ENHANCE-5G (PID2020-114172 RB-C21/AEI/10.13039/501100011033); by Gobierno del Principado de Asturias under project AYUD/2021/51706. Not applicable. The author would like to thank [PERSON] for providing the MoM-LP software. The author declares no conflict of interest. The following abbreviations are used in this manuscript: