Fermionic operator sparsification method and quantum computing device

The quantum computing device converts the fermion operator string into a boson operator string and calculates the mask information, which solves the problem of low efficiency of fermion operator sparse matrix calculation in the existing technology and achieves more efficient sparse matrix calculation. .

WO2024174872A1PCT designated stage expired Publication Date: 2024-08-29HUAWEI TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/076094
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-02-21
Filing Date
2024-02-05
Publication Date
2024-08-29

AI Technical Summary

Technical Problem

The existing technology consumes a large amount of computing resources and storage resources when calculating the sparse matrix of fermion operators, and the calculation efficiency is low. Especially for fermion operator strings containing multiple fermion operators, the complexity of the existing algorithm is O( m*2n, resulting in long calculation time.

Method used

The fermion operator string of the target chemical molecule is converted into a boson operator string through a quantum computing device, and the mask information is determined based on the boson operator string, and then the sparse matrix is ​​calculated, and only non-zero elements are calculated to avoid redundancy. calculation and improve calculation efficiency.

Benefits of technology

It significantly reduces the resource consumption and time of calculating sparse matrices, improves the efficiency of sparse matrix calculations, and achieves more efficient sparse matrix calculations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024076094_29082024_PF_FP_ABST
    Figure CN2024076094_29082024_PF_FP_ABST
Patent Text Reader

Abstract

The present application provides a fermionic operator sparsification method and a quantum computing device. The method comprises: a quantum computing device can: first determine, according to molecular structure information of a target chemical molecule, a first fermionic operator string corresponding to the target chemical molecule; then transform the first fermionic operator string to obtain a corresponding first boson operator string; then, when a plurality of first boson operators comprised in the first boson operator string do not comprise a first boson operator having a value of zero, determine mask information corresponding to the plurality of first boson operators; and determine a sparse matrix of the first fermionic operator string according to the mask information corresponding to the plurality of first boson operators. In this way, according to the method, the sparse matrix is computed when the plurality of first boson operators do not comprise a first boson operator having a value of zero, so that the generation of any redundant computation can be avoided, fewer computing resources are consumed and fewer storage resources are occupied, thereby effectively improving the efficiency of computing a sparse matrix.
Need to check novelty before this filing date? Find Prior Art

Description

A fermion operator sparsification method and quantum computing device

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS

[0002] This application claims priority to the Chinese patent application filed with the State Intellectual Property Office of China on February 21, 2023, with application number 202310187289.1 and application name “A Fermion Operator Sparsification Method and Quantum Computing Device”, the entire contents of which are incorporated by reference into this application. Technical Field

[0003] The present application relates to the field of quantum computing technology, and in particular to a fermion operator sparsification method and a quantum computing device. Background Art

[0004] Quantum computing is a computational paradigm that uses the principles of quantum mechanics, using quantum bits as the basic computing unit, to run quantum algorithms. Due to quantum properties such as quantum entanglement and superposition, quantum computers can achieve polynomial or even exponential efficiency improvements over classical computing for specific algorithms. During the Noisy Intermediate-Scale Quantum (NISQ) era, researchers designed various algorithms that demonstrate quantum superiority, such as variational quantum algorithms, which are hybrid quantum and classical algorithms. For variational quantum algorithms, a quantum computer first runs a parameterized quantum circuit to obtain a quantum state. The quantum computer then measures this quantum state to obtain classical physical quantities. The classical computer then optimizes the parameterized quantum circuit based on these classical physical quantities, thereby completing the computation of the variational quantum algorithm.

[0005] Using variational quantum algorithms, researchers have developed a variety of quantum computing applications, including the Variational Quantum Eigensolver (VQE) algorithm for solving the ground-state energy of chemical molecules, quantum machine learning algorithms for quantum artificial intelligence research, and quantum approximate optimization algorithms for solving combinatorial optimization problems. Among these algorithms, quantum chemistry simulations using the VQE algorithm have shown the greatest development advantages and have been successfully applied to fields such as drug design, catalyst design, and energy material design. In the VQE algorithm, quantum bits are used to describe the occupied or unoccupied states of chemical molecular orbitals. A variational quantum circuit composed of parameterized quantum gates evolves the initial quantum state. By measuring the evolved quantum modes, the expected value E of the chemical molecule's Hamiltonian with respect to this quantum state can be calculated. A classical optimizer is then used to continuously optimize the parameters of the variational quantum circuit to minimize the expected value E and reach E0, which is the ground-state energy of the chemical molecule. Among them, in order to solve the ground state energy of the chemical molecule, it is necessary to calculate the sparse matrix of multiple fermion operators in the unitary coupling cluster operator T contained in the expectation value E and the sparse matrix of multiple fermion operators contained in the Hamiltonian H contained in the expectation value E.

[0006] However, in the prior art, in the process of calculating sparse matrices, matrix direct product operations and matrix multiplication operations are required, which consumes more computing resources and storage resources, and the computing time consumed by the prior art is also longer, resulting in low computational efficiency of sparse matrices. For example, for a fermion operator string that occupies n bits and consists of m fermion operators, the algorithm complexity of converting the fermion operator string into a sparse matrix using the prior art is O(m*2 n ).

[0007] Summary of the Invention

[0008] The embodiments of the present application provide a fermion operator sparsification method and a quantum computing device to effectively improve the computational efficiency of sparse matrices.

[0009] In a first aspect, an embodiment of the present application provides a fermion operator sparsification method, which can be performed by a quantum computing device or a component (such as a chip system or circuit, etc.) that can support the quantum computing device to implement the functions required by the method. Optionally, taking the quantum computing device executing the fermion operator sparsification method as an example, in this method, the quantum computing device can first determine the first fermion operator string corresponding to the target chemical molecule based on the molecular structure information of the target chemical molecule. Thereafter, the quantum computing device can transform the first fermion operator string to obtain the corresponding first bosonic operator string, wherein the first bosonic operator string can include multiple first bosonic operators. When there is no first bosonic operator with a value of zero among the multiple first bosonic operators, the quantum computing device can determine the mask information corresponding to the multiple first bosonic operators, and can determine the sparse matrix of the first fermion operator string based on the mask information corresponding to the multiple first bosonic operators. Optionally, the sparse matrix can be used to determine the ground state energy of the target chemical molecule.

[0010] In the above design, the quantum computing device starts to execute the process of calculating the sparse matrix of the first fermion operator string when the multiple first bosonic operators contained in the first bosonic operator string meet certain conditions (there is no first bosonic operator with a value of zero among the multiple first bosonic operators). This ensures that the calculation of the sparse matrix only involves non-zero elements, helps to avoid any redundant calculations, and consumes relatively few computing resources and occupies relatively few storage resources, so that the sparse matrix can be obtained more efficiently, effectively improving the calculation efficiency of the sparse matrix.

[0011] In one possible design, the multiple first boson operators may include a first target boson operator, a second target boson operator, a third target boson operator, a fourth target boson operator, and a fifth target boson operator; each first boson operator corresponds to a quantum bit;

[0012] The first target boson operator or the second target boson operator is a first boson operator among the multiple first boson operators, and the multiple result values ​​generated by the multiple quantum states are all non-zero. The third target boson operator, the fourth target boson operator, or the fifth target boson operator is a first boson operator among the multiple first boson operators, and the multiple result values ​​generated by the multiple quantum states have at least one result value of zero. The first target boson operator, the second target boson operator, the third target boson operator, the fourth target boson operator, and the fifth target boson operator are different from each other.

[0013] The mask information includes at least one of the following: the number of at least one non-zero element included in the position mask, the mask array, or the sparse matrix;

[0014] The quantum computing device determines mask information corresponding to a plurality of first bosonic operators, including:

[0015] The quantum computing device may determine the number of at least one non-zero element included in the sparse matrix according to the number of the first target bosonic operators and the number of the second target bosonic operators; or

[0016] The quantum computing device may determine a mask array required for calculating the sparse matrix based on the qubits corresponding to the first target bosonic operator and the qubits corresponding to the second target bosonic operator; or

[0017] The quantum computing device may determine a position mask of the third target bosonic operator based on the quantum bit corresponding to the third target bosonic operator; or

[0018] The quantum computing device may determine a position mask of the fourth target bosonic operator based on the quantum bit corresponding to the fourth target bosonic operator; or

[0019] The quantum computing device can determine the position mask of the fifth target bosonic operator based on the quantum bit corresponding to the fifth target bosonic operator.

[0020] In the above design, the quantum computing device can calculate the mask information corresponding to the first bosonic operator string in a timely and accurate manner through the multiple target bosonic operators contained in the first bosonic operator string, which helps the subsequent quantum computing device to effectively calculate the sparse matrix of the first fermion operator string based on the mask information.

[0021] In one possible design, the quantum computing device determines a sparse matrix of a first fermion operator string, including:

[0022] The quantum computing device can determine an integer sequence required for calculating the sparse matrix based on the number of at least one non-zero element contained in the sparse matrix, where the integer sequence includes at least one integer;

[0023] The quantum computing device can determine the horizontal coordinate and vertical coordinate of each non-zero element in the sparse matrix through the following steps: the quantum computing device can select a first integer from the integer sequence and determine a binary array of the first integer; wherein the first integer corresponds to the first non-zero element, and the first non-zero element is any non-zero element in the at least one non-zero element contained in the sparse matrix; then, the quantum computing device can determine the first numerical value required for calculating the horizontal and vertical coordinates of the first non-zero element in the sparse matrix based on the mask array and the binary array of the first integer; then, the quantum computing device can determine the vertical coordinate of the first non-zero element in the sparse matrix based on the first numerical value, the position mask of the third target bosonic operator, and the position mask of the fourth target bosonic operator, and can determine the horizontal coordinate of the first non-zero element in the sparse matrix based on the first numerical value, the position mask of the third target bosonic operator, and the position mask of the fifth target bosonic operator; finally, the quantum computing device can determine the sparse matrix based on the horizontal coordinate and vertical coordinate of each non-zero element in the at least one non-zero element in the sparse matrix.

[0024] In the above design, when the quantum computing device calculates the sparse matrix of the first fermion operator string, the number of loops (i.e., the number of first integers included in the integer sequence) is the number of all non-zero elements in the sparse matrix. Therefore, the quantum computing device can obtain all non-zero elements at one time, and helps to avoid any redundant calculations in the process of calculating the sparse matrix, thereby more efficiently and directly obtaining the numerical values ​​of all non-zero elements in the sparse matrix and the horizontal and vertical coordinates of all non-zero elements in the sparse matrix.

[0025] In one possible design, the value of each non-zero element is determined by the quantum computing device based on a preset threshold;

[0026] Optionally, the quantum computing device can implement a flexible and diverse method for determining the numerical value of each non-zero element to meet the needs of different application scenarios. For example, one possible implementation method is that when the number of 1s contained in the binary value is an odd number, the quantum computing device can determine the product value of the preset threshold and the first coefficient as the numerical value of the first non-zero element. Another possible implementation method is that when the number of 1s contained in the binary value is an even number, the quantum computing device can determine the product value of the preset threshold and the second coefficient as the numerical value of the first non-zero element. The binary value is obtained by the quantum computing device performing a bitwise AND operation on the first integer and the position mask of the second target bosonic operator, and the first coefficient is different from the second coefficient.

[0027] In one possible design, the method further includes:

[0028] When only the first target boson operator and the second target boson operator are retained in the first boson operator string, the quantum computing device can first concatenate the first target boson operator and the second target boson operator to obtain a third boson operator string, in which the first target boson operator and the second target boson operator each correspond to a new quantum bit; thereafter, the quantum computing device can determine the position mask of the second target boson operator based on the new quantum bit corresponding to the second target boson operator.

[0029] In the above design, by retaining only the first target boson operator and the second target boson operator in the first boson operator string, the position mask of the second target boson operator is calculated, which makes it easier for the subsequent quantum computing device to effectively calculate the numerical value of each non-zero element.

[0030] In one possible design, a quantum computing device transforms a first fermion operator string to obtain a first bosonic operator string, including: the quantum computing device can map at least one fermion operator contained in the first fermion operator string separately to obtain multiple second bosonic operator strings; wherein any second bosonic operator string contains multiple second bosonic operators; then, the quantum computing device can perform a product operation on the second bosonic operators belonging to the same quantum bit in the multiple second bosonic operator strings to obtain multiple first bosonic operators; then, the quantum computing device can splice the multiple first bosonic operators in sequence according to the quantum bits corresponding to the multiple first bosonic operators to obtain the first bosonic operator string.

[0031] In the above design, the quantum computing device can accurately obtain the first boson operator located at the quantum bit by directly multiplying at least one second boson operator located at each quantum bit in multiple second boson operator strings, and can accurately obtain the first boson operator string by splicing the first boson operators located at multiple quantum bits without generating temporary variables. Moreover, this design involves only simple operator product operations and does not involve direct product operations or matrix product operations, so the computing resources consumed and the storage resources occupied are relatively small, which can help improve the computational efficiency of sparse matrices.

[0032] In one possible design, a quantum computing device performs a product operation on second bosonic operators belonging to the same qubit in multiple second bosonic operator strings to obtain multiple first bosonic operators, including:

[0033] The quantum computing device can select at least one second bosonic operator located at the first quantum bit from multiple second bosonic operator strings; then, the quantum computing device can perform a product operation on the at least one second bosonic operator located at the first quantum bit according to the extended Pauli operator multiplication table to obtain the first bosonic operator located at the first quantum bit.

[0034] In this design, the quantum computing device uses an extended Pauli operator multiplication table to perform a simple product operation on at least one second bosonic operator located in the same qubit, thereby promptly and accurately obtaining the first bosonic operator. This eliminates the need for complex calculations to obtain the first bosonic operator string, thus consuming relatively few computing resources and occupying relatively few storage resources.

[0035] In one possible design, the method further includes:

[0036] When there is a first bosonic operator with a value of zero among the multiple first bosonic operators, the quantum computing device can directly determine that the sparse matrix is ​​a zero matrix without calculating mask information.

[0037] In a second aspect, an embodiment of the present application provides a possible quantum computing device. The beneficial effects can be found in the description of the first aspect and will not be repeated here. The quantum computing device has the function of implementing the behavior in the method example of the first aspect. The function can be implemented by hardware or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the above functions. In one possible design, the quantum computing device includes an acquisition module and a processing module. The acquisition module is used to obtain molecular structure information of the target chemical molecule. The processing module is used to determine the first fermion operator string corresponding to the target chemical molecule based on the molecular structure information of the target chemical molecule. The processing module is also used to transform the first fermion operator string to obtain a first bosonic operator string, wherein the first bosonic operator string contains multiple first bosonic operators. The processing module is also used to determine the mask information corresponding to the multiple first bosonic operators when there is no first bosonic operator with a value of zero among the multiple first bosonic operators. The processing module is further configured to determine a sparse matrix of the first fermion operator string based on mask information corresponding to the plurality of first bosonic operators, wherein the sparse matrix can be used to determine the ground state energy of the target chemical molecule. These modules can perform corresponding functions in any possible design of the first aspect described above. For details, please refer to the detailed description in the example method and are not further described here.

[0038] In a third aspect, embodiments of the present application provide a possible quantum computing device, comprising a communication interface and a processor. Optionally, the quantum computing device further comprises a memory. The memory is configured to store computer programs or instructions. The processor is coupled to the memory and the communication interface. When the processor executes the computer program or instructions, the quantum computing device performs the method described in any of the possible designs of the first aspect.

[0039] In a fourth aspect, an embodiment of the present application provides a computer program product, which includes a computer program or instructions. When the computer program or instructions are run on a computer, the computer executes the method in any possible design of the first aspect above.

[0040] In a fifth aspect, an embodiment of the present application provides a computer-readable storage medium, in which a computer program or instruction is stored. When the computer program or instruction is executed by a computer, the computer executes the method in any possible design of the first aspect above.

[0041] In a sixth aspect, an embodiment of the present application further provides a chip, which is coupled to a memory, and is used to read a computer program stored in the memory and execute a method in any possible design of the first aspect above.

[0042] In a seventh aspect, an embodiment of the present application further provides a chip system, which includes a processor for supporting a computer device to implement the method in any possible design of the first aspect. In one possible design, the chip system also includes a memory for storing programs and data necessary for the computer device. The chip system can be composed of a chip, or it can include a chip and other discrete devices.

[0043] Based on the implementation methods provided in the above aspects, this application can also be further combined to provide more implementation methods. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] FIG1 exemplarily shows a possible system architecture diagram provided by an embodiment of the present application;

[0045] FIG2 exemplarily shows a flow chart of a fermion operator sparsification method provided in an embodiment of the present application;

[0046] FIG3 exemplarily shows a schematic diagram of an extranuclear electron occupied orbit provided in an embodiment of the present application;

[0047] FIG4 exemplarily shows a schematic structural diagram of a possible quantum computing device provided in an embodiment of the present application;

[0048] FIG5 exemplarily shows a schematic structural diagram of a possible quantum computing device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0049] The embodiments of the present application will be described in detail below with reference to the accompanying drawings.

[0050] FIG1 exemplarily illustrates a possible system architecture diagram applicable to an embodiment of the present application. The system architecture may include a quantum computing device 100, which may include, but is not limited to, a configuration unit 101, a conversion unit 102, an evolution unit 103, or a measurement unit 104. Optionally, in one example, the quantum computing device 100 may be a quantum computing device, wherein the configuration unit 101, the conversion unit 102, the evolution unit 103, and the measurement unit 104 are all deployed on the quantum computing device (e.g., a quantum computer). Optionally, in another example, the quantum computing device 100 may be a combination of a classical computing device (e.g., an ordinary computer, such as a laptop or desktop computer) and a quantum computing device, wherein the configuration unit 101 and the conversion unit 102 may be deployed on the classical computing device, and the evolution unit 103 and the measurement unit 104 may be deployed on the quantum computing device.

[0051] Among them, quantum computing devices are a type of physical device that follows the laws of quantum mechanics to perform high-speed mathematical and logical operations, store and process quantum information. For example, quantum computing devices can be used in the field of quantum chemistry to simulate chemical molecules or chemical reactions.

[0052] The configuration unit 101 is configured to generate the Hamiltonian H of the given chemical molecule and the unitary coupling cluster operator T of the given chemical molecule according to the molecular structure information of the given chemical molecule.

[0053] For example, currently commonly used quantum circuits for calculating the ground state energy of chemical molecules include but are not limited to unitary coupled-cluster with singles and doubles (UCCSD) circuits or hardware efficient (Hardware Efficient) circuits. For example, taking the UCCSD circuit as an example, in the UCCSD circuit, the unitary coupled cluster wave function |Ψ UCC > is defined as:

[0054] Among them, |Ψ HF > represents the Hartree-Fock ground state wave function, T represents the unitary coupling cluster operator under the UCCSD theory, represents the Hermitian conjugate of the unitary coupled cluster operator T.

[0055] The following is a brief introduction to the electronic structure of atoms, followed by an introduction to the meaning of the Hartree-Fock ground state wave function and the unitary coupling cluster operator T.

[0056] Alternatively, an atom is composed of a nucleus and extranuclear electrons, and the arrangement of extranuclear electrons has a significant influence on the chemical properties of an element. For a given chemical molecule, the electron occupancy diagram can be used to describe the electron occupancy. For example, taking the chemical molecule LiH as an example, when processed by a quantum computing device, it can be described by 12 bits and 4 electrons. The 12 bits constitute 6 spatial orbitals, and of the 4 electrons, two have spin-up and two have spin-down, occupying different spin orbitals.

[0057] FIG3 illustrates an exemplary schematic diagram of an extranuclear electron occupied orbital provided by an embodiment of the present application. As shown in FIG3 , 0-11 represent 12 electron orbitals, with even numbers marking spin-up orbitals and odd numbers marking spin-down orbitals. For example, taking the four electrons of LiH as an example, two of the four electrons occupy spin-up orbitals 0 and 2, while the other two occupy spin-down orbitals 1 and 3.

[0058] In quantum mechanics, the fermion operator a can be used to annihilate the operator a and to create the operator To represent the annihilation and creation of particles (the creation operator and the annihilation operator are Hermitian conjugate to each other), for example, a2 represents the annihilation of an electron on spin orbit 2. Indicates that an electron is generated in spin orbital 4. According to the above description, we know that the Hartree-Fock state is the quantum state of the electron occupying the lowest orbital: |Ψ HF >=|111100000000>.

[0059] The unitary coupling cluster operator T is composed of operators of electron transitions between different orbitals. Under the UCCSD theory, T is composed of single-electron excitation and double-electron excitation, that is:

[0060] in, It means that an electron is created in the unoccupied orbital p and an electron is annihilated in the occupied orbital q. It means that an electron is generated in the empty orbital p and the empty orbital q respectively, and an electron is annihilated in the occupied orbital r and the occupied orbital s respectively. The electron transitions between these different orbits are also called different configurations, θ q p is the coefficient of the single electron excited configuration, θ rs pq is the coefficient of the doubly excited configuration.

[0061] Through the above introduction, the quantum circuit required for calculating the ground state energy of chemical molecules can be constructed. In addition, the Hamiltonian H of the chemical molecule needs to be calculated, so that the ground state energy E of the chemical molecule can be calculated through the unitary coupling cluster operator T of the chemical molecule and the Hamiltonian H of the chemical molecule. Among them, the ground state energy E of the chemical molecule satisfies the following form:

[0062] Among them, the Hamiltonian H of the chemical molecule satisfies the following form:

[0063] Among them, h q p The coefficient representing the single electron excited configuration, h rs pq The coefficient representing the di-electron excited configuration, E q p The fermion operator representing the single-electron excited configuration, E rs pq A fermionic operator representing a dielectronic excited configuration.

[0064] The conversion unit 102 is used to convert the unitary coupled cluster operator T into the corresponding sparse matrix M T , convert the Hamiltonian H into the corresponding sparse matrix M H .

[0065] Evolution unit 103, used to transform the sparse matrix M T and the sparse matrix M H Act on the quantum state and evolve it to obtain the evolved quantum state.

[0066] The measuring unit 104 is used to test the evolved quantum state and generate a test result.

[0067] It should be noted that FIG1 only schematically provides a possible system architecture, and this schematic system architecture is intended to more clearly illustrate the technical solution of the embodiment of the present application, and does not limit the system architecture of the fermion operator sparsification method provided in the present application. In addition, the form and quantity of each unit in the system architecture shown in FIG1 are only for example and do not constitute a limitation on the present application. Furthermore, the name of each unit in the system architecture shown in FIG1 is only an example, and the name of each unit in the specific implementation may also be other names, and the present application does not make specific limitations on this.

[0068] As described in the background art, the existing sparse matrix calculation method results in low sparse matrix calculation efficiency. In view of this, the present application provides a fermion operator sparsification method to effectively improve the sparse matrix calculation efficiency.

[0069] Based on the system architecture shown in FIG1 , the specific implementation of the fermion operator sparsification method in this application is introduced in detail below.

[0070] FIG2 exemplarily shows a flow chart of a fermion operator sparsification method provided in an embodiment of the present application. The method is applicable to a quantum computing device, such as the quantum computing device 100 shown in FIG1 . The method flow can be executed by a quantum computing device or a component (such as a chip system or circuit, etc.) that can support the quantum computing device to implement the functions required for the method. In order to facilitate the introduction of the technical solution provided in an embodiment of the present application, the following is an example of an example of a quantum computing device executing a fermion operator sparsification method. As shown in FIG2 , the method includes:

[0071] Step 201: The quantum computing device determines a first fermion operator string corresponding to the target chemical molecule based on the molecular structure information of the target chemical molecule.

[0072] Optionally, the target chemical molecules are used to indicate chemical molecules for which a sparse matrix needs to be calculated, such as molecules contained in a certain catalyst, chemical molecules contained in a certain new energy material, or chemical molecules contained in a certain drug.

[0073] Optionally, when a user needs to calculate the ground state energy of a certain chemical molecule (i.e., a target chemical molecule), it is first necessary to calculate the sparse matrix corresponding to the target chemical molecule. Therefore, after the user submits the molecular structure information of the target chemical molecule to the quantum computing device through the client provided by the quantum computing device, the quantum computing device can generate the Hamiltonian and unitary coupling cluster operator corresponding to the target chemical molecule based on the molecular structure information of the target chemical molecule. Among them, the Hamiltonian contains at least one fermion operator string, the unitary coupling cluster operator contains at least one fermion operator string, and the first fermion operator string is any one of the at least one fermion operator string contained in the Hamiltonian and the at least one fermion operator string contained in the unitary coupling cluster operator.

[0074] For example, taking a chemical molecule (e.g., molecule a) as an example, the quantum computing device can generate the Hamiltonian H and unitary coupling cluster operator T corresponding to molecule a based on the molecular structure information of molecule a. Assume that the Hamiltonian H corresponding to molecule a contains two fermion operator strings, and assume that the unitary coupling cluster operator T corresponding to molecule a contains two fermion operator strings. Afterwards, the quantum computing device can arbitrarily select a fermion operator string from the four fermion operator strings (e.g., ) as the first fermion operator string.

[0075] Step 202: The quantum computing device transforms the first fermion operator string to obtain a first bosonic operator string.

[0076] Exemplarily, the first bosonic operator string may include multiple first bosonic operators.

[0077] Optionally, the quantum computing device can map at least one fermion operator contained in the first fermion operator string separately to obtain multiple second bosonic operator strings. Optionally, any second bosonic operator string can contain one or more second bosonic operators. Thereafter, the quantum computing device can perform a product operation on the second bosonic operators belonging to the same qubit in the multiple second bosonic operator strings to obtain multiple first bosonic operators. Optionally, each first bosonic operator corresponds to a qubit. Then, the quantum computing device can sequentially splice the multiple first bosonic operators according to the qubits to which they correspond, to obtain the first bosonic operator string.

[0078] Optionally, the following describes the implementation process of a quantum computing device performing a product operation on second bosonic operators belonging to the same quantum bit in multiple second bosonic operator strings through the following possible implementation methods.

[0079] Implementation Method 1: The quantum computing device directly selects at least one second bosonic operator located at the first qubit from multiple second bosonic operator strings. The quantum computing device then directly performs a product operation on the at least one second bosonic operator located at the first qubit according to a preset extended Pauli operator multiplication table.

[0080] For example, let's take the first fermion operator string abc as an example, and assume that the second bosonic operator string corresponding to the fermion operator a contained in the first fermion operator string abc is a1a2a3, the second bosonic operator string corresponding to the fermion operator b is b1b2, and the second bosonic operator string corresponding to the fermion operator c is c1c2c3c4. Among them, the order of action of fermion operator a precedes the order of action of fermion operator b, and the order of action of fermion operator b precedes the order of action of fermion operator c. The quantum computing device directly selects the second bosonic operators b2, a2, and c2 located at the first quantum bit (for example, the quantum bit is 2) from the second bosonic operator strings a1a2a3, b1b2, and c1c2c3c4. Afterwards, the quantum computing device directly performs a product operation on the second bosonic operator b2, a2, and c2 located at quantum bit position 2 according to the preset extended Pauli operator multiplication table, that is, b2*a2*c2.

[0081] Implementation Method 2: The quantum computing device can sequentially select the second bosonic operators located at the first qubit from the multiple second bosonic operator strings according to the order of action of the multiple fermionic operators included in the first fermionic operator string, thereby obtaining at least one second bosonic operator located at the first qubit. Each second bosonic operator corresponds to a selection order. The quantum computing device then performs a product operation on the at least one second bosonic operator located at the first qubit, sequentially according to the selection order corresponding to the at least one second bosonic operator, using a preset extended Pauli operator multiplication table.

[0082] For example, let's continue with the example of the first fermion operator string abc. Assume that the second bosonic operator string corresponding to fermion operator a in the first fermion operator string abc is a1a2a3, the second bosonic operator string corresponding to fermion operator b is b1b2, and the second bosonic operator string corresponding to fermion operator c is c1c2c3c4. The order of action of fermion operator a precedes that of fermion operator b, which in turn precedes that of fermion operator c. The quantum computing device can, in the order of action of fermion operators a, b, and c, sequentially select the second bosonic operator a2 at qubit position 2 in the second bosonic operator string a1a2a3, the second bosonic operator b2 at qubit position 2 in the second bosonic operator string b1b2, and the second bosonic operator c2 at qubit position 2 in the second bosonic operator string c1c2c3c4.

[0083] The selection order of the second bosonic operator a2 is 1, the selection order of the second bosonic operator b2 is 2, and the selection order of the second bosonic operator c2 is 3. Afterwards, the quantum computing device can use a preset extended Pauli operator multiplication table to perform product operations on the second bosonic operators a2, b2, and c2 in the selection order of the second bosonic operators a2, b2, and c2, that is, a2*b2*c2.

[0084] Implementation method three: The quantum computing device uses a preset extended Pauli operator multiplication table to perform product operations on at least one second bosonic operator located at the first quantum bit in sequence according to the order of action of the fermion operators corresponding to the at least one second bosonic operator.

[0085] Optionally, an extended Pauli operator multiplication table can be created based on actual application requirements. The extended Pauli operator multiplication table can assist the quantum computing device in more efficiently obtaining the first bosonic operator string. For example, the quantum computing device can perform a simple product operation on at least one second bosonic operator located in the same qubit according to the extended Pauli operator multiplication table to obtain the operation result (such as the first bosonic operator) in a timely and accurate manner. For example, see Table 1, which shows an extended Pauli operator multiplication table provided in an embodiment of the present application.

[0086] Table 1

[0087] It should be noted that Table 1 is only a simple example for the purpose of illustrating the technical solutions in the embodiments of the present application, and does not constitute a limitation on the technical solutions in the embodiments of the present application.

[0088] It should be understood that the above content is only an illustrative introduction to several possible ways for a quantum computing device to perform product operations on second bosonic operators belonging to the same quantum bit in multiple second bosonic operator strings. The quantum computing device can also perform product operations on second bosonic operators belonging to the same quantum bit in multiple second bosonic operator strings by adopting other methods, and the embodiments of this application will not list them one by one.

[0089] For example, the first fermion operator string is For example, the first fermion operator string of the quantum computing device is determined to be The implementation process of the corresponding first bosonic operator string is introduced.

[0090] Optionally, the quantum computing device can transform the first fermion operator string according to a set transformation algorithm (such as Jordan-Wigner transformation, Parity Encoding transformation or Bravyi-Kitaev transformation, etc.) By mapping each fermion operator contained in the equation, we can obtain the second bosonic operator string corresponding to each fermion operator. For example, taking the Jordan-Wigner transformation as an example, the Jordan-Wigner transformation satisfies the following form:

[0091] The quantum computing device can use the above Jordan-Wigner transformation to transform the first fermion operator string Each contained fermion operator is mapped to the second bosonic operator string corresponding to the fermion operator.

[0092] For example, taking the first fermion operator string Taking the fermion operator a1 as an example, the quantum computing device can use the above Jordan-Wigner transformation to map the fermion operator a1 into the second bosonic operator string σ z σ p , that is, JW(a1)=σ z σ p Among them, the second bosonic operator string σ corresponding to the fermion operator a1 z σ p Contains the second bosonic operator σ z and the second bosonic operator σ p .

[0093] For example, taking the first fermion operator string Fermion operators included For example, a quantum computing device can use the above Jordan-Wigner transformation to transform the fermion operator Mapping to the second bosonic operator string σ z σ z σ z σ z σ m ,Right now Among them, the fermion operator The corresponding second bosonic operator string σ z σ z σ z σ z σ m Contains 4 second bosonic operators σ z and a second bosonic operator σ m . Optional, first fermion operator string The specific representation of the second bosonic operator strings corresponding to the multiple fermion operators included can be found in Table 2.

[0094] Table 2

[0095] It should be noted that Table 2 is only a simple example for the purpose of illustrating the technical solutions in the embodiments of the present application, and does not constitute a limitation on the technical solutions in the embodiments of the present application.

[0096] Optionally, the quantum computing device determines the first fermion operator string After the second boson operator string corresponding to each fermion operator is included, the first fermion operator string can be By performing a product operation on the second bosonic operators belonging to the same or identical quantum bit in the second bosonic operator strings corresponding to the multiple fermion operators contained therein, the first bosonic operators located at the multiple quantum bits can be effectively obtained.

[0097] For example, taking the above-mentioned implementation method 2 as an example, for at least one second bosonic operator located at each quantum bit, the quantum computing device calculates the first fermion operator string according to the first fermion operator string. The order of action of the multiple fermion operators included selects at least one second bosonic operator located at the quantum bit in turn.

[0098] For example, taking the quantum bit number as 4, the quantum computing device follows the first fermion operator string The order of action of the multiple fermion operators included is as follows: The corresponding second bosonic operator string σ z σ m The second bosonic operator σ at qubit position 4 m , the second bosonic operator string σ corresponding to the fermion operator a1 z σ p The second bosonic operator σ at qubit position 4 p , the second bosonic operator string σ corresponding to the fermion operator a2 z σ z σ p The second bosonic operator σ at qubit position 4 z , the second bosonic operator string σ corresponding to the fermion operator a3 z σ z σ z σ p The second bosonic operator σ at qubit position 4 z , fermion operator The corresponding second bosonic operator string σ z σ z σ z σ m The second bosonic operator σ at qubit position 4 z , fermion operator The corresponding second bosonic operator string σ z σ z σ z σ z σ z σ m The second bosonic operator σ at qubit position 4 z Selected, that is, the second bosonic operator σ m , σ p , σ z , σ z , σ z , σ z .

[0099] Among them, the second bosonic operator σ mThe selection order is 1, the second bosonic operator σ p The selection order is 2, the second bosonic operator σ z The selection order is 3, the second bosonic operator σ z The selection order is 4, the second bosonic operator σ z The selection order is 5, the second bosonic operator σ z The selection order is 6. Then, the quantum computing device uses the extended Pauli operator multiplication table shown in Table 1 above and calculates the second bosonic operator σ m , σ p , σ z , σ z , σ z , σ z The corresponding selection order is to select the second bosonic operator σ m , σ p , σ z , σ z , σ z , σ z By performing the product operation, we can effectively obtain the first bosonic operator σ1, that is, σ m *σ p *σ z *σ z *σ z *σ z =σ1.

[0100] For example, taking the quantum bit number as 2, the quantum computing device can be operated according to the fermion operator The order of action is to sequentially convert the second bosonic operator string σ corresponding to the fermion operator a3 into z σ z σ z σ p The second bosonic operator σ at qubit position 2 p , fermion operator The corresponding second bosonic operator string σ z σ z σ z σ m The second bosonic operator σ at qubit position 2 m , fermion operator The corresponding second bosonic operator string σ z σ z σ z σ z σ z σ m The second bosonic operator σ at qubit position 2 z Selected, that is, the second bosonic operator σ p , σ m , σz .

[0101] Among them, the second bosonic operator σ p The selection order is 1, the second bosonic operator σ m The selection order is 2, the second bosonic operator σ z The selection order is 3. Then, the quantum computing device uses the extended Pauli operator multiplication table shown in Table 1 above and calculates the second Bosonic operator σ p , σ m , σ z The corresponding selection order is to select the second bosonic operator σ p , σ m , σ z By performing the product operation, we can effectively obtain the first bosonic operator σ0, that is, σ p *σ m *σ z =σ0.

[0102] Based on the above content, taking the above implementation method 2 as an example, the quantum computing device is constructed by By performing product operations on the second bosonic operators belonging to the same or identical quantum bit in the second bosonic operator strings corresponding to the multiple fermion operators included, the first bosonic operators located at multiple quantum bits as shown in Table 3 can be obtained promptly and effectively.

[0103] Table 3

[0104] It should be noted that Table 3 is only a simple example for the purpose of illustrating the technical solutions in the embodiments of the present application, and does not constitute a limitation on the technical solutions in the embodiments of the present application.

[0105] Then, the quantum computing device can be operated according to the first bosonic operators (i.e., I, σ1, -σ p ,σ0,σ z , σ m ) The order of the size of the corresponding quantum bits, multiple first bosonic operators I, σ1, -σ p ,σ0,σ z , σ m By sequentially splicing, we can get the first bosonic operator string S=Iσ1(-σ p )σ0σ z σ m .

[0106] Step 203: When there is no first bosonic operator with a value of zero among the multiple first bosonic operators, the quantum computing device determines mask information corresponding to the multiple first bosonic operators.

[0107] Optionally, when there is a first bosonic operator with a value of zero among the multiple first bosonic operators, the quantum computing device may determine that the sparse matrix of the first fermion operator string is a zero matrix.

[0108] For example, let the first bosonic operator string be σ m σ z 0σ1σ p For example, when the quantum computing device determines the first bosonic operator string σ m σ z 0σ1σ p When the number of first boson operators with a value of 0 is greater than or equal to 1, it is determined that the first boson operator string σ m σ z 0σ1σ p When contains one or more 0s, the quantum computing device can determine the first bosonic operator string σ m σ z 0σ1σ p The corresponding sparse matrix of the first fermion operator string is a zero matrix.

[0109] Optionally, when there is no first bosonic operator with a value of zero among the multiple first bosonic operators, the quantum computing device can determine the mask information corresponding to the multiple first bosonic operators.

[0110] For example, the first bosonic operator string is Iσ1(-σ p )σ0σ z σ m For example, when the quantum computing device determines the first bosonic operator string Iσ1(-σ p )σ0σ z σ m When the number of the first boson operators with a value of 0 is equal to zero, it is determined that the first boson operator string Iσ1(-σ p )σ0σ z σ m When 0 is not included in the quantum computing device, the quantum computing device can determine multiple first bosonic operators I, σ1, -σ p ,σ0,σ z , σ m The corresponding mask information.

[0111] For example, the mask information may include but is not limited to a position mask, a mask array, or the number of at least one non-zero element contained in a sparse matrix.

[0112] By way of example, the following introduces the implementation process of a quantum computing device determining mask information corresponding to multiple first bosonic operators, taking the example of multiple first bosonic operators including a first target bosonic operator, a second target bosonic operator, a third target bosonic operator, a fourth target bosonic operator and a fifth target bosonic operator.

[0113] Among them, the first target boson operator or the second target boson operator is a first boson operator among multiple first boson operators, and multiple result values ​​generated by acting on multiple quantum states are all non-zero; the third target boson operator, the fourth target boson operator or the fifth target boson operator is a first boson operator among the multiple first boson operators, and at least one result value is zero among the multiple result values ​​generated by acting on multiple quantum states; the first target boson operator, the second target boson operator, the third target boson operator, the fourth target boson operator and the fifth target boson operator are different.

[0114] For example, the following briefly introduces the effects of fermion operators and bosonic operators on multiple quantum states, taking a two-level quantum system as an example.

[0115] Alternatively, in a two-level quantum system, the quantum state includes a zero state and a one state. The zero state can be represented by the symbol |0>, and the one state can be represented by the symbol |1>. In linear algebra language, it can be represented by a vector, that is:

[0116] Fermion operators are operators that describe the change in the number of particles in a quantum system. They mainly include the annihilation operator a and the production operator Its effect on quantum states (such as zero state and one state) is as follows: a|0>=0, a|1>=|0>

[0117] In addition, the fermion operators satisfy the anti-commutative relation: {a i ,a j}=a i a j +a j a i =0

[0118] Since fermion operators cannot be directly simulated on quantum computing devices, the quantum computing device needs to first convert fermion operators into bosonic operators through a set transformation algorithm (such as Jordan-Wigner transformation), and then perform quantum simulation using bosonic operators. x , σ y or σ z , its matrix form is:

[0119] In the embodiment of the present application, the boson operator is extended, and the extended boson operator is as follows:

[0120] The effects of the extended bosonic operator on quantum states (such as zero and one) are as follows: σ0|0>=|0>,σ0|1>=0 σ1|0>=0,σ1|1>=|1> σ m |0>=|1>,σ m |1>=0 σ p |0>=0,σ p |1>=|0>

[0121] Optionally, when the mask information includes the number of at least one non-zero elements, the quantum computing device can determine the number of at least one non-zero elements contained in the sparse matrix based on the number of first target bosonic operators contained in the first bosonic operator string and the number of second target bosonic operators contained in the first bosonic operator string after determining that there is no first bosonic operator with a value of zero among the multiple first bosonic operators contained in the first bosonic operator string corresponding to the first fermion operator string (that is, the number of 0s contained in the first bosonic operator string is 0).

[0122] When the mask information includes a mask array, the quantum computing device can determine the mask array required for calculating the sparse matrix based on the quantum bits corresponding to the first target boson operator and the quantum bits corresponding to the second target boson operator after determining that there is no first boson operator with a value of zero among the multiple first boson operators included in the first boson operator string corresponding to the first fermion operator string (that is, the number of 0s included in the first boson operator string is 0).

[0123] When the mask information includes a position mask, the quantum computing device can determine the position mask of the third target boson operator based on the quantum bit corresponding to the third target boson operator after determining that there is no first boson operator with a value of zero among the multiple first boson operators included in the first boson operator string corresponding to the first fermion operator string (that is, the number of 0s included in the first boson operator string is 0), and / or determine the position mask of the fourth target boson operator based on the quantum bit corresponding to the fourth target boson operator, and / or determine the position mask of the fifth target boson operator based on the quantum bit corresponding to the fifth target boson operator.

[0124] For example, take a two-level quantum system as an example, and take the first bosonic operator string as Iσ1(-σ p )σ0σ z σ mFor example, since the first bosonic operator string Iσ1(-σ p )σ0σ z σ m The bosonic operator I in the zero state and the one state have a result value that is not 0. The first bosonic operator string Iσ1(-σ p )σ0σ z σ m The bosonic operator σ in z The result value of the operation on both the zero state and the one state is not 0, so the quantum computing device can choose the bosonic operator I as the first target bosonic operator, and the bosonic operator σ z As the second target bosonic operator, or, the quantum computing device can select the bosonic operator I as the second target bosonic operator, the bosonic operator σ z as the first target bosonic operator.

[0125] Optionally, in a possible implementation, since the first bosonic operator string Iσ1(-σ p )σ0σ z σ m The boson operator σ1 in the zero state and the one state respectively produces two result values, one of which is 0. For example, the result value of the boson operator σ1 acting on the zero state is 0, and the result value of the boson operator σ1 acting on the one state is |1>. The first boson operator string Iσ1(-σ p )σ0σ z σ m The bosonic operator σ in p There is a result value of 0 in the two result values ​​produced by acting on the zero state and the one state respectively. p )σ0σ z σ m The bosonic operator σ in p There is a result value of 0 in the two result values ​​produced by acting on the zero state and the one state respectively. p )σ0σ z σ m The bosonic operator σ in m Among the two result values ​​generated by acting on the zero state and the one state respectively, there is a result value of 0.

[0126] Therefore, the quantum computing device can choose the bosonic operator σ1 as the third target bosonic operator, and the bosonic operator σ p As the fourth target bosonic operator, the bosonic operator σ m As the fifth target bosonic operator, or the quantum computing device can select the bosonic operator σ1 as the fourth target bosonic operator, the bosonic operator σp As the third target bosonic operator, the bosonic operator σ m As the fifth target bosonic operator, or the quantum computing device can select the bosonic operator σ1 as the fifth target bosonic operator, the bosonic operator σ p As the fourth target bosonic operator, the bosonic operator σ m As the third target bosonic operator, or the quantum computing device can select the bosonic operator σ1 as the third target bosonic operator, the bosonic operator σ p As the fifth target bosonic operator, the bosonic operator σ m As the fourth target bosonic operator, or the quantum computing device can select the bosonic operator σ1 as the fourth target bosonic operator, the bosonic operator σ p As the fifth target bosonic operator, the bosonic operator σ m As the third target bosonic operator, or the quantum computing device can select the bosonic operator σ1 as the fifth target bosonic operator, the bosonic operator σ p As the third target bosonic operator, the bosonic operator σ m As the fourth target bosonic operator.

[0127] For example, the quantum computing device selects the bosonic operator I as the first target bosonic operator, and the bosonic operator σ z Taking the second target bosonic operator as an example, in one example, when the quantum computing device determines the first bosonic operator string Iσ1(-σ p )σ0σ z σ m When the number of 0s in is 0, the quantum computing device can count the first target bosonic operator I and the second target bosonic operator σ z The total number n=2. Afterwards, the quantum computing device can calculate the number of non-zero elements included in the sparse matrix, that is, the number of non-zero elements included in the sparse matrix Q=2^(n=2)=4.

[0128] In another example, when the quantum computing device determines the first bosonic operator string Iσ1(-σ p )σ0σ z σ m When the number of 0s in is 0, the quantum computing device can obtain the quantum bit 5 of the first target bosonic operator I and the second target bosonic operator σ z The quantum computing device then calculates the quantum bit 1 of the first target boson operator I and the quantum bit 5 of the second target boson operator σ z The quantum bit of the bit is 1, which determines the mask array A required for calculating the sparse matrix power-array , that is, the mask array A power-array =[25 ,2 1 ].

[0129] In another example, the quantum computing device selects the bosonic operator σ1 as the third target bosonic operator, and the bosonic operator σ p As the fourth target bosonic operator, the bosonic operator σ m Taking the fifth target bosonic operator as an example, when the quantum computing device determines the first bosonic operator string Iσ1(-σ p )σ0σ z σ m When the number of 0s in is 0, the quantum computing device can obtain the quantum bit 4 of the third target bosonic operator σ1 and obtain the fourth target bosonic operator σ p The qubit position 3, and the fifth target bosonic operator σ m The quantum bit is 0.

[0130] Afterwards, the quantum computing device can calculate the position mask mask1 of the third target bosonic operator σ1 according to the quantum bit 4 of the third target bosonic operator σ1, that is, the position mask mask1 = 2 4 , the quantum computing device can be based on the fourth target bosonic operator σ p The qubit 3 calculates the fourth target bosonic operator σ p Position mask mask p , that is, position mask mask p =2 3 , the quantum computing device can be based on the fifth target bosonic operator σ m The qubit is 0, and the fifth target bosonic operator σ is calculated. m Position mask mask m , that is, position mask mask m =2 0 .

[0131] Step 204: The quantum computing device determines a sparse matrix of the first fermion operator string based on the mask information corresponding to the plurality of first bosonic operators.

[0132] Illustratively, the sparse matrix of the first fermion operator string can be used to determine the ground state energy of the target chemical molecule.

[0133] Optionally, after the quantum computing device determines the mask information corresponding to the multiple first bosonic operators, it can calculate the sparse matrix of the first fermion operator string based on the mask information corresponding to the multiple first bosonic operators.

[0134] For example, in the case where the mask information includes a position mask, a mask array, and the number of at least one non-zero element in a sparse matrix, the quantum computing device can first determine the integer sequence required to calculate the sparse matrix based on the number of at least one non-zero element in the sparse matrix, where the integer sequence includes at least one integer. The quantum computing device can then calculate the horizontal and vertical coordinates of each non-zero element in the sparse matrix, and can also calculate the numerical value of each non-zero element. The numerical value of each non-zero element is determined based on a preset threshold.

[0135] The quantum computing device can then determine the sparse matrix of the first fermion operator string based on the numerical value of each non-zero element in the at least one non-zero element and the abscissa and ordinate of each non-zero element in the sparse matrix. Optionally, after calculating the sparse matrix of the first fermion operator string, the quantum computing device can use the sparse matrix of the first fermion operator string to calculate the ground state energy of the target chemical molecule corresponding to the first fermion operator string.

[0136] Exemplarily, the following takes the first non-zero element as an example, where the first non-zero element is any one of at least one non-zero element, to introduce the implementation process of a quantum computing device determining the horizontal coordinate and vertical coordinate of the first non-zero element in a sparse matrix.

[0137] Optionally, the quantum computing device can select a first integer from the integer sequence and convert the first integer into a corresponding binary array through a binary conversion method. The first integer corresponds to the first non-zero element. Thereafter, the quantum computing device can determine the first numerical value required for calculating the horizontal and vertical coordinates of the first non-zero element in the sparse matrix based on the mask array and the binary array of the first integer. Then, the quantum computing device can determine the vertical coordinate of the first non-zero element in the sparse matrix based on the first numerical value, the position mask of the third target boson operator, and the position mask of the fourth target boson operator, and can determine the horizontal coordinate of the first non-zero element in the sparse matrix based on the first numerical value, the position mask of the third target boson operator, and the position mask of the fifth target boson operator.

[0138] Based on the above content, the following continues to take the first non-zero element as an example to introduce the implementation process of a quantum computing device determining the value of the first non-zero element through the following possible implementation methods.

[0139] Method 1: When the number of 1s in the binary value is even, the quantum computing device can perform a product operation on the preset threshold and the first coefficient to obtain a first product result value, and use the first product result value as the value of the first non-zero element.

[0140] Method 2: When the number of 1s in the binary value is odd, the quantum computing device can perform a product operation on the preset threshold and the second coefficient to obtain a second product result value, and use the second product result value as the value of the first non-zero element.

[0141] Optionally, the binary value is obtained by performing a bitwise AND operation on the first integer and the position mask of the second target boson operator by the quantum computing device. Optionally, the first coefficient and the second coefficient are different.

[0142] Optionally, the quantum computing device can determine the position mask of the second target boson operator through the following steps: When only the first target boson operator and the second target boson operator are retained in the first boson operator string, the quantum computing device can concatenate the first target boson operator and the second target boson operator to obtain a third boson operator string. The first target boson operator and the second target boson operator each correspond to a new qubit in the third boson operator string. The quantum computing device can then determine the position mask of the second target boson operator based on the new qubit corresponding to the second target boson operator.

[0143] For example, the boson operator I is selected as the first target boson operator by the quantum computing device, and the boson operator σ z As an example of the second target boson operator, when the first boson operator string Iσ1(-σ p )σ0σ z σ m Only the first target boson operator I and the second target boson operator σ are retained z When the quantum computing device can combine the first target boson operator I with the second target boson operator σ z Perform splicing to obtain the third bosonic operator string S'=Iσ z Among them, the first target boson operator I corresponds to a new quantum bit of 1 in the third boson operator string S', and the second target boson operator σ z The corresponding new quantum bit in the third bosonic operator string S' is 0. Then, the quantum computing device can calculate the quantum bit according to the second target bosonic operator σ z The qubit is 0, and the second target bosonic operator σ is calculated. z Position mask mask z , that is, position mask mask z =2 0 .

[0144] For example, based on the above content, we continue to use the first bosonic operator string Iσ1(-σ p )σ0σ z σ mAs an example, the quantum computing device is introduced based on the first bosonic operator string Iσ1(-σ p )σ0σ z σ m The mask information corresponding to the multiple first bosonic operators contained in , calculate the first fermion operator string The implementation process of sparse matrix.

[0145] Optionally, when the quantum computing device obtains the first bosonic operator string Iσ1(-σ p )σ0σ z σ m After the mask information corresponding to the multiple first bosonic operators contained in , the quantum computing device can calculate the first fermion operator string by performing the following steps The sparse matrix of .

[0146] Step a: The quantum computing device sequentially obtains a first integer i.

[0147] Wherein, the first integer i = range(Q). Optionally, when Q = 4, the first integer i = {0, 1, 2, 3}, where each integer value in {0, 1, 2, 3} corresponds to a non-zero element. The quantum computing device can sequentially obtain each integer value in {0, 1, 2, 3} to calculate the horizontal and vertical coordinates of each non-zero element in the sparse matrix and the numerical value of each non-zero element.

[0148] Step b: The quantum computing device assigns the first non-zero element an initial value data[i]=c. For example, the value (i.e., the preset threshold) c can be set according to actual applications. For example, in one example, the value c=-1.

[0149] Step c: The quantum computing device calculates the binary array b of the first integer i i , that is, b i =bin(i).

[0150] Step d: The quantum computing device generates a power-array and the binary array b i , calculate the first value d i , that is, d i =∑ j A power-array [j]b i [j].

[0151] Step e: The quantum computing device calculates the value of the first value d. i , the position mask mask1 of the third target boson operator σ1 and the position mask mask2 of the fifth target boson operator σ m Position mask mask m, calculate the abscissa row[i] of the first non-zero element in the sparse matrix, that is, the abscissa row[i] = d i +mask1+mask m , and can be calculated based on the first value d i , the position mask mask1 of the third target boson operator σ1 and the fourth target boson operator σ p Position mask mask p , calculate the ordinate col[i] of the first non-zero element in the sparse matrix, that is, the ordinate col[i]=+mask1+mask p .

[0152] Step f: When Countone(i&mask z ) is an odd number, the quantum computing device calculates the value data[i]*=first coefficient of the first non-zero element. For example, the first coefficient can be set according to actual application. For example, in one example, the first coefficient is set to -1. When Countone(i&mask z ) is an even number, the quantum computing device calculates the value data[i]* of the first non-zero element = the second coefficient. For example, the second coefficient can be set according to actual applications. For example, in one example, the second coefficient is set to 1.

[0153] From the above steps a to f, it can be seen that the quantum computing device determines the first fermion operator string. In the process of calculating the sparse matrix, the number of loops or searches is the number of all non-zero elements in the sparse matrix. In this way, all non-zero elements can be obtained at one time. Since zero elements and any other temporary variables are not involved, it can be ensured that the quantum computing device does not generate any redundant calculations in the process of calculating the sparse matrix, and the computing resources consumed and the storage resources occupied are also less, so that the values ​​of all non-zero elements in the sparse matrix and the horizontal and vertical coordinates of all non-zero elements in the sparse matrix can be obtained more efficiently and directly.

[0154] It should be noted that in the description of this application, "at least one" refers to one or more, and "plurality" 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: the existence of A alone, the existence of A and B at the same time, and the existence of B alone, where A and B can be singular or plural. The character " / " generally indicates that the associated objects before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, "at least one of A, B and C" includes A, B, C, AB, AC, BC or ABC. And, unless otherwise specified, the ordinal numbers such as "first", "second", and "third" mentioned in the embodiments of this application are used to distinguish multiple objects and are not used to limit the order, timing, priority or importance of multiple objects. In addition, the terms "including", "comprising", "having" and their variations appearing in this application all mean "including but not limited to" unless otherwise specifically emphasized.

[0155] In addition, it should be noted that each step involved in the above embodiments can be performed by a corresponding device, or by a component such as a chip, processor, or chip system within the device, and the embodiments of the present application do not limit this. The above embodiments are described only as examples of execution by corresponding devices.

[0156] It should be noted that in each of the above embodiments, some steps may be selected for implementation, and the order of the steps in the diagrams may be adjusted for implementation, and this application does not limit this. It should be understood that executing some of the steps in the diagrams, adjusting the order of the steps, or combining them for specific implementation all fall within the scope of protection of this application.

[0157] It is understandable that in order to implement the functions in the above embodiments, the various devices involved in the above embodiments include hardware structures and / or software modules corresponding to the execution of each function. It should be readily apparent to those skilled in the art that, in combination with the units and method steps of the various examples described in the embodiments disclosed in this application, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in the form of hardware or computer software driving hardware depends on the specific application scenario and design constraints of the technical solution.

[0158] It should be noted that the "steps" in the embodiments of this application are merely illustrative and serve as a method of expression for a better understanding of the embodiments. They do not constitute a substantial limitation on the execution of the solutions of this application. For example, the "steps" can also be understood as "features." Furthermore, the steps do not constitute any limitation on the execution order of the solutions of this application. Any changes to the order of steps, or any operations such as step merging or splitting that do not affect the implementation of the overall solution, resulting in new technical solutions, are also within the scope of this application.

[0159] Based on the same concept, an embodiment of the present application also provides a possible quantum computing device, which is suitable for use in the system architecture shown in Figure 1. The quantum computing device is used to implement the fermion operator sparsification method provided in the above embodiments, or the module (such as a chip) of the quantum computing device is used to implement the fermion operator sparsification method provided in the above embodiments, thereby also achieving the beneficial effects of the above embodiments. In an embodiment of the present application, the quantum computing device can be a quantum computing device 100 as shown in Figure 1.

[0160] Referring to Figure 4, the quantum computing device 400 includes an acquisition module 401 and a processing module 402. The acquisition module 401 is used to obtain the molecular structure information of the target chemical molecule. The processing module 402 is used to determine the first fermion operator string corresponding to the target chemical molecule based on the molecular structure information of the target chemical molecule. The processing module 402 is also used to transform the first fermion operator string to obtain a first bosonic operator string, wherein the first bosonic operator string contains multiple first bosonic operators. The processing module 402 is also used to determine the mask information corresponding to the multiple first bosonic operators when there is no first bosonic operator with a value of zero among the multiple first bosonic operators. The processing module 402 is also used to determine the sparse matrix of the first fermion operator string based on the mask information corresponding to the multiple first bosonic operators, wherein the sparse matrix can be used to determine the ground state energy of the target chemical molecule.

[0161] For a more detailed description of the acquisition module 401 and the processing module 402 , reference may be made to the relevant description of the quantum computing device in the above method embodiment, which will not be repeated here.

[0162] It should be understood that the acquisition module 401 in the embodiment of the present application can be implemented by a communication interface or a communication interface related circuit component, and the processing module 402 can be implemented by a processor or a processor related circuit component.

[0163] It should be noted that the division of modules in the embodiments of the present application is illustrative and is merely a logical functional division. In actual implementation, other division methods may be used. Furthermore, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0164] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for enabling a computer device (which can be a personal computer, or a server, etc.) or a processor to execute all or part of the steps of the various embodiments of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0165] Based on the same concept, the embodiment of the present application also provides a possible quantum computing device, which is suitable for the system architecture shown in Figure 1. The quantum computing device is used to implement the technical solutions involved in the quantum computing device in the above embodiments, and therefore can also achieve the beneficial effects of the quantum computing device in the above method embodiments. Referring to Figure 5, the quantum computing device 500 includes: a communication interface 501 and a processor 502. Optionally, the quantum computing device 500 also includes a memory 503. The communication interface 501, the processor 502 and the memory 503 are interconnected. When the quantum computing device 500 is used to implement the technical solutions involved in the quantum computing device provided in the above embodiments, the communication interface 501 can be used to implement the functions of the above-mentioned acquisition module 401, and the processor 502 is used to implement the functions of the above-mentioned processing module 402.

[0166] Optionally, the communication interface 501, the processor 502, and the memory 503 are interconnected via a bus 504. The bus 504 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus. The bus may be classified as an address bus, a data bus, a control bus, etc. For ease of illustration, FIG5 shows only one thick line, but this does not mean that there is only one bus or only one type of bus.

[0167] The communication interface 501 is used to receive and send data. For example, when the quantum computing device is the quantum computing device shown in FIG1 , the communication interface 501 can communicate with other devices outside the system architecture shown in FIG1 , such as a client device (e.g., a smartphone, desktop computer, or laptop computer) equipped with the quantum computing device. Optionally, the communication interface 501 can be an input / output interface.

[0168] The functions of the processor 502 can refer to the description of the corresponding functions involved in the quantum computing device in the above embodiments and will not be repeated here. The processor 502 can be a central processing unit (CPU), a network processor (NP), or a combination of a CPU and an NP, etc. The processor 502 can further include a hardware chip. The above-mentioned hardware chip can be an application-specific integrated circuit (ASIC), a programmable logic device (PLD), or a combination thereof. The above-mentioned PLD can be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL), or any combination thereof. When implementing the above-mentioned functions, the processor 502 can be implemented through hardware, or of course, the corresponding software implementation can be executed by hardware.

[0169] The memory 503 is used to store program instructions, etc. Specifically, the program instructions may include program code, which includes computer operating instructions. The memory 503 may include random access memory (RAM) or non-volatile memory (non-volatile memory), such as at least one disk storage device. The processor 502 executes the program instructions stored in the memory 503 to implement the above functions, thereby performing the method steps required to be executed by the quantum computing device in the above embodiment.

[0170] Based on the same concept, an embodiment of the present application further provides a computer program product, which includes a computer program or instructions. When the computer program or instructions are run on a computer, the computer executes the method provided in the above embodiment.

[0171] Based on the same concept, an embodiment of the present application also provides a computer-readable storage medium, in which a computer program or instruction is stored. When the computer program or instruction is executed by a computer, the computer executes the method provided in the above embodiment.

[0172] The storage medium may be any available medium that can be accessed by a computer. By way of example and not limitation, computer-readable media may include RAM, ROM, EEPROM, CD-ROM or other optical disk storage, magnetic disk storage media or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and can be accessed by a computer.

[0173] Based on the same concept, an embodiment of the present application further provides a chip, which is coupled to a memory and is used to read a computer program stored in the memory to implement the method provided in the above embodiment.

[0174] Based on the same concept, an embodiment of the present application also provides a chip system, which includes a processor for supporting a computer device to implement the functions involved in the quantum computing device in the above embodiments. In one possible design, the chip system also includes a memory for storing the necessary programs and data for the computer device. The chip system can be composed of a chip or can include a chip and other discrete devices.

[0175] The methods provided in the embodiments of the present application can be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented using software, they can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, the process or function described in the embodiments of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via a wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) method. The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server or data center that includes one or more available media integrated therein. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a high-density digital video disc (DVD)), or a semiconductor medium (eg, a solid state drive (SSD)).

[0176] The steps of the methods described in the embodiments of the present application can be directly embedded in hardware, software units executed by a processor, or a combination of the two. The software units can be stored in RAM, ROM, EEPROM, registers, hard disks, removable disks, CD-ROMs, or other storage media in any form known in the art. Exemplarily, the storage medium can be connected to the processor so that the processor can read information from the storage medium and write information to the storage medium. Alternatively, the storage medium can also be integrated into the processor. The processor and storage medium can be arranged in an ASIC.

[0177] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the present application. It should be understood that each flow and / or box in the flow chart and / or block diagram, as well as the combination of the flow chart and / or box in the flow chart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device produce a device for implementing the functions specified in one or more flow charts and / or one or more boxes in the block diagram.

[0178] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, so that the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in one or more processes in the flowchart and / or one or more boxes in the block diagram.

[0179] Obviously, those skilled in the art may make various modifications and variations to this application without departing from the spirit and scope of this application. Thus, if such modifications and variations fall within the scope of the claims of this application and their equivalents, this application is intended to include such modifications and variations.

Claims

1. A fermion operator sparsification method, characterized in that: include: Determining a first fermion operator string corresponding to the target chemical molecule according to the molecular structure information of the target chemical molecule; Transforming the first fermion operator string to obtain a first bosonic operator string, wherein the first bosonic operator string includes a plurality of first bosonic operators; When there is no first boson operator with a value of zero among the plurality of first boson operators, determining mask information corresponding to the plurality of first boson operators; According to the mask information corresponding to the multiple first bosonic operators, a sparse matrix of the first fermion operator string is determined, and the sparse matrix is ​​used to determine the ground state energy of the target chemical molecule.

2. The method according to claim 1, characterized in that The multiple first boson operators include a first target boson operator, a second target boson operator, a third target boson operator, a fourth target boson operator and a fifth target boson operator; each first boson operator corresponds to a quantum bit; wherein the first target boson operator or the second target boson operator is a first boson operator among the multiple first boson operators, and multiple result values ​​generated by acting on multiple quantum states are all non-zero; the third target boson operator, the fourth target boson operator, or the fifth target boson operator is a first boson operator among the multiple first boson operators, and at least one result value is zero among multiple result values ​​generated by acting on multiple quantum states; and the first target boson operator, the second target boson operator, the third target boson operator, the fourth target boson operator, and the fifth target boson operator are different from each other; The mask information includes at least one of the following: a position mask, a mask array, or a number of at least one non-zero element included in the sparse matrix; Determining mask information corresponding to the plurality of first boson operators includes: Determining the number of at least one non-zero element included in the sparse matrix according to the number of the first target boson operators and the number of the second target boson operators; or Determine a mask array required for calculating the sparse matrix according to the qubits corresponding to the first target boson operator and the qubits corresponding to the second target boson operator; or Determining a position mask of the third target boson operator according to the quantum bit corresponding to the third target boson operator; or Determining a position mask of the fourth target boson operator according to the quantum bit corresponding to the fourth target boson operator; or According to the quantum bit corresponding to the fifth target boson operator, a position mask of the fifth target boson operator is determined.

3. The method according to claim 2, characterized in that Determining a sparse matrix of the first fermion operator string includes: Determine, according to the number of at least one non-zero element contained in the sparse matrix, an integer sequence required for calculating the sparse matrix, wherein the integer sequence contains at least one integer; The horizontal coordinate and the vertical coordinate of each non-zero element in the at least one non-zero element in the sparse matrix are determined by the following steps: a first integer is selected from the integer sequence, and a binary array of the first integer is determined; wherein the first integer corresponds to a first non-zero element, and the first non-zero element is any non-zero element in the at least one non-zero element contained in the sparse matrix; according to the mask array and the binary array of the first integer, a first numerical value required for calculating the horizontal and vertical coordinates of the first non-zero element in the sparse matrix is ​​determined; according to the first numerical value, the position mask of the third target boson operator, and the position mask of the fourth target boson operator, the vertical coordinate of the first non-zero element in the sparse matrix is ​​determined; and according to the first numerical value, the position mask of the third target boson operator, and the position mask of the fifth target boson operator, the horizontal coordinate of the first non-zero element in the sparse matrix is ​​determined; The sparse matrix is ​​determined according to the abscissa and ordinate of each non-zero element of the at least one non-zero element in the sparse matrix.

4. The method according to claim 3, characterized in that The value of any non-zero element is determined based on a preset threshold; When the number of 1s in the binary value is an odd number, the product value of the preset threshold and the first coefficient is the value of the first non-zero element; or When the number of 1s in the binary value is an even number, the product value of the preset threshold and the second coefficient is the value of the first non-zero element; The binary value is obtained by performing a bitwise AND operation on the first integer and the position mask of the second target boson operator. The first coefficient is different from the second coefficient.

5. The method according to claim 4, characterized in that The method further comprises: When only the first target boson operator and the second target boson operator are retained in the first boson operator string, the first target boson operator and the second target boson operator are concatenated to obtain a third boson operator string, wherein the first target boson operator and the second target boson operator respectively correspond to new quantum bits in the third boson operator string; According to the new quantum bit corresponding to the second target bosonic operator, a position mask of the second target bosonic operator is determined.

6. The method according to any one of claims 2 to 5, characterized in that: The first fermion operator string is transformed to obtain a first bosonic operator string, including: Mapping at least one fermion operator included in the first fermion operator string respectively to obtain a plurality of second bosonic operator strings; any second bosonic operator string contains a plurality of second bosonic operators; Performing a product operation on the second boson operators belonging to the same quantum bit in the plurality of second boson operator strings to obtain the plurality of first boson operators; According to the quantum bits corresponding to each of the multiple first bosonic operators, the multiple first bosonic operators are sequentially spliced ​​to obtain the first bosonic operator string.

7. The method according to claim 6, characterized in that The method of performing a product operation on the second boson operators belonging to the same quantum bit in the plurality of second boson operator strings to obtain the plurality of first boson operators comprises: Selecting at least one second boson operator located at the first quantum bit position from the plurality of second boson operator strings; According to the extended Pauli operator multiplication table, a product operation is performed on at least one second bosonic operator located at the first quantum bit to obtain a first bosonic operator located at the first quantum bit.

8. The method according to any one of claims 1 to 7, characterized in that: The method further comprises: When there is a first boson operator with a value of zero among the plurality of first boson operators, it is determined that the sparse matrix is ​​a zero matrix.

9. A quantum computing device, characterized in that: The method comprises modules for executing the method as claimed in any one of claims 1 to 8.

10. A quantum computing device, characterized in that: include: Communication interface, used to receive and send data; Memory for storing computer program instructions and data; A processor, configured to read computer program instructions and data in the memory so as to enable the quantum computing device to perform the operating steps of the method as described in any one of claims 1 to 8.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program or instruction. When the computer program or instruction is executed by a computer, the computer is enabled to execute the method according to any one of claims 1 to 8.

12. A computer program product, characterized in that The computer program product comprises a computer program or instructions, and when the computer program or instructions are run on a computer, the computer is caused to perform the method according to any one of claims 1 to 8.

13. A chip, characterized in that: The chip is coupled to a memory, and the chip reads a computer program stored in the memory to execute the method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Glass color subsystem simulation method

    CN114511093A

  • Method and device for acquiring test state of target system in quantum chemistry simulation

    CN114512194A

  • Methods and apparatus for improving signal-to-noise performance in quantum computation

    US20220138607A1

  • Low-weight fermion-to-qubit encoding

    WO2021160989A1