Enhancing Direct Exoplanet Spectroscopy with Apodizing and Beam Shaping Optics

Direct exoplanet spectroscopy aims to measure the spectrum of an exoplanet while simultaneously minimizing the light collected from its host star. Isolating the planet light from the starlight improves the signal-to-noise ratio (S/N) per spectral channel when noise due to the star dominates, which may enable new studies of the exoplanet atmosphere with unprecedented detail at high spectral resolution (>30,000). However, the optimal instrument design depends on the flux level from the planet and star compared to the noise due to other sources, such as detector noise and thermal background. Here we present the design, fabrication, and laboratory demonstration of specially-designed optics to improve the S/N in two potential regimes in direct exoplanet spectroscopy with adaptive optics instruments. The first is a pair of beam-shaping lenses that increase the planet signal by improving the coupling efficiency into a single-mode fiber at the known position of the planet. The second is a grayscale apodizer that reduces the diffracted starlight for planets at small angular separations from their host star. The former especially increases S/N when dominated by detector noise or thermal background, while the latter helps reduce stellar noise. We show good agreement between the theoretical and experimental point spread functions in each case and predict the exposure time reduction ($\sim 33\%$) that each set of optics provides in simulated observations of 51 Eridani b using the Keck Planet Imager and Characterizer instrument at W.M. Keck Observatory.


INTRODUCTION
With over 4000 exoplanets confirmed to date, detection has given way to the era of characterization, critical to understanding the properties of these systems. In this vein, high contrast imagers (HCI), which isolate the light from the planet, offer numerous advantages over indirect techniques that rely on the signal from the host star alone. Typically, HCI use advanced wavefront control techniques combined with coronagraphs to extinguish the star light and minimize contamination Corresponding author: Benjamin Calvin bcalvin@astro.ucla.edu, ben.a.calv@gmail.com to the planet signal (Macintosh et al. 2014;Jovanovic et al. 2015;Males et al. 2018;Beuzit et al. 2019). These systems often exploit low to medium resolving power (R∼10-1,000), integral field spectrographs to characterize the targets (e.g. the CHARIS instrument (Groff et al. 2016)). Besides providing spectral information about the target, dispersing the light offers two advantages. Firstly, the distance between a speckle and the optical axis increases linearly with wavelength, while a planet remains a fixed distance away, which can be used to differentiate between the two. Indeed, this technique is referred to as spectral differential imaging (SDI) (Sparks & Ford 2002). Secondly, the spectrum of a planet has a different profile to that of a star, which enables the observer to constrain the nature of the orbiting object. This technique has been exploited to detect or characterize both planets (Barman et al. 2015) as well as disks (Currie et al. 2017).
Recently, the field has shifted focus towards much greater resolving power (R>30,000), to really take advantage of SDI in the regime where spectral lines in the target begin to be resolved (Snellen et al. 2015). The technique, dubbed High dispersion Coronagraphy (HDC), optimally combines high contrast imaging techniques such as adaptive optics/wavefront control plus coronagraphy to high resolution spectroscopy (Wang et al. 2017;Mawet et al. 2017). One approach that has been explored is to use an optical fiber to route the light of the known planet from the focal planet to the spectrograph. A single-mode fiber (SMF) is the ideal transport vehicle owing to the fact it has a field-of-view (FOV) that can be matched to the 1 λ/D width of the point spread function (PSF), enabling efficient coupling for the planet light and suppression of unwanted star light. Its small core size only allows light to be guided in a single mode providing spatial filtering, which further suppresses starlight speckles from coupling in and more importantly delivers an ultra stable output beam profile, highly desired by many instruments (Schwab et al. 2012;Woillez et al. 2003;Crass et al. 2020). In addition, its narrow FOV reduces the amount of sky background injected into the spectrograph, which can be several orders of magnitude greater in the case of a seeing-limited spectrograph.
HDC provides the ability to do species-by-species molecular characterization (e.g. oxygen, water, carbon dioxide, methane), thermal (vertical) atmospheric structure, planetary spin measurements (length of day), and potentially Doppler imaging of atmospheric (clouds) and/or surface features (continents versus oceans) (Wang et al. 2017). As such several projects have been initiated to realize this new technique from the ground including: the Keck Planet Imager and Characterizer (KPIC) (Jovanovic et al. 2019), which combines Keck AO and NIRSPEC, the Rigorous Exoplanetary Atmosphere Characterization with High dispersion coronography instrument (REACH) (Jovanovic et al. 2017a), which combines SCExAO and IRD and High-Resolution Imaging and Spectroscopy of Exoplanets (HiRISE), which combines SPHERE and CRIRES+ (Vigan et al. 2018). The phase I version of KPIC and the REACH instrument are both transitioning from commissioning to early science at the time of writing of this article and offer complimentary wavelength coverage across the near-IR (NIR) on Maunakea (REACH operates from y-H and KPIC operates in K and L bands), while HiRISE is still in the development stage.
Key to being able to disperse the faint planet signal across many pixels and maintain signal-to-noise (S/N), as is the case in a high resolution spectrograph, is maximizing the planet throughput. This can be done by improving the adaptive optics (AO) correction to boost the Strehl ratio and hence coupling efficiency, reshaping the PSF to better match the fiber mode (Jovanovic et al. 2017b), or minimizing the number of optics in the system. In addition, it is also important to minimize the stellar leakage into the planet fiber to reduce the photon noise contribution from the star. Improved AO correction can also help here, but specific focal plane wavefront control techniques such as speckle nulling (Bottom et al. 2016;Sayson et al. 2019) or the use of a pupil plane apodizing mask (Zhang et al. 2018), are better suited to reducing speckle noise. Although these technologies achieve different goals, they are used to reduce total exposure time, which is critical when characterizing faint exoplanets with high spectral resolution on large telescopes.
The technology or approach of choice depends on the parameters of the system being observed, such as planetto-star flux ratio, angular separation, and the waveband of observation. In this paper, we present the development of two technologies that can help boost the performance of HDC on KPIC and similar instruments, namely: Phase Induced Amplitude Apodization (PIAA) optics for re-shaping the beam and boosting coupling and a grayscale microdot apodizer (MDA) for suppressing diffraction features at small angular separations. We aim to deploy these as part of the phase II upgrade of the KPIC instrument in late 2021. In Section 2 we outline the two technologies and present the design and simulated performance of such devices. In Section 3 we present the experimental setup and procedures to evaluate the two technologies and in Section 4 we summarize and compare the results to simulations. Section 5 compares the two technologies in the context of a hypothetical observing scenario to highlight the benefits of each in their respective domains and Section 6 rounds out the paper with some concluding thoughts.

APODIZATION OPTICS
This section provides an overview of the two technologies that we have developed to enhance the S/N of direct spectroscopic, or HDC, observations of exoplanets: PIAA (see Fig. 1) and MDA (see Fig. 2) optics. Each has been employed previously in apodized coronagraphs in the context of high-contrast imaging (Watson et al. 1991;Nisenson & Papaliolios 2001;Kasdin et al. 2003; Figure 1. a) A ray trace through the PIAA optics. Here, the 50 mm represents the inner spacing between the powered surfaces of the PIAA optics. b) An image of the first lens, which refracts the beam to reshape it. c) An image of the second lens in the pair, which re-collimates the light after beam shaping. d) The radial sag profile for the first lens. e) The radial sag profile for the second lens. Both sag profiles are azimuthally invariant. Soummer et al. 2003), where the PIAA (Guyon 2003) or MDA (Dorrer & Zuegel 2007;Martinez et al. 2009a) modifies the shape of the beam at, or near, the re-imaged telescope pupil to reduce diffracted starlight at small angular separations where exoplanets may be directly imaged. These pupil-plane optics do not require any focal plane masks to work for our purposes with KPIC. Our application differs from conventional high contrast imaging in that we aim to maximize the S/N in the measured spectrum of an exoplanet using a diffractionlimited spectrograph that is fed by a SMF. As such, the PIAA and MDA optics that we developed for KPIC are optimized to maximize the coupling efficiency for planet light, η p , and minimize the fraction of the starlight that is coupled into the SMF, η s .
The coupling efficiency of a coherent, scalar field, E(r), into a fiber mode Ψ(r) is given by: where r is the coordinate in the plane transverse to the beam at the fiber. We use Eqn. 1, often referred to as the overlap integral, to compute η p and η s by plugging in the field at the fiber, E(r), due to the planet and star, respectively. When stellar photon noise dominates, S/N ∝ η p / √ η s , while in most other cases S/N ∝ η p .
In essence, the PIAA optics are designed for the latter scenario, whereas the MDA is optimized for the former. The PIAA optics consist of a pair of beam shaping lenses designed to alter the effective distribution of light at the pupil, in order to reshape the PSF in the focal plane. In the original implementation, PIAA lenses were used to reduce the Airy rings in coronagraphs (Guyon 2003). Later, PIAA optics were used to optimize the coupling to a SMF (Jovanovic et al. 2017b).
The KPIC PIAA optics consist of two aspheric lenses fabricated from CaF 2 because of its high transmission across the wavelength regime that KPIC operates (K and L bands; 2.0-4.2 µm). AR coatings for this spectral region were optimized and deposited on both sides of each optic to minimize Fresnel reflections. Figure 1(a) shows a ray diagram of the PIAA lenses, which are designed to re-distribute an annular intensity distribution, similar to the centrally-obscured Keck pupil, into a quasi-Gaussian profile. As a result, the PSF is a better match to the fundamental mode (LP 01 ) of a SMF and, therefore, the coupling efficiency is improved.
The lenses each consist of one flat surface (facing outwards) and one aspheric surface (facing inwards). As the light propagates from the first aspheric surface to the second 50 mm away, the collimated beam is remapped and recollimated. In this way the PIAA optic pair can be inserted into a collimated beam without modifying (Column 2-4) Log base-10 PSF intensity for (Column 2) an on-axis source as well as sources with an angular separation of (Column 3) 5λ/D and (Column 4) 10λ/D from the optical axis (white cross). All are normalized to the peak intensity in the non-apodized case and using the corresponding central design wavelength (3.8 µm for the PIAA and 2.2µm for the MDA).
the downstream focusing optics. The sag profiles of the two lenses were designed by solving the differential equation in Guyon (2003), which leverages Snell's law to achieve the desired remapping. Figure 1(b) and (c) show the fabricated lens pair while (d) and (e) show the cross-section of the rotationally-symmetric sag profiles. We chose the sag profiles to achieve the desired remapping function at the central wavelength in the L band (λ 0 = 3.8 µm) because we expect the S/N to be limited by thermal background in the longest wavelength filters. However, the PIAA can be used over the full KPIC range with slightly degraded coupling efficiency in the shorter wavelength filters.
One limitation of the PIAA optics is that the remapped intensity depends on the position of the source with respect to the optical axis. While the lenses are designed to provide a quasi-Gaussian beam shape for an on-axis source, the exiting wavefront deviates from this and becomes heavily aberrated when the source is off-axis by even a few resolution elements (i.e. λ/D, where λ is the wavelength and D is the beam diameter at the pupil). Figure 3 shows the beam shape and corresponding PSFs without any alteration (Fig. 3, top row) and with (Fig. 3, middle row) the PIAA optics. The PIAA modifies the PSF favorably in the case of an on-axis source by concentrating more light into the PSF core. However, the off-axis PSFs suffer from a strong coma aberration with a magnitude that increases with the the angular separation ( Fig. 3 shows offsets of 5 and 10 λ/D). Due to the rotational symmetry of the PIAA design, the direction of the coma aberration will always point radially away from the core.
To utilize PIAA optics for HDC, the planet must be aligned to the optical axis of the PIAA lenses to receive the coupling boost. The star would then be off axis, and for the separations depicted in the figure, would diffract a small amount of light onto the location of the planet marked by the white cross. This is where its important to note that Fig. 3 displays the intensity of the PSF, which does not necessarily indicate the amount of light that will couple into a SMF. So although there may be star light of non-zero intensity at the location of the planet fiber, we need to compute the coupling of that speckle pattern to the SMF to understand the stellar leakage term. Figure 4 shows an azimuthally averaged line profile taken from a 2D coupling map computed for the PIAA, MDA and also with no optic in the beam (labelled Keck in the figure). It can be seen that the off-axis coupling response with the PIAA is very similar to that with a clear pupil, emphasizing that the PIAA does not increase stellar leakage.
Where the PIAA makes use of transparent aspheric lenses, the MDA uses an array of opaque microdots to shape the pupil illumination to reduce the brightness of diffraction features around the PSF (Martinez et al. 2009a). Since the MDA can be placed at, or near, the reimaged telescope pupil, the PSF is spatiallyinvariant; i.e. the PSF is approximately the same for the planet and star (see Fig. 3, bottom row). The MDA for KPIC uses a semi-random pattern of 25 µm squares in a 200 nm thick chrome layer on an AR-coated CaF 2 substrate (seen in Fig. 2). The size of the microdots was chosen to maintain a ∼10:1 ratio between the mask feature size and the wavelength of light to avoid anomalous diffraction effects (Martinez et al. 2009b;Zhang et al. 2018). This design is lossy because the chrome dots block light, creating a grayscale beam intensity distribution. The mask is optimized by maximizing the S/N for a planet spectrum assuming the measurement is dominated by stellar photon noise. For computational convenience, rather than maximizing the η p / √ η s ratio, we minimize η s /η 2 p , which is proportional to the required exposure time to achieve a given S/N in a stellar photon noise limited regime.
To optimize the effective transmittance of the MDA, we assumed a polynomial radial apodization function with field amplitude where c j are constants, r is the radial coordinate, and a is the beam radius. In our simulations, we multiplied A(r) by the expected Keck pupil function, which is not rotationally-symmetric. However, using a onedimensional apodization function simplifies the optical system by not requiring a rotational alignment between the apodizer and the beam. For each set of c j coefficients, we computed the fraction of on-axis planet light that couples into the SMF, normalized to the total energy incident on the apodizer. This slightly modified definition of η p includes both losses in coupling efficiency and the semi-transparent design of grayscale mask. The effective η s was defined as the fraction of starlight that couples into the on-axis SMF when the star is imaged off-axis (see Fig. 4), averaged over planet-star separations of 3-15 λ/D. Using these metrics, we found the optimal apodization function by minimizing η s /η 2 p with a simplex algorithm (see Fig. 3, bottom left). We re-  Fig. 3 at the central design wavelength and assuming no other aberrations. A coupling of 100% means that all of the light of the PSF couples into the on-axis fiber. We can see that the PIAA does not significantly affect the off-axis coupling of the clear Keck pupil. We can also see that the MDA decreases the off-axis coupling from 3-12 λ/D, excluding two localized regions of 4.5-6 and 8.5-9. peated the optimization for various values of N and opted to use N = 5 since adding more terms did not significantly improve performance.
We converted the continuous apodization function into a binary microdot pattern using the Floyd-Steinberg error diffusion algorithm (Floyd & Steinberg 1976;Dorrer & Zuegel 2007;Zhang et al. 2018) taking into account the relative transmission of the 200 nm thick chrome layer and the exposed substrate. Figure 2 shows the designed pattern and a photo of the fabricated MDA, which has approximately 500 microdots across the expected 12.3 mm beam size. The full coated region is 15 mm in diameter. Given that the S/N is more likely to be stellar photon noise limited at the shorter wavelengths, we optimized the MDA for the central wavelength of K band (λ 0 = 2.2 µm), but the MDA can technically be used with any KPIC filter. At the longest wavelengths, where thermal background tends to dominate, the MDA is not likely to improve performance because of the reduced throughput and potentially high emissivity of the opaque regions. Figure 5 shows azimuthally averaged line profiles of each on-axis PSF, normalized to the non-apodized case. The PIAA increases the flux in the core of the PSF, which leads to improved fiber coupling. On the other hand, the MDA reduces the diffraction from the star at angular separations beyond 3 λ/D, but at the cost of adding the semi-transparent optic and lowering the coupling efficiency. These technologies provide the abil- ity to enhance the performance of KPIC in two different regimes. However, each has a significant downside. While the PIAA increases the throughput for an on-axis source, the source and PIAA must be carefully aligned to the optical axis of the system; the off-axis PSF becomes heavily aberrated. The MDA suppresses diffracted starlight and thereby reduces stellar photon noise in the measurement of the planet spectrum, but at the cost of overall throughput.

EXPERIMENTAL CHARACTERIZATION
In this section we describe the experimental setup and tests carried out to characterize the fabricated devices.
The key properties to examine for the two technologies are the PSF shape, the throughput, and the coupling efficiency. To specify, we use throughput in this paper to refer to the throughput of the individual optics and not the overall effect that the optic has on the system's throughput. The throughput of the individual optics is less than 100% as a result of Fresnel reflections, absorption, and reflections from the micro-dots in the case of the MDA. Testing the throughput will help ensure that there were no errors in the manufacturing of the optics and that the AR coatings are performing according to spec. In addition, we will measure what effect these technologies have on the light coupled to a SMF on/off axis and compare this to simulations. Figure 6 shows the experimental setup with the PIAA mechanics in the beam. The setup to characterize and measure the MDA is equivalent, but with the KPIC coronagraph module at the "Test Optic" location.

Experimental Setup
This testbed can be separated into 4 main components. First, there is the "telescope simulator," which collimates light injected by a SMF. The SMF can be swapped between a 2 µm laser and a blackbody light source that is single mode across the 2-5 µm wavelength region. The collimating optic is an AR coated CaF2 lens, with f=200 mm. Its distance from the light source can be adjusted with a translation stage to ensure that the light is collimated regardless of the wavelength. The beam then passes through a pupil mask, which imitates the Keck pupil. Given the long focal length of the collimating lens, the beam can be approximated as having a flat top illumination after passing through the mask.
The second component to the testbed is the test optic. These are located in the beam immediately following the telescope simulator in collimated space. Both the PIAA and MDA are mounted on stages that can repeatably move the optics in/out of the beam path. This allows for comparative measurements to be taken quickly between the apodized beam and the non-apodized beam.
Following the test optics is the third component, the coupling arm. This begins with a field-steering pickoff mirror (FSM1) that directs light toward the offaxis parabola (OAP) used to couple the light. FSM1 is mounted on a magnetic plate that can be removed and repeatably replaced to give quick access to the two main functionalities of the testbed. This turning mirror is complemented by a second, fixed steering mirror (FSM2). The two in combination can translate the collimated beam and adjust its angle of incidence with respect to the OAP (inside of the OAP block). This allows for coupling to be efficiently optimized into the SMF. The OAP is a protected gold coated mirror with an offaxis focal length of 36.6 mm, which injects the light into a ZBLAN fiber (Le Verre Fluoré, MFD = 7.5 µm at a 2.0 µm wavelength, core diameter = 6.5 µm, cladding diameter = 125 µm). With the pupil mask diameter of 12.3 mm, this creates an F # = 3.0, which closely Lastly, the setup also contains an imaging arm. The imaging arm has two modes, with the first taking the collimated output of the test optic and passing it through a f=1000 mm AR coated CaF2 focusing lens (FL1) to create an image. This arm is folded for convenience by a 2" silver mirror (FSM3) toward the camera. The second imaging mode is re-imaging the output of the coupling fiber onto the camera. The mounted fiber output is incident on a f=5.7 mm AR coated aspheric lens (FL2), which collects all of the light from the fiber and re-images it onto the camera. As seen in Fig. 6, this reimaging assembly can be inserted and removed when switching from coupling mode to imaging mode.
An InSb camera (Merlin, Indigo) is used to carry out all imaging. It is sensitive from 1-5 µm, and needs to be liquid nitrogen cooled. It has 240 x 318 pixels and a pixel pitch of 30 µm. The PSF formed by the F # = 81.3 beam incident from FL1 is sampled by approximately 6 pixels per FWHM on this detector. Immediately in front of the camera, we place a spectral filter, used to both limit the background incident on the detector and to select the measurement band when using the blackbody light source. When we use the 2 µm laser and do K s measurements, a K s -band filter (Asahi-Spectra) is used. For L band measurements, we use a 3-5 micron bandpass filter.

Procedures
Before the camera could be used to make quantitative measurements, it required us to linearize its response, maximize its dynamic range and do a one-point nonuniformity correction (NUC) flat fielding. The camera's exposure time and video offset were coarsely adjusted to match the expected flux levels for the experiments. Then, they were carefully tuned and the response of the camera to varying flux levels was compared to the reading of a power meter. This resulted in a linear camera response with the maximum possible dynamic range. The next step was to perform a one-point NUC to ensure a uniform response across the detector. This was done with the camera entrance window blocked by a black piece of metal, such that a uniform thermal background from the plate filled the camera's entire field-of-view, while running the NUC correction algorithm built into the camera.

PSF Imaging
We recognize that the shape of the PSF is critical and that the faint wings can only be revealed at a high SNR. With the beam of interest projected onto the camera, the exposure time and video offset were adjusted both to bring the background counts down to around 50-100 ADUs and to maximize the signal. The 1 point NUC was applied as outlined above. The light source was blocked and a cube of 100 frames that constitutes the background were collected. The light source was unblocked and a cube of 100 frames with signal was collected. Finally, the light source was blocked once again and another cube with 100 background frames was col-lected. The two sets of background frames, bracketing the signal frames, were used to construct a background that was as similar to the background when the signal was acquired as possible.

Throughput
To make quantitative measurements of the flux using the camera, aperture photometry/radiometry was conducted. To obtain the throughput of a given optical element (e.g. PIAA or MDA), the flux from the PSF generated when the optic was in the beam was normalized by the flux of the PSF when the optic was out of the beam. As such, it was important to keep the exposure time and other camera settings constant between the two measurements to assure an accurate comparison.
We take the same pattern of 100 background frames, 100 signal frames, and then another 100 background frames both when the optics were in and out of the beam.

Coupling Efficiency
To determine the coupling efficiency to the ZBLAN optical fiber, we again compare the flux between two states: 1) light transmitted through the SMF re-imaged onto the detector and 2) the PSF that was directly incident on the fiber before being imaged onto the detector. These two states have non-common optics and so the throughputs of those optics had to be accounted for during the analysis.
To photometrically measure the coupling efficiency in a given band, we: 1. Adjust the light source power, exposure time, and video offset to maximize the signal from the reimaged coupling fiber, 2. Image, with backgrounds, the re-imaged fiber, 3. Carefully remove the re-imaging system and FSM1 to reconfigure into PSF imaging mode, 4. Image, with backgrounds, the PSF without adjusting any settings.
After normalizing out the differential losses in each arm, we can take the ratio between the extracted fluxes and determine the coupling efficiency in isolation.

Data Acquisition and Analysis
There are multiple things we can do with the imaged PSF to analyze and quantify it's properties in comparison to the model. For example, one can compute the overlap integral (Eqn 1) between the model and the experimental PSFs to assess their similarity. For all other forms of analysis (i.e. throughput or coupling), we must first extract the fluxes from the detector by carefully removing the background. The PSF is localized to, at most, a region with a radius of 25 pixels. Meanwhile the thermal background is a non-zero bias across the frame, that can be assumed to be uniform following the 1 point NUC. When using the single-mode blackbody source, the signal is small, so this background subtraction must be done carefully. To accurately only extract the flux from the PSF, we follow a two step process: 1) subtract a background frame collected close in time to the data and 2) model out the remainder of the background.
To achieve step 2, we take measurements of the total enclosed aperture flux at increasing aperture radii. Beyond the extent of the PSF, the encircled flux increases or decreases linearly (for a uniform background) with the total enclosed pixels, F internal = F P SF + α · n pix , where α is the average background flux. Thus, in order to get F P SF , we fit the linear part of the curve and solve to determine the y-intercept, which is the background free flux. The uncertainty in this measurement is the relevant value from the covariance matrix of the fit.
With the flux's extracted, the throughput can next be calculated. It is the ratio of the fluxes: ξ = F in /F out The coupling efficiency is mathematically very similar to the throughput, the ratio of the flux coupled into the mode of the SMF and the flux incident on the fiber face. However, there is more involved with getting to this step. As was stated in the procedure, there are many noncommon optics between the fiber re-imaging block and the focusing arm of the bench. Once those are accounted for, the coupling efficiency is as well: η = F coup /F in The key to qualifying the experimental measurements is to be able to compare them to accurate models. To ensure we get the highest degree of agreement, we replicate the parameters of Fig. 6 in a simulator. There are uncertainties in some of the physical parameters in the coupling arm of the setup: the NA of the coupling fiber and the effective focal length of the coupling OAP are known only to ∼ 5%. These uncertainties were accounted for in simulations and resulted in a range of expected values.

RESULTS
Here we summarize the measurements of the parameters outlined in the methods section and compare them to simulations.

PSF profiles
The critical feature for both technologies is the structure of the PSFs and specifically the faint structure in the wings. Only the 2 µm laser had enough power to reveal the faint structure on the MIR camera. Figure 7 and 8, present the PSFs obtained from the Indigo camera side-by-side with the corresponding simulations and the residual difference between the two. This enables qualitative comparison between the two, which is important to building confidence in both the manufacturing and design process. It can be seen from both figures, that there is a strong similarity between the experimental and simulated PSFs. The right hand panel in both figures shows that the residuals of the difference between the model and the experimental PSFs are very low, with a peak around the 10 −2 or 1% intensity level. Further, we can also use the overlap integral as a quantitative comparison tool for the PSFs. To account for misalignment's in the peaks of the two PSFs, we scan the model PSF across the experimental PSF in 2D and compute an overlap integral map as shown in Fig. 9. From the overlap integral maps, we can see that both technologies have a peak greater than 99.8%, indicating a high level of consistency between the experimental and simulated PSFs, validating the design and manufacturing process.
We can also compare the azimuthally averaged line profiles of the PSFs. By over plotting the line profile of the experimental PSF with the simulated PSF, we can  identify locations where the flux is unexpectedly high or low. In Fig. 10, we show these line profiles of the two technologies. The shaded regions indicate the standard deviation in the azimuthal direction of the imaged PSF. We can see that both the PIAA and MDA closely follow the simulated curves, once again emphasizing the similarity between the design and the characterized devices.

Throughput
The throughput is defined as ξ = F out /F in , where F in is the flux at the input to the test optic and F out is the flux at the output of the test optic. The simulations were carried out in discrete monochromatic bands, while the experimental measurements, aside from the 2 µm laser, were taken using a broadband black-body light source combined with bandpass filters. The simulated and measured throughputs are shown in Fig. 11, where the horizontal error bars represent the bandwidth of the lab filters.
As can be seen from the figure, both technologies met the expected throughput to within uncertainty. The PIAA is designed to reshape the pupil in a lossless fashion as described in Section 2. The throughput is well above 90% in both K and L bands as expected, and any systematic losses can be easily explained through residual reflections across the four AR coated surfaces.
We can see that the MDA had a throughput consistent with simulations of ∼ 50% in K-band. However, we see it begin to roll off in the experimental results in the L band. This is due to the AR coating on the MDA not being optimized for L band, because the losses associated with the MDA reduce the L-band flux to the point where the thermal background dominates. Therefore, the MDA was not expected to be scientifically useful in L band and hence the coating was not optimized in this range. Figure 11. A comparison of throughput curves between simulations and our experimental measurements for the PIAA and MDA optics.

Coupling Efficiency
The simulations for the coupling efficiency were also produced in discrete monochromatic bands, and compared to the polychromatic results obtained with a filtered black-body light source in the laboratory. The coupling efficiencies for the two technologies are shown in Fig. 12. The expected coupling for the non-apodized pupil is overlaid on these figures for reference.
It can be seen that the coupling for the PIAA optics matches our simulation well. We can also see that the coupling for the MDA matches the simulation quite well, except for the measurement with the 2 µm laser. We are unsure why this data point is off, but believe it has to do with the increased coherence of the 2 µm laser and interference effects generated by the MDA. To ensure that this was not merely an effect of the camera, the measurement was repeated by placing a Thorlabs S148c power meter near the final focal plane and making the same flux comparison as the camera. The power meter confirmed the higher than expected coupling when using the MDA and the 2 µm laser beam. While this is not well understood, it is not an undesirable result in the context of KPIC.
From the figure it is clear that the PIAA boosts the coupling from ∼ 60% in K and L bands without any additional optics to ∼ 70% in K and 84% in L band. In comparison, the MDA reduces the coupling in K band to ∼ 48% and in L band to 45%. It should be made clear that these results are for the Keck like pupil mask in our experiments, which has oversized spiders, and at the Keck telescope, the coupling will be 3 − 4% greater in all cases.
Looking at the impact of the optics at the system level by combining the throughput and coupling efficiency, the PIAA has a total system throughput of 66% in K Figure 12. A comparison of coupling efficiency curves between the simulation and our experimental measurements for both test optics.
band and 77% in L band while the MDA is closer to ∼ 24% in both K and L bands. The impact of these efficiencies will be discussed in the following section.

DISCUSSION
It is clear from the results that the PIAA and MDA have different characteristics that will be useful in different contexts, so we will address them individually.

Beam Shaping Optics
The PIAA are lossless beam-shaping optics. We can see from the Ks and L band measurements that there is an increase in coupling efficiency, from ∼ 60% without the PIAA to ∼ 75% with PIAA in K band and ∼ 85% in L band, where the lenses were optimized to operate. This boost in coupling is only present for the on-axis source as PIAA optics suffer strong aberrations off-axis as shown in Section 2 above. The lenses have a small loss (∼ 8%), which is equal for both the star and the planet. For KPIC to utilize these optics effectively, the known planet will need to be aligned with the optical axis of the PIAA optics, i.e, on-axis. This will result in a throughput increase for the planet light (improved coupling), and a reduction in the starlight (losses from optics and aberrations for off-axis star). Although the PIAA optics may scatter some of the star light onto the location of the planet fiber, for small angular separations between the star/planet as shown in Fig. 3, the coupling to the fiber will be extremely low. In this way, the PIAA optics can reduce the exposure time to reach a given SNR, which will also allow fainter objects to be observed.

Micro-dot Apodizer
The MDA's effect is more subtle. The role of the MDA is to decrease the amount of contaminating light from an off-axis source that gets coupled into the SMF. As can be seen from the line profiles (Fig. 5), the PSF from the apodizer has nearly an order of magnitude less flux between 3 and 12 λ/D compared to the PSF from a non-apodized pupil. So, in situations where the light from the on-axis host star is drowning out the signal from the off-axis planet, using the MDA can help isolate the planet light. One drawback of the MDA is, to achieve such starlight suppression, the apodizer must decrease the throughput of the on-axis (star) and off-axis (planet) objects to ∼ 50%. Furthermore, the coupling is 48%, lower than the native PSF and significantly lower than when using the PIAA optics. Therefore, one must carefully consider when to use this technology.

Exposure Time Calculation
In this section we look at the impact of the two technologies on the exposure time of a simulated observing scenario of the planetary system 51 Eridani b, with KPIC, in both K and L band. Although the star is typically on-axis during acquisition, a tip/tilt mirror in the injection unit is adjusted in the final steps of acquisition to put the known planet on-axis and align it with the SMF. In this scenario, the exposure time (τ exp ) of an observation to reach a given SNR is proportional to the coupling efficiency of the stars PSF (η s ) and approximately inversely proportional to the square of the coupling efficiency of the planet PSF (η p ): τ exp ∝ η s /η 2 p To see how each technology effects the exposure time, the properties of KPIC were included in a realistic exposure time calculator (ETC). η s and η p were scanned across a grid of reasonable values for the case of observing 51 Eridani b. Figure 13 shows the contour maps of exposure time vs raw contrast and throughput to achieve a cross-correlation function (CCF) S/N=10. On these figures, discrete points can be seen for the case of the native PSF (red dots), the PIAA (white dots) and the MDA (gold dots) PSFs. In addition, the cyan dots highlight the phase I level of performance of KPIC on-sky before deploying these technologies in phase II.
It can be seen that in the case of 51 Eridani b, the PIAA optics offer little improvement in K-band compared to the expected phase II performance, while the MDA can reduce the exposure time by ∼ 33% from 3 to 2 hrs. Despite the fact the MDA decreases the planet's throughput, it also suppresses the star light, improving contrast and the net effect is an improvement in the detection exposure time. However, in L-band, which is dominated by thermal background, the PIAA optics offer the advantages in exposure time, reducing the ex- Figure 13. Exposure time contours for S/N=10 detection of 51 Eri b using the different technologies in K-band and L-band in units of hours. Left, we can see in the K-band how the MDA decreases the planet's throughput, but the resultant increase in star contrast creates a net improvement in detection exposure time. Right, we can see how the increased throughput of the PIAA helps to decrease the detection exposure time.
posure time of the expected phase II system by ∼ 33% from 3 to 2 hrs, while the MDA should be avoided. Factors of 33% are significant when it comes to observing time on 8-10 m class telescopes.
This demonstrates the relative strengths and weaknesses of the two technologies, and their applicability to a given observing scenarios depends on the waveband of observation, the flux ratio between the star/planet and their separation.

CONCLUSION
We have demonstrated the design, fabrication, characterization and accurate simulation of both PIAA and MDA optics in the context of HDC. The optics were optimized to operate in the K and L bands, which overlaps with the operating spectral bands of the KPIC instrument. The PSFs, throughput and coupling efficiencies all matched expectations from simulations, providing a high level of confidence in both the simulation tools and manufacturing capabilities. In a simulated observing scenario of 51 Eridani b, it was determined that the MDA would offer a reduction in exposure time of ∼ 33% in K-band, while the PIAA would offer a similar level of reduction for L-band observations. Such reductions in exposure time are important on 8-10 m class telescopes and are necessary to be able to target even fainter objects in future. The application of a par-ticular technology to a given observation will depend on waveband of choice, the flux ratio of the star/planet and their angular separation, and needs to be determined on a case-by-case basis.

ACKNOWLEDGMENTS
This work was supported by the Heising-Simons Foundation through grants #2019-1312, #2017-318 and #2015-129. Support was provided by the Simons Foundation grant "Planetary Context of Habitability and Exobiology" G. Ruane was supported by an NSF Astronomy and Astrophysics Postdoctoral Fellowship under award AST-1602444. W. M. Keck Observatory is operated as a scientific partnership among the California Institute of Technology, the University of California, and the National Aeronautics and Space Administration (NASA). The Observatory was made possible by the generous financial support of the W. M. Keck Foundation. The authors wish to recognize and acknowledge the very significant cultural role and reverence that the summit of Maunakea has always had within the indigenous Hawaiian community. We are most fortunate to have the opportunity to conduct observations from this mountain. Part of this work was carried out at the Jet Propulsion Laboratory, California Institute of Technology, under contract with NASA.