Probing Dark Matter with Adaptive-optics based Flux Ratio Anomalies: Photometric and Astrometric Precision

Strong gravitational lensing is a powerful probe of the distribution of matter on sub-kpc scales. It can be used to test the existence of completely dark subhalos surrounding galaxies, as predicted by the standard cold dark matter model, or to test alternative dark matter models. The constraining power of the method depends strongly on photometric and astrometric precision and accuracy. We simulate and quantify the capabilities of upcoming adaptive optics systems and advanced instruments on ground-based telescopes, focusing as an illustration on the Keck Telescope (OSIRIS + KAPA, LIGER + KAPA) and the Thirty Meter Telescope (TMT; IRIS + NFIRAOS). We show that these new systems will achieve dramatic improvements over current ones in both photometric and astrometric precision. Narrow line flux ratio errors below $2\%$, and submilliarcsecond astrometric precision will be attainable for typical quadruply imaged quasars. With TMT, the exposure times required will be of order a few minutes per system, enabling the follow-up of 100-1000 systems expected to be discovered by the Rubin, Euclid, and Roman Telescopes.


INTRODUCTION
Multiple lines of evidence suggest that the majority of the mass in the Universe is non-baryonic (i.e., not quarks) and does not interact with light.Understanding the fundamental nature of this so-called dark matter has proven elusive so far.
In the standard cosmological model, dark matter is assumed to be "cold", i.e., made of non-relativistic particles that do not have significant interactions with each other or with baryonic matter, apart from gravity.One example of cold dark matter is Weakly Interactive Massive Particles (WIMPs).This CDM model is extremely successful at reproducing observations of the universe at scales larger than an Mpc, including e.g., the cosmic microwave anisotropy, baryonic acoustic oscillations, and light element abundances.
However, many alternative dark matter models have been proposed both on theoretical grounds and as a means to solve some of the tensions that have been identified at galactic and subgalactic scales (see Bullock & Boylan-Kolchin 2017, for a review and references therein).These alternative models can be classified in terms of their particle physics properties, such as formation mechanisms and interactions, or in terms of their astrophysical signatures.In astrophysical contexts, 'warm' refers to models with a non-negligible free-streaming length, while 'self-interacting' pertains to those with significant dark matter self-interaction cross-sections.
Increasingly sensitive ground-based direct detection experiments have been able to set limits to the cross section of interaction with ★ Corresponding author, e-mail: ioana.zelko@gmail.comregular matter.In parallel, a variety of astronomical observations have constrained some of the generic properties of dark matter, based on electromagnetic observations.For example, the mass function of Milky Way Satellites and the non-detection of them in the Gamma and X-ray sets limits on the free streaming lengths and self-interaction cross section (e.g., Strigari 2018, and references therein).
In recent years, strong gravitational lensing has emerged as a powerful complement to these traditional techniques to study the nature of dark matter, because it relies exclusively on gravity, the only known interaction of dark matter.Dark matter models make very specific predictions on how mass should be distributed in the universe.Generically, dark matter models, together with appropriate models of non-linear growth and baryonic effects, can predict the clumping of dark matter as a function of scale, known as the halo and subhalo mass function, as well as the internal structure of halos and subhalos.CDM predicts a power law halo mass function rising as M −1.9 towards small masses (Springel et al. 2008), with dark matter density profiles described by the Navarro et al. (1997) profile, subject to modifications due to baryonic effects.
By carefully measuring the distortion of the multiple images of distant sources, gravitational lensing probes the foreground distribution on subgalactic scales, thus allowing scientists to perform a direct test of dark matter model predictions.For example, in CDM dark matter, halos and subhalos below 10 7 M ⊙ should be extremely abundant yet dark because their potential wells are not deep enough to retain gas and stars.Strong lensing has the potential to test this fundamental prediction of the model, since it is sensitive to substructure independent of its electromagnetic emission.In practice, a powerful way to constrain dark matter models using strong lensing is to measure the flux ratios of unresolved, multiplyimaged sources, often referred to as the "flux ratio anomaly" technique.The flux ratios between multiple images depend on a combination of second derivatives of the projected gravitational potential at the location of the images, making them very sensitive to the local "clumpiness" of matter.A cold dark matter universe will have many more halos and subhalos near a multiple image than a universe with warm dark matter, and thus results in more "anomalous" flux ratios with respect to those predicted by a smooth mass distribution (Mao & Schneider 1998;Cyr-Racine et al. 2019).
One complication is that in typical systems, composed of a galaxy lensing a background quasar, the stars in the foreground galaxy can also affect the flux ratios, a phenomenon called optically thick microlensing 1 .Thus, in order to filter this signal out one needs to study sources that are in projection significantly larger than microarcseconds to smooth over the stellar microlensing.For this reason, the first papers on this topic focused on radio-loud lensed quasars (Dalal & Kochanek 2002;Dobke & King 2006;Metcalf & Madau 2001).More recently, with the advent of adaptive optics-assisted integral field spectrographs and spectrographs in space, it has become possible to use the narrow line region of quasars as a tracer (Moustakas & Metcalf 2003;Nierenberg et al. 2014aNierenberg et al. , 2017;;Nierenberg et al. 2020).The mid-infrared emission of the hot dust surrounding the AGN offers another exciting window to measure flux ratios.Although only detectable in a limited number of instances with 8-10m class telescopes (Chiba et al. 2005), this technique is well within the capabilities of the James Webb Space Telescope (JWST) (Nierenberg et al. 2023) and will be accessible to Extremely Large Telescopes in the future.
In addition to affecting the flux ratios of multiple images, the distribution of matter on small scales also influences their positions, creating what are known as "astrometric anomalies" at the milliarcsecond level (Chen et al. 2007).There are other approaches that exploit both the 'flux ratio anomalies' and the 'astrometric anomalies', by themselves or in combination with the distortion observed in multiply-imaged, extended sources (Vegetti & Koopmans 2009;Birrer 2021).These methodologies provide powerful tools for understanding dark matter and galactic structure (Birrer et al. 2022).
The sensitivity of strong lensing as a probe of dark matter in each observed system relies on angular resolution and sensitivity.These factors are crucial as they determine the relative photometric precision and accuracy, as discussed by Gilman et al. (2019), along with the relative astrometric precision and accuracy, which is explored by Chen et al. (2021).In addition, the statistical power of the method increases with the number of systems that one can study, because by 1 Because the Einstein radius of a star is of order microarcseconds at the distances under consideration probing a larger volume one averages over the stochastic nature of the halo and subhalo distribution.
For these reasons, adaptive optics on large ground-based optical infrared telescopes can be transformative, enabling the observations of a large number of lensing systems with sufficient photometric and astrometric precision.Beyond the obvious sensitivity and resolution requirements, the key issues with laser guide star AO will be sky coverage (to maximize targets) and the ability to reconstruct the point spread function (PSF) well enough to achieve the desired precision and accuracy.
In this paper, we investigate the performance of current and future laser guide star adaptive optics systems, by carrying out detailed simulations of flux and astrometric anomalies as measured from integral field spectroscopy of lensed narrow emission lines.Even though there is no hard threshold and every improvement in precision helps, it is clear based on Gilman et al. (2019) that percent level photometry is needed and that milliarcsecond (mas) level astrometry is needed to make significant progress over what we know so far, for large numbers of systems.Therefore we set as our target requirements 2% total error in flux ratio photometry, and mas total error in astrometry, and show that they are attainable.We also discuss the total amount of exposure time required per system to give a rough estimate of the total amount of time required to investigate certain dark matter models, even though in practice this will depend on the distribution of fluxes of the actual lenses to be observed.
In Section 2 we detail the instruments considered, their PSFs.In Section 3 we describe how we model the quadruply imaged systems, and the simulation cases considered.Section 4 goes over our inference methodology and pipeline.We present our results in Section 5.

OBSERVATORY CHARACTERISTICS
One of our goals is to compare the expected performance of future instrument and adaptive optics systems with current facilities.For this purpose, in this section, we start with an overview of state of the art and upcoming cutting-edge adaptive-optics system, at the Keck Telescope and the Thirty Meter Telescope(TMT), that we take as illustrative of 8-10 and 30m class capabilities.We also describe our models for the point spread functions and expected noise levels.

Instruments and Adaptive Optics Systems
Here we provide details of the systems we are comparing/simulating.Table 1 compiles the key features of the systems.
Keck OSIRIS/Current AO Current dark matter flux ratio measurements are performed with the LGSAO system (Wizinowich et al. 2006) and the OSIRIS spectrograph (Larkin et al. 2006).LGSAO/OSIRIS observations are the baseline with which we will compare the future facilities.
Keck OSIRIS/KAPA Keck's current AO system is currently being upgraded to the Keck All-sky Precision Adaptive-optics (KAPA, Wizinowich et al. 2020), which will have an enhanced Strehl and sky coverage.
Keck LIGER/KAPA The existing OSIRIS spectrograph is planned to be upgraded to the LIGER spectrograph (Wright et al. 2019).LIGER will have 4 times the pixels of OSIRIS, a reduced pixel size, and a lower detector dark current and readout noise, improving resolution and sensitivity.
TMT IRIS/NFIRAOS At first light, TMT will feature NFIRAOS, an advanced AO system designed for its larger aperture (Crane et al. 2018).TMT will use IRIS (Wright et al. 2016), which is similar to LIGER in design, technology, and performance.

Point Spread Functions
The astrometric quality of images is fundamentally constrained by two main factors: the diffraction by the telescope and its optics, represented by a diffraction point spread function (PSF), and the blurring effect of turbulence in the Earth's atmosphere, represented by the seeing PSF2 .The total PSF, which describes the response of the imaging system as a whole, is a combination of these two components.
The efficacy of an imaging system can be quantitatively assessed using the Strehl ratio; a metric that compares the peak intensity of the seeing-aberrated point-source image to that of the ideal diffractionlimited image.Within the context of the total PSF, the Strehl ratio serves as an empirical measure of the optical system's performance.It essentially quantifies how closely the real-world optical system approaches the theoretical performance of a perfect system under identical observing conditions.This is particularly pertinent in adaptive optics, where real-time adjustments are employed to mitigate atmospheric distortions, aiming to achieve near diffraction-limited observations.
We obtained the diffraction limited PSFs for KAPA (Keck) and NI-FARAOS (TMT) from private communications with their respective team members3 .
Our current Keck PSF model is obtained from an observation taken under typical seeing conditions with the OSIRIS spectrograph in Hbb with the 100 mas pixel scale.Even though this pixel scale undersamples the PSF, this configuration is the most typical for measuring flux ratios of gravitationally lensed quasars, owing to field of view and signal to noise ratio constraints.The measured PSF shown here is an inferred sub-sampled PSF created using lenstronomy (Birrer & Amara 2018a;Birrer et al. 2021).
Figure 1 depicts the diffraction-limited PSFs for the KAPA (Keck) and NFIRAOS (TMT) systems.Fig. 2 compares the total (diffraction, instrumental, and seeing) PSFs of Keck's current AO system, KAPA, and NFIRAOS, under typical conditions.Fig. 3 presents cross sections of the diffraction, seeing, and total simulated PSFs for KAPA and NFIRAOS, illustrating the contributions of the subcomponents.

Noise
The observed noise is a combination of instrument noise and sky/background noise.The sky/background noise is expected to be the same for all three facilities, while the instrument noise will vary based on the characteristics of the telescope and instrument.
The OSIRIS/LGSAO noise levels are taken directly from real observations in typical conditions.For Liger and IRIS, we simulate the noise as a combination of instrument noise and sky /background.The instrument noise is determined by the detector technical specifications (refer to Table 1), and the sky background based on the OSIRIS/LGSAO real observations after subtracting the estimated contribution of instrument level effects.For our noise calculations we assume 600 second exposure times, which is the exposure time used for OSIRIS/LGSAO observations of this kind of systems (Nierenberg et al. 2014b).Details for the noise calculations are described in Appendix A.

STRONG GRAVITATIONAL LENS SIMULATIONS
Here we describe how we generate the mock gravitational lensing systems for our analysis.We begin by describing the lensing configurations we choose.Then we describe how the different light components are modelled.Finally we describe the combination of lenses and instrumental setups that we simulate.
We consider three cases for gravitational quad systems, corresponding to the three most common configurations: a cross, a cusp, and a fold.We adopt as representatives of these classes the real systems modeled by Schmidt et al. (2023), ATLASJ2344-3056 (cross), J2205-3727 (cusp), J1131-4419 (Fold).Table 2.3 lists the parameters of the quads: image positions, magnitudes, and lens galaxy light profile.
In order to produce our estimate of astrometric and flux ratio precision and accuracy we start from "white light" images, obtained by integrating data based over the range corresponding to the restframe 4700 and 5100 Å.This range contains the strong H and [O iii] emission lines generally used for flux ratio anomalies, and that we expect will be the main workhorse to follow-up lenses discovered by LSST, Euclid, and Roman Oguri & Marshall (2010).We convert HST F160W band magnitudes measured by Schmidt et al. (2023) to predicted detector counts using the ratio of the observed magnitudes and OSIRIS detector counts for gravitational lenses observed by Nierenberg et al. (2024, in prep).
The quasar point sources are inserted directly into the images using the appropriate point spread function for the selected AO/instrument combination.
We test the effect of the deflector light on the accuracy of the inference by including the deflector for some of our mock systems.We model the deflector as an elliptical Sersic with equation given by: where  () is a normalization constant so that at the effective radius,  e , the profile includes half of the deflector's light. represents the Sérsic index,  1 and  2 are the angular coordinates aligned along the semi-major and semi-minor axis through the rotational PA  L = arctan ( 2 ,  1 ) of the light profile, and  L represents the corresponding axial ratio.See Appendix B1 for an explanation of how to convert these parameters to the definitions used withinlenstronomy.
Each of the three exemplar lens systems are simulated with every instrumental setup, with and without the light from the deflector, for a range of seeing values.During the inference, as discussed in the next section we consider two cases: a known PSF (from, e.g., telemetry and modeling) and an unknown PSF that needs to be reconstructed from the data.Table 3 summarizes the key properties of the simulated systems.Fig. 4 shows noiseless simulations of a cross, cusp and fold system as they would appear through the 4 observational configurations: Keck OSIRIS+current adaptive optics system, Keck OSIRIS with KAPA, Keck LIGER with KAPA, and TMT IRIS with NFIRAOS.B2 show the linear and log images with simulated noise.Fig. 5 shows the simulated cross system in the Keck OSIRIS+KAPA configurations for different values of the seeing FWHM.

INFERENCE METHODOLOGY
For real measurements of quadruply imaged quasars, the narrow-line flux ratios of the lensed quasar images are extracted in a two-step process, as described by Nierenberg et al. (2014b).First, the point spread function, image positions and deflector light (if present) are modelled in an integrated 'white-light' image integrated which is a combination of multiple wavelength frames, effectively creating a narrow-band observation.Next, the fluxes of the point sources are extracted as a function of wavelength, and the spectrum for each separate lensed quasar image is modelled to measure the [O 3] fluxes.
In our analysis, we are interested in the expected improvement in precision due to the higher resolution, sampling, and sensitivity of the next generation of adaptive optics and instruments with respect to the current state of the art.Therefore, we focus our simulated measurements on the white-light PSF and deflector light fitting.We estimate that a fractional improvement in our ability to measure these quantities relative to a current white light image will be reflected in the final expected improvement in the narrow-line flux ratio measurements.In absolute terms, while the astrometric uncertainties from the white light are the appropriate quantity to look at, the photometric uncertainties in the while light will be smaller than what is expected for the narrow lines.This is due to the lower signal to noise ratio of the narrow lines in comparison to the white light, and to the additional uncertainties arising from the process of separating the narrow line emission from the continuum and pseudocontinuum and from the wings of broad H.Based on current OSIRIS data (Nierenberg et al. 2024, in prep) we estimate that the uncertainties on the narrow line flux ratios are approximately three times larger than those on the white light flux ratios.Therefore, we apply this scaling when expressing our uncertainties in terms of narrow line flux ratios.In reality, this approximation should be considered a conservative estimate of the full improvement expected from IRIS and LIGER as these instruments will have higher resolution spectral sampling which will enable improved sky-line subtraction and spectral decomposition and therefore enhance the spectral fitting part of this measurement.
Our inference pipeline has the following steps: • Simulate the quad images with specific detector, AO system PSF, seeing and Strehl.
• Add noise corresponding to the specific detector and exposure time.
• Initialize the model parameters that will be used for the fitting, including the lensed images, the lens galaxy and the PSF.• Run a particle swarm optimizer (PSO) to find the best fitting model parameters.
• Use the results of the PSO to inform the initialization points for the Markov Chain Monte Carlo method used to sample the posterior for the parameters.
The PSF can either be passed as a known array to model, or inferred by the software through multiple PSF iterations before starting the Comparison of the astrometric and photometric performance for each observational setup, with known and unknown PSF and with or without the deflector surface brightness (ON or OFF).At the wavelength of the narrow emission lines, the deflector galaxy will typically be negligible.We include the case with the deflector galaxy surface brightness included to illustrate the performance in case of particularly weak quasar emission lines.The 2% and mas precision targets are virtually met in all cases, except for OSIRIS with unknown PSF and a bright deflector galaxy (ON).For TMT IRIS+NFIRAOS the statistical uncertainties are negligible for the simulated 600s observations, implying that a few minutes of observations will be sufficient for typical lensed quasars.The simulations shown here assumed aseeing of 0. ′′ 3 and Strehl of 0.5.PSO optimization, exploiting the built-in information provided by the four quasar images.For generality, we consider two cases.One in which the surface brightness of the main deflector galaxy is included and one in which it is excluded.The choices are meant to bracket reality.There are systems in which at the wavelength of interest, the deflector will not be bright enough to warrant modeling, while in certain systems it will be prominent and will need to be modeled.

RESULTS
Figure 6 compares the flux ratio and astrometric uncertainties as a function of seeing FWHM across the four lens configurations.
The relative errors in flux are below the threshold target of 2%.Similarly, astrometric precision is reliably within the milliarcsecond range, meeting the overall target.We note that these simulations are rather conservative, assuming a Strehl ratio of 0.3, which should be generally exceeded by future AO systems.Furthermore, both astrometric and photometric precision improve substantially going from the current system to the upcoming ones.Thus, with future facilities it will be possible to extract more information per lens and thus achieve higher sensitivity, e.g., to warm dark matter models than currently possible (Gilman et al. 2019).
In order to consider the effects of two additional non negligible sources of error, in Figure 7 we compare how the measurement precision is affected by the inclusion of the deflector light (i.e. when the narrow emission lines are comparable to the foreground continuum) and whether the PSF is known prior to the inference as a result or modeling the AO system, or whether it needs to be inferred from the data (denoted as 'ON' or 'OFF').
Again, the target precision is met virtually in every case, except for the one of unknown PSF and bright lens galaxy for OSIRIS + KAPA.Even in the most conservative case of unknown PSF, the statistical uncertainties obtained with TMT IRIS+NFIRAOS are very small for our adopted 600s exposures, indicating that much shorter exposure times will be sufficient, thus greatly enhancing survey speed.For example, in order to obtain the same uncertainties obtained with LIGER+KAPA in 600s, 84s are sufficient with IRIS+NFIRAOS.
Appendix Figs.C1 and C2 show the posteriors obtained from one the MCMC sampling of the OSIRIS+KAPA case.The posteriors are Gaussian, and the original flux ratios are recovered well.We note that our results can easily be scaled to predict the performance of similar instrumentation on the Giant Magellan Telescope (GMT).Since the mirror diameter is the main driver of the both astrometric and photometric precision, AO corrected instruments on GMT will achieve precision between Keck LIGER+KAPA configurations and TMT IRIS+NFIRAOS systems.

CONCLUSIONS
We simulated quadruply imaged quasars to estimated the performance in terms of astrometry and narrow line flux ratios of current and upcoming state-of-the-art adaptive optics+instrument system for ground telescopes.As an illustration we have considered the Keck Telescope( OSIRIS + KAPA, LIGER+KAPA), and the Thirty Meter Telescope (IRIS+NFIRAOS).We have shown that expected errors in flux ratio will be well below 2%, and that milliarcsecond precision will be achievable in terms of astrometry, even if the PSF needs to be reconstructed from the data.
With TMT IRIS+NFIRAOS exposure times of 1-2 minutes will be sufficient for the lenses simulated here, implying that it will be practical to characterize the large numbers of lensed quasars that will soon be discovered by the Euclid, Rubin, and Roman Telescopes, including the majority that will be significantly fainter than the ones known so far.(Pedregosa et al. 2012).Open AI's GPT4 was used to check for grammatical correctness of the phrasing.

Figure 1 .Figure 2 .Figure 3 .
Figure 1.Diffraction limited point-spread functions, displayed on a logarithmic scale for the KAPA adaptive optics system (left panel), and for the NFIRAOS adaptive optics system (right panel).The hexagonal pattern created by the mirror/telescope structure is apparent.

Figure 4 .-Figure 5 .
Figure 4. Simulations of a cross (upper row), cusp (middle row) and fold (bottom row) gravitational lens system as they would appear through the 4 different observatory configurations, without noise.From left to right in each row: OSIRIS/current AO, OSIRIS/KAPA, LIGER/KAPA, and IRIS/NFIRAOS.All simulations assume a seeing of 0. ′′ 3, while the Strehl is 0.3 Figure7.Comparison of the astrometric and photometric performance for each observational setup, with known and unknown PSF and with or without the deflector surface brightness (ON or OFF).At the wavelength of the narrow emission lines, the deflector galaxy will typically be negligible.We include the case with the deflector galaxy surface brightness included to illustrate the performance in case of particularly weak quasar emission lines.The 2% and mas precision targets are virtually met in all cases, except for OSIRIS with unknown PSF and a bright deflector galaxy (ON).For TMT IRIS+NFIRAOS the statistical uncertainties are negligible for the simulated 600s observations, implying that a few minutes of observations will be sufficient for typical lensed quasars.The simulations shown here assumed aseeing of 0. ′′ 3 and Strehl of 0.5.

Figure B1 .
Figure B1.Simulations of a cross, cusp and fold system as they would appear through the 4 different observatory configurations: OSIRIS+current adaptive optics system, OSIRIS with KAPA, LIGER with KAPA, and IRIS with NFIRAOS, with the noise levels corresponding to each system overlayed as well.

Figure C1 .
Figure C1.The posteriors for the flux and flux ratio image measurements for the OSIRIS+KAPA configuration, with a galaxy light profile fit, for a Strehl of 0.5 and seeing FWHM of 0. ′′ 3. The vertical green lines indicate the true values of the fluxes and flux ratios, respectively.The posterior is Gaussian and the original flux ratios are properly recovered.See Figs. 6, and 7 for more vizualizations of the errors.

Figure C2 .
Figure C2.The posteriors for MCMC parameters for the OSIRIS+KAPA configuration, with a galaxy light profile fit, for a Strehl of 0.5 and seeing FWHM of 0. ′′ 3. The first 6 parameters correspond to the lens light model and the last 8 to the positions of the images.

Table 1 .
Observational facilities (telescopes, detectors, and adaptive optics systems) considered in this work.The information is provided for the spectrometers (not imager) systems.

Table 2 .
Positions of the main deflector's light profile centroid and lensed QSO images; quasar image magnitudes in the AB system; model parameters for the lens mass distribution.

Table 3 .
Summary of the simulations carried out

"
(Millman & Aivazis 2011;1)suring the physical properties of darkmatter with strong gravitational lensing".IZ acknowledges this work was supported by the Natural Sciences and Engineering Research Council of Canada (NSERC), [funding reference #DIS-2022-568580].We thank Prof. Shelley Wright and Dr. Nils Rundquist for providing PSF configurations for KAPA and NFIRAOS, and for helpful discussions.This research made use of the lenstronomy package Birrer & Amara (2018b) to model the quad lensed systems, and the following software: the NASA Astrophysics Data System's Bibliographic Services (ADS), the color blindness palette by Martin Krzywinski and Jonathan Corum 4 , the Color Vision Deficiency PDF Viewer by Marie Chatfield 5 , Jupyter Notebook(Kluyver et al. 2016), Matplotlib(Hunter 2007), NumPy(van der Walt et al. 2011), Python(Millman & Aivazis 2011; Oliphant 2007), scikit-learn