Preparation method, device and equipment of quantum state and storage medium

By dividing the qubit set under grid limitation and building a preparation operator architecture, the problem of the existing Dicke state preparation circuit is solved, and higher operational parallelism and lower circuit depth are achieved.

CN120218264APending Publication Date: 2025-06-27TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311800954.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-12-25
Publication Date
2025-06-27

AI Technical Summary

Technical Problem

The existing Dicke state preparation circuit has an inoptimal circuit depth under grid limitation and there is a lot of room for improvement.

Method used

By dividing n qubits into multiple qubit sets and recursively decompose them under grid limitations, the allocation operator subset, the permutation operator subset and the unitary operator subset are determined, and the preparation operator architecture is constructed, and the quantum state preparation operator is combined to obtain the quantum state preparation operator.

Benefits of technology

The Hamming weight of the first quantum state is realized to allocate the Hamming weight to multiple qubit sets, which improves the operational parallelism of the quantum state preparation operator and reduces the circuit depth of the quantum state preparation circuit.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120218264A_ABST
    Figure CN120218264A_ABST
Patent Text Reader

Abstract

The invention discloses a quantum state preparation method and device, equipment and a storage medium, and relates to the technical field of quantum. The method comprises the following steps: acquiring n quantum bits under grid limitation; dividing the n quantum bits into a plurality of quantum bit sets meeting sub-grid limitation; an allocation operator subset, a permutation operator subset and a unitary operator subset are determined, the allocation operator subset and the permutation operator subset are used for allocating the Hamming weight of the first quantum state to the multiple quantum bit sets and enabling the multiple quantum bit sets to be mutually entangled, and a permutation operator is used for exchanging the quantum states between the two quantum bit sets; under the indication of the preparation operator architecture, determining a quantum state preparation operator based on the allocation operator subset, the replacement operator subset and the unitary operator subset; and acting the quantum state preparation operator on the n quantum bits to evolve the quantum states of the n quantum bits from the initial quantum state to the first quantum state. According to the invention, the circuit depth of the quantum state preparation circuit can be reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present application relate to the field of quantum technologies, and in particular, to a method, apparatus, device, and storage medium for preparing a quantum state. Background Art

[0002] In quantum computing, Dicke states are a class of important entangled states, which have extensive applications in directions such as quantum networks, quantum game theory, and quantum algorithms. On superconducting quantum devices, two-qubit gates can only act on some qubit pairs, that is, superconducting quantum devices have qubit connectivity limitations (i.e., grid limitations). In order to prepare Dicke states on quantum devices, it is very important to design Dicke state preparation circuits with qubit connectivity limitations.

[0003] Currently, under grid limitations, the circuit depth of the best Dicke state preparation circuit is used to define the upper bound, where n is the number of qubits, k is the Hamming weight of n qubits in the Dicke state, and the theoretical lower bound of the depth of the Dicke state preparation circuit is Ω(n2), and Ω(n2) is used to define the lower bound of n2, where n2 is the number of qubits corresponding to the rows of the grid. That is, the existing Dicke state preparation circuits are not circuits with optimal circuit depth in an asymptotic sense, and there is still much room for improvement. Summary of the Invention

[0004] Embodiments of the present application provide a method, apparatus, device, and storage medium for preparing a quantum state. The technical solution is as follows:

[0005] According to one aspect of the embodiments of the present application, a method for preparing a quantum state is provided, and the method includes:

[0006] Obtaining n qubits under grid limitations and the initial quantum states of the n qubits, where n is a positive integer;

[0007] Dividing the n qubits into multiple qubit sets, where each qubit set includes k qubits, and the connections of the k qubits satisfy sub-grid limitations, and the sub-grids corresponding to the sub-grid limitations are combined into the grid corresponding to the grid limitations, where k is a positive integer less than n;

[0008] In the process of recursively decomposing the n qubits with the qubit sets as units under the grid constraint, an assignment operator set, a permutation operator set, a unitary operator set, and a preparation operator architecture are determined; wherein, each assignment operator in the assignment operator set and each permutation operator in the permutation operator set are used to distribute the Hamming weight of the first quantum state to the multiple qubit sets, and to entangle the multiple qubit sets with each other, the permutation operator is used to exchange the quantum states between two qubit sets, each unitary operator in the unitary operator set is used to evolve the quantum state of the qubit set to the first quantum state, and the preparation operator architecture is used to indicate the operation relationship between the assignment operator, the permutation operator, and the unitary operator;

[0009] Under the constraint of the operation relationship indicated by the preparation operator architecture, the respective assignment operators, the respective permutation operators, and the respective unitary operators are combined to obtain a quantum state preparation operator;

[0010] The quantum state preparation operator is applied to the n qubits to evolve the quantum state of the n qubits from the initial quantum state to the first quantum state.

[0011] According to one aspect of the embodiments of the present application, a device for preparing a quantum state is provided, and the device includes:

[0012] An initial quantum state acquisition module, configured to acquire n qubits under a grid constraint and the initial quantum state of the n qubits, where n is a positive integer;

[0013] A qubit partitioning module, configured to partition the n qubits into multiple qubit sets, each qubit set includes k qubits, and the connection of the k qubits satisfies a sub-grid constraint, and the sub-grids corresponding to the sub-grid constraints form a grid corresponding to the grid constraint, where k is a positive integer less than n;

[0014] An operator set determination module, configured to determine an assignment operator set, a permutation operator set, a unitary operator set, and a preparation operator architecture in the process of recursively decomposing the n qubits with the qubit sets as units under the grid constraint; wherein, each assignment operator in the assignment operator set and each permutation operator in the permutation operator set are used to distribute the Hamming weight of the first quantum state to the multiple qubit sets, and to entangle the multiple qubit sets with each other, the permutation operator is used to exchange the quantum states between two qubit sets, each unitary operator in the unitary operator set is used to evolve the quantum state of the qubit set to the first quantum state, and the preparation operator architecture is used to indicate the operation relationship between the assignment operator, the permutation operator, and the unitary operator;

[0015] A preparation operator determination module, configured to combine the respective distribution operators, the respective permutation operators, and the respective unitary operators under the operation relationship constraints indicated by the preparation operator architecture to obtain a quantum state preparation operator;

[0016] A quantum state evolution module, configured to apply the quantum state preparation operator to the n qubits, so that the quantum states of the n qubits evolve from the initial quantum state to the first quantum state.

[0017] According to one aspect of the embodiments of the present application, a computer device is provided. The computer device includes a processor and a memory. A computer program is stored in the memory, and the computer program is loaded and executed by the processor to implement the above-mentioned quantum state preparation method.

[0018] According to one aspect of the embodiments of the present application, a computer-readable storage medium is provided. A computer program is stored in the readable storage medium, and the computer program is loaded and executed by a processor to implement the above-mentioned quantum state preparation method.

[0019] According to one aspect of the embodiments of the present application, a computer program product is provided. The computer program product includes a computer program, and the computer program is stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium, and the processor executes the computer program, so that the computer device executes the above-mentioned quantum state preparation method.

[0020] According to one aspect of the embodiments of the present application, a quantum chip is provided. The quantum chip includes a quantum preparation circuit constructed based on a quantum state preparation operator obtained by executing the above-mentioned quantum state preparation method.

[0021] The technical solution provided by the embodiments of the present application may include the following beneficial effects:

[0022] Limited by the grid, the allocation operator can only assign weights to two adjacent qubit sets. For example, the weight of the assigned qubit set is shared with the unassigned qubit set adjacent to it. However, in the embodiments of the present application, by combining the quantum state exchange function of the permutation operator, the quantum states of two adjacent qubit sets can be pulled apart. For example, for two adjacent assigned qubit sets, under the grid limitation, through the permutation operator, the quantum state of one of the assigned qubit sets can be permuted to the quantum state of an unassigned qubit set. In this way, the unassigned qubit set after permutation can share its weight with the unassigned qubit sets adjacent to it, while the other assigned qubit set can assign its weight to the assigned qubit set after permutation. Therefore, for n qubits under grid limitation, by combining the allocation operator and the permutation operator to assign the Hamming weight of the first quantum state to multiple qubit sets, the Hamming weight can be shared simultaneously based on multiple qubit sets, improving the operation parallelism of the quantum state preparation operator, and further reducing the circuit depth of the quantum state preparation circuit corresponding to the quantum state preparation operator. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] Figure 1 is a schematic diagram of the implementation environment of the solution provided by an embodiment of the present application;

[0024] Figure 2 is a flowchart of the method for preparing a quantum state provided by an embodiment of the present application;

[0025] Figure 3 is a schematic diagram of a qubit set provided by an embodiment of the present application;

[0026] Figure 4 is a schematic diagram of a qubit set provided by another embodiment of the present application;

[0027] Figure 5 is a flowchart of the method for determining the allocation operator, the permutation operator, and the unitary operator provided by an embodiment of the present application;

[0028] Figures 6 - 12 Exemplarily shows a schematic diagram of the recursive decomposition of n qubits under grid limitation;

[0029] Figure 13 is a block diagram of the quantum state preparation device provided by an embodiment of the present application;

[0030] Figure 14 is a block diagram of the quantum state preparation device provided by another embodiment of the present application;

[0031] Figure 15 is a block diagram of the structure of the computer device provided by an embodiment of the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0032] Before introducing the technical solution of this application, some terms related to this application will be explained. The following relevant explanations can be arbitrarily combined with the technical solution of the embodiments of this application as optional solutions, and they all fall within the protection scope of the embodiments of this application. The embodiments of this application include at least some of the following contents.

[0033] 1. Quantum computing: A computing method based on quantum logic, such as a computing method that can quickly complete computing tasks by utilizing properties such as the superposition and entanglement of quantum states. The basic unit for storing data is Qubit, the quantum bit.

[0034] 2. Qubit (quantum bit): The basic unit of quantum computing. Traditional computers use 0 and 1 as the basic units of binary. Different from this, quantum computing can process 0 and 1 simultaneously, and the system can be in a linear superposition state of 0 and 1: |ψ> = α|0> + β|1>, where α and β represent the complex probability amplitudes of the system on 0 and 1. The square of their modulus |α| 2 , |β| 2 represent the probabilities of being in 0 and 1 respectively.

[0035] 3. Quantum state: The quantum state of a system, which can be expressed as a linear combination of each basis state. For example, for a system of 1 quantum bit, all possible basis states are 0 and 1, while for a system of three quantum bits, all possible basis states are 000, 001, 010, 011, 100, 101, 110, 111, a total of 8. Let these basis states be φ i , then the quantum state can be expressed as ∑ i c i φ i , where c i is the linear combination coefficient.

[0036] 4. Quantum circuit: A representation of a quantum universal computer, representing the hardware implementation of the corresponding quantum algorithm / program under the quantum gate model. The quantum circuit acts on the quantum state to obtain a new quantum state and complete quantum computing. The quantum circuit can be composed of a series of quantum gates and measurement sequences, and the calculation is completed by the quantum gates. It can also be called a quantum circuit.

[0037] 5. Circuit depth of the quantum circuit: It refers to the number of layers or depth of the gate operations in the quantum circuit. The quantum circuit is used to describe the basic unit of quantum computing, which is composed of quantum bits and quantum gates. For example, if the circuit depth of the quantum circuit is equal to the number of quantum gates, it corresponds to the parallel running time of the quantum algorithm. Due to the decoherence property of the quantum bit, that is, the entanglement decreases with the increase of time, in order to ensure the running effect of the quantum circuit, the smaller the circuit depth, the better.

[0038] 6. Quantum Bit Connectivity Limitation: For superconducting quantum devices, two-qubit gates (CNOT) can only act on specific pairs of qubits. There are various types of quantum bit connectivity limitations, and the common ones are path limitations and grid limitations. It is very important to design quantum circuits for Dicke states under quantum bit connectivity limitations.

[0039] Path Limitation: For n consecutive qubits, if the two-qubit gate (CNOT) is only allowed to act on adjacent qubits, then the n-qubit circuit is said to be under path limitation, denoted as Pat / h. n 。

[0040] Grid Limitation: In an n-qubit circuit arranged in a two-dimensional grid, if the two-qubit gate is only allowed to act on adjacent qubits, then the n-qubit circuit is said to be under grid limitation, denoted as: It represents a two-dimensional grid limitation of size n1×n2, and satisfies n = n1n2 and n1 ≤ n2.

[0041] Among them, the path limitation is a special grid limitation:

[0042] 7. Dicke State: It is an important class of entangled states and has extensive applications in directions such as quantum networks, quantum game theory, and quantum algorithms. Especially for some quantum algorithms for solving combinatorial problems, such as variational quantum algorithms and adiabatic computing, which are noisy intermediate-scale quantum algorithms, the Dicke state is the initial quantum state of these algorithms.

[0043] The Dicke state is an equal-weight superposition of all n quantum states under the Hamming weight k constraint. Exemplarily, the (n, k)-Dicke state is defined as follows:

[0044]

[0045] Among them, the Hamming weight hw(x) represents the number of basis states with 1 in the n-qubit set x, and the binomial coefficient Each qubit in the n-qubit circuit in the Dicke state is entangled with each other.

[0046] For example,

[0047]

[0048] 8. Dicke State Preparation Circuit: It refers to a preparation circuit that makes multiple qubits in the Dicke state through a series of operations. This Dicke state preparation circuit can act on n qubits to evolve the quantum state of these n qubits to the Dicke state.

[0049] The circuit C for preparing the n - qubit Dicke state under grid constraints n , which can be used to prepare the Dicke state and its two - qubit gates satisfy grid constraints.

[0050] 9. Parallelism of quantum circuits: Multiple calculations can be completed on the same quantum circuit at the same time node. For example, the same quantum circuit can calculate the function values of the function f(x) at different x values simultaneously.

[0051] 10. Quantum chip (Superconducting Quantum Chip): The central processing unit of a quantum computer, which is a machine that uses the superposition principle and quantum entanglement of quantum mechanics to perform calculations, has strong parallel processing capabilities, and can solve some problems that are difficult to calculate by classical computers.

[0052] 11. [n] and [n]0 represent the integer sets {1, 2,..., n} and {0, 1, 2,..., n} respectively.

[0053] 12. The symbol 0 k and 1 k represent the sets of qubits including k 0s and k 1s basis states respectively.

[0054] 13. If V represents the set of qubits, then the symbol |ψ> V represents the |V|-qubit quantum state |ψ>, which is a quantum state on the set of qubits V.

[0055] 14. Dcike state unitary transformation (also called Dicke state unitary operator): It is used to evolve the quantum state of a set of qubits to the Dicke state. Exemplarily, an n - qubit Dcike state unitary transformation acting on the set of qubits S satisfies:

[0056]

[0057] where, represents an (n, l)-Dicke state, and [k]0 represents the integer set {0, 1, 2,..., k}.

[0058] 15. Weight distribution transformation (also called distribution operator): It is used to distribute the Hamming weight of a set of qubits to another set of qubits. Exemplarily, let S1 and S2 represent two non - overlapping sets of qubits of size k respectively, and all 2k qubits in S1 and S2 are consecutive on the path constraint Path n For any integers n≥m≥k, a 2k - qubit weight distribution transformation Satisfy:

[0059]

[0060] Among them, if n - m < l - i, then the binomial coefficient Here, n is 2k.

[0061] The weight allocation transformation is a transformation acting on the qubit sets S1 and S2, and its function is to distribute l 1s on S1 to S1 and S2. Each allocation method will be assigned a different weight. For example, when there are l 1s on S1, if i 1s and l - i 1s are respectively distributed to S2 and S1, then a weight can be assigned to this allocation scheme

[0062] 16. Permutation transformation under grid constraints (also known as permutation operator): It can be used to exchange the basis states of qubits at corresponding positions on two qubit sets. Exemplarily, for any permutation π ∈ S of n elements n , the U that satisfies the following transformation π is called a permutation transformation.

[0063]

[0064] Among them, x n is the nth element.

[0065] To make the objectives, technical solutions, and advantages of this application clearer, the following will further describe the embodiments of this application in detail with reference to the accompanying drawings.

[0066] Please refer to Figure 1 , which shows a schematic diagram of the solution implementation environment provided by an embodiment of this application. The solution implementation environment may include: a terminal device 10 and a server 20.

[0067] The terminal device 10 may refer to some electronic devices with relatively strong computing capabilities, such as mobile phones, desktop computers, tablet computers, laptop computers, PCs (Personal Computers), servers, in-vehicle terminals, intelligent robots, smart TVs, multimedia playback devices, and other electronic devices. In some feasible examples, the terminal device 10 may also be implemented as a server, and the embodiments of this application do not make any limitations in this regard.

[0068] The terminal device 10 can be used to construct a quantum state preparation operator for preparing a first quantum state (such as a Dicke state) for n qubits under grid constraints. For example, the terminal device 10 can be an industrial intelligent device for fabricating a quantum state preparation circuit, such as a lithography device, a robotic arm, and other devices required for industrial production. After constructing the quantum state preparation operator, it can construct a quantum state preparation circuit 40 (such as a quantum chip) based on the quantum state preparation operator. By operating n qubits through the quantum state preparation circuit 40, the quantum states of the n qubits can be evolved into the first quantum state.

[0069] The quantum state preparation circuit 40 can be integrated on various intelligent terminals, such as electronic devices like smartphones, tablets, laptops, desktop computers, smart speakers, smart watches, smart home appliances, multimedia playback devices, PCs (Personal Computers), smart robots, vehicle-mounted terminals, wearable devices, etc. The embodiments of the present application do not limit this.

[0070] Optionally, a client of a target application for constructing a quantum state preparation operator is installed and run in the terminal device 10, and the server 20 is used to provide background services for the client of the target application in the terminal device 10. For example, the server 20 can be the background server of the above target application. The server 20 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms. The embodiments of the present application do not limit this.

[0071] The terminal device 10 and the server 20 can communicate with each other through the network 30. The network 30 can be a wired network or a wireless network.

[0072] Next, the technical solution provided by the present application will be introduced and described through method embodiments.

[0073] Please refer to Figure 2 , which shows a flowchart of a method for preparing a quantum state provided by an embodiment of the present application. The execution subject of each step of this method can be Figure 1 the terminal device 10 in the implementation environment of the solution shown. For ease of description, only the execution subject of each step being the "client in the terminal device 10" will be introduced and described. This method can include at least one of the following steps (201 to 205):

[0074] Step 201: Obtain n qubits under grid constraints and the initial quantum states of the n qubits, where n is a positive integer.

[0075] The distribution of the n qubits under grid constraints satisfies the grid corresponding to the grid constraints. For example, one qubit is distributed at each vertex of the grid, and the edges of the grid are used to indicate that a two-qubit gate can be added between the two qubits corresponding to the edge. If there is no edge between two qubits, a two-qubit gate cannot be added between the two qubits, that is, entanglement cannot be directly generated between the two qubits.

[0076] The embodiment of the present application does not limit the grid corresponding to the grid constraints. It can be a path constraint, a two-dimensional grid constraint, or a three-dimensional grid. The embodiment of the present application takes a two-dimensional grid as an example to illustrate the method for preparing quantum states.

[0077] In one example, each row of the grid corresponds to n2 qubits, and each column of the grid corresponds to n1 qubits, where n = n1n2, n2 ≥ n1, n1 is a positive integer, and n2 is a positive integer. For example, referring to Figure 1 , the above-mentioned n qubits are distributed according to the two-dimensional grid in Figure 1 . The number of vertices of the two-dimensional grid is the same as the number of qubits, and the connection between the qubits satisfies the constraints of the edges of the two-dimensional grid.

[0078] The above initial quantum states are used to indicate the initial basis states of the n qubits (such as all being 0) and the initial entanglement relationship between the n qubits (such as no entanglement). The embodiment of the present application does not limit the initial quantum states of the n qubits.

[0079] Step 202: Divide the n qubits into multiple qubit sets. Each qubit set includes k qubits, and the connection of the k qubits satisfies the sub-grid constraints. The sub-grids corresponding to the sub-grid constraints are combined into the grid corresponding to the grid constraints, where k is a positive integer less than n.

[0080] Optionally, under the grid constraints, divide the n qubits into multiple qubit sets. For example, divide the grid into multiple sub-grids, and determine the qubits corresponding to each sub-grid as a qubit set. This qubit set can also be referred to as a qubit string or a qubit set.

[0081] Among them, the n qubits can be evenly divided into multiple qubit sets, that is, each qubit set includes k qubits, and the n qubits can be evenly divided into n / k qubit sets, and the grid can be evenly divided into n / k sub-grids. The sub-grid constraint means that the connection of each qubit in the qubit set satisfies the sub-grid.

[0082] Exemplarily, when k ≥ n2 / n1, each row of the sub-grid corresponds to qubits, and each column of the sub-grid corresponds to qubits. For example, referring to Figure 3 , the grid 300 is divided into n / k sub-grids of size . In each row and each column of the grid 300, there are sub-grids respectively, and each sub-grid corresponds to k qubits. Among them, for any i, j ∈ [2 r , the set of qubits corresponding to the sub-grid at the i-th row and j-th column is denoted as S i,j . Without loss of generality, for the convenience of introducing the technical solution provided by the embodiments of the present application, the embodiments of the present application take and both being integers as an example for illustration.

[0083] Optionally, when are not integers, the grid can be re-partitioned as follows. For example, the grid is divided into sub-grids of different sizes but with the number of qubits being of the order of O(k). The grid is divided into rows and columns of sub-grids. The size of the first rows and the first columns of sub-grids is The size of the first sub-grids in the last column is The size of the first sub-grids in the -th column is The size of the first sub-grids in the -th row is The size of the sub-grid at the -th row and -th column is

[0084] When 1 ≤ k ≤ n2 / n1, each row of the sub-grid corresponds to k qubits, and each column of the sub-grid corresponds to 1 qubit. For example, referring to Figure 4 , the grid 300 is divided into n / k sub-grids of size 1×k. In each row of the grid 300, there are sub-grids, and in each column of the grid 300, there are n1 sub-grids. Each sub-grid corresponds to k qubits. For any i ∈ [n1], j ∈ [n2 / k], the set of qubits corresponding to the sub-grid at the i-th row and j-th column is denoted as S i,j. Without loss of generality, for the convenience of introducing the technical solutions provided by the embodiments of the present application, the embodiments of the present application use n / k, both being integers as an example for illustration.

[0085] In one example, the value of k described above is equal to the Hamming weight of the first quantum state, where the first quantum state refers to the quantum state to which n qubits need to be evolved, such as the Dicke state. For example, the value of k described above is equal to the Hamming weight when n qubits are in the Dicke state.

[0086] Optionally, after dividing n qubits into multiple qubit sets, the multiple qubit sets can be initialized. Exemplarily, the quantum state of the leftmost first qubit set in the first row of the multiple qubit sets is replaced with 1, and the quantum states of the remaining qubit sets in the multiple qubit sets are replaced with 0. That is, the k qubits corresponding to the first subnet in the upper left corner of the grid are all initialized to 1, and the remaining n - k qubits are all initialized to 0, so as to facilitate distributing the Hamming weight of the first quantum state to each qubit set, such that the above-mentioned n qubit sets satisfy the Hamming weight of the first quantum state.

[0087] For example, referring to Figure 3 , in the case where the initial base states of n qubits are all 0, can be applied to the first qubit set S 1,1 such that the k qubits in the first qubit set S 1,1 are initialized to 1. For the remaining n - k qubits, no operation is required.

[0088] Optionally, since applying to can obtain Without loss of generality, the embodiments of the present application can set k ≤ n / 2.

[0089] Step 203, in the process of recursively decomposing n qubits in units of qubit sets under grid constraints, determine the distribution operator set, the permutation operator set, and the unitary operator set, as well as the preparation operator architecture; where each distribution operator in the distribution operator set and each permutation operator in the permutation operator set are used to distribute the Hamming weight of the first quantum state to multiple qubit sets and to entangle the multiple qubit sets with each other, the permutation operator is used to exchange the quantum states between two qubit sets, each unitary operator in the unitary operator set is used to evolve the quantum state of the qubit set to the first quantum state, and the preparation operator architecture is used to indicate the operation relationship between the distribution operator, the permutation operator, and the unitary operator.

[0090] In the embodiments of the present application, recursive decomposition is a process of gradually decomposing the above-mentioned multiple qubit sets from a whole into n / k qubit sets of size k. For example, first divide the multiple qubit sets into two qubit sets on average, and then divide the two qubit sets into 4 qubit sets respectively until the n qubits are divided into qubit sets of size k on average. Optionally, the size of the decomposed qubit sets is consistent with the size of the qubit sets.

[0091] Recursive decomposition under grid constraints refers to the process of partitioning qubit sets according to the constraints of the grid. For example, referring to Figure 3 , under the constraints of grid 300, 2 r ×2 r qubit sets can be evenly divided into two parts: S L and S R , represents the part corresponding to the left side of grid 300, represents the part corresponding to the right side of grid 300. Then, under the constraints of grid 300, S L and S R are partitioned, and so on. The entire grid 300 can be partitioned into 2 r ×2 r qubit sets.

[0092] The set of distribution operators includes the distribution operators in each recursive decomposition process. The set of distribution operators is used to distribute the Hamming weight of the first quantum state from the first qubit set (S 1,1 ) to each qubit set (S 1,1 to ), and to entangle each qubit set (S 1,1 to ) with each other.

[0093] The set of permutation operators includes the permutation operators in each recursive decomposition process. The set of permutation operators is used to assist the set of distribution operators in distributing the Hamming weight of the first quantum state. For example, for two adjacent allocated qubit sets, under grid constraints, the quantum state of one of the allocated qubit sets can be permuted to the quantum state of an unallocated qubit set through the permutation operator. In this way, the unallocated qubit set after permutation can distribute the weight to the unallocated qubit sets adjacent to it, and the other allocated qubit set can distribute the weight to the allocated qubit set after permutation. In this way, for n qubits under grid constraints, by combining the distribution operator and the permutation operator to distribute the Hamming weight of the first quantum state to multiple qubit sets, the distribution of the Hamming weight can be achieved simultaneously based on multiple qubit sets, thereby improving the operation parallelism of the quantum state preparation operator.

[0094] The preparation operator architecture in the embodiments of the present application may refer to formulas, relational expressions, etc. composed of distribution operators, permutation operators, and unitary operators, which can reflect the usage patterns of distribution operators, permutation operators, and unitary operators in each recursive decomposition process, as well as the relationships between recursive decomposition processes.

[0095] In one example, since the recursive decomposition methods under k≥n2 / n1 and 1≤k≤n2 / n1 are the same, the case of k≥n2 / n1 will be used as an example for illustration below. Exemplarily, referring to Figure 5 , step 203 may further include the following sub-steps.

[0096] Step 203a, in the horizontal direction of the grid, taking the qubit set as a unit, perform multiple horizontal recursive decompositions on multiple qubit sets under the grid constraint to obtain multiple qubit columns; wherein, the row width of the qubit column is the same as the row width of the sub-grid, and the column width of the qubit column is the same as the column width of the grid.

[0097] Optionally, in the embodiments of the present application, the recursive decomposition is divided into horizontal recursive decomposition and vertical recursive decomposition. The horizontal recursive decomposition refers to the process of dividing n qubits in the horizontal direction (n2) of the grid, and the vertical recursive decomposition refers to the process of dividing n qubits in the vertical direction (n1) of the grid.

[0098] A qubit column refers to a qubit set obtained by arranging qubit sets in columns. For example, referring to Figure 3 , for the grid 300, the qubit set combined from the qubit sets corresponding to the first column of sub-grids S 1,1 to in the grid 300 is a qubit column. After multiple horizontal recursive decompositions, 2 r qubit columns of size can be obtained.

[0099] Exemplarily, in the first horizontal recursive decomposition process, the horizontal recursive decomposition process may include the following:

[0100] 1. Divide multiple qubit sets into 2 first-order initial qubit columns under the grid constraint.

[0101] Optionally, taking the qubit set as a unit, evenly divide n qubits into 2 first-order initial qubit columns under the grid constraint. Each first-order initial qubit column includes 2 r-1 qubit columns, such as the above-mentioned S L and S R .

[0102] 2. Assign weights to the first qubit set and the second qubit set from the left in the first row of the first-order initial qubit column starting from the left, to obtain the adjusted first-order initial qubit column starting from the left.

[0103] Let S L (the first-order initial qubit column starting from the left) in the first row, S 1,1 (the first qubit set from the left) and S 1,2 (the second qubit set from the left) be weighted to obtain the adjusted S L .

[0104] Among them, weight assignment means distributing the Hamming weight of S 1,1 to S 1,1 and S 1,2 .

[0105] 3. Exchange the quantum states of the second qubit set from the left in the first row of the adjusted first-order initial qubit column and the first qubit set from the left in the first row of the second first-order initial qubit column, to obtain two first-order qubit columns.

[0106] Exchange the quantum states of S L in the first row of the adjusted S 1,2 , and S R (the second first-order initial qubit column starting from the left) in the first row with (the first qubit set from the left), to obtain two first-order qubit columns (denoted as the final S L and the final S R ).

[0107] Among them, quantum state exchange means exchanging the quantum states on S 1,2 and .

[0108] In the second and subsequent horizontal recursive decomposition processes, the horizontal recursive decomposition process may include the following:

[0109] 1. In the r-th horizontal recursive decomposition process, for each (r - 1)-th order qubit column, divide the (r - 1)-th order qubit column into two r-th order initial qubit columns under the grid constraint, where r is an integer greater than 1.

[0110] Optionally, after the first horizontal recursive decomposition, two first-order qubit columns can be obtained, and after the r-th horizontal recursive decomposition, 2 r r-th order qubit columns can be obtained. In In this case, the embodiment of the present application completes the horizontal recursive decomposition. That is, when the row width of the r-th order qubit column is the same as the row width of the sub-grid, the r-th order qubit column can be determined as the qubit column.

[0111] Since the quantum state exchange is performed on S 1,2 and , the embodiment of the present application can perform horizontal recursive decomposition on 2 first-order qubit columns in parallel. Since the decomposition methods of each (r - 1)-th order qubit column are the same, the decomposition of any first-order qubit column in the embodiment of the present application will be described.

[0112] For example, taking the final S L as an example, under the constraint of the grid 300, the final S L ((r - 1)-th order qubit column) can be evenly divided into S LL and S LR (2 r-th order initial qubit columns). For the final S R , under the constraint of the grid 300, the final S R can be evenly divided into S RL and S RR (2 r-th order initial qubit columns), a total of 2 2 r-th order initial qubit columns.

[0113] 2. Perform weight assignment on the leftmost first qubit set and the leftmost second qubit set in the first row of the leftmost first r-th order initial qubit column to obtain the adjusted first r-th order initial qubit column.

[0114] For the final S L , perform weight assignment on S LL in the first row of S 1,1 and S 1,2 to obtain the adjusted S LL . For the final S R , perform weight assignment on RL in the first row of S and to obtain the adjusted S RL .

[0115] 3. Perform quantum state exchange on the leftmost second qubit set in the first row of the adjusted first r-th order initial qubit column and the leftmost first qubit set in the first row of the leftmost second r-th order initial qubit column to obtain 2 r-th order qubit columns.

[0116] Perform quantum state exchange on S LL in the first row of the adjusted S 1,2 , and LR in the first row of S Exchange quantum states to obtain two r-th order quantum bit sequences; after adjusting S RL In the first line of and S RR In the first line of By exchanging quantum states, two r-th order quantum bit sequences are obtained.

[0117] Step 203b, in the process of multiple horizontal recursive decompositions, determining the allocation operator and the permutation operator corresponding to each horizontal recursive decomposition, and constructing the sub-preparation operator architecture corresponding to the horizontal recursive decomposition.

[0118] Exemplarily, in the first horizontal recursive decomposition process, step 203b may include the following contents:

[0119] 1. Based on the first quantum bit set from the left and the second quantum bit set from the left in the first row of the first first-order initial quantum bit column from the left, determine the allocation operator corresponding to the first horizontal recursive decomposition.

[0120] Optionally, since the n quantum bits are divided into two first-order quantum bit sequences during the first horizontal recursive decomposition process, the Hamming weight of the first quantum state can be apportioned to the two first-order quantum bit sequences.

[0121] For example, the weight distribution transformation can be used to construct the distribution operator corresponding to the first horizontal recursive decomposition, which can be expressed as follows:

[0122]

[0123] 2. Based on the second quantum bit set from the left in the first row of the adjusted first first-order initial quantum bit column and the first quantum bit set from the left in the first row of the second first-order initial quantum bit column from the left, determine the permutation operator corresponding to the first horizontal recursive decomposition.

[0124] Optionally, since in the grid S 1,1 and S 1,2 adjacent, in order to enable the subsequent permutation transformation to be implemented in parallel, the embodiment of the present application exchanges S 1,2 and The quantum state of can be constructed based on the permutation transformation under the grid restriction, and the permutation operator corresponding to the first horizontal recursive decomposition can be expressed as follows:

[0125]

[0126] 3. Based on the two first-order quantum bit sequences, determine the sub-preparation operator architecture corresponding to the first horizontal recursive decomposition.

[0127] Exemplarily, for any l ∈ [k]0, the construction process of the sub-preparation operator architecture corresponding to the first transverse recursive decomposition of the n-qubit Dicke state unitary transformation can be as follows:

[0128]

[0129] Without loss of generality, n / 2 is an integer above. Optionally, the sub-preparation operator architecture corresponding to the first transverse recursive decomposition can be expressed as follows:

[0130]

[0131] Wherein, can be decomposed into and

[0132] During the r-th transverse recursive decomposition process, step 203b may include the following content:

[0133] 1. For each (r - 1)-th order qubit column, based on the first qubit set and the second qubit set from the left in the first row of the first r-th order initial qubit column, determine the sub-allocation operator corresponding to the (r - 1)-th order qubit column in the r-th transverse recursive decomposition.

[0134] Optionally, each (r - 1)-th order qubit column can be divided into 2 r-th order initial qubit columns. For each (r - 1)-th order qubit column, its corresponding unitary operator can be decomposed into a combination of unitary operators, allocation operators, and permutation operators corresponding to 2 r-th order initial qubit columns.

[0135] For example, for it can be expressed as follows:

[0136]

[0137] That is can be further decomposed into

[0138] Wherein, for S can be L averaged into two parts, the left and the right, which are denoted as S LL and S LR . respectively. On the first two qubit sets S L in the first row of S 1,1 and S 1,2 act the weight allocation transformation Then use the permutation to exchange the first qubit set 1,2 and S L,R in the upper left corner of Finally, perform the Dicke state unitary transformation of n / 2 LL qubits on S LR and S 2 in parallel respectively. and

[0139] Optionally, has the same decomposition method as , which will not be elaborated here. Since and act on two non-overlapping grids, they can be implemented in parallel.

[0140] For example, in the second horizontal recursive decomposition process, two sub-allocation operators can be obtained: and

[0141] 2. Based on the second qubit set from the left in the first row of the adjusted first r-th order initial qubit column and the first qubit set from the left in the first row of the second r-th order initial qubit column, determine the sub-permutation operator corresponding to the r-1-th order qubit column in the r-th horizontal recursive decomposition.

[0142] For example, in the second horizontal recursive decomposition process, two sub-permutation operators can be obtained: and

[0143] 3. Based on the sub-allocation operators corresponding to each r-1-th order qubit column in the r-th horizontal recursive decomposition, obtain the allocation operator corresponding to the r-th horizontal recursive decomposition.

[0144] Optionally, the sub-allocation operators corresponding to each r-1-th order qubit column in the r-th horizontal recursive decomposition can be collectively referred to as the allocation operator corresponding to the r-th horizontal recursive decomposition.

[0145] 4. Based on the sub-permutation operators corresponding to each r-1-th order qubit column in the r-th horizontal recursive decomposition, obtain the permutation operator corresponding to the r-th horizontal recursive decomposition.

[0146] Optionally, the sub-permutation operators corresponding to each r-1-th order qubit column in the r-th horizontal recursive decomposition can be collectively referred to as the permutation operator corresponding to the r-th horizontal recursive decomposition.

[0147] 5. Based on the two r-th order qubit columns corresponding to each r-1-th order qubit column and the sub-preparation operator architecture corresponding to the r-1-th horizontal recursive decomposition, determine the sub-preparation operator architecture corresponding to the r-th horizontal recursive decomposition.

[0148] Optionally, by substituting the decomposition relation of the unitary operator corresponding to each (r - 1)-th order qubit column into the sub-preparation operator architecture corresponding to the (r - 1)-th horizontal recursive decomposition, the sub-preparation operator architecture corresponding to the r-th horizontal recursive decomposition can be obtained.

[0149] Continuously perform horizontal recursive decomposition in this way until the unitary transformation of the n-qubit Dicke state is decomposed into the unitary transformation of the Dicke state of 2 r qubits , that is, the unitary transformation of the Dicke state acting on the j-th column sub-grid

[0150] Optionally, for the last horizontal recursive decomposition, since there is no need to perform Hamming weight sharing in the horizontal direction, quantum state swapping can no longer be performed, that is, for the last horizontal recursive decomposition, a permutation operator does not need to be constructed.

[0151] Step 203c: For each qubit column, in the longitudinal direction of the grid, taking the qubit set as a unit, perform multiple longitudinal recursive decompositions on the qubit column under the grid limit to obtain multiple transformed qubit sets; among them, the transformed qubit sets correspond one-to-one with the qubit sets, the row width of the transformed qubit set is the same as the row width of the sub-grid, and the column width of the transformed qubit set is the same as the column width of the sub-grid.

[0152] Optionally, after obtaining 2 r qubit columns, the 2 r qubit columns can be processed in parallel. In the longitudinal direction of the grid, taking the qubit set as a unit, perform multiple longitudinal recursive decompositions on the qubit column under the grid limit. Since the longitudinal recursive decompositions of each qubit column are the same, only the longitudinal recursive decomposition of a certain qubit column is taken as an example for illustration in the embodiments of the present application.

[0153] Among them, the set of transformed qubit sets satisfies the Hamming weight of the first quantum state, and the transformed qubit sets are entangled with each other. Each qubit set corresponds to a transformed qubit set, and the transformed qubit set and its corresponding qubit set are the same in size, dimension, and position.

[0154] Exemplarily, in the process of the first longitudinal recursive decomposition, step 203c may include the following content:

[0155] 1. For each qubit column, divide the qubit column into 2 first-order initial qubit rows under the grid limit.

[0156] For example, referring to Figure 3 , taking the leftmost qubit column in the grid 300 as an example, it can be evenly divided into 2 first-order initial qubit rows: SU and S D , represents the upper half corresponding to the first column of qubits from the left, and represents the lower half corresponding to the first column of qubits from the left.

[0157] 2. Perform weight assignment on the first qubit set and the second qubit set from the top in the first row of the first-order initial qubits, to obtain the adjusted first row of the first-order initial qubits.

[0158] For S U in S 1,1 and S 1,2 perform weight assignment to obtain the adjusted S U .

[0159] 3. Perform quantum state exchange on the second qubit set from the top in the adjusted first row of the first-order initial qubits and the first qubit set from the top in the second row of the first-order initial qubits, to obtain two rows of first-order qubits.

[0160] For the adjusted S U in S 1,2 , and S D in perform quantum state exchange, then two rows of first-order qubits can be obtained.

[0161] In the s-th longitudinal recursive decomposition process, step 203c may include the following:

[0162] 1. For each row of (s - 1)-th order qubits, divide the row of (s - 1)-th order qubits into two rows of r-th order initial qubits under grid constraints, where s is an integer greater than 1.

[0163] 2. Perform weight assignment on the first qubit set and the second qubit set from the top in the first row of the s-th order initial qubits, to obtain the adjusted first row of the s-th order initial qubits.

[0164] 3. Perform quantum state exchange on the second qubit set from the top in the adjusted first row of the s-th order initial qubits and the first qubit set from the top in the second row of the s-th order initial qubits, to obtain two rows of s-th order qubits.

[0165] Optionally, when the column width of the s-th order qubit row is the same as the column width of the sub-grid, the s-th order qubit column is determined as the transformed qubit set.

[0166] For example, using the same method as the horizontal recursive decomposition, for Perform multiple vertical recursive decompositions until a Dicke state unitary transformation of size k-qubits is decomposed. Up to this point.

[0167] Step 203d, during the multiple vertical recursive decompositions, determine the distribution operator and permutation operator corresponding to each vertical recursive decomposition, and based on the sub-preparation operator architecture, construct a preparation operator architecture.

[0168] During the first vertical recursive decomposition, step 203d may include the following content:

[0169] 1. For each column of qubits, based on the first qubit set and the second qubit set from the first row of the first-order initial qubits, determine the distribution operator corresponding to the first vertical recursive decomposition.

[0170] Optionally, the distribution operator corresponding to the first vertical recursive decomposition can be expressed as follows:

[0171]

[0172] 2. Based on the second qubit set from the adjusted first row of the first-order initial qubits and the first qubit set from the second row of the first-order initial qubits, determine the permutation operator corresponding to the first vertical recursive decomposition.

[0173] Optionally, the permutation operator corresponding to the first vertical recursive decomposition can be expressed as follows:

[0174]

[0175] 3. Based on 2 rows of first-order qubits and the sub-preparation operator architecture corresponding to the horizontal recursive decomposition, construct the sub-preparation operator architecture corresponding to the first vertical recursive decomposition.

[0176] Optionally, substitute the decomposition relationship of each into the sub-preparation operator architecture corresponding to the horizontal recursive decomposition to obtain the sub-preparation operator architecture corresponding to the first vertical recursive decomposition.

[0177] During the s-th vertical recursive decomposition, step 203d may include the following content:

[0178] 1. For each row of (s - 1)-th order qubits, based on the first qubit set and the second qubit set from the first row of the s-th order initial qubits, determine the sub-distribution operator corresponding to the row of (s - 1)-th order qubits in the s-th vertical recursive decomposition.

[0179] Optionally, the method for determining the sub-allocation operator corresponding to the (s-1)-th order qubit row in the s-th vertical recursive decomposition is the same as that for the allocation operator corresponding to the first vertical recursive decomposition, which will not be elaborated here.

[0180] 2. Based on the first qubit set starting from the top in the adjusted first s-th order initial qubit row and the first qubit set starting from the top in the second s-th order initial qubit row, determine the sub-permutation operator corresponding to the (s-1)-th order qubit row in the s-th vertical recursive decomposition.

[0181] Optionally, the method for determining the sub-permutation operator corresponding to the (s-1)-th order qubit row in the s-th vertical recursive decomposition is the same as that for the permutation operator corresponding to the first vertical recursive decomposition, which will not be elaborated here.

[0182] 3. Based on the sub-allocation operators corresponding to each (s-1)-th order qubit row in the s-th vertical recursive decomposition, obtain the allocation operator corresponding to the s-th vertical recursive decomposition.

[0183] 4. Based on the sub-permutation operators corresponding to each (s-1)-th order qubit row in the s-th vertical recursive decomposition, obtain the permutation operator corresponding to the s-th vertical recursive decomposition.

[0184] 5. Based on the two s-th order qubit rows corresponding to each (s-1)-th order qubit row and the sub-preparation operator architecture corresponding to the (s-1)-th vertical recursive decomposition, determine the sub-preparation operator architecture corresponding to the s-th vertical recursive decomposition.

[0185] Optionally, substitute the decomposition relation expressions of the unitary operators corresponding to each (s-1)-th order qubit row into the sub-preparation operator architecture corresponding to the (s-1)-th vertical recursive decomposition, and the sub-preparation operator architecture corresponding to the s-th vertical recursive decomposition can be constructed.

[0186] Optionally, for the last vertical recursive decomposition, since there is no need to perform Hamming weight sharing in the vertical direction anymore, quantum state exchange can no longer be performed, that is, for the last vertical recursive decomposition, there is no need to construct a permutation operator.

[0187] Step 203e: Based on the allocation operators corresponding to each horizontal recursive decomposition and the allocation operators corresponding to each vertical recursive decomposition, obtain the allocation operator set.

[0188] Optionally, sort the allocation operators in the order of recursive decomposition, and the allocation operator set can be obtained.

[0189] Step 203f: Based on the permutation operators corresponding to each horizontal recursive decomposition and the permutation operators corresponding to each vertical recursive decomposition, obtain the permutation operator set.

[0190] Optionally, the permutation operators are sorted according to the order of recursive decomposition to obtain a set of permutation operators.

[0191] Step 203g: Determine the unitary operators for each transformed set of qubits to obtain a set of unitary operators.

[0192] For example, based on the Dicke state unitary transformation, construct the Dicke state unitary operators for each transformed set of qubits, and then sort the Dicke state unitary operators according to the order of recursive decomposition to obtain a set of Dicke state unitary operators. Among them, the Dicke state unitary transformation is used to evolve the quantum state of the set of qubits to the Dicke state. Optionally, the Dicke state unitary operators for each transformed set of qubits can be constructed in parallel (that is, they can act on each transformed set of qubits in parallel, so that the quantum states of each transformed set of qubits evolve to the Dicke state). This is beneficial to further improve the construction efficiency of the quantum state preparation operator and the operation parallelism of the quantum state preparation operator, and thus reduce the circuit depth of the quantum state preparation circuit corresponding to the quantum state preparation operator.

[0193] Step 204: Under the constraint of the operation relationship indicated by the preparation operator architecture, combine each distribution operator, each permutation operator, and each unitary operator to determine the quantum state preparation operator.

[0194] Optionally, place each distribution operator, each permutation operator, and each unitary operator in the corresponding positions in the preparation operator architecture to obtain the quantum state preparation operator.

[0195] For example, place and in the corresponding positions in to obtain the quantum state preparation operator.

[0196] In one example, taking the Dicke state as an example, since the n-qubit Dicke state unitary transformation can be decomposed into multiple k-qubit Dicke state unitary transformations, multiple weight distribution transformations, and multiple permutation transformations, the embodiments of the present application can, under the constraint of the operation relationship indicated by the preparation operator architecture, process multiple k-qubit unitary transformations through multiple weight distribution transformations and multiple permutation transformations to obtain the Dicke state preparation operator. Then, step 204 may further include the following content:

[0197] 1. In the longitudinal direction of the grid, divide each unitary operator in the manner of every two adjacent transformed sets of qubits to obtain multiple pairs of unitary operators.

[0198] For example, referring to Figure 3 , the unitary operator corresponding to the transformed S 1,1 and the transformed S2,1 The corresponding unitary operator is determined as a pair of unitary operators. For another example, the transformed S 1,2 The corresponding unitary operator, and the transformed S 2,2 The corresponding unitary operator is determined as a pair of unitary operators.

[0199] 2. Obtain the Kronecker products of each pair of unitary operators.

[0200] For example, for the transformed S 1,1 and the transformed S 2,1 , the Kronecker product of the corresponding pair of unitary operators can be expressed as follows:

[0201] 3. According to the operation relationships indicated by the preparation operator architecture, determine the positions and operation symbols of each Kronecker product, each distribution operator, and each permutation operator in the preparation operator architecture.

[0202] For example, taking the preparation operator architecture as an example, based on this preparation operator architecture, we can obtain and The positions and operation symbols in the preparation operator architecture, such as the positions being the first, second, and third, and the operation symbols being "·" and "·" respectively.

[0203] 4. According to the positions and operation symbols of each Kronecker product, each distribution operator, and each permutation operator in the preparation operator architecture, combine each Kronecker product, each distribution operator, and each permutation operator to obtain the quantum state preparation operator.

[0204] For example, according to and The positions and operation symbols in the preparation operator architecture, for and Perform combination to obtain the corresponding quantum state preparation operator.

[0205] The quantum state preparation operator in the embodiments of the present application can reflect the logical relationships of operations, such as the logical relationships of operations acting on n qubits. Exemplarily, the Dcike state preparation operator can reflect the action logics of the distribution operator and the permutation operator in each recursive decomposition process, and the action logics of the Dicke state unitary operators of each transformed set of qubits after n qubits are decomposed. Optionally, this quantum state preparation operator can be implemented as a quantum state preparation circuit to operate on n qubits.

[0206] Step 205, apply the quantum state preparation operator to n qubits so that the quantum states of the n qubits evolve from the initial quantum state to the first quantum state.

[0207] Optionally, the n qubits can be operated on through a quantum state preparation circuit corresponding to a quantum state preparation operator, so that the quantum states of the n qubits evolve from an initial quantum state to a first quantum state. For example, through the technical solution provided in the embodiments of the present application, under grid constraints, a Dicke state preparation operator for n-qubit Dicke state unitary transformation can be constructed, and then acting it on the n qubits can make the quantum states of the n qubits evolve from the initial quantum state to the Dicke state. The Dicke state preparation circuit corresponding to the Dicke state preparation operator can first perform a weight distribution transformation and a permutation transformation under grid constraints on the n qubits in sequence to distribute the Hamming weight of the Dicke state to n / k qubit sets, and then perform a k-qubit Dicke state unitary transformation on the n / k qubit sets in parallel, so that the quantum states of the n qubits can evolve from the initial quantum state to the Dicke state.

[0208] In summary, for the technical solution provided in the embodiments of the present application, under grid constraints, the distribution operator can only perform weight distribution on two adjacent qubit sets, such as distributing the weight of the already distributed qubit set to the adjacent undistributed qubit set. However, through the quantum state exchange function of the permutation operator in the embodiments of the present application, the quantum states of two adjacent qubit sets can be pulled apart. For example, for two adjacent already distributed qubit sets, under grid constraints, the quantum state of one of the already distributed qubit sets can be permuted to the quantum state of an undistributed qubit set through the permutation operator. In this way, the undistributed qubit set after permutation can distribute its weight to the adjacent undistributed qubit set, and the other already distributed qubit set can distribute its weight to the already distributed qubit set after permutation. Therefore, for n qubits under grid constraints, by combining the distribution operator and the permutation operator to distribute the Hamming weight of the first quantum state to multiple qubit sets, the sharing of the Hamming weight can be realized simultaneously based on multiple qubit sets, improving the operation parallelism of the quantum state preparation operator, and further reducing the circuit depth of the quantum state preparation circuit corresponding to the quantum state preparation operator.

[0209] In addition, by adopting the technical solution provided in the embodiments of the present application, the preparation of quantum states under any grid constraints can be realized, effectively improving the application range of the technical solution provided in the embodiments of the present application, and further expanding the preparation range of quantum states.

[0210] In some embodiments, taking the preparation of the Dicke state of n qubits under grid constraints as an example, the technical solution provided in the embodiments of the present application may include the following content:

[0211] Refer to Figure 6, in the embodiment of the present application, n qubits are divided into 16 qubit sets of size k, that is, the grid 600 is evenly divided into 16 sub-grids of size k. Each qubit set is constrained by its corresponding sub-grid. If the qubit sets corresponding to these sub-grids are denoted as S i,j ; where, i ∈ [4], j ∈ [4|.

[0212] In the first recursive decomposition process, as Figure 6 shown, on the qubit sets S 1,1 and S 1,2 acts (that is, the assignment operator corresponding to the first recursive decomposition), and distributes the Hamming weight corresponding to S 1,1 to S 1,1 and S 1,2 . Among them, the Hamming weight corresponding to S 1,1 is the Hamming weight when n qubits are in the Dicke state, and the Hamming weights of the remaining qubit sets are all 0.

[0213] Subsequently, as Figure 7 shown, on S 1,1 and S 1,3 acts P(S 1,2, S 1,3 )(that is, the permutation operator corresponding to the first recursive decomposition), in order to perform quantum state exchange on S 1,1 and S 1,3 .

[0214] Optionally, the sub-preparation operator architecture corresponding to the first recursive decomposition can be expressed as follows:

[0215]

[0216] Among them, L represents the 8 sub-grids on the left, and R represents the 8 sub-grids on the right. The n-qubit Dicke state unitary transformation can be decomposed into two n / 2-qubit Dicke state unitary transformations, a permutation transformation, and a weight distribution transformation.

[0217] In the second recursive decomposition process, as Figure 8 shown, on the qubit sets S 1,1 and S 1,2 acts (that is, the sub-assignment operator corresponding to the second recursive decomposition), and redistributes the Hamming weight allocated to S 1,1 to S 1,1 and S 1,2 , and on the qubit sets S 1,3 and S 1,4 acts (that is, the sub-assignment operator corresponding to the second recursive decomposition), and redistributes the Hamming weight allocated to S 1,3The Hamming weight to be apportioned is apportioned to S 1,3 and S 1,4 . Meanwhile, entanglement is made between qubit columns with each other.

[0218] Optionally, the sub-preparation operator architecture corresponding to the second recursive decomposition can be expressed as follows:

[0219]

[0220] where LL represents the first column qubit set, LR represents the second column qubit set, RL represents the third column qubit set, and RR represents the fourth column qubit set. The n / 2-qubit Dicke state unitary transformation can be decomposed into two n / 4-qubit Dicke state unitary transformations, a permutation transformation, and a weight assignment transformation.

[0221] In the process of the third recursive decomposition, as Figure 9 shown, for any 1 ≤ i ≤ 4, on the qubit sets S 1,i and S 2,i acts That is, in parallel on S 1,1 and S 2,1 acts (i.e., the sub-allocation operator corresponding to the third recursive decomposition), on S 1,2 and S 2,2 acts On S 1,3 and S 2,3 acts And on S 1,4 and S 2,4 acts

[0222] Subsequently, as Figure 10 shown, for any 1 ≤ i ≤ 4, on the qubit sets S 2,i and S 3,i acts P(S 2,i , S 3,i ) to swap the quantum states of S 2,i and S 3,i . That is, in parallel on S 2,1 and S 3,1 acts P(S 2,1 , S 3,1 )(i.e., the sub-permutation operator corresponding to the third recursive decomposition), on S 2,2 and S 3,2 acts P(S 2,2 , S 3,2 ), on S 2,3 and S 3,3 acts P(S 2,3 , S 3,3), and acting on S 2,4 and S 3,4 with P(S 2,4 , S 3,4 ).

[0223] Optionally, the sub-preparation operator architecture corresponding to the 3rd recursive decomposition can be represented as follows:

[0224]

[0225] The n / 4-qubit Dicke state unitary transformation can be decomposed into two n / 8-qubit Dicke state unitary transformations, a permutation transformation, and a weight assignment transformation.

[0226] During the 4th recursive decomposition process, as Figure 11 shown, for any 1 ≤ i ≤ 2 and 1 ≤ j ≤ 4, acting on the qubit sets S 2i-1,j and S 2i,j with That is, acting in parallel on S 1,1 and S 2,1 with Acting on S 1,2 and S 2,2 with Acting on S 1,3 and S 2,3 with Acting on S 1,4 and S 2,4 with ..., and acting on S 3,4 and S 4,4 with

[0227] As Figure 12 shown, for any 1 ≤ i ≤ 4 and 1 ≤ j ≤ 4, acting on the qubit set S i,j with That is, acting in parallel on S 1,1 , S 1,2 ,..., S 4,4 with the Dicke state unitary transformation.

[0228] Optionally, the sub-preparation operator architecture corresponding to the 4th recursive decomposition can be represented as follows:

[0229]

[0230]

[0231] The n / 8-qubit Dicke state unitary transformation can be decomposed into two n / 16-qubit Dicke state unitary transformations, a permutation transformation, and a weight assignment transformation.

[0232] Optionally, the assignment operator, permutation operator, and unitary operator corresponding to the four recursive decompositions are substituted into the sub-preparation operator architecture corresponding to the fourth recursive decomposition, and the Dicke state preparation operator can be obtained. Furthermore, based on the Dicke state preparation operator, a Dicke state preparation circuit can be obtained.

[0233] In some embodiments, for the quantum state preparation circuit implemented based on the above quantum state preparation operator, the calculation process of its corresponding circuit depth can be as follows:

[0234] Let T(n) represent the circuit depth of the Dicke state preparation circuit that implements the n-qubit Dicke state unitary transformation. In the first recursive decomposition process, the n-qubit Dicke state unitary transformation is decomposed into a weight assignment transformation acting on 2k consecutive qubits on the path a permutation transformation and two parallel (n / 2)-qubit Dicke state unitary transformations.

[0235] Since there is a path in the qubit set S 1,1 and S 1,2 which can be implemented by a quantum circuit with a circuit depth of O(k), that is, the assignment operator is implemented by a quantum circuit with a circuit depth of O(k). The role of the permutation transformation

[0236] is to perform a basis state exchange between each row of qubits in S and the qubits in the corresponding row of 1,2 . Since the distance between S and 1,2 and in the grid is O(n2 / 2), under the path constraint, the permutation transformation for each row can be implemented by a quantum circuit with a depth of O(n2 / 2). Since these rows do not intersect each other, the permutation transformation can be implemented by a quantum circuit with a circuit depth of O(n2 / 2). Similarly, the permutation transformation for each row can be implemented by a quantum circuit with a circuit depth of O(n1 / 2), that is, the permutation operator is implemented by a quantum circuit with a circuit depth of O(n1 / 2) or O(n2 / 2).

[0237] Two parallel (n / 2)-qubit Dicke state unitary transformations can be implemented by a quantum circuit with a circuit depth of T(n / 2). Then, the circuit depth of each horizontal recursive decomposition can be expressed as follows:

[0238]

[0239] The circuit depth of each vertical recursive decomposition can be expressed as follows:

[0240]

[0241] Since Then we have \(T(n)=T(k)+O(k\log(n / k)) + O(n^2)\). Under the path constraint, the unitary operator is implemented by a quantum circuit with a circuit depth of \(O(k)\), that is, the unitary transformation of the Dicke state of \(k\) qubits can be implemented by a quantum circuit with a depth of \(T(k)=O(k)\).

[0242] Therefore, under the grid constraint, the circuit depth of the Dicke state unitary transformation is \((k\log(n / k)+n^2)\), that is, the circuit depth of the quantum state preparation circuit corresponding to the quantum state preparation operator is \(O(k\log(n / k)+n^2)\).

[0243] In addition, under the grid constraint, the lower bound of the depth of the Dicke state preparation circuit is \(\Omega(n^2)\). When \(k\leq O(n^2 / \log(n))\), the circuit depth of the Dicke state preparation circuit is \(O(\log(n / k)k + n^2)=O(n^2)\), which matches the lower bound \(\Omega(n^2)\). Therefore, when \(k\leq O(n^2 / \log(n))\), the circuit depth of the Dicke state preparation circuit provided by the embodiments of the present application is optimal.

[0244] The following is an embodiment of the apparatus of the present application, which can be used to execute the method embodiment of the present application. For details not disclosed in the embodiment of the apparatus of the present application, please refer to the method embodiment of the present application.

[0245] Please refer to Figure 13 , which shows a block diagram of a quantum state preparation apparatus provided by an embodiment of the present application. The apparatus 1300 may include: an initial quantum state acquisition module 1301, a qubit partitioning module 1302, an operator set determination module 1303, a preparation operator determination module 1304, and a quantum state evolution module 1305.

[0246] The initial quantum state acquisition module 1301 is configured to acquire \(n\) qubits under the grid constraint, and the initial quantum state of the \(n\) qubits, where \(n\) is a positive integer.

[0247] The qubit partitioning module 1302 is configured to partition the \(n\) qubits into a plurality of qubit sets, each qubit set includes \(k\) qubits, and the connection of the \(k\) qubits satisfies the sub-grid constraint, and the sub-grids corresponding to the sub-grid constraints form the grid corresponding to the grid constraint, where \(k\) is a positive integer less than \(n\).

[0248] The operator set determination module 1303 is configured to determine an assignment operator set, a permutation operator set, a unitary operator set, and a preparation operator architecture during the process of recursively decomposing the n qubits in units of the qubit set under the grid constraint; wherein, each assignment operator in the assignment operator set and each permutation operator in the permutation operator set are used to distribute the Hamming weight of the first quantum state to the multiple qubit sets and to entangle the multiple qubit sets with each other, the permutation operator is used to exchange the quantum states between two qubit sets, each unitary operator in the unitary operator set is used to evolve the quantum state of the qubit set to the first quantum state, and the preparation operator architecture is used to indicate the operation relationship between the assignment operator, the permutation operator, and the unitary operator.

[0249] The preparation operator determination module 1304 is configured to combine the respective assignment operators, the respective permutation operators, and the respective unitary operators under the constraint of the operation relationship indicated by the preparation operator architecture to obtain a quantum state preparation operator.

[0250] The quantum state evolution module 1305 is configured to apply the quantum state preparation operator to the n qubits to evolve the quantum state of the n qubits from the initial quantum state to the first quantum state.

[0251] In some embodiments, as Figure 14 shown, the operator set determination module 1303 includes: a horizontal decomposition sub-module 1303a, an operator determination sub-module 1303b, and a vertical decomposition sub-module 1303c.

[0252] The horizontal decomposition sub-module 1303a is configured to perform multiple horizontal recursive decompositions on the multiple qubit sets in units of the qubit set under the grid constraint in the horizontal direction of the grid to obtain multiple qubit columns; wherein, the row width of the qubit column is the same as the row width of the sub-grid, and the column width of the qubit column is the same as the column width of the grid.

[0253] The operator determination sub-module 1303b is configured to determine the assignment operator and the permutation operator corresponding to each horizontal recursive decomposition during the multiple horizontal recursive decomposition process, and to construct a sub-preparation operator architecture corresponding to the horizontal recursive decomposition.

[0254] The vertical decomposition sub-module 1303c is configured to perform multiple vertical recursive decompositions on each of the qubit columns in the vertical direction of the grid, with the qubit set as a unit, and obtain multiple transformed qubit sets under the limitation of the grid; wherein, the transformed qubit sets correspond to the qubit sets one by one, the row width of the transformed qubit sets is the same as the row width of the sub-grid, and the column width of the transformed qubit sets is the same as the column width of the sub-grid.

[0255] The operator determination sub-module 1303b is further configured to determine the assignment operator and the permutation operator corresponding to each vertical recursive decomposition during the multiple vertical recursive decompositions, and construct the preparation operator architecture on the basis of the sub-preparation operator architecture.

[0256] The operator determination sub-module 1303b is further configured to obtain the set of assignment operators based on the assignment operators corresponding to each horizontal recursive decomposition and the assignment operators corresponding to each vertical recursive decomposition.

[0257] The operator determination sub-module 1303b is further configured to obtain the set of permutation operators based on the permutation operators corresponding to each horizontal recursive decomposition and the permutation operators corresponding to each vertical recursive decomposition.

[0258] The operator determination sub-module 1303b is further configured to determine the unitary operator of each of the transformed qubit sets to obtain the set of unitary operators.

[0259] In some embodiments, the value of k is equal to the Hamming weight of the first quantum state; the horizontal decomposition sub-module 1303a is configured to:

[0260] During the first horizontal recursive decomposition process, divide the multiple qubit sets into 2 first-order initial qubit columns under the limitation of the grid; perform weight assignment on the first qubit set and the second qubit set from the left in the first row of the first first-order initial qubit column from the left to obtain the adjusted first first-order initial qubit column; perform quantum state exchange on the second qubit set from the left in the first row of the adjusted first first-order initial qubit column and the first qubit set from the left in the first row of the second first-order initial qubit column from the left to obtain 2 first-order qubit columns;

[0261] Alternatively, in the r-th horizontal recursive decomposition process, for each (r - 1)-th order qubit column, under the grid constraint, the (r - 1)-th order qubit column is divided into two r-th order initial qubit columns, where r is an integer greater than 1; weight distribution is performed on the leftmost first qubit set and the leftmost second qubit set in the first row of the leftmost first r-th order initial qubit column to obtain the adjusted first r-th order initial qubit column; quantum state exchange is performed on the leftmost second qubit set in the first row of the adjusted first r-th order initial qubit column and the leftmost first qubit set in the first row of the leftmost second r-th order initial qubit column to obtain two r-th order qubit columns;

[0262] Wherein, when the row width of the r-th order qubit column is the same as the row width of the sub-grid, the r-th order qubit column is determined as the qubit column.

[0263] In some embodiments, the operator determination sub-module 1303b is configured to:

[0264] In the first horizontal recursive decomposition process, based on the leftmost first qubit set and the leftmost second qubit set in the first row of the leftmost first 1st order initial qubit column, determine the assignment operator corresponding to the first horizontal recursive decomposition; based on the leftmost second qubit set in the first row of the adjusted first 1st order initial qubit column and the leftmost first qubit set in the first row of the leftmost second 1st order initial qubit column, determine the permutation operator corresponding to the first horizontal recursive decomposition; based on the two 1st order qubit columns, determine the sub-preparation operator architecture corresponding to the first horizontal recursive decomposition;

[0265] Alternatively, in the r-th horizontal recursive decomposition process, for each (r - 1)-th order qubit column, based on the first qubit set and the second qubit set from the left in the first row of the first r-th order initial qubit column, determine the sub-allocation operator corresponding to the (r - 1)-th order qubit column in the r-th horizontal recursive decomposition; based on the second qubit set from the left in the first row of the adjusted first r-th order initial qubit column and the first qubit set from the left in the first row of the second r-th order initial qubit column, determine the sub-permutation operator corresponding to the (r - 1)-th order qubit column in the r-th horizontal recursive decomposition; based on the sub-allocation operators corresponding to each (r - 1)-th order qubit column in the r-th horizontal recursive decomposition, obtain the allocation operator corresponding to the r-th horizontal recursive decomposition; based on the sub-permutation operators corresponding to each (r - 1)-th order qubit column in the r-th horizontal recursive decomposition, obtain the permutation operator corresponding to the r-th horizontal recursive decomposition; based on the two r-th order qubit columns corresponding to each (r - 1)-th order qubit column and the sub-preparation operator architecture corresponding to the (r - 1)-th horizontal recursive decomposition, determine the sub-preparation operator architecture corresponding to the r-th horizontal recursive decomposition.

[0266] In some embodiments, the longitudinal decomposition sub-module 1303c is configured to:

[0267] In the first longitudinal recursive decomposition process, for each qubit column, divide the qubit column into two first-order initial qubit rows under the grid constraint; perform weight allocation on the first qubit set and the second qubit set from the top in the first first-order initial qubit row from the top to obtain the adjusted first first-order initial qubit row; perform quantum state exchange on the second qubit set from the top in the adjusted first first-order initial qubit row and the first qubit set from the top in the second first-order initial qubit row from the top to obtain two first-order qubit rows:

[0268] Alternatively, in the s-th longitudinal recursive decomposition process, for each (s - 1)-th order qubit row, divide the (s - 1)-th order qubit row into two r-th order initial qubit rows under the grid constraint, where s is an integer greater than 1; perform weight allocation on the first qubit set and the second qubit set from the top in the first s-th order initial qubit row from the top to obtain the adjusted first s-th order initial qubit row; perform quantum state exchange on the second qubit set from the top in the adjusted first s-th order initial qubit row and the first qubit set from the top in the second s-th order initial qubit row from the top to obtain two s-th order qubit rows;

[0269] Wherein, when the column width of the s-th order qubit row is the same as the column width of the sub-grid, the s-th order qubit column is determined as the converted qubit set.

[0270] In some embodiments, the operator determination sub-module 1303b is further configured to:

[0271] In the first longitudinal recursive decomposition process, for each qubit column, based on the first qubit set and the second qubit set from the top in the first-order initial qubit row, determine the assignment operator corresponding to the first longitudinal recursive decomposition; based on the second qubit set from the top in the adjusted first-order initial qubit row and the first qubit set from the top in the second first-order initial qubit row, determine the permutation operator corresponding to the first longitudinal recursive decomposition; based on the two first-order qubit rows and the sub-preparation operator architecture corresponding to the transverse recursive decomposition, construct the sub-preparation operator architecture corresponding to the first longitudinal recursive decomposition;

[0272] Alternatively, in the s-th longitudinal recursive decomposition process, for each (s - 1)-th order qubit row, based on the first qubit set and the second qubit set from the top in the first s-th order initial qubit row, determine the sub-assignment operator corresponding to the (s - 1)-th order qubit row in the s-th longitudinal recursive decomposition; based on the first qubit set from the top in the adjusted first s-th order initial qubit row and the first qubit set from the top in the second s-th order initial qubit row, determine the sub-permutation operator corresponding to the (s - 1)-th order qubit row in the s-th longitudinal recursive decomposition; based on the sub-assignment operators corresponding to each (s - 1)-th order qubit row in the s-th longitudinal recursive decomposition, obtain the assignment operator corresponding to the s-th longitudinal recursive decomposition; based on the sub-permutation operators corresponding to each (s - 1)-th order qubit row in the s-th longitudinal recursive decomposition, obtain the permutation operator corresponding to the s-th longitudinal recursive decomposition; based on the two s-th order qubit rows corresponding to each (s - 1)-th order qubit row and the sub-preparation operator architecture corresponding to the (s - 1)-th longitudinal recursive decomposition, determine the sub-preparation operator architecture corresponding to the s-th longitudinal recursive decomposition.

[0273] In some embodiments, the preparation operator determination module 1304 is further configured to:

[0274] In the longitudinal direction of the grid, divide each unitary operator in the manner of every two adjacent converted qubit sets to obtain a plurality of unitary operator pairs;

[0275] Obtain the Kronecker product of each of the plurality of unitary operator pairs;

[0276] Determine the positions and operation symbols of each of the Kronecker products, each of the distribution operators, and each of the permutation operators in the preparation operator architecture according to the operation relationships indicated by the preparation operator architecture;

[0277] Combine each of the Kronecker products, each of the distribution operators, and each of the permutation operators according to their positions and operation symbols in the preparation operator architecture to obtain the quantum state preparation operator.

[0278] In some embodiments, as Figure 14 shown, the apparatus 1300 further includes: a quantum state initialization module 1306.

[0279] The quantum state initialization module 1306 is configured to permute the quantum state of the leftmost qubit set in the first row of the plurality of qubit sets to 1, and permute the quantum states of the remaining qubit sets in the plurality of qubit sets to 0.

[0280] In some embodiments, each row of the grid corresponds to n2 qubits, each column of the grid corresponds to n1 qubits, n = n1n2, n2 ≥ n1, n1 is a positive integer, and n2 is a positive integer;

[0281] In the case where k ≥ n2 / n1, the rows of the sub-grid correspond to qubits, and the columns of the sub-grid correspond to qubits;

[0282] Alternatively, in the case where 1 ≤ k ≤ n2 / n1, the rows of the sub-grid correspond to k qubits, and the columns of the sub-grid correspond to 1 qubit.

[0283] In some embodiments, the distribution operator is implemented by a quantum circuit with a circuit depth of O(k), the permutation operator is implemented by a quantum circuit with a circuit depth of O(n1 / 2) or O(n2 / 2), the unitary operator is implemented by a quantum circuit with a circuit depth of O(k), and the circuit depth of the quantum state preparation circuit corresponding to the quantum state preparation operator is O(k log(n / k) + n2).

[0284] To summarize, the technical solution provided by the embodiment of the present application is restricted by the grid, and the allocation operator can only allocate weights to two adjacent quantum bit sets, such as allocating the weight of an allocated quantum bit set to an unallocated quantum bit set adjacent to it. The embodiment of the present application, by combining the quantum state exchange function of the permutation operator, can pull the quantum states of two adjacent quantum bit sets apart. For example, for two adjacent allocated quantum bit sets, under the restriction of the grid, the quantum state of one of the allocated quantum bit sets can be replaced by the quantum state of an unallocated quantum bit set through the permutation operator. In this way, the replaced unallocated quantum bit set can allocate the weight to the unallocated quantum bit set adjacent to it, and the other allocated quantum bit set can allocate the weight to the replaced allocated quantum bit set. Therefore, for n quantum bits under the grid restriction, the Hamming weight of the first quantum state is distributed to multiple quantum bit sets by combining the allocation operator and the permutation operator, which can realize the simultaneous distribution of the Hamming weight based on multiple quantum bit sets, thereby improving the operational parallelism of the quantum state preparation operator, and thereby reducing the circuit depth of the quantum state preparation circuit corresponding to the quantum state preparation operator.

[0285] It should be noted that the device provided in the above embodiment, when implementing its functions, is only illustrated by the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the device and method embodiments provided in the above embodiment belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.

[0286] Please refer to Figure 15 , which shows a block diagram of a computer device provided in one embodiment of the present application. The computer device can be used to implement the method for preparing a quantum state provided in the above embodiment, which specifically may include the following contents.

[0287] The computer device 1500 includes a central processing unit (such as a CPU (Central Processing Unit), a GPU (Graphics Processing Unit), and an FPGA (Field Programmable Gate Array), etc.) 1501, a system memory 1504 including a RAM (Random-Access Memory) 1502 and a ROM (Read-Only Memory) 1503, and a system bus 1505 connecting the system memory 1504 and the central processing unit 1501. The computer device 1500 further includes a basic input / output system (Input Output System, I / O system) 1506 for facilitating the transfer of information between various components within the server, and a mass storage device 1507 for storing an operating system 1513, application programs 1514, and other program modules 1515.

[0288] The basic input / output system 1506 includes a display 1508 for displaying information and input devices 1509 such as a mouse and a keyboard for user input of information. Among them, both the display 1508 and the input devices 1509 are connected to the central processing unit 1501 through an input / output controller 1510 connected to the system bus 1505. The basic input / output system 1506 may further include an input / output controller 1510 for receiving and processing inputs from multiple other devices such as a keyboard, a mouse, or an electronic stylus. Similarly, the input / output controller 1510 also provides outputs to a display screen, a printer, or other types of output devices.

[0289] The mass storage device 1507 is connected to the central processing unit 1501 through a mass storage controller (not shown) connected to the system bus 1505. The mass storage device 1507 and its associated computer-readable medium provide non-volatile storage for the computer device 1500. That is to say, the mass storage device 1507 may include a computer-readable medium (not shown) such as a hard disk or a CD-ROM (Compact Disc Read-Only Memory) drive.

[0290] Without loss of generality, the computer-readable medium may include a computer storage medium and a communication medium. The computer storage medium includes volatile and non-volatile, removable and non-removable media implemented by any method or technology for storing information such as computer-readable instructions, data structures, program modules, or other data. The computer storage medium includes RAM, ROM, EPROM (Erasable Programmable Read-Only Memory), EEPROM (Electrically Erasable Programmable Read-Only Memory), flash memory or other solid-state storage technologies, CD-ROM, DVD (Digital Video Disc) or other optical storage, magnetic tape cartridges, tapes, disk storage or other magnetic storage devices. Of course, those skilled in the art will know that the computer storage medium is not limited to the above several types. The above-mentioned system memory 1504 and mass storage device 1507 can be collectively referred to as memory.

[0291] According to an embodiment of the present application, the computer device 1500 can also run by connecting to a remote computer on the network through a network such as the Internet. That is, the computer device 1500 can be connected to the network 1512 through the network interface unit 1511 connected to the system bus 1505, or in other words, the network interface unit 1511 can also be used to connect to other types of networks or remote computer systems (not shown).

[0292] The memory further includes a computer program, which is stored in the memory and is configured to be executed by one or more processors to implement the above-mentioned method for preparing a quantum state.

[0293] In some embodiments, a computer-readable storage medium is also provided. A computer program is stored in the storage medium, and when the computer program is executed by a processor, it is used to implement the above-mentioned method for preparing a quantum state.

[0294] Optionally, the computer-readable storage medium may include: ROM (Read-Only Memory), RAM (Random Access Memow), SSD (Solid State Drives) or optical discs, etc. Among them, the random access memory may include ReRAM (Resistance Random Access Memory) and DRAM (Dynamic Random Access Memory).

[0295] In some embodiments, a computer program product is further provided. The computer program product includes a computer program stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium, and the processor executes the computer program, so that the computer device executes the above-mentioned method for preparing a quantum state.

[0296] In some embodiments, a quantum chip is further provided. The quantum chip includes a quantum preparation circuit constructed based on a quantum state preparation operator obtained by executing the above-mentioned method for preparing a quantum state.

[0297] It should be noted that, before and during the process of collecting relevant data of the user in the embodiments of the present application, a prompt interface, a pop-up window or a voice prompt message can be displayed. The prompt interface, the pop-up window or the voice prompt message is used to prompt the user that their relevant data is currently being collected, so that the present application only starts to execute the relevant steps of obtaining the user's relevant data after obtaining the confirmation operation of the user on the prompt interface or the pop-up window. Otherwise (that is, when the confirmation operation of the user on the prompt interface or the pop-up window is not obtained), the relevant steps of obtaining the user's relevant data are ended, that is, the relevant data of the user is not obtained. In other words, all user data collected by the present application is processed strictly in accordance with the requirements of relevant national laws and regulations. Obtaining the informed consent or separate consent of the personal information subject is carried out under the condition of the user's consent and authorization, and subsequent data use and processing behaviors are carried out within the scope of laws, regulations and the authorization of the personal information subject, and the collection, use and processing of relevant user data need to comply with the relevant laws, regulations and standards of relevant countries and regions. For example, the grid restrictions, quantum bits, quantum state preparation circuits, etc. involved in the present application are all obtained under full authorization.

[0298] It should be understood that "a plurality of" mentioned herein refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships can exist. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone. The character " / " generally represents an "or" relationship between the associated objects before and after. In addition, the step numbers described in this article only exemplarily show a possible execution sequence between steps. In some other embodiments, the above steps may not be executed in the order of the numbers. For example, two steps with different numbers are executed simultaneously, or two steps with different numbers are executed in the reverse order of the illustration. The embodiments of the present application do not limit this.

[0299] The foregoing are only exemplary embodiments of the present application and are not intended to limit the present application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principle of the present application shall be included within the protection scope of the present application.

Claims

1. A method for preparing a quantum state, characterized in that, The method includes: Obtaining n qubits under grid constraints and the initial quantum states of the n qubits, where n is a positive integer; Dividing the n qubits into multiple qubit sets, where each qubit set includes k qubits, and the connections of the k qubits satisfy sub-grid constraints, and the sub-grids corresponding to the sub-grid constraints form the grid corresponding to the grid constraints, and k is a positive integer less than n; During the process of recursively decomposing the n qubits with the qubit sets as units under the grid constraints, determining an assignment operator set, a permutation operator set, and a unitary operator set, and a preparation operator architecture; wherein, each assignment operator in the assignment operator set and each permutation operator in the permutation operator set are used to distribute the Hamming weight of the first quantum state to the multiple qubit sets and to entangle the multiple qubit sets with each other, the permutation operator is used to exchange the quantum states between two qubit sets, each unitary operator in the unitary operator set is used to evolve the quantum state of the qubit set to the first quantum state, and the preparation operator architecture is used to indicate the operation relationship between the assignment operator, the permutation operator, and the unitary operator; Under the constraint of the operation relationship indicated by the preparation operator architecture, combining the respective assignment operators, the respective permutation operators, and the respective unitary operators to obtain a quantum state preparation operator; Applying the quantum state preparation operator to the n qubits so that the quantum states of the n qubits evolve from the initial quantum states to the first quantum state.

2. The method according to claim 1, characterized in that The step of determining an assignment operator set, a permutation operator set, and a unitary operator set, and a preparation operator architecture during the process of recursively decomposing the n qubits with the qubit sets as units under the grid constraints includes: In the horizontal direction of the grid, with the qubit sets as units, performing multiple horizontal recursive decompositions on the multiple qubit sets under the grid constraints to obtain multiple qubit columns; wherein, the row width of the qubit column is the same as the row width of the sub-grid, and the column width of the qubit column is the same as the column width of the grid; During the multiple horizontal recursive decomposition processes, determining the assignment operators and permutation operators corresponding to each horizontal recursive decomposition, and constructing the sub-preparation operator architecture corresponding to the horizontal recursive decomposition; For each qubit column, in the vertical direction of the grid, with the qubit sets as units, performing multiple vertical recursive decompositions on the qubit column under the grid constraints to obtain multiple transformed qubit sets; wherein, the transformed qubit sets correspond one-to-one with the qubit sets, the row width of the transformed qubit set is the same as the row width of the sub-grid, and the column width of the transformed qubit set is the same as the column width of the sub-grid; During the multiple vertical recursive decomposition processes, determining the assignment operators and permutation operators corresponding to each vertical recursive decomposition, and on the basis of the sub-preparation operator architecture, constructing the preparation operator architecture; Based on the distribution operators corresponding to each horizontal recursive decomposition and the distribution operators corresponding to each vertical recursive decomposition, the set of distribution operators is obtained; Based on the permutation operators corresponding to each horizontal recursive decomposition and the permutation operators corresponding to each vertical recursive decomposition, the set of permutation operators is obtained; Determine the unitary operators of each of the transformed qubit sets to obtain the set of unitary operators.

3. The method according to claim 2, wherein The value of k is equal to the Hamming weight of the first quantum state; In the horizontal direction of the grid, with the qubit sets as units, multiple horizontal recursive decompositions of the multiple qubit sets are performed under the grid constraint, obtaining multiple qubit columns, including: In the first horizontal recursive decomposition process, under the grid constraint, the multiple qubit sets are divided into 2 first-order initial qubit columns; weight distribution is performed on the first qubit set and the second qubit set from the left in the first row of the first first-order initial qubit column from the left, obtaining the adjusted first first-order initial qubit column; quantum state exchange is performed on the second qubit set from the left in the first row of the adjusted first first-order initial qubit column and the first qubit set from the left in the first row of the second first-order initial qubit column from the left, obtaining 2 first-order qubit columns; Or, In the r-th horizontal recursive decomposition process, for each (r - 1)-th order qubit column, under the grid constraint, the (r - 1)-th order qubit column is divided into 2 r-th order initial qubit columns, where r is an integer greater than 1; weight distribution is performed on the first qubit set and the second qubit set from the left in the first row of the first r-th order initial qubit column from the left, obtaining the adjusted first r-th order initial qubit column; quantum state exchange is performed on the second qubit set from the left in the first row of the adjusted first r-th order initial qubit column and the first qubit set from the left in the first row of the second r-th order initial qubit column from the left, obtaining 2 r-th order qubit columns; Among them, when the row width of the r-th order qubit column is the same as the row width of the sub-grid, the r-th order qubit column is determined as the qubit column.

4. The method according to claim 3, wherein During the multiple horizontal recursive decomposition processes, determine the distribution operators and permutation operators corresponding to each horizontal recursive decomposition, and construct the sub-preparation operator architecture corresponding to the horizontal recursive decomposition, including: In the first horizontal recursive decomposition process, based on the first qubit set and the second qubit set from the left in the first row of the first first-order initial qubit column from the left, determine the distribution operator corresponding to the first horizontal recursive decomposition; based on the second qubit set from the left in the first row of the adjusted first first-order initial qubit column and the first qubit set from the left in the first row of the second first-order initial qubit column from the left, determine the permutation operator corresponding to the first horizontal recursive decomposition; based on the 2 first-order qubit columns, determine the sub-preparation operator architecture corresponding to the first horizontal recursive decomposition; Or, In the r-th horizontal recursive decomposition process, for each (r - 1)-th order qubit column, based on the first qubit set and the second qubit set from the left in the first row of the first (r)-th order initial qubit column, determine the sub-allocation operator corresponding to the (r - 1)-th order qubit column in the r-th horizontal recursive decomposition; based on the second qubit set from the left in the first row of the adjusted first (r)-th order initial qubit column and the first qubit set from the left in the first row of the second (r)-th order initial qubit column, determine the sub-permutation operator corresponding to the (r - 1)-th order qubit column in the r-th horizontal recursive decomposition; based on the sub-allocation operators corresponding to each (r - 1)-th order qubit column in the r-th horizontal recursive decomposition, obtain the allocation operator corresponding to the r-th horizontal recursive decomposition; based on the sub-permutation operators corresponding to each (r - 1)-th order qubit column in the r-th horizontal recursive decomposition, obtain the permutation operator corresponding to the r-th horizontal recursive decomposition; based on the two (r)-th order qubit columns corresponding to each (r - 1)-th order qubit column and the sub-preparation operator architecture corresponding to the (r - 1)-th horizontal recursive decomposition, determine the sub-preparation operator architecture corresponding to the r-th horizontal recursive decomposition.

5. The method according to claim 2, wherein For each of the qubit columns, in the longitudinal direction of the grid, with the qubit set as a unit, perform multiple longitudinal recursive decompositions on the qubit column under the grid constraint to obtain multiple transformed qubit sets, including: In the first longitudinal recursive decomposition process, for each of the qubit columns, divide the qubit column into two first-order initial qubit rows under the grid constraint; perform weight allocation on the first qubit set and the second qubit set from the top in the first first-order initial qubit row to obtain the adjusted first first-order initial qubit row; perform quantum state exchange on the second qubit set from the top in the adjusted first first-order initial qubit row and the first qubit set from the top in the second first-order initial qubit row to obtain two first-order qubit rows; Or, In the s-th longitudinal recursive decomposition process, for each (s - 1)-th order qubit row, divide the (s - 1)-th order qubit row into two r-th order initial qubit rows under the grid constraint, where s is an integer greater than 1; perform weight allocation on the first qubit set and the second qubit set from the top in the first s-th order initial qubit row to obtain the adjusted first s-th order initial qubit row; perform quantum state exchange on the second qubit set from the top in the adjusted first s-th order initial qubit row and the first qubit set from the top in the second s-th order initial qubit row to obtain two s-th order qubit rows; Wherein, when the column width of the s-th order qubit row is the same as the column width of the sub-grid, the s-th order qubit column is determined as the transformed qubit set.

6. The method according to claim 5, characterized in that, During the multiple vertical recursive decomposition processes, determining the distribution operator and permutation operator corresponding to each vertical recursive decomposition, and on the basis of the sub-preparation operator architecture, constructing the preparation operator architecture, includes: During the first vertical recursive decomposition process, for each of the qubit columns, based on the first qubit set and the second qubit set from the first row of the first-order initial qubits, determining the distribution operator corresponding to the first vertical recursive decomposition; based on the second qubit set from the first row of the adjusted first-order initial qubits and the first qubit set from the first row of the second first-order initial qubits, determining the permutation operator corresponding to the first vertical recursive decomposition; based on the two first-order qubit rows and the sub-preparation operator architecture corresponding to the horizontal recursive decomposition, constructing the sub-preparation operator architecture corresponding to the first vertical recursive decomposition; Or, During the s-th vertical recursive decomposition process, for each of the (s - 1)-order qubit rows, based on the first qubit set and the second qubit set from the first row of the s-th order initial qubits, determining the sub-distribution operator corresponding to the (s - 1)-order qubit row in the s-th vertical recursive decomposition; based on the first qubit set from the first row of the adjusted s-th order initial qubits and the first qubit set from the first row of the second s-th order initial qubits, determining the sub-permutation operator corresponding to the (s - 1)-order qubit row in the s-th vertical recursive decomposition; based on the sub-distribution operators corresponding to each of the (s - 1)-order qubit rows in the s-th vertical recursive decomposition, obtaining the distribution operator corresponding to the s-th vertical recursive decomposition; based on the sub-permutation operators corresponding to each of the (s - 1)-order qubit rows in the s-th vertical recursive decomposition, obtaining the permutation operator corresponding to the s-th vertical recursive decomposition; based on the two s-th order qubit rows corresponding to each of the (s - 1)-order qubit rows and the sub-preparation operator architecture corresponding to the (s - 1)-th vertical recursive decomposition, determining the sub-preparation operator architecture corresponding to the s-th vertical recursive decomposition.

7. The method according to claim 2, wherein Under the operation relation constraints indicated by the preparation operator architecture, combining the respective distribution operators, the respective permutation operators, and the respective unitary operators to determine the quantum state preparation operator, includes: In the vertical direction of the grid, dividing the respective unitary operators in the manner of every two adjacent transformed qubit sets, to obtain a plurality of unitary operator pairs; Obtaining the Kronecker product of each of the plurality of unitary operator pairs; According to the operation relations indicated by the preparation operator architecture, determining the positions and operation symbols of each of the Kronecker products, each of the distribution operators, and each of the permutation operators in the preparation operator architecture; According to the positions and operation symbols of the respective Kronecker products, the respective distribution operators, and the respective permutation operators in the preparation operator architecture, the respective Kronecker products, the respective distribution operators, and the respective permutation operators are combined to obtain the quantum state preparation operator.

8. The method according to claim 1, characterized in that, Before determining the set of distribution operators, the set of permutation operators, the set of unitary operators, and the preparation operator architecture in the process of recursively decomposing the n qubits under the grid restriction with the qubit sets as units, it further includes: Permute the quantum state of the leftmost qubit set in the first row of the multiple qubit sets to 1, and permute the quantum states of the remaining qubit sets in the multiple qubit sets to 0.

9. The method according to claim 1, wherein Each row of the grid corresponds to n2 qubits, each column of the grid corresponds to n1 qubits, n = n1n2, n2 ≥ n1, n1 is a positive integer, and n2 is a positive integer; When \(k\geq\frac{n_2}{n_1}\), the rows of the sub-grid correspond to qubits, and the columns of the sub-grid correspond to qubits; Or, When 1 ≤ k ≤ n2 / n1, each row of the sub-grid corresponds to k qubits, and each column of the sub-grid corresponds to 1 qubit.

10. The method according to claim 9, characterized in that, The distribution operator is implemented by a quantum circuit with a circuit depth of O(k), the permutation operator is implemented by a quantum circuit with a circuit depth of O(n1 / 2) or O(n2 / 2), the unitary operator is implemented by a quantum circuit with a circuit depth of O(k), and the circuit depth of the quantum state preparation circuit corresponding to the quantum state preparation operator is O(k log(n / k) + n2).

11. A preparation device for a quantum state, characterized in that, The apparatus includes: An initial quantum state acquisition module, configured to acquire n qubits under a grid restriction and the initial quantum states of the n qubits, where n is a positive integer; A qubit partitioning module, configured to partition the n qubits into multiple qubit sets, where each qubit set includes k qubits, and the connection of the k qubits satisfies a sub-grid restriction, and the sub-grids corresponding to the sub-grid restrictions are combined into the grid corresponding to the grid restriction, and k is a positive integer less than n; An operator set determination module, configured to determine the set of distribution operators, the set of permutation operators, the set of unitary operators, and the preparation operator architecture in the process of recursively decomposing the n qubits under the grid restriction with the qubit sets as units; wherein, each distribution operator in the set of distribution operators and each permutation operator in the set of permutation operators are used to distribute the Hamming weight of the first quantum state to the multiple qubit sets and to entangle the multiple qubit sets with each other, the permutation operator is used to swap the quantum states between two qubit sets, each unitary operator in the set of unitary operators is used to evolve the quantum state of the qubit set to the first quantum state, and the preparation operator architecture is used to indicate the operation relationship between the distribution operator, the permutation operator, and the unitary operator; A preparation operator determination module, configured to combine the respective distribution operators, the respective permutation operators, and the respective unitary operators under the constraint of the operation relationship indicated by the preparation operator architecture to obtain a quantum state preparation operator; A quantum state evolution module, configured to apply the quantum state preparation operator to the n qubits, so that the quantum state of the n qubits evolves from the initial quantum state to the first quantum state.

12. A computer device, characterized in that, The computer device includes a processor and a memory. A computer program is stored in the memory and is loaded and executed by the processor to implement the quantum state preparation method according to any one of claims 1 to 10 above.

13. A computer-readable storage medium, characterized in that, A computer program is stored in the computer-readable storage medium and is loaded and executed by a processor to implement the quantum state preparation method according to any one of claims 1 to 10 above.

14. A computer program product, characterized in that, The computer program product includes a computer program. The computer program is stored in a computer-readable storage medium, and a processor reads and executes the computer program from the computer-readable storage medium to implement the quantum state preparation method according to any one of claims 1 to 10.

15. A quantum chip, characterized in that, The quantum chip includes a quantum preparation circuit constructed based on the quantum state preparation operator according to any one of claims 1 to 10.