Quantum sensing of electric field distributions of liquid electrolytes with NV-centers in nanodiamonds

To use batteries as large-scale energy storage systems it is necessary to measure and understand their degradation \textit{in-situ} and \textit{in-operando}. As a battery's degradation is often the result of molecular processes inside the electrolyte, a sensing platform which allows to measure the ions with a high spatial resolution is needed. Primary candidates for such a platform are NV-centers in diamonds. We propose to use a single NV-center to deduce the electric field distribution generated by the ions inside the electrolyte through microwave pulse sequences. We show that the electric field can be reconstructed with great accuracy by using a protocol which includes different variations of the Free Induction Decay to obtain the mean electric field components and a modified Hahn-echo pulse sequence to measure the electric field's standard deviation $\sigma_E$. From a semi-analytical ansatz we find that for a lithium ion battery there is a direct relationship between $\sigma_E$ and the ionic concentration. Our results show that it is therefore possible to use NV-centers as sensors to measure both the electric field distribution and the local ionic concentration inside electrolytes.


I. INTRODUCTION
Rechargeable batteries play an important role for our society and are a key ingredient for the transition towards renewable energy sources [1][2][3].As the production of batteries is accompanied with a considerable use of resources, recyclable [4] batteries with a long lifetime are needed.The latter is limited by degradation mechanisms, such as the formation of solid-electrolyte interfaces [5] or lithium-plating [6] which can reduce the battery's capacity with increasing cell age [7].As these processes happen on a molecular level within nanometer scales [5], a sensor which is capable of monitoring the ionic concentration in-situ and in-operando with high spatial and temporal resolutions is needed.Even though MRI allows to reconstruct transport properties [8,9] of a battery, tools which allow to perform measurements inside the electrolyte are still absent [5].
It has been demonstrated that nitrogen-vacancy (NV) centers in diamond (see Fig. 1(b)) are high-resolution quantum sensors, which can detect oscillating or fluctuating [10][11][12][13] magnetic fields with nano- [14,15] and even subpico-Tesla [16] sensitivities.Besides this, NV-centers have great ability for the detection of electric fields.They can not only detect DC [17,18] or AC [19] electric fields with remarkable precision, but are additionally capable of detecting single fundamental charges [20] even within the diamond lattice [21].This electric field sensitivity was used by Ref. [22] to show that, based on theoretical con-siderations, bulk NV-centers can work as electrochemical sensors if they are in contact with an electrolyte solution.
Here we show that nanodiamonds equipped with single NV-centers can act as in-situ electric field sensors inside liquid electrolytes (Fig. 1(a)).By exploiting how transverse and axial electric fields act on the NV-center's ground state spin states, we find variations of the freeinduction decay (FID) pulse sequence, which allow to measure the mean electric field components.Further, we show that it is possible to use variants of the Hahnecho pulse sequence to additionally obtain the electric field's standard deviation σ E .From a semi-analytical ansatz we demonstrate exemplarily for a lithium ion battery (LIB) that there is a direct relationship between the electric field's standard deviation and the local ionic concentration.A nanodiamond with a single NV-center can therefore work as a sensor which allows to simultaneously reconstruct the electric field distribution and to measure the ionic concentration with nm spatial resolution.

II. ELECTRIC FIELD DISTRIBUTION IN LIQUID ELECTROLYTES
Before introducing measurements of the electric field distribution by the NV-center, we would like to develop an analytic expression of the electric field induced inside the nanodiamond by the positive and negative ions of the electrolyte.
The potential Φ at position r inside the nanodiamond due to a single charge q at position b, is described by and inside a sphere of radius R. The relative permittivities are ND = 5.8 [22] and e = 17.5 [23].Solid lines are fits following Eq.( 3) with A as a fit parameter.(d) Fit parameters A obtained from (c), compared to the theory value.
Poisson's equation Here = 0 i with i = e, ND, are the permittivities of, respectively, the electrolyte and the nanodiamond in terms of the vacuum permittivity 0 and ρ is the charge density induced by q.The solution inside the nanodiamond, Φ ND (see Methods for the detailed derivation), allows to obtain the electric field at the center of the nanodiamond, which is By considering the positions of ions of a molar concentration c to be normally distributed within a sphere of radius R around a nanodiamond (radius r ND ), the standard deviation of the electric field distribution at the center of the nanodiamond is To validate Eq. ( 3), we simulated the standard deviation of 500 sets of uniformly and randomly placed ions for different molar ionic concentrations (see Fig. 1(c)).As it is the most widely used electrolyte of LIBs [24], we chose LiPF − 6 with e = 17.5 [23].The total electric field was calculated as the linear sum of Eq. ( 2) for all randomly placed ions around a 200 nm spherical nanodiamond [25].As it can be seen from Fig. 1(d), the expected A value is in fair agreement with the simulations.From Eq. (3) it can be calculated that for R = 500 nm, the fluctuations will increase only by 3%, compared to σ E (R = 400 nm).
As σ E therefore saturates for R 500 nm, this implies that electric field fluctuations only affect the nanodiamond within sub-micrometer range and the system is limited by the confocal volume of the experimental setup, which typically is ∼ 1 µm 3 [26,27].

III. SENSING OF STATIC ELECTRIC FIELDS INSIDE ELECTROLYTES
An electric field E can in cylindrical coordinates be expressed by its axial component E z , its transverse projection E ⊥ = E 2 x + E 2 y and an angle φ E , which defines the projections onto the x and y axis as E x = E ⊥ cos φ E and E y = E ⊥ sin φ E .The total Hamiltonian which describes the NV-center in presence of electric and axial magnetic fields will in the following be denoted as Ĥ0 .By taking into account that the NV-center can be driven by two perpendicular microwave wires (see Fig. 1(a)) with amplitude Ω, frequency ω d and a phase φ between each other, the total ground state Hamiltonian in a frame rotating with ω d is Ĥ = Ĥ0 + Ĥd (see Methods), where Here ∆ = D − ω d is the detuning between the zerofield splitting, D = 2.87 GHz [28], and the microwave drive frequency.S i , i = x, y, z, are the spin-1 operators, which can be used to define ladder operators S ± = S x ± iS y .σ 0,±1 = |0 ±1| are operators which describe transitions between |0 and, respectively, |±1 .Frequency contributions generated by electric and axial magnetic fields are considered through ) and β z = γ e B z (γ e = 28 GHz/T [30]).
The phase factors ± = 1 − ie ∓iφ /2 which enter into Eq.( 4), allow to describe the transitions which are caused by circularly (φ = ±π/2) or linearly (φ = 0) polarized microwave drives [31].The time-evolution operators of Ĥd , R (t) = e −i Ĥd t (see Methods), show that one can induce Rabi oscillations between |0 and |1 for right circularly polarized drives and |0 ↔ |−1 for left circular polarizations.Linearly polarized drives allow to drive transitions between |0 and both |±1 .In absence of microwave drives, the |±1 states are symmetrically mixed by ξ ⊥ and axial electric fields effectively shift |0 from |±1 , which can be seen from F (τ ) = e −i Ĥ0τ (see Methods).As axial and transverse electric fields thus act differently on the |m s = 0, ±1 states of the NV-center, one can derive variations of the Free Induction Decay (FID), which allow to extract these electric field components.

A. Measurement of electric field components
The FID consists of two microwave pulses separated by a free evolution period τ .Electric field contributions ξ ⊥ , φ E and ξ z can be sensed through FID-variations, as shown in Fig. 2(a).The NV-center can be initialized into its |0 state via excitation with green laser light, followed by intersystem-crossing [32].This state can then be driven to −i |1 through a right-polarized π-pulse, denoted as R (T π ) + , and will be influenced by both axial magnetic as well as transverse electric fields.The latter induce mixing with |−1 .By using a microwave π-pulse with the same polarization as the initial one, the transferred population from |1 to |−1 can be obtained from the FID-signal which is a measure of the population which has been transferred from |1 to |−1 .In Fig. 2(b) one can see this FID-signal as a function of the free evolution time τ for β z values up to 2.8 MHz, which corresponds to B z = 1 G.Besides having a decreased contrast for β z = 0, the frequency β 2 z + ξ 2 ⊥ of the FID-oscillations depends on both axial magnetic and transverse electric fields.It is therefore strongly recommended to perform the measurements in a magnetically shielded environment, for exam-ple by a µ-metal as in Ref. [33].In the following it will be assumed that all measurement are performed without any magnetic field being present.
The transverse electric field components are uniquely defined through φ E , as ξ x = ξ ⊥ cos φ E and ξ y = ξ ⊥ sin φ E .A superposition state −e iπ/4 (|1 + |−1 ) / √ 2 generated through a linearly polarized π-pulse (considered via R (T π ) 0 , see Methods) will additionally to ξ ⊥ also be affected by φ E as this phase differs in its sign for |1 and |−1 (see Methods).If either |1 or |−1 is projected to |0 through the final microwave pulse, one obtains an FID-signal, which both depends on ξ ⊥ and φ E , One can obtain φ E as the relative fraction between the value of the FID-signal at τ = 0 and its first maxima at 2τ ξ ⊥ = π/2, By using FID ξ ⊥ and FID ξ ⊥ ,φ E , it is therefore possible to not only determine the electric field's transverse component, but also to obtain the projection onto the x and y axes, which are determined through φ E .
Axial electric field contributions ξ z cause a Stark shift between |0 and |±1 .A superposition state (|0 − i |−1 ) / √ 2 generated by a circularly polarized π/2-pulse (see Fig. 2(a)) will therefore be affected both by ξ z and ξ ⊥ .If the final microwave π/2-pulse has the same polarization as the initial one, an FID-signal is obtained which depends both on ξ ⊥ and ξ z , if the NV-center was driven with ω d = D.The Fourier transform of Eq. ( 8) (see Methods), shows, that ξ z can be measured if it is possible to spectrally resolve ξ ⊥ ± ξ z .To study this, we numerically [34,35] simulated FID ξz,ξ ⊥ and included dephasing at rates 1/T * 2 through a Lindblad operator 1/T * 2 S z for T * 2 in the range up to 15 µs (see Fig. 2(c)).One can resolve ξ ⊥ ±ξ z for nanodiamonds with T * 2 > 10 µs, which is higher than the value of typical nanodiamonds [36].For a nanodiamond with T * 2 ≈ 15 µs it would be possible to distinguish between ξ ⊥ and ξ z and therefore to determine the projection of the electric field onto the symmetry axis of the NV-center.

IV. INFLUENCE OF FLUCTUATING ELECTRIC FIELDS
It can be assumed that the ions surrounding the nanodiamond will not stay static for the timescales in which measurements are performed but will be subject to, for instance, drift and diffusion.These fluctuations will affect the electric field inside the nanodiamond.Due to the limited T * 2 of nanodiamonds, the FID pulse sequences as introduced before will be mainly suitable for the measurement of the average electric fields (see Methods).The coherence time of a nanodiamond can be significantly prolonged if instead of an FID, a Hahn-Echo pulse sequence is used [25].As it is shown in Fig. 3(a), we propose a modified version of the Hahn-Echo, where after the first free evolution interval, a πpulse with right-circular polarization is performed, before the spin is allowed to precess freely during a second free evolution interval τ .Before being read out, a right-circularly polarized π-pulse is applied, which leads to a signal Hahn (τ ) = (1 − cos (2τ ξ ⊥ )) 2 /4.Simulations of this Hahn-Echo variation show that the averages (see Methods for an example) can be fit by Here T 2 is the sum of the intrinsic spin coherence time T 2,int.= 100 µs [25] and a contribution due to the fluctuating electric fields, In Fig. 3(b), one can see T 2 as a function of the electric field's standard deviation σ E , where solid lines are T 2,E = αE m /σ 2 E in terms of a fit parameters α.The total spin coherence time is therefore strongly affected by σ E and the mean electric field value E m .If the mean transverse electric field has been sensed by the FID sequence as shown in Eq. ( 5), it is therefore possible to derive the electric field's standard deviation, which together with ξ ⊥ , φ E and ξ z defines the electric field distribution.As there is a direct relationship between σ E and the local ionic concentration (see Fig. 1(c)), the proposed Hahnecho pulse sequence additionally allows to use the NVcenter inside the nanodiamond as a local concentration sensor.

FIG. 3. (a)
Hahn-echo pulse sequence used to simulate Eq. ( 10).(b) Total T2 for numerically [34,35] simulated Hahn-Echoes with T2,int = 100 µs, with the electric field components sampled from a normal distribution with mean Em and standard deviation σE.For the simulations a drive of Ω = 10 MHz was used.Solid lines are fits of αEm/σ 2 E .Every trajectory was obtained from 1000 individual simulations.Error bars of one standard deviation are smaller than the data points.

V. CONCLUSION AND OUTLOOK
In conclusion we have shown here a full reconstruction of the mean electric field generated in a liquid electrolyte, through the spin control of a quantum sensor immersed in the electrolyte.We have found exact expressions correlating the electric field components with the free-induction decay of the sensor spin, and the dependence of the variance on the spin-echo measurements.Together we were able to deduce the electric field distribution and also measure the local ionic concentration, a key parameter in characterizing the performance of the liquid electrolyte for battery applications.We envisage that with improved modeling of the electric field distribution in liquid electrolytes and using better quantum control methods, for example using correlation spectroscopy [37], we could enhance the sensitivity of the sensor to the local electric-field environment, allowing for an in-situ monitoring of the battery using the liquid electrolyte.
project QMNDQCNet and DFG (Project No. 507241320 and 46256793).S. V. K. and D. D. would like to acknowledge the funding support from BMBF (Grant No. 16KIS1590K).A. F. is the incumbent of the Elaine Blond Career Development Chair and acknowledges sup-port from Israel Science Foundation (ISF grants 963/19 and 418/20) as well as the Abramson Family Center for Young Scientists and the Willner Family Leadership Institute for the Weizmann Institute of Science.
Quantum sensing of electric field distributions of liquid electrolytes with NV-centers in nanodiamonds -Supplementary Information

I. ELECTRIC FIELD AT CENTER OF NANODIAMOND
In the following we would like to deduce the electric field of a single point charge q at a distance b from the origin of the nanodiamond with radius r ND by following Ref.[S1].Poisson's equation describes the electrostatic potential Φ, where = 0 i , i = e, ND is the permittivity of, respectively, the electrolyte and the nanodiamond in terms of the vacuum permittivity 0 .By exploiting azimuthal symmetry of the problem, the above expression reduces to Laplace's equation for r = b, which in spherical coordinates with |r| = r and θ the angle spanned by r and b is The general solution of this partial differential equation can be expressed in terms of the associated Legendre polynomials P l of order l and in terms of two constants A l and C l as [S1, S2] As the potential inside the nanodiamond must be finite at r = 0, C l needs to vanish and one therefore has (S5) The general solution would then be given as a superposition of this expression with Eq. (S3), i.e.Φ e = Φe + Φ, which reads where it was used that in this case A l = 0 to ensure a vanishing potential at infinite distances to the origin, i.e.Φ e → 0 for r → ∞.The constants A l and C l , which enter into, respectively, Eq. (S4) and Eq.(S6), can be determined by requiring continuity at the interface between electrolyte and nanodiamond, e E e − ND E ND • n ND = 0 (S7) where n ND = r/r is the unit vector normal to the surface of the nanodiamond.These boundary conditions are satisfied, if . (S10) The electrostatic potential inside the nanodiamond therefore is b l+1 e (2l + 1) ND l + e (l + 1) and the electric field at the center, i.e. for r = 0, can be calculated as if it is used that in cartesian coordinates one has e z = cos θe r − sin θe θ with e z the azimuthally symmetric unit vector and e r and e θ the radial and altitudinal unit vectors.

A. Electric field variance
The probability of an ion to be located at b witin a sphere of radius R around the nanodiamond is It can be easily verified that this distribution is normalized, i.e.R 3 d 3 b p (b) = 1.Direct calculation reveals E z = 0 and therefore (2 e + ND ) Under the assumption that the electric fields generated by the single ions are uncorrelated, the total fluctuations are given by multiplying the above expression with the number of ions inside the sphere.The standard deviation σ 2 Ez = cN A V σ 2 Ez,ion of the electric field components with N A Avogadro's number, c the molar ionic concentration and V the volume in which the ions reside therefore is From this it can be seen that the expected electric field fluctuations increase with the molar concentration, i.e. σ Ez ∝ √ c.

II. HAMILTONIAN IN ROTATING FRAME
As derived by Doherty et al. in Ref. [S3], the Hamiltonian of the NV-center in presence of axial magnetic fields B z and electric field components E i with i = x, y, z and = 1 is with γ e = 2.8 MHz/G the NV's gyromagnetic ratio [S4] and d = 0.35 Hz • cm/V and d ⊥ = 17 Hz • cm/V the axial and transverse dipole moments [S5].By rewriting this Hamiltonian in terms of its frequency contributions β z = γ e B z , x + E 2 y and by introducing the electric field polarization φ E , which defines the transverse electric field projections via ξ x = ξ ⊥ cos φ E and ξ y = ξ ⊥ sin φ E , Eq. (S16) can be rewritten as where Ŝ± = Ŝx ± i Ŝy are spin-1 ladder-operators and h.c.means the hermitian conjugate.To understand how fluctuating electric fields alter the FID-signal, we numerically [S7, S8] simulated FID ξ ⊥ (Eq.( 5) main text) for normally distributed electric fields.Hereby, at every timestep at which the time-evolution is calcuated, the electric field components are passed from a beforehand sampled normal distribution with mean E m and standard deviation σ E .It can be seen from Fig. S1 that the average FID ξ ⊥ signal decays rapidly to its steady-state value of 1/2, which is due to the short T * 2 time of 1 µs.For this reason it is proposed to use the Hahn-Echo pulse sequence for measurements of strongly fluctuating electric fields.The total T2 value obtained from this fit is T2 = (39.87± 0.86) µs.
As described in the main text, the numerically obtained Hahn-echo trajectories (see Fig. S2 for an example) are well fitted by Hahn (τ ) = 1 4 1 − cos (2τ ξ ⊥ ) e −τ /T2 2 .Here both the intrinsic T 2,int.= 100 µs and T 2,E due to fluctuating elecric fields contribute to the total T 2 via The latter can be fitted in terms of E m and σ E via The values of the fit parameter α can be found in Fig. S3.

FIG. 1 .
FIG. 1.(a) Experimental setting.A nanodiamond which is dissolved in the liquid electrolyte of the battery is surrounded by positive (orange) and negative (blue) ions.Two perpendicular aligned gold wires allow to generate polarized microwave drives.(b) To work as a quantum sensor, the nanodiamond contains a vacancy (V) next to a nitrogen atom (red).(c) Standard deviation of Ez, calculated from 500 repeated sets of randomly placed ions of concentration c around the nanodiamond (rND = 100 nm)and inside a sphere of radius R. The relative permittivities are ND = 5.8[22] and e = 17.5[23].Solid lines are fits following Eq.(3) with A as a fit parameter.(d) Fit parameters A obtained from (c), compared to the theory value.