Exact distributed quantum algorithm for generalized Simon’s problem
Abstract
Simon’s problem is one of the most important problems demonstrating the power of quantum algorithms, as it greatly inspired the proposal of Shor’s algorithm. The generalized Simon’s problem is a natural extension of Simon’s problem, and also a special hidden subgroup problem: Given a function , with the property that for any , there is some unknown hidden subgroup such that iff , where for some . The goal of generalized Simon’s problem is to find the hidden subgroup . In this paper, we present two key contributions. Firstly, we characterize the structure of the generalized Simon’s problem in distributed scenario and introduce a corresponding distributed quantum algorithm. Secondly, we refine the algorithm to ensure exactness due to the application of quantum amplitude amplification technique. Our algorithm offers exponential acceleration compared to the distributed classical algorithm. When contrasted with the centralized quantum algorithm for the generalized Simon’s problem, our algorithm’s oracle requires fewer qubits, thus making it easier to be physically implemented. Particularly, the exact distributed quantum algorithm we develop for the generalized Simon’s problem outperforms the best previously proposed distributed quantum algorithm for Simon’s problem in terms of generalizability and exactness.
pacs:
Valid PACS appear hereI INTRODUCTION
Quantum computing nielsen_quantum_2010 has been proved to have great potential in factorizing large numbers shor_polynomial-time_1997 , searching unordered database grover_fast_1996 and solving linear systems of equations HHL_2009 . However, large-scale universal quantum computers have not yet been realized due to the limitations of current physical devices. At present, quantum technology has been entered to the Noisy Intermediate-Scale Quantum (NISQ) era preskill_quantum_2018 , which makes it possible to implement quantum algorithms on middle-scale circuits.
Distributed quantum computing is a novel computing architecture, which combines quantum computing with distributed computing goos_distributed_2003 ; beals_efficient_2013 ; Qiu2017DQC ; caleffi_quantum_2018 ; avron_quantum_2021 ; Qiu22 ; Tan2022DQCSimon ; Xiao2023DQAShor ; Hao2023DDJ ; Xiao2023DQAkShor . In distributed quantum computing architecture, multiple quantum computing nodes communicate with each other and cooperate to complete computing tasks. Compared with centralized quantum computing, the size and depth of circuit can be reduced by using distributed quantum computing, which is beneficial to improve the performance of circuit against noise.
Simon’s problem is one of the most important problems in quantum computing simon_power_1997 . For solving Simon’s problem, quantum algorithms have the advantage of exponential acceleration over classical algorithms cai_optimal_2018 . Remarkably, Simon’s algorithm greatly inspired the proposal of Shor’s algorithm shor_polynomial-time_1997 . Furthermore, the generalized Simon’s problem is a natural extension of Simon’s problem, and an instance of the hidden subgroup problem nielsen_quantum_2010 ; kaye_introduction_2007 .
Tan, Xiao, and Qiu et al. Tan2022DQCSimon proposed a distributed quantum algorithm for Simon’s problem, but they left it open as to whether an exact distributed version exists. In the centralized case, Cai and Qiu cai_optimal_2018 utilized quantum amplitude amplification to address the issue of exactness for Simon’s problem. Their approach has served as inspiration for our work. In this paper, we contribute in two new ways. Firstly, we characterize the structure of the generalized Simon’s problem in distributed scenario and leverage this understanding to design a corresponding distributed quantum algorithm. Secondly, we incorporate quantum amplitude amplification BHMT02 to ensure the algorithm’s exactness.
The remainder of this paper is organized as follows. In Sec. II, we present some notations related to group theory, and recall the generalized Simon’s problem. In Sec. III, we characterize the structure of the generalized Simon’s problem in distributed scenario. Then, in Sec. IV we describe a distributed quantum algorithm for the generalized Simon’s problem and give the corresponding analytical procedure. Furthermore, in Sec. V we introduce quantum amplitude amplification technique, and with this technique, we in Sec. VI design an exact distributed quantum algorithm for the generalized Simon’s problem and prove its correctness. In addition, in Sec. VII, we compare our algorithm with other algorithms. Finally, we conclude with a summary in Sec. VIII.
II PRELIMINARIES
In this section, we present some notations related to group theory, and recall the generalized Simon’s problem.
II.1 Notations
It is known that the generalized Simon’s problem is an instance of the hidden subgroup problem. Below, we present some of the notations related to group theory.
For with and , we define
(1) |
(2) |
For any subset , denotes the subgroup generated by , i.e.,
(3) |
The set is linearly independent if for any proper subset of . Notice that the cardinality is if is linearly independent.
Let denote the group , the basis of is a maximal linearly independent subset of . The cardinality of the basis of is called its , denoted by . If is a subgroup of , then we denote . For , let
(4) |
Notice that and if is linearly independent.
II.2 The generalized Simon’s problem
The generalized Simon’s problem is a special kind of the hidden subgroup problem kaye_introduction_2007 , which can be described as follows. Consider a function , where we promise that for any , there is a hidden subgroup , such that if and only if , where for some . For the specific case where , the generalized Simon’s problem precisely aligns with Simon’s problem.
Denote the basis of as , then we have
(5) |
Suppose we have an oracle that can query the value of function . For any and any , if we input into the oracle, then is obtained.The goal of the generalized Simon’s problem is to find the hidden subgroup by performing the minimum number of queries to function .
III the generalized Simon’s problem in the distributed scenario
In the following, we describe the generalized Simon’s problem in distributed scenario and characterize its structure.
The function corresponding to the generalized Simon’s problem is divided into subfunctions as follows. Let
(6) |
where , .
Suppose there are people, each of whom has an oracle that can query all for any , , where are defined as
(7) |
where , and .
Each person can access values of . They need to find the hidden subgroup by querying their own oracle and communicating with each other as few times as possible.
Below, we further introduce some notations related to the function corresponding to the generalized Simon’s problem. We anticipate that the reader is already familiar with the concept of multisets.
Definition 1.
For any , let denote the multiset .
Definition 2.
For any , let .
Definition 3.
For any , let represent a string of length by concatenating all strings according to lexicographical order, that is,
(8) |
where , with , where for any and denotes the lexicographical order.
Let be the hidden subgroup to be found, and denote the basis of as .
Let
(9) |
then .
Denote , , and the basis of as .
Let
(10) |
then .
The following theorem concerning is useful and important.
Theorem 1.
Suppose function , satisfies that there is a subgroup such that if and only if . Then if and only if .
Proof.
Based on the properties of multiset, if and only if . So our goal is to prove if and only if .
(1) . First, we prove if , then . We have such that . According to the definition of the generalized Simon’s problem, , . In addition, we have , , such that .
Thus, we have , . By the definition of group and , we have and , . Since , there such that . Hence, we have . Therefore, and . Similarly, we can prove that and . As a result, we have .
(2) . Since , we have . Then we have such that and . So we have . According to the definition of the generalized Simon’s problem, we have . Further, by the definition of group and , we have . ∎
IV Distributed quantum algorithm for the generalized Simon’s problem
In the following, we begin with giving related notation, function and operators that are used in distributed quantum algorithm for the generalized Simon’s problem, i.e., Algorithm 1.
Let represent the set of integers , and let be the function to convert a binary string of bits to an equal decimal integer.
Intuitively, the effect of in Algorithm 1 is to sort the values in the control registers by lexicographical order and XOR to the target register.
In addition, for any operator with , we let , .
In the following, we prove the correctness of Algorithm 1. The state after the third step of Algorithm 1 is
(13) |
Then Algorithm 1 queries each of the oracles to get the following state.
(14) |
After sorting by using , we have the following state.
(15) |
After that, we query each oracle again and obtain the following state.
(16) |
After using Hadamard transform on the first register, in the light of Theorem 1, we get the following state.
(17) |
Note that if there exists such that , then we have
(18) |
If , then , so we have
(19) |
Thus, in line 9 of Algorithm 1, after measuring the first register of the state , we can obtain an element .
In line 9 of Algorithm 1, since the result we measure may not be linearly independent of the results we measured earlier, there is no guarantee that can be obtained for obtained after running Algorithm 1 iteratively many times.
After running Algorithm 1 iteratively many times, we denote . Denote , , and the basis of as . Note that may not be equal to .
Denote , , .
Denote . It will be proved below that may not be equal to , and hence Algorithm 2 is not exact.
In fact, if , then there may exist in the basis of and , where , , and . Let , where and . Thus, , which indicates that there is a case where is not equal to , i.e., Algorithm 2 is not exact.
V Quantum amplitude amplification
By means of the work of Cai and Qiu cai_optimal_2018 , we also require a similar method, i.e., the use of quantum amplitude amplification technique to make the distributed quantum algorithm for solving the generalized Simon’s problem exactly.
To make Algorithm 1 exact, we add a post-processing subroutine after line 8 of Algorithm 1 to ensure is always linearly independent when we get the measured result of the first register.
Let denote the combined unitary operators from line 4 to line 8 in Algorithm 1, i.e., is defined as
(23) |
Define as
(24) |
Define as
(25) |
Then by and , we define the quantum amplitude amplification operator as
(26) |
Denote by
(27) |
Definition 4.
Let denote the projection onto the good state subspace, that is, the subspace spanned by .
Definition 5.
Let denote the projection onto the bad state subspace, that is, the subspace spanned by .
We have
(28) |
In order to make Algorithm 1 exact, the crucial step is to eliminate all states in from the first register. In quantum amplitude amplification process, one can achieve this by choosing appropriate such that after applying on , the amplitudes of all states in of the first register become zero.
In the following, we present a proposition related to the operator acting on the state , which is proved in Appendix A.
Proposition 1.
Let , , where . Then
(29) |
We describe the quantum amplitude amplification algorithm used to measure good states as follows. In fact, since we do not know the rank of group , i.e., , we assume that the rank of group is , where .
VI Exact distributed quantum algorithm for the generalized Simon’s problem
In this section, we first design an exact distributed quantum algorithm for finding , i.e., Algorithm 4, which combines Algorithm 1 and Algorithm 3. After finding , we design Algorithm 5 to find the hidden subgroup exactly.
We describe the main design idea for Algorithm 4 as follows. First, we use Algorithm 1 to ensure that the state of the first register is in , and then we utilize quantum amplitude amplification technique BHMT02 to ensure that the measured result of the first register is not in .
Since is undetermined, we assume it is and initialise . For a given , if , then during the iterative run of Algorithm 4, it must be obtained that . In this case, the value of is increased by 1. If , then add to . After that, Algorithm 4 is run repeatedly.
If , this means that has been increased to equal . We have also obtained the set , which satisfies . Eventually, by solving the system of exclusive-or equations, we can obtain .

In the following, we present Algorithm 5. The main design idea of Algorithm 5 is to first find the associated string corresponding to the base of group , and then concatenate the strings formed by the base of group with their corresponding associated strings, and finally merge them to form the hidden subgroup exactly.
First, we prove the correctness of Algorithm 4. In line 6 of Algorithm 4, since operator is defined in Eq. (23), which is the combined unitary operators from line 4 to line 8 in Algorithm 1, the following equation can be obtained from the proof of correctness of Algorithm 1.
(30) |
Based on the Proposition 1, we have
(32) |
After measuring on the first register, we can get an element that is in . After repetitions of Algorithm 4, we can obtain elements in . Then, using the classical Gaussian elimination method, we can obtain .
If we have already found out , we can use Algorithm 5 to find out the hidden subgroup . In the following, we prove the correctness of Algorithm 5.
Denote by
(33) |
where , .
To prove the correctness of Algorithm 5, we prove that .
First, we prove that .
Let be any element belonging to . Since , by the definition of the generalized Simon’s problem, we have
(34) |
Moreover, for any , there is
(35) |
Therefore, we have . According to the definition of the generalized Simon’s problem, we have . Thus, .
Then, we prove that .
Let be any element belonging to , where , .
Since is the basis of , we also have
(36) |
By the definition of the generalized Simon’s problem, we have .
Furthermore, there exists such that
(37) |
From the definition of , we have . Thus, . Consequently, .
VII Comparisons with other algorithms
First, we compare Algorithm 1 with the distributed classical randomized algorithm for solving the generalized Simon’s problem. Based on the previous analysis, Algorithm 1 needs queries for finding group . However, in order to find group , the distributed classical randomized algorithm needs to query oracles times.
Algorithms | Query complexity |
Algorithm 1 | |
Distributed classical randomized algorithm |
Therefore, Algorithm 1 has the advantage of exponential acceleration compared with the distributed classical randomized algorithm.
Second, we compare Algorithm 4 with the distributed classical deterministic algorithm for solving the generalized Simon’s problem. According to the previous analysis, Algorithm 4 needs queries for finding group . However, in order to find group , the distributed classical deterministic algorithm needs to query oracles times.
Algorithms | Query complexity |
Algorithm 4 | |
Distributed classical deterministic algorithm |
Hence, Algorithm 4 has the advantage of exponential acceleration compared with the distributed classical deterministic algorithm.
Third, we compare Algorithm 1 and Algorithm 4 with the centralized quantum algorithm for solving the generalized Simon’s problem. In Algorithm 1 and Algorithm 4, the number of actual functioning qubits for each oracle is only . However, in the centralized quantum algorithm, the number of actual functioning qubits for each oracle is .
Algorithms | The number of actual functioning qubits for each oracle |
Algorithm 1 | |
Algorithm 4 | |
The centralized quantum algorithm for solving the generalized Simon’s problem |
Consequently, Algorithm 1 and Algorithm 4 facilitate the reduction of circuit depth and the physical implementation of algorithm in the NISQ era.
Finally, we compare Algorithm 2 and Algorithm 5 with the best distributed quantum algorithm for Simon’s problem proposed previously Tan2022DQCSimon . Algorithm 2 and Algorithm 5 can not only solve Simon’s problem, but also the generalized Simon’s problem. In particular, Algorithm 5 is exact. However, the algorithm Tan2022DQCSimon cannot solve the generalized Simon’s problem and is not exact.
Algorithms | Precision | Generalisability |
Algorithm 2 | Inaccuracy | The generalized Simon’s problem |
Algorithm 5 | Exact | The generalized Simon’s problem |
The algorithm in Tan2022DQCSimon | Inaccuracy | Simon’s problem |
VIII Conclusion
In this paper, we have characterized the structure of the generalized Simon’s problem in distributed scenario. Based on the structure, we have designed a corresponding distributed quantum algorithm. Then we have further utilized quantum amplitude amplification technique to make our algorithm exact. The number of actual functioning qubits for each oracle in our algorithm is reduced, which reduces the circuit depth and helps reduce circuit noise, making our algorithm easier to be implemented in the current NISQ era.
Our algorithm has the advantage of exponential acceleration compared with the distributed classical algorithm. Compared to the centralized quantum algorithm for the generalized Simon’s problem, the oracle in our algorithm is easier to be implemented, which is an important advantage for implementing quantum query algorithms. Compared with the best distributed quantum algorithm for Simon’s problem proposed previously, the exact distributed quantum algorithm we designed for the generalized Simon’s problem has the advantage of better generalisability and exactness.
We found that characterizing the essential structure of problem is crucial for designing corresponding exact distributed quantum algorithm. In future research work, our algorithm may be instructive for designing exact distributed quantum algorithms for solving the hidden subgroup problem. Furthermore, the ideas and methods employed in the design of our algorithm may also be useful for the design of exact distributed quantum algorithms for solving other problems.
Acknowledgements
This work is supported in part by the National Natural Science Foundation of China (Nos. 61876195, 61572532), and the Natural Science Foundation of Guangdong Province of China (No. 2017B030311011).
Appendix A Proof of Proposition 1
Proposition 1.
Let , , where . Then
Proof.
From Eq. (LABEL:eq:R_0), we can write as follows.
(38) |
From the definitions of , and , we have
(39) |
(40) |
Let , then based on Eq. (26), can be written as
(41) |
For , we have
(42) |
Since and , according to the definition of and , we have
(43) |
Thus, we can obtain the following equations.
(44) |
(45) |
By making sure the resulting superposition has inner product zero with , then based on Eq. (44) and Eq. (45), we can obtain the following equation.
(46) |
Denote by
(47) |
Then according to Eq. (46), we have
(48) |
Taking the square of , we can further have
(49) |
Arrange Eq. (49) to get
(50) |
From Eq. (50), we can obtain
(51) |
References
- (1) M.A. Nielsen and I.L. Chuang, Quantum Computation and Quantum Information, 10th ed. (Cambridge University Press, Cambridge, 2010).
- (2) P.W. Shor, SIAM J. Comput. 26, 1484 (1997).
- (3) L.K. Grover, in Proceedings of the Twenty-Eighth Annual ACM Symposium on Theory of Computing (ACM Press, Philadelphia, 1996), pp. 212–219.
- (4) A.W. Harrow, A. Hassidim, and S. Lloyd, Phys. Rev. Lett. 103, 150502 (2009).
- (5) J. Preskill, Quantum 2, 79 (2018).
- (6) H. Buhrman and H. Röhrig, in Mathematical Foundations of Computer Science 2003, edited by G. Goos, J. Hartmanis, J. van Leeuwen, B. Rovan, and P. Vojtáš, Lecture Notes in Computer Science Vol. 2747 (Springer, Berlin, 2003), pp. 1–20.
- (7) R. Beals, S. Brierley, O. Gray, A.W. Harrow, S. Kutin, N. Linden, D. Shepherd, and M. Stather, Proc. R. Soc. A 469, 20120686 (2013).
- (8) K. Li, D.W. Qiu, L.Z. Li, S.G. Zheng, and Z.B. Rong, Inf. Process. Lett. 120, 23 (2017).
- (9) M. Caleffi, A. S. Cacciapuoti, and G. Bianchi, in Proceedings of the 5th ACM International Conference on Nanoscale Computing and Communication (Association for Computing Machinery, New York, 2018), p. 1.
- (10) J. Avron, O. Casper, and I. Rozen, Phys. Rev. A 104, 052404 (2021).
- (11) D.W. Qiu and L. Luo, L.G. Xiao, arXiv:2204.10487.
- (12) J.W. Tan, L.G. Xiao, D.W. Qiu, L. Luo, and P. Mateus, Distributed quantum algorithm for Simon’s problem, Phys. Rev. A 106, 032417 (2022).
- (13) L.G. Xiao, D.W. Qiu, L. Luo, and P. Mateus, Quantum Inf. Comput. 23, 1&2 (2023).
- (14) H. Li, D.W. Qiu, and L. Luo, arXiv:2303.10663.
- (15) L.G. Xiao, D.W. Qiu, L. Luo, and P. Mateus, arXiv:2304.12100.
- (16) D. R. Simon, SIAM J. Comput. 26, 1474 (1997).
- (17) G.Y. Cai and D.W. Qiu, J. Comput. Syst. Sci. 97, 83 (2018).
- (18) P. Kaye, R. Laflamme, and M. Mosca, An Introduction to Quantum Computing (Oxford University Press, Oxford, 2007).
- (19) G. Brassard, P. Hoyer, M. Mosca, and A. Tapp, Quantum amplitude amplification and estimation, AMS Contemporary Mathematics 305 (2002).
- (20) Z.G. Wu, D.W. Qiu, J.W. Tan, H. Li, and G.Y. Cai, Theor. Comput. Sci. 924 (2022).
- (21) Z.K. Ye, Y.Q. Huang, L.Z. Li, and Y.Y. Wang, Inf. Comput. 281, 104790 (2021).