Doubly geometric quantum control

In holonomic quantum computation, single-qubit gates are performed using driving protocols that trace out closed loops on the Bloch sphere, making them robust to certain pulse errors. However, dephasing noise that is transverse to the drive, which is significant in many qubit platforms, lies outside the family of correctable errors. Here, we present a general procedure that combines two types of geometry -- holonomy loops on the Bloch sphere and geometric space curves in three dimensions -- to design gates that simultaneously suppress pulse errors and transverse noise errors. We demonstrate this doubly geometric control technique by designing explicit examples of such dynamically corrected holonomic gates.


I. INTRODUCTION
Quantum information processing demands unprecedented precision in the control of qubits. This is made challenging by the ubiquitous noise from the environment and unavoidable control imperfections, which can substantially reduce the control fidelity. Tremendous progress has been made in the development of quantum optimal control techniques . Holonomic quantum computation [28], where the gates are based on geometric phases [29][30][31][32][33][34][35], is one approach to boosting gate fidelities in the presence of noise. Using geometric rather than dynamical phases to implement quantum gates can mitigate the effect of noise that leaves holonomy loops in the control space unperturbed. Geometric phases can be accrued using either adiabatic [36][37][38] or non-adiabatic driving [39][40][41][42][43][44][45][46][47][48][49]; the latter alleviates decoherence by reducing the operation time. Non-adiabatic holonomic (geometric) gates have been successfully realized in superconducting systems [50,51], trapped ions [52,53], and NV centers in diamond [54][55][56]. An advantage of the holonomic approach is that it affords substantial flexibility in choosing experimentally friendly pulse shapes to generate the gates. However, while holonomic gates are resistant to errors along the holonomy loop, they remain susceptible to noise that is transverse to it, a type of noise that is common in many qubit platforms.
Dynamically corrected gates constitute another approach to designing controls that are robust against various types of noise [57][58][59][60][61][62][63][64][65][66][67][68][69][70][71]. Analytical approaches in particular enable one to search for globally optimal solutions to a given control task. However, these approaches often rely on fixed pulse waveforms that can be experimentally infeasible or can necessitate the use of longer sequences that expose the system to adverse effects that arise on longer time scales. Finding shorter sequences is made challenging by the need to solve highly nonlinear equations that enforce the noise cancellation conditions [61,62]. A recent approach to dynamically corrected gates sidesteps many of these issues by mapping qubit evolution to geometric space curves in three dimensions [70,[72][73][74]. Control fields that cancel transverse noise errors can be obtained from closed space curves. While some progress has * dongwz@vt.edu † efbarnes@vt.edu been made in extending this method to the cancellation of control field errors, this often comes at the expense of reduced flexibility in waveform shaping [61,75,76].
In this paper, we present a general technique for constructing non-adiabatic holonomic gates that dynamically correct transverse noise errors. This is achieved by bringing together two types of geometry: holonomic trajectories on the Bloch sphere and geometric space curves that quantify the error accrued by transverse noise. We show how to systematically design qubit evolutions that exhibit both closed holonomy loops and closed error curves, achieving the simultaneous cancellation of both control field errors and transverse noise errors that are beyond the reach of purely holonomic methods. We refer to these evolutions as Doubly Geometric (DoG) gates. We demonstrate our approach by constructing several families of DoG gates based on smooth pulses.
The paper is organized as follows. In Sec. II we discuss the two types of geometry that characterize the evolution of a noisy quantum system: the holonomy of quantum states and geometric space curves that quantify the response of the system to transverse noise. In Sec. III, we show how to combine space curves with holonomy to arrive at a general procedure for finding control fields that suppress both control errors and transverse noise errors. We present several explicit examples of robust gates generated by this procedure, including singlequbit and two-qubit entangling gates. Quantum speed limits and experimental implementations are discussed. We conclude in Sec. IV. Several appendices contain technical details about our general technique and our explicit examples.

II. TWO GEOMETRIES OF QUANTUM EVOLUTION
We begin by describing the two types of geometry that come into play when a qubit evolves in the presence of noise. The first is the notion of holonomy on the Bloch sphere, which facilitates the design of gate operations that are based on geometric phases. The second is a geometric space curve formalism that allows one to view the accumulation of errors due to transverse noise as a three-dimensional path in the space of traceless Hermitian operators that we refer to as the "error curve". After we describe these two types of geometry, we show how they can be combined together to form a framework for designing dynamically corrected holonomic gates in the following section.

A. Geometric phases and holonomy
Aharonov and Anandan [39] showed that there is a geometric phase associated with any cyclic evolution that starts from state |ψ(0) and ends in the parallel state |ψ(T ) at time T . This phase is given by The right-hand side of the first line of Eq. (1) amounts to subtracting the dynamical phase from the total phase, β g (T ) = β total (T ) − β d (T ). The dynamical phase is often written as an integral of the expectation value of the Hamiltonian, ψ(t)| H(t) |ψ(t) . Note however that this expression is frame-dependent, as we discuss in Appendix A. The second line of Eq. (1) comes from mapping |ψ(t) onto state |ν(t) in a projective space defined such that all parallel |ψ(t) map to the same |ν(t) . In the case of a two-level system, which is the focus of this work, |ν(t) lives on the Bloch sphere. This mapping is illustrated in Fig. 1(a). The area enclosed by the trajectory of |ν(t) determines the geometric phase. It is worth noting that unlike in the case of the Berry phase [36], the Aharonov-Anandan phase is defined without reference to an adiabatic condition; it is exact for any cyclic evolution. Hereafter, we refer to the Aharonov-Anandan phase as the geometric phase.
The defining feature of the geometric phase is that it depends only on the path traced out by |ν(t) on the Bloch sphere [77,78]. As a consequence, the geometric phase is insensitive to "parallel" errors, i.e., errors that only affect the rate at which the path is traversed and that have no effect on the shape of the path [37,79]. As we show in Appendix B, this property of the geometric phase makes it robust against first-and second-order parallel errors, including certain driving field errors. Note that in contrast, the dynamical phase is generally susceptible to these errors even at first order. The robustness of geometric phases against noise errors is the central idea behind holonomic quantum computation [28]. However, it is important to note that the geometric phase is still sensitive to noise that is "perpendicular" to the path, meaning that the noise deforms the path. Our work concerns the simultaneous correction of these additional errors.
To design an abelian holonomic gate on a qubit based on the geometric phase, we start from a cyclic evolution of a twodimensional system (the same strategy also applies in higher dimensions): where k ∈ {0, 1} and where α k (T ) is the total phase accumulated during the evolution. The parallel transport condition, ψ k (t)| H(t) |ψ k (t) = 0, ensures that the dynamical phase vanishes, so that the total phase is equal to the geometric phase and is therefore robust. In the following, we use the term holonomic evolution to refer to cyclic evolution that satisfies the parallel transport condition to distinguish it from evolution that is merely cyclic. This abelian holonomic evolution is cyclic for both initial states |ψ k (0) with k = 0, 1. This is in contrast to the non-abelian case where it is the manifold, instead of each basis state, that is cyclic [29,30]. Non-abelian gates require auxiliary levels to satisfy the parallel transport condition in the computational manifold [34,41,80]. In this work, we only consider abelian holonomic evolution since it is sufficient to construct arbitrary single-qubit gates. The explicit construction of a holonomic single-qubit gate is as follows. First, parameterize the evolution operator as (3) The columns are the time-evolved computational states: |ψ 0 (t) = e iα(t) cos θ(t) 2 , sin θ(t) 2 e iφ(t) and , where is the transpose operator. It is important to note that these two states pick up opposite geometric phases after cyclic evolution (β g,0 (T ) = −β g,1 (T ) := β g (T )). The evolution path θ(t), φ(t) on the Bloch sphere determines the total accumulated phase, provided the parallel transport condition, , is satisfied. When this is the case, the resulting holonomic evolution operator is then given by where the geometric phase is β g (T ) = − 1 2 T 0 (1 − cos θ)dφ. Although this construction yields a single-axis rotation, arbitrary holonomic gates can be implemented by changing the initial state and Bloch sphere trajectory. In this work, we fo-cus on the initial state |ψ 0 (0) = (1, 0) without loss of generality.
It remains to determine how the qubit should be driven such that it undergoes holonomic evolution. Consider a general three-field Hamiltonian: which includes the Rabi frequency Ω(t), the phase field Φ(t) and the detuning field ∆(t). Interestingly, there is a one-toone mapping between a holonomic trajectory on the Bloch sphere and the control fields that generate it: The algebraic steps that lead to this result can be found in Appendix C. The same result was also derived by Li et al. in Ref. [81]. Given a holonomic path, we can determine the control fields that produce it using Eq. (6).
The so-called orange-slice model holonomic gate [82,83] can be implemented using a two-field control Hamiltonian (∆(t) ≡ 0), where Φ(t) is a step function. The corresponding Bloch sphere trajectory is illustrated in Fig. 1(b). The resulting geometric phase is robust to systematic noise in the driving field Ω(t).

B. Geometric error curves
In addition to errors in control fields, many qubit platforms also suffer from noise fluctuations in the detuning [84][85][86][87][88][89]. Because this noise is transverse to the driving field Ω(t), it is not correctable using the holonomic approach described above. In systems such as semiconductor spin qubits and superconducting qubits, these fluctuations are often slow compared to typical gate times, allowing one to describe them using a quasistatic noise model [84-87, 90, 91]. In this case, the Hamiltonian becomes where δ z is an unknown constant that gives rise to errors in the target gate operation. If δ z is sufficiently small, then its detrimental effects can be ameliorated by designing H c (t) appropriately. Zeng et al. presented a general approach to finding control fields that suppress quasistatic noise errors in the detuning [70,72]. This method utilizes a mapping between qubit evolution and space curves in three dimensions. Here, we refer to these as "error curves" because they quantify the extent to which the qubit deviates from its ideal evolution. In this section, we briefly review this error-curve formalism and adapt it to the noisy three-field Hamiltonian of Eq. (7). In the next section, we show how this technique can be combined with holonomy to produce gates that are insensitive to noise in both the driving field and detuning.
The error-curve formalism begins by transforming to the interaction picture, in which the Hamiltonian becomes H is the evolution operator generated by H c (t). Note that in the ideal case where δ z = 0, the evolution operator U I (t) corresponding to H I (t) would equal the identity at all times. The main idea behind dynamically corrected gates is to engineer H c (t) such that U I (T ) is as close to the identity as possible. Enforcing this condition is made difficult by the fact that it is generally hard to calculate U I (t) analytically. However, if δ z is sufficiently small, we can employ a Magnus expansion, which to first order gives U This function can be expanded in a basis of Pauli matrices: The vector r(t) traces out a three-dimensional space curve as time evolves. Because the length of r(t) quantifies the deviation of U I (t) away from the identity, we call this the error curve. Clearly, we have r(0) = 0. If the error curve closes on itself at the final time T , then U I (T ) = 1 + O(δ 2 z ), and the resulting gate is first-order insensitive to detuning noise. Thus, there is a direct relationship between robust gates and closed error curves.
We can write down an explicit parameterization of the error curve using our general form for U c (t) from Eq. (3): The derivative of the error curve yields another curve called the tangent indicatrix (or tantrix for short): At each time t,ṙ(t) is oriented in the direction that is tangent to the error curve at that point. Note that the tantrix is a unit vector: ṙ(t) 2 = 1, so it lives on a unit sphere. One should be careful to distinguish the tantrix from the projected evolution path on the Bloch sphere that is used to define the geometric phase. The relationship between these two curves plays an important role in the next section. Also notice that because the tantrix is normalized, time coincides with the arc length of the curve. Therefore, the length of the error curve is equal to the gate time T . Three-dimensional space curves are characterized by two real functions: the curvature κ(t) and the torsion τ (t). Given these two functions, the space curve can be generated by integrating the Frenet-Serret equations [70]. Conversely, the curvature and torsion can be computed from the curve. Here, we can use the explicit parameterization in Eq. (9) together with the fact that U c satisfies the Schrödinger equation involving H c to relate these quantities to the control fields (see Appendix E): We see that the curvature and torsion of the error curve are given by the driving amplitude, Ω(t), and by the difference of the derivative of the phase field and the detuning,Φ(t) − ∆(t), respectively. As an example, in Fig. 2 we show two error curves with ∆ = 0 = Φ, where in one case Ω(t) is a square pulse, and in the other a hyperbolic secant (sech) pulse. Notice that the error curve for the square pulse is a semicircle, reflecting the fact that the curvature is constant in this case. The long straight segments of the sech error curve correspond to the long tails of the sech pulse. The form of the error curve in the square pulse case allows us to understand pictorially the sensitivity of the orange-slice model holonomic gate [51,53,83] to detuning noise. This gate is implemented using a two-field control Hamiltonian that evolves states sequentially along two geodesic lines that join together at the two poles of the Bloch sphere: T1 Ω 2 (t)dt = π gives the two pole-topole evolution paths. Switching Φ from 0 to Φ 0 when the state reaches the south pole at time T 1 causes the system to return to the north pole along a different geodesic, yielding a closed "orange-slice" trajectory overall. This is depicted in Fig. 3 for Φ 0 = 0 and Φ 0 = π/2. The resulting rotation angle of the gate is determined by the solid angle enclosed by the slice, which in turn depends on Φ 0 . These gates tend to be robust to systematic errors in the pulse Ω(t) that are parallel to the  (12)). The upper (lower) plots correspond to Φ0 = 0 (Φ0 = π/2). The curves are colored to indicate which part of the Bloch sphere trajectory corresponds to which part of the error curve, starting from red at t = 0 and ending with violet at t = T . path [51,53]. However, the improvements afforded by this approach are generally sensitive to the details of how the gate is implemented. These subtleties are discussed in Appendix D. Fig. 3 also shows the corresponding error curves for both values of Φ 0 . We see that for Φ 0 = 0, the error curve is closed, indicating that first-order detuning noise errors are cancelled. On the other hand, for Φ 0 = π/2, the error curve is not closed, and so detuning errors are not corrected in this case. More generally, the error curve does not close for any nonzero value of Φ 0 . In these cases, the error curve consists of two semicircles that lie in planes that are rotated relative to each other by angle Φ 0 . The intersection point at t = T 1 is a singular point with infinite torsion (Φ(T 1 ) = ∞). Note that replacing the square pulses with other single-pulse waveforms (e.g., hyperbolic secant or Gaussian pulses) cannot make the error curve close as long as Φ 0 = 0.
Finally, we note that different Hamiltonians can generate the same error curve. To see this consider transforming to a frame defined by the the detuning field (with transforma- σzdt ), in which case we obtain a two- and H c (t) map to the same error curve, because the transformation between them commutes with the noise term in Eq. (7).

A. Single-qubit DoG gates
We saw in the case of the orange-slice model that there exist qubit evolutions (albeit trivial) which are both holonomic and have closed error curves (see Fig. 3). However, we also saw that holonomic trajectories h(t) on the Bloch sphere do not generically translate to closed error curves. This leads to the question: Is there a systematic way to find nontrivial holonomic evolutions that have closed error curves? If so, this would enable the design of dynamically corrected gates that correct both pulse and detuning errors. We now show that this is indeed possible, and we present an explicit procedure for constructing such gates.
We can always map a holonomic trajectory parameterized by θ(t) and φ(t) onto an error curve by imposing the parallel transport condition in Eq. (10), which yields a restricted form for the tantrix: (13) If we consider a closed trajectory for h(t) that starts and ends at the north pole of the Bloch sphere at times t = 0 and t = T , respectively, then this implies θ(0) = θ(T ) = 0. This in turn means that the tantrix must be closed, withṙ(T ) = r(0) =ẑ. This condition can always be satisfied if the error curve is smooth and closed, because in this case the tantrix will be continuous, and we can always perform a rigid rotation to align the initial and final tangent vectors withẑ. However, it is not easy to design a holonomic evolution h(t) such that the corresponding error curve obtained by integrating Eq. (13) is closed.
To circumvent this difficulty, we can instead start by choosing a smooth, closed error curve r(t). Eq. (13) implies that this maps to a unique holonomic trajectory h(t), which can be obtained by differentiating r(t) and then extracting θ(t) and φ(t) from the result. The control fields can then be obtained using Eq. (6). These equations can be recast in terms of quantities obtained directly from the error curve. The general procedure can then be summarized in terms of the following four steps: and such that the tantrix is normalized, ṙ(t) = 1.

Compute the holonomic control fields using
where τ (t) is the torsion of the error curve, which is given in Eq. (11).
3. If desired, the holonomic trajectory on the Bloch sphere h(t) can be obtained from 4. The geometric phase is given by We refer to the resulting gates as doubly geometric (DoG) gates.
Before we demonstrate this technique with explicit examples, we point out that the above procedure reveals that there is a unique holonomic trajectory associated with each smooth closed error curve. In contrast, there are infinitely many cyclic (non-holonomic) trajectories on the Bloch sphere that can be associated with the same closed error curve. A distinct geometric phase can be defined for each of these non-holonomic trajectories. In the absence of the parallel transport constraint, it is not possible to uniquely relate the curvature and torsion of the error curve to the three fields of the control Hamiltonian H c (t). This is evident from Eq. (11), where the torsion depends only on the differenceΦ(t) − ∆(t). Two Hamiltonians that have distinct Φ(t) and ∆(t) but the same Ω(t) anḋ Φ(t) − ∆(t) will generate the same error curve but different Bloch sphere trajectories. The infinite family of cyclic evolutions associated with a particular error curve are related to each other via unitary transformations that commute with the error term δ z σ z .
It is also important to note that the above procedure, as stated, generates arbitrary rotations about the z axis. This is easily generalized to arbitrary rotation axes by designing the error curve such thatṙ(T ) =ṙ(0) =ẑ. Other choices of the initial tangent vector correspond to initial states for the holonomic evolution that differ from the logical basis states, i.e., h(t) starts away from the poles of the Bloch sphere. Note that even though such a curve might be equivalent to a z-basis curve in terms of its curvature and torsion, the parallel transport conditions will be different, resulting in different control fields and Bloch sphere trajectories. In addition to designing a new curve with different boundary conditions, one can also generate other types of gates by starting from a z-basis curve and redefining the start/end point to lie elsewhere on the curve. This will again result in h(t) starting away from the Bloch sphere poles. Note, however, that if one wants a control field that starts with zero amplitude, then this may restrict which points along an error curve can serve as the start/end point.
We now construct a class of DoG gates by modifying the orange-slice model. In particular, we generalize it from single-pulse to multi-pulse driving along each geodesic. The pulses along each geodesic vary in amplitude and sign but combine to generate a net π rotation that drives the system Each DoG gate consists of two pole-to-pole evolutions along different geodesic lines on the Bloch sphere. Each pole-to-pole evolution is generated by four sech pulses that collectively implement a π pulse. Each closed r(t) consists of two closed planar lobes that correspond to each pole-to-pole evolution. The colors indicate which part of the curve corresponds to which part of the pulse.
from one pole of the Bloch sphere to the other. One can also design the pulses in each half of the evolution such that the error curve forms a closed planar curve. The two sets of pulses (one set for each geodesic) together generate a closed holonomic trajectory h(t) and a closed error curve r(t). The extended orange-slice DoG gate always has a closed error curve, in contrast to the standard orange-slice model. These driving fields and their corresponding error curves are shown in Fig. 4. The DoG method affords tremendous flexibility in terms of the pulse shapes that can be used since we can choose any smooth, closed error curve r(t). In particular, we can ensure that the control waveforms are experimentally friendly, which is crucial for practical implementations. With this in mind, we focus on designing DoG gates based on sech or sech-like pulses Ω(t), which, due to their analytical properties, have been proposed for quantum gates [92][93][94] and used in experiments with quantum dots [95] and superconducting qubits [96]. More details about the control fields and error curves in Fig. 4 can be found in Appendix F. Like the original orange-slice model, the above class of DoG gates is based on restricting the field Φ(t) to be piecewise constant, which corresponds to error curves that have zero torsion everywhere except at a single point. Here, we instead consider an entirely different class of DoG gates in which the torsion is allowed to vary continuously throughout the curve rather than only in the vicinity of a single point. In this case, the error curves are truly three-dimensional, and not locally two-dimensional like in the case of the extended orange-slice model. We thus refer to the former as 3D DoG gates, and the latter 2D DoG gates. As an explicit example of a family of 3D DoG gates, we again start from a planar FIG. 5. Twisted error curves r ξ (t) for three values of the twist parameter ξ: π/1000 (left), π/3000 (middle), and π/5000 (right). As ξ is reduced to zero, the curve flattens out and lies in a vertical plane. Note thatṙ ξ (T ) =ṙ ξ (0) =ẑ (corresponding to the point where the red and purple segments meet) for all values of ξ.  curve with sech curvature. This time, however, we continuously twist the curve about the z axis so that it fills all three dimensions. The twisting causes the curvature to deviate from a sech function, and it creates nonzero torsion. All three control fields are then nonzero in this case. The precise construction of this family of three-dimensional error curves is as follows. We start from an untwisted planar curve r 0 (t) = y(t)ŷ+z(t)ẑ (here we choose it to lie in the yz plane for concreteness). We then obtain a twisted version of the curve from r ξ (t) = −(y − π/2) sin(ξz 3 )x + (y − π/2) cos(ξz 3 )ŷ + zẑ, where we write y = y(t) and z = z(t) for brevity, and the π/2 shift in y is included so that the twist is about the line parallel toẑ that bisects r 0 (t). The "twist constant" ξ controls the amount of twisting. Because the tantrix of the twisted curve is not normalized, ˙ r ξ (t) = 1, the curve must be reparameterized after the twist to restore t as the arc-length. We denote by r ξ (t) the curve we obtain after this reparameterization. Details about this step can be found in Appendix G. The curvature of r 0 (t) is equal to two sequential sech functions, each given by Ω(t) = Ω 0 sech(Ω 0 t) with Ω 0 t ∈ [−10, 10]. Larger twist values ξ cause the curvature of r ξ (t) to deviate more strongly from the sech function form it assumes in the untwisted (ξ = 0) case. The twisted r ξ (t) are three-dimensional closed curves. Examples are shown in Fig. 5 for three different values of ξ.
By smoothly changing the twist parameter ξ, we can accordingly smoothly deform both r ξ (t) and h(t) to construct different DoG gates. We use the DoG construction procedure described above to calculate the three control fields that result from a twisted error curve r ξ (t). The detailed algebraic steps are given in Appendix G. In Fig. 6, we plot the control fields for two twist parameters that give the DoG gates U (ξ = π/20000) = diag{e −i1.15π , e i1.15π } and U (ξ = π/2000) = diag{e −i0.41π , e i0.41π }, respectively. The error curves, tantrix curves, and holonomic trajectories on the Bloch sphere used to obtain these control fields are shown in Figs. S2 and S3 of Appendix H. Any geometric phase can be achieved by choosing the twist parameter ξ appropriately, so that this class of curves yields a universal set of single-qubit DoG gates. We note that the geometric phase in the DoG gate is linear in ξ (see Fig. S4); therefore one can easily determine what twist value is needed given a target geometric phase.
The DoG construction guarantees that the gates are more robust to detuning errors compared to more standard holonomic gate designs. We calculate the 3D DoG gate fidelity F = 1 6 Tr(U † r U r ) + 1 6 |Tr(U † i U r )| 2 [97] (U i and U r represent ideal and noisy gates, respectively) of U (ξ = π/2000) and U (ξ = π/20000) in the presence of a small detuning error δ z . For comparison, we also compute the fidelities of the same gates, but this time designed using the original orange-slice model. As Fig. 7 shows, the designed 3D DoG gates provide substantial robustness to detuning errors compared to the standard holonomic gates. In the case of the DoG gates, the fidelities for the two target gates shown in the figure are almost the same due to the fact that the error curves are nearly identical in these two cases. In contrast, the fidelity of the standard orange-slice holonomic gate depends more on the target gate; this is because the openness of the error curve depends on which gate is being performed in this case.
The 3D and 2D DoG gates have a similar tolerance to detuning errors since they both correspond to closed error curves. Their tolerance to errors in the pulse amplitude Ω(t), however, is different. We compare the gate fidelity of 3D and 2D DoG gates in the presence of pulse amplitude errors in Fig. 8. We see that which DoG gate family works better depends on the target gate, which is determined by ξ or Φ 0 . For a given target gate, one should then choose the DoG gate family that gives better performance for that particular gate. Note that the 2D DoG gates inherit the same pulse amplitude error robustness from the simple orange-slice holonomic gate (see Appendix D).
One advantage that the 3D DoG gate family has over the 2D DoG gates is that the former does not require pulses that change sign in order to form a closed error curve. This is important for systems in which the sign of the control field is fixed, which for example is the case in singlet-triplet spin qubits [62,63].

B. Quantum speed limits and experimental implementations
The time it takes to perform a quantum operation is fundamentally bounded from below by a quantum speed limit [98][99][100], which is usually determined by the number and structure of the control terms in the Hamiltonian and by the maximum pulse strengths or bandwidths. DoG gates are not an exception. Since the length of the error curve is equal to the gate time, designing the fastest DoG gate relies on designing an error curve with the least total length [73] while respecting curvature constraints that correspond to experimental pulseshaping limitations. In the case of a fully-controllable system such as the three-axis control Hamiltonian given in Eq. (5), a simple way to reduce the gate time is to rescale the curve. When an error curve is scaled down by some factor, the curvature and torsion, and hence the control field amplitudes, in- crease by the same factor, such that the pulse areas, and correspondingly the evolution operator/quantum gate, remain invariant. Thus, the speed limit for each DoG gate can be approached by rescaling the curve until the pulse constraints are saturated. After this rescaling, different curves will deviate from the quantum speed limit by different amounts. In the case of the 2D and 3D DoG gates, the 3D DoG gate is faster for a given pulse amplitude bound. This can be readily explained by the fixed-sign pulses in the 3D model, while the 2D model requires more pulses (eight pulses in Fig. 4) to realize dynamical correction. A natural question arises: For a particular pulse amplitude bound, is there a fastest DoG gate (beyond the two classes of DoG gates presented here)? Because the geometric error curve method is completely general (any pulse that cancels transverse noise corresponds to a closed error curve), this approach is well suited to answer this question. This could potentially be addressed by combining our analytical techniques with numerical optimization [1,2] (notice that a similar case has been studied in Ref. [73]). We leave this to future work.
Since rescaling the error curve amounts to rescaling the driving field amplitudes and the gate time in opposite directions, we choose the maximum pulse amplitude Ω 0 as the basic unit for all dimensionful quantities in this work. The gate fidelities shown in Figs. 7 and Fig. 8 can be interpreted in the context of various experimental platforms, as long as the static noise is small (δ z Ω 0 ). The values of pulse amplitudes and noise levels for several qubit platforms are listed in Table I,  based on which we also listed the evaluated 3D DoG gate time T = 40/Ω 0 = 2π/Ω (considering Ω 0 T = 40 in Fig. 6). In all cases shown in the table, T is well below the coherence time of the given platform. We use an NV center spin qubit in diamond to illustrate how it fits the DoG model. Consider an NV center spin qubit that is driven by 40 MHz microwave pulses [64]. The onsite 14 N nuclear spin constantly dephases the NV center at ∼ 2 MHz through the hyperfine interaction [64]. This corresponds to δ z /Ω ∼ 0.05, in which case the DoG gate achieves > 0.999 fidelity (see Fig.7). The 3D DoG gate time T = 240 ns is much shorter than the qubit coherence time [64]. We can also consider the DoG gate performance for an optically driven NV spin. In Ref. [55], an optical dephasing time of T φ = 18 ns was measured, corresponding to an rms noise value of δ z /2π ∼ √ 2/T φ = 12.5 MHz. Gate times are limited by pulse rise times, which were found to be lowerbounded by 1.2 ns in Ref. [54], implying a maximum average pulse strength ofΩ/2π = 0.5/(2.4 ns) ≈ 208 MHz for the standard orange-slice model. On the other hand, imposing the same rise time constraint on the sech pulses shown in Fig. 6 for the 3D DoG gates yieldsΩ/2π ≈ 106 MHz. Thus, for an optically controlled NV spin, we estimate that δ z /Ω ≈ 0.06 is the lowest possible effective noise strength for the standard orangle-slice holonomic gate, while δ z /Ω ≈ 0.12 for the 3D DoG gate example shown in Fig. 6. From Fig. 7, we see that the fidelity of the 3D DoG gate is still substantially higher than that of the standard holonomic gate despite the increase in gate time and effective noise strength (both are larger by a factor of ∼ 2 compared to the standard orange-slice model). This is a direct consequence of the built-in suppression of transverse noise enjoyed by the DoG gate.

C. Two-qubit DoG gates
Thus far, we have focused on applying the DoG formalism to single-qubit gates. However, both holonomic gates and the concept of error curves can also be applied to multi-level or multi-qubit quantum systems. In the higher-dimensional case, noise cancellation still requires the error curves to close; however, for systems with more than two levels, the curves generally live in higher dimensions [74]. Therefore, we can generalize the DoG formalism to any finite-dimensional system by starting from closed error curves embedded in the appropriate number of dimensions and imposing the parallel transport condition.
Here, we exemplify these ideas by designing two-qubit DoG gates. The concrete example we focus on is a system in which the qubits interact through a tunable coupling described by the following Hamiltonian: where λ z (t) and λ ⊥ (t) represent tunable interaction amplitudes along two directions, Φ(t) is the tunable phase field of the transverse part, and σ (j) µ is the Pauli µ matrix acting on the jth qubit. We assume further that the frequency of qubit 1 is fixed while that of qubit 2 is tunable. Specifically, we let qubit 2 be driven by the following three-field Hamiltonian: where the Φ(t) here is the same one appearing in H couple (t). Qubit 1 is left idle. The total Hamiltonian is then block diagonal as follows: where for brevity we have introduced the following quantities: We take the error Hamiltonian to be H error = δ z σ (2) z , which represents quasistatic fluctuations of the energy splitting of qubit 2 [88,101]. Naively, the error curve for the total twoqubit Hamiltonian, H c (t)+H error , lives in six dimensions [74]. However, this Hamiltonian is block diagonal, and each 2 × 2 block can also be interpreted as an effective two-level system, implying that the six-dimensional curve can be factorized into two three-dimensional curves. Notice that these two curves are not independent because the two blocks both involve the sameΩ(t) and ∆(t). This means that their error curves have the same curvature yet different torsions: Moreover, these two curves must have identical total length since both lengths are set by the evolution time. These geometric constraints can be satisfied by using a pair of geometric curves that we used to construct single-qubit 3D DoG gates, r 1 (t) = r ξ (t) and r 2 (t) = r −ξ (t) (see Fig. 9), with opposite twist parameters. Due to the opposite twist constant ξ, r 1 (t) and r 2 (t) have opposite torsions. Such a torsion symmetry has the extra benefit of reducing the number of independent control fields needed to implement the gate, as will become clear shortly. We can use this pair of curves to design two-qubit DoG gates. For each curve, we identify the unique holonomic evolution and compute the corresponding diagonal control fields, yielding The phase fields are then obtained as Due to the torsion symmetry of such dual curves, two of the fields are identically zero: Consequently, the remaining nontrivial control fields λ z (t), λ ⊥ (t), and Ω(t) are sufficient to realize DoG control in this system. In Fig. 9, we plot the control fields synthesized from ξ = π/2000 dual curves. The control fields give the two-qubit DoG gate where β g,ξ (T ) and β g,−ξ (T ) are the geometric phases of the two subsystems. Another consequence of the torsion symmetry is that these geometric phases are related by a minus sign: β g,ξ (T ) = −β g,−ξ (T ). Different values of ξ give different two-qubit gates (see Fig. S4). ξ = 0.08π/1000 corresponds to β g,ξ (T ) = −1.25π, and the DoG gate is diag{e 3iπ/4 , e −3iπ/4 , e −3iπ/4 , e 3iπ/4 }, which is equivalent to the controlled-Z gate [105]. Notice that β g,ξ (T ) = −1.25π up to an integer multiplies of 2π corresponds to different control fields yet same CZ equivalent gate.
It is interesting to point out that other designs of dual curves without the torsion symmetry, say those used in [74], can require more independent control fields to implement [106]. In Appendix I we also show an alternative approach to constructing two-qubit DoG gates that does not employ dual curves.

IV. CONCLUSIONS
In conclusion, we showed how to combine two types of geometry to design quantum gate operations that are simultaneously robust to multiple types of errors. In particular, we presented a systematic procedure for designing qubit evolutions that exhibit both closed holonomy loops and closed error curves-three-dimensional curves that quantify the effect of transverse noise. In addition, we provided a general recipe for determining the control fields that generate such evolutions, which we refer to as Doubly Geometric (DoG) gates. These gates are robust against both control errors and transverse noise errors, thus extending the error-correcting capabilities of holonomic gate designs. We demonstrated our formalism by constructing several types of single-qubit and twoqubit DoG gates. Our approach provides a new perspective on achieving robust quantum control in the presence of multiple sources of error. In future work, it would be interesting to combine our DoG formalism, which provides a global view of the space of noise-cancelling pulses, with numerical approaches to quantum control [1], and with more insights of various types of noises [107,108]. Combining these methods could yield globally time-optimal pulses that cancel noise while respecting experimental constraints. Even though the dynamical phase is often expressed as the integral of ψ(t)|H(t)|ψ(t) , one must be careful in interpreting this as the integral of the expectation value of the Hamiltonian. Generally, the expectation value of the Hamiltonian is invariant under frame transformations: ψ(t)|H(t)|ψ(t) = ψ(t)|R † (t)R(t)H(t)R † (t)R(t)|ψ(t) for any unitary transformation R(t). The dynamical phase can only be written in terms of an expectation value in the Schrödinger picture, which is the only frame considered in Aharonov and Anandan's work [39]. Here, we show this by starting from the definition of the geometric phase in the projected space. We show that under a basis transformation, the integrand in the dynamical phase should transform according to No matter which frame one works in, the dynamical phase should be defined in terms of the Hamiltonian that generates the cylic evolution, which means that in a rotating frame, one should use the ef- This in turn means that the dynamical phase is not invariant under frame transformations.
We begin by considering the Hamiltonian in the Schrödinger picture: Suppose that this Hamiltonian generates the cyclic evolution where |ψ S (t) is the projected state that defines the geometric phase i ψ S (t)| ∂ t |ψ S (t) and which is cyclic (starts/ends at the north pole of the Bloch sphere). We can subtract the geometric phase from the total phase to obtain (the time derivative of) the dynamical phase: (A2) It is readily shown that this is equivalent to ψ(t)|H(t)|ψ(t) , the expectation value in the Schrödinger picture. Now we define the basis transformation σzdt . It is immediately clear that (i) the transformed evolution is also cyclic, making the geometric phase well-defined in the new frame, and (ii) the state in the rotating frame (labelled by I) is: |ψ I (t) = e iα I (t) cos θ I (t) 2 e iφ I (t) sin θ I (t) 2 = e iα I (t) |ψ I (t) . One can check that the parameters in the two frames are related through: (A3) Accordingly, we can calculate the dynamical phase in the ro-tating frame: ).
(A4) Clearly, the dynamical phase is not invariant under the frame change. Moreover, one can check that it is equal to the integral of ψ I (t)| H eff (t) |ψ I (t) .

Appendix B: Robustness of geometric phases
In this appendix, we examine the robustness of the geometric phase to perturbations in the Hamiltonian.
Following the simple model from [33], we consider a twolevel system with Hamiltonian H = E n |n n|+E m |m m|, E n > E m and state |ψ(t) = ae −iEnt |n +be −iEmt |m with |a| 2 + |b| 2 = 1. At time T = 2π En−Em , the evolution is cyclic: En −Em (a |n + b |m ). The total phase is β total = −2π En En−Em , and the dynamical phase is En−Em (|a| 2 E n + |b| 2 E m ). The geometric phase is β g = β total − β d = −2π|b| 2 . Clearly, the geometric phase depends on the initial state. Now consider a perturbation in the system energy such that both energies are shifted to E n = E n , We can define a dimensionless quantity = (δE − δE )/δE that characterizes the strength of the perturbation. We will now show that if 1, i.e., the perturbation is small compared to the original energy splitting, then the error in the geometric phase vanishes to first order in , while this is not the case for the total phase and the dynamical phase.
The state at time T with the perturbation included is En −Em |m ). The total and dynamical phases become En−Em (|a| 2 E n + |b| 2 E m ). The geometric phase is then Expanding this to first order in , we find We see that the two O( ) terms cancel out, and so the geometric phase is first-order robust against such energy perturbations.
The above analysis is also applicable to the case of Rabi driving.
Parameterizing the state as |ψ(0) = cos θ |e + sin θe iφ |g and considering the case of a real Rabi frequency Ω(t), the evolution operator is U (t) = exp(−i t 0 Ω(t )dt σ x ). The cycle time T is determined from the condition T 0 Ω(t)dt = π. The geometric phase in this case is given by β g = π(1 − sin 2θ cos φ). If we assume the noise is parallel to the evolution path, T 0 Ω(t)dt = π + x , where x 1, then following a similar algebraic procedure reveals that β g = β g +O( 3 x ). However, if the noise is perpendicular to the travel path, say Ω(t)σ x → Ω(t) (1 − x )σ x + z σ z , then one finds that β g contains terms of order O( z ).
Appendix D: Holonomic gates in the presence of pulse errors Despite the robust nature of the geometric phase, there is generally no absolute advantage of holonomic gates over nonholonomic ones. Even in the case of noise that is parallel to the evolution path, it is still possible that holonomic gates exhibit worse gate fidelity compared to non-holonomic ones.
Here we compare the fidelity of the orange-slice holonomic gate with that of a straightforward non-holonomic gate in the presence of pulse errors. We focus on three types of errors: (i) parallel noise, (ii) perpendicular noise, and (iii) Ω noise. In the first two types of noise, the ideal orange-slice evolution trajectory connecting the two poles is preserved but "appended" by a perturbation parallel (or perpendicular) to the ideal geodesic line. The Ω noise will break the ideal evolution path since the second geodesic line will be spoiled if there exists a pulse area error along the first geodesic line. It is worth pointing out that due to different trajectories for the holonomic and non-holonomic gates, what constitutes "parallel" noise for one gate is not necessarily "parallel" for another gate.
We begin by writing explicitly the Hamiltonians for the holonomic and non-holonomic gates, respectively: where Ω and Φ are constants, i.e., both gates are implemented using square pulses.
We first examine the case of "parallel" noise, where the perturbed Hamiltonian can be written as: where represents a small ( 1) deviation in the pulse area caused by noise. Note that these Hamiltonians are meant to serve as effective toy models in which the perturbation has the intended consequence on the evolution, e.g., in H , HG (t) the noise does not necessarily happen only on the second geodesic line, but could arise along the first line instead (but in Ω and Φ) such that the ideal trajectory is preserved until the state returns to north pole. The gate fidelities [97] for the holonomic and non-holonomic gates are F HG = 1 3 (2 + cos π ), and so we find that for parallel noise, the non-holonomic gate fidelity depends on the gate angle Φ, while the fidelity of the holonomic gate does not. The relative performance thus depends on Φ.
Next we consider "perpendicular" noise, where the per-turbed Hamiltonians are now The fidelity is readily calculated: where we have kept terms up to O( 2 ). We see that the holonomic gate outperforms the non-holonomic one when Φ > 0.595π. It is interesting to point out that for non-abelian quantum holonomy, where an ancillary level is required [34,41], nonunitary errors occur when the cyclicity is broken [109,110], which could reduce the gate fidelity below the non-holonomic one.
Appendix E: Geometric formalism for dynamically corrected gates The first-order term in the Magnus expansion of the interaction-picture evolution operator U I (t) and its derivatives are The explicit form of the error curve and its derivative (the tantrix) are given in Eqs. 9 and 10 of the main text. To obtain the curvature and torsion from the error curve, we use the dimension-scaled Frobenius norm of matrices defined as Using that AU F = A F for arbitrary unitary U , we have So, Ω(t) is the curvature κ(t) = r(t) of error curve r(t).
Next, using the resulṫ we obtain

−2i
Tr Geometrically, it is also equivalent to which is the torsion of the error curve.
Appendix F: DoG gates from an extended orange-slice model In this appendix, we provide additional details about the DoG gate shown in Fig. 4, which is based on a modified orange-slice model. In this example, the driving field is constructed from 8 hyperbolic secant pulses, as shown in the figure. This 8-pulse sequence is obtained by applying the following 4-pulse sequence twice in succession: 2 sech(20.6 − u) 15.6 ≤ u ≤ 25.6 (F1) Here, u = Ω 0 t. The first 4-pulse sequence drives the system along a geodesic from the north pole to the south pole of the Bloch sphere, while the second sequence takes the system along a second geodesic back to the north pole. Which geodesic is traversed during the return trip is controlled by the value of Φ(t) = Φ 0 . The error curve generated by the 4-pulse sequence (one planar lobe of the whole 3D closed error curve in Fig. 4) is shown in Fig. S1.
Appendix G: DoG gates from twisted three-dimensional error curves Here we discuss details of the DoG gate construction based on twisted three-dimensional error curves r ξ (t). An important aspect of this procedure is that after one constructs a closed error curve r ξ by twisting r 0 , one needs to restore the arc-length parameterization to obtain the control fields that implement the DoG gate.
Suppose we construct r ξ =0 (t) by twisting r 0 (t). It is important to note that the arc-length parameterization t of r 0 (t) is not the same as that of the twisted curve r ξ =0 . This is evident considering the arc-length on r 0 (t) is not invariant after the non-rigid body twist. If r ξ (w) is parameterized by w, then the arc-length parameterization is obtained from t(w ) = w w min dx(w) dw 2 + dy(w) dw 2 + dz(w) w 2 dw, where w min ≤ w ≤ w max , and x, y, z are the components of r ξ (w).
After performing the integration, we can invert the result to obtain r ξ (t) = r ξ (w(t)). Hereafter, we will use the w parameterization (w = t for r 0 (t)) for calculations; w is the arc-length only for the untwisted curve.

Appendix H: 3D DoG gate
In the main text, we show the error curves (Fig. 5) and control fields (Fig. 6) that generate 3D DoG gates with different r  (t): h(t): FIG. S2. Error curve r ξ (t) with ξ = π/20000, and the corresponding tantrixṙ ξ (t) and the evolution trajectory on the Bloch sphere h(t).
In Fig. S4 we show the relationship between the twist parameter ξ and the geometric phase encoded in the DoG gate. It is apparent from the figure that different ξ values yield different geometric phases.