Quantum annealing with twisted fields

Quantum annealing is a promising method for solving combinational optimization problems and performing quantum chemical calculations. The main sources of errors in quantum annealing are the effects of decoherence and non-adiabatic transition. We propose a method for suppressing both these effects using inhomogeneous twist operators corresponding to the twist angles of transverse fields applied to qubits. Furthermore, we adopt variational methods to determine the optimal inhomogeneous twist operator for minimizing the energy of the state after quantum annealing. Our approach is useful for increasing the energy gap and/or making the quantum states robust against decoherence during quantum annealing. In summary, our results can pave the way to a new approach for realizing practical quantum annealing.


Introduction
Quantum annealing (QA) [1,2,3,4,5], which has attracted considerable attention in recent decades, was originally used as a method for solving combinational optimization problems. It is well known that such problems can be mapped to finding the ground states of Ising Hamiltonians [6,7,8]. In QA, we prepare a ground state of a Hamiltonian of a transverse field, which is called a driving Hamiltonian; then, we let the system evolve with a time-dependent Hamiltonian to change from the transverse field to the problem Hamiltonian. As long as an adiabatic condition is satisfied and the Hamiltonian contains matrix elements to induce transitions between the initial state and the target state, the ground state of the problem Hamiltonian can be prepared after the dynamics. By measuring the ground state, we can obtain the solutions of combinatorial optimization problems.
Furthermore, many studies have attempted to use QA for quantum chemical calculations. The Hamiltonian of molecules is written in the second quantized form.
There are methods for transforming the Hamiltonian of the second quantized form into that of qubit forms [9,10,11,12,13]. In quantum chemistry, high accuracy is required in the calculation of molecular energy, which is referred to as chemical accuracy. Knowledge of energy with chemical accuracy is essential for predicting the chemical reactions of molecules [14].
There are several other applications of QA. For example, QA has been applied to clustering [15,7]. Further, a method that uses QA to perform calculations for topological data analysis (TDA) has been reported [16]. In addition, QA has been investigated for solving the shortest-vector problem, which is a candidate for postquantum cryptography [17].
D-Wave Systems Inc. has realized QA machines composed of thousands of qubits [18]. Superconducting flux qubits have been employed in these machines. Many experimental demonstrations of QA have been performed using these machines, including machine learning, and graph coloring problems [19,20,21,22].
Although considerable effort has been devoted toward identifying useful applications of QA, many obstacles are yet to be overcome for using QA to solve practical problems. In particular, there are two major obstacles: decoherence and non-adiabatic transitions [23]. To suppress decoherence, we need to implement QA with a shorter time schedule. However, as the annealing time becomes shorter, more non-adiabatic transitions will occur during QA. This trade-off makes it difficult to use QA for solving practical problems.
When the problem Hamiltonian is of the Ising type with only diagonal terms, we randomly obtain the ground state of the problem Hamiltonian after QA by performing measurements in the computational basis. The density matrix after QA is expressed as ρ = j p j |E j E j |, where p j denotes the population and |E j denotes an eigenvector of the problem Hamiltonian. In this case, the probability of obtaining the ground state depends on the population of the ground state. Thus, if the ground-state population is finite, we can obtain the ground state by increasing the number of trials.
By contrast, if we choose a Hamiltonian with off-diagonal matrix elements as the problem Hamiltonian, we cannot estimate the energy of the Hamiltonian by performing measurements in the computational basis. In this case, we need to estimate the energy of the Hamiltonian by performing the Pauli measurements. We consider the case in which the Hamiltonian is composed of the summation of the products of the Pauli matrices, such as H = i c i σ i , where σ i is the Pauli product and c i is the coefficient. We obtain the expectation value of each term by performing measurements of the Pauli products in the quantum states after QA, and we take the sum of the expectation values of all the terms. The energy of the Hamiltonian for a density matrix ρ is given by H = Tr[Hρ] = n p n E n , and we obtain the expectation values of the Hamiltonian H by performing a large number of measurements. Hence, if there is a population in the excited state, the energy measured experimentally is different from the ground-state energy. Therefore, we need to prepare a density matrix close to the exact ground state in order to determine the ground-state energy with high accuracy.
In this paper, we propose a method for suppressing both decoherence and nonadiabatic transitions by using inhomogeneous twist operators that change the angles of the transverse fields during QA. We define inhomogeneous twist operators that rotate the direction of the transverse fields of the driving Hamiltonian, and we also define the twist parameters that correspond to the rotation angle at each qubit. Further, we apply these operators to the driving Hamiltonian.
By using this twisted driving Hamiltonian, we can implement QA for the given twist parameters and measure the energy of the state after QA. To minimize the energy, we update the parameters by using, e.g., gradient descent methods, and we perform QA again with different twist parameters. By repeating these processes, we can obtain the ground-state energy, which is lower than that obtained using conventional QA. Through numerical simulations, we demonstrate that our approach suppresses the effect of decoherence and non-adiabatic transitions in QA for some problem Hamiltonians.
The remainder of this paper is organized as follows. Sections 2 and 3 review QA and gradient descent, respectively. Section 4 introduces our scheme with twist operators. Section 5 describes numerical simulations conducted to evaluate the performance of our scheme and shows that, for some problem Hamiltonians, the ground-state energy obtained using our scheme is more accurate than that obtained using the conventional scheme. Finally, Section 6 concludes the paper.

Quantum Annealing
Here, we review QA for the ground-state search [3]. We choose the driving Hamiltonian H D as the transverse field (i.e., H D = − N i=1σ x i ). The total Hamiltonian is described as follows: where T is the annealing time, H D is the driving Hamiltonian, and H P is the problem Hamiltonian. We prepare the ground state of the driving Hamiltonian. The driving Hamiltonian is adiabatically changed into the problem Hamiltonian. If the dynamics is adiabatic, the adiabatic theorem guarantees that we can obtain the ground state of the problem Hamiltonian. The accuracy of QA is degraded by many types of noise. The relevant types are environmental decoherence and non-adiabatic transitions [23,24,25,26,27,28,29,30]. For the suppression of non-adiabatic transitions, it is necessary to implement QA with a longer time schedule. However, as the annealing time becomes longer, the decoherence effects become more significant during QA. Owing to this trade-off, it is not straightforward to solve practical problems using QA.
Several methods for suppressing decoherence and non-adiabatic transitions have been investigated. Susa et al. proposed a way to accelerate the annealing process using an inhomogeneous driving Hamiltonian for a specific case [31,32]. It is known that "non-stoquastic" Hamiltonians with negative off-diagonal matrix elements improve the performance of QA for some problem Hamiltonians [33,34]. Direct estimation of the energy gap between the ground state and the first excited state by QA has been proposed [35], and this method is robust against non-adiabatic transitions. In addition, considerable effort has been devoted toward suppressing the effect of environmental noise. Error correction of QA has been investigated to suppress decoherence [36]. In addition, the idea of using a decoherence-free subspace for QA has been proposed [28,37]. Spin lock techniques can be adopted to use long-lived qubits for QA [38,39,40]. Furthermore, several methods using non-adiabatic transitions and quenching for efficient QA have been studied [41,42,43,44,45,46,47]. Other approaches have also been proposed to suppress non-adiabatic transitions and decoherence by using variational methods [48,49,50]. It is worth noting that such variational methods have been adopted to find a ground state of the Hamiltonian by using variational algorithms with near-term intermediate-scale quantum (NISQ) devices [51,52].

Gradient descent
Here, we review the basic gradient descent method. The gradient descent method is a method that searches for the lowest value of the cost function by the gradient. It consists of four steps. First, we determine the learning rate that indicates by how much we can change the parameters when we update them. Second, we derive the gradient of the cost function. When we cannot obtain the gradient of the cost function analytically, we need to use numerical differentiation. Third, we update the parameters using the gradient and learning rate as follows: where f is the cost function, α is the learning rate, and a (0) and a (1) are the initial and updated parameters, respectively. Fourth, we repeat the second and third steps until the cost function converges to a specific value.

Our variational twisting scheme
Here, we introduce our scheme for using twist operators with QA. By deforming the driving Hamiltonian with an inhomogeneous twist operator, we aim to obtain the ground-state energy with higher accuracy than that obtained using conventional QA. The inhomogeneous twist operator consists of several parameters, which we refer to as twist parameters. To find the optimal twist parameters for an efficient groundstate search, we use the so-called variational methods, where we adaptively update the parameters according to the measurement results after QA.

Inhomogeneous twist operator
Let us consider the problem Hamiltonian composed of L qubits. Let σ x j , σ y j , and σ z j denote the standard Pauli matrices at the j-th site. Then, the inhomogeneous twist operator is defined by where L is the number of qubits and {θ j } L j=1 are the twist parameters. We define a single rotational operator of the y-axis at the j-th site as In addition, we define the inhomogeneous twist operator as Further, we deform the driving Hamiltonian with the inhomogeneous twist operator.
The key idea of our scheme is to use the deformed driving Hamiltonian for QA as follows: The energy spectrum of this total Hamiltonian is changed by the twist parameters.

Variational QA with gradient descent
Here, we explain how to apply gradient descent with our scheme. Let E (ann) (T, θ 1 , · · · , θ L ) denote the energy that we measure after QA using the deformed annealing Hamiltonian (6). Our scheme consists of three steps. First, to obtain the derivative of E (ann) (T, θ 1 , · · · , θ L ) with respect to {θ j } L j=1 for a given T , we set the inhomogeneous twist operators with some twist parameters, perform QA with the deformed Hamiltonian, and measure the energy of the state after QA. It is worth noting that we cannot analytically obtain the derivative of E (ann) (T, θ 1 , · · · , θ L ); hence, we use numerical differentiation. Second, we update the twist parameters on the basis of the results of step 1. Third, we repeat steps 1 and 2 until the energy converges to a finite value. The entire procedure is summarized in Figure 1.
It is worth noting that by performing the scheme shown in Figure 1 for several values of the annealing time, we can find the optimized annealing time that minimizes E (ann) . This optimized annealing time is denoted by T (opt) .

Numerical Results
This section describes numerical simulations conducted to evaluate the performance of our scheme. In particular, to account for decoherence, we employ the Lindblad master equation. For the problem Hamiltonians, we consider two examples: a hydrogen molecule and a deformed spin star model.

Step1 numerical differentiation
Step2 update twist parameter Step3 repeat Step1 and Step2 !"" where is given by the QA Figure 1: Schematic of gradient descent for twisted QA. Here, α denotes the learning rate.

Lindblad master equation
In this subsection, we introduce the Lindblad master equation to consider the decoherence during QA. The Lindblad master equation that we use in this paper is given by where σ (k) j (k = x, y, z) denote the Lindblad operators acting at site j, γ denotes the decoherence rate, and ρ(t) is the density matrix of the quantum state at time t. We solve the Lindblad master equation using QuTiP [53,54]. Throughout this paper, we choose σ z j as the Lindblad operator because this type of noise is considered as the main source of decoherence for the qubits used in QA [55].

Hydrogen molecule
In this subsection, we discuss the numerical results obtained using a hydrogen molecule as the problem Hamiltonian. In our numerical simulations, the dynamics of the state strongly depends on the annealing time.
First, we introduce the hydrogen molecule. The Hamiltonian of the hydrogen molecule is described by the second quantized form. We map the Hamiltonian with the second quantized form to a spin Hamiltonian by the Jordan-Wigner transformation. The Hamiltonian of the hydrogen molecule is given by y 1σ x 2σ y 0σ x 1σ x 2σ y 3 + h 14σ x 0σ x 1σ y 2σ where we use the STO-3G basis and Jordan-Wigner transformation. The coefficients h 0 , h 1 , · · · , h 14 of the Hamiltonian in Eq. (8) depend on the interatomic distance. We obtain these coefficients of the Hamiltonian expressed by the spin in Eq. (8) using OpenFermion for each interatomic distance. We choose the interatomic distance as 0.74 A, and the coefficients of the Hamiltonian with this interatomic distance are listed in Table 1. It is known that the ground state of the Hamiltonian of the hydrogen molecule is very close to the separable state using the Hartree-Fock approximation. In this case, as will be discussed later, the twist parameters tend to be chosen such that the ground states of the driving Hamiltonian and problem Hamiltonian are very close. We conduct numerical simulations to quantify the performance of our scheme, where we use inhomogeneous twist parameters for the driving Hamiltonian to lower the energy in a variational manner. For comparison, we also perform numerical simulations with conventional QA, where the driving Hamiltonian is chosen as the transverse field. We set γ = 10 −4 and α = 0.05. Furthermore, the number of steps is 200. We plot the energy spectrum of the annealing Hamiltonian for each scheme in Figure 2. We observe that the twist operations increase the energy gap between the ground state energy and the first excited state energy. In this paper, we define an estimation error as the difference between the true ground state energy and the measured energy after QA. If our scheme provides a smaller estimation error than the conventional scheme, it is considered to be more accurate than the conventional scheme. In Figure 3, we plot the estimation error against the number of variational steps and annealing time using either our variational scheme with the optimal variational parameters or the conventional approach, and we find that the estimation error of our scheme is one order of magnitude smaller than that of the conventional scheme. In addition, we find that the optimal annealing time for minimizing the energy in our scheme is shorter than that in the conventional approach.  When we set a short annealing time, our variational method tends to choose a driving Hamiltonian whose ground state has a large overlap with the target ground state of the problem Hamiltonian. By contrast, when we set a long annealing time, our method tends to choose a driving Hamiltonian whose ground state is robust against decoherence.
Let | ϕ drive |ϕ prob | denote the overlap, where |ϕ drive denotes the ground state of the driving Hamiltonian and |ϕ prob denotes the ground state of the problem Hamiltonian. In Figure 4 (a), we plot the overlap between the initial state of twisted QA and the ground state of the problem Hamiltonian. It is worth noting that this overlap can be large only when the ground state of the problem Hamiltonian is close to the product states. From Figure 4 (a), we find that the overlap becomes especially large for a short annealing time. To investigate the reason for this increase, we use the so-called purity, which is known as a measure for quantifying the effect of decoherence. It is defined by where ρ is a density matrix. For a pure state, the purity becomes 1, whereas it becomes exponentially small against the number of qubits for a completely mixed state. We plot the purity to quantify the effect of decoherence (see Figure 4 (b)). In conventional

Energy error [GHz]
Step variational twist conventional (a) Estimation error of the energy against the variational step  QA, as we increase the annealing time, the purity decreases owing to decoherence. By contrast, in our scheme, the decoherence effect is negligible. This is probably because both the initial state of the driving Hamiltonian in our scheme and the ground state of the problem Hamiltonian are nearly eigenstates ofσ z , which is robust againstσ z noise. Furthermore, we analyzed a so-called adiabatic condition. If the following quantity A j is much smaller than 1 for all j, the adiabatic condition is satisfied [23,24,25,56]: where the numerator denotes the transition matrix elements of the derivative of the Hamiltonian from the ground state to the j-th excited state and the denominator denotes the energy gap between the ground state and the j-th excited state. We plot the energy gap between the ground state and the first excited state(see Figure 5 (a)). We can see that our method increases the energy gap between the ground state and the first excited state. Similarly, the energy gap between the ground state and the second excited state is increased in our scheme, as shown in Figure 5 (b). Furthermore, we plot the transition matrix that corresponds to the numerator of A j for conventional QA and our method in Figure 6 (a) and (b), respectively. We find that the transition matrix in our scheme is around two orders of magnitude smaller than that in the conventional one. Therefore, in the case of the hydrogen molecule, our method is advantageous in all aspects, namely the effects of decoherence, the energy gap, and the transition matrix of the derivative of the annealing Hamiltonian.

Deformed spin star model
In this subsection, we consider a deformed spin star model as the problem Hamiltonian. In contrast to the case of the hydrogen molecule, the ground state of the deformed spin star model is highly entangled, and the overlap between the initial ground state of the twisted driving Hamiltonian and the ground state of the problem Hamiltonian cannot be large regardless of the twist parameters. The deformed spin star model Hamiltonian is given by whereĴ + ≡ N j=1 e 2π j N σ + j andĴ − ≡ N j=1 e −2π j N σ − j . This model has been studied to represent a hybrid system composed of a superconducting flux qubit and nitrogenvacancy centers in a diamond lattice [57,58,59,60,61,62]. It is known that the ground state of the deformed spin star model with ω = ω 1 is As this state is highly entangled, an overlap with a product state created by the driving Hamiltonian in our scheme cannot be large. We set γ = 10 −4 , α = 0.001, J = 15, and ω = ω 1 = 1. Further, the number of steps is 500. We plot the energy spectrum of the annealing Hamiltonian at each time in Figure 7. From this graph, the energy spectrum does not seem to have changed significantly; however, we observe that the energy gap between the ground state and the excited states in our scheme is larger than that in the conventional scheme, as shown in Figure 10 (a).
In Figure 8, we plot the estimation error against the number of variational steps and the annealing time when we adopt either twisted QA or conventional QA. From these plots, we find that our scheme improves the accuracy by an order of magnitude compared to the conventional scheme.
In Figure 9 (a), we plot the overlap between the initial state of twisted QA and the ground state of the problem Hamiltonian. From this Figure, we confirm that the overlap

Energy [GHz]
Step min variational twist exact min conventional with the deformed spin star model is smaller than that with the hydrogen molecule. We investigate the effects of decoherence and non-adiabatic transitions. First, we plot the purity to show the effect of decoherence in Figure 9 (b). We can see that the purity of our scheme is slightly higher than that of the conventional scheme. However, as the difference in purity between them is small, we conclude that our scheme cannot significantly suppress the effect of decoherence in this case. Furthermore, we show the energy gap between the ground state and the first excited state in Figure 10 (a). Comparing the smallest energy gaps in this graph, we can see that the difference between our method and the conventional method is around two orders of magnitude. In the case of the energy gap between the ground state and the second excited state, the results obtained for the conventional scheme and our scheme are nearly the same.  Energy gap between the ground state and the second excited state. In (a) and (b), the learning rate α = 0.001, the decoherence rate γ = 10 −4 , and the number of steps is 500.
Finally, we consider the transition matrix elements of the derivative of the Hamiltonian from the ground state to the j-th excited state. The transition matrices between the ground state and the first and second excited states are plotted for conventional QA and our method in Figure 11. The difference between the conventional method and our method is rather small.
From these results, we conclude that the improvement in the accuracy of our scheme arises from the increase in the energy gap owing to the twisting operations.

Conclusion
In this paper, we proposed a variational method for determining a suitable driving Hamiltonian for QA. We employed a parameterized twist operator to change the driving Hamiltonian, where each spin was rotated with some angle characterized by the twist parameters. Starting from the conventional (transverse-field) driving Hamiltonian, we updated the parameters to minimize the energy of the state after QA until the energy converged to a certain value. We found that the behavior of the states in our scheme strongly depends on whether the ground state of the problem Hamiltonian is close to a product state or a highly entangled state. If the ground state of the problem Hamiltonian is close to a product state, our variational method tends to find a driving Hamiltonian whose ground state has a large overlap with the target ground state. By contrast, if the ground state of the problem Hamiltonian is highly entangled, our method tends to find a driving Hamiltonian that has a larger energy gap during QA. In summary, our QA approach of using variational methods with twist operators can estimate the ground state energy of the problem Hamiltonian with higher accuracy than conventional QA.