Polarization state generation and measurement with a single metasurface

The constituent elements of metasurfaces may be designed with explicit polarization dependence, making metasurfaces a fascinating platform for new polarization optics. In this work we show that a metasurface grating can be designed to produce arbitrarily specified polarization states on a set of defined diffraction orders given that the polarization of the incident beam is known. We also demonstrate that, when used in a reverse configuration, the same grating may be used as a parallel snapshot polarimeter, requiring a minimum of bulk polarization optics. We demonstrate its use in measuring partially polarized light, and show that it performs favorably in comparison to a commercial polarimeter. This work is of consequence in any application requiring lightweight, compact, and low-cost polarization optics, polarimetry, or polarization imaging. © 2018 Optical Society of America under the terms of the OSA Open Access Publishing Agreement OCIS codes: (260.5430) Polarization; (230.5440) Polarization-selective devices; (160.3918) Metamaterials; (050.2555) Form birefringence; (050.2770) Gratings. References and links 1. M. Born and E. Wolf, Principles of Optics (Cambridge University, 1999). 2. J. N. Damask, Polarization Optics in Telecommunications (Springer, 2005). 3. A. Yariv and P. Yeh, Photonics: Optical Electronics in Modern Communications (Oxford University, 2006). 4. J. S. Tyo, D. L. Goldstein, D. B. Chenault, and J. A. Shaw, “Review of passive imaging polarimetry for remote sensing applications.” Appl. Opt. 45, 5453–5469 (2006). 5. F. Snik, J. Craven-Jones, M. Escuti, S. Fineschi, D. Harrington, A. De Martino, D. Mawet, J. Riedi, and J. S. Tyo, “An overview of polarimetric sensing techniques and technology with applications to different research fields,” Proc. SPIE 9099, 90990B (2014). 6. P. Y. Deschamps, J. C. Buriez, F. M. Bréon, M. Leroy, A. Podaire, A. Bricaud, and G. Sèze, “The POLDER mission: instrument characteristics and scientific objectives,” IEEE Trans. Geosci. Remote Sens. 32, 598–615 (1994). 7. T. Novikova, A. Pierangelo, and A. De Martino, “Polarimetric imaging for cancer diagnosis and staging,” Opt. Photonics News 23, 26–33 (2012). 8. A. Pierangelo, A. Nazac, A. Benali, P. Validire, H. Cohen, T. Novikova, B. H. Ibrahim, S. Manhas, C. Fallet, M.-R. Antonelli, and A.-D. Martino, “Polarimetric imaging of uterine cervix: a case study,” Opt. Express 21, 14120–14130 (2013). 9. J. Trujillo-Bueno, F. Moreno-Insertis, F. Sanchez, E. Landi Degl’Innocenti, J. O. Stenflo, G. Mathys, R. Antonucci, R. Blandford, E. Agol, A. Broderick, J. Heyl, L. Koopmans, H.-W. Lee, M. Elitzur, R. H. Hildebrand, and C. U. Keller, Astrophysical Spectropolarimetry (Cambridge University, 2002). 10. S. J. Wiktorowicz and G. P. Laughlin, “Toward the detection of exoplanet transits with polarimetry,” Astrophys. J. 795, 12 (2014). 11. J. O. Stenflo, Instrumentation for Solar Polarimetry (Springer Netherlands, Dordrecht, 1994), pp. 312–350. 12. R. M. A. Azzam, “Stokes-vector and Mueller-matrix polarimetry,” J. Opt. Soc. Am. A 33, 1396–1408 (2016). Vol. 26, No. 17 | 20 Aug 2018 | OPTICS EXPRESS 21455 #327946 https://doi.org/10.1364/OE.26.021455 Journal © 2018 Received 20 Apr 2018; revised 15 Jul 2018; accepted 16 Jul 2018; published 6 Aug 2018 13. R. M. A. Azzam, “Division-of-amplitude photopolarimeter (DOAP) for the simultaneous measurement of all four Stokes parameters of light,” J. Mod. Opt. 29, 685–689 (1982). 14. R. M. A. Azzam and K. A. Giardina, “Photopolarimeter based on planar grating diffraction,” J. Opt. Soc. Am. A 10, 1190–1196 (1993). 15. Y. Cui and R. M. A. Azzam, “Sixteen-beam grating-based division-of-amplitude photopolarimeter,” Opt. Lett. 21, 89–91 (1996). 16. W. Shurcliff, Polarized Light: Production and Use (Harvard University, 1962). 17. N. Yu, P. Genevet, M. A. Kats, F. Aieta, J. P. Tetienne, F. Capasso, and Z. Gaburro, “Light propagation with phase discontinuities: generalized laws of reflection and refraction,” Science 334, 333–337 (2011). 18. A. Arbabi, Y. Horie, M. Bagheri, and A. Faraon, “Dielectric metasurfaces for complete control of phase and polarization with subwavelength spatial resolution and high transmission,” Nat. Nanotechnol. 10, 937–943 (2015). 19. J. P. B. Mueller, N. A. Rubin, R. C. Devlin, B. Groever, and F. Capasso, “Metasurface polarization optics: independent phase control of arbitrary orthogonal states of polarization,” Phys. Rev. Lett. 118, 113901 (2017). 20. J. P. B. Mueller, K. Leosson, and F. Capasso, “Ultracompact metasurface in-line polarimeter,” Optica 3, 42–47 (2016). 21. M. Juhl, C. Mendoza, J. P. B. Mueller, F. Capasso, and K. Leosson, “Performance characteristics of 4-port in-plane and out-of-plane in-line metasurface polarimeters,” Opt. Express 25, 28697–28709 (2017). 22. A. Pors, M. G. Nielsen, and S. I. Bolzhevolnyi, “Plasmonic metagratings for simultaneous determination of Stokes parameters,” Optica 2, 716–723 (2015). 23. A. Pors and S. I. Bozhevolnyi, “Waveguide metacouplers for in-plane polarimetry,” Phys. Rev. Appl. 5, 1–9 (2016). 24. W. T. Chen, P. Török, M. R. Foreman, C. Y. Liao, W.-Y. Tsai, P. R. Wu, and D. P. Tsai, “Integrated plasmonic metasurfaces for spectropolarimetry,” Nanotechnology 27, 224002 (2016). 25. F. Ding, A. Pors, Y. Chen, V. A. Zenin, and S. I. Bozhevolnyi, “Beam-size-invariant spectropolarimeters using gap-plasmon metasurfaces,” ACS Photonics 4, 943–949 (2017). 26. S. Wei, Z. Yang, and M. Zhao, “Design of ultracompact polarimeters based on dielectric metasurfaces,” Opt. Lett. 42, 1580–1583 (2017). 27. F. Afshinmanesh, J. S. White, W. Cai, and M. L. Brongersma, “Measurement of the polarization state of light using an integrated plasmonic polarimeter,” Nanophotonics 1, 125–129 (2012). 28. F. Gori, “Measuring Stokes parameters by means of a polarization grating,” Opt. Lett. 24, 584–586 (1999). 29. G. Cincotti, “Polarization gratings: design and applications,” IEEE J. Quantum Electron. 39, 1645–1652 (2003). 30. F. Xu, J. E. Ford, and Y. Fainman, “Polarization-selective computer-generated holograms: design, fabrication, and applications,” Appl. Opt. 34, 256–266 (1995). 31. J. Tervo and J. Turunen, “Paraxial-domain diffractive elements with 100% efficiency based on polarization gratings,” Opt. Lett. 25, 785–786 (2000). 32. J. A. Davis, J. Adachi, C. R. Fernández-Pousa, and I. Moreno, “Polarization beam splitters using polarization diffraction gratings.” Opt. Lett. 26, 587–589 (2001). 33. C. Menzel, C. Rockstuhl, and F. Lederer, “Advanced Jones calculus for the classification of periodic metamaterials,” Phys. Rev. A 82, 053811 (2010). 34. L. A. Romero and F. M. Dickey, “Theory of optimal beam splitting by phase gratings. I. One-dimensional gratings,” J. Opt. Soc. Am. A 24, 2296–2312 (2007). 35. R. C. Devlin, M. Khorasaninejad, W.-T. Chen, J. Oh, and F. Capasso, “Broadband high-efficiency dielectric metasurfaces for the visible spectrum,” Proc. Natl. Acad. Sci. 113, 10473–10478 (2016). 36. D. S. Sabatke, M. R. Descour, E. L. Dereniak, W. C. Sweatt, S. A. Kemme, and G. S. Phipps, “Optimization of retardance for a complete Stokes polarimeter,” Opt. Lett. 25, 802–804 (2000). 37. J. S. Tyo, “Design of optimal polarimeters: maximization of signal-to-noise ratio and minimization of systematic error.” Appl. Opt. 41, 619–630 (2002). 38. R. M. A. Azzam and A. G. Lopez, “Accurate calibration of the four-detector photopolarimeter with imperfect polarizing optical elements,” J. Opt. Soc. Am. A 6, 1513–1521 (1989). 39. R. M. A. Azzam, “Arrangement of four photodetectors for measuring the state of polarization of light.” Opt. Lett. 10, 309–311 (1985). 40. A. Asensio Ramos and M. Collados, “Error propagation in polarimetric demodulation,” Appl. Opt. 47, 2541–2549 (2008). 41. E. Wolf, Introduction to the Theory of Coherence and Polarization of Light (Cambridge University, 2007). 42. A. Lizana, I. Estévez, F. A. Torres-Ruiz, A. Peinado, C. Ramirez, and J. Campos, “Arbitrary state of polarization with customized degree of polarization generator,” Opt. Lett. 40, 3790–3793 (2015). 43. H. G. Berry, G. Gabrielse, and A. E. Livingston, “Measurement of the Stokes parameters of light.” Appl. Opt. 16, 3200–3205 (1977). 44. L. A. Romero and F. M. Dickey, “The mathematical theory of laser beam-splitting gratings,” Prog. Opt. 54, 319–386 (2009). 45. J. S. Jensen and O. Sigmund, “Topology optimization for nano-photonics,” Laser Photonics Rev. 5, 308–321 (2011). 46. D. Sell, J. Yang, S. Doshay, R. Yang, and J. A. Fan, “Large-angle, multifunctional metagratings based on freeform multimode geometries,” Nano Lett. 17, 3752–3757 (2017). 47. J. Yang and J. A. Fan, “Topology-optimizedmetasurfaces: impact of initial geometric layout,” Opt. Lett. 42, 3161–3164 Vol. 26, No. 17 | 20 Aug 2018 | OPTICS EXPRESS 21456


Introduction
Polarization holds a role of paramount importance in countless areas of science and technology, in areas as diverse as atomic physics and fundamental light/matter interaction [1], fiber-optic telecommunications [2,3], and polarization-resolved imaging [4,5]. The latter has found application in remote sensing [4], aerosol characterization [6], non-invasive cancer pathology [7,8], and astrophysics [9][10][11]. Methods of producing and measuring polarized light, then, are of significant scientific and technological interest.
Polarization measurement is known as polarimetry [12]. Stokes polarimetry in particular refers to the determination of the full, four-component polarization Stokes vector ì S = S 0 S 1 S 2 S 3 T , which quantifies the shape and orientation of the polarization ellipse as well as the beam's intensity and degree of polarization. Polarization generation and analysis are conjugate -any configuration of polarization optics serving as a polarization state generator may be an analyzer, if used in reverse. If an unknown Stokes vector ì S inc is incident on an analyzer, a detector would observe, as a consequence of this symmetry, I meas ∝ ì S a · ì S inc , where ì S a is the characteristic polarization of the analyzer. Polarimetry amounts to several such projective measurements of the Stokes vector ( Fig. 1(f)). This is formalized in the matrix equation A is an N × 4 matrix known as the instrument matrix, ì S inc is an incident Stokes vector, and ì I is a list of N measured intensities. A links the Stokes vector to N measured intensities ì I on N analyzer channels. In the special case where N = 4 we can write ì S inc = A −1 ì I (in the over-determined case N > 4, one finds a least-squares solution for ì S inc ) [12]. Several broad categories of Stokes polarimeters exist, varying in how these N projective measurements are implemented. In the division-of-time approach, measurements are taken sequentially as a configuration of polarization optics changes. While this reduces the number of necessary components, time resolution is limited by the speed at which the polarization optics may be readjusted, representing a handicap (especially in the case of mechanical rotation). Active polarization optics such as liquid-crystal variable retarders ameliorate this somewhat, though here too, time resolution is limited to the ms range at great expense [5]. In the division-of-amplitude (also known as parallel, or snapshot) approach, on the other hand, the beam is divided among N parallel channels each of which contains a different analyzer. This may be accomplished by the use of birefringent (e.g., Wollaston) prisms and beamsplitters [13] or by employing a diffraction grating to split the beam into N orders containing unique polarization optics and a detector [14,15]. Division-of-amplitude is desirable because its time-resolution is detector-limited with no moving parts. This, however, requires distinct polarization optics on each channel, increasing complexity and bulk.
The basic units of these polarization optics (in free space, at least) are polarizers and phase retarders (waveplates). Retarders most commonly take the form of bulk bi/uniaxial crystals whose birefringent properties allow for polarization conversion; these led to the original discovery of light's polarization. These plates are, however, difficult to manufacture and process and challenging to integrate [2,16].
Meanwhile, metasurfaces [17] -that is, subwavelength-spaced arrays of nanophotonic phaseshifting elements -have attracted significant interest and hold promise for miniaturization of a variety of bulk optics. The elements comprising a metasurface may possess tailored structural birefringence making metasurfaces a fascinating platform for new polarization optics [18,19].
Here, we present a scheme for the design of a metasurface grating that, when light of a known polarization is incident, may produce arbitrarily specified states of polarization in parallel on its orders ( Fig. 1(a)) in the visible spectral region. We experimentally characterize two metasurface gratings designed with this scheme. The same grating, by the symmetry described above, may act as a parallel full-Stokes polarimeter requiring no bulk birefringent optics. We characterize such a polarimeter and compare its performance to a commercial rotating-waveplate instrument. In contrast to previous work by us [20,21] on terminating polarimeters and by others [22][23][24][25][26][27] on a variety of metasurface/metamaterial-based schemes, the present work allows for the generation and analysis of polarization on channels whose polarizations may themselves be arbitrarily specified, demonstrates full-Stokes vector determination (including partially polarized light), and provides a quantitative error analysis. As such, it is of consequence for any application requiring low-cost, easily integrated polarimetry or polarization imaging and is a testament to the flexibility of metasurfaces in the realm of polarization optics.
Retarder Diattenuator ...   1. a, Conceptual schematic: A metasurface diffraction grating can be designed to produce arbitrarily specified polarization states on its diffraction orders. The same device can also act as a parallel polarimeter. b, Such a metasurface is composed of pillar-like phase-shifting elements with two perpendicular mirror symmetry axes (e.g., rectangles) whose orthogonal dimensions w x and w y may be adjusted to allow for independent and tailorable phase delays φ x and φ y on xand y-polarized light. c, If Q such elements of varying dimensions are arranged into a periodic unit cell along thex direction, we form a 1D diffraction grating. At each point in the unit cell, constant phases are imparted on xand y-polarized light. We may then describe the phase profiles experienced by these polarizations in the form of Q-vectors ì Φ x and ì Φ y . d, The action of each diffraction order is equivalent to a bulk optic cascade of a diattenuator and a phase retarder, each oriented along x/y. e, The Poincaré sphere aids in understanding the behavior of the diffraction order for general input polarization. A standard Poincaré sphere (left) represents the set of all possible incident polarizations. After the beam passes through the diattenuator, the sphere is distorted along the S 1 axis according to the extinction ratio of the diattenuator (center). Finally, the phase retarder enacts a precession of the sphere along the S 1 axis by an angle equal to its retardance δ (m) (right). The red arrows depict the corresponding polarization states in (d). Note also that the power of the output beam is polarization-dependent (not shown). f, The functionality contained in a single metasurface (c) would require, most generally, a two birefringent plates on each order in addition to a grating. g, Conceptually, polarimetry amounts to several projective measurements of an incident Stokes vector, ì S inc , onto a number of analysis Stokes vectors { ì S n }. If the analysis vectors are known and linearly independent, ì S inc can be recovered.

Principle of operation
Space-variant polarization optics have long been a subject of investigation (as we discuss in Section 6.4) [28][29][30][31][32]. In the context of metasurfaces, a subwavelength element with two perpendicular symmetry axes [33] (e.g., a rectangle, but far from the only example) can function as a waveplate-like phase shifter, imparting independent phase shifts φ x and φ y on xand y-polarized light [18,19]. The values of φ x and φ y may be arbitrarily and independently adjusted between 0 and 2π by changing the element's perpendicular dimensions w x and w y ( Fig. 1(b)). If Q such birefringent phase shifters are arranged with subwavelength spacing in a 1D grating unit cell ( Fig. 1(c)), we can denote the phase shift experienced by x-polarized light at the q th position in the unit cell by φ (q) x . That is, we may approximate the phase shift acquired by the wavefront at each position in the unit cell as constant. This discrete phase function φ x (x) experienced by x-polarized light, as a function of the spatial coordinatex (not to be confused with x-polarized light), can be written as a vector, ì x } with ì Φ y holding an analogous meaning for y-polarized light. If the unit cell is tessellated we form a metasurface phase grating implementing independent and arbitrary periodic phase profiles for orthogonal x and y polarizations.
Being periodic, the grating's angular spectrum is discrete. Given the phase profiles φ x (x) and φ y (x) (which are contained in ì Φ x and ì Φ y ), we may compute the Fourier series of each phase grating. The projection onto grating order m is given by and where d is the length of the periodic unit cell and {c (m) x } and {c (m) y } are the Fourier coefficients of the gratings experienced by x and y polarizations, respectively.
Each coefficient is in general complex, so we may write c (m) y . Then, we can ascribe to each order a Jones matrix J (m) : The polarization properties of order m contained in J (m) may be seen as equivalent to a cascade of two bulk optical elements ( Fig. 1(d)): the first Jones matrix in the product is that of a diattenuator-that is, an imperfect polarizing element selectively attenuating light along the x and y directions, while the second Jones matrix is that of a phase retarder -a waveplate -with retardance δ (m) = δ (m) x − δ (m) y . Both have their eigenaxes mutually oriented along x and y ( Fig.  1(d)).
If, for instance, a beam linearly polarized at 45°with electric field amplitude E 0 is incident on the grating, the electric field on the m th grating order will be In the special case of 45°polarized light, then, the complex grating coefficients {c (m) x } and {c (m) y } directly yield the polarization state of order m without any further transformation. For a general input polarization, the output polarization state on each order can be understood with aid of the Poincaré sphere ( Fig. 1(e), see caption).

Optimization
Given a grating with known ì Φ x and ì Φ y and an incident beam of known polarization, the polarization state and power on each diffraction order m can be computed with simple Fourier optics. Conversely, can one deduce the ì Φ x and ì Φ y producing diffraction orders with specified states of polarization, for a given incident polarization? This would allow for the straightforward engineering of such gratings, embedding in a single monolithically integrated metasurface a functionality that would otherwise require, in the most general case, an ordinary diffraction grating with 2P birefringent crystalline waveplates, where P is the number of diffraction orders to be controlled ( Fig. 1(f)).
Suppose that for each diffraction order in a set { } we specify desired output polarization states. These polarizations directly dictate {c m x } and {c m y }, the required Fourier coefficients. The requisite gratings for x and y polarizations could then be found by simply inverting the Fourier transform. However, being the sum of many spatial harmonics of the grating, this solution would require both amplitude and phase variation. In the realm of metasurfaces, this is undesirable. One generally hopes to obtain a range of phase-shifter geometries with nearly uniform amplitude transmission that yield phase shifts ranging between 0 and 2π [18]. It is generally difficultat least, drawing from a limited set of possible geometries of simple design -to assemble a library of structures yielding arbitrarily shape-tunable phase shift and transmission. In the present case, we would require that this be achievable for both x and y polarizations, simultaneously and independent of one another. This is, without resorting to a very large range of simulated geometries, untenable. Moreover, an amplitude grating will inherently have lower transmission.
A phase-only grating addresses both issues. A phase-only grating, however, may only possess one or infinitely many diffraction orders, so the exact solution cannot in general be phase-only [34]. We must resort to optimization in order to concentrate as much diffracted light in the orders of interest while generating the desired polarization states.
More formally, we wish to design a grating that, when light linearly polarized at 45°is incident, produces desired polarization states on a set of grating orders { }. The target Jones vector on each order m ∈ { } is given as Light will generally be diffracted into all orders, not just those in { }. In order to direct as much of the incident power as possible into these desired orders, we seek to maximize under the constraints and The constraints provide for the desired polarization on each order, and the phase profile vectors ì Φ x and ì Φ y are the quantities to be optimized. If the grating has Q constituent elements, the optimization will involve 2Q parameters. Q and the inter-element separation dictate the grating period d which, along with the operating wavelength λ, specifies the angular separation of the grating orders. Once optimized ì Φ x and ì Φ y are obtained, the power in the desired orders and correspondence with the target polarization can be mathematically evaluated (cf. Eqns. (7), (8), and (9)).
We perform a simple gradient descent optimization of η( ì Φ x , ì Φ y ) under the above constraints with randomly generated initial conditions ( Fig. 2(a)). This is a purely mathematical exercise and is independent of any particular material implementation or wavelength. Once optimized { ì Φ x , ì Φ y } are found, the geometries of appropriate phase shifters can be located from a library of simulated structures, once the operating wavelength and desired material platform are specified.
While the essence of this work is wavelength-independent, in this work we use rectangular TiO 2 pillar structures for operation at λ = 532 nm, owing to the scientific and technological ubiquity of the visible range. The optimization scheme as presented above assumes that each phase shifter has a uniform amplitude transmission. In our library of simulated structures, the transmission does vary, an effect which compromises the results of the optimization. To address this, we add a second optimization step in which the result obtained from gradient descent (i.e., assuming uniform amplitude transmission) is used as an initial condition to a gradient-free scheme in which the Fourier transforms are computed using the transmission and phase shifts of actual structures drawn from our library; this two-step optimization, which explicitly acknowledges the properties of available phase-shifting structures, yielded improved results.

Polarization state generation
We designed two such gratings for operation at λ = 532 nm. For each element in the optimized ì Φ x and ì Φ y , a rectangular TiO 2 pillar, 600 nm in height whose dimensions best impart the required phases on x and y polarized light is selected from a library of simulated structures. The designed gratings are then fabricated on a glass substrate with a process extensively detailed elsewhere that relies on electron beam lithography [35].
A first grating is designed to produce +45°linear, right-circular, left-circular, and −45°linear polarizations on the m = −2, −1, +1, and +2 diffraction orders, respectively, all with equalized intensities, when 45°linear polarized light is incident. These represent a set of polarizations commonly encountered in optics experiments and are thus of general interest. We refer to this as the "four polarization" grating. A second grating is designed to produce four polarization states on these same diffraction orders corresponding to the vertices of a tetrahedron inscribed in the Poincaré sphere, with equalized intensities, for incident 45°linear polarization. This set of polarizations is of significance in polarimetry (discussed below) [36,37]. We refer to this as the "tetrahedron grating".
Both gratings contained Q = 20 individual elements, and thus each required the optimization of 2Q = 40 parameters. This Q was found, heuristically, to produce results that achieve high efficiency η and good correspondence with the desired polarization ellipses -mathematically and from FDTD simulation -while minimizing the number of optimization parameters.
The unit cell geometries implementing the optimized phase profiles for each grating are shown in Fig 2c alongside corresponding electron micrographs. Each unit cell was tessellated into a bulk metasurface grating 250 × 250 µm in size.
Each grating was illuminated with laser light at λ = 532 nm linearly polarized at 45°relative to the axes of the grating. The polarization state on the diffraction orders of interest was then measured with a commercial rotating waveplate polarimeter.
In Fig. 2(b), for each grating, the measured polarization ellipses on each order are plotted alongside the desired target ellipses as well as the ellipses predicted by a finite-difference time-domain (FDTD) simulation of the grating geometry. We observe a qualitatively close correspondence between the desired target, simulated, and observed polarization states. Further data is tabulated in Appendix A.

Metasurface polarimetry
Each order of the metasurface polarization grating can be thought of as a diattenuator followed by a phase retarder, each oriented along x/y (Eqn. 4 and Fig. 1(d)). When light from a source passes through a polarizer oriented at 45°, a polarization state is produced on the grating order, ideally close to some target state ( Fig. 3(a), top). When the grating is used in reverse -that is, with the grating followed by a linear polarizer oriented at 45°-each diffraction order may be seen as a polarization state analyzer for its characteristic Stokes vector ( Fig. 3(a), bottom). The A random initial guess for the phase profiles ì Φ x and ì Φ y is optimized to direct as much light as possible into the diffraction orders of interest using gradient descent under the constraints of the desired polarization states. This result is improved by a gradient-free method that accounts for simulated properties of the phase shifters used, and a final geometry is generated. These geometries are realized in TiO 2 for operation at λ = 532 nm. b, The scheme in (a) is used to generate two gratings, one for four polarizations of general interest (top) and one for a tetrahedron configuration of polarization states (bottom). Each grating generates four polarization states, and the target ellipse, expected result from FDTD simulation, and experimentally observed polarization ellipse on each grating order are shown. c, Design (black) and electron micrographs as-fabricated of the "four polarization" (top) and "tetrahedron" (bottom) gratings. In the tetrahedron grating, the small rightmost pillar has not survived fabrication. characteristic analyzer Stokes vectors are the same as the generated polarizations with the chiral component S 3 reversed (owing to the symmetry of this particular system -see Appendix E).
The grating may then be used as a parallel full-Stokes polarimeter with no polarization optics (with the exception of a single polarizer, which could be easily integrated on top of the gratingthe polarizer, even if it is imperfect, is indeed necessary for Stokes vector determination, as can be shown using simple Mueller calculus). This of course relies on a suitable choice of analyzer states, which must yield a non-singular instrument matrix; here, these states may be arbitrarily specified. The four polarization grating is not sufficient for full-Stokes polarimetry as its states are not linearly independent (in actuality, its imperfections break this and render it usable, though far from optimal, for polarimetry). For a polarimeter making N = 4 measurements, it has been extensively documented that, in the absence of calibration errors [37], a configuration of analyzers whose characteristic Stokes vectors correspond to (any) regular tetrahedron inscribed in the Poincaré sphere yields maximum signal-to-noise ratio in Stokes vector determination [36].
In acknowledgment of this, a larger version (1.5 mm × 1.5 mm) of the tetrahedron grating described above was fabricated. When laser light is incident, the four diffraction orders of interest diverge and pass through a polarizer oriented at 45°. Each beam then impinges on a standard silicon photodiode centimeters away, producing a photocurrent which is amplified and converted to digital form ( Fig. 3(b), right side).
The instrument matrix A must be determined by calibration. Accordingly, we carry out  Fig. 3. a, As each diffraction order may be thought of as a cascade of a diattenuator and a retarder (Fig. 1d), when light from a source of known polarization (in this case, linearly polarized at 45°) is incident, a characteristic polarization ì S c is produced. If light of unknown polarization ì S inc is incident in the reverse direction and the source is replaced with a detector, the measured intensity I ∝ ì S inc · ì S c , with ì S c identical to ì S c with a change in the sign of the last component. b, This allows the meta-grating to function as a parallel polarimeter. Each of the four diffraction orders of the tetrahedron grating may be used as an analyzer. Light incident on the metasurface passes through a linear polarizer at 45°and diffracts onto four photodiodes whose photocurrents are amplified and digitized through an analog-to-digital converter (ADC). During testing and calibration, light passes through various polarization optics in front of the meta-grating. The role of the boxed components (i) and (ii) are described in the text. c, As the linear polarizer is rotated in front of a polarization Mach-Zehnder interferometer ((i) in (b)) whose path length difference is larger than the laser coherence length L coh , the degree of polarization (DOP) varies. Plotted in red is the DOP measured by the meta-grating polarimeter which closely follows the theoretically expected curve (black). At 45°(inset) a DOP of p = 0.12 ± 0.018% is measured. a calibration scheme [38] developed for the well-known four-detector photopolarimeter of Azzam [39], applicable to any polarimeter with four intensity channels (N = 4) which explicitly accounts for imperfect quarterwave-plates. Each entry of the resultant instrument matrix A may be assigned error bounds which provide for the covariance matrix of any computed Stokes vector [40] allowing for the calculation of uncertainty bounds.

Quantifying partially polarized light
With the metasurface grating polarimeter thus calibrated, the Stokes vector of any incident beam may be determined from A and the measured intensities on the photodiodes. An interesting case is that of partially polarized light. Partially and un-polarized light, inherently a consequence of temporal coherence phenomena [2,41], are common in all non-laser light sources. The degree to which light is unpolarized is quantified by the degree of polarization (DOP), defined as where S i denotes the i th element of the Stokes vector. Fully polarized light corresponds to p = 1, totally unpolarized light to p = 0; in intermediate cases, p represents the ratio of the beam's power which is polarized to that which is not.
To study the response of the metasurface-grating polarimeter to varying DOP, a deterministic means of producing partially polarized light is required. We employ a Mach-Zehnder-like setup with two polarization beamsplitters [2,42]. This is depicted in Fig. 3(b), where the boxed components in (i) are included while (ii) is omitted (though (ii)'s presence would theoretically not affect the DOP). As a linear polarizer rotates in front of the interferometer, different fractions of incident light travel along each arm. When equal parts of the beam enter each path (when θ LP = 45°) and the path-length difference of the interferometer is many coherence lengths L coh of the laser source, the recombined beam will be totally unpolarized: The beam will be composed of half x-polarized light and half y-polarized light which no longer have phase-coherence. On the other hand, when θ LP = 0°or 90°, all light goes along one path only and the beam is completely polarized. At intermediate angles, p = |cos θ LP | [42].
A linear polarizer was rotated in front of the interferometer and the Stokes vector measured by the meta-grating computed. The corresponding DOPs (Eqn. 10) are plotted in Fig. 3(c). As shown in the inset, a minimum DOP of 1.2 ± 0.018% is observed. Finally, we compare the performance of the metasurface-grating polarimeter to a commercial and widely used visible-range rotating waveplate polarimeter (ThorLabs model PAX5710VIS-T). In a rotating waveplate polarimeter (RWP), a waveplate mechanically rotates in front of a linear polarizer and a detector. From the Fourier coefficients of the time-varying signal, the incident Stokes vector can be determined [12,43].

Comparison with a commercial rotating-waveplate polarimeter
An experiment was carried out using the setup depicted in Fig. 3(b) including boxed components (i) and (ii). A set of randomly selected linear polarizer (LP) and quarterwave-plate angles (QWP) were selected. In an automated measurement, the mounts holding the LP and QWP moved to these pre-determined angles and the polarization state produced at each of these configurations was deduced using the meta-grating polarimeter. Next, the commercial rotating waveplate polarimeter (RWP) was placed in the beampath in place of the metasurface-grating polarimeter. The QWP and LP revisited the same positions and the polarizations measured by the RWP were recorded.
The comparison is summarized in Fig. 4 with regards to the quantities of azimuth and ellipticity of the polarization ellipse (we plot the double azimuth and ellipticity angles 2θ and 2 , since these are the angular coordinates on the Poincaré sphere) and DOP. The graphs in the top row of Fig. 4 plot the values measured by the metasurface-grating polarimeter along the vertical axis and the values measured by the RWP on the horizontal axis (an ideal 1:1 correspondence line is shown in black).
For each quantity, the difference in the values reported by the two polarimeters is calculated and plotted in a histogram in the bottom row of Fig. 4. Each is fitted with a normal distribution, whose means (µ) and standard deviations (σ) are shown.

Optimization
In the literature of phase-only gratings, it has been shown using variational calculus that the optimum phase profile splitting light into a set of desired diffraction orders with maximal efficiency has an analytical optimum [34,44]. Once the desired amplitude and phase relationship of light in these orders is specified, a finite set of coefficients may be optimized to find this optimum grating. The question of an analytical solution, not to mention uniqueness and local minima, in the present work, however, is complicated by the fact that this optimization couples two such phase gratings together, acknowledges their discrete nature, and is influenced by the properties of available phase-shifters from a library. An analytical and statistical examination of this optimization will form the basis for future work.
We stress the simplicity of the optimization scheme used here. Optimized structures are more generally of great interest in nanophotonics, including freeform geometries designed with the aid of topology optimization [45][46][47][48]. These schemes, however, are computationally expensive and require the repeated use of full-wave simulations. The gratings in the present work, on the other hand, are optimized using only the numerical evaluation of simple Fourier integrals. This method of course requires a considerable assumption about the physical nature of the problem, in that the transmission properties of the structures must be assumed to be of a certain mathematical form (cf. Eq. (4)). Additionally, the structures to be used are limited to those that have been previously simulated and may not take on arbitrary geometries. Nonetheless, this simple scheme enables arbitrary polarization control of the diffraction orders, and its success suggests that related polarization problems are an interesting application area for more sophisticated optimization.

Parallel polarization state generation
As illustrated in Fig. 2, for both the four polarization and tetrahedron gratings, the polarization ellipses observed on the diffraction orders compellingly match the desired target ellipses and those expected from FDTD simulation. A more quantitative view of this comparison is given in Appendix A; there, we see that the average deviation in azimuth and ellipticity between target and measurement is 4.37% and 3.57%, respectively. Much of this difference is likely attributable to fabrication imperfections and unpredictability of the exact element dimensions. As the nominal dimensions of the fabricated geometries are slightly adjusted to compensate for overexposure and overetching, the measured polarization ellipses are observed to change smoothly in response (Appendix B). Given even ideal fabrication, the ellipses would not completely match the target states since the optimization will never achieve perfection. From the perspective of polarimetry, at least, any imperfection in the performance of the tetrahedron grating can be easily accounted for by the calibration (while the matrix condition number of A may only increase somewhat).

Parallel polarimetry
Above, we presented a characterization of the meta-grating's polarimeter functionality, specifically its ability to measure partially polarized light and its polarimetric performance in comparison with a commercial RWP.
We demonstrated that the meta-grating polarimeter can detect partially polarized light produced by a polarization Mach-Zehnder interferometer. The dependence of DOP on linear polarizer angle follows the expected theoretical trend. At 45°, we measure a minimum DOP of 1.2 ± 0.18%. While the minimum DOP would ideally be 0%, the DOP aggregates error from all four Stokes components, and the minimum value achievable is in a sense a reflection of the accuracy of the polarimetric system as a whole. The exact significance this minimum value is not immediately clear -there are experimental subtleties to the production of partially polarized light with a polarization Mach-Zehnder interferometer, including the DOP varying over the profile of the output beam. The non-zero DOP observed at 45°could be a consequence of errors in the polarimeter, actual deviations of the beam's DOP from zero, or likely some combination of the two. The result, however, should be taken as a testament to the flexibility of the presented device -an integrated element in a completely parallel measurement can provide information about DOP, a coherence property.
Lastly, we compared the performance of the meta-grating polarimeter to that of a commercial rotating waveplate device. For the quantities of DOP, azimuth, and ellipticity -polarimetric parameters of common interest -we examined the difference in the values measured by the two polarimeters and treat these as statistical quantities. For DOP, we observe a standard deviation of σ = 1.6% and a mean difference of µ = 0.6%, a systematic error which could easily be attributed to one polarimeter being slightly misaligned. For azimuth χ and ellipticity , we observe σ = 0.023 rad = 1.32°and σ = 0.0075 rad = 0.43°, respectively. This implicitly assumes that the RWP is an absolute polarization reference; any degree to which this is not true will increase the perceived error of the meta-grating polarimeter. Moreover, this error is itself polarization-dependent (see Appendices C and D). By sampling the error more or less uniformly over all possible polarizations, the values of σ for each parameter represent worst-case performance. Already, these are in the vicinity of the errors quoted for the RWP used (Appendix C). Notably, the performance of the RWP can be approached with a device having no moving parts, no bulk birefringent polarization optics, and detector-limited time resolution.
In Appendix D, we study angle-of-incidence effects and conclude that up to ∼ ±5°accidental misalignment, the meta-grating polarimeter could still be used with reasonable accuracy.

Context within diffractive optics and metasurfaces, and technological perspective
Diffractive optics has long been the subject of intensive investigation. Within diffractive optics, polarization gratings emerged from the realization that polarization had been largely overlooked [28,31,32]. As described in the review of Cincotti [29], polarization gratings (and their close cousins, polarization holograms [49,50]) may be seen as a periodic modulation of diattenuation, retardance, angular orientation, or all three [29]. A parallel Stokes polarime-ter may be constructed from cascades or a spatial interlacing (sometimes dubbed "spatial multiplexing") of such gratings [28,29,[51][52][53]. More recently, metasurface-based diffractive polarimeters [22][23][24]26] have appeared that, despite a higher spatial resolution of grating elements and new operating wavelengths, rest on a spatial multiplexing of the same unit cell designs conceived of with earlier polarization gratings.
Many diffractive optics works have examined periodic spatial modulation of retardance [29,31,51,52,[54][55][56], but retardance itself is not all that counts. An overall phase may be added to both polarization components while keeping retardance constant, and this overall phase may vary spatially, too. This degree of freedom has largely not been exploited, and as a consequence, several discrete or spatially interlaced polarization gratings are necessary to generate (or measure) polarization in parallel [22,24,25,28,53] and the generated (or analyzed) states cannot be arbitrarily specified.
Explicit use of this phase freedom has interesting consequences [19], and it is the control of both retardance and overall phase that distinguishes this work. Notably, it allows for the generation of arbitrarily specified polarization states on the diffraction orders and equivalently, polarimetry with an arbitrarily specified set of basis polarizations. We note that a similar approach with similar functionality has been demonstrated using liquid crystal spatial light modulator technology [57,58]. Owing to the constraints of these SLMs, however, a relatively complex double-pass architecture relying on a waveplate and a polarization beamsplitter must be employed in order to impart independent phase profiles on x and y polarized light independently, limiting the scope of potential applications.
In the present work, equivalent functionality has been embedded in a single, flat metasurface where the two phase profiles may be applied in the same plane, improving prospects for widescale application. Requiring only a linear polarizer (which may be easily integrated on top of the device as a wire grid), a single device may generate/measure polarization in parallel with no bulk birefringent optics or moving parts, permitting ease of integration and minizaturization. The device may be extended to spectroscopic polarimetry if linear arrays of detectors are used or to polarization imaging with imaging sensors. This may represent a far simpler solution to integrated full-Stokes polarimeters and polarization cameras which would not require bulk lithographic patterning of dichroic or birefringent material on top of a focal plane array [5,[59][60][61][62][63].
In diffractive optics, there exists an extensive body of work on geometric phase devices [51,52,55,56,64,65]. In this approach, a phase profile may be imparted on circularly polarized light by spatially varying the angular orientation of a retarder. These retarders may take the form of, e.g., micro-fabricated dielectric [51] or liquid crystal [65] materials. The simplicity of this approach has numerous advantages, including achromatic phase (all wavelengths see the same angular orientation) and ease of fabrication, but the same simplicity is also a drawback. In contrast to the approach presented here, the spatially varying polarization in the plane of the grating cannot be arbitrarily engineered; the phase profile experienced by one circular polarization is constrained to be equal and opposite that experienced by the other [19]. Consequently, phase profiles cannot be imparted independently on an orthogonal basis of polarization states, and as such the polarization (and analysis) states of the diffraction orders cannot be arbitrarily specified as in this work. Nonetheless, geometric phase gratings have shown promise for use in a variety of polarization imaging systems [66][67][68]. However, owing to the constraint discussed above, multiple successive gratings [66] and other polarization optics are required for full-Stokes imaging polarimetry. The present work has the potential to significantly simplify these systems.

Conclusion
We have presented a method for the design of a metasurface diffraction grating with orders whose polarization states may be arbitrarily specified. We design and fabricate two such gratings and characterize the polarization states of the diffraction orders, finding close correspondence with desired target polarization states. The grating, by time-reversal symmetry, may also function as a parallel polarization analyzer and permits for snapshot full-Stokes polarimetry. We demonstrate its ability to measure partially polarized light. Additionally, we compare its performance to a commercial RWP and present a statistical analysis showing comparable performance. The metasurface-based polarimeter has no moving parts and no bulk birefringent optics which facilitates its integration, and thus presents a significant simplification in polarimetric technology which may extend easily to polarization imaging if detector arrays are used instead. Being a grating, the chromatic dispersion of the orders may also be harnessed for use in spectroscopic polarimetry.
This work is a testament to the flexibility of metasurfaces in the realm of polarization optics and may have consequences for low-cost, lightweight, and significantly simplified polarimetry and polarization imaging systems.

A. Tabulated data on measured polarization ellipses, design, and overall efficiency
Tabulated data detailing the measured polarization ellipses shown in main text Fig. 3 are given in Tables 1 and 2. We note that there is an inherent issue with using the metrics in Tables 1 and 2 because certain azimuths (i.e., near the poles of the Poincaré sphere) are far more error prone. Even given this, the data are merely a supplement to the qualitative correspondence that is visually evident in Fig. 2.
In Table 3, we provide the optimized phase profiles { ì Φ x , ì Φ y } for both gratings as well as the geometries of the 600 nm tall a-TiO 2 pillars that optimally impart these phase shifts (these geometries detail the schematics of each grating in Fig. 2(c)).
With any diffractive element, the question of efficiency naturally arises. In the present work, we stress that absolute efficiency is not the foremost concern, since in principle this work is independent of any particular material platform or wavelength regime. To provide order-ofmagnitude type efficiency estimates, however, we characterized the tetrahedron grating described in the main text, with the results given in Table 4. In Table 4, the power in the innermost four diffraction orders (the four of interest) is given as a fraction of the power of the incident λ = 532 nm beam and as a fraction of the power in all diffraction orders. It can be seen that 63.4% of the incident power passes through the grating and diffracts into the orders. All of these orders and their energy are usable for polarimetry if extra detectors are employed, and indeed this would increase the accuracy of the polarimeter. It can also be seen, too, that the power in each of the four orders of interest is more-or-less uniform, as constrained by the optimization scheme.
For this grating, the optimized efficiency expected mathematically was η = 73.1%. The fraction of the power in the four innermost orders with respect to all other diffraction orders, then, is off by about a factor of two from this prediction. This may have its origins in imperfections of the grating as-fabricated, or in the design assumption that the acquired phase is constant over the unit cell of one element. An optimization scheme that explicitly acknowledges the radiation pattern of the phase shifters may yield a better correspondence.

B. Effect of fabrication imperfection on observed polarization ellipses
Electron beam lithography yields size discrepancies between desired structures (as in a CAD layout file) and what is actually realized. Generally, the fabricated structures are larger than intended. This effect depends in a complicated way on dose, development time, etch rate, and other fabrication-related factors. The phase imparted by the structures in this work is size-dependent, so one would expect fabrication imperfections to have a notable effect on the polarization ellipses observed on the diffraction orders, relative to design. Here we present additional data chronicling Table 1. Extended polarization state data for tetrahedron grating, as presented in Fig.  2(b). The azimuth (θ) and ellipticty ( ) angles for each diffraction order (target, FDTD, and measured) are given in radians. Note that the azimuth of the target polarization state for the m = +2 order is not defined since this state was designed to be circular. Varying scale: Varying offset: this effect. For each grating design, several samples were fabricated with either fixed size offsets in the CAD (10, 20, or 30 nm smaller than desired) or fixed size scaling factors (all dimensions scaled by 85, 75, or 70%). The polarization states on the diffraction orders from all such gratings were recorded.
We illustrate this by depicting the polarization ellipses recorded from the tetrahedron grating with different size offsets and scalings in Fig. 5. It can be seen that varying the nominal size of the fabricated structures has a significant effect on the observed polarization ellipses, which Table 2. Extended polarization state data for the four-state grating, as presented in Fig.  2(b). The azimuth (θ) and ellipticty ( ) angles for each diffraction order (target, FDTD, and measured) are given in radians. Note that the azimuth of the target polarization state for the m = −1 and m = +1 orders are not defined since these states were designed to be circular. is to be expected. The data presented in the text came from samples with -20 nm offset for the four-polarization grating and -30 nm size offset for the tetrahedron grating; these samples produced ellipses closest to the target polarizations.

C. Additional detail on polarimeter comparison
What do the histograms presented in Fig. 4 mean? In each histogram, we examine a statistical distribution of the difference between the set of measured values and (what we take to be) the true values, those reported by the commercial RWP. Each plots the distribution of some practical quantity derived from the Stokes vector. Depending on the polarization states of the test points selected, these distributions could be artificially broadened or narrowed. For example, if all the test polarization states are located near the poles of the Poincaré sphere, the azimuth histogram will be broader; if the test states are all located on the equator, the distribution will narrow. The deviation in the polarimetric parameters measured by both polarimeters will vary in a vectorial way as a function of the Stokes vector, as dictated by the error in the instrument matrix (which is a matrix quantity; see Appendix D). In order to be unbiased, the measurement test points should be uniformly distributed in the entire range of the given parameter, so that all of the best cases and the worst cases receive equal representation. If this is done, the standard deviation of the distribution of differences between measurement and a reference can be indicative of the accuracy of the polarimeter with regards to that particular quantity; the mean is indicative of some systematic error that causes the polarimeter to be off by a constant amount relative to a reference.
In this work, we have endeavored to explore (somewhat uniformly) all possible values of DOP, azimuth, and ellipticity relative to what we treat as an absolute polarization reference, that being the RWP. To a good approximation, then, we can treat the σ of our histograms to be a measure of Table 3. Details of the design of the two gratings presented in this work. For each of the two gratings, thex andỹ phase profiles are provided (in radians). Corresponding to each pair {φ x , φ y } are the lateral dimensions {w x , w y } of a rectangular pillar of a-TiO 2 , 600 nm in height best implementing this pair of phases (in nanometers).

Grating Design Parameters Tetrahedron Grating
Four State Grating  Table 4. Efficiency data for the tetrahedron grating.  Table 5, with values for the RWP obtained from its datasheet (as of this writing listed on ThorLabs' webpage at this link). We do not know how the specified accuracies of the RWP are obtained, so whether they are directly comparable is unknown. Additionally, we treat the RWP as an absolute polarization reference. Any degree to which this is not the case will increase the perceived error of the metasurface grating polarimeter.

Tetrahedron grating efficiencies
The overall point we wish to make here is that the accuracies for the metasurface grating polarimeter closely approach those of the RWP, despite the former being a monolithically integrated device with no moving parts or bulk polarization optics. .

Dependence of polarimetric accuracy on angle-of-incidence
A polarimeter is calibrated with a beam impinging at one angle of incidence; if it is then used at a different angle of incidence, the determined Stokes vector will consequently contain error. This is an effect relevant to all polarimeters, including the rotating waveplate polarimeter.
We conducted a small study on the metasurface grating polarimeter to determine its susceptibility to angle dependent effects, an important question in assessing its technological relevance. If the polarimeter is calibrated for a 0°angle-of-incidence, how much could an end user accidentally tilt the device and still expect to obtain reasonably accurate results? The study presented here is by no means exhaustive.

D.0.1. Description of error analysis scheme
We imagine a scenario in which the polarimeter is used assuming a "perceived" instrument matrix A p which the user erroneously applies believing that it is correct and an "actual" instrument matrix A a that reflects the true behavior of the polarimeter. If the user makes an observation in the form of an intensity vector ì I meas , they will report a measured Stokes vector ì S p = A −1 p ì I meas . The Stokes vector in actuality, however, is ì S a = A −1 a ì I meas , meaning that there is measurement error which we can express in vector form as The error accrued from use of the incorrect instrument matrix (because of e.g., an angular tilt of the polarimeter) has a polarization dependence that is fully governed by the matrix (A −1 p A a − I) (I is the 4 × 4 identity matrix). The eigenvectors of the matrix A −1 p A a will merely be stretched or compressed along the same direction, and will suffer no distortion of azimuth, ellipticity, or DOP.
The above discussion suggests a Monte-Carlo-like error analysis scheme, depicted in Fig. 6. Beginning with a sampled set of actual Stokes vectors, { ì S a }, we compute a set of measured intensity vectors that would actually be observed by the user, { ì I meas } = A a { ì S a }, corresponding to each of the actual Stokes vectors. Making use of the perceived (incorrect) instrument matrix A p , the user will compute a set of perceived Stokes vectors { ì An error analysis can be carried out between { ì S a } and { ì S p } (Fig. 6), with respect to any number of possible quantities derived from the Stokes vector.
This error analysis scheme reveals how a given Stokes vector will be measured by a polarimeter that is out of its calibration condition. In general, the whole Stokes vector will be deformed, so a user measuring a given beam will not only observe a different polarization ellipse, but may also report a different beam power or a beam that appears artificially polarized or depolarized. The discrepancy between A a and A p could stem from any error source, though here we wish to examine the effect of angle of incidence. To this end, we begin by calibrating the polarimeter at normal incidence. Then, with the meta-grating placed on a rotation mount, the calibration is repeated at incident angles of 5°, 10°, 15°, and 20°. In a realistic situation, a user will believe that they are using the instrument matrix from normally-incident calibration, that is, A p = A 0°. If, however, the device is tilted at angle θ, A a = A θ . We perform the analysis detailed above for each incident angle. We take { ì S a } to be a uniform sampling of points on the surface of the Poincaré sphere. (In a more general analysis, the entire volume of the sphere would be included too to account for partially polarized inputs).
The results of this analysis are depicted in Fig. 7. For each Poincaré sphere in Fig. 7, the dots represent the set of test polarizations { ì S a }. For each angle, the deviation in azimuth, ellipticity, and DOP is computed between all of the members of { ì S p } and { ì S a }. These errors are shown as the color of the dot on the sphere, with red corresponding to higher error. It can be seen that for different incident angles and different quantities of interest, different regions of polarization state-space experience higher error. The maximum and minimum errors for each quantity/angle, as well as the standard deviation, are also given. We stress again that the positions of the dots in Fig. 7 represent the actual Stokes vectors, not the measured ones; one could track the way in which the Poincaré sphere distorts under the influence of the matrix (A −1 p A a − I) as well. The Stokes vectors constituting the rows of the instrument matrix are sometimes referred to as analyzer vectors because any incident Stokes vector is projected on these to produce the measured intensities ì I. Also shown inscribed in the spheres of Fig. 7 (in pink) are the analyzer Stokes vectors at angle θ (the rows of the instrument matrix A θ ) alongside the ideal tetrahedron (gray line) for each case. From the previous study whose results are detailed in Table 5, the uncertainty in the DOP, azimuth, and ellipticity of measured polarization ellipses are known for normal-incidence polarimetry.
In Fig. 7 the average and variance (µ and σ) of the errors in these same quantities for each angle of incidence are given. In order to evaluate the effect of off-normal incidence on polarimetric performance, µ + σ (or µ − σ, whichever is larger in absolute value) for each quantity should be compared to the precisions in Table 5 ig. 7. Results of angle-dependent polarimetry study. Note that DOP errors are expressed in absolute terms (i.e., not in %). For each quantity of interest (DOP, azimuth, and ellipticity) and each incident angle (5°, 10°, 15°, 20°), a Poincaré sphere populated with dots representing a sample set of Stokes vectors is shown. The color of each dot represents the error in that quantity a user would report at that accidental misalignment, with red representing higher error. Also given are the maximum, minimum, mean, and variance of the error over the sample set for each quantity and angle. the expected error from an accidental tilt is inside the measurement uncertainty of the polarimeter at normal incidence anyway, and its effect is minimal. Even at a 5°misalignment, the errors (µ ± σ) exceed the uncertainties measured at normal incidence, but not exceedingly so (9% vs. 1.6% for DOP, 4.42°vs. 1.32°for azimuth, and 1.60°vs. 0.43°for ellipticity). Qualitatively, then, the polarimeter could suffer an accidental misalignment of 5°or less and still offer reasonable accuracy, with some polarization states that would yield particularly high error (clustered around the red regions in Fig. 7). Even if the misalignment exceeds this, the grating can still be used for polarimetry assuming a new calibration is carried out. For this reason the grating can still be used in a polarization imaging application where a wide angular bandwidth is required, so long as the angular variations are characterized.  Fig. 8. On the left, generators (combinations of linear polarizers (LP) and quarter-wave plates (QWP) that generate x, 45°, and RCP (the cardinal directions on the Poincaré sphere) are shown. On the right, analyzers constructed from these generators by three different linear transformations are shown. In each case, one of the three analyzers (marked by a red 'x') shown passes the orthogonal polarization rather than the one produced by the generator. Intuitively, this demonstrates that the analyzer's Stokes vector differs from the generator's Stokes vector in a way that depends on the symmetry of the transformation between the two.

E. Comment on reciprocity, symmetry, and correspondence between polarization analyzers and generators
A configuration of polarization optics implementing a singular Jones matrix (meaning it contains a polarizer-like element) is known as a polarization state generator. No matter the state of incident light illuminating the generator, the polarization state-that is, the Stokes vector-of light exiting the generator will always be the same, though its intensity will vary. We denote the characteristic polarization state produced by a polarization state analyzer as ì S c . A polarization state analyzer is a configuration of polarization optics that provides an intensity modulation depending on the incident polarization. In particular, the analyzer has its own characteristic polarization ì S c , and the intensity detected at the exit of the analyzer follows the trend I ∝ ì S inc · ì S c . If ì S c corresponds to a fully polarized Stokes vector with p = 1, then the modulation of intensity with incident polarization state will have perfect contrast (that is, there is an ì S inc for which I = 0). If not, there is no incident polarization which can completely extinguish the output intensity.
Polarization optics is reciprocal, and a configuration of polarization optics working as a generator can also be used as an analyzer. What is the relation, then, between ì S c and ì S c ? This depends on the symmetry by which the generator is converted to an analyzer to face the beam.