원시데이터 수집 시스템
선정목록으로

Differentiable scattering matrix for optimization of photonic structures

간접 관련 필름·전자재료 · (13) 프리즘 필름 (11) 배리어 필름(15) 디스플레이 패널재료(16) CPI(투명 폴리이미드)

기본 정보

저자
  1. Ziwei Zhu
  2. Changxi Zheng
DOI
10.1364/oe.409261
저널
Optics Express
발행년도
2020
발행기관
Optica Publishing Group
피인용수
6
라이선스
0
논문 유형
–
언어
–
원문 페이지
https://doi.org/10.1364/oe.409261
토픽
Optical Coatings and Gratings
OpenAlex ID
W3088512199

평가 내용

관련도
간접 관련
사업분야
필름·전자재료 · (13) 프리즘 필름
부 분야
(11) 배리어 필름, (15) 디스플레이 패널재료, (16) CPI(투명 폴리이미드)
R&D 측면
분석·모델링
확신도
0.70
근거 용어
photonic structures, scattering matrix, metasurface, optical design, optimization
판단 근거
이 논문은 광학 구조(metasurface 등)의 산란 행렬(scattering matrix) 미분값을 효율적으로 계산하여 광학 성능을 최적화하는 알고리즘을 다룹니다. 이는 코오롱인더스트리의 프리즘 필름(13)이나 디스플레이용 광학 필름/봉지재(11, 15) 설계 시 미세 구조 최적화 및 광학 특성 예측 모델링에 응용될 수 있습니다.
R&D 활용 포인트
메타표면 및 미세 구조 광학 필름 설계 시, 수치 해석적 최적화 알고리즘을 적용하여 원하는 광학적 특성(위상, 진폭, 편광 제어 등)을 갖는 필름 구조를 정밀하게 설계하는 데 활용 가능합니다.
평가 입력
본문 76,316자 중 30,032자 발췌

초록

The scattering matrix, which quantifies the optical reflection and transmission of a photonic structure, is pivotal for understanding the performance of the structure. In many photonic design tasks, it is also desired to know how the structure’s optical performance changes with respect to design parameters, that is, the scattering matrix’s derivatives (or gradient). Here we address this need. We present a new algorithm for computing scattering matrix derivatives accurately and robustly. In particular, we focus on the computation in semi-analytical methods (such as rigorous coupled-wave analysis). To compute the scattering matrix of a structure, these methods must solve an eigen-decomposition problem. However, when it comes to computing scattering matrix derivatives, differentiating the eigen-decomposition poses significant numerical difficulties. We show that the differentiation of the eigen-decomposition problem can be completely sidestepped, and thereby propose a robust algorithm. To demonstrate its efficacy, we use our algorithm to optimize metasurface structures and reach various optical design goals.

본문 76,316자

본문 펼치기
## Differentiable Scattering Matrix for Optimization of Photonic Structures Ziwei Zhu <sup>1</sup> and Changxi Zheng <sup>1,*</sup> 1Department of Computer Science, Columbia University, New York, New York 10027, USA *Corresponding author: cxz@cs.columbia.edu September 25, 2020 Abstract The scattering matrix, which quantifies the optical reflection and transmission of a photonic structure, is pivotal for understanding the performance of the structure. In many photonic design tasks, it is also desired to know how the structure’s optical performance changes with respect to design parameters, that is, the scattering matrix’s derivatives (or gradient). Here we address this need. We present a new algorithm for computing scattering matrix derivatives accurately and robustly. In particular, we focus on the computation in semi-analytical methods (such as rigorous coupled-wave analysis). To compute the scattering matrix of a structure, these methods must solve an eigen-decomposition problem. However, when it comes to computing scattering matrix derivatives, differentiating the eigen-decomposition poses significant numerical difficulties. We show that the differentiation of the eigen-decomposition problem can be completely sidestepped, and thereby propose a robust algorithm. To demonstrate its efficacy, we use our algorithm to optimize metasurface structures and reach various optical design goals. ##### 1 introduction The scattering matrix is a fundamental concept in many fields. It relates the input state and the output state of a physical system undergoing a scattering process. Particularly revealing in optics, the scattering matrix has been widely used for analyzing photonic structures such as waveguides [9, 18, 19] and metasurface units [8,16,43]. Once the scattering matrix of a photonic structure is known, the structure’s optical performance (e.g., mode conversion efficiency and phase shift) can be directly obtained. Because of its vital importance, many numerical methods have been developed to compute the scattering matrix of a photonic structure. Among them, a 1 popular class is the _semi-analytical_ _methods_, such as the method of lines [28] and rigorous coupled-wave analysis (RCWA) [24]. These methods exploit the fact that many photonic structures in practice (such as waveguides and metasurface units) have a piecewise constant cross-sectional shape along the transmission direction (denoted as _z_ -direction). Thus, to solve Maxwell’s equations, they only need to discretize the 2D cross-sectional region, reducing Maxwell’s equations into a set of continuous differential equations along _z_ -direction, whose solution can be expressed through an eigenvalue analysis. Thanks to the semidiscretization, these methods often enable faster computation in comparison to full discretization methods (such as finite-element- and finite-volume-based methods). Indeed, methods like RCWA have been widely used in designing various photonic structures, such as metasurfaces [3,4,11,16], metagratings [1,13], holograms [43,44], polarimeters [5], solar cells [40], radiative cooling structures [30], color structures [34], photonic crystals [41], and waveguides [9,19]. In this work, we extend the semi-analytical methods to obtain the higher-order information of scattering matrices, namely the scattering matrix’s _derivatives_ (or gradient). Provided a photonic structure specified by certain design parameters, we aim to compute not only its scattering matrix but its derivatives with respect to the design parameters. The scattering matrix derivatives depict the changes of the structure’s optical behaviors as its design parameters vary. This higher-order information, if robustly and efficiently computed, finds many applications in photonic design. Most notable is the optimization of photonic structures. The derivatives provide guidance on how we can adjust the parameters (e.g., through the gradient descent algorithm [31]) to improve the structure’s optical performance [20] or to find a design robust to fabrication error [2,39,45]. Unfortunately, the computation of scattering matrix derivatives is nontrivial. The difficulty is rooted in the fact that the permissible optical modes in a photonic structure are eigenfunctions of a linear (Hermitian) operator determined by Maxwell’s equations [15]. Thus, to compute the scattering matrix, semi-analytical methods must solve an eigen-decomposition problem: its eigenvalues describe the propagation constants (or effective indices) of the modes and its eigenvectors indicate propagating modal patterns. Differentiating the scattering matrix, by chain rule, requires the derivatives of eigenvalues and eigenvectors. It is the need of eigenvector derivatives that renders the scattering matrix differentiation ill-posed: when there exist repeated eigenvalues, the corresponding eigenvectors are not uniquely defined. As the parameter changes, the numerical results of the eigenvectors may change discontinuously, and their derivatives become undefined (see more discussion in Section 3). Not merely does this issue exist as a corner case; many photonic structures in practice have geometric and material symmetries, from which repeated eigenvalues and thus ill-defined eigenvector derivatives emerge (see Fig. 2). Consequently, one must carefully choose eigenvectors such that they vary smoothly with respect to the design parameters. This choice, albeit attainable, demands complex and expensive computational effort [38]. In this paper, we question the necessity of eigenvector derivatives for differen 2 (a) (b) Layer 1 Layer 2 Figure 1: (a) In a photonic structure, light may be incident from both sides and get scattered out. The relationship of incident and scattered light is characterized by the scattering matrix. (b) A complex structure can be decomposed into individual layers. Each layer is characterized by its scattering matrix, and these scattering matrices are then combined (using the Redheffer star product [29]) to form the scattering matrix of the entire structure. tiating scattering matrices. We show that while eigen-decompositions are needed for computing a photonic structure’s scattering matrix, eigenvector derivatives can be fully sidestepped for differentiating the scattering matrix. Based on our new derivation, we present a fast and robust algorithm that, without resorting to eigenvector derivatives, computes the scattering matrix derivatives with respect to any design parameters. Our method is designed for scattering matrices in general, independent from any specific basis representation; nor is it bound to any particular geometric parameterization. To demonstrate the use of our method, we apply the scattering matrix derivatives for optimizing the design of metasurface units. We can choose different design parameterizations and use gradient-based optimization to reach various light transmission goals. We also propose a general parameterization of the meta-unit’s cross-sectional shape that can be optimized using our method. ##### 2 Background: Scattering Matrix We start by briefly reviewing the classic notion of scattering matrix in computa tional photonics, to pave the way toward its differentiation. To numerically analyze a photonic structure (such as a waveguide), the structure is often discretized along the wave propagation direction (i.e., _z_ direction) into a series of layers each with a uniform cross-sectional material distribution (Fig. 1-b). Consider optical waves of a specific frequency. Their propagation in each layer is characterized by a _scattering_ _matrix_ S, which relates waves incident on the layer from left and right sides (Fig. 1-a) to the waves scattered out in either direction. Concretely, let a L and a R denote vectors describing incident waves on the layer from left and right sides, respectively. Here a L and a R stack coefficients that represent the waves under a chosen basis, whose construction will be outlined shortly. Under the same basis, we use b L and b R to denote the scattered waves in left and right directions. With these notations, the incident and scattered 3 ~~mode 0~~ ~~mode 4~~ ~~mod~~ e 8 3.5 ### (a) (b) (c) mode 1 mode 5 mode 9 ~~mode 0~~ 3.5 mode 1 mode 2 3 mode 3 ~~mode 4~~ mode 5 mode 6 mode 7 3 2.5 2 1.5 0 0.2 0.4 0.6 0.8 1 parameter Figure 2: Repetition from symmetry. Consider a meta-atom structure (b) whose cross-sectional shape (a) is parameterized by _α_, which controls the size of the cross-shaped hollow region. The shape symmetry causes the structure’s propagating modes to have repeated effective indices (c), as also indicated by the repeated eigenvalues when one solves (2). As _α_ varies, mode 0 and mode 1 always have the same effective index, meaning that their first-order and higher-order derivatives of the corresponding eigenvalues with respect to _α_ are always the same, and thus their eigenvector derivatives are not mathematically well-defined. The same issue occurs in other modes when _α_ becomes small and more propagating modes appear (e.g., see mode 5 and mode 6 when _α_ is within _∼_ [0 _._ 3 _,_ 0 _._ 5]). waves are related through T RL T LR R R - R L _._ (1) a R - a L _,_ where S := b R - b L = S Here S is decomposed into four submatrices: R L and R R indicate how the incident wave from left or right direction is reflected by the layer, while T RL and T LR describe how the incident wave (from either direction) transmits through the layer. The computation of scattering matrix starts with a semi-discretization of the frequency-domain Maxwells equations of a photonic layer, namely, _<u>∂</u>_ _∂z_ <sup>h</sup> <sup>=</sup> <sup>Qe</sup> <sup>_,_</sup> (2) _−_ _jk_ 0 _<u>∂</u>_ _∂z_ <sup>e</sup> <sup>=</sup> <sup>Ph</sup> <sup>and</sup> _−_ _jk_ 0 where _k_ 0 is the free-space wave number, and the vectors e and h describe the electric and magnetic fields of the photonic structure under a chosen basis— for example, RCWA uses the 2D Fourier basis on the cross-section of the wave propagation direction. The matrices P and Q encode the cross-sectional distributions of material permeability and permittivity. The semi-discretization (2) is a common form in many numerical analysis methods for photonic structures (such as the method of line [28] and RCWA [24]). 4 The difference across those methods only lies in the specific ways of constructing P and Q (e.g., see Supplement 1 for their construction in RCWA). Once P and Q are determined, the scattering matrix S can be constructed. A key step of this construction is to solve an eigenvalue problem, ( PQ ) W = WΓ, to obtain eigenvectors W and the diagonal eigenvalue matrix Γ . As we will discuss in Section 3, it is this eigenproblem that renders the differentiation of the scattering matrix ill-posed. To understand the challenges and how we overcome them, we first present the recipe of computing S from W and Γ, as follows. Let Ω := ( PQ ) <u>12 .</u> Then, its eigenvalue matrix is Λ = Γ <u>12 .</u> As derived in [32], the formulas of computing the scattering matrix S defined in (1) are _,_ (3a) _,_ - (3b) R L = R R = T LR = T RL = A _−_ XBA <sup>_−_</sup> <sup>1</sup> XB A _−_ XBA <sup>_−_</sup> <sup>1</sup> XB A _−_ XBA <sup>_−_</sup> <sup>1</sup> XB �and B have the XBA <sup>_−_</sup> <sup>1</sup> XA _−_ B - _−_ 1 � A _−_ BA <sup>_−_</sup> <sup>1</sup> B - _−_ 1 X - - _−_ 1 � A _−_ BA <sup>_−_</sup> <sup>1</sup> B following� _−_ 1 X - forms: where the matrices X, A, and B have the following forms: _,_ - (3b) X = _e_ <sup>_j_</sup> <sup>Λ</sup> _k_ <sup>_<u>L</u>_</sup> 0 _,_ (4a) A = W <sup>_−_</sup> <sup>1</sup> W 0 + V <sup>_−_</sup> <sup>1</sup> V 0 _,_ and B = W <sup>_−_</sup> <sup>1</sup> W 0 _−_ V <sup>_−_</sup> <sup>1</sup> V 0 _._ (4b) Here we use _L_ to denote the layer thickness (Fig. 1), and the matrix V is related to W through V = QWΛ <sup>_−_</sup> <sup>1</sup> . W and V together form a basis of electric and magnetic components for the optical waves in the layer. Similarly, W 0 and V 0 form a basis for free space propagation, independent from the photonic structure. They are constant values for computing the derivatives of S . The vectors, a L, a R b L, and b R, in (1) are coefficients under this free-space basis to describe incident and scattered waves. Once the scattering matrices of individual layers are computed, they are combined using the Redheffer star product [29] into the total scattering matrix, one that indicates the optical response of the entire photonic structure. _Remark._ The formulas in Eqs. (3) and (4) assume that the current photonic layer is sandwiched by two free-space layers. This assumption is by no means a limitation. In an arbitrary photonic structure, the layers can be treated as if they are interleaved with free-space layers—each of which has a zero thickness. ##### 3 Differentiable Scattering Matrix The geometry or material distribution of photonic structure is specified by its structural (design) parameters (e.g., see Fig. 2). These parameters determine the structure’s permittivity and permeability distributions described by P and Q in (2). Thus, one can compute their derivatives, P <sup>_′_</sup> and Q <sup>_′_</sup>, with respect to an arbitrary parameter. Given P <sup>_′_</sup> and Q <sup>_′_</sup>, we now address the question of how to compute the scattering matrix derivative S <sup>_′_</sup> with respect to the same parameter. 5 3.1 Challenges in Scattering Matrix Differentiation The construction of scattering matrix S needs to solve an eigenvalue problem ( PQ ) W = WΓ, as the eigenvalues Γ and eigenvectors W appear in Eqs. (3) and (4) for computing S . Thus, for the differentiation of S, it seems also needed to compute the derivatives of the eigenvalues Γ and eigenvectors W . Unfortunately, the derivatives of eigenvectors in many cases are ill-defined. Most notable is when there exist _repeated_ eigenvalues. Repeated eigenvalues are not uncommon: many photonic devices have certain structural symmetries, from which eigenvalue repetition naturally emerges (see Fig. 2). For those repeated eigenvalues, their eigenvectors (up to a scale) are not uniquely determined; any set of linearly independent vectors that span the same subspace are valid eigenvectors. Because of the ambiguity, as the structural parameter changes, those eigenvectors may change discontinuously (see an examples in Supplement 1), and thus their derivatives may not be well-defined. As a result, one must carefully choose eigenvectors in the subspace of repeated eigenvalues such that the eigenvectors change continuously with respect to the structural parameter. This choice, however, is computationally expensive. As derived in [38], to ensure well-defined eigenvector derivatives, one must compute higher-order derivatives of the eigenvalues and the matrix PQ : if the repeated eigenvalues have repeated derivatives up to the _n_ -th order (see Fig. 2), then derivatives up to the ( _n_ + 1)-th order of both eigenvalues and the matrix PQ must be computed to determine first-order eigenvector derivatives. 3.2 Differentiation without Resort to Eigenvector Derivatives We now present a new algorithm for computing the scattering matrix derivative S <sup>_′_</sup> . Even in the presence of repeated eigenvalues and their derivatives, our method requires only the first-order derivatives of the matrices P and Q, completely sidestepping the differentiation of eigenvalues and eigenvectors. In comparison to the way that takes eigenvalue derivatives (as described above), our method is more robust and efficient. First, we rewrite the commonly used expressions of scattering matrix components, shown in (3), in new forms, R L = R R = T LR = T RL = 1 I _−_ D <sup>2</sup> - 1 I _−_ D <sup>2</sup> - 1 I _−_ D <sup>2</sup> 1 (5a) <sup>2</sup> 1� _−_ 1 ( D 1 D 2 _−_ D 3) _,_ (5b) <sup>2</sup> - _−_ 1 ( D 2 _−_ D 1 D 3) _,_ 1� _−_ 1 ( D 1 D 2 _−_ D 3) _,_ (5b) <sup>2</sup> - _−_ 1 ( D 2 _−_ D 1 D 3) _,_ matrix multiplications, respectively: where D 1, D 2, and D 3 denote the following matrix multiplications, respectively: (6a) D 1 := A <sup>_−_</sup> <sup>1</sup> XB = ( W 0 + TV 0) <sup>_−_</sup> <sup>1</sup> WXW <sup>_−_</sup> <sup>1</sup> ( W 0 _−_ TV 0) _,_ D 2 := A <sup>_−_</sup> <sup>1</sup> XA = ( W 0 + TV 0) <sup>_−_</sup> <sup>1</sup> WXW <sup>_−_</sup> <sup>1</sup> ( W 0 + TV 0) _,_ (6b) (6c) D 3 := A <sup>_−_</sup> <sup>1</sup> B = ( W 0 + TV 0) <sup>_−_</sup> <sup>1</sup> ( W 0 _−_ TV 0) _._ 6 The derivation of these new expressions (5) and (6) are provided in Supplement 1. In Eqs. (6), the equalities are reached by applying (4) and using T that denotes T := ΩQ <sup>_−_</sup> <sup>1</sup> . The expressions in (5) present a new route for computing scattering matrix derivative. They indicate that the scattering matrix S is determined by the three matrices, D 1, D 2, and D 3. As a result, to compute its derivative S <sup>_′_</sup> using the chain rule, we need to compute the derivatives of D 1, D 2, and D 3 with respect to the structural parameter. In Eqs. (6), both W 0 and V 0 (introduced in (4)) are constant matrices. Thus, the derivatives of D 1, D 2, and D 3 only depend on the derivatives of two other matrices in Eqs. (6), namely T and WXW <sup>_−_</sup> <sup>1</sup> . We now describe how to compute the derivatives of the two matrices, respectively. Derivative of T. The matrix T := ΩQ <sup>_−_</sup> <sup>1</sup> is related to Q and Ω := ( PQ ) <sup>1</sup> <sup>_/_</sup> <sup>2</sup> but not the eigenvalues and eigenvectors. Its derivative can be expressed as T <sup>_′_</sup> = Ω <sup>_′_</sup> Q <sup>_−_</sup> <sup>1</sup> + Ω (7) - Q <sup>_−_</sup> <sup>1</sup> permittivity <sup>�</sup> <sup>_′_</sup> = Ω <sup>_′_</sup> Q <sup>_−_</sup> <sup>1</sup> _−_ distributions ΩQ <sup>_−_</sup> <sup>1</sup> Q <sup>_′_</sup> Q <sup>_−_</sup> of <sup>1</sup> _,_ the photonic where Q depends on the material permittivity distributions of the photonic structure, and therefore its derivative Q <sup>_′_</sup> with respect to a design parameter can be directly computed (see examples in Section 4). The way of computing Ω <sup>_′_</sup> can be derived by taking the derivatives on both sides of the relation Ω <sup>2</sup> = PQ, which yields Ω <sup>_′_</sup> Ω + ΩΩ <sup>_′_</sup> = P <sup>_′_</sup> Q + PQ <sup>_′_</sup> _._ (8) Given P <sup>_′_</sup> and Q <sup>_′_</sup>, the right-hand side of this equation can be directly computed. To compute Ω <sup>_′_</sup>, we rewrite the left-hand side by denoting Ω <sup>_′_</sup> as Ω <sup>_′_</sup> = WYW <sup>_−_</sup> <sup>1</sup> for some unknown Y, where W is the eigenvector matrix of PQ . Using the fact that Ω = ( PQ ) <sup>1</sup> <sup>_/_</sup> <sup>2</sup> = WΛW <sup>_−_</sup> <sup>1</sup>, we obtain a simplified form of (8): YΛ + ΛY = W <sup>_−_</sup> <sup>1</sup> ( P <sup>_′_</sup> Q + PQ <sup>_′_</sup> ) W _._ (9) From (9), Y can be easily solved by noticing that Λ is a diagonal matrix, and therefore (9) can be written element-wise as ( _λi_ + _λj_ ) Y _ij_ = C _ij_, where _λi_ is the _i_ -th eigenvalue in Λ, and C denote the matrix on the right-hand side of (9). In other words, the elements of Y can be obtained by solving _n_ <sup>2</sup> 1D linear equations in parallel. Once Y is obtained, Ω <sup>_′_</sup> is computed using Ω <sup>_′_</sup> = WYW <sup>_−_</sup> <sup>1</sup> . We note that while this process of computing Ω <sup>_′_</sup> requires the eigenvectors W and eigenvalues Λ, they are also needed for computing the scattering matrix in the first place. Our solving process does not require the derivatives of eigenvectors. Therefore, it introduces no additional effort in terms of eigen-decomposition. Derivative of WXW <sup>_−_</sup> <sup>1</sup> . In the first glance, the derivative of WXW <sup>_−_</sup> <sup>1</sup> depends on the eigenvectors W . However, from the definition of X in (4a), we notice that WXW <sup>_−_</sup> <sup>1</sup> = _e_ <sup>_j_</sup> <sup>Ω</sup> <sup>_L/k_</sup> <sup>0</sup>, which suggests an alternative approach: take the derivative of the matrix exponential _e_ <sup>_j_</sup> <sup>Ω</sup> <sup>_L/k_</sup> <sup>0</sup> with respect to Ω . 7 A common approach of computing the matrix exponential _e_ <sup>_j_</sup> <sup>Ω</sup> <sup>_L/k_</sup> <sup>0</sup> is through the eigen-decomposition of Ω followed by the exponential of the resulting eigenvalues. If we take this approach, the derivative computation must involve the derivatives of eigenvectors, which might not be well-defined. Another approach, used by Feynman [12] and others [7,17,35], expresses the derivative of a matrix exponential using an integral that in itself involves matrix exponentials. Yet, numerically evaluating the matrix exponentials and the integral are expensive. Instead, our proposed method for computing the derivative is based on the following proposition originally proved in [25]. Proposition 1. _Consider_ _an_ _n × n_ _matrix_ Ω _and_ _its_ _derivative_ Ω <sup>_′_</sup> _with_ _respect_ _to_ _an_ _arbitrary_ _parameter._ _If_ _,_ _then_ _e_ <sup>_j_</sup> <sup>G</sup> <sup>_L/k_</sup> <sup>0</sup> = _e_ <sup>_j_</sup> <sup>Ω</sup> <sup>_L/k_</sup> <sup>0</sup> 0 _e_ <sup>_j_</sup> <sup>Ω</sup> <sup>_L/k_</sup> <sup>0</sup> - - _e_ <sup>_j_</sup> <sup>Ω</sup> <sup>_L/k_</sup> <sup>0�</sup> <sup>_′_</sup> _,_ (10) G = Ω <sup>_′_</sup> 0 Ω - Ω _where_ _the_ _top-right_ _n × n_ _block_ _matrix_ _in_ _e_ <sup>_j_</sup> <sup>G</sup> <sup>_L/k_</sup> <sup>0</sup> _is_ _the_ _derivative_ _of_ _the_ _matrix_ _exponential_ _e_ <sup>_j_</sup> <sup>Ω</sup> <sup>_L/k_</sup> <sup>0</sup> _._ In our problem, Ω <sup>_′_</sup> is computed as described above (by solving (9)), and the common way of computing _e_ <sup>_j_</sup> <sup>G</sup> <sup>_L/k_</sup> <sup>0</sup> is by taking the eigen-decomposition of G, which is again what we wish to avoid. We therefore take a different approach, the scaling and squaring method [14], to compute _e_ <sup>_j_</sup> <sup>G</sup> <sup>_L/k_</sup> <sup>0</sup> —without the need of eigen-decomposition. The scaling and squaring method exploits the relation _e_ <sup>A</sup> = _n × n_ matrix A . In practice, _σ_ is chosen to be _σ_ = 2 <sup>_s_</sup> for some� _e_ <sup>A</sup> non-negative <sup>_/σ_</sup> <sup>�</sup> <sup>_σ_</sup> for any integer _s_ . The idea is to have the norm of A _/σ_ sufficiently small such that _e_ <sup>A</sup> <sup>_/σ_</sup> can be well approximated by a Pad´e approximant near the origin. The Pad´e approximant is a rational polynomial of A . Its evaluation requires only matrix multiplications and inverse, but no eigen-decomposition. The scaling and squaring method is robust and accurate, and has been used in many numerical tools (such as MATLAB’s expm function). When applying this method, we further exploit the specific structure of G (i.e., its bottom-left block matrix vanishes, and its two diagonal block matrices are identical) to tailor the method for improving computational performance. Supplement 1 presents our detailed derivations and computational steps. ##### 4 Results This section presents our numerical results. First, we validate our algorithm for computing scattering matrix derivatives. Next, to demonstrate the use of scattering matrix derivatives in photonics, we optimize the geometry of photonic metasurface units (also called _meta-atoms_ ). Meta-atoms are the building blocks of a metasurface, often designed based on physical intuitions and manually crafted libraries [26, 27, 42]. More recently, inverse design methods of meta-atom structures have also been explored— 8 3.1 FDFD #### (a) (b) (c) RCWA 90 120 60 <u>1</u> RCWA Lumerical-FDTD 30 0 330 <u>1</u> ~~0.8~~ <u>0.</u> ~~<u>6</u>~~ ~~<u>0.4</u>~~ ~~<u>0.</u>~~ <u>2</u> ~~<u>0</u>~~ 1.6 1.5 1.4 1.3 1.2 ###### z 3 2.9 ###### x 2.8 1.2 1.3 1.4 1.5 1.6 wavelength ( µ m) 150 180 210 240 300 270 Figure 3: Accuracy comparison. (a) We use our method and FDTD (Lumerical [36]) to analyze a 3D meta-atom. The width of the pillar and its square hole are 0 _._ 6 _µ_ m and 0 _._ 2 _µ_ m, respectively, and it has a height of 1.4 _µ_ m. We use the periodic boundary condition, with the period of 0 _._ 66 _µ_ m. (b) We scan the (x-polarized) wavelength and plot the effective indices of the fundamental mode evaluated by FDFD and our method. (c) For each wavelength (color mapped here), we compute the far-field amplitudes and phases changes, and compare our results to FDTD. e.g., through finite-difference-based gradient descent [6], adjoint-based level-set method [23], and topological optimization [22,33]. Due to fabrication constraints, meta-atoms often have constant cross-sectional shapes along one direction (i.e., _z_ -direction, as shown in Fig. 3-a). Thus, the semi-analytical methods (such as RCWA) are particularly efficient for simulating meta-atoms, thanks to their ability of _not_ discretizing along _z_ -direction [24]. Our method, for the first time, enables the semi-analytical methods to also compute scattering matrix derivatives with respect to design parameters. Here, in the framework of RCWA, we demonstrate automatic discovery of meta-atom structures that reach various amplitude and phase goals. 4.1 Validation To validate our algorithm, we consider a dielectric meta-atom used in metasurface holography [26,27]. Its structure is shown in Fig. 3-a. We use Eqs. (5) to compute the scattering matrix, for which the matrices P and Q (introduced in (2)) are constructed using RCWA. The scattering matrix allows us to compute light propagation properties of the meta-atom, which are in turn compared to the results from finite difference time domain (FDTD) method implemented in Lumerical [36]. We first scan the light wavelength from 1 _._ 2 _µ_ m to 1 _._ 6 _µ_ m. For each wavelength, we compute, using our scattering matrix and FDFD respectively, the effective index of the fundamental mode propagating in the meta-atom. The results from our method agree with FDFD results (see Fig. 3-b). Furthermore, we consider 9 2 0 -2 -4 -6 2 4 <u>× 10</u> <sup><u>−6</u></sup> <u>× 10</u> <sup><u>−6</u></sup> <u>× 10</u> <sup><u>−6</u></sup> <u>+ 3.54362</u> <u>× 10</u> <sup><u>−6</u></sup> <u>−8.85759</u> 4 ##### (a) -6 -4 (b) ∆α ~~<u>10</u>~~ 4: <sup>~~−2~~</sup> Scattering ~~<u>10</u>~~ <sup>~~−6~~</sup> ~~<u>10</u>~~ <sup>~~−10~~</sup> matrix ~~<u>10</u>~~ <sup>~~−14~~</sup> derivatives. ~~10~~ We <sup>~~−2~~</sup> choose ~~10~~ <sup>~~−6~~</sup> ~~10~~ two <sup>~~−10~~</sup> matrix ~~10~~ <sup>~~−14~~</sup> ##### (a) ##### -6 -4 (b) -4 ##### ∆α ∆α ~~10~~ <sup>~~−2~~</sup> ~~10~~ <sup>~~−6~~</sup> ~~10~~ <sup>~~−10~~</sup> ~~10~~ <sup>~~−14~~</sup> 2 4 real imag 4 2 0 -2 -4 real imag 2 0 -2 -4 0 -2 -4 -6 Figure 4: Scattering matrix derivatives. We choose two matrix elements in the scattering matrix, and plot their FD derivatives estimated with different FD sizes (∆ _α_ in _x_ -axis) in (a) and (b), respectively. In each plot, the red and blue solid curves correspond to the real and imaginary parts of the estimated derivative. Meanwhile, the derivatives computed by our method are indicated by the red (real) and blue (imaginary) horizontal dash lines. These plots show that FD estimation is highly sensitive to ∆ _α_ . Light green regions indicate valid ∆ _α_ ranges for both matrix elements. The valid ∆ _α_ varies element by element. Thus, in practice, it is hard to choose a proper ∆ _α_ for the entire scattering matrix, whereas our method is always robust. the far-field light transmission through the meta-atom, and compute the phase shift and amplitude change for each wavelength. Again, the results from our method and FDTD match closely, as shown in Fig. 3-c. These experiments confirm that our scattering matrix computation is as accurate as FDTD in Lumerical. In terms of computational cost, our method takes about 0.15 seconds for each monochromatic simulation, and a few seconds for the entire 1 _._ 2 _µ_ m-1 _._ 6 _µ_ m wavelength range, whereas the FDTD simulation takes several minutes. Next, we validate our derivative computation. We consider again the metaatom structure shown in Fig. 3-a, and choose the parameter _α_ to be the size of the hollow square. Using our method, we compute the derivative of the structure’s scattering matrix with respect to _α_ . Meanwhile, since there is no analytic expression of the scattering matrix derivative, we approximate it using finite difference (FD) estimation, that is, _<u>∂</u>_ <u>S</u> _._ (11) 2∆ _α_ _∂α_ <sup>_≈_</sup> <sup><u>S</u></sup> <sup><u>(</u></sup> <sup>_<u>α</u>_</sup> <sup><u>+ ∆</u></sup> <sup>_<u>α</u>_</sup> <sup><u>)</u></sup> <sup>_<u>−</u>_</sup> <sup><u>S</u></sup> <sup><u>(</u></sup> <sup>_<u>α −</u>_</sup> <sup><u>∆</u></sup> <sup>_<u>α</u>_</sup> <sup><u>)</u></sup> We estimate _∂α_ <sup>_<u>∂</u>_</sup> <sup><u>S</u></sup> <sup>using</sup> <sup>a</sup> <sup>sweeping</sup> <sup>range</sup> <sup>of</sup> <sup>∆</sup> <sup>_α_</sup> <sup>values,</sup> <sup>and</sup> <sup>compare</sup> <sup>them</sup> <sup>to</sup> <sup>the</sup> derivative resulted from our method. The results are illustrated in Fig. 4. The accuracy of FD approximation largely depends on the choice of ∆ _α_ . Only when ∆ _α_ is chosen within a certain range, FD approximation is accurate enough to agree with our derivative results. This agreement confirms the correctness of our method. But for different elements 10 (a) (b) 150 180 210 (c) β y ~~α~~ z x x 90 120 1 60 1 0.8 0.6 0.4 0.2 ~~0~~ 0 0.2 π 0.4 π 0.6 π 0.8 π π 1.2 π 1.4 π 1.6 π 1.8 π target optimized global 30 0 330 240 300 270 Figure 5: Optimization of (12) . (a) We optimize the cross-sectional shape specified by two design parameters _α_ and _β_ in order to reach a target transmission amplitude and phase. We examine different targets evenly sampled on a circle on the complex plane (indicated by the square dots in (b)). The optimized amplitudes and phases (indicated by triangular dots) reach closely to the targets. As a reference, we also show the amplitudes and phases (in circular dots) of the designs that globally minimize (12), that is, ones obtained through a slow, exhaustive search of all parameter combinations. While no gradient-based optimization algorithm can guarantee the global minimum of (12), our results approach the targets closely, comparable to what the global minimums can achieve. The resulting cross-sectional shape for each sampled target are shown in (c). in the scattering matrix, the valid ∆ _α_ range varies (indicated in light green in Fig. 4), suggesting that FD approximation is impractical: it is hard, if not impossible, to choose a proper ∆ _α_ to produce accurate derivative estimations for all elements in the scattering matrix. In contrast, our method is robust for computing the derivatives. Computational cost. In addition to the robustness, our method is also faster than the FD method. In the FD method, computing a matrix derivative requires the computation of two scattering matrices S ( _α_ + ∆ _α_ ) and S ( _α −_ ∆ _α_ ). In contrast, our method, in addition to computing S ( _α_ ), only requires a few matrix multiplications and inverses (recall Section 3.3.2). On our workstation computer, the overhead of computing a scattering matrix derivative is about 30% _∼_ 40% of the cost for computing the scattering matrix itself. 11 ###### (a) (b) 0.2 0.4 0.6 0.8 <u>α</u> β <u>α</u> β y z x 1 x x 0.2 0.4 0.6 0.8 1 blue ###### (c) 0.2 (d) 0.2 0.2 0.2 0.2 0.4 0.6 0.8 1 0.4 0.6 0.8 1 0.4 0.6 0.8 1 0.2 0.4 0.6 0.8 1 0.15 0.1 0.05 0 blue blue Figure 6: Optimization of (14) . (a) We optimize meta-atom structures described by two archetypes, each with two parameters. The goal is to obtain desired amplitude responses at two separate wavelengths (i.e., 1.2 _µ_ m (blue) and 1.6 _µ_ m (red)), simultaneously. We sample five amplitudes from 0.2 to 1 for each wavelength, forming 25 different optimization targets. Each target leads to a different cross-sectional design shown in (b). For red light, the discrepancies between achieved amplitudes and the targets are shown in (c), and the same visualization for blue light is shown in (d). 4.2 Use Case: Optimization of Meta-atom Structure Controlling phase and amplitude of monochromatic light. First, we optimize meta-atom structures to reach specific transmitted amplitudes and phases for a monochromatic light (at 1.55 _µ_ m wavelength, _x_ -polarized). The cross-sectional shape is shown in Fig. 5-a, determined by two parameters. The objective function for the inverse design is defined as _L_ = _|_ T LR( _m, m_ ) _−_ _tm|_ <sup>2</sup> _,_ (12) where T LR is the transmission submatrix in the scattering matrix (recall (1)), _m_ is the mode index for the incident and outgoing light in free space, thus T LR( _m, m_ ) denotes the _m_ -th diagonal element of the matrix. Also, _tm_ is a complex constant specifying the target amplitude and phase of the transmission. 12 (a) (b) 0 ###### ~~α~~ ###### β Ey 0.2 0.4 0.6 0.8 z <u>y</u> x x (c) 0.2 (d) 0 0.2 0.4 0.6 0.8 Ex 0 0 0.2 0 0.2 0.4 0.6 0.8 0.2 0.4 0.6 0.8 Ey 0.2 0.4 0.6 0.8 Ey 0 0.2 0.4 0.6 0.8 0.16 0.12 0.08 0.04 0 Ex Ex Figure 7: Optimization of (13) . (a) We optimize the meta-atom structure described by two parameters. The goal is to achieve certain phase changes for _x_ and _y_ -polarized light simultaneously. (b) We sample six target phase changes for _x_ - and _y_ -polarized light, respectively. Their combination forms 36 different optimization targets. For each target, our optimization produces a cross-sectional shape design. (c) For _x_ -polarized incident light, we show the residual (in terms of phase angle difference) between each pair of inversely designed phase change and the target. And similar visualization for _y_ -polarized light is shown in (d). 13 Here we consider the fundamental mode (the way to choose corresponding _m_ is given in Supplemental 1), which describes the far-field light transmission along the _z_ -direction. To verify the robustness of our method and the enabled optimization, we evenly sample different targets _tm_ on a circle on the complex plane (see Fig. 5-b). For each target, we find meta-atom’s shape parameters by minimizing (12) through a gradient-descent algorithm [31], for which the gradients of (12) with respect to the design parameters are computed using our method. As shown in Fig. 5-b, we are able to automatically discover structures that reach these targets closely. Controlling phases for both _x−_ and _y−_ polarized light. Next, we optimize meta-atom structures to obtain target responses for _x_ - and _y_ -polarized light, simultaneously. This type of meta-atoms has been used to construct metasurface holograms [10]. In our example, the light wavelength is 1.3 _µ_ m; the meta-atoms have a fixed height of 2.0 _µ_ m and a period of 2.5 _µ_ m along _x_ - and _y_ -direction. The cross-sectional shape of the meta-atoms are specified by two parameters shown in Fig. 7-a. We determine the parameters by minimizing the following objective function: _L_ = _−_ <sup><u>T</u></sup> <sup><u>LR(</u></sup> <sup>_<u>mx, mx</u>_</sup> <sup><u>)</u></sup> _|_ T LR( _mx, mx_ ) _x_ <sup>_−_</sup> <sup><u>T</u></sup> <sup><u>LR(</u></sup> <sup>_<u>my, my</u>_</sup> <sup><u>)</u></sup> <sup>_∗_</sup> _|_ T LR( _my, my_ ) <sup><u>T</u></sup> <sup><u>LR(</u></sup> <sup>_<u>mx, mx</u>_</sup> <sup><u>)</u></sup> _x_ _|_ T LR( _mx, mx_ ) _|_ <sup>_t∗_</sup> _y_ <sup><u>T</u></sup> <sup><u>LR(</u></sup> <sup>_<u>my, my</u>_</sup> <sup><u>)</u></sup> _|_ T LR( _my, my_ ) _|_ <sup>_t∗_</sup> _y_ <sup>_,_</sup> (13) where the subscript _x_ (and _y_ ) indicates light polarization; _tx_ (and _ty_ ) are the target phase changes from _x_ -polarized (and _y_ -polarized) incident light to the outgoing light with the same polarization (i.e., _tx_ = exp( _iφx_ ) for some _φx_ ). The first term in (13) measures, for the _x_ -polarized light, the cosine difference (through dot product on complex plane) between the _m_ -th mode’s phase change and the target phase change, and similarly for the second term. The optimized structures for different _x_ - and _y_ -polarized phase targets are shown in Fig. 7. In all cases, the residual between the target and the resulting phase change is within 7% of one period (2 _π_ ), and in most cases within 1%. Controlling amplitudes for multiple wavelengths. We also demonstrate inverse design of meta-atoms for another type of optical response: obtain two target amplitude responses at two separate wavelengths, simultaneously. This type of responses have proven useful for making colored metasurface holograms [26,27]. Here we consider two archetypes used in [27], each described by two parameters (see Fig. 6-a). The two wavelengths under consideration are 1.2 _µ_ m (labeled as blue) and 1.6 _µ_ m (red), and the objective function is defined as 2 _|_ T LR _,_ 2( _m, m_ ) _|_ <sup>2</sup> _−_ _A_ <sup>2</sup> 2 _._ (14) <sup>2</sup> �2 _L_ = 1 _|_ T LR _,_ 1( _m, m_ ) _|_ <sup>2</sup> _−_ _A_ <sup>2</sup> 1 + <sup>2</sup> �2 Here the subscript “1” and “2” indicate the blue (1.2 _µ_ m) and red (1.6 _µ_ m) wavelength, respectively. The first term accounts for the blue wavelength: T LR _,_ 1 is the transmission submatrix of the scattering matrix and _A_ 1 is the desired 14 amplitude. Similar is the second term. More terms can be added in (14) to incorporate more than two wavelengths. For each archetype, we find its parameter values via a gradient-descent algorithm that minimizes (14), and choose between the two archetypes one that produces a smaller objective value. The optimized structures and their performances are shown in Fig. 6. For almost all the experiments (each with a different amplitude target), the resulting amplitudes by the inversely designed meta-atoms match closely to their targets. General cross-sectional shape design. Lastly, we introduce a new way to inverse design the meta-atom’s cross-sectional shape under a general representation. We use the star-convex polygon [37] to represent the cross-sectional shape. Such a shape can be discretized by sampling _N_ points on its boundary so that the polar angles of these points are evenly distributed over [0 _,_ 2 _π_ ]. In other words, the ( _k_ + 1)-th point has the coordinate _pk_ [cos (2 _kπ/N_ ) _, −_ sin (2 _kπ/N_ )], where _pk_ is a non-negative value (see Fig. 8-a), and the shape is specified by _N_ parameters _p_ 1 _, . . ., pN_ . A large _N_ offers many degrees of freedom to represent a complex shape, but meanwhile renders exhaustive search through the entire parameter space too expensive—one must rely on numerical optimization methods to determine the parameter values. This shape representation is particularly suitable for RCWA-based analysis, as it allows for a closed-form 2D Fourier transform of the shape (and thus the permittivity distribution) [21]. In RCWA framework, 2D Fourier transform of the cross-sectional permittivity distribution is needed for computing the matrices, P and Q, as well as their derivatives with respect to the _pk_ parameters. Supplemental 1 provides the details of this process. As examples, we optimize octagons ( _N_ = 8) to obtain desired optical responses in different scattering directions. First, we specify the target scattering directions. Notice that to predict optical behavior of a single meta-atom in simulation, periodic boundary condition is often used. Under this condition, the meta-atom is effectively a 2D grating structure, for which we can use diffraction orders to specify different scattering directions: the output light with diffraction order ( _p, q_ ) is along the direction _k_ = _Lx_ - <u>2</u> _<u>πp</u>_ _,_ <sup><u>2</u></sup> <sup>_<u>πq</u>_</sup> _Ly_ _,_ 1 _,_ (15) where _Lx_ and _Ly_ are periods along _x_ - and _y_ -axis, respectively ( _Lx_ = _Ly_ = 1 _µ_ m in our examples). We consider _x_ -polarized light with the wavelength of 1.55 _µ_ m. The goal here is to obtain specified far-field phases and amplitudes at two scattering directions—ones that correspond to the diffraction orders, ( _−_ 1 _,_ 0) and (1 _,_ 0), as shown in Fig. 8-b. We further restrict _pk_ to be in the range [0 _._ 15 _µ_ m _,_ 0 _._ 45 _µ_ m], and determine _pk_ values by minimizing (16) _L_ = _|_ T LR( _m, n_ 1) _−_ _t_ 1 _|_ <sup>2</sup> + _|_ T LR( _m, n_ 2) _−_ _t_ 2 _|_ <sup>2</sup> _,_ 15 (a) 0.08 0.04 (b) z x y (1,0) z (1,0) (-1,0) 1 <u>(c)</u> <u>(d)</u> 0.5 0 0 100 200 300 400 500 0 0 100 200 300 iteration iteration Figure 8: Inverse design of star-convex meta-atoms. (a) The star-convex polygon is used to represent the cross-section of a meta-atom, defined by many control variables ( _p_ 1. . . _p_ 8 in this case). As an example, we inverse design the shape for reaching target amplitudes and phases in two scattering directions (i.e., corresponding to diffraction orders (-1,0) and (1,0) in (b)) simultaneously. (c-d) We perform two experiments to reach two sets of ( _t_ 1 _, t_ 2) goals shown in the plots. In each experiment, our optimization finds the design parameters within hundreds of iterations, resulting in nontrivial shapes that are hard to be manually designed. where _n_ 1 and _n_ 2 are mode indices for the diffraction orders ( _−_ 1 _,_ 0) and (1 _,_ 0), respectively; and _t_ 1 and _t_ 2 specify the target phases and amplitudes (as complex values) in the two outgoing directions. We perform two experiments for two sets of _t_ 1 and _t_ 2 goals. The optimization convergence curves and resulting shapes are shown in Fig. 8. ##### 5 Conclusion We have presented an algorithm for computing the derivatives of the scattering matrices of a photonic structure with respect to its structural parameters. Our method is built on the framework of semi-analytical methods for analyzing photonic structures. A key step in semi-analytical methods for computing scattering matrices is the eigen-decomposition. However, to compute scattering matrix derivatives, directly differentiating the eigenvalue analysis poses significant difficulties. We show a new route to compute scattering matrix derivatives without the need of differentiating the eigen-decomposition process. The scattering matrix derivatives present how a photonic structure’s performance changes as its structural parameters vary. While we demonstrated their use in the optimization of meta-atom units, they are useful in many other 16 applications. Therefore, our method may serve as a useful analysis tool in a wide range of photonic design tasks. ##### Funding National Science Foundation (CAREER-1453101, 1717178, 1816041). ##### Acknowledgments We thank Nanfang Yu for valuable suggestions. ##### Disclosures The authors declare no conflicts of interest. See Supplement 1 for supporting content. ##### References [1] Ahmed, A., Liscidini, M., and Gordon, R. Design and analysis of high-index-contrast gratings using coupled mode theory. <u>IEEE</u> <u>Photonics</u> <u>Journal</u> <u>2,</u> 6 (2010), 884–893. [2] Akel, H., and Webb, J. Design sensitivities for scattering-matrix calcu lation with tetrahedral edge elements. <u>IEEE</u> <u>transactions</u> <u>on</u> <u>magnetics</u> <u>36,</u> 4 (2000), 1043–1046. [3] Arbabi, A., Horie, Y., Bagheri, M., and Faraon, A. Dielectric meta surfaces for complete control of phase and polarization with subwavelength spatial resolution and high transmission. <u>Nature</u> <u>nanotechnology</u> <u>10,</u> 11 (2015), 937–943. [4] Arbabi, E., Arbabi, A., Kamali, S. M., Horie, Y., and Faraon, A. Multiwavelength polarization-insensitive lenses based on dielectric metasurfaces with meta-molecules. <u>Optica</u> <u>3,</u> 6 (2016), 628–633. [5] Arbabi, E., Kamali, S. M., Arbabi, A., and Faraon, A. Full-stokes imaging polarimetry using dielectric metasurfaces. <u>ACS</u> <u>Photonics</u> <u>5,</u> 8 (2018), 3132–3140. [6] Backer, A. S. Computational inverse design for cascaded systems of metasurface optics. <u>Optics</u> <u>express</u> <u>27,</u> 21 (2019), 30308–30331. [7] Bellman, R. <u>Introduction</u> <u>to</u> <u>matrix</u> <u>analysis,</u> vol. 19. Siam, 1997. [8] Blau, Y., Eitan, M., Egorov, V., Boag, A., Hanein, Y., and Scheuer, J. In situ real-time beam monitoring with dielectric metaholograms. <u>Optics</u> <u>express</u> <u>26,</u> 22 (2018), 28469–28483. 17 [9] Cao, Q., Lalanne, P., and Hugonin, J.-P. Stable and efficient bloch mode computational method for one-dimensional grating waveguides. <u>JOSA</u> <u>A</u> <u>19,</u> 2 (2002), 335–338. [10] Chen, W. T., Yang, K.-Y., Wang, C.-M., Huang, Y.-W., Sun, G., Chiang, I.-D., Liao, C. Y., Hsu, W.-L., Lin, H. T., Sun, S., Zhou, L., Liu, A. Q., and Tsai, D. P. High-efficiency broadband meta-hologram with polarization-controlled dual images. <u>Nano letters 14, 1 (2014), 225–230.</u> [11] Colburn, S., Zhan, A., and Majumdar, A. Varifocal zoom imaging with large area focal length adjustable metalenses. <u>Optica</u> <u>5,</u> 7 (2018), 825–831. [12] Feynman, R. P. An operator calculus having applications in quantum electrodynamics. <u>Physical</u> <u>Review</u> <u>84,</u> 1 (1951), 108. [13] Fitio, V., Yaremchuk, I., Bendzyak, A., and Bobitski, Y. Applica tion rcwa for studying plasmon resonance under diffraction by metal gratings. In <u>2017</u> <u>IEEE</u> <u>First</u> <u>Ukraine</u> <u>Conference</u> <u>on</u> <u>Electrical</u> <u>and</u> <u>Computer</u> <u>Engineering</u> <u>(UKRCON)</u> (2017), IEEE, pp. 667–670. [14] Higham, N. J. The scaling and squaring method for the matrix exponential revisited. <u>SIAM</u> <u>Journal</u> <u>on</u> <u>Matrix</u> <u>Analysis</u> <u>and</u> <u>Applications</u> <u>26,</u> 4 (2005), 1179–1193. [15] Joannopoulos, J., Meade, R., and Winn, J. Photonic crystals. Molding <u>the</u> <u>flow</u> <u>of</u> <u>light</u> (1995). [16] Kamali, S. M., Arbabi, E., Arbabi, A., Horie, Y., Faraji-Dana, M., and Faraon, A. Angle-multiplexed metasurfaces: encoding independent wavefronts in a single metasurface under different illumination angles. <u>Physical</u> <u>Review</u> <u>X</u> <u>7,</u> 4 (2017), 041056. [17] Karplus, R., and Schwinger, J. A note on saturation in microwave spectroscopy. <u>Physical</u> <u>Review</u> <u>73,</u> 9 (1948), 1020. [18] Kwiecien, P., Richter, I., and Ctyrok <sup>ˇ</sup> y,` J. Rcwa/arcwa-an efficient and diligent workhorse for nanophotonic/nanoplasmonic simulations-can it work even better? In <u>2015</u> <u>17th</u> <u>International</u> <u>Conference</u> <u>on</u> <u>Transparent</u> <u>Optical</u> <u>Networks</u> <u>(ICTON)</u> (2015), IEEE, pp. 1–8. [19] Lalanne, P., and Silberstein, E. Fourier-modal methods applied to waveguide computational problems. <u>Optics Letters 25, 15 (2000), 1092–1094.</u> [20] Lalau-Keraly, C. M., Bhargava, S., Miller, O. D., and Yablonovitch, E. Adjoint shape optimization applied to electromagnetic design. <u>Optics</u> <u>express</u> <u>21,</u> 18 (2013), 21693–21701. [21] Lee, S.-W., and Mittra, R. Fourier transform of a polygonal shape function and its application in electromagnetics. <u>IEEE</u> <u>Transactions</u> <u>on</u> <u>Antennas</u> <u>and</u> <u>Propagation</u> <u>31,</u> 1 (1983), 99–103. 18 [22] Lin, Z., Liu, V., Pestourie, R., and Johnson, S. G. Topology optimization of freeform large-area metasurfaces. <u>Optics</u> <u>express</u> <u>27,</u> 11 (2019), 15765–15775. [23] Mansouree, M., and Arbabi, A. Metasurface design using levelset and gradient descent optimization techniques. In <u>2019</u> <u>International</u> <u>Applied</u> <u>Computational</u> <u>Electromagnetics</u> <u>Society</u> <u>Symposium</u> <u>(ACES)</u> (2019), IEEE, pp. 1–2. [24] Moharam, M., and Gaylord, T. Rigorous coupled-wave analysis of planar-grating diffraction. <u>JOSA</u> <u>71,</u> 7 (1981), 811–818. [25] Najfeld, I., and Havel, T. F. Derivatives of the matrix exponential and their computation. <u>Advances</u> <u>in</u> <u>applied</u> <u>mathematics</u> <u>16,</u> 3 (1995), 321–375. [26] Overvig, A., Shrestha, S., Xiao, C., Zheng, C., and Yu, N. Two-color and 3d phase-amplitude modulation holograms. In <u>CLEO:</u> <u>QELS</u> ~~<u>F</u>~~ <u>undamental</u> <u>Science</u> (2018), Optical Society of America, pp. FF1F– 6. [27] Overvig, A. C., Shrestha, S., Malek, S. C., Lu, M., Stein, A., Zheng, C., and Yu, N. Dielectric metasurfaces for complete and independent control of the optical amplitude and phase. <u>Light:</u> <u>Science</u> <u>&</u> <u>Applications</u> <u>8,</u> 1 (2019), 1–12. [28] Pregla, R., and Pascher, W. The method of lines. Numerical techniques <u>for</u> <u>microwave</u> <u>and</u> <u>millimeter</u> <u>wave</u> <u>passive</u> <u>structures</u> <u>1</u> (1989), 381–446. [29] Redheffer, R. Difference equations and functional equations in transmission-line theory. <u>Modern</u> <u>mathematics</u> <u>for</u> <u>the</u> <u>engineer</u> <u>12</u> (1961), 282–337. [30] Rephaeli, E., Raman, A., and Fan, S. Ultrabroadband photonic structures to achieve high-performance daytime radiative cooling. <u>Nano</u> <u>letters</u> <u>13,</u> 4 (2013), 1457–1461. [31] Ruder, S. An overview of gradient descent optimization algorithms. <u>arXiv</u> <u>preprint</u> <u>arXiv:1609.04747</u> (2016). [32] Rumpf, R. C. Improved formulation of scattering matrices for semianalytical methods that is consistent with convention. <u>Progress</u> <u>In</u> <u>Electromagnetics</u> <u>Research</u> <u>35</u> (2011), 241–261. [33] Sell, D., Yang, J., Doshay, S., Yang, R., and Fan, J. A. Large-angle, multifunctional metagratings based on freeform multimode geometries. Nano <u>letters</u> <u>17,</u> 6 (2017), 3752–3757. [34] Shen, Y., Rinnerbauer, V., Wang, I., Stelmakh, V., Joannopoulos, J. D., and Soljacic, M. Structural colors from fano resonances. <u>Acs</u> <u>Photonics</u> <u>2,</u> 1 (2015), 27–32. 19 [35] Snider, R. Perturbation variation methods for a quantum boltzmann equation. <u>Journal</u> <u>of</u> <u>Mathematical</u> <u>Physics</u> <u>5,</u> 11 (1964), 1580–1587. [36] Solutions, F. Lumerical solutions inc. <u>Vancouver,</u> <u>Canada</u> (2003). [37] Stanek, J. C. A characterization of starshaped sets. <u>Canadian</u> <u>Journal</u> <u>of</u> <u>Mathematics</u> <u>29,</u> 4 (1977), 673–680. [38] van der Aa, N., Ter Morsche, H., and Mattheij, R. Computation of eigenvalue and eigenvector derivatives for a general complex-valued eigensystem. <u>The</u> <u>electronic</u> <u>journal</u> <u>of</u> <u>linear</u> <u>algebra</u> <u>16</u> (2007). [39] Veronis, G., Dutton, R. W., and Fan, S. Method for sensitivity analysis of photonic crystal devices. <u>Optics</u> <u>letters</u> <u>29,</u> 19 (2004), 2288–2290. [40] Wang, K. X., Yu, Z., Liu, V., Cui, Y., and Fan, S. Absorption enhancement in ultrathin crystalline silicon solar cells with antireflection and light-trapping nanocone gratings. <u>Nano</u> <u>letters</u> <u>12,</u> 3 (2012), 1616–1619. [41] Wang, Z., and Yu, Z. Spectral analysis based on compressive sensing in nanophotonic structures. <u>Optics</u> <u>Express</u> <u>22,</u> 21 (2014), 25608–25614. [42] Yu, N., Aieta, F., Genevet, P., Kats, M. A., Gaburro, Z., and Capasso, F. A broadband, background-free quarter-wave plate based on plasmonic metasurfaces. <u>Nano</u> <u>letters</u> <u>12,</u> 12 (2012), 6328–6333. [43] Zhao, R., Sain, B., Wei, Q., Tang, C., Li, X., Weiss, T., Huang, L., Wang, Y., and Zentgraf, T. Multichannel vectorial holographic display and encryption. <u>Light:</u> <u>Science</u> <u>&</u> <u>Applications</u> <u>7,</u> 1 (2018), 1–9. [44] Zhou, Y., Kravchenko, I. I., Wang, H., Zheng, H., Gu, G., and Valentine, J. Multifunctional metaoptics based on bilayer metasurfaces. <u>Light:</u> <u>Science</u> <u>&</u> <u>Applications</u> <u>8,</u> 1 (2019), 1–9. [45] Zhu, Z., Dave, U. D., Lipson, M., and Zheng, C. Inverse geometric design of fabrication-robust nanophotonic waveguides. In <u>CLEO:</u> <u>Science</u> <u>&</u> <u>Innovations</u> (2020), Optical Society of America. 20 ## Differentiable Scattering Matrix for Optimization of Photonic Structures: supplemental document Ziwei Zhu <sup>1</sup> and Changxi Zheng <sup>1,*</sup> 1Department of Computer Science, Columbia University, New York, New York 10027, USA *Corresponding author: cxz@cs.columbia.edu September 23, 2020 Abstract This document provides supplementary information to the paper “Differentiable Scattering Matrix for Optimization of Photonic Structures”. ##### 1 Matrix Construction in RCWA 1.1 Construct Wave Equation Coefficient Matrices When analyzing a meta-atom structure, we use _z_ -direction to indicate the wave propagation direction, and use periodic boundary condition on _x_ - _y_ plane. In the framework of RCWA, the electric and magnetic fields at a distance _z_ are represented under a set of Fourier basis functions (also called harmonics). Suppose the E- or H-field is represented using _nx × ny_ harmonics. The _i_ -th harmonic along the _x_ -axis together with the _j_ -th harmonic along the _y_ -axis describes a wave vector projected on the _x_ - _y_ plane, that is, _ki,j_ = ( _kix, kjy_ ) (1) �� _i −_ <sup>_<u>nx</u>_</sup> <sup><u>+ 1</u></sup> 2 _j −_ <sup>_<u>ny</u>_</sup> <sup><u>+ 1</u></sup> 2 = _Lx_ - <u>2</u> _<u>π</u>_ 2 _,_ <sup><u>2</u></sup> <sup>_<u>π</u>_</sup> _Ly_ where _Lx_ and _Ly_ are periods along _x_ - and _y_ -axis, respectively. When _i_ = <sup>_<u>nx</u>_</sup> 2 <sup><u>+1</u></sup> 2 and _j_ = <sup>_<u>ny</u>_</sup> 2 <sup><u>+1</u></sup>, the wave vector _⃗ki,j_ = _⃗_ 0, corresponding to the wave propagating and _j_ = <sup>_<u>ny</u>_</sup> 2 <sup><u>+1</u></sup>, the wave vector _⃗ki,j_ = _⃗_ 0, corresponding to the wave propagating only along _z_ -direction. With these Fourier basis functions, the E-field at a distance _z_ can be expressed as _E_ ( _x, y, z_ ) = _nx_ _i_ =1 _ci,j_ ( _z_ ) _e_ <sup>_j_</sup> <sup>(</sup> <sup>_kixx_</sup> <sup>+</sup> <sup>_kjyy_</sup> <sup>)</sup> _,_ (2) _i_ =1 _ny_ _j_ =1 _j_ =1 1 where _ci,j_ ( _z_ ) are Fourier coefficients, and they are functions of _z_ . In other words, (2) is a representation using separation of variables. It discretizes the field on _x_ - _y_ plane but remain analytic along _z_ -direction. The H-field can be (semi-)discretized in the same way. Substituting (2) into the frequency-domain Maxwell’s equations leads to the semi-discussed equations (2) in the main text. Here, for the sake of simplicity of the presentation and following the use in common situations, we assume the materials are non-ferromagnetic. Then, the coefficient matrices P and Q in Eqn. (2) have the following forms, (3) and P = Q = K _x_ [[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> K _y_ _k_ 0 <sup>2</sup> 0 <sup>I</sup> - K _y_ [[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> K _y −_ _k_ <sup>2</sup> _−_ K _x_ K _y_ K _x_ K _x −_ _k_ 0 <sup>2</sup> - _k_ 0 <sup>2[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> <sup>_−_</sup> <sup>K</sup> <sup>_y_</sup> <sup>K</sup> <sup>_y_</sup> K _y_ K _x_ K _x_ [[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> K _y_ _k_ 0 <sup>2</sup> <sup>I</sup> <sup>_−_</sup> <sup>K</sup> <sup>_x_</sup> <sup>[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> <sup>_−_</sup> <sup>1</sup> <sup>K</sup> <sup>_x_</sup> K _y_ [[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> K _y −_ _k_ 0 <sup>2</sup> <sup>I</sup> _−_ K _y_ [[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> K _x_ _−_ K _x_ K _y_ K _x_ K _x −_ _k_ 0 <sup>2[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> _k_ 0 <sup>2[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> <sup>_−_</sup> <sup>K</sup> <sup>_y_</sup> <sup>K</sup> <sup>_y_</sup> K _y_ K _x_ 0 <sup>2[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> <sup>_−_</sup> <sup>K</sup> <sup>_y_</sup> <sup>K</sup> <sup>_y_</sup> K _y_ K _x_ 0 <sup>2</sup> <sup>I</sup> _−_ K _y_ [[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> K _x_ _,_ where _k_ 0 = 2 <sup>_<u>π</u>_</sup> _λ_ <sup>for</sup> <sup>the</sup> <sup>considered</sup> <sup>wavelength</sup> <sup>_λ_</sup> <sup>,</sup> <sup>[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> <sup>is</sup> <sup>the</sup> <sup>matrix</sup> <sup>describing</sup> the permittivity distribution on _x_ - _y_ plane; its construction will be presented in the next subsection. Lastly, K _x_ and K _y_ are both diagonal matrices of size _nxny × nxny_ [3], and the [ _j −_ 1 + ( _i −_ 1) _ny_ ]-th diagonal elements in K _x_ and K _y_ are expressed, respectively, as follows: and _._ K _x_ ( _j −_ 1 + ( _i −_ 1) _ny_ ) = _L_ <sup><u>2</u></sup> _x_ K _x_ ( _j −_ 1 + ( _i −_ 1) _ny_ ) = _L_ <sup><u>2</u></sup> _x_ K _y_ ( _j −_ 1 + ( _i −_ 1) _ny_ ) = _L_ <sup><u>2</u></sup> _y_ _π_ _π_ _i −_ <sup>_<u>nx</u>_</sup> <sup><u>+ 1</u></sup> 2 _j −_ <sup>_<u>ny</u>_</sup> <sup><u>+ 1</u></sup> 2 2 2 (4) K _y_ ( _j −_ 1 + ( _i −_ 1) _ny_ ) = _L_ <sup><u>2</u></sup> _y_ In the expressions of P and Q, _k_ 0, K _x_, and K _y_ are all independent from the structural design parameters; they are constant values when one take the derivatives with respect to design parameters. The permittivity matrix [[ _ϵ_ ]], however, will change with respect to the design parameters. Therefore, the derivatives of the coefficient matrices have the forms, and d P = d Q = _−_ K _x_ d[[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> K _x_ K _y_ d[[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> K _y_ - K _x_ d[[ _ϵ_ ]] _−_ 1 K _y_ _−_ K _y_ d[[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> K _x_ 0 _−k_ 0 <sup>2</sup> _k_ 0 <sup>2d[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> 0 _−k_ 0 <sup>2d[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> _k_ 0 <sup>2d[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> 0 0 <sup>2d[[</sup> <sup>_ϵ_</sup> <sup>]]</sup> 0 - (5) where the symbol d indicates the derivative with respect to a particular design parameter _p_, and d[[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> can be expressed as (6) d[[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> = _−_ [[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> d[[ _ϵ_ ]][[ _ϵ_ ]] <sup>_−_</sup> <sup>1</sup> _._ 1.2 Permittivity Matrix of Grid-discretized Shapes To construct the permittivity matrix [[ _ϵ_ ]] in (3), we consider the cross-sectional region of the photonic structure on _x_ - _y_ plane. Suppose the region has a size 2 _Lx × Ly_ . The continuous Fourier transform of the permittivity distribution in this region is written as d _x_ d _y_ (7) _ϵ_ ( _m, n_ ) = <sup><u>1</u></sup> _S_ �� _S_ _Lx_ <sup><u>2</u></sup> <sup>_<u>π</u>_</sup> <sup>_mx_</sup> <sup>)</sup> _e_ _ϵ_ ( _x, y_ ) _e_ <sup>(</sup> <sup>_−i_</sup> _Lx_ <sup><u>2</u></sup> <sup>_<u>π</u>_</sup> _−i_ _Ly_ <sup><u>2</u></sup> <sup>_<u>π</u>_</sup> _Ly_ <sup><u>2</u></sup> <sup>_<u>π</u>_</sup> <sup>_ny_</sup> where _S_ is the cross-sectional region and _S_ is its area. To compute (7) numerically, we first divide the cross-sectional region into _Px_ _× Py_ grids. Assume that the permittivity in each grid ( _l, p_ ) is uniformly distributed, denoted as _ϵl,p_ . Then, the (discrete) Fourier transform of all grids is a summation of the Fourier transform of each grid, namely, _−i_ <sup>_<u>mπ</u>_</sup> _Lx_ sinc _,_ (8) _Py_ _p_ =1 _−i_ <sup>_<u>nπ</u>_</sup> _Ly_ <u>�</u> _Ly_ _Lx_ _Lx_ - _<u>mπ</u>_ ( _ul −_ _ul−_ 1) _Lx_ - <u>1</u> exp _ϵ_ ( _m, n_ ) = _ϵl,p_ ( _ul_ + _ul−_ 1) _Ly_ - _<u>nπ</u>_ sinc ( _vp −_ _vp−_ 1) ( _ul −_ _ul−_ 1) _Px_ _l_ =1 exp _p_ =1 _×_ _Ly_ - <u>1</u> ( _vp −_ _vp−_ 1) ( _vp_ + _vp−_ 1) where sinc( _x_ ) = <sup><u>sin</u></sup> _x_ <sup>_<u>x</u>_</sup> <sup>,</sup> <sup>_ul_</sup> <sup>is</sup> <sup>the</sup> <sup>_x_</sup> <sup>-coordinate</sup> <sup>of</sup> <sup>the</sup> <sup>_l_</sup> <sup>-th</sup> <sup>vertical</sup> <sup>grid</sup> <sup>line,</sup> <sup>and</sup> _vp_ is the _y_ -coordinate of the _p_ -th horizontal grid line. _m_ and _n_ are indices of the discrete Fourier coefficients: _m_ = _−_ ( _nx −_ 1) _, · · ·_ _,_ 0 _,_ 1 _, · · ·_ _,_ ( _nx −_ 1) and _n_ = _−_ ( _ny −_ 1) _, · · ·_ _,_ 0 _,_ 1 _, · · ·_ _,_ ( _ny −_ 1). After computing _ϵ_ ( _m, n_ ) for all _m_ and _n_, we can construct the permittivity matrix [[ _ϵ_ ]], which has the size _nxny × nxny_ . The matrix [[ _ϵ_ ]] has the so-called block-Toeplitz structure, containing matrix blocks that are repeated down the diagonals of the matrix. Its element values are assembled from the Fourier coefficients _ϵ_ ( _m, n_ ) in the following way: [[ _ϵ_ ]] ( _iny_ + _j, kny_ + _l_ ) = _ϵ_ ( _i −_ _k, j −_ _l_ ) _,_ (9) where the indices _i_ and _k_ are in the range 0 _, . . ., nx −_ 1; _j_ and _l_ are in the range 0 _, . . ., ny −_ 1. Similarly, the derivative of [[ _ϵ_ ]] with respect to a design parameter can be computed using d[[ _ϵ_ ]] ( _iny_ + _j, kny_ + _l_ ) = d _ϵ_ ( _i −_ _k, j −_ _l_ ) _,_ (10) where the scalar derivative d _ϵ_ ( _i −_ _k, j −_ _l_ ) is computed by differentiating (8) with respect to the design parameter. 1.3 Permittivity Matrix of Star-Convex Shapes For a star-convex shape discussed in Section 4.B (recall Fig. 8) of the main text, we do not need to discretize the shape into grid-based representation. Suppose the shape is described by the parameters _p_ 1 _, . . ., pN_ (recall Fig. 8-a in the main text). As derived in [2], in this case the Fourier transform (7) can be computed 3 directly: _<u>n</u>_ <u>ˆ</u> _<u>×⃗</u>_ _<u>αk ·⃗</u>_ _<u>αk−</u>_ <u>1</u> exp ( _j⃗w ·⃗pk_ ) ( _⃗w ·⃗αk_ )( _⃗w ·⃗αk−_ 1) _Ek_ ~~�~~ vector, _⃗w_ = ~~�~~ - ~~�~~ _−_ 2 _π_ _L_ <sup>_<u>m</u>_</sup> _x_ <sup>_, −_</sup> <sup>2</sup> <sup>_π_</sup> _ϵ_ ˜( _m, n_ ) = <sup><u>1</u></sup> _S_ _N_ _k_ =1 _,_ (11) where _n_ ˆ = (0 _,_ 0 _,_ 1) is the _z_ -axis ~~�~~ vector, _⃗w_ = ~~�~~ - ~~�~~ _Ly_, and _⃗αk_ = _−_ 2 _π_ _L_ <sup>_<u>m</u>_</sup> _x_ <sup>_, −_</sup> <sup>2</sup> <sup>_π_</sup> <sup>_<u>n</u>_</sup> - _pk_ +1 _−⃗pk_ . There exist two corner cases in which the denominator in (11) vanishes, and where _n_ ˆ = (0 _,_ 0 _,_ 1) is the _z_ -axis vector, _⃗w_ = _−_ 2 _π_ _L_ <sup>_<u>m</u>_</sup> _x_ _Ly_ _L_ <sup>_<u>m</u>_</sup> _x_ <sup>_, −_</sup> <sup>2</sup> <sup>_π_</sup> <sup>_<u>n</u>_</sup> _Ly_ There exist two corner cases in which the denominator in (11) vanishes, and thus they require special treatments: 1. When _m_ = _n_ = 0, the vector _⃗w_ in (11) vanishes. In this case, we resort to the continuous Fourier transform (7), which leads to _ϵ_ ˜(0 _,_ 0) = 1. 2. _⃗w_ may become perpendicular to _⃗αk_, and we have _w ·⃗αk_ = 0 and _⃗w ·⃗pk_ +1 = _⃗w ·⃗pk._ (12) In this case, we consider two terms _Ek_ and _Ek_ +1 in the summation (11). It can be shown that _Ek_ + _Ek_ +1 = <sup><u>0</u></sup> 0 <sup>,</sup> <sup>which</sup> <sup>is</sup> <sup>mathematically</sup> <sup>undefined.</sup> Instead, _Ek_ + _Ek_ +1 should be defined as its limit as the parameter _pk_ (i.e., the length of _⃗pk_ ) approaches to the situation where _⃗w ·⃗αk_ = 0 occurs. This limit can be computed using L’Hˆopital’s rule, by taking the derivatives of both the numerator and the denominator with respect to _pk_ . This process leads to the following form: <sup>_⃗_</sup> ( _⃗w ·_ _p_ ˆ _k_ )( _⃗w ·⃗ak_ +1) _⃗_ _⃗_ _Ek_ + _Ek_ +1 = exp ( _j⃗w ·⃗pk_ ) _−_ <sup><u>[ˆ</u></sup> <sup>_<u>pk ·</u>_</sup> <sup><u>(ˆ</u></sup> <sup>_<u>n ×</u>_</sup> <sup><u>(</u></sup> <sup>_⃗ak_</sup> <sup><u>+</u></sup> <sup>_⃗_</sup> <sup>_<u>ak−</u>_</sup> <sup><u>1))]</u></sup> <u>�</u> ( _⃗w ·_ _p_ ˆ _k_ )( _⃗w_ _<u>·⃗ak−</u>_ 1) <sup>_⃗_</sup> <sup>_⃗_</sup> _⃗_ _⃗_ <sup>_<u>·</u>_</sup> <sup><u>(ˆ</u></sup> <sup>_<u>n ×</u>_</sup> <sup><u>(</u></sup> <sup>_⃗ak_</sup> <sup><u>+</u></sup> <sup>_⃗_</sup> <sup>_<u>ak−</u>_</sup> <sup><u>1))]</u></sup> + <sup><u>[(ˆ</u></sup> <sup>_<u>n ×⃗</u>_</sup> <sup>_<u>ak</u>_</sup> <sup><u>+1)</u></sup> <sup>_<u>·</u>_</sup> <sup>_<u>p</u>_</sup> <sup><u>ˆ</u></sup> <sup>_<u>k</u>_</sup> <sup><u>]</u></sup> ( _⃗w ·_ _p_ ˆ _k_ )( _⃗w_ _<u>·⃗ak−</u>_ 1) ( _⃗w ·_ _p_ ˆ _k_ )( _⃗w ·⃗ak_ +1 <sup>_⃗_</sup> <sup>_⃗_</sup> _⃗_ _⃗_ <u>[(ˆ</u> _<u>n ×⃗</u>_ _<u>ak</u>_ <u>+1)</u> _<u>·⃗</u>_ _<u>ak</u>_ <u>]</u> <sup>_<u>×⃗</u>_</sup> <sup>_<u>ak</u>_</sup> <sup><u>)</u></sup> <sup>_<u>·⃗</u>_</sup> <sup>_<u>ak−</u>_</sup> <sup><u>1]</u></sup> _−_ ( _⃗w ·⃗ak−_ 1) ( _⃗w ·⃗ak−_ 1)( _⃗w ·⃗ak_ +1) _⃗w ·⃗ak_ +1 (13) _−_ <sup>_<u>j</u>_</sup> <sup><u>[(ˆ</u></sup> <sup>_<u>n ×⃗</u>_</sup> <sup>_<u>ak</u>_</sup> <sup><u>)</u></sup> <sup>_<u>·⃗</u>_</sup> <sup>_<u>ak−</u>_</sup> <sup><u>1]</u></sup> ( _⃗w ·⃗ak−_ 1) Here it is safe to assume that _⃗w_ is _not_ perpendicular to _⃗αk−_ 1 or _⃗αk_ +1. This is because, if it is indeed perpendicular to _⃗αk−_ 1, then _⃗pk−_ 1, _⃗pk_, and _⃗pk_ +1 are co-linear, and we can discard the parameter _pk_ while still representing the same star-convex shape. Similarly, if _⃗w_ is perpendicular to _⃗αk_ +1, we can safely discard _pk_ +1. Lastly, note that _ϵ_ ˜( _m, n_ ) in (11) is merely the Fourier transform of the starconvex shape, but not the entire material in an _Lx × Ly_ region. The permittivity distribution in the entire region can be viewed as a superposition of a background permittivity _ϵ_ 0 and a star-convex shape with the permittivity _ϵ_ 1 _−_ _ϵ_ 0. Thus the Fourier transform of the entire permittivity distribution is the Fourier transforms of both components: _ϵ_ ( _m, n_ ) = _LxLy_ <sup>_ϵ_</sup> <sup>˜(</sup> <sup>_m, n_</sup> <sup>) +</sup> <sup>_ϵ_</sup> <sup>0,</sup> <sup>if</sup> <sup>_m_</sup> <sup>=</sup> <sup>_n_</sup> <sup>= 0;</sup> (14) - _<u>ϵϵL</u>_ <u>11</u> _x−−Lϵϵy_ <u>00</u> <sup>_ϵ_</sup> <sup>˜(</sup> <sup>_m, n_</sup> <sup>),</sup> <sup>Otherwise.</sup> Once _ϵ_ ( _m, n_ ) for all _m_ and _n_ are obtained, we can assemble the permittivity matrix [[ _ϵ_ ]] and compute its derivative d[[ _ϵ_ ]] using the same formula (9) and (10) presented earlier. 4 ##### 2 An Example of Eigenvector Discontinuity Figure 2 in the main text provides an exemplar meta-atom structure in which repeated eigenvalues (and thus repeated propagation constants) exist. Here we use a simple mathematical example to show that when repeated eigenvalues emerge, the eigenvector derivatives become undefined. Consider the following 2 _×_ 2 matrix with a parameter _p_ : A ( _p_ ) = _p_ _p_ 1 <u>�1</u> _._ (15) <u>�</u> When _p̸_ = 0, its eigenvectors form a constant matrix. _̸_ _~~<u>√</u>~~_ _~~<u>√</u>~~_ <u>2</u> <u>2</u> 2 X = _̸_ _<u>−</u>_ _~~<u>√</u>~~_ <u>2</u> <u>2</u> _~~<u>√</u>~~_ <u>22</u> _~~<u>√</u>~~_ <u>22</u> _̸_ _~~<u>√</u>~~_ <u>2</u> <u>2</u> 2 <u>2</u> <u>2</u> _̸_ _._ (16) In fact, when _p̸_ = 0, this eigenvector matrix is unique up to a scale. When _p_ becomes zero, repeated eigenvalues emerge (both are 1). However, while X is still a valid eigenvector matrix of A (0), it is not unique anymore. In fact, any 2 _×_ 2 orthonormal matrix is a valid eigenvector matrix of A (0). For example, the standard eigen-decomposition solver (e.g., in Matlab) gives X (0) = 0 _._ (17) 0 1 �1 Therefore, in the presence of repeated eigenvalues, the non-uniqueness of eigenvectors causes the eigenvector derivatives undefined—in this case, an infinitesimal deviation from _p_ = 0, can cause the eigenvectors to change from (17) to (16), discontinuously. _Remark._ In this simple example, the discontinuity can be fixed by examining the limit of the X derivative as _p_ approaches 0, because in this case the derivative of X at _p̸_ = 0 is well-defined. However, the situations encountered in many photonic design tasks can be much more challenging. For example, in Fig. 2 of the main text, not only are the eigenvalues (i.e., effective indices) repeated, their derivatives with respect to the parameter are also repeated (e.g, see mode 0 and mode 1 in Fig. 2-c). In those cases, the derivative of X is not well-defined any more. If up to the _n_ -th order derivatives of the eigenvalues are repeated, one has to rely on the _n_ + 1-th order derivative of X to resolve the discontinuity. This is a rather expensive, if not impossible, computational process. 5 ##### 3 Derivation of Equations (5) Here we present the derivation of Eqs. (5) in the main text. Starting from Eqs. (3), we first rewrite them as R L = R R = = = I _−_ 1 I _−_ D <sup>2</sup> I _−_ A <sup>_−_</sup> <sup>1</sup> XB A <sup>_−_</sup> <sup>1</sup> XB A <sup>_−_</sup> <sup>1</sup> XB <sup>2</sup> 1 <sup>2</sup> - _−_ 1 ( D 1 D 2 _−_ D 3) _,_ �2 <sup>�</sup> <sup>_−_</sup> <sup>1</sup> A <sup>_−_</sup> <sup>1 �</sup> A <sup>_−_</sup> <sup>1</sup> XBA <sup>_−_</sup> <sup>1</sup> XA _−_ B (18) (19) A <sup>_−_</sup> <sup>1</sup> XBA <sup>_−_</sup> <sup>1</sup> XA _−_ A <sup>_−_</sup> <sup>1</sup> B �2 <sup>�</sup> <sup>_−_</sup> <sup>1</sup> and A _−_ BA <sup>_−_</sup> <sup>1</sup> B - _−_ A 1 X <sup>_−_</sup> <sup>1</sup> - XA - I _−_ ( A <sup>_−_</sup> <sup>1</sup> B ) <sup>2�</sup> T LR = T RL = = = = A _−_ XBA <sup>_−_</sup> <sup>1</sup> XB - A <sup>_−_</sup> <sup>1</sup> XB 1 I _−_ D <sup>2</sup> expressions,� I _−_ I _−_ A <sup>_−_</sup> <sup>1</sup> XB A <sup>_−_</sup> <sup>1</sup> XB A <sup>_−_</sup> <sup>1</sup> XB <sup>2</sup> 1 <sup>2</sup> - _−_ the1 ( D three2 _−_ D matrix1 D 3) _._ - _−_ A 1 X <sup>_−_</sup> <sup>1</sup> - XA �2 <sup>�</sup> <sup>_−_</sup> <sup>1</sup> A <sup>_−_</sup> <sup>1</sup> XA _−_ A <sup>_−_</sup> <sup>1</sup> XBA <sup>_−_</sup> <sup>1</sup> B �2 <sup>�</sup> <sup>_−_</sup> <sup>1</sup> In the above two expressions, the three matrix notations are defined as D 1 := A <sup>_−_</sup> <sup>1</sup> XB _,_ D 2 := A <sup>_−_</sup> <sup>1</sup> XA _,_ and D 3 := A <sup>_−_</sup> <sup>1</sup> B _._ (20) To reach the expressions in Eqs. (6) of the main text, we first rewrite the expressions of A and B in Eqs. (4) as the following forms: A = W <sup>_−_</sup> <sup>1</sup> ( W 0 + WV <sup>_−_</sup> <sup>1</sup> W 0) and (21) B = W <sup>_−_</sup> <sup>1</sup> ( W 0 _−_ WV <sup>_−_</sup> <sup>1</sup> W 0) _._ Notice that T, defined as T := ΩQ <sup>_−_</sup> <sup>1</sup> in Sec. 3.B of the main text, has the equality relation T = WV <sup>_−_</sup> <sup>1</sup> . This is because, as introduced in Sec. 2, V is related to W through V = QWΛ <sup>_−_</sup> <sup>1</sup>, and thus we have V = QWΛ <sup>_−_</sup> <sup>1</sup> = QΩ <sup>_−_</sup> <sup>1</sup> ΩWΛ <sup>_−_</sup> <sup>1</sup> = QΩ <sup>_−_</sup> <sup>1</sup> W = T <sup>_−_</sup> <sup>1</sup> W _,_ (22) where the third equality uses the fact that W is the eigenvector matrix of Ω . Substituting T = WV <sup>_−_</sup> <sup>1</sup> into (21) and then in (20) yields the expressions in Eqs. (6) of the main text. ##### 4 Derivative of Matrix Exponential Provided the matrix Ω and its derivative Ω <sup>_′_</sup> with respect to a design parameter, we compute the derivative of the matrix exponential _e_ <sup>_j_</sup> <sup>Ω</sup> <sup>_L/k_</sup> <sup>0</sup> through another the matrix exponential _e_ <sup>_j_</sup> <sup>G</sup> <sup>_L/k_</sup> <sup>0</sup>, where G is defined in Eq. (10) in the main text, and we repeat it here for convenience: _._ G = Ω Ω <sup>_′_</sup> 0 Ω 6 To compute this matrix exponential efficiently (and avoid eigenvalue decomposition), we tailor the scaling and squaring method [1] to leverage the particular matrix structure of G . We refer to [1] for the details of scaling and squaring method. To present how we tailor it for efficient computation, we outline its major steps here: 1. Compute an integer _s_ to scale the matrix _j_ G _L/k_ 0. Let G <sup>˜</sup> denote the scaled version: G <sup>˜</sup> = 21 <sup>_s_</sup> <sup>_j_</sup> <sup>G</sup> <sup>_L/k_</sup> <sup>0.</sup> 2. Compute two matrix polynomials, _D_ ( G <sup>˜</sup> ) and _N_ ( G <sup>˜</sup> ). The specific forms of these polynomials are determined by the scaling and squaring method. 3. Compute A = _D_ <sup>_−_</sup> <sup>1</sup> ( G <sup>˜</sup> ) _N_ ( G <sup>˜</sup> ). The matrix inverse here is computed through matrix factorization. 4. Repeatedly square matrix A for _s_ times, resulting in B = A <sup>2</sup> <sup>_s_</sup> . B is a close approximation of _e_ <sup>_j_</sup> <sup>G</sup> <sup>_L/k_</sup> <sup>0</sup> . We notice that the matrix G has a specific structure—its lower-left block matrix is always a zero matrix, and its two diagonal block matrices are the same. This structure is preserved in G <sup>˜</sup> as well as in its matrix polynomials. We leverage this structure for accelerating the computation in two aspects. First, in the computation of a matrix polynomial (step 2), we need to compute some matrix powers G <sup>˜</sup> <sup>_n_</sup> for some integers _n_ . Typically, G <sup>˜</sup> <sup>_n_</sup> is expressed recursively as G <sup>˜</sup> G <sup>˜</sup> <sup>_n−_</sup> <sup>1</sup>, and each recursion requires a multiplication of two _N ×_ _N_ matrices, where _N_ is the size of G <sup>˜</sup> . In our computation, both G <sup>˜</sup> and G <sup>˜</sup> <sup>_n−_</sup> <sup>1</sup> have the aforementioned block structure, and they can be represented as N 2 0 M 2 - M 2 _._ (23) and G <sup>˜</sup> <sup>_n−_</sup> <sup>1</sup> = G ˜ = N 1 0 M 1 - M 1 Their product is _,_ (24) <u>�</u> G ˜ ˜ G <sup>_n−_</sup> <sup>1</sup> = M 1 N 2 + N 1 M 2 0 M 1 M 2 - M 1 M 2 which involves three matrix multiplications of size <sup>_<u>N</u>_</sup> 2 which involves three matrix multiplications of size <sup>_<u>N</u>_</sup> 2 <sup>_×_</sup> <sup>_<u>N</u>_</sup> 2 <sup>.</sup> <sup>This</sup> <sup>is</sup> <sup>significantly</sup> faster than computing a multiplication of two _N_ _× N_ matrices. Secondly, the two matrix polynomials _D_ ( G <sup>˜</sup> ) and _N_ ( G <sup>˜</sup> ) also have the same block structure, represented as and _N_ ( G <sup>˜</sup> ) = V 2 0 U 2 - U 2 _._ (25) _D_ ( G <sup>˜</sup> ) = V 1 0 U 1 - U 1 Then, then the matrix product _D_ <sup>_−_</sup> <sup>1</sup> ( G <sup>˜</sup> ) _N_ ( G <sup>˜</sup> ) (in step 3) can be expressed as _,_ <u>�</u> <sup>_−_</sup> 1 <sup>1</sup> <sup>V</sup> <sup>1</sup> U <sup>_−_</sup> 1 <sup>1</sup> <sup>_−_</sup> 1 <sup>1</sup> <sup>U</sup> <sup>2</sup> �� _D_ <sup>_−_</sup> <sup>1</sup> ( G <sup>˜</sup> ) _N_ ( G <sup>˜</sup> ) = 1 <sup>U</sup> <sup>2</sup> U <sup>_−_</sup> 1 <sup>1</sup> 0 - U _−_ 1 0 U <sup>_−_</sup> 1 <sup>1</sup> <sup>_−_</sup> 1 <sup>1</sup> <sup>V</sup> <sup>2</sup> <sup>_−_</sup> U <sup>_−_</sup> 1 <sup>1</sup> U <sup>_−_</sup> 1 <sup>1</sup> <sup>_−_</sup> 1 <sup>1</sup> <sup>U</sup> <sup>2</sup> <sup>_−_</sup> 1 <sup>1</sup> <sup>U</sup> <sup>2</sup> <u>�</u> which involves only the matrix inverse (factorization) of the <sup>_<u>N</u>_</sup> 2 whichand a fewinvolvesmatrixonlymultiplicationsthe matrix inverseof size(factorization) <sup>_<u>N</u>_</sup> 2 <sup>_×_</sup> <sup>_<u>N</u>_</sup> 2 <sup>.</sup> <sup>This</sup> of <sup>is</sup> the <sup>also</sup> <sup>_<u>N</u>_</sup> 2 <sup>much</sup> <sup>_×_</sup> <sup>_<u>N</u>_</sup> 2 <sup>fastermatrixthan</sup> <sup>U</sup> <sup>1</sup> and a few matrix multiplications of size <sup>_<u>N</u>_</sup> 2 <sup>_×_</sup> <sup>_<u>N</u>_</sup> 2 <sup>.</sup> <sup>This</sup> <sup>is</sup> <sup>also</sup> <sup>much</sup> <sup>faster</sup> <sup>than</sup> computing _D_ <sup>_−_</sup> <sup>1</sup> ( G <sup>˜</sup> ) _N_ ( G <sup>˜</sup> ) directly. 7 ##### References [1] Higham, N. J. The scaling and squaring method for the matrix exponential revisited. <u>SIAM</u> <u>Journal</u> <u>on</u> <u>Matrix</u> <u>Analysis</u> <u>and</u> <u>Applications</u> <u>26,</u> 4 (2005), 1179–1193. [2] Lee, S.-W., and Mittra, R. Fourier transform of a polygonal shape function and its application in electromagnetics. <u>IEEE</u> <u>Transactions</u> <u>on</u> <u>Antennas</u> <u>and</u> <u>Propagation</u> <u>31,</u> 1 (1983), 99–103. [3] Rumpf, R. C. Design and optimization of nano-optical elements by coupling <u>fabrication</u> <u>to</u> <u>optical</u> <u>behavior.</u> PhD thesis, University of Central Florida, 2006. 8

섹션 본문

섹션 본문이 없습니다.

참고문헌 32건

  1. Fourier-modal methods applied to waveguide computational problems Optics Letters · Optica Publishing Group · 2000 10.1364/ol.25.001092
  2. Angle-Multiplexed Metasurfaces: Encoding Independent Wavefronts in a Single Metasurface under Different Illumination Angles Physical Review X · American Physical Society · 2017 10.1103/physrevx.7.041056
  3. Rigorous coupled-wave analysis of planar-grating diffraction Journal of the Optical Society of America · Optica Publishing Group · 1981 10.1364/josa.71.000811
  4. Dielectric metasurfaces for complete control of phase and polarization with subwavelength spatial resolution and high transmission Nature Nanotechnology · Nature Portfolio · 2015 10.1038/nnano.2015.186
  5. Design and Analysis of High-Index-Contrast Gratings Using Coupled Mode Theory IEEE photonics journal · Institute of Electrical and Electronics Engineers · 2010 10.1109/jphot.2010.2079322
  6. Multichannel vectorial holographic display and encryption Light Science & Applications · Springer Nature · 2018 101038s4137701800910
  7. Full-Stokes Imaging Polarimetry Using Dielectric Metasurfaces ACS Photonics · American Chemical Society · 2018 10.1021/acsphotonics.8b00362
  8. Absorption Enhancement in Ultrathin Crystalline Silicon Solar Cells with Antireflection and Light-Trapping Nanocone Gratings Nano Letters · American Chemical Society · 2012 10.1021/nl204550q
  9. Ultrabroadband Photonic Structures To Achieve High-Performance Daytime Radiative Cooling Nano Letters · American Chemical Society · 2013 10.1021/nl4004283
  10. Structural Colors from Fano Resonances ACS Photonics · American Chemical Society · 2014 10.1021/ph500400w
  11. Spectral analysis based on compressive sensing in nanophotonic structures Optics Express · Optica Publishing Group · 2014 10.1364/oe.22.025608
  12. Adjoint shape optimization applied to electromagnetic design Optics Express · Optica Publishing Group · 2013 10.1364/oe.21.021693
  13. Design sensitivities for scattering-matrix calculation with tetrahedral edge elements IEEE Transactions on Magnetics · IEEE Magnetics Society · 2000 10.1109/20.877620
  14. Method for sensitivity analysis of photonic crystal devices Optics Letters · Optica Publishing Group · 2004 10.1364/ol.29.002288
  15. Inverse Geometric Design of Fabrication-Robust Nanophotonic Waveguides Conference on Lasers and Electro-Optics · 2020 10.1364/cleo_si.2020.sf1j.3
  16. IMPROVED FORMULATION OF SCATTERING MATRICES FOR SEMI-ANALYTICAL METHODS THAT IS CONSISTENT WITH CONVENTION Progress In Electromagnetics Research B · The Electromagnetics Academy · 2011 10.2528/pierb11083107
  17. Derivatives of Complex Eigenvectors Using Nelson's Method AIAA Journal · American Institute of Aeronautics and Astronautics · 2000 10.2514/2.907
  18. Calculating Derivatives of Repeated and Nonrepeated Eigenvalues Without Explicit Use of Eigenvectors AIAA Journal · American Institute of Aeronautics and Astronautics · 2000 10.2514/2.1119
  19. Design sensitivity and Hessian matrix of generalized eigenproblems Mechanical Systems and Signal Processing · Elsevier BV · 2013 10.1016/j.ymssp.2013.09.007
  20. An Operator Calculus Having Applications in Quantum Electrodynamics Physical Review · American Institute of Physics · 1951 10.1103/physrev.84.108
  21. A Note on Saturation in Microwave Spectroscopy Physical Review · American Institute of Physics · 1948 10.1103/physrev.73.1020
  22. Perturbation Variation Methods for a Quantum Boltzmann Equation Journal of Mathematical Physics · American Institute of Physics · 1964 10.1063/1.1931191
  23. Derivatives of the Matrix Exponential and Their Computation Advances in Applied Mathematics · Elsevier BV · 1995 10.1006/aama.1995.1017
  24. The Scaling and Squaring Method for the Matrix Exponential Revisited SIAM Journal on Matrix Analysis and Applications · Society for Industrial and Applied Mathematics · 2005 10.1137/04061101x
  25. A Broadband, Background-Free Quarter-Wave Plate Based on Plasmonic Metasurfaces Nano Letters · American Chemical Society · 2012 10.1021/nl303445u
  26. Dielectric Metasurfaces for Complete and Independent Control of Optical Amplitude and Phase arXiv (Cornell University) · Cornell University · 2019 10.1038/s41377-019-0201-7
  27. Computational inverse design for cascaded systems of metasurface optics Optics Express · Optica Publishing Group · 2019 10.1364/oe.27.030308
  28. Large-Angle, Multifunctional Metagratings Based on Freeform Multimode Geometries Nano Letters · American Chemical Society · 2017 10.1021/acs.nanolett.7b01082
  29. Topology optimization of freeform large-area metasurfaces Optics Express · Optica Publishing Group · 2019 10.1364/oe.27.015765
  30. High-Efficiency Broadband Meta-Hologram with Polarization-Controlled Dual Images Nano Letters · American Chemical Society · 2013 10.1021/nl403811d
  31. A Characterization of Starshaped Sets Canadian Journal of Mathematics · Cambridge University Press · 1977 10.4153/cjm-1977-070-2
  32. Fourier transform of a polygonal shape function and its application in electromagnetics IRE Transactions on Antennas and Propagation · Institute of Electrical and Electronics Engineers · 1983 10.1109/tap.1983.1142981