Observation of full-parameter Jones matrix in bilayer metasurface

Metasurfaces, artificial 2D structures, have been widely used for the design of various functionalities in optics. Jones matrix, a 2×2 matrix with eight parameters, provides the most complete characterization of the metasurface structures in linear optics, and the number of free parameters (i.e., degrees of freedom, DOFs) in the Jones matrix determines the limit to what functionalities we can realize. Great efforts have been made to continuously expand the number of DOFs, and a maximal number of six has been achieved recently. However, the realization of the ultimate goal with eight DOFs (full free parameters) has been proven as a great challenge so far. Here, we show that by cascading two layer metasurfaces and utilizing the gradient descent optimization algorithm, a spatially varying Jones matrix with eight DOFs is constructed and verified numerically and experimentally in optical frequencies. Such ultimate control unlocks opportunities to design optical functionalities that are unattainable with previously known methodologies and may find wide potential applications in optical fields.

The design of optical structures with arbitrary functionalities has always been an ultimate dream for people in optics. However, the number of the degrees of freedom (DOFs) of light control by the implemented optical structure itself determines the limit to what functionalities that can be realized. In linear optics, the optical structures can be completely characterized by a spatially varying 2 × 2 Jones matrix 1 , which contains of eight parameters, therefore indicating a maximal number of eight DOFs (otherwise known as the free parameters that can be arbitrarily varied) for all linear structures in nature. Obviously, the more free parameters in the Jones matrix can be varied, the diverse functionalities we can achieve. The highest eight DOFs (full free parameters) represent the most general control in optics and are the foundation to realize the most complex optical functionalities. So, the question arises that how to expand the number of DOFs in Jones matrix, even to the ultimate eight DOFs?
Metasurfaces, which consist of a monolayer of planar structures, provide a suitable platform for spatially varying light control in subwavelength scales [2][3][4] . The metasurfaces have been extensively explored in the past ten years for diverse functionalities, such as anomalous refraction 4-8 , hologram [9][10][11][12][13][14][15][16] , metalens [17][18][19][20][21][22] , vortex beam [23][24][25][26] , etc. In fact, almost all these functionalities can be categorized into the different DOFs in the Jones matrix, which manifests the process of continuous endeavors to expand the number of DOFs. For example, the x-polarized anomalous refraction with y-polarized incidence 4 can be attributed to the phase control of the J 12 component of the Jones matrix, i.e., one DOF. The polarization-control dual holographic images 16 is enabled by the independent phase control of the two diagonal entries of the Jones matrix, i.e., two DOFs. An application of four DOFs (the amplitude and phase terms of both J 12 and J 22 components in the Jones matrix) is to generate arbitrary amplitude, phase, and polarization distributions 23 . Due to the mirror symmetry, the Jones matrix of planar structure is symmetric and thus has an upper limit number of six DOFs 27 , which is constructed with metasurface recently 28,29 . To break the mirror symmetry, multi-layer design is necessary. Recently, Yuan et al. 30 proposed a five-layer metallic structure to independently control the phases of the four components of the Jones matrix (circular polarization base) in microwave reign (i.e., four DOFs). Although great achievements have been made in expanding the number of DOFs, the goal with ultimate eight DOFs in Jones matrix has not yet been realized. The construction of such Jones matrix, especially operated in optical frequencies, is of great importance and meaningful to the field of optical design.
Here, we proposed and experimentally demonstrated an arbitrary spatially varying Jones matrix with eight DOFs in optical frequencies by using a bilayer metasurface to break the mirror symmetry of planar structures (Fig. 1a). The Jones matrix distributions of the two single layers in the bilayer structure are calculated based on gradient descent optimization algorithm, and the optimized results can agree well with any designed target distributions. The Jones matrix with eight DOFs provides unparalleled control of light. One example is that we can impose arbitrary and independent amplitude and phase control on any set of two polarizations (Fig. 1b). Most importantly, there are no restrictions on the input and output polarizations. In comparison, previously reported Jones matrix with three DOFs can impart independent phase 31 (or amplitude 32 ) control on orthogonal polarizations only, and the output polarizations must be the same as the input ones with flipped handedness (or mutually conjugate), i.e., the output two polarizations are orthogonal with each other, too. Following work with six DOFs 33 extends the above light control and can impart both independent amplitude and phase control, but exhibits the same restrictions on the input and output polarizations as that with three DOFs. The comparison in Fig. 1c highlights the unique and versatile control with eight DOFs. In addition, the bilayer design introduces another rotation DOF, which is utilized to realize polarization-rotation multiplexed holography reaching up to 16 independent functionalities. Figure 1a illustrates the schematic view of our designed structure with eight DOFs in the Jones matrix, which consists of two layers of metasurfaces with a separation z between them. Such bilayer metasurface design approaches have been previously proposed for various optical functionalities [34][35][36][37][38][39][40][41][42][43][44] . Here, the Jones matrix of each of the two layers J 1 ðx 1 ,y 1 Þ and J 2 ðx 2 ,y 2 Þ is symmetric due to mirror symmetry and assumed to have upper limit of six DOFs to provide enough design freedom. When light impinges from the bottom of the bilayer metasurface, it firstly passes through the first layer, then propagates over a distance z in gap (homogenous environment) and finally passes through the second layer. The incident and output Jones vectors through the bilayer metasurface can be characterized by a spatially varying 2 × 2 Jones matrix J, which represents the optical properties of the whole optical system. In the following, we refer to it as equivalent Jones matrix (EQJM) in order to distinguish from that of the two single layers. The mnth (m, n = 1, 2) component of the EQJM can be written as (see Supplementary section 1)

Results
where J 1 qn and J 2 mq are the qnth and mqth component of the Jones matrix of the first and second layer, respectively, f ðx 2 À x 1 ,y 2 À y 1 ,zÞ = 1 2π expðikrÞ r z r ð 1 r À i 2π λ Þ is the Rayleigh-Sommerfeld impulse response, r = ffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi ffi ðx 1 Àx 2 Þ 2 + ðy 1 Ày 2 Þ 2 + z 2 p , i is the imaginary unit, λ is the wavelength and z is the distance between the two layers. Note that the Jones matrix of a single layer is symmetric and therefore J 1 12 ðx 1 ,y 1 Þ = J 1 21 ðx 1 ,y 1 Þ and J 2 12 ðx 2 ,y 2 Þ = J 2 21 ðx 2 ,y 2 Þ. We aim to find the Jones matrix values of the two single layers   and phase control of arbitrary set of two polarizations. The incident two arbitrary polarizations |α 1 iand |α 2 i can be transformed into arbitrary output polarizations |β 1 iand |β 2 i with independent complex-amplitude A 1 e iδ 1 and A 2 e iδ 2 , respectively. There are no constraints imposed on the input and output polarizations. c Comparison of the independent controlled parameters and polarization constraints between metasurfaces with different DOFs in Jones matrix.
allows the convenient use of gradient descent optimization algorithm to obtain the optimized solutions ( Fig. 2a and see Supplementary section 2 for details). Besides the conventional absolute-meansquared-error loss, we also add a boundary constraint loss L bnd to ensure that this algorithm converges to solutions that are inside the valid domains. The specific form of the boundary loss is determined based on the metasurface unit design, which will be introduced in the following. A detailed discussion of this boundary loss is provided in supplementary section 3. To verify our approach, a target EQJM is designed with its amplitude and phase distributions chosen to present four nanoprintings (trinary intensity images of weather symbol) and four holographic images (letter strings "XX", "XY", "YX" and "YY") encoded in its four components (The details can be found in supplementary section 4). Figure 2b plots the loss value obtained from the algorithm as a function of the iteration number, which decays rapidly and reaches convergence after nearly 600 iterations. The optimized results of the EQJM, including both the amplitude and phase distributions, show good agreements with the targets (supplementary fig. 2). Only a slight deviation of the magnitude occurs near the boundaries, where the sharp truncation of the magnitude contains high angular spectrum frequencies that extend beyond our design.
The two single-layer metasurfaces with six DOFs of Jones matrix can be constructed by multi-element unit design 28,29 . Such multi-element unit design (diatomic, tetratomic, et al.) has shown unique advantages in increasing the DOFs of controlling light [45][46][47] . In this case, the Jones matrix ij ðx 1 ,y 1 Þ,J 2 ij ðx 2 ,y 2 Þ, ij = 11, 12 (21), 22). The defined loss includes two parts: the mean of the absolute squared differences of EQJM components between the prediction (J ij ) and target (J t ij ), and a boundary constraint lossL bnd . b Loss value as a function of the iteration number in the gradient descent optimization algorithm. c Unit cell of the single layer metasurface to construct Jones matrix with six DOFs. Each unit contains of four dielectric nanopillars, and the two sets of nanopillars AB and A'B' can individually and independently construct Jones matrix with six DOFs. Under oblique incidence or oblique scattering, detour phases of e ÀiΔφ and e iΔφ are imposed on the two sets of nanopillars AB and A'B'. To compensate the detour phases, the Jones matrixes of the two set of nanopillars are chosen as J s AB = e iΔφ J and J s A0B0 = e ÀiΔφ J to constructively generate the designed Jones matrix J for the unit cell. The period of the squared unit pixel is P = 800 nm. d Schematic of light propagation through the bilayer metasurface with the oblique incidence-oblique detection measurement strategy. For each layer, the scattering light (indicated by wavy line arrows) is deflected by applying a gradient phase distribution e ik x x on it and the residual zero order maintains its propagation direction as the incident one. With such measurement, the influence of the residual zero orders can be totally eliminated in the detection. RZO: residual zero order. is decomposed as the summation of the ones of the individual elements. We consider the element with rectangle dielectric nanopillars of silicon on glass, which have a higher refractive index than the surrounding environment air. The Jones matrix of the single layer metasurface with two-element (nanopillars A and B, Fig. 2c) unit is given by where φ 1 (φ 3 ) and φ 2 (φ 4 ) are the phase shifts imposed on the light linearly polarized along the fast and slow axes of nanopillar A (B), θ A,B are the rotational angles of the two nanopillars and Rðθ A,B Þ is the 2 × 2 rotation matrix. Clearly, not all symmetric Jones matrix can be decomposed as that in Eq. (2). A sufficient precondition of Eq. (2) is |J s 11 | + |J s 12 | ≤ 2 and |J s 12 | + |J s 22 | ≤ 2. The details of the derivations are provided in supplementary section 3. Therefore, a boundary constraint loss is added in the gradient descent algorithm to ensure that the input Jones matrix values always fall inside the above domains.
The phase shift values φ 1 (φ 3 ) and φ 2 (φ 4 ) are associated with the transverse dimensions (length and width in xy plane) of the nanopillar. Full wave finite-difference time-domain (FDTD) simulations are performed, and a library of the transmission magnitudes and phase shifts dependent on the transverse dimensions of the nanopillar with incident xand ypolarizations is built. With such databases, any φ 1 (φ 3 ) and φ 2 (φ 4 ) combinations ranging from 0 to 2π can be achieved by properly selecting the transverse dimensions of the nanopillars (see details in Supplementary section 4). As the optical response of nanopillar remains almost unchanged with the incident angle, such a library can be used for cases with oblique incidences (Supplementary Fig. 5).
The two nanopillars A and B are arranged vertically along y axis, and to create a square pixel, a simple way is to duplicate the set of nanopillars AB to A'B' and distribute them uniformly within the pixel (Fig. 2c). This treatment is appropriate under normal incidence and normal scattering. For oblique incidence or oblique scattering (along x direction), the introduced detour phases of the two sets of nanopillars can cause a major reduction of efficiency and deteriorate the optical performance (see discussion in Supplementary section 7).
When the incident light passes through the first layer metasurface, besides the transmitted scattering field, the unwanted residual zeroorder light also imposes on the second layer. The two beams then pass through the second layer metasurface and respectively generate both the scattered field and residual zero order. Here the field of interest only is the scattering from the second layer illuminated by the scattering from the first layer. The residual zero-order light may strongly affect the measurement when its magnitude is comparable to that of the designed images.
We apply an oblique incidence-oblique detection measurement strategy, as shown in Fig. 2d. Here, the light is obliquely incident on the first layer, and the transmitted scattering is bended towards the normal direction by applying a gradient phase distribution e ik x x (k x = 0:3k, k is the wavevector of the light in air) on the first layer. The same gradient phase distribution is also added on the second layer, which diffracts the incident normal scattering to an oblique direction. The influence of the residual zero orders can be totally eliminated if only the obliquely diffracted scattering is collected for imaging. In each pixel design, the Jones matrix of the nanopillars AB and A'B' are set as e iΔφ J and e ÀiΔφ J to compensate the detour phases, where Δφ is the detour phase arisen from the oblique incidence or oblique scattering and J is the designed Jones matrix value for the pixel. The advantages of the above measurement strategy are demonstrated (see Supplementary Fig. 6) by performing the full-wave FDTD simulations of the realistic bilayer metasurface under different optical measurement setups (normal incidence-normal detection, oblique incidence-normal detection, and oblique incidence-oblique detection). The details of the simulation processes are provided in supplementary section 6. It is noted that the image quality of the holographic image maintains almost the same fidelity under all measurement setups. This is mainly because the holographic image is designed to be highly focused in farfield with its magnitude much larger than the diffracted background noise of the residual zero orders. In addition, a comparison between the consideration of the detour phase in the unit pixel design and without is shown in Supplementary Fig. 10. We also investigate the optical performance on the alignment of the two layers, which reveals that the images can be recognized with translational movement shift less than about 5 μm (Supplementary Fig. 11).
To set up the bilayer metasurface, we utilized two metasurfaces on separated substrates and cascaded them front-to-front to maintain a homogeneous environment (air) between them. The two metasurface samples are fabricated on 600 nm height crystal silicon layer that is transferred on glass substrate. The patterns are then defined by electron beam lithography (EBL) and reactive ion etching (RIE) process. The details of the fabrication procedure are outlined in the Methods. Figure 2e shows the SEM images of the metasurfaces, where the different designs of nanopillar sets of AB and A'B' within the pixel are observed. The oblique view of the metasurface shows the smooth sidewall profiles of these nanopillars. To measure the optical images along the oblique direction, we carry out a spatial filtering process in the Fourier plane. The Fourier plane of the objective lens (usually lies inside its barrel) is taken outside by adopting two lenses, which is then readily available for the filtering process. The details of the optical measurement are shown in Methods and Supplementary section 9.
The experimental results of the measured optical images with different combinations of the incident and analyzed polarizations are shown in Fig. 2f, which have good agreements with the designed targets. Although the measurement of the nanoprintings can be easily influenced by optical setups, the trinary intensity distributions are clearly seen for all four nanoprintings, demonstrating the accurate amplitude control of the EQJM. Due to the phase variations (arising from oblique incidence-oblique detection), the measured nanoprinting images exhibit fringe patterns, which are also verified in the simulations (Supplementary Fig. 6).
The efficiencies of the holographic images are measured to be 14.2% and 13.5% for x-polarized and y-polarized incidences, respectively (Supplementary section 9). Although the operation wavelength (808 nm) has been chosen to minimize the absorption loss of the silicon, the measured efficiency is somewhat lower than the common dielectric metasurfaces. The reason lies in two aspects. One is that the Jones matrix is designed with spatially varied amplitude distributions (the magnitudes in certain areas are nearly zero), which reduces the transmission through the metasurface. As a result, the efficiency of each single layer in our design is lower than that of the pure phase-only hologram. The other is that the efficiency of the bilayer metasurface is the product of the two single-layer ones, which reduces the efficiency value further. Therefore, the measured efficiencies after considering the two factors still meet the expected values of dielectric metasurfaces.
Next, we aim to demonstrate the proposed light control enabled by the eight DOFs that is mentioned in Fig. 1b. It is worth to mention that a recent theoretical work 48 has shown that the binary metasurface can implement arbitrary unitary polarization transformation, but lacks the control of the amplitude DOFs and is limited to orthogonal polarizations only. Let the two incident arbitrary polarizations be given by Jones vectors |α 1 i = ½ γ 1 γ 2 and |α 2 i = ½ γ 3 γ 4 . The metasurface transforms the two input polarizations to output polarizations |β 1 i = ½ χ 1 χ 2 and with independent complex-amplitude control of A 1 e iδ 1 and A 2 e iδ 2 , respectively (Fig. 1b). Note that we do not impose any constraints on the input and output polarizations. The Jones matrix of the Article https://doi.org/10.1038/s41467-022-35313-2 metasurface should simultaneously satisfy and The Jones matrix can be directly extracted as Obviously, we can always use the bilayer metasurface to construct a Jones matrix that satisfies Eq. (5) only if the input two polarizations are not exactly the same. It is worth mentioning that if only one of the two conditions ( Eqs. 3 and 4) is satisfied, i.e., converting arbitrary polarization into another polarization state with independent amplitude and phase control, the Jones matrix requires a minimal number of four DOFs 49 . For demonstration, we choose nonorthogonal linear polarization ðγ 1 = 2 Þ, respectively. The amplitude and phase control are demonstrated by designing two nanoprintings and two holographic images (first column in Fig. 3). When the incident and analyzed polarizations are set as the designed ones, we can observe clear nanoprintings and holographic images in the measurement (second column in Fig. 3), agreeing well with the targets. The output polarizations are verified from the observed almost dark images when switching the analyzed polarizations to the orthogonal ones (third column in Fig. 3).
The bilayer metasurface design introduces another DOF, the rotation angle between the two layers (Fig. 4a). It can be imagined that when the two layer metasurfaces rotate with respect to each other, the whole structure will exhibit different optical responses, which are that we want to control. The proposed bilayer metasurface is a good platform for multifunctional control as it provides enough DOFs (12 N 2 , N is the pixel number along one direction) for design. We consider four cases with rotational angles ϕ = 0°, 90°, 180°, and 270°, and in each case, four independent functionalities are designed for each of the four different combinations of the incident and analyzed polarizations, i.e., a total of 16 polarization-rotation multiplexed functionalities. Here, we only consider the holographic functionality, as it is robust to the measurement conditions (see Supplementary Fig. 6). The loss is defined as the summation of the 16 squared differences between the magnitudes the predicted holographic images and the targets, plus the boundary loss (see details in Supplementary section 10). Then the gradient descent optimization algorithm is used to retrieve the Jones matrix values of the two single layers. To avoid the overlapping of the holographic image and the possible residual zero order, we applied the oblique incidence-normal detection measurement strategy. Figure 4b display our measured 16 holographic images under different combinations of the four rotation angles, two incident polarizations and two analyzed polarizations. All the measured images have high fidelity and have good agreement with the calculated optimized results (Supplementary Fig. 14). More importantly, the measured results almost have no cross-talk between any two holographic images, demonstrating the full independent multifunctionalities.
Although the whole device in the demonstration is not that compact (the gap distance between the two layers is set as 150 μm for the measurement convenience), our design strategy is general, and can be extended to gap distance towards several wavelengths (e.g., 5 μm), as shown in Supplementary section 11. For certain applications, it may be more convenient to integrate the two layer metasurfaces into monolithic system [38][39][40][41] , but at the cost of disabling the rotation DOF. In addition, the operation bandwidth of current implementations is over 60 nm (Supplementary Fig. 16). It is noteworthy that although the demonstration was designed at 808 nm, which is aimed to avoid the large optical loss of silicon, our approach applies to short wavelengths in the visible range and can maintain performance with other lossless materials, such as TiO 2 .

Discussion
In conclusion, we have cascaded two single layer metasurfaces with six DOFs in the Jones matrix to construct a spatially varying Jones matrix with full parameters of eight DOFs, the maximal number allowed in nature. This represents a significant advance in the state-of-the-art for light control. Enabled by the eight DOFs of light control, we have demonstrated functionalities with independent amplitude and phase control of arbitrary set of two polarizations, without any constraints on the incident and output polarizations. In addition, we have investigated the DOF of rotation in the bilayer metasurface and demonstrated polarization-rotation multiplexed holography reaching up to 16 independent functionalities. We believe that our proposed design strategy of eight DOFs in Jones matrix offers a generalize method towards arbitrary control of light and may find applications that are not attainable with conventional methods.

Sample fabrication
A commercial SOI wafer with a 1200 nm-thickness of device layer is firstly transferred on glass substrate by adhesive wafer bonding and deep reactive ion etching (DRIE). The thickness of the device layer is further reduced to 600 nm using inductively coupled plasma (ICP). To fabricate the metasurface pattern, a 300 nm-thickness hydrogen silsesquioxane (HSQ) layer is first spin-coated at 4000 rpm on the substrate and baked on a hot plate for 5 min at 90°C. Then a 30 nm thickness aluminum layer (thermal evaporation) is deposited to serve as the charge dissipation layer. Next, the pattern is exposed using electron beam lithography (EBL). After exposure, the aluminum layer is removed by 5% phosphoric acid, and the resist is developed with  tetramethy-lammonium hydroxide. Finally, the sample is etched using ICP. An important note is that the two metasurfaces are cascaded front-to-front, and therefore the EBL pattern of the second metasurface should be flipped horizontally.

Optical setup and measurement
A schematic of the optical setup for the experimental measurement is shown in supplementary fig. 13. A tunable laser source is used to generate the light beam with a wavelength of 808 nm. The laser source is collimated with uniform intensity in the center and obliquely incident on the bilayer metasurface. The different polarization is generated by a polarizer and a quarter waveplates (QWP) in front of two metasurface samples, which are separately mounted on 3D translational stages. The light scattered by the bilayer metasurface is collected by a 20×/0.50 objective and isolated with another pair of QWP and polarizer. To measure the optical images along oblique direction, we carry out a spatial filtering process in the Fourier plane. The Fourier plane of the objective lens (usually lies inside its barrel) is taken outside by adopting Lenses 1 and 2, which is then readily available for the filtering process. A continuously variable iris is placed at the Fourier plane to serve as the filter. The position and the diameter of the iris are determined according to designed parameters (See details in Supplementary section 9). The final image is focused by Lens 3 and formed on the CMOS camera.

Data availability
The data underlying Fig. 2b of the Main Text are provided as Source data files. Any additional data that support this study are available from the corresponding author upon request. Source data are provided with this paper.  Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons license, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons license and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this license, visit http://creativecommons.org/ licenses/by/4.0/.