title: Searching for Dark Matter with a Superconducting Qubit
authors: Akash V. Dixit Srivatsan Chakram Kevin He Ankur Agrawal Ravi K. Naik David I. Schuster Aaron Chou
text: 
  
  
  
  
  avdixit@uchicago.edu
  James Franck Institute, University of Chicago, Chicago, Illinois 60637, USA
  Department of Physics, University of Chicago, Chicago, Illinois 60637, USA
  Kavli Institute for Cosmological Physics, University of Chicago, Chicago, Illinois 60637, USA
  
  
  James Franck Institute, University of Chicago, Chicago, Illinois 60637, USA
  Department of Physics, University of Chicago, Chicago, Illinois 60637, USA
  Department of Physics and Astronomy, Rutgers University, Piscataway, New Jersey 08854, USA
  
  
  James Franck Institute, University of Chicago, Chicago, Illinois 60637, USA
  Department of Physics, University of Chicago, Chicago, Illinois 60637, USA
  
  
  James Franck Institute, University of Chicago, Chicago, Illinois 60637, USA
  Department of Physics, University of Chicago, Chicago, Illinois 60637, USA
  Kavli Institute for Cosmological Physics, University of Chicago, Chicago, Illinois 60637, USA
  
  
  Department of Physics, University of California Berkeley, California 94720, USA
  
  
  James Franck Institute, University of Chicago, Chicago, Illinois 60637, USA
  Department of Physics, University of Chicago, Chicago, Illinois 60637, USA
  Pritzker School of Molecular Engineering, University of Chicago, Chicago, Illinois 60637, USA
  
  
  Fermi National Accelerator Laboratory, Batavia, Illinois 60510, USA
  
  
  
    Detection mechanisms for low mass bosonic dark matter candidates, such the axion or hidden photon, leverage potential interactions with electromagnetic fields, whereby the dark matter (of unknown mass) on rare occasion converts into a single photon. Current dark matter searches operating at microwave frequencies use a resonant cavity to coherently accumulate the field sourced by the dark matter and a near standard quantum limited (SQL) linear amplifier to read out the cavity signal. To further increase sensitivity to the dark matter signal, sub-SQL detection techniques are required. Here we report the development of a novel microwave photon counting technique and a new exclusion limit on hidden photon dark matter. We operate a superconducting qubit to make repeated quantum non-demolition measurements of cavity photons and apply a hidden Markov model analysis to reduce the noise to 15.7 below the quantum limit, with overall detector performance limited by a residual background of real photons. With the present device, we perform a hidden photon search and constrain the kinetic mixing angle to ϵ≤ 1.68 × 10^-15 in a band around 6.011 (24.86) with an integration time of 8.33. This demonstrated noise reduction technique enables future dark matter searches to be sped up by a factor of 1300. By coupling a qubit to an arbitrary quantum sensor, more general sub-SQL metrology is possible with the techniques presented in this work.
  
  
  
  
   Searching for Dark Matter with a Superconducting Qubit
      Aaron Chou
      August, 2020
  ========================================================
  
  
  
  
  
  § INTRODUCTION
  
  The nature of dark matter is an enduring mystery of our universe. Observations of galaxy rotation curves, gravitational lensing, and the presence of structure in the cosmos all inform our understanding of dark matter, but provide little insight into its intrinsic properties <cit.>. Though the gravitational evidence for the existence of dark matter is extensive <cit.>, thus far, dark matter has evaded direct detection in terrestrial experiments. We are interested in testing the hypothesis that dark matter is composed of waves of low mass bosons, which due to their high galactic phase space density, arrive as coherent waves with macroscopic occupation number. Well known dark matter candidates include the axion and hidden sector photon, which both have compelling cosmological origin stories <cit.>.
  
  One method for detecting these dark matter waves exploits their interactions with the electromagnetic field <cit.>. A microwave cavity with resonance frequency tuned to the mass of the hypothetical particle is used to coherently accumulate the electromagnetic response (see Supplemental Material). On rare occasions, the dark matter deposits a single photon in the cavity.
  
  There are specified targets in the parameter space of coupling and dark matter mass in the case of the axion of quantum chromodynamics (QCD). The expected signal photon occupation number is ∼10^-2 for searches like the Axion Dark Matter eXperiment operating at 650 MHz <cit.>. However, for searches at higher frequencies, the microwave cavity volume must shrink to maintain the resonance condition. The signal photon rate scales with the volume of the cavity, making detection of smaller signals increasingly challenging at higher frequencies. For an axion search with the microwave cavity (6.011) used in the present work and given the experimental parameters in typical axion search experiments <cit.>, QCD axion models <cit.> predict a signal with mean photon number of n̅_axion∼10^-8-10^-5 per measurement. For hidden photons, the parameter space is less constrained, <cit.> and the mean photon number per measurement could be n̅_HP≤ 10^-1. Currently, these searches employ linear amplification operating near the standard quantum limit (SQL) <cit.> to read out the built up signal in the microwave cavity, where the noise variance is equivalent to fluctuations of an effective background of n̅_SQL = 1. At GHz frequencies and above, the noise inherent to quantum limited linear amplification overwhelms the signal, making the search untenable (n̅_SQL≫n̅_axion, n̅_HP).
  
  We use single photon resolving detectors to avoid quantum noise by measuring only field amplitude, resulting in insensitivity to the conjugate phase observable. The noise is then dominated by the Poisson fluctuations of the background counts and ultimately limited by the shot noise of the signal itself <cit.>. Superconducting nanowire single-photon detectors or photomultipier tubes can readily count infrared photons; however, these technologies are not well suited to detect single low energy microwave photons <cit.>. Here, we develop a detector that is sensitive in the microwave regime and has a low dark count probability commensurate with the small signal rates expected in a dark matter experiment.
  
  
  
  § QUBIT BASED PHOTON COUNTER
  
  In order to construct a single photon counter, we employ quantum non-demolition (QND) techniques pioneered in atomic physics <cit.>. To count photons, we utilize the interaction between a superconducting transmon qubit <cit.> and the field in a microwave cavity, as described by the Jaynes-Cummings Hamiltonian <cit.> in the dispersive limit (qubit-cavity coupling ≪ qubit, cavity detuning): ℋ/ħ = ω_c a^† a + 1/2ω_q σ_z + 2 χ a^† a 1/2σ_z. The Hamiltonian can be recast to elucidate a key feature: a photon number dependent frequency shift (2 χ) of the qubit transition (Fig. <ref>(b)).
  
  
      ℋ/ħ = ω_c a^† a + 1/2(ω_q + 2 χ a^† a) σ_z
  
  
  
  
  We use an interferometric Ramsey measurement of the qubit frequency to infer the cavity state <cit.>. Errors in the measurement occur due to qubit decay, dephasing, heating, cavity decay, and readout infidelity, introducing inefficiencies or worse, false positive detections. For contemporary transmon qubits, these errors occur with much greater probability (1-10%) than the appearance of a dark matter induced photon, resulting in a measurement that is limited by detector errors. The qubit-cavity interaction (2 χ a^† a 1/2σ_z) is composed solely of number operators and commutes with the bare Hamiltonian of the cavity (ω_c a^† a) and qubit (1/2ω_q σ_z). Thus, the cavity state collapses to a Fock state (|0⟩ or |1⟩ in the n̅≪1 limit) upon measurement, rather than being absorbed and destroyed <cit.>. Repeated measurements of the cavity photon number made via this QND operator enable us to devise a counting protocol, shown in Fig. <ref>(a), insensitive to errors in any individual measurement <cit.>. This provides exponential rejection of false positives with only a linear cost in measurement time.
  
  In this work, we use a device composed of a high quality factor (Q_s = 2.06 × 10^7) 3D cavity <cit.> used to accumulate and store the signal induced by the dark matter (storage, ω_s = 2 π×6.011), a superconducting transmon qubit (ω_q = 2 π×4.749), and a 3D cavity strongly coupled to a transmission line (Q_r = 1.5 × 10^4) used to quickly read out the state of qubit (readout, ω_r = 2 π×8.052) (Fig. <ref>(a)). We  mount the device to the base stage of a dilution refrigerator at 8.
  
  To count photons, we repeatedly map the cavity population onto the qubit state by performing a cavity number parity measurement with Ramsey interferometry, as depicted in Fig. <ref>(a). We place the qubit, initialized either in |g⟩ or |e⟩, in a superposition state 1/√(2) (|g⟩±|e⟩) with a π/2 pulse. The qubit state precesses at a rate of |2 χ| = 2 π×1.13 when there is one photon in the storage cavity due to the photon dependent qubit frequency shift. Waiting for a time t_p = π/|2 χ| results in the qubit state accumulating a π phase if there is one photon in the cavity. We project the qubit back onto the z-axis with a -π/2 pulse completing the mapping of the storage cavity photon number onto the qubit state. We then determine the qubit state using its standard dispersive coupling to the readout resonator. For weak cavity displacements (n̅≪ 1), this protocol functions as a qubit π pulse conditioned on the presence of a single cavity photon <cit.>. If there are zero photons in the cavity, the qubit remains in its initial state. If there is one photon in the cavity, the qubit state is flipped (|g⟩↔|e⟩). More generally, this protocol is sensitive to any cavity state with odd photon number population.
  
  
  
  § HIDDEN MARKOV MODEL ANALYSIS
  
  In order to account for all possible error mechanisms during the measurement protocol, we model the evolution of the cavity, qubit, and readout as a hidden Markov process where the cavity and qubit states are hidden variables that emit as a readout signal (see Fig. <ref>(b)). The Markov chain is characterized by the transition matrix (T) (Eqn. <ref>) that governs how the joint cavity, qubit hidden state s ∈ [|0g⟩, |0e⟩, |1g⟩, |1e⟩] evolve, and the emission matrix (E) (Eqn. <ref>) which determines the probability of a readout signal R ∈ [𝒢,ℰ] given a possible hidden state.
  
  
  
  The transition matrix captures the possible qubit (cavity) state changes. Qubit (cavity) relaxation |e⟩→|g⟩ (|1⟩→|0⟩) occurs with a probability P_eg^↓ = 1 - e^-t_m/T_1^q (P_10 = 1 - e^-t_m/T_1^s). The probability of spontaneous heating |g⟩→|e⟩ (|0⟩→|1⟩) of the qubit (cavity) towards its steady state population is given by P_ge^↑ = n̅_q [1 - e^-t_m/T_1^q] (P_01 = n̅_c [1 - e^-t_m/T_1^s]). n̅_c is set to zero in the model in order to penalize events in which a photon appears in the cavity after the measurement sequence has begun. This makes the detector insensitive to cavity heating events. Dephasing during the parity measurement occurs with probability P^ϕ = 1 - e^-t_p/T_2^q, leading to outcomes indistinguishable from qubit heating or decay. The transition matrix contains all qubit errors: P_ge = P_ge^↑ + P^ϕ and P_eg = P_eg^↓ + P^ϕ. P_gg, P_ee, P_00, and P_11 correspond to events where no error occurs, such that probabilities pairwise sum to unity (e.g. P_gg + P_ge = 1). These probabilities are calculated using independently measured qubit coherences (T_1^q = 108(18), T_2^q = 61(4)), cavity lifetime (T_1^s = 546(23)), qubit spurious excited state population (n̅_q = 5.1(3)× 10^-2), the length of the parity measurement (t_p = 380), and the time between parity measurements (t_m = 10) (see Supplemental Material for descriptions of experimental protocols used to determine these parameters <cit.>). The repetition rate of the experiment is constrained primarily by the readout time (3) and time for the readout resonator to relax back to the ground state.
  
  
      T =
          ccccc|0g⟩   |0e⟩   |1g⟩   |1e⟩
      [cccc]c
          P_00P_gg    P_00P_ge    P_01P_ge    P_01P_gg   |0g⟩
      
          P_00P_eg    P_00P_ee    P_01P_ee    P_01P_eg   |0e⟩
      
          P_10P_gg    P_10P_ge    P_11P_ge    P_11P_gg   |1g⟩
      
          P_10P_eg    P_10P_ee    P_11P_ee    P_11P_eg   |1e⟩
  
  
  The elements of the emission matrix are composed of the readout fidelities of the ground and excited states of the qubit (F_g𝒢 = 95.8(4), F_eℰ = 95.3(5)). Noise from the first stage cryogenic HEMT amplifier sets the readout fidelity.
  
  
      E = 1/2ccc𝒢   ℰ
      [cc]c
          F_g𝒢    F_gℰ   |0g⟩
      
          F_e𝒢    F_eℰ   |0e⟩
      
          F_g𝒢    F_gℰ   |1g⟩
      
          F_e𝒢    F_eℰ   |1e⟩
  
  
  Given a set of N+1 measured readout signals (R_0, R_1, ..., R_N), we reconstruct the initial cavity state probabilities P(n_0=0) and P(n_0=1) by using the backward algorithm (Eqn. <ref>) <cit.> and summing over all possible initial qubit states.
  
  
      P(n_0) = ∑_s_0 ∈ [|n_0,g⟩, |n_0,e⟩]∑_s_1 ... ∑_s_N    E_s_0,R_0 T_s_0,s_1 E_s_1,R_1
      
          ...     T_s_N-1,s_N E_s_N,R_N
  
  
  This reconstruction includes terms corresponding to all the possible processes that could occur. For example, a readout measurement of 𝒢 followed by ℰ could occur due the correct detection of a photon in the cavity (with probability P_11P_ggF_eℰ/2). Alternatively, this measurement could be produced by a qubit heating event (P_00P_geF_eℰ/2) or a readout error (P_00P_ggF_gℰ/2). Fig. <ref>(c) displays the measured readout signals and reconstructed initial cavity probabilities of two events. The top panels correspond to the absence of a cavity photon and the bottom panels indicate the presence of a photon.
  
  We apply a likelihood ratio test (λ =P(n_0=1)/P(n_0=0)) to the reconstructed cavity state probabilities to determine if the cavity contained zero or one photons. If the likelihood ratio is greater than (less than) a threshold, λ > λ_thresh (λ≤λ_thresh), we determine the cavity to contain one (zero) photon. The probability of a detector error induced false positive is therefore less than 1/λ_thresh+1. As the threshold for detection increases, so too does the number of repeated parity measurements needed to confirm the presence of a photon, exacting a cost to detection efficiency that is linear in the number of measurements. More importantly for the detection of rare events, false positives are exponentially suppressed with more repeated measurements, as evident in Fig. <ref>(c).
  
  
  
  § DETECTOR CHARACTERIZATION
  
  
  
  
  To characterize the detector, we populate the cavity by applying a weak drive (n̅≪ 1). We map out the relationship between the probability of injected and measured photons (Fig. <ref>(a)) by varying the injected mean photon population (n̅ = α^2), performing 30 repeated parity measurements, and applying λ_thresh to discriminate between one and zero photon events. We fit this relationship with the function n̅_meas = ηn̅_inj + δ. We obtain the efficiency of detection η = 0.409(55) and the false positive probability δ = 4.3(11)× 10^-4 at threshold λ_thresh = 10^5 with goodness of fit χ_fit^2 = 0.0048. 
  
  Fig. <ref>(b) shows the efficiency corrected false positive probability (δ/η) initial decrease for low likelihood thresholds λ_thresh, indicating a suppression of qubit and readout based false positives. Leveling off at larger thresholds indicates that the dominant source of false positives is no longer detector errors, but rather a background of real photons.
  
  False positives that occur when qubit errors are highly suppressed (at large λ_thresh) are due to a photon background in the storage cavity. In experiments with no photons injected into the cavity, we observe events with high likelihood ratios comparable with those seen in experiments with injected photons (Fig. <ref>(c)). The detector thus correctly identifies real photons which set the background for dark matter searches. We measure the background cavity occupation to be n̅_c = 7.3(29)× 10^-4, corresponding to a temperature of 39.9(22).
  
  Because the measured cavity photon temperature is greater than the physical 8 temperature of the device there must be coupling to extraneous baths. One contribution, arising from coupling to quasiparticles via qubit dressing of the cavity <cit.>, results in a photon population of n̅_c^q = 1.8(1)× 10^-4 (see Supplemental Material). Suppression of quasiparticle production could be achieved by enhanced infrared filtering, extensive radiation shielding, gap engineering, and quasiparticle trapping <cit.>. Other sources of background photons could include blackbody radiation from higher temperature stages of the dilution refrigerator, poorly thermalized or insufficiently attenuated microwave lines, or amplifier noise <cit.>.
  
  
  
  § HIDDEN PHOTON DARK MATTER EXCLUSION
  
  By counting photons with repeated parity measurements and applying a Markov model based analysis, we demonstrate single photon detection with background shot noise reduced to -10 log_10√(n̅_c) = 15.7(9) below the quantum limit. We use this detection technique to conduct a narrow band hidden photon search. We collect 15,141 independent measurements where the injected n̅ is well below the background population n̅_c and the time between measurements is much longer than either cavity or qubit timescale. Each measurement consists of integrating the signal (for the cavity lifetime, T_1^s = 546) and counting the number of photons in the cavity with 30 repeated parity measurements (30 × t_m =  300). The total search time is 15,141 × (546 + 300)  = 12.81 with a duty cycle of 546 μ s/846 μ s = 65% (8.33 of integration). We apply a detection threshold of λ_thresh = 10^5, such that the qubit and readout errors are suppressed below the background photon probability (1/λ_thresh+1 < n̅_c). We count 9 photons in 15,141 measurements. Accounting for the systematic uncertainties of the experiment (statistical uncertainties are dominant, see Supplemental Material for full treatment of all systematics <cit.>), a hidden photon candidate on resonance with the storage cavity (m_γ ' c^2 = ħω_s), with mixing angle ϵ > 1.68 × 10^-15 is excluded at the 90% confidence level. Fig. <ref> shows the regions of hidden photon parameter space excluded by the qubit based search, assuming the hidden photon comprises all the dark matter density (ρ_DM = 0.4 / ^3). The detector is maximally sensitive to dark matter candidates with masses within a narrow window around the resonance frequency of the cavity. This window is set by the lineshape of the dark matter <cit.> (Q_DM∼ 10^6) such that the sensitivity falls to half the maximum (-3dB point) 3 away from the cavity resonance. Additionally, sensitivity to off resonant candidates occurs in regions where the photon number dependent qubit shift is an odd multiple of the dispersive shift 2χ (see Supplemental Material for calculation of hidden photon constraints <cit.>).
  
  
  
  
  
  § CONCLUSIONS
  
  Photon number measurements allow us to gain unprecedented sensitivity to dark matter signals. The single photon counting protocol demonstrated in this work results in a 15.7 metrological gain, relative to the SQL. This improvement is currently limited by background photons n̅_c = 7.3× 10^-4 whose suppression by improved filtering and shielding will further increase detector sensitivity.
  
  In a full scale dark matter search, where the cavity is tuned to scan a wide range of dark matter masses, it is possible to estimate and subtract the background population of the cavity. The standard technique is to measure the photon population as the cavity is tuned to neighboring cavity frequencies separated by more than the dark matter linewidth. The signal hypothesis can be tested by repeating the experiment with an auxiliary cavity of the same frequency as the detection cavity, but with poor coupling to the dark matter.
  
  The integration time required for a background limited dark matter search is determined by the signal rate (R_s = n̅_DM/T_1^s) and background rate (R_b = n̅_c/T_1^s) : R_s t > √(R_b t). The signal integration time scales with the background photon probability: t > n̅_c T_1^s/n̅^2_DM. The photon detection technique developed in this work constitutes a n̅_SQL/n̅_c ∼ 1300 times speed up of dark matter searches, relative to a linear quantum limited amplifier.
  
  This unprecedented sensitivity enables future cavity based searches for axions and hidden photons in the 3-30 GHz range. At lower frequencies, thermal backgrounds will dominate and at higher frequencies near the aluminium Josephson junction plasma frequency, qubit losses will degrade the measurement. A fixed frequency qubit can be coupled to a tunable cavity to scan over a dark matter mass range of order 𝒪(GHz), limited by the tuning range of the cavity. As long as the photon number dependent shift 2χ is resolvable and the qubit and cavity are sufficiently detuned at each tuning, the QND counting protocol can be harnessed to perform a search with sub-SQL noise. A nonlinear element made of higher T_c superconductor, such as tantalum <cit.>, niobium, or titanium nitride, could be used to access frequencies beyond 30 (see Supplemental Material for more information about future dark matter searches <cit.>).
  
  High fidelity non destructive photon counting can be utilized for accurate primary thermometry in low temperature microwave systems. This technique is applicable to quantum computing architectures which utilize long lived storage cavities <cit.>. Assessing the residual cavity population independently of the qubit errors allows for both single shot and real time monitoring of the storage cavity, crucial when preparing states whose fidelity is sensitive to the initial conditions.
  
  In this work, we demonstrate a state of the art photon counter for dark matter sensing. More generally, this technique of performing many QND measurements within a mode resolution time can be used more to perform sub-SQL metrology in other quantum sensing applications.
  
  
  
  § ACKNOWLEDGEMENTS
  
  We thank N. Earnest, A. Oriani, and C. Hann for discussions. We gratefully acknowledge the support provided by the Heising-Simons Foundation. This work made use of the Pritzker Nanofabrication Facility of the Institute for Molecular Engineering at the University of Chicago, which receives support from Soft and Hybrid Nanotechnology Experimental (SHyNE) Resource (NSF ECCS-1542205), a node of the National Science Foundation’s National Nanotechnology Coordinated Infrastructure. This manuscript has been authored by Fermi Research Alliance, LLC under Contract No. DE-AC02-07CH11359 with the U.S. Department of Energy, Office of Science, Office of High Energy Physics, with support from its QuantISED program. We acknowledge support from the Samsung Advanced Institute of Technology Global Research Partnership.
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
      
  
      Searching for Dark Matter with a Superconducting Qubit
      
  
      Supplemental Material
      
  
      Akash V. Dixit, Srivatsan Chakram, Kevin He, Ankur Agrawal, Ravi K. Naik, 
   David I. Schuster, Aaron Chou
      
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  § DARK MATTER INDUCED SIGNAL
  
  We use the potential interaction of the dark matter with electromagnetism as the basis for a search protocol. The dark matter candidate forms an effective oscillating current density that sources Maxwell's equations. Via Faraday's law, the electric field of a microwave cavity is sourced by the effective current formed by the dark matter ∇×B -∂E/∂ t = j_DM. For axions, the effective current density is j_axion = g_a γγ√(2 ρ)B_0 e^i m_a t, where g_a γγ is the predicted coupling of the axion field to electromagnetism, ρ is the local dark matter density, B_0 is a DC magnetic field applied in the laboratory, and m_a is the mass of the axion. For hidden photons, the effective current is j_HP = ϵ m_γ'√(2ρ) e^i m_γ' tû, where ϵ is a postulated kinetic angle of mixing between standard electromagnetism and hidden sector electromagnetism, û is the polarization of the hidden photon field, and m_γ' is the hidden photon mass. A microwave cavity tuned to the hypothetical mass of the dark matter candidate is used to accumulate the signal before it is read out.
  
  
  
  § FLUTE CAVITY FABRICATION
  
  The cavities used in this work are fabricated from high purity (99.9999%) Aluminium using a novel flute method illustrated in Fig. <ref>. This technique involves drilling offset holes from the top and bottom of the stock material, with a region of overlap defining the cavity volume <cit.>. Making the cavity from a monolithic piece of Aluminium eliminates seam loss by design <cit.> and results in a high quality factor. The full device consists of two microwave cavities each coupled to the transmon qubit. One cavity has a long lived storage mode and the other is strongly coupled to the line to perform qubit readout.
  
  
  
  
  
  § TRANSMON QUBIT FABRICATION
  
  The transmon qubits were fabricated on 430 thick C-plane (0001) Sapphire wafers with a diameter of 50.8. Wafers were cleaned with organic solvents (Toluene, Acetone, Methanol, Isopropanol, and DI water) in an ultrasonic bath to remove contamination, then were annealed at 1200 for 1.5 hours. Prior to film deposition, wafers underwent a second clean with organic solvents (Toluene, Acetone, Methanol, Isopropanol, and DI water) in an ultrasonic bath.  The base layer of the device, which includes the capacitor pads for the transmon, consists of 75 of Nb deposited via electron-beam evaporation at 1 /. The features were defined via optical lithography using AZ MiR 703 photoresist, and exposure with a Heidleberg MLA150 Direct Writer. The resist was developed for 1 minute in AZ MIF 300 1:1. The features were etched in a Plasma-Therm inductively coupled plasma (ICP) etcher using fluorine based ICP etch chemistry with a plasma consisting of 15 sccm SF_6, 40 sccm CHF_3, and 10 sccm Ar. The junction mask was defined via electron-beam lithography of a bi-layer resist (MMA-PMMA) in the Manhattan pattern using a Raith EBPG5000 Plus E-Beam Writer, with overlap pads for direct galvanic contact to the optically defined capacitors. The resist stack was developed for 1.5 minutes in a solution of 3 parts IPA and 1 part DI water. Before deposition, the overlap regions on the pre-deposited capacitors were milled in-situ with an Argon ion mill to remove the native oxide. The junctions were then deposited with a three step electron-beam evaporation and oxidation process. First, an initial 35 layer of aluminium was deposited at 1 / at an angle of 29 relative to the normal of the substrate, parallel azimuthally to one of the fingers in the Manhattan pattern for each of the junctions. Next, the junctions were exposed to 20 of a high-purity mixture of Ar and O_2 (ratio of 80:20) for 12 minutes for the first layer to grow a native oxide. Finally, a second 120 layer of aluminium was deposited at 1 / at the same angle relative to the normal of the substrate, but orthogonal azimuthally to the first layer of aluminium. After evaporation, the remaining resist was removed via liftoff in N-Methyl-2-pyrrolidone (NMP) at 80 for 3 hours, leaving only the junctions directly connected to the base layer. After both the evaporation and liftoff, the device was exposed to an ion-producing fan for 15 minutes, in order to avoid electrostatic discharge of the junctions. The room temperature DC resistance of the Josephson junction on each qubit was measured to select the qubit which corresponds to the target Josephson energy <cit.> (E_J).
  
  
  
  § EXPERIMENTAL SETUP
  
  The cavities and qubit are mounted to the base plate of a dilution fridge (Bluefors LD400) operating at 8. The device is potted in a block of infrared (IR) absorbant material (eccosorb CR-110) to absorb stray radiation and housed in two layers of μ-metal to shield from magnetic fields. Signals sent to the device are attenuated and thermalized at each temperature stage of the cryostat as shown in Fig. <ref>. The field probing the readout resonator is injected via the weakly coupled port (shorter dipole stub antenna). Control pulses for qubit, storage cavity, and sideband operation are inserted through the strongly coupled readout port (longer dipole stub antenna). This line includes a cryogenic microwave attenuator thermalized to the base stage (Courtesy of B. Palmer) and a weak eccosorb (IR filter). Both control lines also contain an inline copper coated XMA attenuator that is threaded to the base state. The signal from the readout resonator reflects off a Josephson parametric amplifier (not used in this work) before being amplified by a cryogenic HEMT amplifier at the 4 stage. The output is mixed down to DC before being digitized.
  
  
  
  
  
  § CALIBRATION OF PARITY MEASUREMENT
  
  The cavity number parity measurement requires the calibration of the two qubit π/2 pulses as well as the delay between them. To set the π/2 pulse length, we perform qubit Rabi oscillations between the |g⟩ and |e⟩ levels by driving at the qubit transition frequency. The population transfer is sinusoidal and can be fit to determine when the qubit population has inverted (π pulse). By turning on the drive for only half the time required to perform a π pulse gives us the needed π/2 pulse to put the qubit in a clock state (1/√(2) (|g⟩ + |e⟩)). The parity measurement is comprised of an initial π/2 pulse followed by a time delay of π/ |2χ| and a final -π/2 pulse (constructed by advancing the phase of the π/2 pulse by π).
  
  To calibrate the time delay used in the parity measurement, we perform two Ramsey interferometry experiments on the qubit either in the absence or presence of a single photon in the cavity. We chose the Ramsey drive frequency to be on resonance with the qubit transition frequency. In the absence of the photon, the qubit superposition remains unchanged in the frame of the qubit. We use the |f0⟩-|g1⟩ sideband <cit.> to populate the cavity with a single photon. In the presence of the cavity photon, the qubit transition frequency is shifted by 2 χ relative to the Ramsey  frequency, consequently, the resulting fringe oscillates at a rate of 2 χ. The parity measurement delay time (t_p) is chosen such that the qubit superposition state has obtained a phase shift of π. This is also a calibration of the dispersive shift (|2 χ| = π/t_p).
  
  
  
  § DRIVE PULSE CALIBRATION
  
  By applying a weak coherent tone at the storage cavity frequency, we induce a variable displacement α of the cavity state. We calibrate the number of photons injected into the storage cavity by varying the drive amplitude and performing qubit spectroscopy. By fitting the qubit spectrum show in Fig. <ref> to a Poisson distribution, we extract the cavity occupation, n̅ = |α|^2.
  
  
  
  Nonlinearities of the signal generator result in a non trivial relationship between drive amplitude (at the software level) and the cavity occupation number. We map the transfer function that describes this relation and use it to apply calibrated cavity displacements (Fig. <ref>).
  
  
  
  
  
  
  
  § ELEMENTS OF HIDDEN MARKOV MODEL
  
  The hidden Markov model relies on independent measurements of the probabilities contained in the transition and emission matrices. The elements of these matricies depend on the parameters of the experiment and the device, including the lifetimes of the qubit and cavity, qubit spurious population, and readout fidelities.
  
  
  
   §.§ Transmission matrix elements
  
  The lifetime of the qubit is determined by applying a π pulse and waiting for a variable time before measuring the population. We map out the qubit population as a function of the delay time, fit it with an exponential characterizing the Poissonian nature of the decay process, and obtain T_1^q = 108(18).
  
  The dephasing time of the qubit is measured by a Ramsey interferometry experiment with a π/2 pulse, variable delay, and a final π/2 with its phase advanced by ω_r t where ω_r is the Ramsey frequency. During the variable delay period, a series of π pulses are applied to perform spin echos and reduce sensitivity to low frequency noise. We observe a dephasing time of T_2^q = 61(4).
  
  The storage cavity lifetime is calibrated by performing a cavity T_1 experiment. This is accomplished by applying a π_ge pulse and a π_ef to the transmon. This is followed by driving the |f0⟩-|g1⟩ transition, mediated by the Josephson nonliniearity for a time corresponding to a π pulse <cit.>. This populates the cavity with |n⟩=|1⟩ photons. After a variable time delay, the cavity population is swapped back into the qubit using the same π_|f0⟩-|g1⟩ pulse. Measuring the qubit population, we infer the cavity population as a function of the time delay. This is fit with a decaying exponential to obtain T_1^s = 546(23) (Fig. <ref>). To measure the cavity dephasing time, the cavity is initialized in a superposition state 1/√(2) (|0⟩ + |1⟩) by first applying a π_ge/2 pulse, a π_ef, followed by a π_|f0⟩-|g1⟩ pulse. A Ramsey measurement is performed to obtain a cavity dephasing time of T_2^s = 774(286).
  
  
  
  The qubit spurious population is determined by measuring the relative populations of its ground and excited states <cit.>. This is done by utilizing the f-level of the transmon. Two Rabi experiments are conducted swapping population between the |e⟩ and |f⟩ levels. First, we apply a π_ge pulse to invert the qubit population followed by the |e⟩-|f⟩ Rabi experiment. Second, no π_ge pulse is applied before the ef Rabi oscillation. The ratio of the amplitudes of the oscillations gives us the ratio of the populations of the excited and ground state. Assuming that P(g) + P(e) = 1 and measuring P(e)/P(g), we obtain P(g) = 0.949 and P(e) = 0.051, corresponding to an effective qubit temperature of 71.
  
  
  
   §.§ Emission matrix elements
  
  In order to characterize the emission matrix it is necessary to measure the readout infidelity of a particular transmon state. All the possible transmon states (|g⟩, |e⟩, |f⟩) are prepared (3000 independent experiments per state) and the resulting I,Q signals are digitized. The resulting distributions in I,Q space are used as a map to determine the probability that any readout signal is the result of transmon being in either |g⟩, |e⟩, or |f⟩. Based on the calculated probability, the state is assigned to either 𝒢, ℰ, or ℱ (Fig. <ref>).
  
  
  
  Readout errors are due to voltage excursions from amplifier noise or spurious qubit transitions. The emission matrix should only contain readout errors that occur due to voltage fluctuations. Errors due to qubit transitions during the readout window are accounted for in the transition matrix. To disentangle the two contributions the analysis is run with various contingencies, all resulting in the same detector false positive probability and efficiency, indicating that the Markov model is robust to small perturbations of the emission matrix when so heavily biased against false positives. In the most conservative case, the qubit errors are accounted for during the entire 10 window or each parity measurement. The readout infidelity is determined by finding how many errors are made (regardless of the source) during the 3 readout window (part of the 10 experiment time window). In this case qubit errors are counted twice during the readout window. In the second case, we consider qubit errors only for times when readout is not occurring (7 of the 10) and include all error channels in the readout infidelity. This avoids double counting of the qubit error during readout. The third case most closely aligns with the plausible physical model of errors during the readout window occurring due to a combination of qubit errors and amplifier noise. The readout infidelity is computed by subtracting the qubit error probabilities during the 3 readout window due to qubit decay (1-e^-3 / T_1^q) or heating (n̅_q[1-e^-3 / T_1^q]) from the total measured error during readout, leaving only readout errors due to voltage noise from amplifiers. This is the readout infidelity used to determine the elements of the emission matrix in the analysis.
  
  
  
  
  
  § DETECTOR CHARACTERIZATION
  
  To characterize the detector, the cavity population is varied by applying a weak drive and the cavity photon number is counted using the technique described in the main text. In order to extract the efficiency (η) and false positive probability (δ) of the detector, the relationship between injected photon population (n̅_inj) and measured photon population (n̅_meas) is fit to n̅_inj = η×n̅_meas + δ.
  
  
  
   §.§ Detector efficiency
  
  The detector efficiency and false positive probability is determined at varying thresholds for detection λ_thresh. As the detection threshold is increased, more parity measurements are required to determine the presence of a photon. This suppresses false positives due to qubit errors but also leads to a decrease in the detector efficiency as events with low likelihood ratio are now rejected (Fig. <ref>). For large thresholds where 1/λ_thresh+1 < δ, the qubit based errors are no longer the dominant source of detector errors. These errors occur due to the presence of a background of real photons whose population is given by the efficiency corrected false positive probability δ/η (shown in the main text).
  
  
  
  
  
   §.§ Analysis with cavity backgrounds
  
  In the initial application of the hidden Markov analysis, the cavity background population is set to zero to exclude the effects of cavity heating events during the measurement. We measure a background population of 7.3(29)× 10^-4 and then include n̅_c in the model to reanalyze the data. Now in addition to the possibility of a photon from injection or background initially occupying the cavity, we allow for both cavity heating during the measurement and qubit errors. The reconstructed false positive probability of the detector P(n=0) is set by the probability of a cavity heating event preceding the first parity measurement n̅_c × (1-e^-t_m/T_1^s) = 1.3 × 10^-5. Therefore, the maximum likelihood ratio of the reconstructed probabilities cannot exceed the cavity heating limit. By setting the detection threshold to λ_thresh = 2.0 × 10^4 and including cavity heating processes in the model, we measure the background population of the cavity to be 5.6(18)× 10^-4, which is consistent with the initial measurement of n̅_c = 7.3(29)× 10^-4. This reinforces our belief that repeated parity measurements successfully mitigate qubit based errors and that cavity background photons are the limiting process for photon detection.
  
  
  
  § SOURCES OF CAVITY BACKGROUNDS
  
  The measured photon background contains a contribution from spurious photons injected due to the cavity interaction with the qubit. To characterize the significance of the effect of converted qubit excitations, we recognize that cavity (|1̃⟩) and qubit (|ẽ⟩) excitations are dressed due to their interaction. In the dispersive limit, written in terms of the bare basis eigenstates (|e⟩, |1⟩), the dressed states are:
  
  
      |ẽ⟩   = sinθ|g,1⟩ + cosθ|e,0⟩
      |1̃⟩   = cosθ|g,1⟩ - sinθ|e,0⟩
  
  
  where θ is the mixing angle between the two systems. Qubit heating events from quasiparticle tunneling, in effect, prepare the system in the state |e,0⟩ = |ẽ⟩ - sinθ/cosθ|1̃⟩. The probability that the heating event manifests as a cavity excitation is (sinθ/cosθ)^2 = 3.5 × 10^-3. Therefore, the contribution of qubit heating events converted to cavity photons is determined by the probability that there is a qubit heating event and the probability that it is projected into a cavity excitation, n̅_c^q = n̅_q × (sinθ/cosθ)^2 = 1.8(1)× 10^-4.
  
  
  
  § CONVERTING CAVITY OCCUPATION LIMIT TO HIDDEN PHOTON EXCLUSION
  
  
  
  
   §.§ Kinetic mixing angle exclusion
  
  
  For a dark matter candidate on resonance with the cavity frequency (m_DM c^2 = ħω_c), the rate of photons deposited in the cavity by the coherent build up of electric field in one cavity coherence time is given by <cit.>:
  
  
      d N_HP/dt  = U/ω_s/T_1^s = 1/2E^2 V /ω_sω_s/Q_s = 1/2J^2_DM Q^2_DM/m^2Q_s/Q_DM G V 1/Q_s
  
  The cavity coherence time is given by T_1^s = Q_s/ω_s. The volume of the cavity is 0.953 × 3.48 ×3.56^3 =  11.8^3. 𝒢 encompasses the total geometric factor of the particular cavity used in the experiment. This includes a factor of 1/3 due to the dark matter field polarization being randomly oriented every coherence time. For the lowest order mode of the rectangular cavity coupled to the qubit with E = sin(π x/l) sin(π y/w)z the geometric form factor is given by:
  
  
      G = 1/3| ∫ dV E_z |^2/V ∫ dV | E_z |^2 = 1/32^6/π^4
  
  
  Since the cavity decay and dephasing times (T_1^s and T_2^s) are longer than the dark matter coherence (Q_DM = 10^6), the cavity is displaced Q_s/Q_DM times with a random phase each dark matter coherence time. The cavity field displacement follows a random walk, leading to an signal amplitude enhancement by a factor of √(Q_s/Q_DM).
  
  The hidden photon generated current is set by the density of dark matter in the galaxy ρ_DM = 0.4 / ^3 = 2π×9.67e19 / ^3:
  
  
      J^2_DM = 2ϵ^2 m^4 A'^2 = 2ϵ^2 m^2 ρ_DM
  
  
  Substituting Eqn. <ref> into Eqn. <ref> yields the signal rate of photons deposited in the cavity by a hidden photon dark matter candidate:
  
  
      d N_HP/dt = ϵ^2 ρ_DM Q_DM G V
  
  
  The total number of photons we expect to be deposited is determined by the photon rate and the integration time (T_1^s × N_meas = 8.33):
  
  
      N_HP = d N_HP/dt× T_1^s × N_meas = ϵ^2 ρ_DM Q_DM Q_s G V N_meas/ω_s
  
  
  
  
   §.§ Calculating 90% confidence limit
  
  
  
  By counting single photons when the applied drive population less than the background population (n̅_c) we perform a hidden photon search. We count N = 9 background photons in N_meas = 15,141 measurements. We determine the hidden photon mixing angle ϵ that can be excluded at the 90% confidence level by computing the probability that the signal could result in less than or equal to  9 photons measured (N ≤ 9) with less than 10% probability. In each measurement a photon is counted or not so the signal is described by a binomial distribution with probability set by the expected number of deposited photons as calculated in Eqn. <ref>. The systematic uncertainties of the various experimentally determined quantities in Eqn. <ref> are treated as nuisance parameters <cit.> with an assumed Gaussian distribution of mean Θ and standard deviation σ_Θ as shown in Table <ref>. We marginalize over the nuisance parameters <cit.> and compute the cumulative probability shown in Eqn. <ref>.
  
  
      P(≤ N) = ∫_0^∞   ∏_i dΘ_i' e^-(Θ_i-Θ_i')^2/2σ_Θ_i^2/√(2 π)σ_Θ_i∑_k=0^NN_meas!/k! (N_meas-k)!
         ×( η' ϵ^2 ρ_DM Q_DM Q_s' G' V'/ω_s') ^k
         ×(1- η' ϵ^2 ρ_DM Q_DM Q_s' G' V'/ω_s')^N_meas - k
  
  
  For a given hidden photon candidate, a cumulative probability of < 0.1 implies that candidate has less than 10% chance of producing the observed signal, thereby excluding such a candidate with 90% confidence. This leads us to exclude, with 90% confidence, hidden photon candidates with ϵ^90% > 1.68 × 10^-15 as seen in Fig. <ref>
  
  
  
  
  
  
  § HIDDEN PHOTON PARAMETER SPACE EXCLUSION
  
  Single photon counting with repeated parity measurements is sensitive to a wide range of candidates in the parameter space of hidden photon mass (m_γ ') and kinetic mixing angle (ϵ). To determine the sensitivity of the detector to a particular candidate, there are two considerations: the photon number dependent shift of the qubit transition as a function of the hidden photon mass, and the probability that a candidate would result in the measurement of a photon with probability larger than excluded. The photon population excluded as the 90% confidence level is computed using the excluded mixing angle ϵ^90% and Eqn. <ref> as n̅_HP^90% = N_HP^90%/N_meas = 2.42 × 10^-3.
  
  The photon dependent shift of the qubit transition as a function of the frequency of an external drive is determined in Gambetta et. al. <cit.> to be 2χ + ω_c - ω_γ ' where ħω_γ ' = m_γ ' c^2. The efficiency of an individual parity measurement for a photon dependent shift that is incommensurate with the nominal shift 2χ is given by η_parity = |1/2(e^i π(2χ + ω_c - ω_γ ')/2χ-1)|^2 (Fig. <ref>). The effect of an inefficient parity measurement is modeled as a higher probability of qubit error in the hidden Markov model. The data is then reanalyzed and the efficiency of detection in the presence of the additional error is extracted (Fig. <ref>).
  
  
  
  We note that for large detunings of the external drive, the shifted qubit transition frequency is out of the band of the π/2 pulses used in the parity measurement. The pulse shapes are Gaussian with σ = 6. This constrains the maximum addressable dark matter detuning from the cavity.
  
  A hidden photon candidate that could result in more detector counts than background counts is only possible if the population of the odd number states of the cavity state (P_odd) induced by the hidden photon is larger than the excluded hidden photon probability (n̅_HP^90%). To calculate this P_odd we again follow Gambetta et. al. <cit.>.
  
  
      P_odd = 1/π∑_k=0^∞Re( 1/(2k+1)! (-A)^2k+1 e^A/2(2 π/T_2^q, echo + Γ_m) + (2k+1) 2π/T_1^c)
  
  
  where A = D π/T_1^c - iχ - i (ω_c-ω_γ ')/π/T_1^c + iχ + i (ω_c-ω_γ ') and Γ_m = D π/T_1^c with the distinguishability D = 2(n_- + n_+)χ^2/(π/T_1^c)^2 + χ^2 + (ω_c-ω_γ ')^2. n_- and n_+ are related to the drive strength (n_drive) in units of photons: n_± = n_drive (π/T_1^c)^2 /(π/T_1^c)^2 + (ω_c-ω_γ '±χ)^2. At a given hidden photon mass, we calculate all n_drive such that P_odd≥n̅_HP^90%.
  
  We note that for external drives with large amplitudes, the shifted qubit transition frequency will be out of the band of the σ = 6 Gaussian π/2 pulses used in the parity measurement. This constrains the maximum addressable dark matter induced photon occupation. 
  
  
  By combining the detector efficiency with the n_drive such that P_odd≥n̅_HP^90%, we determine all n_drive to which the repeated parity measurements are sensitive enough to detect and exclude (Fig. <ref>). Using Eqn. <ref> we convert the excluded n_drive to a region of excluded hidden photon mixing angle (ϵ).
  
  
  
  The above calculations assume an infinitely narrow dark matter line. To obtain the excluded region of the hidden photon kinetic mixing angle, we must account for the lineshape of the dark matter <cit.>. We convolve the dark matter lineshape, characterized by Q_DM∼ 10^6, with the region shown in Fig. <ref> to obtain the excluded ϵ shown in the main text.
  
  We note that the storage cavity contains an infinite set of discrete resonances each with a unique coupling to the dark matter. We focus only on the lowest order mode that is specifically designed to couple to the qubit. In principle, the interactions between any modes and the dark matter could result in additional sensitivity to the hidden photon. This would require the mode of interest to have a sufficiently large geometric form factor as well as a resolvable photon number dependent qubit shift. Future dark matter searches could employ structures with multiple resonances to enable multiple simultaneous searches <cit.>.
  
  
  
  § FUTURE DARK MATTER SEARCH
  
  In order to implement a full scale axion search, the photon counting device must be coupled to a microwave cavity bathed in a magnetic field that accumulates the axion deposited signal. To extract the signal, a nonlinear element such as a Josephson parametric converter can be used to transfer the signal photon from the accumulation cavity to the storage cavity <cit.>. When the accumulation cavity frequency is tuned to search for a different axion mass, the converter can be pumped at appropriate frequency to enable photon transfer. The storage cavity and qubit can remain fixed in frequency, which leaves the photon detection protocol unchanged at each tuning. Although novel cavity techniques to achieve high Q in the presence of magnetic fields have been demonstrated <cit.>, in the most pessimistic scenario the accumulation cavity will be made of copper and limited to a Q ∼ 10^4 at 10 due to the anomalous skin effect. This sets the accumulation time to ∼1. To minimize the dead time of the experiment, the time required to measure the storage cavity should ideally be matched to that of a copper accumulation cavity lifetime. Reaching the required detector error probability in this limited time will be challenging. In this work, each parity measurement requires 10 because of the large readout signal necessary to overcome the HEMT amplifier noise. We perform 30 repeated measurements in order to reduce the probability of detector errors to a level below the expected signal photon probability for dark matter (n̅_axion∼ 10^-8). Readout of a superconducting qubit with >99% fidelity in 100 has been achieved by using quantum limited parametric amplifiers <cit.> and appropriate pulse shaping <cit.>. Both techniques can be applied to this protocol to significantly increase the measurement rate and readout fidelity.
  
  For a hidden photon search, a magnetic field is not required. As demonstrated in this work, the accumulation and storage cavity can be the same device. When the cavity is tuned to search through the parameter space, as long as a sufficiently large dispersive shift to the accumulation/storage is maintained and the qubit is still far detuned, the fundamental QND interaction between the qubit and photon is maintained. Additionally, by using extremely high Q cavities (Q ≫ Q_DM) to sample the dark matter energy distribution once or twice per dark matter linewidth, only Q_DM∼ 10^6 cavity frequency tunings are required to test each mass hypothesis in a frequency octave.
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  