{'fraction_non_alphanumeric': 0.038735355120802735, 'fraction_numerical': 0.009950109311060037, 'mean_word_length': 4.105022177707826, 'pattern_counts': {'":': 0, '<': 1, '<?xml version=': 0, '>': 1, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
High-efficiency resonant amplification of weak magnetic fields for single spin magnetometry

We demonstrate theoretically that by placing a ferromagnetic particle between a nitrogen-vacancy (NV) magnetometer and a target spin, the magnetometer sensitivity is increased dramatically. Specifically, using materials and techniques already experimentally available, we find that by taking advantage of the ferromagnetic resonance the minimum magnetic moment that can be measured is smaller by four orders of magnitude in comparison to current state-of-the-art magnetometers. As such, our proposed setup is sensitive enough to detect a single nuclear spin at a distance of $30$~nm from the surface within less than one second of data acquisition at room temperature. Our proposal opens the door for nanoscale NMR on biological material under ambient conditions.


I. INTRODUCTION
Magnetic resonance techniques not only provide powerful imaging tools that have revolutionized medicine, but they have a wide spectrum of applications in other fields of science like biology, chemistry, neuroscience, and physics. 1,2 In order to resolve structures on the nanometer scale and thus image individual molecules, however, one needs to go beyond conventional magnetometric techniques. In particular, standard nuclear magnetic resonance (NMR) and magnetic resonance imaging (MRI) experiments detect magnetic fields through the current induced inside a coil according to Faraday's law; unfortunately induction-based detection is not sensitive enough to allow resolution in the sub-micrometer regime. 3 Over the last years, a lot of experimental effort has been put into improving magnetic detection schemes. At present, Hall-sensors and SQUID sensors are among the most sensitive magnetic field detectors. 4,5 Furthermore, a great deal of success has been achieved with magnetic resonance force microscopy, where the force between a magnetic tip and the magnetic moment under investigation is exploited to detect single electron-spins, achieving a resolution of a few cubic nanometers. [6][7][8] On the other hand, the very low temperatures that are required in such schemes represent a considerable drawback to imaging systems in many biological environments.
NV-center spins also provide very good candidates for magnetometry, boosting sensitivities up to a few nT/ √ Hz at room temperature 9-14 and sub-nanometer spatial resolution, permitting three-dimensional imaging of nanostructures. 10 These results are realizable due to the amazingly long decoherence times of NV-centers at room temperature and the ability to noninvasively engineer an NV-magnetometer very close to the magnetic sample. Although impressive, current state-of-the-art technology 15 is unable to detect a single nuclear spin; achieving such sensitivity would revolutionize magnetic imaging in chemical and biological systems by facilitat-ing atomic resolution of molecules.
In this work, we propose an experimental realization of NV-magnetometers which could increase present NVcenter sensitivities by four orders magnitude at room temperature; this unprecedented amplification of sensitivity forecasts magnetometers capable of detecting individual nuclear spins. This can be achieved by introducing a ferromagnetic particle between the spin that needs to be detected, which henceforth we call a qubit, 16 and the NV-magnetometer. When excited on resonance by the driven qubit, the macroscopic ferromagnetic spin begins to precess which, in turn, amplifies the magnetic field felt by the NV-center. By resonantly addressing the qubit and using a ferromagnetic resonator as a lever, our setup, in contrast to existing schemes, is particularly advantageous because, due to the large amplification of sensitivity, the nuclear spin need not lie within a few nanometers of the surface 17 but rather can be detectable at a distance of 30 nm, and, while related existing schemes rely on the quantum nature of a mediator spin, 18 our proposal is fully classical. With these novelties, our scheme provides chemically sensitive spin detection.

II. SETUP
The standard experimental setup, yielding the most accurate NV-magnetometers (e.g. Ref. 10), consists of an NV-center near the target qubit and two distinct microwave sources that independently control the NV-center and qubit so that double electron-electron (electron-nuclear) resonance, DEER (DENR), can be performed.
We extend this setup by including a macrospin ferromagnetic particle (FM) between the NVmagnetometer and the qubit we want to measure, see Fig. 1. Due to the presence of the FM stray field, the qubit energy-splitting, and therefore the frequency (ω s ) at which the qubit responds resonantly, is strongly modified; one needs first to characterize the FM stray field in order to be able to control the qubit by, in our case, applying π-pulses. 19 Treating the ferromagnet as a single classical spin, the Hamiltonian of this system is 20,21 where m is the normalized magnetization of the FM, M F the saturation magnetization of the FM, and V its volume. We assume uniaxial anisotropy in the FM with the anisotropy constant, K > 0, composed of both shape and crystalline anisotropy, with an easy axis along z. An external magnetic field b is applied along the z axis. The magnetic moment of the qubit is µ s and n s (t) is its polarization at time t.
is the stray field produced by the FM at the position of the qubit, r s , when the FM is polarized along the j-axis for j = x, y, or z. The Hamiltonian of the qubit is not explicitly written as its polarization is completely determined by the applied time-dependent microwave field and the stray field of the FM. For example, in equilibrium the ground state of the qubit is polarized along the FM stray field n and the externally applied magnetic field is small, |b| |B z F |. Although in the following we take V small enough to approximate the FM as a monodomain, our analysis and therefore our results are amenable to including the effects of magnetic texture.
Using two independent microwave sources we apply a train of π-pulses first to the qubit and subsequently a Carr-Purcell-Meiboom-Gill (CPMG) pulse sequence 22,23 to the NV-center, see Fig. 2. As the qubit is pulsed it will drive the FM at the frequency of the pulse sequence π/τ , τ being the time between the application of two subsequent π-pulses. When π/τ is close to the ferromagnetic resonance (FMR) frequency, ω F , the response of the FM becomes large and one obtains a large amplification of the magnetic field felt by the NV-center. The pulses are applied to the qubit only until the FM reaches steady state precession. We also allow for a possible time offset, ξ, between the pulse sequences applied to the qubit and the NV-center, see Fig. 2. Here, ξ may be chosen to compensate for the phase difference between the driving of the qubit and the response of the FM, thus maximizing the amplification. Since the microwave field applied to the qubit is a sequence of π-pulses, the polarization is simply n s (t) = n s f τ (t), where f τ (t) may take the values ±1 according to the pulse sequence. It is worth noting that even though we excite the FMR with the inhomogeneous dipolar field of the qubit, only the lowest Kittel mode is excited since for small FM higher modes are separated by an energy gap that exceeds the perturbation amplitude. Therefore the macrospin approximation used in Eq. (1) is justified.  1. Panel a) shows a detailed illustration of the setup considered. The abbreviation "FM" denotes the ferromagnetic particle that is placed on top of the diamond surface that contains the NV-center (red) which is used as magnetometer. Close to the top surface of the FM lies the qubit (black) we want to measure. The setup also includes separate microwave (MW) controls of the qubit (black) and NV-center (red) with resonance frequencies ωs and ωNV, respectively. The ferromagnetic resonance frequency ωF is assumed to be different from both ωs and ωNV. The NV-center is read out optically with a green laser. A slightly modified version of the setup with the NV-center and the FM on a tip is illustrated in panel b); for simplicity we have omitted the two driving fields in this panel.

III. AMPLIFICATION
We now consider our particular scenario wherein a FM is introduced at a distance d from the qubit and h from the NV-center (Fig. 1). In this case, both the accumulated phase and the dephasing of the NV-center are modified by the presence of the FM. Because our amplification crucially depends on the series of pulses applied to the NV-center and qubit, here we detail the pulse sequence, see Fig. 2. First we apply, on the qubit only, N π-pulses separated by a time interval τ , for a total time of t = N τ -during this time the FM reaches steady state precession. Next we initialize the NV-center in state |0 , which takes time t p . Then, a π/2 pulse is applied to the NV-center allowing it to accumulate the phase from the FM tilt stray field. Consequently, a series of N π-pulses are applied to both the NV-center and qubit for a total interrogation time t i = N τ . Finally we apply to the NVcenter a π/2-pulse which is, in general, along an axis in the plane orthogonal to the NV-center axis and different from the first π/2-pulse by an angle θ. The probability that the NV-center occupies the state |0 or |1 after the pulse sequence is now a function of the accumulated phase ϕ NV (t i ) Here, n = ±1 are the two possible outcomes when the state of the NV-center is measured, (δϕ NV (t i )) 2 is the dephasing of the NV-center, and · · · is the expectation value in the Gibbs state. Because the accumulated phase itself depends on the value of the qubit magnetic moment µ s , a measurement of the NV-center is a measurement of µ s . The variance in the measured value of the NVcenter can be reduced by repeating the measurement N times (Fig. 2). Because typically t N t i and therefore t +N t i ≈ N t i , the total measurement time is marginally prolonged by the initial pulse sequence that initialized the tilt of the FM.
Given Eq.
(2), one may show quite generally that, in the relevant experimental limit when t i t p , the AC sensitivity of the NV-magnetometer is given by which defines the minimum detectable magnetic field for a given total measurement time. Here, R, the measurement contrast, is the relative difference in detected signal depending on spin-projection of the NV-center spin, and η is the detection efficiency which takes into account that many measurements have to be performed in order to detect a photon. 24 A detailed derivation of Eq. (3) can be found in Appendix B. The sensitivity is small (i.e., 'good') when the NV-center dephasing is small while the accumulated phase is large. When the qubit is directly coupled to the NV-center (unamplified) the dephasing time of the NV-center is given by T 2 ∼ 200 µs 25,26 so that (δϕ NV (t i )) 2 = (t i /T 2 ) 2 .
As we show in Appendix D, given the pulse sequence described above, when Γt 1 and Γt i 1, where Γ is the linewidth of the ferromagnet, there is a resonant response of the FM while the NV-center picks up nonresonant noise. As such, the ratio of the dephasing to the accumulated phase of the qubit is minimized thereby optimizing the sensitivity. We henceforth take Γt 1 Γt i in the remainder of the text. FIG. 2. The pulse sequence that we apply to the qubit (black) and to the NV-center spin (red). The pulse sequence fτ (t) that consists of N (N is even) is applied to both spins, with the time offset ξ, during the interrogation time ti = N τ . The measurement is repeated N times until the desired precision is achieved, as illustrated on the bottom panel. The sequence section denoted by "FM init" with duration t = N τ is the time during which the precession of the FM is being developed. We assume that the frequencies ωs, ωNV, and ωF are all sufficiently different from each other. The green laser is applied to the NV-center for initialization (polarization) and read-out. The total measurement time is t + N ti ≈ N ti.
The accumulated phase is formally where γ NV is the gyromagnetic ratio of the NV.
is a complex combination of the magnetic stray-field for the FM polarization along the x and y axes at the position of the NV-center (qubit), r N V (r s ), and n NV is the NV-center polarization axis. Within the linear response regime and using the pulse sequence described above and optimally choosing ξ, the expression for the phase accumulated by the NV-center when τ = (2k + 1)π/ω F , 27 for k = 0, 1, . . ., is where γ is the gyromagnetic ratio of the FM. k is defined such that the resonantly driven FM undergoes 2k + 1 half-periods between consecutive π-pulses applied to the NV-center. In the optimal case we have k = 0 so that τ is half the period of precession of the ferromagnet. The details of the derivation of Eq. 5 can by found in Appendix D. It is readily observed from the above equation that ϕ NV (t i ) ∼ 1/Γ which is proportional to the AC magnetic susceptibility of the FM on resonance; thus we indeed obtain a resonant response as anticipated. Even though the phase ϕ NV accumulated due to the FM tilt is large, the angle of the FM tilt is small (∼ 10 −3 if the qubit is a nuclear spin) because M F V µ s . Therefore, we can neglect the effects of the backaction of the FM tilt on the qubit, because the stray field modulation induced by the tilt is small compared to the qubit Rabi amplitude and far detuned from the qubit Larmor precession frequency (i.e. ω F = ω s ). Thus, the qubit is polarized along the FM stray field n s = B z F /B z F ; the scalar product B + F,s · n s is nonzero only if the stray field of the FM tilt has a component along n s at the position of the qubit. We address the optimal geometry and position of the qubit relative to the FM in Sec. III B.
The relevant dephasing is the maximum of the inherent dephasing of the NV-center, (t i /T 2 ) 2 , and the dephasing due to the coupling to the FM, 22 Here S(s) = B NV (s)B NV (0) is the autocorrelation function of the FM noise. Again taking τ = (2k + 1)π/ω F , we show in Appendix D 2 that (5) and Eq. (7) into Eq. (3) and performing the optimization over the interrogation time in Eq. (3), we find the ratio of the unamplified to the amplified sensitivity is the dipolar field of the qubit at the position of the NV-center in the unamplified case and T 2 is the NV-center decoherence time when the FM is not present; these quantities define the unamplified sensitivity. The biggest amplification is obtained when one half-period of the FM oscillation occurs over the timescale τ , i.e., k = 0. In practice, experimental limitations, such as limitations to the qubit Rabi frequency, bound τ and therefore k from below. Thus, in order to achieve the resonance, one has to use k 0 (at the expense of sensitivity) or to tune the FMR frequency as described in the following subsection.

A. Tuning the FMR frequency
It has been demonstrated experimentally 28 that the electron spin of NV-centers can be coherently driven at GHz frequency. For a proton spin, however, the same drive would yield Rabi oscillations in the MHz range. Because typical FMR frequencies are in GHz range, ω F needs to be reduced in order for the proton Rabi frequency to be on resonance with the FMR.  1), as a function of θ, where mz = cos θ. The metastable state at θ = 0 has smaller FMR frequency compared to the case with no external field. The tunneling time τ + from the metastable state has to be longer than the measurement time.
One way to decrease ω F is to apply an external magnetic field antiparallel to m, 29 whereby there is a metastable state when b < b a , with b a = K/M F the FM (crystalline and shape) anisotropy field. In Fig. 3, we plot the energy of the FM as a function of angle θ of the magnetization with respect to the easy axis, according to Eq. (1). It is straightforward to show that the FMR frequency in the metastable state is ω + . On the other hand, the ferromagnet will relax to the thermal state on a timescale τ + given by the Arrhenius law We can insure that the FM is initialized in the metastable state by first measuring the direction of the magnetization, applying an external magnetic field b antiparallel to m and checking subsequently that the FM magnetization direction is unchanged, which can be done under a nanosecond. 30,31 In order for the ferromagnet to remain in the metastable state while the measurement is being performed, we require τ + 1/Γ. Indeed, the total measurement time T should be larger than the FMR initialization time t 1/Γ, and smaller than Arrhenius' timescale τ + T , see Fig. 2. Thus, if we want to tune ω + F to a certain value and work at room temperature, the Arrhenius law suggests that the FM volume must satisfy in order for the metastable state lifetime to be bigger than the measurement time. Here α = Γ/ω + F is the Gilbert damping of the FM. Substituting Eq. (9) for the minimal volume into Eq. (8) we obtain Compared to the amplification formula in Eq. (8), the above equation is independent of the FMR frequency ω F and the FM volume V . Thus, irrespective of the choice of the frequency we work at, the same value for the amplification is obtained. Furthermore, the only dependence on the volume is incorporated in the stray fields but, as shown in Sec. III B, this dependence is weak in the limit d, h V 1/3 ≡ L. The volume in Eq. (9) is implicitly bounded from above in order to remain in the regime where the macrospin approximation is valid. As detailed in Sec. III C, FMs with volumes corresponding to MHz resonance at room temperature are well-described by a single classical spin.

B. FM geometry and demagnetizing fields
In the absence of an external magnetic field, the qubit aligns along the stray field direction of the FM, while the FM spins are aligned along the easy axis, according to Eq. (1). Because M F V µ s , the FM tilt induced by the qubit is negligible. Therefore, the qubit will align along the direction of the stray field produced by the FM. However, for most geometries of the FM and positions of the qubit, B x,y F,s ·B z F,s ∼ 0, and therefore the amplification ν ∼ 0. In the following discussion, we consider our ferromagnet to be a cube of side L, but our conclusions can be straightforwardly generalized to other geometries. To gain insight into the direction and strength of the stray field, we use the well-known analogy between the stray field of a homogeneously magnetized body and an electric field produced by surface charges, 32 see Fig. 4. Specifically, we may consider the surfaces of the cube to have charge density ∼ M F m · s, where s is the vector normal to the surface of the cube. Therefore, when the position of the qubit is very close to the center of the FM surface which is perpendicular to the polarization direction (here assumed along z-axis), B z F,s points along the z-axis, see Fig. 4. Similarly, B x F,s and B y F,s are almost aligned with the x and y axes close to the surface, respectively. Therefore, in these positions, B x,y F,s · B z F,s ∼ 0. However, this is not true near the edges of the ferromagnet. Therefore, in order to obtain a strong amplification, one needs, first, a ferromagnet with edges and, second, to position the qubit close to the edges. One may show analytically and numerically (see Fig. 5) that |B + · n s |/|B + | close to the edges is about an order of magnitude bigger than close to the face center and that it has local maxima close to the cube's corners.
In evaluating B x,y,z F,s , we assume that the FM is homogeneously magnetized as, in cubic geometry, one can find an analytical formula for the stray field in this case, see Appendix E. However, it is important to note that due + + + + + + + + + + + + + + + + + + + + + + + + + B z F,s k z :direction of stray field close to the surface to demagnetizing fields (arising from dipole-dipole interactions in the FM), the FM ground-state is not homogeneous but rather "flowerlike". 33 Specifically, the canting of the spins close to the edges is more pronounced, 32 which modifies the FM stray field close to the edges. To account for the effects of the demagnetizing fields, we perform micromagnetic simulations in OOMMF. 34 In Fig. 5 we plot |B + ·n s |/|B + | in the xy-plane that is 2 nm above the upper face of the cube. We find that the inclusion of demagnetizing fields changes our value of B x,y,z F,s by only ∼ 1% as compared to the uniformly magnetized cube. Therefore, we expect the analytical expression for the stray field to be valid for our choice of parameters.
Because the amplification depends on h and d only through the stray fields, here we detail this dependence and show that our scheme is robust against small variations of h and d. The stray fields above the face-center of the cube are equivalent to the electric field of an infinitely charged plane. Therefore, when h L and the NV-center is near the center of the cube face, the amplification is independent of h. On the other hand, the stray field close to the cube edge in comparison to L is equivalent to the electric field of a set of infinite line charges. Therefore, there is a logarithmic dependence of the stray field on the distance to the edge, d, of the cube in units of L so that the amplification is weakly dependent on d.
Typical values of the stray fields at the position of the qubit and NV-center in the limit d, h L for YIG are on the order of a few hundreds of Gauss. While the presence of a magnetic field perpendicular to the NV-center axis can significantly limit the read-out fidelity of the NVcenter, it was found that the fields up to 10 mT can be tolerated. 35 Therefore, we conclude that one can either place the NV-center at distances where the stray field does not exceed 10 mT or care must be taken that the stray field is mostly aligned along the NV-center axis.

C. Estimates
In this section we give estimates for the amplification for two cases: detecting a nuclear spin and an electron spin. For all the estimates provided herein, we assume room temperature and that the FM material is YIG, so that α ∼ 10 −5 , µ 0 M F = 0.185 T, and K/M F = 60 mT. 36 For simplicity but without loss of generality, we assume that the FM has the shape of a cube for the estimates given below. For a cube and in the macrospin approximation there is no contribution from shape anisotropy. Because in typical experiments 10 h ∼ 5 nm and d = 20 − 30 nm, we take these values for our estimates below.
For detecting a single nuclear spin, we need to tune the FMR to the MHz range and thus, according to Eq. (9), the optimal FM volume V corresponds to a cube side L = 400 − 500 nm. In this regime d, h L, and thus the amplified sensitivity only weakly depends on the particular choice of d and h. Taking T 2 ∼ 200 µs, which is the best case scenario for the unamplified sensitivity and subsequently worst case for amplification, we obtain ν ∼ 1.2 × 10 3 . Since state-of-the-art NV-magnetometers can resolve clusters of about 300 nuclear spins at a distance of ∼ 10 nm, 9,11,37,38 the amplification by three orders of magnitude obtained herein suffices for resolving a single nuclear spin at a distance of 30 nm from the surface.
We note that the volume considered in our estimate corresponds to T 2 ∼ 10 ns [see Eq. (7)], which is also the value of the optimal interrogation time, and therefore even when the "bare" T 2 ∼ 10 ns (i.e., the T 2 time in the absence of the FM), the decoherence time of the NVcenter is limited by the FM noise. Thus, because the signal amplification in our scheme far exceeds the effect of the additional decoherence it induces, even shallow NVcenters 25,26 with relatively short decoherence time can be used and significantly outperform unamplified long-lived NV-centers.
To amplify the signal from a single electron spin, there is no need to tune down the FMR frequency since the electron spin can be driven at GHz frequencies. Thus, one can use the stable state of the FM and therefore there is no restriction on the minimum FM volume. With the same distances d and h as in the nuclear spin case and for L = 20 − 40 nm, corresponding to the volume of maximum amplification, we obtain ν ∼ 0.5 × 10 4 . In order to obtain this estimate, we used the fact that the relaxation time of the electron spin is typically shorter than the NVcenter T 2 time and that the NV-center interrogation time cannot be longer than the relaxation time of the electron spin. 10 Thus, in Eq. (10) we use a typical electron spin relaxation time T d 1 ∼ 150 ns in place of T 2 . 10 If we choose h = 20 nm and d = 1 nm, we obtain an amplification as big as ν ∼ 2 × 10 4 for L = 15 − 20 nm.

IV. CONCLUSIONS
We have proposed and analyzed, both analytically and numerically, a modification of a standard NVmagnetometry setup that yields a significant improvement of NV-magnetometer sensitivity by up to four orders of magnitude. Our scheme is based on a ferromagnetic particle, placed in close proximity to a sensing NVcenter spin. The qubit spin to be detected is then used to resonantly drive the large macrospin of the FM giving rise to a strong, amplified stray field acting on the NVmagnetometer. Compared to the existing schemes that use the quantum nature of an intermediate spin for improving sensitivity, 18 we stress that our scheme is fully classical and thus should be easily realizable at room temperature-all the ingredients of our scheme are already demonstrated in separate experiments. 10,28,39,40 An alternative setup to achieve resonance between the qubit and FM is to place the NV-center and the FM on a cantilever 41 with resonance frequency in the GHz range. By driving the cantilever, we alleviate the necessity of driving the qubit at FMR frequency as the qubit field is modulated by the oscillations of the cantilever. Since the dipolar field of the qubit decays rapidly with distance, the modulation of the qubit field achieved in this scheme is almost as big as when the qubit is driven via a microwave field (the previously described scheme for which the amplification estimates are given). Therefore, we conclude that the estimates for the sensitivity amplification given in Sec. III C still hold in that case.
The magnetometric scheme including a ferromagnetic particle proposed here is a step forward to a more accurate magnetic field measurement. In particular, it enables the detection of a single nuclear spin at distances that are noninvasive to the system under study. Therefore, the proposed room temperature amplification method opens up new venues for future analyses of previously inaccessible biological and chemical systems.

V. ACKNOWLEDGMENTS
We would like to thank H. Fanghor for sharing his expertise about micromagnetic simulations. This work was supported by the SNF, NCCR QSIT, IARPA, DARPA QuASAR programs and the MURI QuISM. F. L. P. is grateful for support from the Alexander von Humboldt foundation.

Appendix A: Cramer-Rao Bound
For the sake of completeness, we review here the proof of the Cramer-Rao bound, that we use to derive the sensitivity expression (3) in the main text. The Fisher information of the parameter estimatorμ s is given by The Cramer-Rao bound follows from the trivial identity where ∆μ s =μ s (n 1 , . . . , n N ) − μ s . Taking the derivative of this identity with respect to µ s and using the fact that the estimatorμ s does not depend explicitly on µ s , we obtain n1 · · · n N p(n 1 |µ s ) . . . p(n N |µ s ) Furthermore, for the unbiased estimator, μ s = µ s and thus the right-hand side of Eq. (A4) is equal to 1. Finally, applying the Schwarz inequality, cov(X, Y ) 2 ≥ var(X)var(Y ), to the above equation yields the Cramer-Rao bound, Eq. (A1).

Appendix B: Sensitivity of an NV-center
The variance of any estimatorμ s of the unknown parameter µ s satisfies the Cramer-Rao inequality Eq. (A1). Using the probability distribution from Eq. (2) we obtain Thus, a bigger Fisher information F (µ s ) leads to a more accurate value of the estimatorμ s . For DC magnetometry we typically have ϕ NV (t i ) = γ NV (B 0 + B)t i ≡ t i /T and (δϕ NV (t i )) 2 = t i /T * 2 , where γ NV B 0 = 2.87GHz is the zero-field splitting of the NVcenter and T * 2 is typically on the order of a few microseconds. The field we want to measure is B = µ 0 µ s /(4πd 3 ), with d the distance between the qubit and the NV-center. Consider the scenario T T 2 which is valid for DC magnetometry. In such a situation, one may choose an interrogation time maximizing sin 2 [ϕ NV (t i )+θ] and minimizing cos 2 [ϕ NV (t i )+θ] in Eq. (B1). This is independent of the angle θ which we set to zero without loss of generality. Thus instead of maximizing the Fisher information from Eq. (B1), we need only to maximize its envelope function, Repeating the measurement N = T /(t p + t i ) times (t p is the initialization time) reduces the variance by a factor 1/N . The Cramer-Rao bound (A1) then leads to (δμ s ) 2 ≥ 1 N F (µs) . The minimal value of the magnetic momentμ s (t i , T ) (that can be resolved within measurement time T and interrogation time t i ) is determined by the one for which the mean value is equal to its standard deviation,μ Assuming t i t p , we finally obtain the sensitivity As mentioned in the main text, R is the measurement contrast and η is the detection efficiency; 24 these quantities take into account that the measurement has to be performed many times in order to detect a photon. The situation for AC magnetometry is different; here ϕ NV (t i ) = λγ N V Bt i ≡ t i /T while we still have (δϕ NV (t i )) 2 = t i /T 2 . (Note that the constant of proportionality λ depends on the specific pulse sequence applied.) In typical situations, the AC magnetic field is small and T T 2 . In such scenario, and for vanishing angle θ, the accumulated phase will never reach a value of π/2 and one needs to maximize the Fisher information (B1), not only its envelope. In this limit, we obtain a very different expression for the sensitivity, and, in particular, the expression is in units of "magnetic moment"/Hz 1 4 (see Appendix C). Fortunately, such result can be improved: one may take a nonzero value of the angle θ such that the expression ϕ NV (t i ) + θ = π/2 within the interrogation time. In this case, the amplified sensitivity takes the form (B4), improving the sensitivity.
Appendix C: AC sensitivity for θ = 0 The goal of this appendix is to derive the expression for the AC sensitivity when the angle θ between the two π/2-pulses, applied at the beginning and at the end of the sequence, is zero. This calculation is presented for the sake of completeness, however, this is not the expression we use to derive our amplified sensitivity. As mentioned in the main text, for AC magnetometry we have where the constant of proportionality depends on the specific pulse sequence applied. It is important to note that here only the AC field component that matches the frequency of the pulse sequence contributes (i.e., there is no contribution from B 0 ). When the magnitude of the AC driving field is small, we are in the limit of T T 2 . As noted above, in this regime the accumulated phase ϕ NV (t i ) will not reach the value of π/2 and thus the full Fisher information needs to be maximized. Namely, we maximize Therefore, . Now, if we remove the dependence on the total measurement time from the above expression, we obtain the quantity that describes the magnetic moment sensitivity in units of "magnetic moment"/Hz 1 4 , i.e., Appendix D: Calculation of ϕNV (ti) and β(ti, τ ) The goal of this appendix is to give a detailed derivation of Eqs. (5) and (7) that are central to our work. The former describes the phase accumulated by the NVmagnetometer, while the latter the variance of this accumulated phase.
Within linear response, the accumulated phase is where ξ (|ξ| ≤ τ ) is the time offset between the CPMG pulse sequence applied to the qubit and the NV-center. We have introduced the following notation, with Ω = iω F + Γ and p τ (s, t i ; ξ) = ti−s 0 dt f τ (t − ξ)f τ (t + s). After performing the integral in Eq. (D2) and using t i = N τ , t = N τ , we obtaiñ Since we want the qubit to perturb the ferromagnet within a narrow frequency window around the FMR (i.e., narrower than the FMR linewidth Γ), we require that Γt 1. In this limit, the expression for X ξ (t i , t ) is significantly simplified The expression for dephasing can be obtained from 22 is the anisotropy field) one obtains the following expression for the fluctuations of the ferromagnet, Combining equations (D9-D11) we finally obtain 1. On-resonance case τ = (2k + 1)π/ωF The Fourier transform of the CPMG sequence depicted in Fig. 2 has peaks at frequencies (2k + 1)π/τ . Thus we have a resonant behavior whenever this frequency matches ω F . Assuming Γt 1 and ω F (2k + 1)Γ leads to the following expression for X ξ (t i ), namely where ψ = ω F ξ. Assuming ω F (2k + 1) 2 π 2 Γ, we can neglect the second term in the bracket in Eq. (D13) and obtain the expression for the phase accumulated by the NV-center during the interrogation time t i , Next, we choose the time offset ξ (i.e., ψ) such that ϕ NV (t i ) in the above equation is maximized Assuming that the optimal interrogation time satisfies Γt i 1, we arrive at the following expression for Y ξ=0 (t i ), namely The above expression yields the following variance of the phase accumulated by the NV-center 2. Pulse sequence applied: a matter of timescales Here we elucidate the importance of the different duration of the pulse sequences applied to the qubit and the NV-center. We analyze what happens to the amplification when both pulse sequences have the same duration, see Fig. 6. Performing the Fourier transform of Eq. (D9), one obtains Here the subscript ω F refers to the Fourier transform evaluated at frequency ω F . We assume that the filter function F (ωt i ) is centered around the frequency ω F (onresonance case) and that it is much narrower than the FMR linewidth, i.e., Γt i 1-this is exactly the opposite limit from the one assumed to arrive at Eq. (7). The accumulated phase is given in Eq. (5), and thus the magnetic moment sensitivity in this case reads where χ ⊥ (ω) = γ/ [M F V (ω F − ω + iΓ)]. The above expression yields almost no amplification, since we do not only excite the FM resonantly but also the NV-center picks up the resonant noise. If we rewrite Eq. (7) in the form β(t i , τ ) ≡ (t i /T 2 ) 2 , we can understand that the decoherence times in the two considered limits differ from each other by many orders of magnitude, namely Appendix E: Stray field from a uniformly magnetized cuboid In this section we review the analytical formulas giving the stray field of a uniformly magnetized cuboid of side lengths L x , L y , and L z , see Fig. 4. As mentioned in the main text, the magnetic field B(r) at a point r = (x, y, z) outside of the cuboid can be calculated from the expression for the electric field originating from charges uniformly distributed on the surfaces of the cuboid perpendicular to the magnetization, 42,43 see Fig. 4. For the sake of simplicity, we assume that the magnetization direction points either along x, y, or z. The expression for the stray field is then Plot of the stray field components normalized to the magnetic saturation: B z x (x, y, z = 16 nm)/(µ0MF ), B z y (x, y, z = 16 nm)/(µ0MF ), and B z z (x, y, z = 16 nm)/(µ0MF ) for a cube of side length L = 15 nm. Because the origin of our coordinate system is at the center of the cube, this is a plot of the stray field at a distance of 1 nm from the upper surface of the cube.