MetaPhyNet: intelligent design of large-scale metasurfaces based on physics-driven neural network

Metasurface has garnered extensive attention across multiple disciplines owing to its profound capability in electromagnetic (EM) manipulations. To determine its EM characteristics accurately, full-wave simulations are essential. These simulations necessitate significant amounts of time and memory resources, hindering the efficiency of the design process. In this article, we propose MetaPhyNet, a novel physics-driven neural network based on temporal coupled-mode theory (CMT) to address the challenges of low efficiency and high memory consumption in large-scale metasurface design. In the proposed approach, a surrogate model is developed to achieve rapid prediction of the EM responses of ultra-large-scale metasurfaces. In comparison with the full-wave EM simulation, the proposed model reduces the simulation time of the ultra-large-scale metasurface by up to two orders of magnitude and the memory consumption by more than two orders of magnitude. Our proposed approach aims to enhance the efficiency and intelligence in metasurface design by leveraging the principles of CMT within a neural network framework. Through this innovative integration of physics-based modeling and machine learning, we seek to achieve significant advancements in the design efficiency of metasurfaces. We apply the proposed model to optimize the design of two metasurface absorbers to showcase the effectiveness of our proposed approach. Simulations and experimental results are provided to demonstrate the value and impact of our approach in addressing existing challenges in full-wave EM simulation-based design optimizations of metasurfaces.


Introduction
The past decade has witnessed the rapid development of metasurfaces [1][2][3][4][5].Due to their superior electromagnetic (EM) wave manipulation capabilities, metasurfaces are highly regarded as one of the most promising technologies in the field of EM research for the future.During the design process of metasurfaces, the time-consuming and memory-intensive nature of full-wave EM simulation is a critical challenge that must be addressed.In the traditional EM simulation-driven design procedure, a large amount of time is typically dedicated to the utilization of commercial simulation software for conducting full-wave EM simulations.Particularly in the context of reverse optimization design, designers must repeatedly adjust various size or structural parameters to achieve the desired EM response.During this parameter adjustment process, commercial EM simulation software needs to be repeatedly driven to obtain the corresponding EM response for optimization.This traditional optimization method is time-consuming and consumes a significant amount of computer memory.Numerous machine learning (ML) based methods have been developed to address the issues mentioned above [6][7][8][9][10][11][12][13][14][15][16][17][18].These ML methods involve creating a database that encompasses geometric information and EM responses, which is then used to train relevant neural networks.Subsequently, the trained neural networks are utilized to predict the EM response of unknown metasurface units.Previous studies commonly employed data-driven neural networks to construct surrogate models, resulting in the creation of large EM databases as the complexity and scale of metasurfaces increase [16].The expansion in database size poses significant challenges for accurate prediction of the EM response.To address this issue, the integration of physical principles into data-driven neural networks has been implemented [17][18][19].By incorporating physical principles into the development of surrogate models, these physics-driven networks reduce the reliance on database size, leading to improved prediction accuracy and greater applicability.
Coupled-mode theory (CMT), a widely utilized theory in optical and microwave system design, describes the interaction between multiple modes within a system [20][21][22][23][24][25].Recently, numerous works employing this theory for reverse design have been documented in academic literature [19,26,27].In [26], CMT is utilized for the reverse design of ultra-large-scale high numerical aperture metal lenses, significantly outperforming traditional full-wave simulation methods.This work was further advanced in [27] by incorporating adjoint optimization to extend the design to far-field EM response, enhancing the precision and efficiency of metamaterial lens design.In addition, the work in [27] also shows the feasibility and accuracy of using CMT to achieve far-field focusing and imaging for different images from different anglesdeal with oblique incidence problems, which demonstrates the wide range of useability of CMT surrogate modelto predict EM responses at oblique incidences.However, the use of a look-up table (LUT) in this process has raised concerns regarding design accuracy, as the density of LUT data may be insufficient.Expanding the LUT scale to enhance accuracy poses challenges in terms of memory space utilization.This limitation has prompted researchers to explore alternative approaches, such as integrating adjoint optimization techniques and incorporating neural networks to replace traditional LUT methods, as demonstrated in another study in [19].This new approach not only resolves the memory space issue associated with LUTs but also ensures computational efficiency without compromising design accuracy.The findings from these studies highlight the importance of continuously refining and optimizing design methodologies in reverse engineering processes using CMT.However, how to apply CMT to achieve fast inverse design of ultra-large-scale metasurfaces remains an open subject in this literature.This article proposes a novel algorithmic approach that combines physics-driven neural networks with CMT to achieve efficient and intelligent design of large-scale metasurfaces.We refer to our proposed method as MetaPhyNet.In the proposed method, we construct a surrogate model capable of rapidly predicting the EM responses of metasurfaces.Subsequently, employing this surrogate model, we design a large-scale, fully random absorber and frequency selector with dimensions surpassing 400 mm in side length, followed by experimental validations.Concurrently, the potential for designing microwave devices of greater scale is validated, with a comparative analysis highlighting its advantages over conventional full-wave simulation and data-driven neural network methodologies.
In recent years, neural network-based reverse design methods have been widely studied [28,29].In [28], a neural network is used to predict the parameters that are used to write the Lorentzian equation.Similarly, the work in [29] uses a neural network to predict the permittivity and permeability of the all-dieletrics metameterials and by using the predicted result, accurate S-parameter predictions are obtained.These works focus on the design of small-scale metasurfaces.In contrast, we focus on designing large-scale metasurface absorbers in this study.On the other hand, using an excellent phyical model can also make the prediction more accurate [30][31][32].The physical model reported in [30] and [31] shows an powerful phase retriecal capabilities for programmable metasurfaces.Furthermore, the physical model and deep-learning method are combined in [32], which help introduce one-loop wave control in programmable metasurfaces complex media.Although the physical models in these works show great abilities of predicting the performance of programmable metasurfaces.None of them have considered the challenging problem of designing large-scale random metasurfaces, which is the main focus of our study.In this study, we propose to combine a physical model (i.e. the CMT equation) with neural networks to achieve fast and intelligent metasurface design.To the best of our knowledge, this is the first time for CMT to be combined with ML techniques and applied to large-scale random metasurfaces design.At the same time, in order to solve the problem of excessive demand for neural network database construction, many improved methods for neural network data generation have been proposed [33,34].The imbalance datasets used by the work in [33] can reduce the size of database by nearly three-quarter, and make the target spectra more accurate.In [34], a novel method that combines supervised and unsupervised learning is developed to obtain an efficient improvement for the inverse design associated with ANN.

Design and implementation
We commence with a succinct overview of CMT, which is extensively utilized throughout the methodologies presented in this article.Figure 1(a) illustrates a microwave system comprising a vast array of interacting resonators, designed with a focus on coupling between proximal or diagonally adjacent resonators.The broader coupling interactions are omitted to maintain the model's fidelity and simplicity.The microwave system, depicted in figure 1(b), is composed of a multitude of meta-elements with varying dimensions, meticulously engineered to elicit the targeted EM response.The meta-element is structured in a tri-layer configuration, comprising two copper layers and a central FR-4 dielectric layer.The top copper layer is configured in a square geometry to optimize the EM response; the bottom layer is engineered to reflect incident waves, enhancing absorption efficiency.An FR-4 dielectric layer is interposed between the copper layers to ensure isolation.The absorption rate formula of the single resonator can be obtained from [19]: And the absorption rate formula for mutual coupling with dual resonators can be expressed as [19]: where ) represent the resonant frequency, absorption attenuation, and radiation attenuation of the ith resonator, respectively.The symbol represents the coupling constant between the ith and jth resonators.
The absorption rate for a metasurface array with N × N elements can be obtained by combining equations ( 1) and (2) as follows [19]: The matrix D is a complex matrix that represents the coupling relationship between the incident amplitude and the reflected amplitude, and its values are given as follows: The matrices Ω and Γ, each of size N 2 × N 2 , are utilized to denote the resonant frequencies, coupling constants, and attenuation rates for each resonator within the system.Their values are defined as follows: Equations ( 1)-( 6) offer a framework for determining the absorption rate of metasurfaces.In practical applications, these CMT parameters are typically refined via optimization techniques, iteratively adjusting them to minimize the objective loss function.Figure 2 delineates the design paradigm, encompassing three pivotal stages: initial absorption rate determination via EM full-wave simulation; iterative parameter optimization employing CMT formulas to satisfy the loss function criteria; and neural network training with CMT parameters to forecast the absorption rates of a given metasurface.Notably, the neural network employed in the third step is a tripartite construct, including a single-resonator CMT parameter network, a dual-resonator CMT parameter network, and a multi-coupled system CMT equation.This network accepts the size parameters of the metasurface array as input and yields the absorption rate EM response as output.
The development procedure initiates with the generation of data via full-wave EM simulations of singleand dual-resonator systems, each with distinct geometric configurations.Following the acquisition of a predefined set of samples, an optimizer is employed to determine the CMT parameters for both single and dual-resonator systems.The optimization process commences with the establishment of a random initial point, utilizing the CMT formula to compute the absorption rate F (ω 0 , γ a0 , γ r0 ) for a single resonator.Subsequently, the CMT parameters for a single resonator are fine-tuned to minimize the objective function 2 , thereby determining the resonant frequency and CMT parameters γ, γ r .These findings are then leveraged to refine the CMT parameters for dual resonator systems.The dual resonator CMT parameters β are derived by computing the absorption rate G (β 0 ) and optimizing the objective function 2 to its minimum.It is important to recognize that the aforementioned problem constitutes a nonlinear, unconstrained optimization challenge, which can be effectively addressed using classical numerical techniques.In this research, we have employed the Nelder-Mead [35] simplex direct search algorithm, as implemented in MATLAB, to resolve the optimization issue.
In the training phase of a single neural network, a dataset comprising N s training samples, each with parameters

}
, is initially constructed.This dataset is then utilized to train a three-layer multilayer perceptron (MLP) to establish the correlation between CMT parameters, resonant frequency, and the geometric dimensions of the resonator, denoted by a.To achieve a well-calibrated neural network, the training process is focused on minimizing the network's residual error.Consequently, the resulting network is capable of precisely and expeditiously estimating the CMT parameters for resonators with unspecified geometric configurations.The neural network training for a dual resonator system follows a process analogous to that of a single resonator network.A three-layer MLP is employed to train on the training samples } , derived from the optimizer's output.Here, a 1 and a 2 denote the geometric dimensions of the two resonators within the dual system, while p signifies the relative position index.Given that coupling is considered for only the eight nearest resonators, p takes the values of 1, 2, 3, or 4. For a target meta-element, only the couplings between this meta-element and its eight adjacent meta-elements are considered.Generally, we number these eight adjacent metasurfaces as 1-8 in order from left to right and from top to bottom.However, in order to avoid duplicate calculation, the coupling between adjacent meta-elements numbered 5-8 and this meta-element can be omitted.This reduces the computational workload to half of its size and greatly improves the computational efficiency of the algorithm.The formulation for predicting the absorption rate is derived by amalgamating the CMT equation ( 3) for an N × N system with the weight vector w * , which is constituted by a single resonator neural network weight w * 1 and two additional neural network weights w * 2 [19]: where Λ (a, w * ) = j (ωI N 2 − Ω (a, w * + Γ (a, w * ).Equation ( 7) enables the precise and efficacious forecasting of the EM response for resonators of arbitrary geometric dimensions a within an N × N coupled resonant system, as exemplified in figure 3. Specifically, figure 3(c) depicts a 20 × 20 system with fully random sizes, demonstrating the high fidelity of MetaPhyNet in predicting the full-wave EM response of metasurfaces.Here, we should note that people often use the first-order mode of meta-atoms to reduce the complexity of inverse design for metasurface in practical applications, as demonstrated in [27].Generally, the degrees of freedom for inverse design of metasurface are mainly achieved through the arrangement and size of meta-atoms.By flexibly adjusting the arrangement patterns and sizes of meta-atoms, it is generally possible to achieve the desired absorption spectrum, even when considering only one mode of meta-atom.Figure 4 demonstrates the performance between MetaPhyNet and the time-domain EM solver, specifically the Finite-Difference Time-Domain (FDTD) algorithm, implemented within the CST commercial software suite.To achieve a fair comparison, all computations were executed on a server equipped with an AMD Ryzen Threadripper 3960X 24-Core Processor @4.03 GHz.The FDTD algorithm simulation, denoted by the red diamond in figure 4(a), is capable of handling up to 40 single-sided meta-elements per run for a resonator system, whereas MetaPhyNet can accommodate systems with up to 80 meta-elements.Notably, the MetaPhyNet approach not only outperforms EM full-wave simulations by several orders of magnitude in terms of running speed, as depicted in figure 4(b), but also significantly reduces memory consumption by two or more orders of magnitude.This substantial reduction in memory usage is instrumental in minimizing computational expenses.Additionally, figure 4(c) compares the sample size requirements for MetaPhyNet with traditional neural network methods when constructing a database.It is evident that MetaPhyNet necessitates a database size that is over 10 orders of magnitude smaller than traditional methods, given equivalent resonator system dimensions and sampling densities.This efficiency in data requirements ensures a substantial decrease in neural network training time, thereby accelerating the development process.

Application instances
To assess the efficacy of our design methodology, we perform parametric optimization for frequency-selective and broadband microwave absorbers, employing standard printed circuit board technology to fabricate circular samples.This serves as a concrete instance of MetaPhyNet integrated with the design optimization process.A two-dimensional metasurface prototype, comprising 20 meta-elements with an aggregate dimension of 400 mm, was designed.The FR-4 dielectric substrate, with a thickness of 0.5 mm along the z-axis, exhibits a dielectric constant of ε r = 4.3 and a loss tangent of 0.025.The metasurface is fastened to the platform, the antenna, which is connected to a vector network analyzer, is placed at about 2 m from the metasurface.This antenna is used to generate incident EM waves for the metasurface and receive the reflected EM waves.The experiments were conducted within a standard EM anechoic chamber to mitigate the influence of environmental noise on the outcomes.The fabricated metasurface system is depicted in figure 5.
The design parameters include the geometric dimension parameter set a = {a 1 , a 2 , • • • , a 400 } for each square meta-element, so that its absorption rate for normal incident plane waves can reach more than 0.6.We first establish a CMT model for a single unit and extract the CMT parameters of a single resonator.Here, a dataset with a size range of [L min , L max ] = [9.5, 16] (mm), a uniform sampling step of 0.1 mm, and a total of 66 samples is established.The time-domain solver (real-time finite difference method) in CST is used to achieve EM full-wave simulation of a single resonator at a specific frequency range (4-8 GHz).Compared to the frequency domain solver (i.e.finite element method), using a time domain solver can reduce simulation time while ensuring computational accuracy, thereby further reducing computational costs.The absorption rate is calculated under the condition of vertical incidence of TM polarized plane waves (magnetic field, x-polarization).
The simulation time for a single unit is completed between 20-30 s, with a total time of 30 min.The extraction of CMT parameters was optimized using the 'fminsearch' function in MATLAB, and the error between CMT calculation results and EM simulation results was minimized.In order to keep the residual error in a relatively low level, multiple optimizations were conducted to obtain the optimal extraction solution.The entire optimization process took 5 h.The process of extracting CMT parameters for dual resonators is similar to that for single resonators, with a single geometric size of 66 and a relative position index of 4. Therefore, the total number of geometric samples for dual resonators is 17 424 groups.The time required for each EM simulation is approximately 1.5 min.Therefore, multiple computers were used for parallel computing and full-wave EM simulation was performed on 17 424 samples.The sample collection time is about 100 h.The process of optimizing and extracting CMT parameters using the 'fminsearch' function takes about 26 h to complete.After obtaining the CMT parameter samples, a three-layer MLP neural network is constructed using the neural network toolbox in MATLAB to train the above parameters.For the single resonator system, the number of hidden layers in the neural network is 5 and the number of training iterations is 10.For the dual resonator system, the number of hidden layers in the neural network is 50 and the number of training iterations is 100.The training time for single and dual-resonator system neural networks is 10 s and 107 s, respectively.In the optimization process, the 'patternsearch' algorithm in the optimization toolbox in MATLAB is used in both of the following design cases.

Design of frequency-selective microwave absorber
We first apply the proposed MetaPhyNet approach to design a frequency-selective microwave absorber, as shown in figure 6(a).The metasurface under consideration has a total of 400 geometric size parameters, and the design specifications to be satisfied is a microwave absorption rate of over 60% at 4.5 GHz, 5.3 GHz, 6.1 GHz, and 7.1 GHz.The entire optimization process is performed using the MetaPhyNet developed in the aforementioned process.The initial values of all the optimization parameters are set to 13 mm.For this design optimization case, it takes approximately 15 h to achieve the optimization goal using the MetaPhyNet model for optimization.A single optimization process usually requires tens of thousands of simulations, while in this case, a single full-wave EM simulation of this metasurface requires 0.5 h to accomplish.Therefore, using full-wave EM simulator to accomplish the same optimization task requires several months and occupies massive memory, which is computationally infeasible.

Design of broadband microwave absorber
In addition to the frequency-selective microwave absorber, we also apply the proposed approach to design a wide-band microwave absorber, as shown in figure 6(c).The metasurface to be optimized has 400 geometric size parameters, and its design specification is a microwave absorption rate of over 50% in the frequency band range of 5-7 GHz.The initial values of all optimization parameters are also set to 13 mm.For this optimization task, the proposed MetaPhyNet-based design optimization requires approximately 13 h o to achieve the design objectives.In comparison, using full-wave EM simulator to accomplish the same optimization task would require several months, after which the design objectives may still not be satisfied.
The MetaPhyNet prediction results and experimental results of the two optimized metasurfaces are shown in figures 6(b) and (d).From the figure, it can be seen that the absorbance at the optimal design can basically meet the design objectives, and the predicted responses are in good agreements with the measured responses, with the same trend of change within the specified frequency range.There are several sources for the deviations.One is the omition of the resonance between each resonator and other resonators exept for the adjancent eight resonators.Another is the experimental deviation.In addition to the processing tolerance, the limitation of the experimental environment is also one of the cause of the deviation.

Conclusion
We have designed a physics-driven neural network computing method that combines CMT theory with neural networks to achieve rapid and intelligent optimization design of ultra-large-scale metasurfaces.This method develops a surrogate model named MetaPhyNet, which can quickly and accurately predict the EM response of a ultra-large-scale metasurface whose response cannot be calculated using the traditional EM full-wave simulation method.We apply this model to realize the design of a large-scale frequency-selective microwave absorber and a broadband microwave absorber, whose speed is several orders of magnitude higher than that of traditional methods while ensuring its accuracy.The method proposed in this article takes a step forward in solving the challenging problem of designing ultra-large-scale metasurfaces.In future experimental design researchstudies, we will improve the accuracy of the proposed modelalgorithm and considerby taking into accounta more compreshensive consideration of the coupling effect amongbetween adjacent all the resonators.In addition, we will continue to develop and explore the application scenarios of this method and apply it to solve other typles of EM design problems such as large-scale holographic imaging and beam control.

Figure 1 .
Figure 1.(a) Schematic of a large-scale metasurface containing N × N microwave resonators that are coupled to each other.(b) Simulation model of the meta-element.(c) Schematic of the proposed optimization framework, which combines neural networks with the coupled-mode theory for accurate prediction and fast optimization of large-scale metasurface EM responses.

Figure 2 .
Figure 2. MetaPhyNet architecture for the intelligent design of large-scale metasurfaces.

Figure 3 .
Figure 3.The fitting result between MetaPhyNet and CST simulated data.(a) Single resonator (b) dual resonators (c) large-scale resonators system.

Figure 4 .
Figure 4. (a) The comparation of computing time between MetaPhyNet and EM simulation.(a) The comparation of occupied memory between MetaPhyNet and EM simulation.(c) The comparation of sample size between MetaPhyNet and traditional NN. (d), (e) Comparision between EM simulation, MLP prediction and MetaPhyNet at two types of metasurface.

Figure 5 .
Figure 5. Photograph of the configuration of the measurement environment for the designed large-scale metasurface.

Figure 6 .
Figure 6.(a) The experimental prototype of the frequency-selective absorber.(b) The EM response of the frequency-selective absorber.(c) The experimental prototype of the wide-band absorber.(d) The EM response of the wide-band absorber.