Quantum computing support program, quantum computing support method, and information processing device.
The quantum computing support program optimizes observable partitioning by reducing 2-qubit gates through index-based selection and basis transformation, addressing inefficiencies in existing GC methods and enhancing computational efficiency.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2024-09-05
- Publication Date
- 2026-03-17
AI Technical Summary
Existing quantum computing methods using garbage collection (GC) for observable partitioning result in a high number of 2-qubit gates, leading to increased noise and computational inefficiencies due to the high noise level of these gates.
A quantum computing support program that calculates an index value for each observable based on the number of characters other than 'I' in the Pauli string, selects a predetermined number of observables, and generates a basis transformation circuit to convert the expected values into 1-qubit measurement results, reducing the number of 2-qubit gates.
Reduces the number of 2-qubit gates in the basis conversion circuit, enhancing computational efficiency by minimizing noise and improving the overall performance of quantum computations.
Smart Images

Figure 2026048557000001_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a quantum computing support program, a quantum computing support method, and an information processing apparatus.
Background Art
[0002] A quantum computer can measure the expected value of a target physical quantity (observable) using quantum bits. An observable is represented by an array of Pauli operators (X, Y, Z, I). This array of Pauli operators is called a Pauli string. Each Pauli operator in the Pauli string corresponds to a quantum bit for measuring a state. The Pauli string indicates the tensor product of the Pauli operators included in the Pauli string. For example, the observable "ZZI" is "Z×Z×I" (× is × in a circle and indicates a tensor product). Hereinafter, the tensor product of Pauli operators may be simply referred to as a product.
[0003] A quantum circuit to be executed on a quantum computer has a quantum circuit that executes a quantum calculation corresponding to a problem to be solved and a basis conversion circuit that performs a basis conversion for outputting an observable to be measured. A plurality of observables satisfying certain conditions can be simultaneously measured by the same basis conversion circuit. In order for a plurality of observables to be simultaneously measurable, it is required that those observables commute with each other.
[0004] There are two levels of "commute" for observables: QWC (Qubit-Wise Commute) and GC (General Commute). In QWC, for each quantum bit, when the corresponding Pauli characters of a plurality of observables commute with each other, the plurality of observables commute with each other. If they commute in QWC, they also commute in QC. In GC, furthermore, for each quantum bit, even when the corresponding Pauli characters of a plurality of observables do not commute with each other, if a predetermined condition is satisfied, they commute as a whole Pauli string.
[0005] The process of dividing multiple observables to be measured into groups of observables (partitions) that can be measured simultaneously is called partitioning. Proper partitioning makes it possible to efficiently measure expected values simultaneously.
[0006] Regarding observable partitioning techniques, for example, partitioning methods have been proposed that reduce the number of partitions containing simultaneously measurable observables. Furthermore, methods have been proposed to reduce the circuit depth and number of entangled gates of quantum circuits as a way to generate quantum circuits from unitarily coupled Ansatz clusters. In addition, systems have been proposed to facilitate partitioned template matching or symbolic beep-hole optimization, or both. [Prior art documents] [Patent Documents]
[0007] [Patent Document 1] International Publication No. 2022 / 269712 [Patent Document 2] Special Publication No. 2023-521223 [Patent Document 3] Special Publication No. 2023-547348 [Overview of the project] [Problems that the invention aims to solve]
[0008] Applying QWC to partitioning allows for basis transformations with a single qubit operation, but it also increases the number of partitions. A larger number of partitions requires more execution of the quantum circuit to obtain the values of all observables, thus worsening the computational efficiency of solving the problem.
[0009] In partitioning using garbage collection (GC), the number of partitions is significantly reduced compared to quantum wakework (QWC), and GC allows for more efficient computation than QWC. However, GC includes many 2-qubit gates in its basis conversion circuit. The gate operations of 2-qubit gates have a high noise level and can be a source of errors.
[0010] In one aspect, this project aims to reduce the number of 2-qubit gates in the basis conversion circuit. [Means for solving the problem]
[0011] One proposal provides a quantum computing support program that instructs a computer to perform the following processes: The computer calculates an index value for each of the multiple simultaneously measurable observables included in the observable group, based on the number of characters other than 'I' in the Pauli string representing the observable. The computer selects a predetermined number of observables from the observable group based on the index value. The computer then generates a basis transform circuit that converts the expected value of each of the selected predetermined number of observables in the execution result of a quantum circuit that performs quantum computation according to the problem to be solved into a 1-qubit measurement result. [Effects of the Invention]
[0012] According to one embodiment, the number of 2-qubit gates in the basis conversion circuit can be reduced. [Brief explanation of the drawing]
[0013] [Figure 1] This figure shows an example of a quantum computing support method according to the first embodiment. [Figure 2] This figure shows an example of the system configuration of the second embodiment. [Figure 3] This figure shows an example of the hardware of a classical computer. [Figure 4] This figure shows an example of determining an exchange relationship. [Figure 5]This is a diagram showing an example of partitioning. [Figure 6] This figure shows an example of a basis transformation operation. [Figure 7] This figure shows a first example of a basis transform circuit corresponding to a basis transform operation. [Figure 8] This figure shows a second example of a basis change circuit corresponding to a basis change operation. [Figure 9] This figure shows an example of a basis transformation operation. [Figure 10] This figure shows the first example of the transformation of Pauli strings representing observables using a basis transformation circuit. [Figure 11] This figure shows a second example of the transformation of Pauli strings representing observables using a basis transformation circuit. [Figure 12] This figure shows an example of how to select observables to include in generator "G". [Figure 13] This diagram shows an example of the generation process of generator "G". [Figure 14] This figure shows an example of a method for generating a basis conversion circuit. [Figure 15] This figure shows an example of a basis transformation operation (1 / 5). [Figure 16] This figure shows an example of a basis transformation operation (2 / 5). [Figure 17] This figure shows an example of a basis transformation operation (3 / 5). [Figure 18] This figure (4 / 5) shows an example of a basis transformation operation. [Figure 19] This figure shows an example of a basis transformation operation (5 / 5). [Figure 20] This figure shows an example of the capabilities that classical computers possess to perform quantum computations. [Figure 21] This is a flowchart showing an example of a quantum computing procedure. [Figure 22] This flowchart shows an example of the procedure for generating quantum circuits. [Figure 23] This flowchart shows an example of the procedure for the generator generation process. [Figure 24]This figure shows an example of adding an element to the set "Q". [Figure 25] This is a flowchart (1 / 2) showing an example of the procedure for adding elements to Q. [Figure 26] This is a flowchart (2 / 2) showing an example of the procedure for adding elements to Q. [Figure 27] This flowchart shows an example of the procedure for determining the basis transformation operation. [Figure 28] This flowchart shows an example of the procedure for determining the H operation. [Figure 29] This is a flowchart showing an example of the procedure for determining CX operation. [Figure 30] This flowchart shows an example of the procedure for H conversion and CX conversion. [Figure 31] This flowchart shows an example of the procedure for H operation and CX operation processing. [Figure 32] This flowchart shows an example of the procedure for determining the S operation. [Figure 33] This flowchart shows an example of the procedure for determining the CZ operation. [Figure 34] This is a diagram (1 / 5) showing an example of a basis transformation operation. [Figure 35] Figure (2 / 5) shows an example of a basis transformation operation. [Figure 36] Figure (3 / 5) shows an example of a basis transformation operation. [Figure 37] Figure (4 / 5) shows an example of a basis transformation operation. [Figure 38] Figure (5 / 5) shows an example of a basis transformation operation. [Figure 39] This figure shows an example of a generated basis transformation circuit. [Figure 40] This figure shows an example of determining the basis transformation operation in the H-transform and CX-transform process. [Figure 41] This figure shows an example of partitioning results. [Figure 42] This figure shows an example of the number of 2 quantum gates in the generated basis conversion circuit. [Figure 43]This figure shows an example of a partition generator for partition number "2". [Figure 44] This figure shows an example of a partition generator for partition number "10". [Figure 45] This figure shows an example of the number of 2-qubit gates corresponding to the weights of the characters used to calculate the index value. [Modes for carrying out the invention]
[0014] The following description of this embodiment will be made with reference to the drawings. Note that each embodiment can be implemented by combining multiple embodiments within a reasonable scope. [First Embodiment] The first embodiment is a quantum computing support method that enables the generation of a basis transform circuit for simultaneously measuring observables using as few as two qubit gates.
[0015] Figure 1 shows an example of a quantum computing support method according to the first embodiment. Figure 1 shows an information processing device 10 that implements the quantum computing support method. The information processing device 10 can implement the quantum computing support method, for example, by executing a quantum computing support program.
[0016] The information processing device 10 includes a storage unit 11 and a processing unit 12. The storage unit 11 is, for example, a memory or storage device of the information processing device 10. The processing unit 12 is, for example, a processor or arithmetic circuit of the information processing device 10.
[0017] The information processing device 10 is connected to the quantum computer 1 and causes the quantum computer 1 to perform quantum computations. For example, the information processing device 10 obtains the expected value of the observable obtained as a result of the quantum computation from the quantum computer 1. Based on the expected values of a number of observables, the information processing device 10 calculates the solution to the problem to be solved.
[0018] For example, the processing unit 12 of the information processing device 10 causes the quantum computer 1 to execute a quantum circuit 8 that shows the procedure for quantum computation according to the problem to be solved, and a basis transform circuit 9 for measuring the observable obtained from the execution result of the quantum circuit 8. At this time, the processing unit 12 generates the basis transform circuit 9 for simultaneously measuring multiple observables using a small number of 2-qubit gates.
[0019] For example, suppose there is an observable group 2 that includes multiple observables that can be measured simultaneously. Note that observable group 2 may include observables used in calculating the solution to the problem to be solved and observables that are not necessary for calculating the solution. For each of the multiple observables that can be measured simultaneously in observable group 2, the processing unit 12 calculates an index value according to the number of characters other than "I" in the Pauli string representing the observable. For example, the processing unit 12 calculates an index value in which observables with fewer characters other than "I" in the Pauli string representing the observable in observable group 2 will have a higher selection order.
[0020] The processing unit 12 selects a predetermined number of observables 3a to 3d from among the observables included in the observable group 2 based on an index value. For example, the processing unit 12 selects a predetermined number of observables 3a to 3d in order of their ranking based on the index value. The number of observables 3a to 3d to be selected is, for example, the same as the number of qubits operated by the quantum circuit 8.
[0021] The processing unit 12 then generates a basis conversion circuit 9. The basis conversion circuit 9 is a quantum circuit that converts the expected values of each of the selected predetermined number of observables 3a to 3d in the execution result of the quantum circuit 8 into a 1-qubit measurement result.
[0022] In this way, by selecting a predetermined number of observables 3a to 3d according to the number of characters other than "I" in the Pauli string representing the observable, it is possible to select, for example, an observable with a small number of characters other than "I" in the Pauli string. As a result, the number of 2-qubit gates included in the basis conversion circuit 9 is reduced.
[0023] In other words, after the gate operation of the basis conversion circuit 9, the expected value of the selected predetermined number of observables 3a to 3d becomes equal to the expected value of the observable represented by the Pauli string of one "Z" and one or more "I"s.
[0024] At this time, the expected values of each of the selected predetermined number of observables 3a to 3d are obtained from the measurement results of each qubit after the gate operation of the basis transform circuit 9. In the example in Figure 1, the Pauli string of observable 3a is "XXXX", and the expected value of this observable 3a is obtained as the expected value of "ZIII" (measurement result of the first qubit) after the execution of the basis transform circuit 9. The Pauli string of observable 3b is "IZIZ", and the expected value of this observable 3b is obtained as the expected value of "IZII" (measurement result of the second qubit) after the execution of the basis transform circuit 9. The Pauli string of observable 3c is "IIZZ", and the expected value of this observable 3c is obtained as the expected value of "IIZI" (measurement result of the third qubit) after the execution of the basis transform circuit 9. The Pauli string of the observable 3d is "ZIIZ", and the expected value of this observable 3d is obtained as the expected value of "IIIZ" after the execution of the basis change circuit 9 (the measurement result of the fourth qubit).
[0025] Of the observables 6a to 6c within group 2 used to calculate the solution to the problem to be solved, the expected values of the unselected observables can be calculated from the measurement results of the selected observables 3a to 3d. In other words, if the expected values of the selected observables 3a to 3d can be measured, the expected values of the observables 6a to 6c used to calculate the solution to the problem to be solved can be obtained.
[0026] In the basis conversion circuit 9, for example, one character of a Pauli string, such as "ZIII", is converted to "Z", and all other characters are converted to "I". A 2-qubit gate is used to convert characters other than "I" to "I". Therefore, the more "I" characters there are in the selected observables 3a to 3d before conversion, the fewer 2-qubit gates are needed in the basis conversion circuit 9.
[0027] The index value is, for example, a linear sum of the number of "X," "Y," and "Z" characters in the Pauli string representing the observable. In this case, a smaller index value indicates a higher selection order. By calculating the index value using a linear sum, it becomes possible to appropriately set the weight coefficients for "X," "Y," and "Z," thereby optimizing the selection of observables 3a to 3d.
[0028] For example, processing unit 12 calculates the index value by setting the weight coefficient for the number of "Y"s in the linear combination to a value greater than the respective weight coefficients for the number of "X"s and the number of "Z"s. If the weight coefficients for the number of "X"s and the number of "Z"s are "1" and the weight coefficient for the number of "Y"s is "2", then the index value becomes "number of Xs + number of Zs + 2 × number of Ys". In this case, the index value for the Pauli string "IIZZ,IZIZ,···" is "2". The index value for the Pauli string "XXXX,ZZZZ" is "4". The index value for the Pauli string "XYYX,YYXX,···" is "6". The index value for the Pauli string "YYYY" is "8".
[0029] By setting a high weight coefficient for "Y", the inclusion of "Y" in the Pauli strings of the selected observables 3a to 3d is suppressed. When the basis conversion circuit 9 converts "Y" to "I", it is converted to "X" or "Z" first, and then to "I". Therefore, the more "Y" is included in the Pauli strings of the selected observables 3a to 3d, the more 2-qubit gates will be included in the basis conversion circuit 9. In other words, by suppressing the inclusion of "Y" in the Pauli strings of the selected observables 3a to 3d, the number of 2-qubit gates included in the basis conversion circuit 9 is also suppressed.
[0030] Observables within Observable Group 2 can be generated based on Observable Group 4, which includes observables used to calculate the solution to the problem to be solved. For example, the processing unit 12 partitions Observable Group 4 and generates multiple partitions 5a to 5c that group together observables that can be measured simultaneously. In this case, the processing unit 12 generates a basis transform circuit 9 for each of the multiple partitions 5a to 5c.
[0031] For example, partition 5c contains multiple simultaneously measurable observables 6a to 6c from the observable group 4. In this case, the processing unit 12 includes, for example, observables 6a to 6c and observables 7a to 7d, which are represented by the product of observables 6a to 6c, in the observable group 2. Observables 7a to 7d are simultaneously measurable with observables 6a to 6c, which are used to calculate the solution to the problem to be solved.
[0032] In this way, by including observables 7a to 7d, which are not used in calculating the solution to the problem to be solved, in observable group 2, the likelihood of observables with fewer characters other than "I" being included in observable group 2 increases. This makes it possible to reduce the number of characters other than "I" in the Pauli strings of the selected observables 3a to 3d, and thus reduce the number of 2-qubit gates included in the basis conversion circuit 9.
[0033] If the number of qubits being manipulated by quantum circuit 8 is n (where n is a natural number), then, excluding the trivial Pauli string "II..." (all "I"), the number of simultaneously measurable observables is "2 n The number of observables in the observable group 2 is "2 n If the number of observables in Observable Group 2 is less than "-1", then the number of observables in Observable Group 2 is "2 n You may add observables to group 2 of observables so that there are -1 of them.
[0034] For example, even if you add observables 7a to 7c to observable group 2, the sum of the number of observables 6a to 6c and the number of observables 7a to 7c is "2 n There are cases where it is less than -1. Therefore, the processing unit 12 generates an additional observable 2a that is commutative with each of the multiple observables 6a to 6c and has a number of characters other than "I" in the Pauli string that is 2 or less. Then the processing unit 12 includes the observables 6a to 6c, the newly generated observable 2a, and the observables 2b-1, 2b-2, ... (white circles in the figure), which are represented by the product of two or more of the observables 6a to 6c and observable 2a, in the observable group 2. As a result, "2 n A group of observables 2 is obtained that contains -1 observables.
[0035] This makes it possible to select appropriate observables 3a to 3d from the group of observables 2, which includes all observables that can be measured simultaneously with observables 6a to 6c. As a result, the number of characters other than "I" in the Pauli string of the selected observables 3a to 3d can be minimized, and the number of 2-qubit gates in the basis conversion circuit 9 is reduced.
[0036] [Second Embodiment] Next, a second embodiment will be described. The second embodiment is a quantum computing system that efficiently measures the complete state of a qubit.
[0037] Figure 2 shows an example of the system configuration of the second embodiment. The quantum computing system 30 includes a classical computer 100 and a quantum computer 200. The classical computer 100 is a computer known as a von Neumann type computer. The quantum computer 200 is a non-von Neumann type computer that applies the principles of quantum mechanics. The classical computer 100 is connected to a terminal 29 via a network 20. The terminal 29 is a von Neumann type computer used by the user.
[0038] Terminal 29 transmits a quantum computation request to the quantum computing system 30 in response to user input. The quantum computing system 30, in cooperation with the classical computer 100 and the quantum computer 200, performs the quantum computation in accordance with the acquired quantum computation request. The quantum computing system 30 then transmits the computation result to terminal 29.
[0039] Figure 3 shows an example of the hardware of a classical computer. The classical computer 100 is controlled as a whole by a processor 101. The processor 101 is connected to memory 102 and several peripheral devices via bus 100a. The processor 101 may be a multiprocessor. The processor 101 is, for example, a CPU (Central Processing Unit), an MPU (Micro Processing Unit), or a DSP (Digital Signal Processor). At least some of the functions that the processor 101 implements by executing a program may be implemented by electronic circuits such as an ASIC (Application Specific Integrated Circuit) or a PLD (Programmable Logic Device).
[0040] Memory 102 is used as the main memory of the classical computer 100. Memory 102 temporarily stores at least a portion of the OS (Operating System) program and application programs that are to be executed by the processor 101. Memory 102 also stores various data used for processing by the processor 101. For memory 102, a volatile semiconductor memory device such as RAM (Random Access Memory) is used.
[0041] Peripheral devices connected to bus 100a include a storage device 103, a GPU (Graphics Processing Unit) 104, an input interface 105, an optical drive device 106, a device connection interface 107, a network interface 108, and a communication interface 109.
[0042] The storage device 103 electrically or magnetically writes and reads data from its built-in recording medium. The storage device 103 is used as an auxiliary storage device for a computer. The storage device 103 stores the OS program, application programs, and various data. For example, the storage device 103 can be an HDD (Hard Disk Drive) or an SSD (Solid State Drive).
[0043] The GPU104 is a processing unit that performs image processing and is also called a graphics controller. A monitor 21 is connected to the GPU104. The GPU104 displays images on the screen of the monitor 21 according to instructions from the processor 101. The monitor 21 can be a display device using organic EL (Electro Luminescence) or a liquid crystal display device.
[0044] The input interface 105 is connected to a keyboard 22 and a mouse 23. The input interface 105 transmits signals from the keyboard 22 and mouse 23 to the processor 101. Note that the mouse 23 is just one example of a pointing device; other pointing devices can also be used. Other pointing devices include touch panels, tablets, touchpads, and trackballs.
[0045] The optical drive device 106 uses laser light or the like to read data recorded on the optical disc 24 or write data to the optical disc 24. The optical disc 24 is a portable recording medium on which data is recorded in a way that makes it readable by the reflection of light. Examples of optical discs 24 include DVD (Digital Versatile Disc), DVD-RAM, CD-ROM (Compact Disc Read Only Memory), and CD-R (Recordable) / RW (ReWritable).
[0046] The device connection interface 107 is an interface for connecting peripheral devices to the classical computer 100. For example, a memory device 25 and a memory reader / writer 26 can be connected to the device connection interface 107. The memory device 25 is a recording medium equipped with a communication function with the device connection interface 107. The memory reader / writer 26 is a device that writes data to or reads data from the memory card 27. The memory card 27 is a card-type recording medium.
[0047] The network interface 108 is connected to the network 20. The network interface 108 is connected to other computers (including terminals) not shown via the network 20.
[0048] The communication interface 109 is connected to the quantum computer 200. The communication interface 109 communicates with the quantum computer 200. For example, the communication interface 109 instructs the quantum computer 200 to execute a quantum circuit. The communication interface 109 also obtains the measurement results of expected values from the quantum computer 200.
[0049] The classical computer 100 can realize the processing functions of the second embodiment with the hardware described above. The information processing device 10 shown in the first embodiment can also be realized with the same hardware as the classical computer 100 shown in Figure 3.
[0050] The classical computer 100 implements the processing functions of the second embodiment by executing a program recorded on a computer-readable recording medium, for example. The program describing the processing to be executed by the classical computer 100 can be recorded on various recording media. For example, the program to be executed by the classical computer 100 can be stored in the storage device 103. The processor 101 loads at least a portion of the program in the storage device 103 into the memory 102 and executes the program. Alternatively, the program to be executed by the classical computer 100 can be recorded on a portable recording medium such as an optical disc 24, a memory device 25, or a memory card 27. The program stored on the portable recording medium becomes executable after being installed in the storage device 103, for example, under control from the processor 101. The processor 101 can also directly read and execute the program from the portable recording medium.
[0051] A user of the quantum computing system 30 uses terminal 29 to create a quantum circuit to solve a problem using quantum computing. When the user instructs terminal 29 to execute a quantum computation, terminal 29 sends a request to execute the quantum computation, including the generated quantum circuit, to the quantum computing system 30. The request to execute the quantum computation specifies, for example, the observable to be measured.
[0052] In the quantum computing system 30, the classical computer 100 prompts the quantum computer 200 to perform quantum computations based on quantum circuits in response to requests for quantum computation execution. At this time, the classical computer 100 converts the quantum circuit to be executed into a quantum circuit using executable quantum gates, in accordance with the hardware specifications of the quantum computer 200 (such as native gates corresponding to the qubit device).
[0053] The classical computer 100 calculates the solution to the problem to be solved based on the measurement results of a predetermined observable for the state of the obtained quantum circuit after execution. Here, the measurement of the qubit state by the quantum computer 200 is a measurement in the Z basis (computation basis) ("Z" measurement). Therefore, when using the measurement results in the X basis (Hadamard basis) or Y basis (circular basis), a basis transformation is performed from the X basis or Y basis to the Z basis. If the measurement is performed after the basis transformation, the measurement results of "X" or "Y" in the qubit state before the basis transformation can be obtained.
[0054] Furthermore, basis transformations allow the tensor product of multiple qubit states to be combined into a single qubit state. In other words, basis transformations allow the measurement results of observables for multiple qubit states to be obtained by measuring a single qubit in the Z basis. With appropriate basis transformations, it becomes possible to obtain different observable measurement results from each of the multiple qubits.
[0055] Observables that can be measured simultaneously under the same basis transformation must be commutative with each other. Therefore, the classical computer 100 determines the commutation relationship between the observables to be measured as a preprocessing step for generating a basis transformation circuit that performs the appropriate basis transformation operation.
[0056] Figure 4 shows an example of determining commutation relations. The commutative / anticommutative correspondence table 31 shows whether each combination of operators is commutative or anticommutative. At the intersection of rows and columns, symbols are shown indicating whether the operators shown in the row and the operators shown in the column are commutative or anticommutative. The symbol "+" indicates commutative, and the symbol "-" indicates anticommutative. In the case of commutative, the value does not change even if the order of multiplication is changed, but in the case of anticommutative, the sign is reversed if the order of multiplication is changed.
[0057] For example, in the case of I0Y1X2 and Z0Z1Z2, we determine whether each pair of I0 and Z0, Y1 and Z1, and X2 and Z2 is commutative or anticommutative. In this case, "I0Z0=Z0I0" is commutative, "Y1Z1=-Z1Y1" is anticommutative, and "X2Z2=-Z2X2" is anticommutative. If the number of anticommutative pairs is even (including 0), then the whole is commutative "(I0Y1X2)(Z0Z1Z2)=(Z0Z1Z2)(I0Y1X2)".
[0058] The expectation value of each observable in a set of mutually commutative observables can be calculated from the measurement results of the same quantum circuit; in other words, they can be measured simultaneously. The classical computer 100 performs partitioning of multiple observables to be measured, for example, based on the results of the exchange relationship determination. Partitioning generates multiple groups of observables (partitions) that contain observables that can be measured simultaneously.
[0059] Figure 5 shows an example of partitioning. For example, the group of observables 40, which includes the observable to be measured, is divided into partitions 41 to 43, each containing observables that can be measured simultaneously. Each of partitions 41 to 43 contains multiple observables that can be measured simultaneously. For example, partition 41 contains seven observables 41a to 41g. In Figure 5, mutually interchangeable observables are connected by lines. As shown in Figure 5, each of the observables 41a to 41g contained in a single partition 41 is interchangeable with all other observables within partition 41.
[0060] Furthermore, the Pauli strings for each of the observables 41a to 41g are assigned, in ascending order, the qubit indices of the qubits being measured, starting from the leftmost letter. For example, the Pauli string for observable 41b is "XXYY". This Pauli string is the product of "X" of the qubit with qubit index "1", "X" of the qubit with qubit index "2", "Y" of the qubit with qubit index "3", and "Y" of the qubit with qubit index "4".
[0061] Next, we will explain in detail how to measure the expected value of an observable. An observable whose expected value can be estimated without basis transformation can be represented by the tensor product of only "I" and "Z". "I" is the identity operator and is expressed by the following formula.
[0062]
number
[0063] "Z" is represented by the following formula.
[0064]
number
[0065] The expectation value for an observable "P" for any quantum state ψ is given by the following equation:
[0066]
number
[0067] Here, the expected value of the observable "Z" can be estimated without basis transformation operations. The reason is as follows: The probability of obtaining "0" by measuring a single qubit state "ψ" is expressed by the following formula.
[0068]
number
[0069] Furthermore, the probability of obtaining "1" by measuring the 1-qubit state "ψ" is expressed by the following formula.
[0070]
number
[0071] On the other hand, "Z" can be written as shown on the right-hand side of the following equation.
[0072]
number
[0073] From equation (6), the expected value of "Z" can be expressed by the following equation.
[0074]
number
[0075] The first term on the right-hand side of equation (7) is the probability of obtaining "0" through measurement, and the second term is the probability of obtaining "1" through measurement. Therefore, the expected value of "Z" can be calculated from the probability of measuring "0" and the probability of measuring "1".
[0076] When the observable "P" is represented as the tensor product of "I" and "Z", without performing a basis transformation, the number of occurrences of "1" in the measurement results of the qubit index multiplied by "Z" is counted. Then, the expected value "<ψ|P|ψ>" is calculated by subtracting the probability of having an odd number of qubits with a measurement result of "1" from the probability of having an even number of qubits with a measurement result of "1".
[0077] For example, consider the case where we want to find the expected value of the observable "ZZI" in a state with 3 qubits (q1, q2, q3). In this case, it can be found by subtracting the probability that the measurement result of qubit "q1" and qubit "q2" is either "01" or "00" from the probability that the measurement result is either "01" or "10". The measurement result of qubit "q3", which is affected by "I", does not affect the expected value of the observable "ZZI".
[0078] Thus, the expectation values of all observables, which can be expressed as a tensor product of only "I" and "Z", can be calculated from the measurement results of each qubit without performing a basis transformation. In other words, simultaneous measurement is possible. When there are n qubits (n is a natural number) operated on by a quantum circuit, excluding the trivial observable "III···I", 2 n - One observable can be measured simultaneously.
[0079] Of the observables 41a to 41g shown in Figure 5, observables 41e to 41g are represented only by "I" and "Z", and simultaneous measurement of expected values is possible without basis transformation. In contrast, observables 41a to 41d contain either "X" or "Y".
[0080] "X" can be expressed by the following formula:
[0081]
number
[0082] "Y" is represented by the following formula:
[0083]
number
[0084] If the observable "P" contains "X" or "Y" other than "I" and "Z", a basis transformation operation is performed before measurement. In this case, by an appropriate basis transformation operation "B", "P" is transformed into "P'" represented as a tensor product of "I" and "Z". The transformation to "P'" is expressed by the following equation.
[0085]
Number
[0086] Figure 6 is a diagram showing an example of a basis transformation operation. Let the observables included as elements in partition 44 be "P1, P2, ···, P m "(m is a natural number). The transformation of these observables by the basis transformation operation "B" can be expressed as "B(P) = BPB † ". Let the observables after the transformation of "P1, P2, ···, P m " (Pauli strings) be "P'1, P'2, ···, P' m ". At this time, the basis transformation operation "B" is determined so that all of the transformed observables "P'1, P'2, ···, P' m " can be represented as a tensor product of only "I" and "Z".
[0087] By causing the quantum computer 200 to execute a basis transformation circuit corresponding to the basis transformation operation, it is possible to measure the expected value of the observable after the basis transformation. Figure 7 is a diagram showing a first example of a basis transformation circuit corresponding to the basis transformation operation. In the example of Figure 7, the number of qubits to be measured is "4". In this case, the number of observables represented as a tensor product of only "I" and "Z" is "(2 4 - 1)" (excluding "IIII" which is trivial).
[0088] The basis transformation operation "B1" transforms the observables "P1, P2, P3, P4, P5, P6, P7" into observables "P'1, P'2, P'3, P'4, P'5, P'6, P'7". For example, the observable "P1" of "XXXX" is transformed into the observable "P'1" of "ZIII". The observable "P2" of "XXYY" is transformed into the observable "P'2" of "IZII". The observable "P3" of "XYXY" is transformed into the observable "P'3" of "IIZI". The observable "P4" of "YXXY" is transformed into the observable "P'4" of "IIIZ". The observable "P5" of "IIZZ" is transformed into the observable "P'5" of "ZZII". The observable "P6" of "IZIZ" is converted to the observable "P'6" of "ZIZI". The observable "P7" of "ZIIZ" is converted to the observable "P'7" of "ZIIZ".
[0089] In this case, the expected values of each of the observables "P'1, P'2, P'3, P'4, P'5, P'6, P'7" after the basis transformation operation "B1" become the expected values of the corresponding observables "P1, P2, P3, P4, P5, P6, P7".
[0090] The Pauli strings of the transformed observables "P'1, P'2, P'3, P'4" corresponding to the observables "P1, P2, P3, P4" contain only one "Z" and all the others are "I". The observables "P'1, P'2, P'3, P'4" which contain only one "Z" can have their expected values calculated using the measurement results of one qubit. Therefore, by repeatedly performing measurements on qubit indices "1" to "4", the expected values of observables "P1, P2, P3, P4" can be obtained based on the measurement results. Furthermore, the expected values of observables "P5, P6, P7" can be calculated based on the measurement results of qubits "1" to "4".
[0091] The classical computer 100 then generates a basis transform circuit 32 corresponding to the basis transform operation "B1". By executing the basis transform circuit 32 after the quantum circuit used to solve the problem to be solved, the measurement result of the qubit with qubit index "1" becomes the observable "XXXX". The measurement result of the qubit with qubit index "2" becomes the observable "XXYY". The measurement result of the qubit with qubit index "3" becomes the observable "XYXY". The measurement result of the qubit with qubit index "4" becomes the observable "YXXY". The number of 2-qubit gates in the basis transform circuit 32 is "11".
[0092] In this case, the number of 2-qubit gates used in the basis transformation depends on which Pauli string observable is associated with the observable whose expected value can be obtained by measuring one qubit after the basis transformation operation.
[0093] Figure 8 shows a second example of a basis transform circuit corresponding to a basis transform operation. Figure 8 shows an example of performing a basis transform operation "B2" which is different from the basis transform operation "B1" in Figure 7. The basis transformation operation "B2" transforms the observable "P1" of "XXXX" into the observable "P'1" of "ZIII". The observable "P2" of "XXYY" is transformed into the observable "P'2" of "ZIZI". The observable "P3" of "XYXY" is transformed into the observable "P'3" of "ZZII". The observable "P4" of "YXXY" is transformed into the observable "P'4" of "ZIIZ". The observable "P5" of "IIZZ" is transformed into the observable "P'5" of "IIZI". The observable "P6" of "IZIZ" is transformed into the observable "P'6" of "IZII". The observable "P7" of "ZIIZ" is transformed into the observable "P'7" of "IIIZ".
[0094] The Pauli strings of the transformed observables "P'1, P'5, P'6, P'7" corresponding to the observables "P1, P5, P6, P7" contain only one "Z" and all the others are "I". Therefore, by repeatedly performing measurements on the qubits with qubit indices "1" to "4", the expected values of the observables "P1, P5, P6, P7" can be obtained based on the measurement results. Furthermore, the expected values of the observables "P2, P3, P4" can be calculated based on the measurement results of the qubits with qubit indices "1" to "4".
[0095] The classical computer 100 then generates a basis transform circuit 33 corresponding to the basis transform operation "B2". By executing the basis transform circuit 33 after the quantum circuit used to solve the problem to be solved, the measurement result of the qubit with qubit index "1" becomes the observable "XXXX". The measurement result of the qubit with qubit index "2" becomes the observable "IZIZ". The measurement result of the qubit with qubit index "3" becomes the observable "IIZZ". The measurement result of the qubit with qubit index "4" becomes the observable "ZIIZ". The number of 2-qubit gates in the basis transform circuit 33 is "3".
[0096] As shown in Figures 7 and 8, the number of 2-qubit gates included in basis conversion circuits 32 and 33 differs depending on which tensor product observables "P'1, P'2, P'3, P'4, P'5, P'6, P'7" are associated with each of the observables "P1, P2, P3, P4, P5, P6, P7".
[0097] Next, we will explain the four basic operations in basis transformation operations. Figure 9 shows an example of a basis transformation operation. The basis transformation operations include S operation 34, H operation 35, CX operation 36, and CZ operation 37.
[0098] S-operation 34 is the operation corresponding to a π / 2 phase-shift quantum gate (S-gate). When S-operation 34 is performed, the "Y" of the target qubit is converted to "X", and "X" is converted to "Y". "Z" and "I" are not converted when S-operation 34 is performed.
[0099] H operation 35 is the operation corresponding to the Hadamard gate (H gate). When H operation 35 is performed, the "Z" of the target qubit is converted to "X", and "X" is converted to "Z". "Y" and "I" are not converted when H operation 35 is performed.
[0100] CX operation 36 is the operation corresponding to the CX gate (also called the CNOT gate). The character corresponding to the qubit being operated on in the Pauli string changes when CX operation 36 is performed in the following cases:
[0101] If the control qubit for CX operation 36 is "I" and the target qubit is "Y", the control qubit is converted to "Z". If the control qubit for CX operation 36 is "I" and the target qubit is "Z", the control qubit is converted to "Z".
[0102] If the control qubit of CX operation 36 is "X" and the target qubit is "I", the target qubit is converted to "X". If the control qubit of CX operation 36 is "X" and the target qubit is "X", the target qubit is converted to "I". If the control qubit of CX operation 36 is "X" and the target qubit is "Y", the control qubit is converted to "Y" and the target qubit is converted to "Z". If the control qubit of CX operation 36 is "X" and the target qubit is "Z", the control qubit is converted to "Y" and the target qubit is converted to "Y".
[0103] If the control qubit for CX operation 36 is "Y" and the target qubit is "I", the target qubit is converted to "X". If the control qubit for CX operation 36 is "Y" and the target qubit is "X", the target qubit is converted to "I". If the control qubit for CX operation 36 is "Y" and the target qubit is "Y", the control qubit is converted to "X" and the target qubit is converted to "Z". If the control qubit for CX operation 36 is "Y" and the target qubit is "Z", the control qubit is converted to "X" and the target qubit is converted to "Y".
[0104] If the control qubit for CX operation 36 is "Z" and the target qubit is "Y", the control qubit is converted to "I".
[0105] CZ operation 37 is the operation corresponding to the CZ gate. The character corresponding to the qubit being operated on in the Pauli string changes when CZ operation 37 is performed in the following cases:
[0106] If the control qubit for CZ operation 37 is "I" and the target qubit is "X", the control qubit is converted to "Z". If the control qubit for CZ operation 37 is "I" and the target qubit is "Y", the control qubit is converted to "Z". If the control qubit for CZ operation 37 is "I" and the target qubit is "Z", the control qubit is converted to "Z".
[0107] If the control qubit of CZ operation 37 is "X" and the target qubit is "I", the target qubit is converted to "Z". If the control qubit of CZ operation 37 is "X" and the target qubit is "X", the control qubit is converted to "Y", and the target qubit is converted to "Y". If the control qubit of CZ operation 37 is "X" and the target qubit is "Y", the control qubit is converted to "Y", and the target qubit is converted to "X". If the control qubit of CZ operation 37 is "X" and the target qubit is "Z", the target qubit is converted to "I".
[0108] If the control qubit of CZ operation 37 is "Y" and the target qubit is "I", the target qubit is converted to "Z". If the control qubit of CZ operation 37 is "Y" and the target qubit is "X", the control qubit is converted to "X" and the target qubit is converted to "Y". If the control qubit of CZ operation 37 is "Y" and the target qubit is "Y", the control qubit is converted to "X" and the target qubit is converted to "X". If the control qubit of CZ operation 37 is "Y" and the target qubit is "Z", the target qubit is converted to "I".
[0109] If the control qubit for CZ operation 37 is "Z" and the target qubit is "X", the control qubit is converted to "I". If the control qubit for CZ operation 37 is "Z" and the target qubit is "Y", the control qubit is converted to "I".
[0110] Of the four operations, only the 2-qubit operations (CX operation, CZ operation) can convert to "I". There are operations that directly convert "X" or "Z" to "I". There are only operations that convert "Y" to "X" or "Z". "Y" can be converted to "I" by first converting to "X" or "Z".
[0111] By combining these four operations, it is possible to generate a basis transformation operation that converts multiple simultaneously measurable observables into an observable of a Pauli string consisting only of "I" and "Z". By arranging the quantum gates corresponding to each of the fundamental operations included in the generated basis transformation operation, a basis transformation circuit is created to realize that basis transformation operation.
[0112] Figure 10 shows a first example of the transformation of a Pauli string representing an observable by a basis transform circuit. Figure 10 shows an example of a basis transform operation that transforms the Pauli string of the observable "XXXX,XXYY,XYXY,YXXY" in partition 41 to "ZIII,IZII,IIZI,IIIZ". Such a basis transform operation is realized by the basis transform circuit 32.
[0113] Figure 11 shows a second example of the transformation of a Pauli string representing an observable by a basis transform circuit. Figure 10 shows an example of a basis transform operation that transforms the Pauli string of the observable "XXXX,IZIZ,IIZZ,ZIIZ" in partition 41 to "ZIII,IZII,IIZI,IIIZ". Such a basis transform operation is realized by a basis transform circuit 33.
[0114] The basis conversion circuits 32 and 33 shown in Figures 10 and 11 are realized using H gates, CX gates, and CZ gates. If S gates are also available in addition to these quantum gates, an appropriate basis conversion circuit can be generated regardless of the Pauli string of the observable before the conversion.
[0115] Many of the gate operations between basis conversion circuit 32 and basis conversion circuit 33 are gate operations to convert characters other than "I" in the Pauli string of the observable before the basis conversion to the character "I". Therefore, if the number of characters other than "I" in the observable before the basis conversion is small, the number of 2-qubit gate operations used for the basis conversion will be small.
[0116] For example, in the basis transformation shown in Figure 10, the Pauli strings of the four observables before the basis transformation do not contain "I". On the other hand, in the basis transformation shown in Figure 11, the four observables before the basis transformation contain a total of six "I"s. For qubits that are "I" before the basis transformation, the operation to convert them to "I" is not required. As a result, the basis transformation circuit 33 shown in Figure 11 uses fewer 2-qubit gates. In other words, by appropriately selecting observables that can be simultaneously measured to be transformed into "ZIII, IZII, IIZI, IIIZ" by the basis transformation, the depth of the basis transformation circuit can be shortened.
[0117] Below, we define the generator "G" as the set of observables such that the expected value can be obtained by measuring one qubit after a basis transformation. Figure 12 shows an example of how to select observables to include in generator "G". Classical computer 100 has elements {P1, P2, P3, ...} in partition "P".
[0118] Classical computer 100 generates a set of observables "Q={Q1,Q2,Q3,...}" that can be represented by the product of observables within partition "P". The product of observables is the product of each Pauli character (X,Y,Z,I) assigned to the same qubit index. The product of the characters "X,Y,Z" and "I" remains the original characters "X,Y,Z". The product of identical characters is "I". The product of "X" and "Z" is "Y". The product of "X" and "Y" is "Z". The product of "Y" and "Z" is "X". Based on equations (6), (8), and (9), XZ=-iY, XY=iZ, and YZ=iX, but for convenience, we will not consider the constant multiple term here.
[0119] The maximum number of elements in set "Q" is 2 nThe value is -1 (where n is the number of qubits). If the number of elements in set "Q" is less than the maximum, the classical computer 100 increases the number of elements in set "Q" by adding observables that can be measured simultaneously with the observables included in set "Q".
[0120] Next, the classical computer 100 generates an observable generator "G" from the set "Q" using the following procedure. (Procedure 1) The classical computer 100 selects one observable from the set "Q" according to predetermined selection criteria and adds that observable as element "G1" to "G". (Step 2) The classical computer 100 removes the observable corresponding to element "G1" from the set "Q". (Step 3) The classical computer 100 selects one observable from the set "Q" according to predetermined selection criteria and adds that observable to "G" as element "G2". (Step 4) The classical computer 100 removes from the set "Q" the observable corresponding to element "G2", and the observable in the set "Q" that can be expressed as the product of element "G2" and other elements in "G".
[0121] The classical computer 100 then repeats steps 3 and 4 until the number of elements in set "Q" becomes "0". Here, the predetermined selection criteria in steps 1 and 3 include, for example, the element "Q" of the set "Q". i The index value "v" is set for each of the following (i is a natural number). i The index value "v" is used. i " is "v i = 'X' character count + 'Z' character count + ('Y' character count) × 2)". Classical computer 100, in steps 1 and 3, uses the index value "v i Select the element with the smallest value.
[0122] Index value "v iIn the calculation of ", the reason why only the "number of characters in 'Y'" is multiplied by a factor of 2 is that when converting "Y" to "I" by a basis transformation, it must first go through "X" or "Z", and if there are many "Y"s, the number of 2-qubit gates also increases.
[0123] As described above, a generator "G" containing the selected elements is generated. Then the classical computer 100 processes the elements "G1, G2, ..., G" of the generator "G". n " to "G'1, G'2, ..., G' n Determine the basis transformation operation to convert to "G'1, G'2, ..., G' n The string "" is an observable in which only the character corresponding to one qubit is "Z" and the other characters are "I". Furthermore, the classical computer 100 generates a basis change circuit 38 to cause the quantum computer 200 to execute the basis change operation "B".
[0124] Figure 13 shows an example of the generation process of generator "G". It assumes the simultaneous measurement of observables contained in partition "P={XXXX,XXYY,XYXY,YXXY}". Classical computer 100 generates a set "Q" containing the observables contained in partition "P" and observables that can be represented by the tensor product of those observables. The set "Q" has a maximum number of elements "15" (2 4 (-1) observable is included.
[0125] Classical computer 100 has an index value "v" for each observable in the set "Q". i The value of " is calculated. In the example in Figure 13, the six observables "IIZZ,IZIZ,ZIIZ,ZZII,IZZI,ZIZI" are calculated as "v i The minimum value is 2.
[0126] Classical computer 100 first selects one of "IIZZ,IZIZ,ZIIZ,ZZII,IZZI,ZIZI". In the example in Figure 13, "ZIIZ" is selected. Classical computer 100 adds the selected "ZIIZ" to generator "G" and removes it from set "Q".
[0127] Next, the classical computer 100 selects one of "IIZZ, IZIZ, ZZII, IZZI, ZIZI". In the example in Figure 13, "IZIZ" is selected. The classical computer 100 adds the selected "IZIZ" to the generator "G" and removes it from the set "Q". The classical computer 100 also removes "ZZII", which is the product of "ZIIZ" (which was already included in the generator "G") and the newly added "IZIZ", from the set "Q".
[0128] Next, the classical computer 100 selects one of "IIZZ, ZZII, IZZI, ZIZI". In the example in Figure 13, "IIZZ" is selected. The classical computer 100 adds the selected "IIZZ" to the generator "G" and removes it from the set "Q". The classical computer 100 also removes "ZIZI, IZZI", which is the product of the newly added "IIZZ" and the already included "ZIIZ, IZIZ" in the generator "G", from the set "Q". Furthermore, the classical computer 100 removes "ZZZZ", which is the product of the already included "ZIIZ, IZIZ" product "ZZII" and the newly added "IIZZ", from the set "Q".
[0129] This results in the index value "v i All observables with index value "v = 2" are removed from the set "Q". Therefore, classical computer 100, of the remaining observables in the set "Q", i " is the minimum "v iThe classical computer 100 selects the observable "XXXX" with the value "=4". The classical computer 100 adds the selected "XXXX" to the generator "G" and removes it from the set "Q". Furthermore, the classical computer 100 removes from the set "Q" any observables that could be generated by the product of "XXXX" with one or more observables already included in the generator "G". As a result, the set "Q" becomes an empty set.
[0130] The classical computer 100 determines a basis conversion procedure based on the generator "G" it generates, and then generates a basis conversion circuit corresponding to that procedure. Figure 14 shows an example of a method for generating a basis conversion circuit. Classical computer 100 represents the group of observables contained in the generator "G={XXXX,IZIZ,IIZZ,ZIIZ}" using two binary matrices, X matrix 51 and Z matrix 52. X matrix 51 and Z matrix 52 are n × n (where n is the number of qubits) square matrices. Each column corresponds to a qubit index assigned to a qubit. Each row corresponds to an observable index that identifies the observable contained in the generator "G".
[0131] In the example in Figure 14, the observable index for "XXXX" is "1" (1st row). The observable index for "IZIZ" is "2" (2nd row). The observable index for "IIZZ" is "3" (3rd row). The observable index for "ZIIZ" is "4" (4th row).
[0132] Matrix X 51 shows the position of "X" in the Pauli string for each observable. Matrix Z 52 shows the position of "Z" in the Pauli string for each observable. Note that "Y" is treated as having both "X" and "Z" present.
[0133] For example, the elements of matrix X 51 are "1" if the letter of the qubit index in the column of the observable corresponding to the row of that element is "X" or "Y", and "0" otherwise. The elements of matrix Z 52 are "1" if the letter of the qubit index in the column of the observable corresponding to the row of that element is "Z" or "Y", and "0" otherwise.
[0134] The classical computer 100 calculates matrix operations 53a, 53b, ..., 53n to transform the X matrix 51 and the Z matrix 52 so that they represent "ZIII, IZII, IIZI, IIIZ". The resulting sequence of matrix operations 53a, 53b, ..., 53n becomes the basis transformation procedure 53. The classical computer 100 then generates a basis transformation circuit 54 in which quantum gates 54a, 54b, ..., 54n corresponding to each of the matrix operations 53a, 53b, ..., 53n included in the basis transformation procedure 53 are arranged.
[0135] The matrix operations used to generate the basis transformation procedure will be explained in detail below, with reference to Figures 15 to 19. Figure 15 shows an example of a basis change operation (1 / 5). First, the classical computer 100 swaps columns of matrix X 51 and matrix Z 52 for each qubit index so that the rank of matrix X 51 matches the number of elements in generator "G". In the example in Figure 15, the number of elements in generator "G" is "4". Therefore, the classical computer 100 swaps columns so that the rank of matrix X 51 is "4". For example, the classical computer 100 swaps columns of matrix X 51 and matrix Z 52 for the columns corresponding to qubit indices "2, 3, 4".
[0136] Matrix operations that swap columns correspond to the H operations, which are fundamental operations in basis transformations. Therefore, the classical computer 100 places H gates 55a to 55c on the qubits with qubit indices "2, 3, and 4" of the basis transformation circuit 55.
[0137] Figure 16 shows an example of a basis transformation operation (2 / 5). The classical computer 100 manipulates the matrix X 51 so that each row contains exactly one element that is "1". Specifically, the classical computer 100 selects two qubit indices. The classical computer 100 designates one of the selected qubit indices as "index A" and the other as "index B". In the example in Figure 16, qubit index "2" is "index A" and qubit index "4" is "index B".
[0138] Classical computer 100 calculates the remainder (mod 2) when it adds the column element at "index A" to the column element at "index B" of matrix X 51 and divides by 2. Classical computer 100 updates the column element at "index B" with the value of the remainder.
[0139] Classical computer 100 calculates the remainder (mod 2) when it adds the column element at index B of matrix Z 52 to the column element at index A and divides by 2. Classical computer 100 updates the column element at index A with the value of the remainder.
[0140] The operation shown in Figure 16 corresponds to the CX operation, one of the basic operations of basis conversion. Therefore, the classical computer 100 places a CX gate 55d in the basis conversion circuit 55, with the qubit at qubit index "2" as the control qubit and the qubit at qubit index "4" as the target qubit.
[0141] As shown in Figure 16, the CX operation reduces the number of elements in the second row of matrix X 51 from two to one. However, the third row of matrix X 51 still has two elements that are "1". Therefore, the matrix operation corresponding to the CX operation is repeated in each row of matrix X 51 until there is only one element that is "1".
[0142] Figure 17 shows an example of a basis change operation (3 / 5). The classical computer 100 uses the CX operation to select two qubit indices such that each row in the X matrix 51 contains exactly one element that is "1". In the example in Figure 17, the classical computer 100 selects qubit index "3" as "index A" and qubit index "4" as "index B".
[0143] Classical computer 100 calculates the remainder (mod 2) when it adds the column element at "index A" to the column element at "index B" of matrix X 51 and divides by 2. Classical computer 100 updates the column element at "index B" with the value of the remainder.
[0144] Classical computer 100 calculates the remainder (mod 2) when it adds the column element at index B of matrix Z 52 to the column element at index A and divides by 2. Classical computer 100 updates the column element at index A with the value of the remainder.
[0145] Then, the classical computer 100 places a CX gate 55e in the basis conversion circuit 55, with the qubit at qubit index "3" as the control qubit and the qubit at qubit index "4" as the target qubit.
[0146] This matrix operation satisfies the condition that each row of matrix X 51 contains exactly one element that is "1". Figure 18 shows an example of a basis transformation operation (4 / 5). The classical computer 100 performs a matrix operation so that the Z matrix 52 becomes a zero matrix. Specifically, the classical computer 100 selects two qubit indices. The classical computer 100 designates one of the selected qubit indices as "index A" and the other as "index B". In the example in Figure 18, qubit index "1" is "index A" and qubit index "4" is "index B".
[0147] Classical computer 100 calculates the remainder (mod 2) when it adds the column element at index B of matrix X 51 to the column element at index A of matrix Z 52 and divides by 2. Classical computer 100 updates the column element at index A of matrix Z 52 with the value of the remainder.
[0148] Classical computer 100 calculates the remainder (mod 2) when it adds the column element at index B of matrix Z 52 to the column element at index A of matrix X 51 and divides by 2. Classical computer 100 updates the column element at index B of matrix Z 52 with the value of the remainder.
[0149] The operation shown in Figure 18 corresponds to the CZ operation, one of the basic operations of the basis transformation. Therefore, the classical computer 100 places a CZ gate 55f that operates on the qubit with qubit index "1" and the qubit with qubit index "4" in the basis transformation circuit 55.
[0150] This CZ operation satisfies the condition that the Z matrix 52 is a zero matrix. Figure 19 shows an example of a basis transformation operation (5 / 5). The classical computer 100 swaps the X matrix 51 and the Z matrix 52 (exchanges all columns). This matrix operation corresponds to the H operation, a fundamental operation of basis transformations. Therefore, the classical computer 100 adds H gates 55g to 55j to all qubits of the basis transformation circuit 55.
[0151] The observable group represented by matrix X 51 and matrix Z 52 after the matrix permutation operation is "ZIII, IZII, IIZI, IIIZ". Therefore, the matrix operation is complete.
[0152] In this way, a basis transform circuit 55 is generated that can obtain the expected value of each observable contained in the generated generator "G" by measuring one qubit. Since such a basis transform circuit 55 has a small number of 2-qubit gates, performing quantum computation using the basis transform circuit 55 can reduce errors during the execution of the quantum circuit.
[0153] Figure 20 shows an example of the functions that a classical computer has to perform quantum computation. The classical computer 100 has a quantum computation request receiving unit 110, a partitioning unit 120, a quantum circuit generation unit 130, and a quantum computation execution control unit 140.
[0154] The quantum computation request receiving unit 110 receives quantum computation requests from the terminal 29. Upon receiving a quantum computation request, the quantum computation request receiving unit 110 instructs the partitioning unit 120 to partition the observable to be measured. Upon receiving the quantum computation result from the quantum computation execution control unit 140, the quantum computation request receiving unit 110 transmits the calculation result to the terminal 29.
[0155] The partitioning unit 120 performs observable partitioning. The partitioning unit 120 transmits information indicating the partitions created by the partitioning to the quantum circuit generation unit 130.
[0156] The quantum circuit generation unit 130 generates a quantum circuit for solving the problem to be solved. For example, the quantum circuit generation unit 130 generates a quantum circuit that performs quantum computation according to the problem, and a basis transform circuit for measuring the observable to be measured output from that quantum circuit. For example, the quantum circuit generation unit 130 obtains information on one or more partitions from the partitioning unit 120 and generates a basis transform circuit for each partition. The quantum circuit generation unit 130 transmits the quantum circuit with the added basis transform circuit to the quantum computation execution control unit 140.
[0157] The quantum computation execution control unit 140 instructs the quantum computer 200 to execute a quantum circuit. When the quantum computation execution control unit 140 obtains measurement results from the quantum computer 200, it calculates the solution to the problem to be solved based on the measurement results and transmits it to the quantum computation request reception unit 110.
[0158] Next, we will explain in detail the procedure for quantum computing processing using classical computer 100. Figure 21 is a flowchart showing an example of a quantum computing procedure. The process shown in Figure 21 will be explained below according to the step numbers.
[0159] [Step S101] When the quantum computation request receiving unit 110 receives a quantum computation request from the terminal 29, it enumerates the elements (observables) of the group of observables to be measured by quantum computation. The quantum computation request receiving unit 110 then instructs the partitioning unit 120 to partition the group of observables.
[0160] [Step S102] The partitioning unit 120 determines the exchange relationships between the observables included in the group of observables. [Step S103] The partitioning unit 120 generates one or more partitions that collect observables that can be measured simultaneously, based on the exchange relationships between the observables.
[0161] [Step S104] The quantum circuit generation unit 130 selects one of the unselected partitions from among the partitions generated by the partitioning unit 120. [Step S105] The quantum circuit generation unit 130 generates a quantum circuit by adding a basis transform circuit for simultaneously measuring observables contained in the selected partition to the quantum circuit for calculating the solution to the problem to be solved. Details of the quantum circuit generation process will be described later (see Figure 22).
[0162] [Step S106] The quantum computation execution control unit 140 instructs the quantum computer 200 to perform a quantum computation based on the generated quantum circuit. The quantum computer 200 performs the quantum computation according to the instruction.
[0163] [Step S107] The quantum computation execution control unit 140 acquires the measurement results from the quantum computer 200 and records the measurement results in the memory 102 or storage device 103. [Step S108] The quantum circuit generation unit 130 determines whether or not there are any unselected partitions. If there are any unselected partitions, the quantum circuit generation unit 130 proceeds to step S104. If all generated partitions have been selected, the quantum circuit generation unit 130 proceeds to step S109.
[0164] [Step S109] The quantum computation execution control unit 140 calculates the expected values of all observables used to calculate the solution to the problem to be solved, based on the measurement results obtained by executing the quantum circuits generated corresponding to each partition.
[0165] [Step S110] The quantum computation execution control unit 140 calculates the solution to the problem to be solved based on the expected value of the observable and outputs the solution. The quantum computation request reception unit 110 transmits the output solution to the terminal 29.
[0166] In this way, quantum computations are performed in response to quantum computation requests. Next, the quantum circuit generation process will be explained in detail. Figure 22 is a flowchart showing an example of the procedure for generating a quantum circuit. The process shown in Figure 22 will be explained below according to the step numbers.
[0167] [Step S201] The quantum circuit generation unit 130 acquires a quantum circuit for quantum computation corresponding to the problem to be solved. For example, if the quantum computation request from terminal 29 includes a quantum circuit, the quantum circuit generation unit 130 acquires that quantum circuit. Also, if a quantum circuit corresponding to the problem is already prepared in advance in the storage device 103 or the like, the quantum circuit generation unit 130 acquires that quantum circuit.
[0168] Furthermore, if the acquired quantum circuit contains quantum gates that cannot be executed by the quantum computer 200, the quantum circuit generation unit 130 converts those quantum gates into native gates that can be executed by the quantum computer 200. The quantum circuit generation unit 130 also inserts a SWAP gate so that gate operations of two-qubit gates can be performed, according to the connection relationships (connection topology) of the qubits of the quantum computer 200.
[0169] [Step S202] The quantum circuit generation unit 130 generates a generator "G" corresponding to the selected partition. Details of the generator generation process will be described later (see Figure 23). [Step S203] The quantum circuit generation unit 130 determines the basis transformation operation based on the generated generator "G". Details of the basis transformation operation determination process will be described later (see Figure 27).
[0170] [Step S204] The quantum circuit generation unit 130 adds a basis transformation circuit to the quantum circuit acquired in step S201, which performs a basis transformation according to the basis transformation procedure generated in step S203.
[0171] By performing quantum computations based on the quantum circuits generated in this way, quantum computations with fewer errors can be realized. Next, we will explain in detail the generation process of generator "G".
[0172] Figure 23 is a flowchart showing an example of the generator generation process. The process shown in Figure 23 will be explained below according to the step numbers. [Step S211] The quantum circuit generation unit 130 acquires the selected partition "P={P1,P2,P3,...}".
[0173] [Step S212] The quantum circuit generation unit 130 creates a set of observables "Q={Q1,Q2,···}" which consists of all the elements of partition "P" and observables that are represented by the product of the elements within partition "P".
[0174] [Step S213] The quantum circuit generation unit 130 generates a set "Q" with 2 elements. n It determines whether there is -1 (where n is the number of qubits used for quantum computation). The quantum circuit generation unit 130 determines whether the number of elements in the set "Q" is 2 n -If there is 1, the process proceeds to step S215. Also, the quantum circuit generation unit 130 checks if the number of elements in the set "Q" is 2 n If the number is less than one, proceed to step S214.
[0175] [Step S214] The quantum circuit generation unit 130 performs an element addition process on the set "Q". Details of the element addition process on Q will be described later (see Figures 25 and 26). [Step S215] The quantum circuit generation unit 130 generates each element of the set "Q" i Regarding the index value "v i For example, the quantum circuit generation unit 130 calculates "Q". i The number of characters in "X, Y, Z" is "n i,x ,n i,y ,n i,z When this is done, the index value "v i " is a linear combination "v i =c x n i,x +c y n i,y +c z n i,z The calculation is performed using "". Linear sums are also called weighted sums or weighted sums. x ,c y ,c z These are all positive real numbers. For example, "c x =c z =1,cy = 2
[0176] [Step S216] The quantum circuit generation unit 130 initializes a generator "G" that represents an observable group for which the expected value is calculated by measuring one qubit (G = empty set). [Step S217] The quantum circuit generation unit 130 initializes the variable k, which represents the element number of the observable included in the generator "G", to "1" (k=1).
[0177] [Step S218] The quantum circuit generation unit 130 generates an index value "v i The smallest element is "Q i Select "Q". Then the quantum circuit generation unit 130 generates the selected element "Q i The k-th element "G k It is added to the generator "G" as "".
[0178] [Step S219] The quantum circuit generation unit 130 generates an element "G k The observable corresponding to "" is removed from the set "Q". The quantum circuit generation unit 130 also removes the element "G k " and the element "G1, G2, ..., G k-1 Remove any observable that can be expressed as a product of any of the above from the set "Q".
[0179] [Step S220] The quantum circuit generation unit 130 determines whether the set "Q" has become an empty set. If the set "Q" has become an empty set, the quantum circuit generation unit 130 terminates the generator generation process. If there are elements remaining in the set "Q", the quantum circuit generation unit 130 proceeds to step S221.
[0180] [Step S221] The quantum circuit generation unit 130 adds "1" to the variable k (k=k+1). Then the quantum circuit generation unit 130 proceeds to step S218. In this way, a generator "G" is generated that includes an observable capable of minimizing the number of 2 qubits in the basis conversion circuit.
[0181] Next, we will explain in detail the process of adding elements to Q. Figure 24 shows an example of adding elements to the set "Q". For example, suppose the number of qubits is "n=8" and partition "P" contains observables as shown in Figure 24. In this case, if we generate the set "Q" from only the elements of partition "P", the number of elements in the set "Q" will be 127. This is the maximum number of elements in the set "Q" "2 8 Less than -1.
[0182] The quantum circuit generator 130 first generates a set "P'" of copies of partition "P". Next, the quantum circuit generator 130 searches for a Pauli string with two or fewer characters other than "I" that all elements of partition "P" are commutative, and adds it to "P'". Then, the quantum circuit generator 130 creates a set of observables "Q'={Q'1,Q'2,···}" which consists of all the elements of partition "P'" and observables that can be represented by the product of the elements within partition "P'". In the example in Figure 24, the set "Q'" has 255 elements, which is the maximum number of elements in the set "Q".
[0183] The quantum circuit generator 130 takes all elements of set "Q'" and makes them elements of set "Q". As a result, the number of elements in set "Q" becomes 2 n -1 item. Figure 25 is a flowchart (1 / 2) showing an example of the procedure for adding elements to Q. The process shown in Figure 25 will be explained below according to the step numbers.
[0184] [Step S231] The quantum circuit generation unit 130 acquires partitions "P={P1,P2,···}" and a set "Q". [Step S232] The quantum circuit generation unit 130 generates a set of duplicates of partition "P" called "P'" (P'←P).
[0185] [Step S233] The quantum circuit generation unit 130 initializes the set of qubit indices "q" used for decision-making in the branching process of steps S242 and S244 (see Figure 26) to an empty set.
[0186] [Step S234] The quantum circuit generation unit 130 executes the processes in steps S235 to S237 for each of the qubit indices "q1=1,...,n" of the qubits used in the quantum circuit.
[0187] [Step S235] The quantum circuit generation unit 130 determines whether the condition is met that there are two types of Pauli strings for the qubit index "q1" in each element of partition "P", and one of them is "I". If the condition is met, the quantum circuit generation unit 130 proceeds to step S236. If the condition is not met, the quantum circuit generation unit 130 proceeds to step S238.
[0188] [Step S236] The quantum circuit generation unit 130 adds the qubit index "q1" to the set "q". [Step S237] The quantum circuit generation unit 130 generates a Pauli string from the two types of Pauli strings for the qubit index "q1" in each element of partition "P" that is not "I" and is "p q,1 The Pauli letter for the qubit index "q1" is "p q,1 Add the observable "P'" to the set "P'", where the other Pauli letter is "I".
[0189] [Step S238] For each of the qubit indices "q1=1,...,n" of the qubits used in the quantum circuit, the quantum circuit generation unit 130 proceeds to step S241 (see Figure 26) after completing the processing in steps S235 to S237.
[0190] Figure 26 is a flowchart (2 / 2) showing an example of the procedure for adding elements to Q. The process shown in Figure 26 will be explained below according to the step numbers. [Step S241] The quantum circuit generation unit 130 executes the processes in steps S242 to S250 for each of the qubit indices "q1=1,...,n-1" of the qubits used in the quantum circuit.
[0191] [Step S242] The quantum circuit generation unit 130 determines whether the qubit index "q1" to be processed is included in the set "q". If "q1" is included in the set "q", the quantum circuit generation unit 130 proceeds to step S251. If "q1" is not included in the set "q", the quantum circuit generation unit 130 proceeds to step S243.
[0192] [Step S243] The quantum circuit generation unit 130 executes the processes in steps S244 to S249 for each of the qubit indices "q2 = q1 + 1, ..., n" that have a value greater than "q1".
[0193] [Step S244] The quantum circuit generation unit 130 determines whether the qubit index "q2" to be processed is included in the set "q". If "q2" is included in the set "q", the quantum circuit generation unit 130 proceeds to step S250. If "q2" is not included in the set "q", the quantum circuit generation unit 130 proceeds to step S245.
[0194] [Step S245] The quantum circuit generation unit 130 performs the processes in steps S246 to S248 for all combinations of elements between the first Pauli letter sequence "s1=X,Y,Z" and the second Pauli letter sequence "s2=X,Y,Z".
[0195] [Step S246] The quantum circuit generation unit 130 creates an observable in which the Pauli letter of qubit index "q1" is "s1", the Pauli letter of qubit index "q2" is "s2", and the Pauli letter of all other qubits is "I".
[0196] [Step S247] The quantum circuit generation unit 130 determines whether the observable created in step S246 is commutative with all elements of partition "P". If it is commutative with all elements, the quantum circuit generation unit 130 proceeds to step S248. If it is not commutative with at least some elements, the quantum circuit generation unit 130 proceeds to step S249.
[0197] [Step S248] The quantum circuit generation unit 130 adds the observable created in step S246 to "P'". [Step S249] The quantum circuit generation unit 130 proceeds to step S250 if it has completed the processing in steps S246 to S248 for all combinations of elements of the first Pauli letter sequence "s1=X,Y,Z" and the second Pauli letter sequence "s2=X,Y,Z".
[0198] [Step S250] If the quantum circuit generation unit 130 has completed the processing in steps S244 to S249 for all qubit indices "q2=q1+1,...,n" that have a value greater than "q1", it proceeds to step S251.
[0199] [Step S251] The quantum circuit generation unit 130 proceeds to step S252 when it has completed the processing in steps S242 to S250 for all the qubit indices "q1=1,...,n-1" of the qubits used in the quantum circuit.
[0200] [Step S252] The quantum circuit generation unit 130 creates an observable group "Q'={Q1',Q2',···}" which consists of all the elements of the set "P'" and observables that can be represented by the product of the elements within "P'".
[0201] [Step S253] The quantum circuit generation unit 130 updates "Q" so that the elements of the observable group "Q'" become the elements of "Q". In this way, an element is added to the set "Q".
[0202] Next, the basis transformation operation determination process will be described in detail. FIG. 27 is a flowchart showing an example of the procedure of the basis transformation operation determination process. Hereinafter, the process shown in FIG. 27 will be described along with the step numbers.
[0203] [Step S301] The quantum circuit generation unit 130 acquires the generator "G = {G1, G2, ···}". [Step S302] Based on the generator "G", the quantum circuit generation unit 130 creates two binary matrices (X matrix and Z matrix).
[0204] [Step S303] The quantum circuit generation unit 130 executes the H operation determination process. The details of the H operation determination process will be described later (see FIG. 28). [Step S304] The quantum circuit generation unit 130 executes the CX operation determination process. The details of the CX operation determination process will be described later (see FIG. 29).
[0205] [Step S305] The quantum circuit generation unit 130 executes the S operation determination process. The details of the S operation determination process will be described later (see FIG. 32). [Step S306] The quantum circuit generation unit 130 executes the CZ operation determination process. The details of the CZ operation determination process will be described later (see FIG. 33).
[0206] [Step S307] The quantum circuit generation unit 130 performs a matrix operation (H operation on all columns) that exchanges the X matrix and the Z matrix. That is, the quantum circuit generation unit 130 determines to perform an H gate operation on all qubits after the operation of the quantum gate corresponding to the matrix operation determined in Steps S303 to S306.
[0207] Next, the H operation determination process will be described in detail. FIG. 28 is a flowchart showing an example of the procedure of the H operation determination process. Hereinafter, the process shown in FIG. 28 will be described along with the step numbers.
[0208] [Step S311] The quantum circuit generation unit 130 executes the processes in steps S312 to S313 for each of the qubit indices "q1=1,...,n". [Step S312] The quantum circuit generation unit 130 calculates the rank of the leftmost submatrix of the X matrix, specifically the "q1" column. The quantum circuit generation unit 130 then determines whether the rank satisfies the condition that it is equal to the smaller of the number of elements in "q1" and the generator "G". If the condition is met, the quantum circuit generation unit 130 proceeds to step S314. If the condition is not met, the quantum circuit generation unit 130 proceeds to step S313.
[0209] [Step S313] The quantum circuit generation unit 130 performs a matrix operation to swap the "q1" column of the X matrix with the "q1" column of the Z matrix. As a result, the quantum circuit generation unit 130 decides to perform an H gate operation on the qubit with qubit index "q1" in the basis conversion circuit.
[0210] [Step S314] When the quantum circuit generation unit 130 has completed the processing in steps S312 to S313 for all qubit indices "q1=1,...,n", it terminates the H operation determination process.
[0211] After the H operation decision process determines which qubit will perform the first H gate operation in the basis conversion circuit, the CX operation decision process is then performed. Figure 29 is a flowchart showing an example of the procedure for determining the CX operation. The process shown in Figure 29 will be explained below according to the step numbers.
[0212] [Step S321] The quantum circuit generation unit 130 repeatedly executes the processes in steps S322 to S329 as long as there is at least one row in the X matrix that has two or more elements that are "1".
[0213] [Step S322] The quantum circuit generation unit 130 initializes the variable "l" to "1". [Step S323] The quantum circuit generation unit 130 selects the column of the X matrix that has the l-th number of elements that are "1". The quantum circuit generation unit 130 designates the selected column as the "q2" column.
[0214] [Step S324] The quantum circuit generation unit 130 identifies rows in the X matrix where the element in the "q2" column is "0". The quantum circuit generation unit 130 then determines whether there are any columns in the X matrix other than the "q2" column where the elements of all the identified rows are "0". If at least one such row exists, the quantum circuit generation unit 130 proceeds to step S328. If no such row exists, the quantum circuit generation unit 130 proceeds to step S325.
[0215] [Step S325] The quantum circuit generation unit 130 determines whether the variable "l" is equal to the number of columns in the X matrix. If the variable "l" is equal to the number of columns in the X matrix, the quantum circuit generation unit 130 proceeds to step S326. If the variable "l" is less than the number of columns in the X matrix, the quantum circuit generation unit 130 proceeds to step S327.
[0216] [Step S326] The quantum circuit generation unit 130 performs the H transformation and CX transformation. Details of the H transformation and CX transformation process will be described later (see Figure 30). After that, the quantum circuit generation unit 130 terminates the CX operation determination process.
[0217] [Step S327] The quantum circuit generation unit 130 adds "1" to the variable "l" (l←l+1) and proceeds to step S323. [Step S328] The quantum circuit generation unit 130 selects the column with the largest number of elements that are "1" among the columns that satisfy the conditions in the determination in step S324. The quantum circuit generation unit 130 designates the selected column as the "q1" column.
[0218] [Step S329] The quantum circuit generation unit 130 adds the element in the same row of the "q1" column to each element in the "q2" column, and updates the value of each element in the "q2" column with the remainder (mod 2) obtained by dividing the sum by 2. In response to this matrix operation, the quantum circuit generation unit 130 decides to perform a CX gate operation with the qubit corresponding to the "q1" column as the control qubit and the qubit corresponding to the "q2" column as the target qubit.
[0219] [Step S330] The quantum circuit generation unit 130 terminates the CX operation determination process when there are no longer any rows in the X matrix that contain two or more elements of "1". Next, we will explain the H-conversion and CX-conversion processes in detail.
[0220] Figure 30 is a flowchart showing an example of the H-conversion and CX-conversion process. The process shown in Figure 30 will be explained below according to the step numbers. [Step S341] The quantum circuit generation unit 130 repeatedly executes steps S342 to S346 as long as there is at least one row in the X matrix that has two or more elements that are "1".
[0221] [Step S342] The quantum circuit generation unit 130 generates the qubit index "q h For each of the values "=1, ..., n", the process from steps S343 to S345 is executed. [Step S343] The quantum circuit generation unit 130 generates the "q" matrix of the X matrix. h The first row and the "q" of the Z matrix h The quantum circuit generation unit 130 determines whether the rank of the X matrix remains unchanged even if the row is swapped with the first row. If the rank does not change, the quantum circuit generation unit 130 proceeds to step S344. If the rank does change, the quantum circuit generation unit 130 proceeds to step S346.
[0222] [Step S344] The quantum circuit generation unit 130 generates the "q" matrix of the X matrix. h The "q" column and the Z matrix hDetermine whether there exists a pair of columns \((q1, q2)\) for which the CX operation is possible when the columns of the "」" column are swapped. If there exists a pair of columns for which the CX operation is possible, the quantum circuit generation unit 130 proceeds to step S345. Also, if there does not exist a pair of columns for which the CX operation is possible, the quantum circuit generation unit 130 proceeds to step S346.
[0223] [Step S345] The quantum circuit generation unit 130 executes the H operation & CX operation. Details of the H operation & CX operation will be described later (see Fig. 31). [Step S346] The quantum circuit generation unit 130 h If the processing of steps S343 to S345 has ended for all quantum bit indices "q
[0224] [Step S347] If there are no rows in the X matrix that have two or more "1" elements, the quantum circuit generation unit 130 ends the H transformation & CX transformation processing. Next, the H operation & CX operation processing will be described in detail.
[0225] Fig. 31 is a flowchart showing an example of the procedure of the H operation & CX operation processing. Among the processing shown in Fig. 31, the processing of steps S352 to S360 is the same as the processing of steps S321 to S325, S327 to S330 of the CX operation determination processing shown in Fig. 29. However, if the determination in step S356 is "YES", the H operation & CX operation processing ends without performing other processing. The processing performed in step S351, which is different from the CX operation determination processing in Fig. 29, is as follows.
[0226] [Step S351] The quantum circuit generation unit 130 swaps the "q h " column of the X matrix and the "q h " column of the Z matrix. In response to this matrix operation, the quantum circuit generation unit 130 determines to perform an H gate operation on the quantum bit corresponding to the "q1" column. Thereafter, the column for which the CX operation is to be performed is determined by the processing after step S352.
[0227] If performing an H operation results in a column that can be used for a CX operation, then the H operation is performed first, followed by the CX operation. After the CX operation decision process determines which qubit will operate the CX gate of the basis conversion circuit, the S operation decision process is then performed.
[0228] Figure 32 is a flowchart showing an example of the procedure for determining the S operation. The process shown in Figure 32 will be explained below according to the step numbers. [Step S361] The quantum circuit generation unit 130 executes the processes in steps S362 to S363 for each of the qubit indices "q1=1,...,n".
[0229] [Step S362] The quantum circuit generation unit 130 identifies rows in the X matrix where the element in the "q1" column is "1". The quantum circuit generation unit 130 determines whether the condition that the element in the "q1" column is "1" is met in all rows of the Z matrix with the same observable index as each of the identified rows. If the condition is met, the quantum circuit generation unit 130 proceeds to step S363. If the condition is not met, the quantum circuit generation unit 130 proceeds to step S364.
[0230] [Step S363] The quantum circuit generation unit 130 adds each element of the "q1" column of the X matrix to each element of the "q1" column of the Z matrix, divides by 2, and uses the remainder as each element of the "q1" column of the new Z matrix. In response to this matrix operation, the quantum circuit generation unit 130 decides to perform an S-gate operation on the qubit at qubit index "q1".
[0231] [Step S364] The quantum circuit generation unit 130 terminates the S operation determination process when it has completed the processing in steps S362 to S363 for all qubit indices "q1=1,...,n".
[0232] Once the S operation decision process is complete, the CZ operation decision process is performed. Figure 33 is a flowchart showing an example of the procedure for determining the CZ operation. The process shown in Figure 33 will be explained below according to the step numbers.
[0233] [Step S371] The quantum circuit generation unit 130 executes the processes in steps S372 to S377 for each of the qubit indices "q1=1,...,n-1". [Step S372] The quantum circuit generation unit 130 executes the processes in steps S373 to S376 for each qubit index "q2 = q1 + 1, ..., n" that has a value greater than "q1".
[0234] [Step S373] The quantum circuit generation unit 130 identifies rows in the X matrix where the element in the "q1" column is "1". The quantum circuit generation unit 130 determines whether the condition that the element in the "q2" column is "1" is met in all rows of the Z matrix with the same observable index as each of the identified rows is met. If the condition is met, the quantum circuit generation unit 130 proceeds to step S374. If the condition is not met, the quantum circuit generation unit 130 proceeds to step S377.
[0235] [Step S374] The quantum circuit generation unit 130 identifies rows in the X matrix where the element in the "q2" column is "1". The quantum circuit generation unit 130 determines whether the condition that the element in the "q1" column is "1" is met in all rows of the Z matrix with the same observable index as each of the identified rows is met. If the condition is met, the quantum circuit generation unit 130 proceeds to step S375. If the condition is not met, the quantum circuit generation unit 130 proceeds to step S377.
[0236] [Step S375] The quantum circuit generation unit 130 adds each element of the "q1" column of the X matrix to each element of the "q2" column of the Z matrix, divides by 2, and uses the remainder as each element of the "q2" column of the new Z matrix.
[0237] [Step S376] The quantum circuit generation unit 130 adds each element of the "q2" column of the X matrix to each element of the "q1" column of the Z matrix, divides by 2, and uses the remainder as each element of the "q1" column of the new Z matrix.
[0238] The quantum circuit generation unit 130 decides to perform a CZ gate operation on qubit indices "q1" and "q2" in response to the matrix operations in steps S375 and S376.
[0239] [Step S377] If the quantum circuit generation unit 130 has completed the processing in steps S373 to S376 for all qubit indices "q2=q1+1,...,n" that have a value greater than "q1", it proceeds to step S378.
[0240] [Step S378] The quantum circuit generation unit 130 terminates the CZ operation determination process when it has completed the processing in steps S372 to S377 for all qubit indices "q1=1,...,n-1".
[0241] As described above, the appropriate basis transformation operation is determined, and a basis transformation circuit corresponding to the determined basis transformation operation is generated. Next, an example of a basis transformation operation will be explained with reference to Figures 34 to 38. Figure 34 is a diagram (1 / 5) showing an example of a basis change operation. For example, let's assume we are performing a measurement on an 8-qubit (n=8) observable. The generated generator 60 is "G={ZIIZIIII,IIIIIIZZ,IIIIIIXY,IIIIYXII,IYXIIIII,IXZZIXII,IIXZXZII,XIXXIXII}". The number of elements in generator 60 is "8".
[0242] The elements of such a generator 60 can be represented by the X matrix 61 and the Z matrix 62. Based on the H operation decision process using the X matrix 61 and the Z matrix 62, three H operations 63a to 63c are performed on the X matrix 61 and the Z matrix 62.
[0243] In the first H operation 63a, the fourth column of matrix X 61 and the fourth column of matrix Z 62 are swapped. In the second H operation 63b, the sixth column of matrix X 61 and the sixth column of matrix Z 62 are swapped. In the third H operation 63c, the eighth column of matrix X 61 and the eighth column of matrix Z 62 are swapped.
[0244] Based on these H operations, an H gate is placed for each qubit with qubit indices "4, 6, and 8" in the basis conversion circuit. Figure 35 is a diagram (2 / 5) showing an example of a basis transformation operation. Based on the CX operation determination process using the X matrix 61 and Z matrix 62 after the H operation, seven CX operations 64a to 64g are performed on the X matrix 61 and Z matrix 62.
[0245] In the first CX operation 64a, the 6th column is "q1" and the 4th column is "q2". The first CX operation 64a updates the 4th column of the X matrix 61 and the 6th column of the Z matrix 62. In the second CX operation 64b, the 6th column is "q1" and the 3rd column is "q2". The second CX operation 64b updates the 3rd column of the X matrix 61 and the 6th column of the Z matrix 62. In the third CX operation 64c, the 1st column is "q1" and the 3rd column is "q2". The third CX operation 64c updates the 3rd column of the X matrix 61 and the 1st column of the Z matrix 62. In the fourth CX operation 64d, the 3rd column is "q1" and the 2nd column is "q2". The fourth CX operation 64d updates the 2nd column of the X matrix 61 and the 3rd column of the Z matrix 62. In the 5th CX operation 64e, the 2nd column is "q1" and the 4th column is "q2". The 5th CX operation 64e updates the 4th column of the X matrix 61 and the 2nd column of the Z matrix 62. In the 6th CX operation 64f, the 6th column is "q1" and the 5th column is "q2". The 6th CX operation 64f updates the 5th column of the X matrix 61 and the 6th column of the Z matrix 62. In the 7th CX operation 64g, the 7th column is "q1" and the 8th column is "q2". The 7th CX operation 64g updates the 8th column of the X matrix 61 and the 7th column of the Z matrix 62.
[0246] In Figure 35, elements whose values are changed by CX operations 64c to 64g are indicated with a diagonal line. A "0" with a diagonal line is changed to "1", and a "1" with a diagonal line is changed to "0".
[0247] Based on CX operation 64a, a CX gate is placed in the basis circuit with the qubit at qubit index "6" as the control qubit and the qubit at qubit index "4" as the target qubit. Based on CX operation 64b, a CX gate is placed in the basis circuit with the qubit at qubit index "6" as the control qubit and the qubit at qubit index "3" as the target qubit. Based on CX operation 64c, a CX gate is placed in the basis circuit with the qubit at qubit index "1" as the control qubit and the qubit at qubit index "3" as the target qubit. Based on CX operation 64d, a CX gate is placed in the basis circuit with the qubit at qubit index "3" as the control qubit and the qubit at qubit index "2" as the target qubit. Based on CX operation 64e, a CX gate is placed in the basis circuit with the qubit at qubit index "2" as the control qubit and the qubit at qubit index "4" as the target qubit. Based on CX operation 64f, a CX gate is placed in the basis circuit with the qubit at qubit index "6" as the control qubit and the qubit at qubit index "5" as the target qubit. Based on CX operation 64g, a CX gate is placed in the basis circuit with the qubit at qubit index "7" as the control qubit and the qubit at qubit index "8" as the target qubit.
[0248] Figure 36 is a diagram (3 / 5) showing an example of a basis transformation operation. Based on the X matrix 61 and Z matrix 62 after the CX operation, an S operation determination process is performed, resulting in three S operations 65a to 65c being performed on the X matrix 61 and Z matrix 62.
[0249] In the first S operation 65a, the third column of matrix Z 62 is updated using the third column of matrix X 61. In the second S operation 65b, the fifth column of matrix Z 62 is updated using the fifth column of matrix X 61. In the third S operation 65c, the seventh column of matrix Z 62 is updated using the seventh column of matrix X 61.
[0250] Based on these S operations, S gates are placed in the basis conversion circuit for each qubit with qubit indices "3, 5, and 7". Figure 37 is a diagram (4 / 5) showing an example of a basis transformation operation. Based on the X matrix 61 and Z matrix 62 after the S operation, a CZ operation determination process is performed, resulting in four CZ operations 66a to 66d being performed on the X matrix 61 and Z matrix 62.
[0251] In the first CZ operation 66a, the first column is "q1" and the second column is "q2". The first CZ operation 66a updates the first and second columns of the Z matrix 62. In the second CZ operation 66b, the seventh column is "q1" and the eighth column is "q2". The second CZ operation 66b updates the seventh and eighth columns of the Z matrix 62. In the third CZ operation 66c, the first column is "q1" and the fourth column is "q2". The third CZ operation 66b updates the first and fourth columns of the Z matrix 62. In the fourth CZ operation 66d, the second column is "q1" and the third column is "q2". The fourth CZ operation 66d updates the second and third columns of the Z matrix 62.
[0252] In Figure 37, elements whose values are changed by CZ operations 66c to 66d are marked with a diagonal line. A "0" with a diagonal line is changed to "1", and a "1" with a diagonal line is changed to "0".
[0253] Based on CZ operation 66a, CZ gates targeting qubits with qubit indices "1" and "2" are placed in the basis circuit. Based on CZ operation 66b, CZ gates targeting qubits with qubit indices "7" and "8" are placed in the basis circuit. Based on CZ operation 66c, CZ gates targeting qubits with qubit indices "1" and "4" are placed in the basis circuit. Based on CZ operation 66d, CZ gates targeting qubits with qubit indices "2" and "3" are placed in the basis circuit.
[0254] Figure 38 is a diagram (5 / 5) showing an example of a basis transformation operation. Based on the X matrix 61 and Z matrix 62 after the CZ operation, a matrix swap operation is performed on the X matrix 61 and Z matrix 62, and column-by-column H operations 67a, 67b, ... are performed on the X matrix 61 and Z matrix 62. Based on the H operations 67a, 67b, ..., an H gate is placed on all qubits in the basis transformation circuit.
[0255] As described above, the procedure for the basis conversion operation is determined, and the basis conversion circuit is generated according to the determined procedure for the basis conversion operation. Figure 39 shows an example of a generated basis transform circuit. The basis transform circuit 68 contains quantum gates corresponding to each of the basis transform operations shown in Figures 34 to 38. By executing the basis transform circuit, the expectation value of each observable included in the generator 60 is measured as the expectation value of the observables shown in the observable group 60a.
[0256] The Pauli strings of the observables shown in the observable group 60a all consist of one "Z" and seven "I"s. That is, the expected value of each observable in the observable group 60a can be obtained from the measurement result of the qubit corresponding to the qubit index of "Z".
[0257] In the examples shown in Figures 34 to 38, the H-transformation and CX-transformation processes are not performed during the CX-operation determination process. Below, we will explain an example of determining the basis transformation operation when the H-transformation and CX-transformation processes are performed.
[0258] Figure 40 shows an example of determining the basis transformation operation in the H transformation and CX transformation process. For example, suppose that during the CX operation determination process, the X matrix 71 and Z matrix 72 are in the following state. The CX operation determination process is a matrix transformation process that performs such a transformation on each row of the X matrix 71 that there is only one element that is "1". The X matrix 71 has three rows that do not have one element that is "1". However, it is not possible to perform any further CX operations on the X matrix 71. In such a case, the H transformation and CX transformation process is performed.
[0259] In the H-transformation and CX-transformation process, qubit indices whose rank in the X matrix remains unchanged even when the columns of the X matrix 71 and the Z matrix 72 are swapped are listed. In the example in Figure 40, qubit indices "1, 3, 7, 8" are among those that fall into this category. For the corresponding qubit indices, it is then checked whether the CX operation can be continued after the columns of the X matrix 71 and the Z matrix 72 are swapped. For qubit indices that are determined to allow the CX operation to be continued after the column swap, the H-operation 73 is performed, which swaps the columns of the X matrix 71 and the Z matrix 72. In the example in Figure 40, the columns of the X matrix 71 and the Z matrix 72 are swapped for qubit index "8".
[0260] This makes it possible to perform further CX operations. In the example in Figure 40, five CX operations 74a to 74e are performed. In Figure 40, elements whose values are changed by CX operations 74a to 74e are drawn with a diagonal line. A diagonally lined "0" is changed to "1", and a diagonally lined "1" is changed to "0". As a result, in each row of the X matrix 71, there is one element that is "1".
[0261] The above procedure for generating the basis conversion circuit includes at least the following three improvements to reduce the number of 2-qubit gates. The first improvement involves calculating an appropriate index value for each observable from a set of basis transformation observables "Q," and then generating a generator "G," which is a set of observables for which the expected value is calculated by a 1-qubit measurement, based on that index value.
[0262] The second improvement involves selecting the observable used to calculate the expected value in a single-qubit measurement not only from elements within partition "P", but from a set of partitions "Q" that encompasses the elements of partition "P" and contains more elements. The set of partitions "Q" includes the elements of partition "P", as well as observables represented by the product of those elements.
[0263] The third improvement is that the number of elements in the set "Q" generated from the elements of partition "P" is "2 n This process updates set "Q" using set "P'", which is obtained by adding observables that commute with the elements of partition "P" when the value is less than -1.
[0264] The following will specifically explain the relationship between the application of the three improvement measures described above and the number of qubits in the generated basis transform circuit. Note that if the first improvement measure is not applied, for example, an observable randomly selected from partition "P" becomes an element of generator "G". If the second improvement measure is not applied, the observable whose expected value is calculated by a 1-qubit measurement is selected only from elements within partition "P". If the third improvement measure is not applied, the number of elements in the set "Q" generated from the elements of partition "P" is "2 n Even if the value is less than -1, no element is added to the set "Q".
[0265] Below, we consider the case where the ground state energy of LiH is calculated using a quantum computer, with the calculation basis being STO3G, the number of active spin orbits being 12, and based on qubit mapping using the Jordan-Wigner transform. In this case, the number of observables for which expectation values need to be measured is 630, and each observable is represented by a 12-qubit Pauli string. We will now explain the number of 2-qubit gates in the ground state transform circuit when measuring the observables in this case.
[0266] First, based on these observables, a partition is generated containing all simultaneously measurable observables. Figure 41 shows an example of the partitioning results. Graph 81 shows the number of elements in each partition generated by the partitioning. In Graph 81, the horizontal axis is the partition number, and the vertical axis is the number of elements. In the example in Figure 41, 18 partitions were generated.
[0267] For each of these partitions, we will explain the number of 2-qubit gate operations required when generating a basis transform circuit for "no improvement," "first improvement," "first + second improvement," and "first + second + third improvement."
[0268] If "No improvement measures" is applied, an observable "G1, G2, ..." is randomly selected from partition "P", and a generator "G" is created. When the "first improvement measure" is applied, the index value "v" is obtained from partition "P". i Based on the size of the object, the observables "G1, G2, ..." are selected, and the generator "G" is created.
[0269] When the "first + second improvement measures" are applied, a set of observables "Q" is generated based on the elements of partition "P," which can be represented as the product of those elements. Then, from the set "Q," the index value "v" is obtained. iBased on the size of the object, the observables "G1, G2, ..." are selected, and a generator "G" containing the selected observables is created.
[0270] When the "1st + 2nd + 3rd improvement measures" are applied, the number of observables in the set "Q" becomes 2 n If the number of elements is less than -1, the set "Q" has 2 elements. n -1 observable group "Q'" is created. Then, from the observable group "Q'", the index value "v i Based on the size of the object, the observables "G1, G2, ..." are selected, and a generator "G" containing the selected observables is created.
[0271] Figure 42 shows an example of the number of 2-qubit gates in the generated basis transform circuit. Table 82 shows the number of 2-qubit gates included in the basis transform circuit for each partition in the case of "no improvements". Table 83 shows the number of 2-qubit gates included in the basis transform circuit for each partition when "first improvement" is applied. Table 84 shows the number of 2-qubit gates included in the basis transform circuit for each partition when "first + second improvement" is applied. Table 85 shows the number of 2-qubit gates included in the basis transform circuit for each partition when "first + second + third improvement" is applied.
[0272] Tables 82-85 show the number of CX gates and CZ gates below the number of 2-qubit gates per partition. Tables 84 and 85 also show the number of elements in set "Q" for each partition.
[0273] As can be seen by comparing Tables 82-85, applying "Improvement 1" results in fewer 2-qubit gates than applying "No Improvement Measures". Furthermore, applying "Improvement 1 + Improvement 2" results in fewer 2-qubit gates than applying "Improvement 1" alone. Moreover, applying "Improvement 1 + Improvement 2 + Improvement 3" results in fewer 2-qubit gates than applying "Improvement 1 + Improvement 2".
[0274] By applying these various improvement measures, it becomes possible to reduce the number of 2-qubit gates included in the basis conversion circuit. Below, the comparison results of generator "G" for each applied improvement measure will be explained with reference to Figures 43 and 44.
[0275] Figure 43 shows an example of a partition generator for partition number "2". Observable group 86 shows generator "G" in the case of "no improvement". The average number of characters other than "I" in the observables of observable group 86 is "4.5".
[0276] Observable group 87 shows generator "G" when "the first improvement measure" is applied. The average number of characters other than "I" in the observables of observable group 87 is "3.5".
[0277] Observable group 88 shows generator "G" when the "first + second improvement measures" are applied. The average number of characters other than "I" in the observables of observable group 88 is "2.0".
[0278] Observable group 89 represents generator "G" when the "1st + 2nd + 3rd improvement measures" are applied. The average number of characters other than "I" in the observables of observable group 89 is "2.0".
[0279] Figure 44 shows an example of a partition generator for partition number "10". Observable group 90 shows generator "G" in the case of "no improvement". The average number of characters other than "I" in the observables of observable group 90 is "7.1".
[0280] Observable group 91 shows generator "G" when the "first improvement measure" is applied. The average number of characters other than "I" in the observables of observable group 91 is "4.5".
[0281] Observable group 92 shows generator "G" when the "first + second improvement measures" are applied. The average number of characters other than "I" in the observables of observable group 92 is "3.3".
[0282] Observable group 93 represents generator "G" when the "1st + 2nd + 3rd improvement measures" are applied. The average number of characters other than "I" in the observables of observable group 93 is "2.7".
[0283] As shown in Figures 43 and 44, applying more improvements reduces the number of non-I characters in the observable included in generator "G". The fewer non-I characters there are in the observable included in generator "G", the higher the likelihood that the number of 2-qubit gates in the basis conversion circuit can be reduced.
[0284] In the example above, the index value "v i =c x n i,x +c y n i,y +c z n i,z The weight coefficient of "c x =c z =1,c y Although it is set to "=2", the optimal value of the weight coefficient depends on the Pauli string of the observable included in the partition.
[0285] FIG. 45 is a diagram showing an example of the number of two-qubit gates according to the weights of characters used in the calculation of the index value. Table 94 shows the number of two-qubit gates for each combination of character weights when the "First + Second + Third improvement measures" are applied. The weights of X, Y, and Z are each represented by an array of numerical values of [c x , c y , c z . Below the combination of character weights, the number of two-qubit gates included in the basis change circuit, the number of CX gates among them, and the number of CZ gates are shown.
[0286] In the example of Table 94, when [c x , c y , c z = [1.0, 1.5, 1.0], the number of two-qubit gates is minimized to "12". Thus, by increasing the weight of Y more than that of X or Z, the number of two-qubit gates can be reduced.
[0287] As described above, the embodiments have been illustrated. However, the configurations of each part shown in the embodiments can be replaced with other ones having the same functions. Also, other arbitrary components or processes may be added. Furthermore, combinations of any two or more configurations (features) among the above-described embodiments may be used.
Explanation of Reference Numerals
[0288] 1 Quantum computer 2,4 Observable group 2a, 2b - 1, 2b - 2, ···, 3a~3d, 6a~6c, 7a~7d Observable 5a~5c Partition 8 Quantum circuit 9 Basis change circuit 10 Information processing device 11 Storage unit 12 Processing unit
Claims
1. For each of the multiple simultaneously measurable observables included in the group of observables, an index value is calculated according to the number of characters other than "I" in the Pauli string representing the observable. From the group of observables, a predetermined number of observables are selected based on the index value. A basis transform circuit is generated that converts the expected value of each of the selected predetermined number of observables in the execution result of a quantum circuit that performs quantum computation according to the problem to be solved into a measurement result of one qubit. A quantum computing support program that allows a computer to perform a process.
2. In the process of calculating the aforementioned index value, the index value is calculated such that the fewer the number of characters other than I included in the Pauli string, the higher the selection order of the observable. In the process of selecting the predetermined number of observables, the predetermined number of observables are selected starting from the one with the highest selection order based on the index value. The quantum computing support program according to claim 1.
3. In the process of calculating the aforementioned index value, the linear sum of the numbers X, Y, and Z contained in the Pauli string is calculated as the index value. The quantum computing support program according to claim 2.
4. In the process of calculating the index value, the weight coefficient of the number of Y in the linear combination is set to a value greater than the respective weight coefficients of the number of X and the number of Z, and the index value is calculated. The quantum computing support program according to claim 3.
5. In the process of calculating the index value, the group of observables includes multiple simultaneously measurable observables among the multiple observables of the multiple measurables used to calculate the solution of the problem to be solved, and an observable represented by the product of the simultaneously measurable observables. The quantum computing support program according to claim 1.
6. In the process of calculating the index value, an additional observable is generated that is commutative to each of the multiple simultaneously measurable observables among the multiple observables of the multiple measurables used to calculate the solution to the problem to be solved, and which contains two or fewer characters other than I in the Pauli string. The group of observables includes the simultaneously measurable observables, the additional observables, and an observable represented by the product of two or more of the simultaneously measurable observables and the additional observables. The quantum computing support program according to claim 1.
7. For each of the multiple simultaneously measurable observables included in the group of observables, an index value is calculated according to the number of characters other than "I" in the Pauli string representing the observable. From the group of observables, a predetermined number of observables are selected based on the index value. A basis transform circuit is generated that converts the expected value of each of the selected predetermined number of observables in the execution result of a quantum circuit that performs quantum computation according to the problem to be solved into a measurement result of one qubit. A quantum computing support method in which a computer performs the processing.
8. A processing unit that calculates an index value for each of the multiple simultaneously measurable observables included in the group of observables, corresponding to the number of characters other than "I" in the Pauli string representing the observable, selects a predetermined number of observables from the group of observables based on the index value, and generates a basis conversion circuit that converts the expected value of each of the selected predetermined number of observables in the execution result of a quantum circuit that performs quantum computation according to the problem to be solved into a measurement result of one qubit. An information processing device having
Citation Information
Patent Citations
Quantum circuit generation system and generation method
JP2023521223A
Partitioned Template Matching and Symbolic Peephole Optimization
JP2023547348A
Method for partitioning multiple qubit observables, program for partitioning multiple qubit observables, and information processing device
WO2022269712A1