A Rydberg-atom approach to the integer factorization problem

The task of factoring integers poses a significant challenge in modern cryptography, and quantum computing holds the potential to efficiently address this problem compared to classical algorithms. Thus, it is crucial to develop quantum computing algorithms to address this problem. This study introduces a quantum approach that utilizes Rydberg atoms to tackle the factorization problem. Experimental demonstrations are conducted for the factorization of small composite numbers such as $6 = 2 \times 3$, $15 = 3 \times 5$, and $35 = 5 \times 7$. This approach involves employing Rydberg-atom graphs to algorithmically program binary multiplication tables, yielding many-body ground states that represent superpositions of factoring solutions. Subsequently, these states are probed using quantum adiabatic computing. Limitations of this method are discussed, specifically addressing the scalability of current Rydberg quantum computing for the intricate computational problem.


I. INTRODUCTION
Modern cryptosystems using public-key distribution rely on the fact that finding prime factors, p and q, of a given semi-prime integer, n = p × q, is computationally inefficient in classical computation [1].On a quantum computer, Shor's algorithm is expected to run in a poly-logarithimic time of n, i.e., to solve the factorization problem efficiently [2,3].Experimental tests of Shor's algorithm for small integers have been conducted on various quantum gate-based computers, including those using NMR [4], trapped ions [5], superconductor qubits [6,7], and photons [8,9].Improvements are expected in gate fidelity and system size to facilitate factorization of larger numbers.An alternative approach is provided by quantum adiabatic computing [10], where the integer factorization problem is encoded into the Hamiltonian of a quantum many-body system, which allows the prime factors to be obtained by adiabatically driving the system to its ground state.Scalable experiments of quantum adiabatic methods have been carried out with NMR systems [11,12] and on commercially accessible platforms such as IBMQ [13] and D-Wave [14].These experiments utilize quadraticunconstrained-binary-optimization (QUBO) to encode the factorization problem into Hamiltonians.
This paper aims to utilize Rydberg-atom graphs to program the integer factorization problem and to determine the integer factors experimentally.The procedure involves an efficient two-step reduction algorithm that transforms the integer factorization problem, via (i) the SAT problem, into (ii) the MIS problem.Additionally, it includes a protocol for embedding the MIS problem onto a Rydberg-atom graph and experimentally probing the Rydberg-atom graph's ground state.The subsequent sections of the paper elaborate on the procedure, starting with an overview of the use of a Rydberg-atom graph in integer factorization, illustrated by the example of p × q = 6 in Sec.II.Details about encoding of the factorization into the SAT problem are provided in Sec.III.Experimental demonstrations of p × q = 15 and 35 are presented in Sec.IV.Scalability issues related to the Rydberg-atom approach to the integer factorization problem are discussed in Sec.V, leading to conclusions in Sec.VI.

II. RYDBERG-ATOM APPROACH TO THE INTEGER FACTORIZATION PROBLEM
We describe the method of programming the integer factorization problem with a Rydberg-atom graph, using the simplest possible example of p × q = 6 as illustrated in Fig. 1.Initially, we reduce the integer factorization problem to a SAT one.Considering the three-bit binary representation 6 = (110) 2 , we assume that the factors p and q are two-bit integers, denoted as p = (p 1 p 0 ) 2 and q = (q 1 q 0 ) 2 .The Boolean equations governing the binary variables p 0 , p 1 , q 0 , q 1 are then derived from the multipli- cation table in Fig. 1(a) as follows: where ⊕ is XOR and p 0 q 1 p 1 q 0 in Eq. (1c) denotes the carry arising from Eq. (1b).These equations can be efficiently (i.e., in a polynomial number of steps in the bit number of n) converted to a Boolean equation in conjunctive normal form, yielding Further details will be described in Sec.III.The Boolean equation Ψ 6 = 1 readily translates into the following Boolean satisfiability (SAT) problem of 4 clauses: Subsequently, we translate this SAT problem into an MIS problem on a graph, as depicted in Fig. 1(c).The first two clauses C 1 and C 2 in Eqs.(3b) and (3c) are incorporated into isolated single-vertex graphs denoted as K 1 's in graph nomenclature: For C 3 and C 4 , two-vertex connected graphs, or K 2 's, are employed: Now, we introduce additional edges to represent interclause relations between variables p 0 , q 0 and their negations p 0 , q 0 , creating connections between C 3 and C 4 .These inter-clause edges impose constraints between the vertices encoding the same variables.Consequently, the graph G 6 expressing the factorization problem p × q = 6 as an MIS problem on the graph is defined as follows: + e(p 0 , p 0 ) + e(q 0 , q 0 ).( 6) Here, G 6 has maximum independent set of size 4, which is equal to the number of clauses in Ψ 6 .Therefore, any maximum independent set configuration of size 4 corresponds to an assignment satisfying Ψ 6 = 1, ensuing that the corresponding binary representation of numbers p, q meet p × q = 6.By transforming the integer factorization problem into an MIS one, we can leverage a Rydberg-atom experiment to address it, exploiting the Rydberg blockade phenomenon to inherently encode the independence condition in the spatial configuration of the atoms.Specifically, the graph G 6 is implemented as a Rydberg-atom graph, where each vertex corresponds to an atom, and edges are established by positioning the respective pairs of atoms in close proximity, ensuring that their simultaneous excitation to the Rydberg state is hindered by the blockade phenomenon [30,31].Following a quantum evolution, the collection of atoms in the Rydberg state delineates a subset of vertices of G 6 .These subsets sampled from this final state are expected to be good candidates for the MIS of the graph.
The Hamiltonian is defined for a general graph G (an unweighted graph) as follows: where |0⟩ and |1⟩ are pseudo-spin states denoting the ground and Rydberg-atom states, respectively, σz = |1⟩ ⟨1| − |0⟩ ⟨0|, U is the interaction between each pair of "edged" atoms (of the same separation distance), and ∆ is the detuning of Rydberg-atom excitation.The MIS phase requires two conditions: U ≫ ℏ|∆| enforces the Rydberg blockade phenomenon; and ∆ > 0 maximizes the number of atoms being excited to the Rydberg state.The many-body ground state, Ĥ(G) , is then the superposition of MIS's of G [26,32].For the Rydbergatom graph G 6 in Eq. ( 6), the many-body ground state Ĥ(G 6 ) of Ĥ(G 6 ) is given by: which is the superposition of two factoring solutions, p × q = (10) 2 × (11) 2 and (11) 2 × (10) 2 .
Experimental verification can be performed with the adiabatic evolution of the Rydberg-atom graph G 6 from the paramagnetic phase to the anti-ferromagnetic phase, which corresponds to the MIS phase [28].We used rubidium atoms ( 87 Rb) with ground state |0⟩ ≡ 5S 1/2 , F = 2, m F = 2 and Rydberg state |1⟩ ≡ 71S 1/2 , m J = 1/2 .The Rabi frequency Ω is ramped up from 0 to Ω 0 = (2π)1.5MHz, while the laser detuning is maintained at ∆ = −(2π)3.5MHz for 0.3 µs.Then the detuning is ramped up from −(2π)3.5 to +(2π)δ F MHz for 2.4 µs, with δ F = 3.5 and fixed Rabi frequency Ω 0 .(The p × q = 15 and 35 experiments in Sec.IV are performed with δ F = 3.5 and 3.9, respectively.)Finally the Rabi frequency is ramped down to zero and the detuning is maintained at +(2π)3.5 MHz for 0.3 µs.The entire evolution time is 3.0 µs.The detuning and Rabi frequencies are changed with the frequency and the power of the excitation lasers with acousto-optic modulators (AOM), which are controlled by a programmable radiofrequency synthesizer (Moglabs XRF).After the quasiadiabatic evolution, the population of each atom is measured by illuminating the conventional cycling transition lights where the atoms in the ground state show fluorescence whereas the atoms in the Rydberg state do not.The experimental results obtained with G 6 are depicted in Fig. 1(d), where the expected states |p 0 p 1 q 0 q 1 ; p 0 q 0 ⟩ = |0111; 10⟩ and |1101; 01⟩ in Eq. ( 8) are measured with high probabilities, confirming that the integer factors are (11) 2 = 3 and (10) 2 = 2.

III. ENCODING INTEGER FACTORIZATION INTO THE SATISFIABILITY PROBLEM
The conjunctive normal form of integer multiplication can be efficiently represented using a binary decision diagram (BDD), as detailed in Ref. [33].In this context, we provide a concise overview of the BDD construction process, utilizing the example of p × q = 6 in Sec.II, and derive Ψ 6 in Eq. ( 3), the Boolean expression in conjunctive normal form for the SAT problem [34,35].
In a generic factorization problem for a given semiprime number n = p × q, if n is an N -bit integer, finding the unknown factors, p (an N p -bit integer) and q (an N q -bit integer), involves identifying the preimage of n through the binary multiplication function where N q ≥ N − N p .Let p i (0 ≤ i ≤ N p − 1) be the i-th bit of p, q j (0 ≤ j ≤ N q − 1) the j-th bit of q, and n k (0 ≤ k ≤ N − 1) the k-th bit of n.The function f is then expressed as: where each term p i q j 2 i+j contributes a nonzero value to the sum only when p i = q j = 1. Figure 2(a) shows the BDD for the p × q = 6 factoring problem.In this constructed BDD, each column corresponds to one of the three bit-wise calculations of p × q = 6 in Eq. (1).There are three columns comprising a total of 10 unit BDDs, interconnected based on the constraints from bit-wise equations in Eq. (10).Assuming that we have processed the sum in Eq. (10) up to the (i, j)-th term, by defining a running sum f (i,j) = v, the subsequent running sum f (i ′ ,j ′ ) is given by: These running sum relations can be represented by the unit BDD, as depicted in Fig. 2(b).The starting and ending nodes contains the running values f (i,j) and f (i ′ ,j ′ ) , respectively, with edges distinguished as solid or dotted based on whether the product p i ′ q j ′ is set to 1 or 0, respectively.The BDD for f is formed by linking these unit BDDs representing all running sum relations.The unit BDD representing the logical relation between p i ′ and q j ′ in the multiplication table, depicted by the blue-colored box labeled f (i ′ ,j ′ ) , where the edges in the BDD can be either solid or dotted, depending on whether The first column (column 0) in Fig. 2(a) pertains to the first bit calculation, utilizing the topmost unit BDD to compute the running sum f (0,0) (p 0 , q 0 ) = p 0 q 0 .Two possible end node values, f (0,0) = 0 (derived from paths satisfying p 0 q 0 = 0) and f (0,0) = 1 (through the path of p 0 q 0 = 1, ), emerge.Only the former (the orangecolored, left end node) aligns with the first bit constraint f (0,0) = n 0 , leading to the exclusion of the latter (the gray-colored, right end node).The second column (column 1) initiates from the f (0,0) = 0 node and computes the second bit of n.Three possible end nodes represent the running sums f (1,0) = 0, 2, and 4, respectively.Among these, only the second one satisfies the second bit equation, f (1,0) = n 0 +n 1 ×2.Similarly, the third column (column 2) begins from the f (1,0) = 2 node and terminates at two possible nodes, f (1,1) = 2 and 6.The second one is the only one satisfying f (1,1) = n 0 +n 1 ×2+n 2 ×2 2 .Now we seek a Boolean expression in conjunctive normal form for the 3-SAT problem.Generally, the prime number couple (p, q) for a semi-prime number n = p×q is unique (up to ordering).So, the determination of BDD paths leading to the end node corresponding to n establishes the values of p i s and q j s.Since p i s and q j s are involved in various paths, fixing their values imposes constraints on the BDD paths.Conversely, preventing certain paths from extending beyond the solution space by incorrectly setting a bit-wise equation for n i introduces constraints on the potential values of p i s and q j s.Aggregating these constraints enables the representation of the given factorization problem through a Boolean formula of the SAT problem.

IV. EXPERIMENTAL DEMONSTRATION
We now apply the process of translating factoring problems into Rydberg-atom graphs to experimentally investigate the integer factors of p×q = 15 and p×q = 35.We first derive the corresponding Boolean expressions in conjunctive normal form using the methodology outlined in Sec.III and subsequently these expressions are transformed into their respective Rydberg-atom graphs.

A. Solving p × q = 15
The conjunctive normal form Boolean equation representing p × q = 15 is derived as follows: •(p 1 + p 2 + q 2 )(q 1 + p 2 + q 2 )p 0 q 0 = 1.( 14 The detailed construction of Ψ 15 from the BDD is described in Appendix.The corresponding Rydberg-atom graph G 15 is then expressed as: which is depicted in Fig. 3(a).Each parenthesized term in Ψ 15 corresponds to a two-or three-vertex connected graph (K 2 or K 3 ), and each variable-negation relation is represented by an additional edge.The superscript indices in the last four terms in Eq. ( 15) denote variableatom duplicates in different subgraphs (K 2 or K 3 ).The single-vertex graphs for p 0 and q 0 are omitted in Fig. 3(a), for simplicity.
Implementing G 35 directly in an experiment is challenging, even with Rydberg quantum wires.Hence, we explore a 2D version of the experimental graph, denoted .The probability distribution is plotted in the basis of all variable and negation atoms of G Exp 35 .Among the 13 microstates highlighted in blue, there are correct mapping to the solution factors.Conversely, the microstates labeled in black are deemed Ψ 35 -unsatisfiable, and those in gray are considered "undecidable" regarding a definite set of values for variables (p 2 , p 1 , q 2 , q 1 , s).Out of 9,383 experimental events, 5,337 usable events were collected after the procedures of the single-vertex error mitigation protocol [29] and the Rydberg quantumwire compilation method [26] are applied.In contrast to the previous p × q = 15 experiment, where 89.7% of total events are usable, the case of p × q = 35 yields  7) .Refer to the text for a detailed discussion.
wherein we assume p and q to be N p = N q = log 2 n/2-bit binary integers.Thus, the number of clauses in the total 3-SAT formula is, up to the leading order, which results in Eq. ( 20).
Computational complexity.The classical computational complexity involved in converting the integer factorization problem to a BDD is discussed following the methodology outlined in Ref. [33].The number of nodes in a total BDD is given by when the BDD consists of N 0 ≡ (log 2 n/2) 3 unit BDD blocks, each with an average 2 nodes, as depicted in Fig. 2(b).The number of time steps required to build each unit BDD of the total BDD for factoring the given integer n and the memory space needed to arrange these unit BDD cells are respectively given by ∆N step = N 0 , (28) ∆N memory = N 0 . (29) Hence, the construction of a BDD can be accomplished in polynomial time steps and memory space, efficiently using classical computation.

VI. CONCLUSION
These Rydberg-atom experiments have taken on the task of addressing the integer factorization problem, with a particular focus on instances of p × q = 6, 15, and 35.The approach involves converting these instances into 3-SAT problems and subsequently mapping them onto Rydberg atom graphs.These graphs are then subjected to quasi-adiabatic quantum experiments, producing superpositions of microstates.These microstates are used to experimentally determine the integer factors (p, q) that constitute n = p × q.The proposed method estimates that the number of required atoms and classical computational resources for obtaining the Rydberg atom graph remain within polynomial orders of log 2 n, suggesting the effectiveness of this encoding scheme.Nonetheless, it is important to note that solving 3-SAT problems on a large scale using Rydberg atoms remains challenging, primarily due to the current limitations of imperfect quantum adiabatic processing hardware.

VII. DATA AVAILABILITY
The experimental data set is archived in Ref. [39] for further analysis.

VIII. ACKNOWLEDGEMENTS
This research is supported by Samsung Science and Technology Foundation (SSTF-BA1301-52).Louis Vignoli thanks Sélim Touati for useful discussions.

FIG. 2 .
FIG. 2. (a)The binary decision diagram (BDD) for factoring p × q = 6.(b) The unit BDD representing the logical relation between p i ′ and q j ′ in the multiplication table, depicted by the blue-colored box labeled f (i ′ ,j ′ ) , where the edges in the BDD can be either solid or dotted, depending on whether p i ′ q j ′ is 1 or 0.

TABLE I .
Atom positions of G Exp 15 , G Exp