Method and device for calculating energy of target system and medium

By constructing quantum phase estimation lines and evolving qubits, the problem of insufficient number of quantum bits available to quantum computers in the prior art is solved, the computing speed and accuracy are improved, and quantum chemical simulation calculations of large systems are supported.

CN119692486AActive Publication Date: 2025-03-25ORIGIN QUANTUM COMPUTING TECH (HEFEI) CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202311237072.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-09-22
Publication Date
2025-03-25
Estimated Expiration
2043-09-22

AI Technical Summary

Technical Problem

In the prior art, when calculating the ground state energy of the target system based on quantum phase estimation calculation method, the number of quantum bits available for quantum computers cannot meet the computing needs of large systems, which limits the development of computing chemistry.

Method used

By constructing a quantum phase estimation line that can be used in current quantum computing hardware devices, a control pulse of the quantum logic gate is generated and applied to the qubits, so that the specified qubits evolve from the Hartree Fock state to the target quantum state, and then the ground state energy of the target system is calculated.

Benefits of technology

It improves the calculation speed and calculation accuracy, promotes the simulation calculation of the ground state energy of the target system, overcomes the limit on the number of quantum bits, and supports the quantum chemical simulation calculation of large systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119692486A_ABST
    Figure CN119692486A_ABST
Patent Text Reader

Abstract

The invention discloses a method and device for calculating energy of a target system and a medium, and the method comprises the steps: firstly, determining a Fermi-form Hartree Fock state of the target system, then constructing a quantum phase estimation line, generating a control pulse of a quantum logic gate in the quantum phase estimation line, and calculating the energy of the target system according to the control pulse. The method comprises the following steps of: constructing a quantum phase estimation circuit capable of being used for current quantum computing hardware equipment, enabling a control pulse to act on a quantum bit in the quantum phase estimation circuit to evolve the specified quantum bit from a Hartree Fock state to a target quantum state, and finally calculating ground state energy of a target system according to the Hartree Fock state and the target quantum state, so that the ground state energy of the target system is calculated by constructing the quantum phase estimation circuit capable of being used for the current quantum computing hardware equipment. The method provides support for realizing quantum chemistry simulation calculation of target system energy, improves calculation speed and calculation precision, and promotes simulation calculation of target system ground state energy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of quantum computing technology, and in particular to a method, device and medium for calculating the energy of a target system. Background Art

[0002] Quantum computers are physical devices that follow the laws of quantum mechanics to perform high-speed mathematical and logical operations, store and process quantum information. When a device processes and calculates quantum information and runs quantum algorithms, it is a quantum computer. Quantum computers have become a key technology under research because they have the ability to process mathematical problems more efficiently than ordinary computers. For example, they can speed up the time to crack RSA keys from hundreds of years to a few hours.

[0003] Quantum computing simulation is a simulation that uses numerical calculations and computer science to simulate calculations that follow the laws of quantum mechanics. As a simulation program, it uses the basic laws of quantum bits in quantum mechanics and the high-speed computing power of computers to characterize the spatiotemporal evolution of quantum states.

[0004] With the continuous improvement of quantum chemistry theory, computational chemistry has become an important tool for chemists to explain experimental phenomena, predict experimental results, and guide experimental design. It has been widely used in drug synthesis, catalyst preparation, etc. The calculation of the ground state energy of the target system based on the quantum phase estimation algorithm requires a sufficient number of quantum bits, but the number of available quantum bits in current quantum computers is very limited and cannot meet the computing needs of large systems. This has limited the development of computational chemistry to a certain extent, resulting in weak application of users to simulate chemical systems, affecting the further development of quantum chemical simulation applications. Summary of the invention

[0005] The purpose of the present invention is to provide a method, device and medium for calculating the energy of a target system to address the deficiencies in the prior art. It provides support for the realization of quantum chemical simulation calculation of the energy of a target system by constructing a quantum phase estimation circuit that can be used in current quantum computing hardware devices, thereby improving the calculation speed and accuracy and promoting the simulation calculation of the ground state energy of the target system.

[0006] An embodiment of the present application provides a method for calculating the energy of a target system, the method comprising:

[0007] Determine the Hartree Fock state of the target system in fermion form;

[0008] A quantum phase estimation circuit is constructed, a control pulse of a quantum logic gate in the quantum phase estimation circuit is generated, and the control pulse is applied to a quantum bit in the quantum phase estimation circuit so that a specified quantum bit evolves from the Hartree Fock state to a target quantum state; the quantum phase estimation circuit includes at least a controlled first quantum logic gate, and a unitary matrix of the first quantum logic gate satisfies: in, is the unitary matrix representation of the first quantum logic gate, is the phase, k is the number of iterations and k>1, b is the scaling factor, is the Hamiltonian of the target system;

[0009] The ground state energy of the target system is calculated according to the Hartree Fock state and the target quantum state.

[0010] Optionally, determining the Hartree Fock state of the target system in fermion form includes:

[0011] Based on the electronic information and electron spin-orbit information of the target system, the Hartree Fock state of the target system in the form of fermions is determined.

[0012] Optionally, the step of constructing a quantum phase estimation circuit comprises:

[0013] A first quantum register configured to store phase information, wherein the first quantum register includes at least n quantum bits, and n≥4;

[0014] configuring a second quantum register for storing the Hartree Fock state, wherein the number of quantum bits of the second quantum register is determined by the Hamiltonian of the target system;

[0015] A second quantum logic gate acting on at least n direct products of the first quantum register and an inverse quantum Fourier transform unit acting on the first quantum register are configured, the controlled first quantum logic gate acts on the first quantum register and the second quantum register, the quantum bit of the first quantum register is a control bit, and the quantum bit of the second quantum register is a target bit.

[0016] Optionally, before calculating the ground state energy of the target system according to the Hartree Fock state and the target quantum state, the method further includes:

[0017] Performing an encoding operation on the Hartree Fock state by a preset encoding method to obtain a quantum state in the form of a Pauli operator;

[0018] The Hartree Fock energy of the target system is calculated according to the Hamiltonian of the target system and based on the quantum state in the Pauli operator form.

[0019] Optionally, the second quantum logic gate includes: a Hadamard gate.

[0020] Optionally, the preset encoding method includes:

[0021] Parity transform, Jordan-Wigner transform, or Bravyi-Kitaev transform.

[0022] Optionally, calculating the ground state energy of the target system according to the Hartree Fock state and the target quantum state includes:

[0023] The ground state energy of the target system is calculated by the following formula:

[0024]

[0025] Wherein, E represents the ground state energy of the target system, E HF represents the Hartree Fock energy of the target system, is the phase after superposition.

[0026] Another embodiment of the present application provides a device for calculating the energy of a target system, the device comprising:

[0027] Determination module, used to determine the Hartree Fock state of the target system in fermion form;

[0028] A construction module is used to construct a quantum phase estimation circuit, generate a control pulse of a quantum logic gate in the quantum phase estimation circuit, and apply the control pulse to a quantum bit in the quantum phase estimation circuit to make a specified quantum bit evolve from the Hartree Fock state to a target quantum state; the quantum phase estimation circuit includes at least a controlled first quantum logic gate, and the unitary matrix of the first quantum logic gate satisfies: in, is the unitary matrix representation of the first quantum logic gate, is the phase, k is the number of iterations and k>1, b is the scaling factor, is the Hamiltonian of the target system;

[0029] A calculation module is used to calculate the ground state energy of the target system according to the Hartree Fock state and the target quantum state.

[0030] Optionally, the determining module includes:

[0031] The determination unit is used to determine the Hartree Fock state of the target system in the form of fermions based on the electronic information and the electron spin orbit information of the target system.

[0032] Optionally, the building block includes:

[0033] A first configuration unit, configured to configure a first quantum register for storing phase information, wherein the first quantum register includes at least n quantum bits, and n≥4;

[0034] A second configuration unit is used to configure a second quantum register for storing the Hartree Fock state, wherein the number of quantum bits of the second quantum register is determined by the Hamiltonian of the target system;

[0035] a third configuration unit, configured to configure a second quantum logic gate acting on at least n direct products of the first quantum register and an inverse quantum Fourier transform unit acting on the first quantum register, wherein the controlled first quantum logic gate acts on the first quantum register and the second quantum register, and the quantum bit of the first quantum register is a control bit, and the quantum bit of the second quantum register is a target bit.

[0036] Optionally, the device further comprises:

[0037] An execution module, used for performing an encoding operation on the Hartree Fock state by a preset encoding method to obtain a quantum state in the form of a Pauli operator;

[0038] An energy calculation module is used to calculate the Hartree Fock energy of the target system according to the Hamiltonian of the target system and based on the quantum state in the form of the Pauli operator.

[0039] An embodiment of the present application provides a storage medium, in which a computer program is stored, wherein the computer program is configured to execute any of the above methods when running.

[0040] An embodiment of the present application provides an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute any one of the methods described above.

[0041] Compared with the prior art, the present invention first determines the Hartree Fock state of the fermion form of the target system, then constructs a quantum phase estimation circuit, generates a control pulse of the quantum logic gate in the quantum phase estimation circuit, and applies the control pulse to the quantum bit in the quantum phase estimation circuit to make the designated quantum bit evolve from the Hartree Fock state to the target quantum state, and finally calculates the ground state energy of the target system according to the Hartree Fock state and the target quantum state. By constructing a quantum phase estimation circuit that can be used for current quantum computing hardware devices, the present invention provides support for the realization of quantum chemical simulation calculation of the energy of the target system, improves the calculation speed and calculation accuracy, and promotes the simulation calculation of the ground state energy of the target system. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] Figure 1 is a system network block diagram for calculating target system energy provided by an embodiment of the present invention;

[0043] Figure 2 is a flow chart of a method for calculating the energy of a target system provided by an embodiment of the present invention;

[0044] Figure 3 It is a schematic diagram of a quantum circuit for generating a Hartree Fock state provided by an embodiment of the present invention;

[0045] Figure 4 It is a schematic diagram of the structure of a quantum phase estimation circuit provided by an embodiment of the present invention;

[0046] Figure 5 It is a schematic diagram of the structure of a device for calculating the energy of a target system provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0047] The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, but should not be construed as limiting the present invention.

[0048] The embodiment of the present invention first provides a method for calculating the energy of a target system. The method can be applied to electronic devices, such as computer terminals, specifically ordinary computers, quantum computers, etc.

[0049] The following describes it in detail by taking running on a computer terminal as an example. Figure 1 1 is a system network block diagram for calculating target system energy provided by an embodiment of the present invention. The system used for calculating target system energy may include a network 110, a server 120, a wireless device 130, a client 140, a storage unit 150, a classical processing system 160, a quantum processing system 170, and may also include additional memories, classical processors, quantum processors, and other devices not shown.

[0050] The network 110 is a medium that provides communication links between various devices and computers connected together within the system network used for the method of calculating the energy of the target system, including but not limited to the Internet, corporate intranets, local area networks, mobile communication networks and combinations thereof. The connection method can be wired, wireless communication links or optical fiber cables, etc.

[0051] The server 120 and the client 140 are conventional data processing systems that may contain data and applications or software tools that perform conventional computing processes. The client 140 may be a personal computer or a network computer, so the data may also be provided by the server 120. The wireless device 130 may be a smart phone, a tablet, a laptop, a smart wearable device, etc. The storage unit 150 may include a database 151, which may be configured to store data such as quantum bit parameters, quantum logic gate parameters, quantum circuits, quantum programs, etc.

[0052] The classical processing system 160 (quantum processing system 170) may include a classical processor 161 (quantum processor 171) for processing classical data (quantum data) and a memory 163 (memory 172) for storing classical data (quantum data). The classical data (quantum data) may be a boot file, an operating system image, and an application 162 (application 173). The application 162 (application 173) may be used to implement a quantum algorithm compiled according to a method for calculating the energy of a target system provided in an embodiment of the present invention.

[0053] Any data or information stored or generated in the classical processing system 160 (quantum processing system 170) can also be configured to be stored or generated in another classical (quantum) processing system in a similar manner, and any application program executed by it can also be configured to be executed in another classical (quantum) processing system in a similar manner.

[0054] It should be noted that a true quantum computer is a hybrid structure, which includes at least Figure 1 There are two major parts in it: the classical processing system 160, which is responsible for performing classical calculations and control; and the quantum processing system 170, which is responsible for running quantum programs and thus realizing quantum calculations.

[0055] The classical processing system 160 and the quantum processing system 170 may be integrated into one device or distributed in two different devices. For example, the first device including the classical processing system 160 runs a classical computer operating system, on which quantum application development tools and services are provided, as well as storage and network services required for quantum applications. Users develop quantum applications through the quantum application development tools and services thereon, and send quantum programs to the second device including the quantum processing system 170 through the network services thereon. The second device runs a quantum computer operating system, parses the code of the quantum program through the quantum computer operating system, and compiles it into instructions that can be recognized and executed by the quantum computer measurement and control system. The quantum processor 170 implements the quantum algorithm corresponding to the quantum program according to the instructions.

[0056] In the classic processing system 160 based on silicon chips, the unit of the classic processor 161 is a CMOS tube. This computing unit is not limited by time and coherence, that is, this computing unit is not limited by the length of use and is available at any time. In addition, in the silicon chip, the number of such computing units is also sufficient. At present, the number of computing units in a classic processor is tens of thousands. The number of computing units is sufficient and the computing logic that can be selected by the CMOS tube is fixed, for example: AND logic. When calculating with the help of CMOS tubes, a large number of CMOS tubes are combined with limited logic functions to achieve the calculation effect.

[0057] Unlike this logic unit in the classical processing system 160, the basic computing unit of the quantum processor 171 in the quantum processing system 170 is a quantum bit, and the input of the quantum bit is limited by coherence and coherence time, that is, the quantum bit is limited by the use time and is not available at any time. Making full use of the quantum bit within the available use time of the quantum bit is a key problem in quantum computing. In addition, the number of quantum bits in a quantum computer is one of the representative indicators of the performance of a quantum computer. Each quantum bit realizes the computing function through the logical function configured on demand. In view of the limited number of quantum bits, the logical functions in the field of quantum computing are diverse, such as: Hadamard gate (Hadamard gate, H gate), Pauli-X gate (X gate), Pauli-Y gate (Y gate) Pauli-Z gate (Z gate), X gate, RY gate, RZ gate, CNOT gate, CR gate, iSWAP gate, Toffoli gate, etc. In quantum computing, it is necessary to use limited quantum bits combined with a variety of logical functions to achieve the computing effect.

[0058] Based on these differences, the design of the role of logical functions in quantum bits (including the design of whether the quantum bits are used or not and the design of the efficiency of each quantum bit) is the key to improving the computing performance of quantum computers, and special designs are required. The above-mentioned design for quantum bits is a technical problem that ordinary computing devices do not need to consider or face. In this application, with the continuous improvement of quantum chemical theory, computational chemistry has become an important tool for chemists to explain experimental phenomena, predict experimental results, and guide experimental design. It has a wide range of applications in the synthesis of drugs and the preparation of catalysts. The calculation of the ground state energy of the target system based on the quantum phase estimation algorithm requires a sufficient number of quantum bits, but the number of available quantum bits of current quantum computers is very limited and cannot meet the computing needs of large systems. This limits the development of computational chemistry to a certain extent, resulting in the user's weak application of simulation calculations of chemical systems, affecting the further development of quantum chemical simulation applications. This application provides a method, device and medium for calculating the energy of a target system to solve the deficiencies in the prior art. It provides support for the realization of quantum chemical simulation calculation of the energy of the target system by constructing a quantum phase estimation circuit that can be used in current quantum computing hardware devices, improves the calculation speed and calculation accuracy, and promotes the simulation calculation of the ground state energy of the target system.

[0059] See also Figure 2 , Figure 2 It is a flow chart of a method for calculating the energy of a target system provided by an embodiment of the present invention.

[0060] This embodiment provides an embodiment of a method for calculating the energy of a target system. The method for calculating the energy of a target system may include:

[0061] S201: Determine the Hartree Fock state of the target system in fermion form.

[0062] Specifically, to determine the Hartree Fock state of the target system in the form of fermions, the target system information can be determined first. The target system information includes the Hamiltonian, electron information, and electron spin-orbit information of the target system.

[0063] Specifically, the target system can be considered as the molecular structure modeling for which the user wants to perform ground state energy simulation, including, for example, the number of electrons constituting the molecule, the type of electrons, and the spin-orbit information of the electrons.

[0064] Among them, Hamiltonian is a physical concept in classical mechanics, while in quantum mechanics, the physical quantities of classical mechanics become corresponding operators, and Hamiltonian corresponds to the Hamiltonian operator. Hamiltonian can be understood as the sum of the kinetic energy of all particles in the target system plus the potential energy of the particles related to the target system. For different situations or numbers of particles, Hamiltonian is different because it includes the sum of the kinetic energy of the particles and the potential energy function corresponding to this situation, generally represented by H.

[0065] In quantum mechanics, all measurable mechanical quantities can be described by a Hermitian matrix. The definition of a Hermitian matrix is ​​that the transposed conjugate of the matrix is ​​the matrix itself, that is,

[0066]

[0067] Such a matrix is ​​usually called a measurement operator. A non-zero operator will have at least one non-zero eigenvalue λ and a corresponding eigenstate |ψ>:

[0068] H|ψ>=λ|ψ>

[0069] If the eigenvalue of the operator H corresponds to the energy level distribution of a system, then such an operator can also be called a Hamiltonian.

[0070] An electron is a fundamental particle, generally referring to the number of electrons outside the nucleus of a target system. Electron spin orbit information uses mathematical methods to describe the probability of finding an electron in a specific space outside the nucleus of a target system, and points out the possible position of the electron in three-dimensional space.

[0071] In an optional implementation, determining the Hartree Fock state of the target system in the form of fermions may include: determining the Hartree Fock state of the target system in the form of fermions based on the electron information and electron spin-orbit information of the target system.

[0072] It should be noted that in quantum computing, the determination of the Hartree Fock state can be understood as the selection of a wave function, which requires a ground state wave function as a basis vector. For example, in quantum chemistry, the Hartree Fock state vector is usually used as the ground state wave function to satisfy:

[0073] ψ(θ)=U(θ)|ψ> Hartree-Fock

[0074] Among them, ψ(θ) represents the wave function corresponding to a set of parameters θ, U(θ) represents the matrix operator corresponding to a set of parameters θ, and the ground state wave function |ψ> Hartree-FockCorresponding to the Hartree Fock ground state in chemistry, it means that the electrons of the molecule are all in the lowest orbital.

[0075] In an alternative embodiment, see Figure 3 , Figure 3 This is a schematic diagram of a quantum circuit for generating a HartreeFock state provided by an embodiment of the present invention. For example, for a hydrogen molecule target system, it is only necessary to add a NOT gate to each of the two quantum bits to initialize |0000> to |0101> in the quantum circuit.

[0076] Taking the target system as an example, the hydrogen molecule contains four single-electron spin molecular orbitals and two electrons. According to the number of electrons in the hydrogen molecule and the electron spin orbital information, if a quantum bit represents an electron spin orbital, that is, 0 represents an empty orbital and 1 represents an occupied orbital, the Hartree Fock state of the hydrogen molecule target system can be represented by the quantum state |0101>.

[0077] S202: constructing a quantum phase estimation circuit, generating a control pulse of a quantum logic gate in the quantum phase estimation circuit, and applying the control pulse to a quantum bit in the quantum phase estimation circuit, so that a specified quantum bit evolves from the Hartree Fock state to a target quantum state; the quantum phase estimation circuit includes at least a controlled first quantum logic gate, and the unitary matrix of the first quantum logic gate satisfies: in, is the unitary matrix representation of the first quantum logic gate, is the phase, k is the number of iterations and k>1, b is the scaling factor, is the Hamiltonian of the target system.

[0078] Specifically, the step of constructing a quantum phase estimation circuit may include:

[0079] A first quantum register configured to store phase information, wherein the first quantum register includes at least n quantum bits, and n≥4;

[0080] configuring a second quantum register for storing the Hartree Fock state, wherein the number of quantum bits of the second quantum register is determined by the Hamiltonian of the target system;

[0081] A second quantum logic gate acting on at least n direct products of the first quantum register and an inverse quantum Fourier transform unit acting on the first quantum register are configured, the controlled first quantum logic gate acts on the first quantum register and the second quantum register, the quantum bit of the first quantum register is a control bit, and the quantum bit of the second quantum register is a target bit.

[0082] Wherein, the second quantum logic gate may include: a Hadamard gate.

[0083] For example, see Figure 4 , Figure 4 : is a schematic diagram of a quantum phase estimation circuit provided by an embodiment of the present invention. In the figure, the first quantum register includes 4 quantum bits, and a direct product H gate is applied to each quantum bit in the first quantum register, and the second quantum register includes m quantum bits and uses the HartreeFock state |ψ> in the form of fermions of the target system. Hartree-Fock is the initial state of the second quantum register, which is stored in the second quantum register. Quantum functional modules The inverse quantum Fourier transform unit is used in the first quantum register, and finally the measurement operation is performed on the first quantum register to obtain the target quantum state.

[0084] It should be noted that the control pulse of the quantum logic gate is an important part of quantum simulation computing, which involves how to design the control pulse based on the target problem to achieve the desired target quantum operation. The goal of the control pulse design is to enable the system to achieve the required quantum logic gate operation within a certain period of time, and to have a certain robustness and fault tolerance to noise and system errors. Among them, the control pulse design needs to clarify the target quantum operation to be generated, and the target quantum operation is usually composed of some basic quantum logic gate operations, such as the H gate in this application.

[0085] S203: Calculate the ground state energy of the target system according to the Hartree Fock state and the target quantum state.

[0086] Specifically, before calculating the ground state energy of the target system according to the Hartree Fock state and the target quantum state, the method further includes:

[0087] Step 1: Perform an encoding operation on the Hartree Fock state using a preset encoding method to obtain a quantum state in the form of a Pauli operator.

[0088] Specifically, N preset quantum bits may be determined first, and the Hartree Fock state in the form of fermions may be converted into the Hilbert space in the form of Pauli operators through a preset encoding method, so that each fermion state may be represented by a quantum state.

[0089] The electronic information of the target system may include α electrons and β electrons, and the quantum state in the form of Pauli operators can be represented by the following form:

[0090]

[0091] p is the spin orbit number of the α electron or β electron, M is the number of the spin orbit of the α electron or β electron, and

[0092] In an optional embodiment, the pre-set encoding method can be one of the Parity transform, the Jordan-Wigner transform, or the Bravyi-Kitaev transform. From the Jordan-Wigner mapping to the Parity transform or the Bravyi-Kitaev mapping, because the number of electrons and the number of spin electrons of the target system are conserved, this is true for any Slater determinant that retains the number of alpha electrons. It can be seen that the ground state is just a linear combination of Slater determinants, and because the calculation of the ground state energy can essentially be regarded as a problem of the distribution of electrons between orbitals, the above information can be used to simplify the calculation. Specifically, if the expected occupancy number of an orbital is close to 0 or 1, it can be removed from the calculation. The calculation is therefore simplified to include only the most important orbitals, which is called performing the calculation of the energy of the target system in a reduced activity space.

[0093] For example, for the Jordan-Wigner transform, its Slater determinant can be expressed as:

[0094]

[0095]

[0096] Step 2: Calculate the Hartree Fock energy of the target system according to the Hamiltonian of the target system and based on the quantum state in the Pauli operator form.

[0097] Specifically, according to the Hamiltonian of the target system, the expectation value corresponding to the Hamiltonian can be measured. The Hamiltonian of the target system in the second quantization method can be mapped to a linear combination of local Pauli operator products by introducing a preset transformation method. The expectation value of the second quantization operator must be equivalent to the expectation value of the corresponding first quantization operator. Since the first quantization operator keeps the number of electrons unchanged, the second quantization operator must contain an equal number of creation and annihilation operators. That is, these requirements can be used to obtain the second quantization form of the electronic Hamiltonian:

[0098]

[0099] In an optional embodiment, calculating the Hartree Fock energy of the target system according to the Hamiltonian of the target system and based on the quantum state of the Pauli operator form may include:

[0100] Step a: Obtain the fermion Hamiltonian corresponding to the target system, and transform the fermion Hamiltonian corresponding to the target system into the Pauli Hamiltonian of the target system.

[0101] Specifically, based on the mechanical analysis of the target system, the Hamiltonian of this system can be obtained. To obtain the fermion Hamiltonian corresponding to the target system, the creation operator is required. and the annihilation operator a q To achieve this, they satisfy the anti-commutation relation.

[0102] For example, for a hydrogen molecule system, the corresponding fermion Hamiltonian is:

[0103]

[0104] It should be noted that in quantum computing, the Hamiltonian in fermion form cannot be directly evolved on the circuit, so there needs to be a process to convert the expected value solution in integral form into a readable one for the quantum circuit, which is called mapping. It should be noted that mapping is just to express the Hamiltonian in another form, and the system energy information represented by each type of Hamiltonian is equivalent. In addition, for a quantum simulation circuit or a real quantum chip, the Pauli operator is easier to operate and generate, so the fermion Hamiltonian corresponding to the target system can be transformed into the Pauli Hamiltonian of the target system, which is convenient for subsequent simulation operations.

[0105] Continuing with the above example, for the hydrogen molecule system, the corresponding fermion Hamiltonian is transformed into the Pauli Hamiltonian, specifically:

[0106]

[0107] Step b: According to the sub-items of the Pauli Hamiltonian decomposed by the target system, construct quantum circuits corresponding to the sub-items of the Pauli Hamiltonian of the target system.

[0108] Specifically, we can first obtain the experimental state of the target system |ψ n >, and then use the quantum expectation estimation algorithm to calculate the test state |ψ n >Expectation on the molecular Hamiltonian. The so-called quantum expectation estimate means that the Hamiltonian H of the multi-electron system, Heisenberg model, quantum Ising model and other systems can be expanded into the sum of multiple sub-terms, that is:

[0109]

[0110] Among them, h is a real number, σ is the Pauli operator, α, β and γ∈(X,Y,Z,I), and i, j, k represent the subspaces on which the Hamiltonian quantum terms act.

[0111] Since the observables are linear, the average energy of the system can be calculated using the following formula:

[0112] E HF =<ψ * |H|ψ>

[0113] Among them, ψ * is orthogonal to ψ, and the right side of the equation can also be expanded into this form:

[0114]

[0115] It can be seen that we only need to calculate the expectation of each sub-item first, and then sum up the expectations to get the average energy E of the system. It should be noted that the measurement of the expectation of each sub-item can be performed on a quantum processor, and the classical processor can be responsible for summing up the expectations.

[0116] For example, assuming that the Hamiltonian of a system is H, it can eventually be expanded into this form:

[0117]

[0118] In this formula, all sub-item coefficients h are 1, and it is assumed that the obtained test state is in the following form:

[0119] |ψ n >=a|00>+b|01>+c|10>+d|11>

[0120] Among them, a 2 , b 2 、c 2 d 2 They refer to the probability P of collapsing to |00>, |01>, |10>, and |11> respectively when measuring the test state. S , applying each sub-term H1, H2, H3 of the Hamiltonian to the test state respectively, we can get the expected E1, E2, E3 in turn, specifically:

[0121] E1=<ψ * |H1|ψ>

[0122] E2=<ψ * |H2|ψ〉

[0123] E3=〈ψ * |H3|ψ〉

[0124] Taking E1, E2, and E3 as examples, for the expected E1, the coefficient h is the expected value, and there is no need to construct line measurements, that is, For the expectation E2, its Hamiltonian is Since the measurement operation is performed at σ Z On (with σ Z The eigenvectors of are the subspace formed by the basis vectors), so we only need to add measurement gates to the quantum bits, and then pass the measurement results to the classical processor for summation.

[0125] Step c: Use the quantum circuits corresponding to each sub-term of the Pauli Hamiltonian of the target system to measure the Hartree Fock energy of the test state.

[0126] Specifically, by expanding the expected measurement circuits of each sub-item of the Pauli Hamiltonian of the target system, we can obtain the measurement circuits of each sub-item expectation E(i). Then the quantum processor transmits E(i) to the classical processor in sequence for summation, and the Hartree Fock energy of the target system in the test state is obtained.

[0127] It should be noted that since the measurement operation is performed at σ Z For the x , σ y The Hamiltonian cannot be measured directly at this time, and it is necessary to measure σ x and σ y Perform a base change operation, that is, let the test state evolve again. x =H×σ Z ×H, That is, for σ x and σ y Before measurement, the Hadamard gate and The measurement results are then passed to a classical processor for summation.

[0128] It should be emphasized that the above-mentioned simulated methods, mapping methods and optimization methods are merely examples and do not constitute a limitation of the present invention. For example, the simulated methods also include HE (Hardware Efficient) and SP (Symmetry Preserved) methods.

[0129] In an optional implementation, calculating the ground state energy of the target system according to the Hartree Fock state and the target quantum state may include:

[0130] The ground state energy of the target system is calculated by the following formula:

[0131]

[0132] Wherein, E represents the ground state energy of the target system, E HF represents the Hartree Fock energy of the target system, is the phase after superposition.

[0133] For example, using Figure 4 The quantum phase estimation circuit shown here performs the evolution and measurement operations on the Hartree Fock state and can be expressed as:

[0134] U|ψ>=e (i*2πθ) |ψ>

[0135] Right now:

[0136] e (-ibH) |ψ>=e (-ibE) |ψ>=e (i*2πθ) |ψ>

[0137] It can be seen that:

[0138]

[0139] where θ is the phase and θ∈[0,1).

[0140] It should be noted that due to e (i*2πθ) It is a periodic function. To ensure that θ∈[0,1), a reasonable scaling factor b needs to be set. For example, the scaling factor b can be determined based on the Hartree Fock energy of the target system, and the phase θ=0.5 is preset at this time, and we can get:

[0141]

[0142] because

[0143] When k = 1, Assuming that the target quantum state measured by the first quantum register is |ψ1>, the corresponding phase

[0144] When k = 2, Assuming that the target quantum state measured by the first quantum register is |ψ2>, the corresponding phase

[0145] When k = 3, Assuming that the target quantum state measured by the first quantum register is |ψ3>, the corresponding phase

[0146] By analogy, at the kth iteration, Assume that the target quantum state obtained by the measurement of the first quantum register is |ψ k >, then the corresponding phase

[0147] And because:

[0148]

[0149] Right now:

[0150]

[0151] according to:

[0152]

[0153] get:

[0154]

[0155] So we can infer that the phase θ is:

[0156]

[0157] That is, the ground state energy of the target system is calculated by the following formula:

[0158]

[0159] It can be seen from the above formula that the more iterations there are, the higher the accuracy of obtaining the ground state energy of the target system.

[0160] It can be seen that the present invention first determines the Hartree Fock state of the fermion form of the target system, then constructs a quantum phase estimation circuit, generates a control pulse of the quantum logic gate in the quantum phase estimation circuit, and applies the control pulse to the quantum bit in the quantum phase estimation circuit, so that the specified quantum bit evolves from the Hartree Fock state to the target quantum state, and finally calculates the ground state energy of the target system according to the Hartree Fock state and the target quantum state. It provides support for the realization of quantum chemical simulation calculation of the energy of the target system by constructing a quantum phase estimation circuit that can be used for current quantum computing hardware devices, improves the calculation speed and calculation accuracy, and promotes the simulation calculation of the ground state energy of the target system.

[0161] See also Figure 5 , Figure 5 is a schematic diagram of a structure of a device for calculating target system energy provided by an embodiment of the present invention, and Figure 2 Corresponding to the process shown, the device includes:

[0162] A determination module 501 is used to determine the Hartree Fock state of the target system in the form of fermions;

[0163] A construction module 502 is used to construct a quantum phase estimation circuit, generate a control pulse of a quantum logic gate in the quantum phase estimation circuit, and apply the control pulse to a quantum bit in the quantum phase estimation circuit to make a specified quantum bit evolve from the Hartree Fock state to a target quantum state; the quantum phase estimation circuit includes at least a controlled first quantum logic gate, and the unitary matrix of the first quantum logic gate satisfies: in, is the unitary matrix representation of the first quantum logic gate, is the phase, k is the number of iterations and k>1, b is the scaling factor, is the Hamiltonian of the target system;

[0164] The calculation module 503 is used to calculate the ground state energy of the target system according to the Hartree Fock state and the target quantum state.

[0165] Specifically, the determination module includes:

[0166] The determination unit is used to determine the Hartree Fock state of the target system in the form of fermions based on the electronic information and the electron spin orbit information of the target system.

[0167] Specifically, the building blocks include:

[0168] A first configuration unit, configured to configure a first quantum register for storing phase information, wherein the first quantum register includes at least n quantum bits, and n≥4;

[0169] A second configuration unit is used to configure a second quantum register for storing the Hartree Fock state, wherein the number of quantum bits of the second quantum register is determined by the Hamiltonian of the target system;

[0170] a third configuration unit, configured to configure a second quantum logic gate acting on at least n direct products of the first quantum register and an inverse quantum Fourier transform unit acting on the first quantum register, wherein the controlled first quantum logic gate acts on the first quantum register and the second quantum register, and the quantum bit of the first quantum register is a control bit, and the quantum bit of the second quantum register is a target bit.

[0171] Specifically, the device further includes:

[0172] An execution module, used for performing an encoding operation on the Hartree Fock state by a preset encoding method to obtain a quantum state in the form of a Pauli operator;

[0173] An energy calculation module is used to calculate the Hartree Fock energy of the target system according to the Hamiltonian of the target system and based on the quantum state in the form of the Pauli operator.

[0174] Compared with the prior art, the present invention first determines the Hartree Fock state of the fermion form of the target system, then constructs a quantum phase estimation circuit, generates a control pulse of the quantum logic gate in the quantum phase estimation circuit, and applies the control pulse to the quantum bit in the quantum phase estimation circuit to make the designated quantum bit evolve from the Hartree Fock state to the target quantum state, and finally calculates the ground state energy of the target system according to the Hartree Fock state and the target quantum state. By constructing a quantum phase estimation circuit that can be used for current quantum computing hardware devices, the present invention provides support for the realization of quantum chemical simulation calculation of the energy of the target system, improves the calculation speed and calculation accuracy, and promotes the simulation calculation of the ground state energy of the target system.

[0175] An embodiment of the present invention further provides a storage medium, in which a computer program is stored, wherein the computer program is configured to execute the steps of any of the above method embodiments when running.

[0176] Specifically, in this embodiment, the above storage medium may be configured to store a computer program for performing the following steps:

[0177] S201: Determine the Hartree Fock state of the target system in the form of fermions;

[0178] S202: constructing a quantum phase estimation circuit, generating a control pulse of a quantum logic gate in the quantum phase estimation circuit, and applying the control pulse to a quantum bit in the quantum phase estimation circuit, so that a specified quantum bit evolves from the Hartree Fock state to a target quantum state; the quantum phase estimation circuit includes at least a controlled first quantum logic gate, and the unitary matrix of the first quantum logic gate satisfies: in, is the unitary matrix representation of the first quantum logic gate, is the phase, k is the number of iterations and k>1, b is the scaling factor, is the Hamiltonian of the target system;

[0179] S203: Calculate the ground state energy of the target system according to the Hartree Fock state and the target quantum state.

[0180] Specifically, in this embodiment, the above-mentioned storage medium may include but is not limited to: a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk, and other media that can store computer programs.

[0181] An embodiment of the present invention further provides an electronic device, comprising a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.

[0182] Specifically, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.

[0183] Specifically, in this embodiment, the processor may be configured to perform the following steps through a computer program:

[0184] S201: Determine the Hartree Fock state of the target system in the form of fermions;

[0185] S202: constructing a quantum phase estimation circuit, generating a control pulse of a quantum logic gate in the quantum phase estimation circuit, and applying the control pulse to a quantum bit in the quantum phase estimation circuit, so that a specified quantum bit evolves from the Hartree Fock state to a target quantum state; the quantum phase estimation circuit includes at least a controlled first quantum logic gate, and the unitary matrix of the first quantum logic gate satisfies: in, is the unitary matrix representation of the first quantum logic gate, is the phase, k is the number of iterations and k>1, b is the scaling factor, is the Hamiltonian of the target system;

[0186] S203: Calculate the ground state energy of the target system according to the Hartree Fock state and the target quantum state.

[0187] An embodiment of the present invention may also provide a quantum computer operating system, which implements a method for calculating the energy of a target system according to any of the above method embodiments provided in an embodiment of the present invention.

[0188] An embodiment of the present application may also provide a quantum computer, wherein the quantum computer includes the quantum computer operating system.

[0189] The above describes in detail the structure, features and effects of the present invention based on the embodiments shown in the drawings. The above is only a preferred embodiment of the present invention, but the present invention is not limited to the scope of implementation shown in the drawings. Any changes made according to the concept of the present invention, or modifications to equivalent embodiments with equivalent changes, which still do not exceed the spirit covered by the description and drawings, should be within the protection scope of the present invention.

Claims

1. A method for calculating the energy of a target system, characterized in that: The method comprises: Determine the Hartree Fock state of the target system in fermion form; A quantum phase estimation circuit is constructed, a control pulse of a quantum logic gate in the quantum phase estimation circuit is generated, and the control pulse is applied to a quantum bit in the quantum phase estimation circuit so that a specified quantum bit evolves from the Hartree Fock state to a target quantum state; the quantum phase estimation circuit includes at least a controlled first quantum logic gate, and a unitary matrix of the first quantum logic gate satisfies: in, is the unitary matrix representation of the first quantum logic gate, is the phase, k is the number of iterations and k>1, b is the scaling factor, is the Hamiltonian of the target system; The ground state energy of the target system is calculated according to the Hartree Fock state and the target quantum state.

2. The method according to claim 1, characterized in that The determining of the HartreeFock state of the fermion form of the target system comprises: Based on the electronic information and electron spin-orbit information of the target system, the Hartree Fock state of the target system in the form of fermions is determined.

3. The method according to claim 2, characterized in that The construction of the quantum phase estimation circuit comprises: A first quantum register configured to store phase information, wherein the first quantum register includes at least n quantum bits, and n≥4; configuring a second quantum register for storing the Hartree Fock state, wherein the number of quantum bits of the second quantum register is determined by the Hamiltonian of the target system; A second quantum logic gate acting on at least n direct products of the first quantum register and an inverse quantum Fourier transform unit acting on the first quantum register are configured, the controlled first quantum logic gate acts on the first quantum register and the second quantum register, the quantum bit of the first quantum register is a control bit, and the quantum bit of the second quantum register is a target bit.

4. The method according to claim 3, characterized in that Before calculating the ground state energy of the target system according to the Hartree Fock state and the target quantum state, the method further includes: Performing an encoding operation on the Hartree Fock state by a preset encoding method to obtain a quantum state in the form of a Pauli operator; The Hartree Fock energy of the target system is calculated according to the Hamiltonian of the target system and based on the quantum state in the Pauli operator form.

5. The method according to claim 4, characterized in that The second quantum logic gate includes: a Hadamard gate.

6. The method according to claim 5, characterized in that The preset encoding methods include: Parity transform, Jordan-Wigner transform, or Bravyi-Kitaev transform.

7. The method according to any one of claims 4 to 6, characterized in that: The step of calculating the ground state energy of the target system according to the Hartree Fock state and the target quantum state includes: The ground state energy of the target system is calculated by the following formula: Wherein, E represents the ground state energy of the target system, E HF represents the Hartree Fock energy of the target system, is the phase after superposition.

8. A device for calculating the energy of a target system, characterized in that: The device comprises: Determination module, used to determine the Hartree Fock state of the target system in fermion form; A construction module is used to construct a quantum phase estimation circuit, generate a control pulse of a quantum logic gate in the quantum phase estimation circuit, and apply the control pulse to a quantum bit in the quantum phase estimation circuit to make a specified quantum bit evolve from the Hartree Fock state to a target quantum state; the quantum phase estimation circuit includes at least a controlled first quantum logic gate, and the unitary matrix of the first quantum logic gate satisfies: in, is the unitary matrix representation of the first quantum logic gate, is the phase, k is the number of iterations and k>1, b is the scaling factor, is the Hamiltonian of the target system; A calculation module is used to calculate the ground state energy of the target system according to the Hartree Fock state and the target quantum state.

9. A storage medium, characterized in that: The storage medium stores a computer program, wherein the computer program is configured to execute the method according to any one of claims 1 to 7 when executed.

10. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to run the computer program to perform the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Generating quantum computing circuits by distributing approximation errors in a quantum algorithm

    CN112204583A

  • Method and device for calculating energy of target system based on quantum chemistry and medium

    CN114492815A

  • Quantum comparison method and device for matrix eigenvalues

    CN114819168A

  • Method and device for obtaining eigenvalue of system to be tested based on quantum gate

    CN115545202A

  • Verified quantum phase estimation

    CN116508030A