WO2024154265A1 - Quantum circuit design assistance program, quantum circuit design assistance method, and quantum circuit design assistance device - Google Patents
Quantum circuit design assistance program, quantum circuit design assistance method, and quantum circuit design assistance device Download PDFInfo
- Publication number
- WO2024154265A1 WO2024154265A1 PCT/JP2023/001368 JP2023001368W WO2024154265A1 WO 2024154265 A1 WO2024154265 A1 WO 2024154265A1 JP 2023001368 W JP2023001368 W JP 2023001368W WO 2024154265 A1 WO2024154265 A1 WO 2024154265A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- quantum
- gate
- bit
- bits
- gates
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N10/00—Quantum computing, i.e. information processing based on quantum-mechanical phenomena
- G06N10/40—Physical realisations or architectures of quantum processors or components for manipulating qubits, e.g. qubit coupling or qubit control
Definitions
- the present invention relates to a quantum circuit design support program, a quantum circuit design support method, and a quantum circuit design support device.
- quantum circuits The quantum computations to be executed by a quantum computer or quantum computer simulator (hereafter referred to as quantum simulator) are represented by quantum circuits.
- a quantum circuit is a quantum computation model that combines various types of quantum gates.
- a quantum gate represents an operation that rewrites the state of a quantum bit.
- Basic quantum gates are quantum gates that can be executed by a quantum computer.
- Quantum circuits generated using the quantum circuit description language also use quantum gates that perform complex operations other than basic quantum gates.
- a classical computer then converts the quantum gates included in the quantum circuit, other than the basic quantum gates, into an equivalent quantum circuit (equivalent circuit) that combines basic quantum gates. This generates a quantum circuit described only with basic quantum gates.
- auxiliary quantum bits There are two types of auxiliary bits: quantum bits whose state is known to be a specified value (for example,
- the present invention aims to make it possible to determine whether a quantum bit becomes a predetermined value during a quantum computing process.
- a quantum circuit design support program causes a computer to execute the following processes.
- the computer determines whether the quantum bit to be operated by the quantum gate to be determined will have a predetermined value after the gate operation based on initial value information indicating whether each of the multiple quantum bits operated by the quantum circuit has a predetermined value in the initial state.
- the computer then identifies, for each quantum gate to be determined, the quantum bit that has become the predetermined value after the gate operation by the quantum gate to be determined.
- FIG. 1 is a diagram illustrating an example of a quantum circuit design support method according to a first embodiment.
- FIG. 1 illustrates an example of a system configuration according to a second embodiment;
- FIG. 1 is a diagram illustrating an example of a hardware configuration of a classical computer.
- FIG. 13 is a diagram showing an example of conversion to an equivalent circuit of a C 3 -NOT gate.
- FIG. 13 is a diagram showing an example of conversion to an equivalent circuit of a C 4 -NOT gate.
- FIG. 1 is a diagram showing an example of a quantum circuit using a plurality of C k -NOT gates.
- FIG. 13 shows an example of adding a clean quantum bit for the transformation of a C k -NOT gate.
- FIG. 1 is a diagram illustrating an example of a quantum circuit design support method according to a first embodiment.
- FIG. 1 illustrates an example of a system configuration according to a second embodiment
- FIG. 1 is a diagram illustrating an example of
- FIG. 2 is a diagram illustrating an example of a state transition of a quantum bit.
- FIG. 2 is a block diagram showing an example of functions of each device.
- 1 is a flowchart showing an example of a procedure for executing quantum computation involving optimization of a quantum circuit.
- 13 is a flowchart illustrating an example of a procedure for a clean bit update process.
- FIG. 13 is a diagram illustrating an example of initial information setting by a clean bit update process.
- FIG. 13 is a diagram illustrating an example of a state transition of tmpCleanBitList.
- FIG. 13 is a diagram illustrating an example of a correspondence relationship between the number of available auxiliary bits and an applicable conversion method.
- FIG. 13 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate according to the first conversion method.
- FIG. 13 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate according to the second conversion method.
- FIG. 13 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate according to the third conversion method.
- FIG. 13 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate according to the basic approach of the fourth conversion method.
- FIG. 13 is a diagram showing a first example of an equivalent circuit of a C 7 -NOT gate according to the fourth transformation scheme when there are less than k ⁇ 2 clean bits.
- FIG. 13 is a diagram showing a second example of an equivalent circuit of a C 7 -NOT gate according to the fourth transformation scheme when there are less than k ⁇ 2 clean bits.
- FIG. 13 is a diagram illustrating an example of functions of a quantum gate conversion unit.
- 13 is a flowchart illustrating an example of a procedure for a quantum gate conversion process.
- 13 is a flowchart illustrating an example of a procedure for a division method determination process.
- 13 is a flowchart illustrating an example of a procedure for an equivalent circuit generation process in a fourth conversion method.
- FIG. 13 is a flowchart (1/2) showing an example of a procedure for C k_i -NOT gate conversion processing. 13 is a flowchart (2/2) showing an example of a procedure for C k_i -NOT gate conversion processing. FIG. 13 is a diagram showing an example of transformation of a C k -NOT gate.
- the first embodiment is a quantum circuit design support method that supports the design of a quantum circuit by determining whether or not a quantum bit becomes a predetermined value during a quantum computation process.
- FIG. 1 is a diagram showing an example of a quantum circuit design support method according to a first embodiment.
- FIG. 1 shows a quantum circuit design support device 10 that realizes the quantum circuit design support method.
- the quantum circuit design support device 10 can implement the quantum circuit design support method, for example, by executing a quantum circuit design support program.
- the quantum circuit design support device 10 has a memory unit 11 and a processing unit 12.
- the memory unit 11 is, for example, a memory or storage device that the quantum circuit design support device 10 has.
- the processing unit 12 is, for example, a processor or arithmetic circuit that the quantum circuit design support device 10 has.
- the storage unit 11 stores quantum circuit 1a to be executed by a quantum computer or quantum simulator, and initial value information 1b indicating whether each of the multiple quantum bits operated by quantum circuit 1a has a predetermined value in the initial state.
- Quantum circuit 1a includes multiple quantum gates 2 to 6. In the example of Figure 1, the number of quantum bits operated by quantum circuit 1a is seven.
- a gate operation according to quantum gates 2 to 4 is performed as the X-1th gate operation (X is a natural number).
- Each of the quantum gates 2 to 4 is a Hadamard gate that operates on the fifth to seventh quantum bits.
- a gate operation according to quantum gate 5 is performed as the Xth gate operation.
- the quantum gate 5 is a Hadamard gate for the fifth quantum bit.
- a gate operation according to quantum gate 6 is performed as the X+1th gate operation.
- the quantum gate 6 is a C 3 -NOT gate that uses the first to third quantum bits as control bits and the fourth quantum bit as a target bit.
- the C 3 -NOT gate is a quantum gate that inverts a control bit when all three control bits are
- the superscript of C indicates the number of control bits.
- This type of quantum gate is called MPMCT (Mixed-Polarity Multiple-Control Toffoli).
- the processing unit 12 determines, based on the quantum circuit 1a and the initial state of each of the multiple quantum bits operated by the quantum circuit 1a, whether the quantum bit to be operated will have a predetermined value after a gate operation on the quantum bit to be operated by the first quantum gate included in the quantum circuit 1a.
- the initial state of each of the multiple quantum bits is, for example, a state in which the values of all quantum bits are
- the predetermined value for the quantum bit to be operated is, for example,
- the processing unit 12 judges the quantum gates in the quantum circuit 1a in order of the gate operation, and judges whether the quantum bit to be operated becomes a predetermined value after the gate operation on the quantum bit to be operated based on the initial value information 1b.
- the processing unit 12 identifies a quantum bit that has become a predetermined value after the gate operation by the quantum gate to be judged. For example, the processing unit 12 generates a list of the identified quantum bits. Specifically, the processing unit 12 generates the list based on whether the quantum bit to be operated by the quantum gate to be judged becomes a predetermined value after the gate operation, and whether the quantum bits other than the quantum bit to be operated are a predetermined value before the gate operation. That is, the processing unit 12 includes the identification numbers of the quantum bits that have been at a predetermined value before the gate operation by the quantum gate to be judged and are not the object of operation by the quantum gate to be judged in the list corresponding to the quantum gate to be judged.
- the processing unit 12 also includes the identification numbers of the quantum bits that become a predetermined value by the gate operation according to the quantum gate to be judged in the list corresponding to the quantum gate to be judged. Furthermore, the processing unit 12 excludes the identification numbers of the quantum bits for which it is unclear whether they become a predetermined value after the gate operation according to the quantum gate to be judged from the list corresponding to the quantum gate to be judged.
- a list of quantum bits that will become a predetermined value after gate operation by that quantum gate can be generated.
- the processing unit 12 can effectively use the quantum bits whose value is
- the processing unit 12 can reduce the number of quantum gates in the quantum circuit after conversion. As a result, the quantum computer or quantum simulator can perform efficient quantum calculations.
- the processing unit 12 judges that the quantum bit to be manipulated will have a predetermined value after the gate operation. Furthermore, if the gate operation by the quantum gate to be judged is an operation other than an operation that changes the state of the quantum bit to be manipulated to a predetermined value, the processing unit 12 judges that it is unclear whether the predetermined value will be obtained after the gate operation. For example, the user specifies in advance to the processing unit 12 a quantum gate that indicates a gate operation that changes the state of the quantum bit to be manipulated to a predetermined value. The processing unit 12 determines that the gate operation of the specified quantum gate is a gate operation that changes the state of the quantum bit to be manipulated to a predetermined value.
- the processing unit 12 judges that the states of the two quantum bits to be operated by the SWAP gate will be swapped. That is, the processing unit 12 judges that when the first quantum bit to be operated by the SWAP gate is a predetermined value before the gate operation by the quantum gate to be judged, the second quantum bit to be operated will be a predetermined value after the gate operation. In this case, the processing unit 12 includes the second quantum bit in the list.
- the processing unit 12 determines that it is unclear whether the second quantum bit to be operated will have a predetermined value after the gate operation. In this case, the processing unit 12 excludes the second quantum bit from the list.
- the processing unit 12 can appropriately generate a list of quantum bits that will become a predetermined value after gate operation by the SWAP gate.
- the generated list can be used, for example, in a process of converting a complex quantum gate into an equivalent circuit composed of basic quantum gates.
- the processing unit 12 identifies a third quantum bit that is a predetermined value after the gate operation of the first quantum gate based on the list generated when the first quantum gate is the quantum gate to be judged.
- the processing unit 12 then converts the second quantum gate to be executed after the first quantum gate into a quantum circuit equivalent to the second quantum gate, using the third quantum bit. This allows the quantum gate of the predetermined value to be used as an auxiliary bit, and the second quantum gate is converted into an equivalent circuit with a smaller number of quantum gates.
- 0> after the X-2th gate operation are the fourth to seventh quantum bits. In this case, it is unclear whether the first to third quantum bits are
- 0> quantum bits after the X-2th gate operation is ⁇ 4, 5, 6, 7 ⁇ .
- gate operations are performed by quantum gates 2 to 4 (Hadamard gates) as the X-1th gate operation.
- quantum gates 2 to 4 Hadamard gates
- 0> quantum bits after the X-1th gate operation is ⁇ 4 ⁇ .
- quantum circuit 1a a gate operation by quantum gate 5 (Hadamard gate) is performed as the Xth gate operation.
- the fifth quantum bit has had two gate operations by the Hadamard gate performed from
- the fifth quantum bit returns to
- 0> after the Xth gate operation becomes ⁇ 4, 5 ⁇ .
- a quantum gate (C 3 -NOT gate) is operated.
- the C 3 -NOT gate is not a basic quantum gate. Therefore, the C 3 -NOT gate is converted into an equivalent circuit that combines C 2 -NOT gates.
- the conversion to an equivalent circuit of the C 3 -NOT gate if a quantum bit of
- the processing unit 12 Since the processing unit 12 has generated a list of quantum bits of
- the second embodiment is a computer system that converts a quantum gate that performs complex gate operations in a quantum circuit into a basic quantum gate and causes a quantum computer to execute quantum calculations according to a quantum circuit composed only of basic quantum gates.
- 0> is called a clean quantum bit or clean bit.
- 0> or not is called a dirty quantum bit or dirty bit.
- FIG. 2 is a diagram showing an example of a system configuration of the second embodiment.
- the system includes a classical computer 100 and a quantum computer 200.
- Terminals 31, 32, ... are connected to the classical computer 100 via a network 20.
- the terminals 31, 32, ... are computers used by users who request quantum computing by the quantum computer 200.
- the classical computer 100 accepts quantum circuits from the terminals 31, 32, ....
- a quantum circuit indicates the order of operations on quantum bits by the arrangement of elements such as gates.
- a quantum bit is a bit that can express a superposition state of the
- the classical computer 100 converts the quantum circuits received from the terminals 31, 32, ... into quantum circuits that can be executed by the quantum computer 200.
- a quantum circuit that can be executed by the quantum computer 200 is, for example, a quantum circuit described using only basic quantum gates.
- the classical computer 100 instructs the quantum computer 200 to execute the converted quantum circuit.
- the classical computer 100 obtains the measurement results of each quantum bit from the quantum computer 200.
- Quantum computer 200 has multiple quantum bits and a device for manipulating each of the multiple quantum bits.
- the multiple quantum bits of quantum computer 200 may be, for example, of a superconducting type or an ion trap type.
- the multiple quantum bits may also be of a diamond spin type. If the quantum bits are of a superconducting type, quantum computer 200 may have a refrigerator for cooling the quantum bits.
- the quantum computer 200 irradiates the quantum bits with microwaves, for example, in response to instructions from the classical computer 100.
- a device for manipulating each of the multiple quantum bits measures the state of each of the multiple quantum bits and transmits the state to the classical computer 100.
- FIG. 3 is a diagram showing an example of the hardware configuration of a classical computer.
- the CPU 101 is a processor that executes program instructions.
- the CPU 101 may include multiple processor cores.
- the CPU 101 may also be multiple processors, such as an MPU (Micro Processing Unit) or a DSP (Digital Signal Processor).
- MPU Micro Processing Unit
- DSP Digital Signal Processor
- At least a part of the functions realized by the CPU 101 executing a program may be realized by electronic circuits such as an ASIC (Application Specific Integrated Circuit) or a PLD (Programmable Logic Device).
- a RAM (Random Access Memory) 102 and multiple peripheral devices are connected to the CPU 101 via a bus 100a.
- RAM 102 is the main storage device of classical computer 100.
- RAM 102 temporarily stores at least a portion of the OS (Operating System) program and application programs to be executed by CPU 101.
- RAM 102 also stores various data used for processing by CPU 101.
- classical computer 100 may be equipped with a type of memory other than RAM, or may be equipped with multiple memories.
- the peripheral devices connected to bus 100a include a HDD (Hard Disk Drive) 103, a GPU (Graphics Processing Unit) 104, an input interface 105, an optical drive device 106, device connection interfaces 107 and 108, and a network interface 109.
- HDD Hard Disk Drive
- GPU Graphics Processing Unit
- the HDD 103 is an auxiliary storage device for the classical computer 100.
- the HDD 103 magnetically writes and reads data to the built-in magnetic disk.
- the HDD 103 stores the OS program, application programs, and various data.
- the classical computer 100 may be equipped with other types of auxiliary storage devices, such as flash memory or an SSD (Solid State Drive), or may be equipped with multiple auxiliary storage devices.
- the monitor 21 is connected to the GPU 104.
- the GPU 104 displays images on the screen of the monitor 21 in accordance with commands from the CPU 101.
- the monitor 21 may be a display device using an organic EL (Electro Luminescence) display device or a liquid crystal display device.
- the input interface 105 is connected to the keyboard 22 and mouse 23.
- the input interface 105 transmits signals sent from the keyboard 22 and mouse 23 to the CPU 101.
- the mouse 23 is an example of a pointing device, and other pointing devices can also be used.
- Other pointing devices include a touch panel, a tablet, a touch pad, a trackball, etc.
- the optical drive device 106 uses laser light or the like to read data recorded on the optical disc 24.
- the optical disc 24 is a portable recording medium on which data is recorded so that it can be read by the reflection of light.
- Optical discs 24 include DVDs (Digital Versatile Discs), DVD-RAMs, CD-ROMs (Compact Disc Read Only Memory), and CD-Rs (Recordable)/RWs (ReWritable), etc.
- the device connection interface 107 is a communication interface for connecting peripheral devices to the classical computer 100.
- a memory device 25 or 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 the memory card 27 or reads data from the memory card 27.
- the memory card 27 is a card-type recording medium.
- the device connection interface 108 is a communication interface for connecting the quantum computer 200 to the classical computer 100.
- the classical computer 100 transmits instructions for controlling quantum bits to the quantum computer 200 via the device connection interface 108.
- the network interface 109 is connected to the network 20.
- the network interface 109 transmits and receives data to and from other computers or communication devices via the network 20.
- the classical computer 100 can realize the processing functions of the second embodiment with the hardware configuration described above.
- the quantum circuit design support device 10 shown in the first embodiment can also be realized with hardware similar to that of the classical computer 100 shown in FIG. 3.
- the CPU 101 is an example of the processing unit 12 shown in the first embodiment.
- the classical computer 100 realizes the processing functions of the second embodiment by executing a program recorded on, for example, a computer-readable recording medium.
- the program describing the processing to be executed by the classical computer 100 can be recorded on various recording media.
- the program to be executed by the classical computer 100 can be stored on the HDD 103.
- the CPU 101 loads at least a part of the program in the HDD 103 into the RAM 102 and executes the program.
- the program to be executed by the classical computer 100 can also be recorded on a portable recording medium such as the optical disk 24, memory device 25, or memory card 27.
- the program stored on the portable recording medium becomes executable after being installed on the HDD 103 under the control of, for example, the CPU 101.
- the CPU 101 can also read and execute the program directly from the portable recording medium.
- the classical computer 100 acquires from the terminals 31, 32, ... a quantum circuit that describes the procedure for gate operations of quantum bits for quantum computation.
- the quantum circuits acquired from the terminals 31, 32, ... include quantum gates that perform complex operations other than basic quantum gates.
- gate operations in the quantum computer 200 are limited to gate operations of basic quantum gates. Therefore, the classical computer 100 converts the quantum gates other than the basic quantum gates included in the quantum circuits acquired from the terminals 31, 32, ... into equivalent circuits that use basic quantum gates that can be executed by the quantum computer 200. The classical computer 100 then instructs the quantum computer 200 to perform quantum computation using the converted quantum circuits.
- the basic quantum gate varies depending on the system.
- the basic quantum gates include the Hadamard gate, the NOT gate, and the rotation gate.
- the basic quantum gates include the C-NOT gate and the controlled rotation gate.
- the basic quantum gate includes the C 2 -NOT gate.
- a frequently used quantum gate is the C k -NOT gate (k is an integer equal to or greater than 3).
- the C k -NOT gate is a quantum gate that inverts the "0/1" of a target bit when all k control bits are
- the gate operation of the C k -NOT gate can be replaced with an equivalent quantum circuit composed of a minimum number of C 2 -NOT gates depending on the number of clean auxiliary bits and dirty auxiliary bits.
- FIG. 4 is a diagram showing an example of conversion of a C 3 -NOT gate into an equivalent circuit.
- the C 3 -NOT gate 41 has three quantum bits, "c 1 " to "c 3 ", as control bits and a quantum bit, "x", as a target quantum bit.
- the C 3 -NOT gate 41 can be converted into an equivalent circuit 42 if clean auxiliary bits can be used.
- the equivalent circuit 42 is made up of three C 2 -NOT gates 42a to 42c.
- the C 3 -NOT gate 41 can be converted into an equivalent circuit 43 if clean auxiliary bits cannot be used but dirty auxiliary bits can be used.
- the equivalent circuit 43 is made up of four C 2 -NOT gates 43a to 43d.
- the C 3 -NOT gate 41 can be converted into three C 2 -NOT gates 42a to 42c. In contrast, if only dirty auxiliary bits can be used, the C 3 -NOT gate 41 will be converted into four C 2 -NOT gates 43a to 43d. In other words, if clean auxiliary bits can be used, the number of quantum gates in the quantum circuit after conversion can be reduced.
- FIG. 5 is a diagram showing an example of conversion of a C 4 -NOT gate into an equivalent circuit.
- the C 4 -NOT gate 44 has four quantum bits, "c 1 " to "c 4 ", as control bits and a quantum bit, "x", as a target quantum bit.
- the C 4 -NOT gate 44 can be converted into an equivalent circuit 45 if two clean auxiliary bits can be used.
- the equivalent circuit 45 is composed of five C 2 -NOT gates 45a to 45e.
- the C 4 -NOT gate 44 can be converted into an equivalent circuit 46 if one clean auxiliary bit and one dirty auxiliary bit can be used.
- the equivalent circuit 46 is composed of six C 2 -NOT gates 46a to 46f.
- the C 4 -NOT gate 44 can be converted into an equivalent circuit 47 if no clean auxiliary bit can be used and two dirty auxiliary bits can be used.
- the equivalent circuit 47 is made up of eight C 2 -NOT gates 47a to 47h.
- the C 4 -NOT gate 44 can be converted into five C 2 -NOT gates 45a to 45e. If only one clean auxiliary bit can be used, the C 4 -NOT gate 44 will be converted into six C 2 -NOT gates 46a to 46f. Furthermore, if only dirty auxiliary bits can be used, the C 4 -NOT gate 44 will be converted into eight C 2 -NOT gates 47a to 47h. In other words, the more clean auxiliary bits that can be used, the more the number of quantum gates in the quantum circuit after conversion can be reduced.
- FIG. 6 is a diagram showing an example of a quantum circuit using multiple C k -NOT gates.
- the quantum circuit 48 uses a large number of C k -NOT gates. In this case, if it is not known which quantum bit is clean, all the C k -NOT gates are converted into equivalent circuits with a large number of gates. As a result, the number of quantum gates in the entire quantum circuit after conversion increases significantly.
- quantum circuit 48 includes 11 C 2 -NOT gates, 16 C 3 -NOT gates, and 13 C 4 -NOT gates.
- the 16 C 3 -NOT gates are converted into 64 C 2 -NOT gates by equivalent circuit 43.
- the 13 C 4 -NOT gates are converted into 104 C 2 -NOT gates by equivalent circuit 47.
- a quantum circuit is generated that shows gate operations by 179 C 2 -NOT gates for 18 quantum bits.
- C k -NOT can be converted into an equivalent circuit 45 composed of a minimum number of C 2 -NOT gates if the required number of clean quantum bits can be added.
- FIG. 7 is a diagram showing an example of adding clean quantum bits to convert a C k -NOT gate.
- the quantum circuit 49 two clean quantum bits are added. If the added quantum bits are used as auxiliary bits, each C k -NOT can be converted into an equivalent circuit composed of a minimum number of C 2 -NOT gates. In this case, the number of quantum bits used to execute the quantum circuit increases because clean quantum bits are added. There is a limit to the number of quantum bits that can be used in a quantum computer. Therefore, if the number of quantum bits used increases, there is a possibility that the quantum computer cannot execute the quantum circuit after conversion.
- the 16 C 3 -NOT gates included in the quantum circuit 49 are converted into 48 C 2 -NOT gates by the equivalent circuit 42.
- the 13 C 4 -NOT gates are converted into 65 C 2 -NOT gates by the equivalent circuit 45.
- a quantum circuit is generated that shows gate operations by 124 C 2 -NOT gates for 20 quantum bits. In this way, if clean quantum bits are added as auxiliary bits, the number of quantum gates after conversion can be reduced, but the number of quantum bits increases. As a result, there is a risk that the quantum circuit cannot be executed due to a shortage of available quantum bits.
- a clean bit management function is introduced to the classical computer 100, and the classical computer 100 manages whether the state after each gate operation for each quantum bit used in the quantum circuit is clean or dirty.
- the initial state of each quantum bit is clean. Even if a quantum bit becomes dirty due to a subsequent gate operation, if a gate operation is performed that changes the state to
- FIG. 8 is a diagram showing an example of the state transition of a quantum bit. If the initial state of a quantum bit is
- a quantum circuit 51 is arranged with a C 7 -NOT gate 51a and six Hadamard gates 51b to 51g.
- the C 7 -NOT gate 51a has seven quantum bits, "c 1 " to "c 7 ", as control bits and a quantum bit, "x", as a target quantum bit. If the states of all the control bits are
- Hadamard gates 51b to 51f are arranged for the five quantum bits “a 1 " to “a 5 ", respectively. Furthermore, a Hadamard gate 51g is arranged for the quantum bit "a 1 ".
- the states of all quantum bits are clean. After the gate operations of the Hadamard gates 51b to 51f are performed on the five quantum bits “a 1 " to “a 5 ", the states of these five quantum bits “a 1 " to “a 5 " change from clean to dirty quantum bits. When the second gate operation of the Hadamard gate 51g is performed on the quantum bit "a 1 ", the state of the quantum bit “a 1 " changes from dirty to clean.
- quantum circuit 51 when the last C 7 -NOT gate 51a is converted into an equivalent circuit, the quantum bit “a 1 ” can be used as a clean auxiliary bit, and the quantum bits “a 2 ” to “a 5 ” can be used as dirty auxiliary bits.
- each quantum bit is initially clean, but becomes dirty when any gate operation is performed. Even if the quantum bit becomes dirty, if the same gate operation as before is performed again, the quantum bit will become clean.
- a SWAP gate is a quantum gate that performs an operation to exchange the states of two quantum bits. For example, one quantum bit operated by a SWAP gate may be in a clean state, while the other quantum bit may be in a dirty state. In this case, application of the SWAP gate changes the state of the clean quantum bit to dirty, and the state of the dirty quantum bit to clean.
- the classical computer 100 uses its clean bit management function to change a clean quantum bit to dirty when a quantum gate operation is performed in which a clean quantum bit is the target bit. Also, when a SWAP gate operation is performed, the classical computer 100 swaps the states of both quantum bits that are the target of the operation. Furthermore, when a process is performed to set a dirty quantum bit to
- the classical computer 100 can convert all C k -NOT gates appearing in the quantum circuit into optimal equivalent circuits according to the number of clean auxiliary bits and the number of dirty auxiliary bits without increasing the number of quantum bits. As a result, the calculation time in the quantum computer 200 can be reduced. This also applies when a quantum circuit simulator is used instead of the quantum computer 200.
- FIG. 9 is a block diagram showing an example of the functions of each device.
- the terminal 31 has a quantum circuit generation unit 31a.
- the quantum circuit generation unit 31a generates a quantum circuit described in a circuit description language according to input from a user.
- the quantum circuit generated by the quantum circuit generation unit 31a also uses quantum gates other than basic quantum gates.
- the quantum circuit generation unit 31a transmits the generated quantum circuit to the classical computer 100.
- the classical computer 100 has a quantum computation manager 110, a clean bit manager 120, and a quantum gate converter 130.
- the quantum computing management unit 110 manages the execution of quantum computation according to the quantum circuit sent from the terminal 31. For example, when the quantum circuit sent from the terminal 31 contains a quantum gate other than a basic quantum gate, the quantum computing management unit 110 instructs the quantum gate conversion unit 130 to convert the quantum gate into an equivalent circuit.
- the quantum computing management unit 110 also instructs the management of the state (clean/dirty) of each quantum bit after operation by each quantum gate in the quantum circuit.
- the quantum computing management unit 110 instructs the quantum computer 200 to perform quantum computation based on the quantum circuit. Then, the quantum computing management unit 110 obtains the computation result from the quantum computer 200 and outputs the computation result to the terminal 31.
- the clean bit manager 120 manages the state of the quantum bit that is being operated on in the quantum circuit. For example, the clean bit manager 120 interprets the operations performed by the quantum gates of the quantum circuit from the beginning, and determines whether the state of the operated quantum bit will be clean or dirty after the gate operation.
- the quantum gate conversion unit 130 converts quantum gates other than the basic quantum gates contained in the quantum circuit into an equivalent circuit using only the basic quantum gates. In doing so, the quantum gate conversion unit 130 obtains the state of each quantum bit immediately before executing the quantum gate to be converted from the clean bit management unit 120. The quantum gate conversion unit 130 then identifies clean quantum bits and dirty quantum bits that can be used as auxiliary bits, and converts the quantum gate to be converted into the smallest equivalent circuit that effectively uses these quantum bits.
- each element shown in FIG. 9 can be realized, for example, by causing a computer to execute a program module corresponding to that element.
- a procedure for performing quantum computation involving optimization of a quantum circuit will be described in detail.
- Step S101 The quantum computing manager 110 acquires a quantum circuit to be computed from one of the terminals 31, 32, .... Based on the acquired quantum circuit, the quantum computing manager 110 instructs the clean bit manager 120 to set information for clean bit management. The clean bit manager 120 then analyzes the specified quantum circuit and sets circuit information to be used for managing the clean bits.
- the circuit information to be set is, for example, the number of quantum bits n, the quantum circuit "QC", the initial state I, and cleaning information CI.
- the number of quantum bits n is the number of quantum bits that appear in the quantum circuit.
- the number of quantum bits n is the minimum number of quantum bits required to execute the input quantum circuit.
- a quantum circuit "QC" is information that lists ⁇ gate number, quantum gate configuration ⁇ in order.
- the quantum gate configuration is the type of quantum gate, the number of the quantum bit to be operated on, etc.
- "QC" is information such as [ ⁇ 1, Hadamard gate for the first quantum bit ⁇ , ⁇ 2, C 10 -NOT gate with 1st to 10th bits as control bits and 11th bit as the target bit ⁇ , ...].
- the initial state I is a set of clean quantum bit numbers. For example, if the 1st, 2nd, and 10th quantum bits are clean, the initial state I is ⁇ 1, 2, 10 ⁇ .
- the cleaning information CI is a set of identification numbers of quantum gates that make the state of the target bit clean when executed. For example, for the fifth quantum gate and the ninth quantum gate, if the state of the target bit after execution becomes clean, the cleaning information CI is ⁇ 5, 9 ⁇ . In the example of the quantum circuit 51 shown in FIG. 8, the identification number of the Hadamard gate 51g is set in the cleaning information CI.
- the quantum computing manager 110 and the clean bit manager 120 generate the initial state of the information used to optimize the quantum circuit.
- the clean bit manager 120 generates the initial state of the information used to manage the state changes of the quantum bits each time a gate operation is performed.
- the information used to manage the state changes of the quantum bits includes a list of clean quantum bits "cleanBitList”, a list of dirty quantum bits “dirtyBitList”, and the number of quantum gates "N" included in "QC".
- “N” is set to the maximum value of the quantum gate identification number shown in "QC”.
- the quantum gate conversion unit 130 determines whether the i-th quantum gate "QC[i]" of "QC" is to be converted into an equivalent circuit.
- Quantum gates to be converted into equivalent circuits are quantum gates other than basic quantum gates. If the quantum gate is to be converted into an equivalent circuit, the quantum gate conversion unit 130 proceeds to step S105. If the quantum gate is not to be converted into an equivalent circuit, the quantum gate conversion unit 130 proceeds to step S108.
- the quantum gate conversion unit 130 creates a temporary list of clean quantum bits, "tmpCleanBitList", and a temporary list of dirty quantum bits, "tmpDirtyBitList". For example, the quantum gate conversion unit 130 deletes the identification numbers of the control bit and target bit of QC[i] from "cleanBitList” to create “tmpCleanBitList”. The quantum gate conversion unit 130 also deletes the identification numbers of the control bit and target bit of QC[i] from "dirtyBitList" to create “tmpDirtyBitList”.
- the quantum gate conversion unit 130 performs a conversion process (quantum gate conversion) of QC[i] into an equivalent circuit of a quantum gate based on QC[i], "tmpCleanBitList", and "tmpDirtyBitList".
- the equivalent circuit obtained as a result of the quantum gate conversion is called "qc”. Details of the quantum gate conversion process will be described later (see FIG. 24).
- the clean bit manager 120 performs a clean bit update process in response to the gate operation of QC[i]. The details of the clean bit update process will be described later (see FIG. 11).
- the quantum computing manager 110 adds 1 to the variable “i” (i ⁇ i+1) and proceeds to step S103.
- the quantum computation manager 110 instructs the quantum computer 200 to execute quantum computation based on the quantum circuit.
- the quantum computation manager 110 acquires a computation result from the quantum computer 200 .
- the quantum computation manager 110 outputs the result of the quantum computation based on the quantum circuit.
- the quantum gate conversion unit 130 can correctly determine which quantum bits are clean when performing the gate operation of the quantum gate to be converted, and can convert to an equivalent circuit with a smaller number of quantum gates depending on the number of clean quantum bits.
- Fig. 11 is a flow chart showing an example of the procedure of the clean bit update process.
- the process shown in Fig. 11 will be explained below in order of step numbers. Note that in the process of Fig. 11, the quantum gate of QC[i] indicates the i-th quantum gate before conversion, even if QC[i] has been converted to the equivalent circuit "qc".
- Step S201 The clean bit manager 120 determines whether the quantum gate to be processed, QC[i], has been converted to the equivalent circuit "qc". If it has been converted, the clean bit manager 120 proceeds to step S204. If it has not been converted, the clean bit manager 120 proceeds to step S202.
- Step S202 The clean bit management unit 120 determines whether the quantum gate of QC[i] is a SWAP gate. If it is a SWAP gate, the clean bit management unit 120 proceeds to step S203. If it is not a SWAP gate, the clean bit management unit 120 proceeds to step S204.
- the clean bit manager 120 swaps the state of the quantum bit being operated on by the quantum gate being processed (SWAP gate). For example, if one of the identification numbers "j, k" of the quantum bit being operated on is included in “cleanBitList” and the other is included in "dirtyBitList", the clean bit manager 120 swaps the lists to which they belong.
- the clean bit manager 120 deletes the identification number ("j" or “k”) of the quantum bit to be operated on that is included in the "cleanBitList” from the “cleanBitList” and adds it to the "dirtyBitList”.
- the clean bit manager 120 also deletes the identification number ("j" or “k") of the quantum bit to be operated on that is included in the "dirtyBitList” from the "dirtyBitList” and adds it to the "cleanBitList”.
- the clean bit manager 120 ends the clean bit update process.
- Step S204 The clean bit manager 120 determines whether or not the condition that the identification number [j] of the target bit in the quantum gate of QC[i] is included in "cleanBitList" and is not included in the cleaning information CI is satisfied. If the condition is satisfied, the clean bit manager 120 proceeds to step S205. If the condition is not satisfied, the clean bit manager 120 proceeds to step S206.
- Step S205 The clean bit manager 120 deletes the identification number [j] of the target bit in the quantum gate of QC[i] from the "cleanBitList” and adds it to the "dirtyBitList”. After that, the clean bit manager 120 ends the clean bit update process.
- Step S206 The clean bit manager 120 determines whether the condition that the identification number [j] of the target bit in the quantum gate of QC[i] is included in "dirtyBitList" and also in the cleaning information CI is satisfied. If the condition is satisfied, the clean bit manager 120 proceeds to step S207. If the condition is not satisfied, the clean bit manager 120 ends the clean bit update process.
- Step S207 The clean bit manager 120 deletes the identification number [j] of the target bit in the quantum gate of QC[i] from the "dirtyBitList” and adds it to the "cleanBitList”. After that, the clean bit manager 120 ends the clean bit update process.
- Fig. 12 is a diagram showing an example of initial information setting by clean bit update processing. In the example of Fig. 12, it is assumed that quantum gates other than the basic quantum gates of the quantum circuit 48 shown in Fig. 6 are converted into equivalent circuits.
- the quantum circuit 48 is a circuit that adds "211" to the quantum bit string " q8 , ..., q0 " (binary notation) when both quantum bits " x1 " and " x2 " are
- seven clean quantum bits " c1 , ..., c7 " can be used as auxiliary bits.
- the number of quantum bits used in quantum circuit 48 is 18, and n is set to 18.
- cleanBitList ⁇ 4, 6, 8, 10, 12, 14, 16 ⁇
- dirtyBitList ⁇ 1, 2, 3, 5, 7, 9, 11, 13, 15, 17, 18 ⁇
- the “cleanBitList” and “dirtyBitList” are updated each time a quantum gate is converted into an equivalent circuit and converted into an equivalent circuit.
- a “tmpCleanBitList” is generated based on the "cleanBitList” at that time.
- the “tmpCleanBitList” indicates quantum bits that can be used as clean auxiliary bits in the equivalent circuit of the corresponding quantum gate.
- the “tmpDirtyBitList” is generated based on the "dirtyBitList”.
- the “tmpDirtyBitList” indicates quantum bits that can be used as dirty auxiliary bits in the equivalent circuit of the corresponding quantum gate.
- FIG. 13 shows an example of the state transition of tmpCleanBitList.
- the labels of each column in state transition table 52 for tmpCleanBitList indicate the quantum gate number.
- the labels of each row in state transition table 52 for "tmpCleanBitList" indicate quantum bits.
- the column corresponding to a quantum gate shows the state (clean or dirty) of the quantum bit before the operation by that quantum gate.
- a quantum bit set as "control” is the control bit of the corresponding quantum gate.
- a quantum bit set as "t” is the target bit of the corresponding quantum gate.
- a quantum bit set as "c” is a clean quantum bit, and the identification number of that quantum bit is included in "tmpCleanBitList”.
- a quantum bit with a blank setting is a dirty quantum bit, and the identification number of that quantum bit is included in "tmpDirtyBitList".
- the type of equivalent circuit to which the C k -NOT gate is converted is determined according to the number of clean bits that can be used.
- the C 2 -NOT gate does not require conversion.
- the quantum gates that do not require conversion are 11 in total: 3, 8, 12, 15, 19, 21, 26, 28, 35, 37, and 40.
- C 3 -NOT gates those that can use at least one clean bit as an auxiliary bit can be converted into an equivalent circuit 42 (see FIG. 4).
- the equivalent circuit 42 includes three quantum gates, the total number of quantum gates after conversion is 36 (12 x 3).
- C 4 -NOT gates those that can use at least two clean bits as auxiliary bits can be converted into an equivalent circuit 45 (see FIG. 5).
- the equivalent circuit 45 includes five quantum gates, the total number of quantum gates after conversion is 40 (5 x 8).
- the total number of basic quantum gates in the quantum circuit after the conversion is 179. That is, by managing the clean bits, the number of quantum gates in the quantum circuit is reduced from 179 to 139.
- FIG. 14 is a diagram showing an example of the correspondence between the number of available auxiliary bits and applicable conversion methods.
- Conversion method application table 60 shows applicable conversion methods according to the number of clean bits and the number of dirty bits.
- the horizontal axis of conversion method application table 60 is the number of available clean bits, and the vertical axis is the number of available dirty bits.
- the first conversion method is a conversion method capable of converting into an equivalent circuit with the smallest number of quantum gates.
- the first conversion method is a conversion method capable of converting a C k -NOT gate into 2k-3 C 2 -NOT gates using k-2 clean auxiliary bits.
- the first conversion method results in a smaller number of quantum gates after conversion than the other conversion methods described below.
- the first conversion method can only be applied when k-2 or more clean bits are available. Therefore, the quantum gate conversion unit 130 applies the first conversion method when k-2 clean auxiliary bits are available.
- the second conversion method is a conversion method that converts into an equivalent circuit using clean or dirty auxiliary bits.
- a C k -NOT gate can be converted into 4k-8 C 2 -NOT gates using k-2 auxiliary bits.
- all auxiliary bits can be applied even if they are dirty, and it is highly versatile.
- the auxiliary bits are insufficient, it is required to add quantum bits to be used as auxiliary bits until the auxiliary bits (the sum of clean bits and dirty bits) become k-2.
- the second conversion method increases the number of gates by 2k-5 compared to the first conversion method.
- the third conversion method is a conversion method that converts to an equivalent circuit using one auxiliary bit (clean bit or dirty bit).
- the third conversion method allows conversion with a small number of auxiliary bits.
- the number of gates increases by 4k to 6k compared to the first or second conversion method.
- the fourth conversion method is a conversion method that can compensate for the shortcomings of the first, second, and third conversion methods.
- the fourth conversion method is a conversion method that can convert into an equivalent circuit with a smaller number of quantum gates by effectively using available auxiliary bits when at least one clean bit is available.
- the fourth conversion method can be applied without adding auxiliary bits even when there are fewer than k-2 clean bits, and can compensate for the shortcomings of the first conversion method that uses k-2 or more clean bits.
- the fourth conversion method can also convert into an equivalent circuit with a smaller number of quantum gates than the second and third conversion methods, and can compensate for the shortcoming of the second and third conversion methods that the number of quantum gates is increased.
- the first conversion method can be used to convert to an equivalent circuit with the minimum number of quantum gates. Therefore, the fourth conversion method is effective when the number of clean bits c is "1 ⁇ c ⁇ k-3".
- the C 7 -NOT gate 61 has seven control bits. In this case, the number of clean bits used in the first conversion method is five. Therefore, four clean bits are insufficient. In other words, to convert the C 7 -NOT gate 61 using the first conversion method, four clean bits are added.
- an equivalent circuit 62 can be generated by the first conversion method. Sets of control bits are generated starting from the most significant control bit, and for each set, the result of the C 2 -NOT gate is set as the clean bit. The clean bit to which the operation result is set is also used as the control bit, and a similar gate operation is repeated. Then, the sixth C 2 -NOT gate performs the same operation as that by the C 7 -NOT gate 61 on the target bit.
- the latter five C 2 -NOT gates are quantum gates that clean the ancillary bits that were previously clean bits. Due to the presence of these C 2 -NOT gates, the equivalent circuit 62, including the state of the ancillary bits after the gate operation, becomes equivalent to the C 7 -NOT gate 61.
- 16 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate by the second conversion method.
- the second conversion method is applied to the C 7 -NOT gate 61, k-2 (5) auxiliary bits are used. Therefore, by treating the clean bits as equivalent to the dirty bits, the C 7 -NOT gate 61 can be converted into an equivalent circuit 63 by the second conversion method.
- the first five C 2 -NOT gates use a pair of an auxiliary bit (clean bit or dirty bit) and the control bit of the C 7 -NOT gate 61 as the control bit of the corresponding C 2 -NOT gate. There is no overlap in the control bits of the first five C 2 -NOT gates.
- the target bit of the first C 2 -NOT gate is the target bit of the C 7 -NOT gate 61.
- the target bits of the second to fifth C 2 -NOT gates are the auxiliary bits used as the control bit in the immediately preceding C 2 -NOT gate.
- the control bit of the sixth C 2 -NOT gate is the control bit of the C 7 -NOT gate 61 that is not used in the first five C 2 -NOT gates.
- the target of the sixth C 2 -NOT gate is the auxiliary bit used as the control bit in the fifth C 2 -NOT gate.
- the seventh to eleventh C 2 -NOT gates are the first to fifth C 2 -NOT gates arranged in reverse order.
- the twelfth to twentieth C 2 -NOT gates are the second to tenth C 2 -NOT gates arranged in reverse order.
- the eleventh C 2 -NOT gate in the equivalent circuit 63 performs the same operation on the target bit as the C 7 -NOT gate 61.
- the latter nine C 2 -NOT gates are quantum gates that restore the states of the ancillary bits.
- the presence of these C 2 -NOT gates makes the equivalent circuit 63 equivalent to the C 7 -NOT gate 61, including the states of the ancillary bits after the gate operation.
- FIG. 17 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate by the third conversion method.
- the third conversion method is applied to the C 7 -NOT gate 61, one auxiliary bit is used.
- an equivalent circuit 64 is generated in which the C 7 -NOT gate 61 is divided into four C 4 -NOT gates by using one auxiliary bit (a clean bit in the example of FIG. 17).
- an equivalent circuit 65 consisting of only C 2 -NOT gates is generated.
- the quantum gate conversion unit 130 therefore minimizes the number of gates by using as many of the given clean bits and dirty bits as possible.
- the quantum gate conversion unit 130 uses the fourth conversion method to convert to an equivalent circuit with a smaller number of quantum gates.
- the quantum gate conversion unit 130 adds a C 2 -NOT gate to the equivalent circuit, in which the two generated quantum bits are control bits and the clean bit is a target bit.
- the clean bit that becomes the target bit in the added C 2 -NOT gate is added to the control bit group C.
- the conversion method is the same as the first conversion method.
- Such a conversion policy is the basic policy of the fourth conversion method.
- the quantum gate conversion unit 130 gradually reduces the number of control bits of the C k -NOT gate 61. In this case, if the control bits are not appropriately grouped, the number of quantum gates in the quantum circuit after conversion cannot be sufficiently reduced.
- FIG. 19 is a diagram showing a first example of an equivalent circuit of a C 7 -NOT gate by the fourth conversion method when there are less than k-2 clean bits.
- the C 7 -NOT gate 61 is converted into an equivalent circuit 72 including two C 2 -NOT gates and one C 6 -NOT gate.
- the quantum gate conversion unit 130 divides the control bit group of the C k -NOT gate to be converted into a plurality of subgroups so that the second conversion method can be applied to the central C k -NOT gate after the division, thereby reducing the number of quantum gates in the equivalent circuit that is finally generated.
- FIG. 20 is a diagram showing a second example of an equivalent circuit of a C 7 -NOT gate by the fourth conversion method when there are less than k-2 clean bits.
- the C 7 -NOT gate 61 is converted into an equivalent circuit 72 including two C 3 -NOT gates 72a and 72c and one C 5 -NOT gate 72b.
- control bits ⁇ c 4 , c 5 , c 6 ⁇ can be used as dirty auxiliary bits, so the C 3 -NOT gate 72a can be converted into four C 2 -NOT gates using the second conversion method.
- control bits ⁇ c 1 , c 2 , c 3 ⁇ can be used as dirty auxiliary bits, so that the C 5 -NOT gate 72b can be converted into 12 C 2 -NOT gates using the second conversion method.
- control bits ⁇ c 4 , c 5 , c 6 ⁇ can be used as dirty auxiliary bits, so the C 3 -NOT gate 72c can be converted into four C 2 -NOT gates using the second conversion method.
- the central C k -NOT gate becomes a C 5 -NOT gate.
- the second conversion method can convert the C 7 -NOT gate into a total of 20 C 2 -NOT gates.
- the quantum gate conversion unit 130 divides the C k -NOT gate into 2c+1 quantum gates. At this time, the quantum gate conversion unit 130 determines c+1 integers "k 1 , ..., k c+1 ". The quantum gate conversion unit 130 divides it into C k_1 -NOT, ..., C k_c -NOT, C k_c+1 -NOT, C k_c -NOT, ..., C k_1 -NOT.
- the characters following the superscript k indicate the subscript of k. For example, the superscripts "k_1, ..., k_c+1" respectively represent the superscript integers "k 1 , ..., k c+1 ".
- the quantum gate conversion unit 130 determines an integer indicating the number of control bits of the quantum gate after division (number of control bits after division) so as to satisfy the following two conditions among those satisfying k 1 ⁇ k 2 ⁇ ... ⁇ k c , where k c+1 satisfies the following formula:
- the quantum gate conversion unit 130 can use the clean bits from (i+1) to (c) when converting a C k_i -NOT gate to a C 2 -NOT gate in 1 ⁇ i ⁇ c ⁇ 1. Also, when converting a C k_i -NOT gate in 1 ⁇ i ⁇ c ⁇ 1 to a C 2 -NOT gate, a sufficient number of dirty bits can be secured. Therefore, the above-mentioned "basic policy + second conversion method" can be applied.
- Condition 1 is a condition for ensuring as many clean bits as possible in the C k_i -NOT gates having many control bits.
- Condition 2 is a condition for using clean bits without excess or deficiency. If there exists 1 ⁇ i ⁇ j ⁇ c that satisfies k i >c-i+2 and k j ⁇ c-j+2, it can be confirmed that in the new division with k i ⁇ k i -1, k j ⁇ k j +1, the clean bits can be utilized more effectively than in the initial division, especially in the conversion of the C k_j -NOT gate.
- the quantum gate conversion unit 130 can reduce the number of quantum gates by four from the initial division by changing the number of control bits after division to k i ⁇ k i -1, k j ⁇ k j +1.
- a C 12 -NOT gate 73 is converted into an equivalent circuit 74.
- the C 3 -NOT gates 74a and 74e In the conversion to the equivalent circuit of the C 3 -NOT gates 74a and 74e, one clean bit can be used as an auxiliary bit.
- the fourth conversion method can be applied to the C 3 -NOT gates 74a and 74e. Therefore, the C 3 -NOT gates 74a and 74e can be converted to an equivalent circuit 42 (see FIG. 4) including three C 2 -NOT gates using a clean bit based on the basic principle of the fourth conversion method.
- one dirty bit In the conversion to the equivalent circuit of the C 3 -NOT gates 74b and 74d, one dirty bit can be used as an auxiliary bit. Therefore, the C 3 -NOT gates 74b and 74d can be converted to an equivalent circuit 43 (see FIG.
- the quantum gate conversion unit 130 can convert the C 12 -NOT gate 73 into an equivalent circuit including a total of 38 C 2 -NOT gates by converting each C k -NOT gate in the equivalent circuit 74 into an equivalent circuit.
- a C 12 -NOT gate 73 is converted into an equivalent circuit 75.
- each of the C 3 -NOT gates 75a and 75g can be converted into an equivalent circuit 42 (see FIG. 4) including three C 2 -NOT gates using the clean bit.
- six dirty bits can be used as auxiliary bits. Therefore, the C 8 -NOT gate 75d can be converted into 24 C 2 -NOT gates by the second conversion method.
- the quantum gate conversion unit 130 converts each C k -NOT gate in the equivalent circuit 75 into an equivalent circuit, thereby making it possible to convert the C 12 -NOT gate 73 into an equivalent circuit including a total of 34 C 2 -NOT gates.
- the quantum gate conversion unit 130 includes a quantum gate conversion management unit 131, a division method determination unit 132, and a quantum circuit generation unit 133.
- the quantum gate conversion management unit 131 cooperates with the division method determination unit 132 and the quantum circuit generation unit 133 to convert the input C k -NOT gate into an equivalent circuit "qc".
- information indicating a C k -NOT gate "tmpCleanBitList” and “tmpDirtyBitList”, are input to the quantum gate conversion management unit 131.
- c is the number of clean bits (where 1 ⁇ c ⁇ k-3).
- the division method determination unit 132 determines the number of control bits (k 1 , . . . , k c+1 ) of the quantum gates after division of the C k -NOT gates, so that the final number of C 2 -NOT gates is minimized, depending on the values of k, c, and d .
- the quantum circuit generation unit 133 receives the number of control bits (k 1 , . . . , k c+1 ) of the quantum gates after division determined by the division method determination unit 132, and outputs an equivalent circuit "qc" of the C k -NOT gate (consisting only of a C 2 -NOT gate).
- 24 is a flowchart showing an example of a procedure for quantum gate conversion processing. The processing shown in FIG. 24 will be described below in order of step numbers.
- Step S302 The quantum gate conversion management unit 131 instructs the quantum circuit generation unit 133 to generate a quantum circuit equivalent to the C k -NOT gate to be converted.
- the quantum circuit generation unit 133 generates an equivalent circuit "qc" of the C k -NOT gate to be converted by the third conversion method.
- the quantum gate conversion management unit 131 obtains the equivalent circuit "qc" from the quantum circuit generation unit 133, the process proceeds to step S307.
- Step S303 The quantum gate conversion management unit 131 determines whether the condition that the number of clean bits c is equal to or greater than k-2 (c ⁇ k-2) is satisfied. If the condition is satisfied, the quantum gate conversion management unit 131 advances the process to step S304. If the condition is not satisfied, the quantum gate conversion management unit 131 advances the process to step S305.
- Step S304 The quantum gate conversion management unit 131 instructs the quantum circuit generation unit 133 to generate a quantum circuit equivalent to the C k -NOT gate to be converted.
- the quantum circuit generation unit 133 generates an equivalent circuit "qc" of the C k -NOT gate to be converted by the first conversion method.
- the quantum gate conversion management unit 131 obtains the equivalent circuit "qc" from the quantum circuit generation unit 133, the process proceeds to step S307.
- the quantum gate conversion management unit 131 instructs the division method determination unit 132 to determine a division method.
- the division method determination unit 132 determines the number of post-division control bits of the C k_i -NOT gate obtained by dividing the C k -NOT gate according to the instruction.
- the quantum gate conversion management unit 131 obtains a set of integers indicating the number of post-division control bits from the division method determination unit 132. Details of the division method determination process will be described later (see FIG. 25).
- the quantum gate conversion management unit 131 instructs the quantum circuit generation unit 133 to generate a quantum circuit equivalent to the C k -NOT gate in the fourth conversion method.
- the quantum circuit generation unit 133 generates an equivalent circuit "qc" of the C k -NOT gate by the fourth conversion method.
- the quantum gate conversion management unit 131 obtains the equivalent circuit "qc" from the quantum circuit generation unit 133.
- the quantum gate conversion management unit 131 outputs the equivalent circuit "qc" as the equivalent circuit of the C k -NOT gate to be converted.
- the C k -NOT gate is converted into an equivalent circuit by the first conversion method.
- the applicable conversion method is limited to the third conversion method
- the C k -NOT gate is converted into an equivalent circuit by the third conversion method.
- the C k -NOT gate is converted into an equivalent circuit by the fourth conversion method.
- 25 is a flowchart showing an example of a division method determination process. The process shown in FIG. 25 will be described below in order of step number.
- the division method determination unit 132 determines whether to end the process based on whether the following formula (2) is satisfied.
- Equation (2) indicates a condition that the number of quantum bits usable as dirty auxiliary bits at the time of execution of the C k_c+1 -NOT gate is k c+1 -2 or more. This condition is an application condition of the second conversion method.
- the number of quantum bits usable as dirty auxiliary bits at the time of execution of the C k_c+1 -NOT gate is the sum of the number of elements included in the DA and the number of quantum bits used as control bits in each quantum gate from the C k_1 -NOT gate to the C k_c -NOT gate.
- the division method determination unit 132 advances the process to step S407. If the condition for the termination judgment is not satisfied, the division method determination unit 132 advances the process to step S404.
- Step S404 The division method determination unit 132 adds "1" to kj ( kj ⁇ kj +1). Also, the division method determination unit 132 subtracts "1" from kc+1 ( kc+1 ⁇ kc +1-1 ).
- Step S405 The division method determination unit 132 judges whether k j is equal to or greater than c-j+2 (k j ⁇ c-j+2?). If k j is equal to or greater than c-j+2, the division method determination unit 132 advances the process to step S406. If k j is less than c-j+2, the division method determination unit 132 advances the process to step S403.
- step S405 satisfies the above-mentioned condition 2 (there is no 1 ⁇ i ⁇ j ⁇ c such that k i >c-i+2 and k j ⁇ c-j+2 are satisfied).
- condition 2 there is no 1 ⁇ i ⁇ j ⁇ c such that k i >c-i+2 and k j ⁇ c-j+2 are satisfied.
- condition 2 is satisfied by the presence of step S405.
- condition 2 clean bits are effectively utilized, and the number of quantum gates after conversion to an equivalent circuit is reduced.
- Step S406 The division method determination unit 132 updates j to the value obtained by adding 1 to the remainder obtained by dividing j by c (j ⁇ (j mod c)+1). After that, the division method determination unit 132 proceeds to step S403.
- the division method determination unit 132 outputs " k1 , ..., kc+1 " and ends the division method determination process.
- the output " k1 , ..., kc+1 " indicates that the number of quantum gates after division is 2c+1, and the number of control bits for each gate is " k1 , ..., kc , kc+1 , kc , ..., k1 ".
- the number of control bits is determined for each of the divided C k_1 -NOT gates, C k_2 -NOT gates, ....
- the number of quantum gates in the finally generated equivalent circuit can be reduced.
- 26 is a flow chart showing an example of the procedure of an equivalent circuit generation process in the fourth conversion method. The process shown in FIG. 26 will be described below in order of step numbers.
- the quantum circuit generation unit 133 divides the C k -NOT gate according to a set of integers "k 1 , ..., k c , k c+1 " indicating the number of control bits after division. Through the division process, a C k_1 -NOT gate, ..., C k_c -NOT gate, C k_c+1 -NOT gate, ..., C k_c -NOT gate, ..., C k_1 -NOT gate are generated.
- the quantum circuit generation unit 133 sets the initial value of the variable i to “1”.
- Step S504 The quantum circuit generation unit 133 determines whether the value of the variable i is equal to or less than the number of clean bits c. If the value of the variable i is equal to or less than the number of clean bits c, the quantum circuit generation unit 133 proceeds to step S505. If the value of the variable i exceeds the number of clean bits c, the quantum circuit generation unit 133 proceeds to step S508.
- the quantum circuit generation unit 133 performs a process (C k_i -NOT gate conversion process) of converting the C k_i -NOT gate (the i-th quantum gate after division) into an equivalent circuit using a C 2 -NOT gate.
- the equivalent circuit generated by the conversion process is called "circ". Details of the C k_i -NOT gate conversion process will be described later (see Figures 27 and 28). Note that in the process of the C k_i -NOT gate conversion process, the quantum bit that has become the control bit in the C k_i -NOT gate is deleted from the list C of control bits.
- Step S506 The quantum circuit generation unit 133 adds the equivalent circuit "circ" to the equivalent circuit "qc”.
- Step S507 The quantum circuit generation unit 133 adds 1 to the variable i (i ⁇ i+1). After that, the quantum circuit generation unit 133 proceeds to step S504.
- the quantum circuit generation unit 133 generates a quantum circuit "qc inv " in which the quantum gates included in the equivalent circuit "qc" are arranged in reverse order.
- the quantum circuit generation unit 133 converts the C k_(c+1) -NOT gate, which is the central quantum gate after division, into an equivalent circuit using a C 2 -NOT gate by the second conversion method.
- the control bits of the C k_(c+1) -NOT gate are the quantum bits remaining in the control bit list C.
- the target bit of the C k_(c+1) -NOT gate is the same as the target bit x of the C k -NOT gate to be converted.
- the quantum circuit generation unit 133 uses the first two of the dirty bits included in DA as auxiliary bits to convert the Ck_(c+1) -NOT gate into an equivalent circuit by the second conversion method.
- the quantum circuit generation unit 133 names the equivalent circuit generated by the conversion "CIRC”.
- Step S510 The quantum circuit generation unit 133 adds the equivalent circuit "circ” generated in step S509 to the equivalent circuit "qc”.
- Step S511 The quantum circuit generation unit 133 adds the quantum circuit "qc inv " generated in step S508 to the equivalent circuit "qc”.
- each of the divided quantum gates is converted into an equivalent circuit composed only of C 2 -NOT gates, resulting in the generation of an equivalent circuit "qc" of the original C k -NOT gate to be converted.
- the quantum circuit generation unit 133 adds a C 2 -NOT gate to the equivalent circuit "circ", with the first two quantum bits of C (C[0], C[1]) as control bits and the i- th quantum bit of CA (CA[i]) as the target bit.
- Step S604 The quantum circuit generation unit 133 deletes the control bits (the first two quantum bits of C) in the C 2 -NOT gate added to the equivalent circuit "CIRC" from C. Then, the quantum circuit generation unit 133 adds these quantum bits to DA.
- Step S605 The quantum circuit generation unit 133 adds CA[i], which is the target bit in the C 2 -NOT gate added to the equivalent circuit "circ", to DA.
- Step S606 The quantum circuit generation unit 133 adds CA[i], which is the target bit in the C 2 -NOT gate added to the equivalent circuit "CIRC”, to C. After that, the quantum circuit generation unit 133 proceeds to step S627 (see FIG. 28).
- the quantum circuit generation unit 133 judges whether the value of j is equal to or less than i+p (j ⁇ i+p?). If the value of j is equal to or less than i+p, the quantum circuit generation unit 133 proceeds to step S613. If the value of j exceeds i+p, the quantum circuit generation unit 133 proceeds to step S618.
- the quantum circuit generation unit 133 adds a C 2 -NOT gate to the quantum circuit “qc tmp1 ”, which has the first two quantum bits of C tmp (C tmp [0], C tmp [1]) as control bits and the jth quantum bit of CA ( CA [j]) as a target bit.
- the quantum circuit generation unit 133 adds the control bits (C tmp [0], C tmp [1]) of the C 2 -NOT gate added to the quantum circuit “qc tmp1 ” to DA tmp .
- the quantum circuit generation unit 133 deletes the control bits (C tmp [0], C tmp [1]) of the C 2 -NOT gate added to the quantum circuit “qc tmp1 ” from C tmp .
- Step S616 The quantum circuit generation unit 133 adds the target bit (CA[j]) of the C 2 -NOT gate added to the quantum circuit “qc tmp1 ” to C tmp .
- Step S617 The quantum circuit generation unit 133 adds 1 to the value of j (j ⁇ j+1). After that, the quantum circuit generation unit 133 proceeds to step S612.
- Step S618 The quantum circuit generation unit 133 sets k i -p to L (L ⁇ k i -p). After that, the quantum circuit generation unit 133 proceeds to step S621 (see FIG. 28).
- Step S622 The quantum circuit generation unit 133 sets a C 2 -NOT gate in which the first two quantum bits of C tmp (C tmp [0], C tmp [1]) are set as control bits and the i-th quantum bit of CA (CA[i]) is set as a target bit, as an equivalent circuit "qc tmp2 ". After that, the quantum circuit generation unit 133 proceeds to step S624.
- the quantum circuit generation unit 133 converts a C L -NOT gate, which has the quantum bit of C tmp as the control bit and the i-th quantum bit of CA as the target bit, into an equivalent circuit by the second conversion method with the first L-2 bits of DA tmp as dirty bits.
- the quantum circuit generation unit 133 outputs the equivalent circuit "qc tmp2 " obtained by the conversion.
- the quantum circuit generation unit 133 generates a quantum circuit "qc tmp1_inv " by arranging the C 2 -NOT gates in the quantum circuit "qc tmp1 " in reverse order.
- the quantum circuit generation unit 133 adds "qc tmp1 ", "qc tmp2 ", and "qc tmp1_inv " to the equivalent circuit "circ”.
- the quantum circuit generation unit 133 deletes k i elements from the beginning of C.
- the quantum circuit generation unit 133 also adds to DA the elements deleted from C. Furthermore, the quantum circuit generation unit 133 adds to C the i-th element of CA (CA[i]).
- Step S627 The quantum circuit generation unit 133 outputs the equivalent circuit “circ”.
- each of the quantum circuits (C k_1 -NOT gate, ..., C k_c -NOT gate) for the number of clean bits is converted into an equivalent circuit combining C 2 -NOT gates, and the converted equivalent circuit is added to the equivalent circuit "CIRC”.
- 29 is a diagram showing an example of conversion of a C k -NOT gate.
- the quantum circuit generation unit 133 generates a quantum circuit "qc inv " in which the quantum gates included in "qc" are arranged in reverse order. In the example of FIG. 29, only the C 2 -NOT gate 76c is included in "qc inv ".
- an equivalent circuit 76 of the C 2 -NOT gate 61 is output.
- the number of quantum bits of the output equivalent circuit 76 is "13", and the number of gates is "18".
- the fourth conversion method requires a smaller number of quantum bits.
- the second conversion method number of quantum bits: "13", number of quantum gates: "20" shown in FIG. 16
- the fourth conversion method requires a smaller number of quantum gates.
- the third conversion method number of quantum bits: "13", number of quantum gates: "32" shown in FIG. 17
- the fourth conversion method requires a smaller number of quantum gates.
- the number of quantum gates for conversion can be reduced without increasing the number of quantum bits used by applying the fourth conversion method in the same manner. For example, assume that the C 12 -NOT gate 73 shown in FIG. 21 is converted.
- the number of quantum gates in the equivalent circuit after conversion varies depending on the number of clean bits "c" and the number of dirty bits "d" that can be used.
- the C 12 -NOT gate 73 can be converted into an equivalent circuit of 72 C 2 -NOT gates by the third conversion method, and if d ⁇ k-3, it can be converted into an equivalent circuit of 40 C 2 -NOT gates by the second conversion method.
- the quantum gate conversion unit 130 can convert the C k -NOT gate into a combination of the minimum number of C 2 -NOT gates possible.
- quantum computation based on a quantum circuit is executed by the quantum computer 200, but it is also possible to execute quantum computation by quantum simulation using a classical computer.
- a classical computer capable of executing quantum simulation is used instead of the quantum computer 200.
- the classical computer 100 shown in the second embodiment may execute the quantum simulation.
- the quantum computer 200 can perform gate operations of the C 2 -NOT gate, but there may be cases where the quantum computer 200 cannot perform gate operations of the C 2 -NOT gate.
- the classical computer 100 converts the C 2 -NOT gate into an equivalent circuit that further combines other basic quantum gates. Even in this case, as shown in the first and second embodiments, the number of gates in the quantum circuit that is finally generated can be reduced by converting the C k -NOT gate into a C 2 -NOT gate with a smaller number of quantum gates in advance.
- the equivalent circuit includes a quantum circuit for returning the state of the auxiliary bit (clean bit or dirty bit) to the state before use. If it is known that the auxiliary bit does not need to be restored, it is also possible to exclude the quantum circuit for returning it to the state before use from the equivalent circuit. A case in which the auxiliary bit does not need to be restored is, for example, when the auxiliary bit is not the object of measurement and the subsequent state of the auxiliary bit does not affect the quantum bit that is the object of measurement. By excluding the quantum circuit for returning the auxiliary bit to the state before use from the equivalent circuit, the number of quantum gates can be reduced.
Landscapes
- Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Mathematical Analysis (AREA)
- Data Mining & Analysis (AREA)
- Evolutionary Computation (AREA)
- Condensed Matter Physics & Semiconductors (AREA)
- Computational Mathematics (AREA)
- Mathematical Optimization (AREA)
- Pure & Applied Mathematics (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Mathematical Physics (AREA)
- Software Systems (AREA)
- Artificial Intelligence (AREA)
- Logic Circuits (AREA)
Abstract
Description
本発明は、量子回路設計支援プログラム、量子回路設計支援方法および量子回路設計支援装置に関する。 The present invention relates to a quantum circuit design support program, a quantum circuit design support method, and a quantum circuit design support device.
量子コンピュータまたは量子コンピュータシミュレータ(以下、量子シミュレータ)に実行させる量子計算の内容は量子回路で表される。量子回路は、さまざまな種類の量子ゲートを組み合わせた量子計算モデルである。量子ゲートは、量子ビットの状態を書き換える操作を示している。量子回路に用いる量子ゲートには基本量子ゲートとそれ以外のものがある。基本量子ゲートは、量子コンピュータに実行させることができる量子ゲートである。 The quantum computations to be executed by a quantum computer or quantum computer simulator (hereafter referred to as quantum simulator) are represented by quantum circuits. A quantum circuit is a quantum computation model that combines various types of quantum gates. A quantum gate represents an operation that rewrites the state of a quantum bit. There are basic quantum gates and other types of quantum gates used in quantum circuits. Basic quantum gates are quantum gates that can be executed by a quantum computer.
量子回路を作成する場合、まず量子回路記述言語を用いて、目的の問題を解くためのゲート操作手順を示す量子回路が生成される。量子回路記述言語で生成された量子回路には、基本量子ゲート以外の複雑な操作を行う量子ゲートも使用される。そこで古典コンピュータによって、量子回路に含まれる基本量子ゲート以外の量子ゲートが、基本量子ゲートを組み合わせた等価な量子回路(等価回路)に変換される。これにより、基本量子ゲートのみで記述した量子回路が生成される。 When creating a quantum circuit, a quantum circuit is first generated using a quantum circuit description language, which shows the gate operation procedures required to solve the target problem. Quantum circuits generated using the quantum circuit description language also use quantum gates that perform complex operations other than basic quantum gates. A classical computer then converts the quantum gates included in the quantum circuit, other than the basic quantum gates, into an equivalent quantum circuit (equivalent circuit) that combines basic quantum gates. This generates a quantum circuit described only with basic quantum gates.
なお、基本量子ゲート以外の量子ゲートを、基本量子ゲートを組み合わせた等価回路に変換すると、量子ゲートの数が増加する。量子回路内の量子ゲートの数が増加すると、量子コンピュータまたは量子シミュレータによる量子計算の効率が低下する。また量子コンピュータでは、量子ビットが量子状態を維持できる時間には限りがある。そのため、量子回路の基本量子ゲート数が少ない方が量子計算に成功する確率が高くなる。これらのことから、基本量子ゲート以外の量子ゲートを等価回路に変換する場合、より少ない基本量子ゲートを用いた等価回路に変換することが望まれる。 In addition, when quantum gates other than basic quantum gates are converted into an equivalent circuit that combines basic quantum gates, the number of quantum gates increases. As the number of quantum gates in a quantum circuit increases, the efficiency of quantum computation by a quantum computer or quantum simulator decreases. Also, in a quantum computer, there is a limit to the time that a quantum bit can maintain a quantum state. Therefore, the probability of successful quantum computation increases when the number of basic quantum gates in a quantum circuit is reduced. For these reasons, when converting quantum gates other than basic quantum gates into an equivalent circuit, it is desirable to convert them into an equivalent circuit that uses fewer basic quantum gates.
量子回路に関する技術としては、例えば特定の問題を解決する際の量子コンピュータの固有の利点に基づいて、その強みを効率的に費用対効果良く活用するように量子コンピュータをプログラミングするための量子回路の最適化に関する技術が提案されている。また、量子計算で期待されるサイズとタイプの量子回路を最適化するための自動化技術において、連続的なゲートパラメータを処理する方法も提案されている。また訓練後の量子ニューラルネットワークが双方向量子テレポーテーションとなるようにする訓練方法も提案されている。さらに、量子ビットの値の初期レイアウトに適用される、量子ゲートの順序付けられたシリーズの量子回路を最適化するための方法も提案されている。 Technologies related to quantum circuits have been proposed, for example, for optimizing quantum circuits to program quantum computers in a way that efficiently and cost-effectively exploits their inherent advantages in solving specific problems. Methods have also been proposed for handling continuous gate parameters in automated techniques for optimizing quantum circuits of the size and type expected for quantum computing. Training methods have also been proposed for training quantum neural networks such that, after training, they are capable of bidirectional quantum teleportation. Methods have also been proposed for optimizing quantum circuits for an ordered series of quantum gates that are applied to an initial layout of qubit values.
基本量子ゲート以外の量子ゲートを等価回路に変換する技術として、補助の量子ビット(補助ビット)を使用する技術がある。補助ビットには、状態が所定の値(例えば|0>)であることがわかっている量子ビット(cleanな補助ビット)と、所定の値であるか否か不明な量子ビット(dirtyな補助ビット)とがある。使用可能なcleanな補助ビットの数が多ければ、基本量子ゲート以外の量子ゲートをより少ない量子ゲートの量子回路に変換できる。 One technique for converting quantum gates other than basic quantum gates into equivalent circuits is the use of auxiliary quantum bits (auxiliary bits). There are two types of auxiliary bits: quantum bits whose state is known to be a specified value (for example, |0>) (clean auxiliary bits), and quantum bits whose state is unknown (dirty auxiliary bits). If there are a large number of clean auxiliary bits available, quantum gates other than basic quantum gates can be converted into quantum circuits with fewer quantum gates.
しかし、従来は、複数の量子ゲートで構成される量子回路に応じた量子計算過程において、各量子ビットがゲート操作後にcleanとなるかdirtyとなるかを把握する技術がない。そのため基本量子ゲート以外の量子ゲートを等価回路に変換することで生成される量子回路のゲート数の削減が困難となっている。 However, until now, there has been no technology to determine whether each quantum bit will be clean or dirty after a gate operation in a quantum computation process corresponding to a quantum circuit composed of multiple quantum gates. This makes it difficult to reduce the number of gates in a quantum circuit generated by converting quantum gates other than basic quantum gates into an equivalent circuit.
1つの側面では、本件は、量子計算過程で量子ビットが所定の値となるか否かを把握できるようにすることを目的とする。 In one aspect, the present invention aims to make it possible to determine whether a quantum bit becomes a predetermined value during a quantum computing process.
1つの案では、以下の処理をコンピュータに実行させる量子回路設計支援プログラムが提供される。
コンピュータは、量子回路におけるゲート操作の順番が早い量子ゲートから順に判定対象とし、量子回路により操作される複数の量子ビットそれぞれが初期状態で所定の値か否かを示す初期値情報に基づいて、判定対象の量子ゲートによる操作対象の量子ビットがゲート操作後に所定の値となるか否かを判定する。そしてコンピュータは、判定対象の量子ゲートごとに、判定対象の量子ゲートによるゲート操作後に所定の値になっている量子ビットを特定する。
In one proposal, a quantum circuit design support program is provided that causes a computer to execute the following processes.
The computer determines whether the quantum bit to be operated by the quantum gate to be determined will have a predetermined value after the gate operation based on initial value information indicating whether each of the multiple quantum bits operated by the quantum circuit has a predetermined value in the initial state.The computer then identifies, for each quantum gate to be determined, the quantum bit that has become the predetermined value after the gate operation by the quantum gate to be determined.
1態様によれば、量子計算過程で量子ビットが所定の値となるか否かを把握することができる。
本発明の上記および他の目的、特徴および利点は本発明の例として好ましい実施の形態を表す添付の図面と関連した以下の説明により明らかになるであろう。
According to one aspect, it is possible to know whether or not a quantum bit becomes a predetermined value during a quantum computation process.
The above and other objects, features and advantages of the present invention will become apparent from the following description taken in conjunction with the accompanying drawings illustrating preferred embodiments of the present invention.
以下、本実施の形態について図面を参照して説明する。なお各実施の形態は、矛盾のない範囲で複数の実施の形態を組み合わせて実施することができる。
〔第1の実施の形態〕
第1の実施の形態は、量子計算過程で量子ビットが所定の値となるか否かを把握することで量子回路の設計を支援する量子回路設計支援方法である。
Hereinafter, the present embodiment will be described with reference to the drawings. Note that each embodiment can be implemented in combination with a plurality of other embodiments as long as no contradiction occurs.
First Embodiment
The first embodiment is a quantum circuit design support method that supports the design of a quantum circuit by determining whether or not a quantum bit becomes a predetermined value during a quantum computation process.
図1は、第1の実施の形態に係る量子回路設計支援方法の一例を示す図である。図1には、量子回路設計支援方法を実現する量子回路設計支援装置10が示されている。量子回路設計支援装置10は、例えば量子回路設計支援プログラムを実行することにより、量子回路設計支援方法を実施することができる。
FIG. 1 is a diagram showing an example of a quantum circuit design support method according to a first embodiment. FIG. 1 shows a quantum circuit
量子回路設計支援装置10は、記憶部11と処理部12とを有する。記憶部11は、例えば量子回路設計支援装置10が有するメモリまたはストレージ装置である。処理部12は、例えば量子回路設計支援装置10が有するプロセッサまたは演算回路である。
The quantum circuit
記憶部11は、量子コンピュータまたは量子シミュレータに実行させる量子回路1aと、量子回路1aにより操作される複数の量子ビットそれぞれが初期状態で所定の値か否かを示す初期値情報1bとを記憶する。量子回路1aには複数の量子ゲート2~6が含まれる。図1の例では、量子回路1aで操作する量子ビット数は7個である。
The
量子回路1aには、X-1回目(Xは自然数)のゲート操作として、量子ゲート2~4に応じたゲート操作を行うことが示されている。量子ゲート2~4それぞれは、5番目から7番目の量子ビットを操作対象とするアダマールゲートである。また量子回路1aには、X回目のゲート操作として、量子ゲート5に応じたゲート操作を行うことが示されている。量子ゲート5は、5番目の量子ビットに対するアダマールゲートである。さらに量子回路1aには、X+1回目のゲート操作として、量子ゲート6に応じたゲート操作を行うことが示されている。量子ゲート6は、1番目から3番目までの量子ビットを制御ビットとし、4番目の量子ビットをターゲットビットとするC3-NOTゲートである。
In the
C3-NOTゲートは、3つの制御ビットがすべて|1>の場合にコントロールビットを反転させる量子ゲートである。Cの上付きの添字が制御ビット数を表している。このような量子ゲートは、MPMCT(Mixed-Polarity Multiple-Control Toffoli)と呼ばれる。 The C 3 -NOT gate is a quantum gate that inverts a control bit when all three control bits are |1>. The superscript of C indicates the number of control bits. This type of quantum gate is called MPMCT (Mixed-Polarity Multiple-Control Toffoli).
処理部12は、量子回路1aと、量子回路1aで操作する複数の量子ビットそれぞれの初期状態とに基づいて、量子回路1aに含まれる第1の量子ゲートによる操作対象の量子ビットへのゲート操作後に操作対象の量子ビットが所定の値となるか否かを判定する。複数の量子ビットそれぞれの初期状態は、例えばすべての量子ビットの値が|0>であるという状態である。また、操作対象の量子ビットについての所定の値とは、例えば|0>である。
The
処理部12は、例えば量子回路1aにおけるゲート操作の順番が早い量子ゲートから順に判定対象とし、初期値情報1bに基づいて、操作対象の量子ビットへのゲート操作後に操作対象の量子ビットが所定の値となるか否かを判定する。
The
さらに処理部12は、判定対象の量子ゲートごとに、判定対象の量子ゲートによるゲート操作後に所定の値になっている量子ビットを特定する。例えば処理部12は、特定した量子ビットのリストを生成する。具体的には処理部12は、判定対象の量子ゲートによる操作対象の量子ビットがゲート操作後に所定の値となるか否か、および操作対象の量子ビット以外の量子ビットがゲート操作前に所定の値であるか否かに基づいて、リストを生成する。すなわち処理部12は、判定対象の量子ゲートによるゲート操作前から所定の値であり、判定対象の量子ゲートでの操作対象外の量子ビットの識別番号を、判定対象の量子ゲートに対応するリストに含める。また処理部12は、判定対象の量子ゲートに応じたゲート操作により所定の値になる量子ビットの識別番号を、判定対象の量子ゲートに対応するリストに含める。さらに処理部12は、判定対象の量子ゲートに応じたゲート操作後に所定の値になるか否かが不明な量子ビットの識別番号を、判定対象の量子ゲートに対応するリストから除外する。
Furthermore, for each quantum gate to be judged, the
このように、量子ゲートごとに、その量子ゲートによるゲート操作後に所定の値となる量子ビットのリストを生成することができる。例えば処理部12は、値が|0>の量子ビットのリストが生成されることで、値が|0>の量子ビットを補助ビットとして有効に利用して、次に実行する量子ゲートを、より少ないゲート数の等価回路に変換することができる。すなわち処理部12は、量子回路1aを、量子コンピュータまたは量子シミュレータに実行させることが可能な量子回路に変換する際に、変換後の量子回路の量子ゲート数を削減することができる。その結果、量子コンピュータまたは量子シミュレータは、効率的な量子計算が可能となる。
In this way, for each quantum gate, a list of quantum bits that will become a predetermined value after gate operation by that quantum gate can be generated. For example, by generating a list of quantum bits whose value is |0>, the
処理部12は、例えば判定対象の量子ゲートによるゲート操作が、操作対象の量子ビットの状態を所定の値に変更するゲート操作である場合、ゲート操作後には操作対象の量子ビットが所定の値になると判定する。また処理部12は、判定対象の量子ゲートによるゲート操作が、操作対象の量子ビットの状態を所定の値に変更する操作以外の操作の場合、ゲート操作後に所定の値になるかが不明であると判定する。例えばユーザは、処理部12に対して、操作対象の量子ビットの状態を所定の値に変更するゲート操作を示す量子ゲートを予め指定する。処理部12は、指定された量子ゲートのゲート操作について、操作対象の量子ビットの状態を所定の値に変更するゲート操作であると判定する。
For example, if the gate operation by the quantum gate to be judged is a gate operation that changes the state of the quantum bit to be manipulated to a predetermined value, the
また処理部12は、例えば判定対象の量子ゲートがスワップ(SWAP)ゲートの場合、SWAPゲートの操作対象の2つの量子ビットの状態が入れ替わると判断する。すなわち処理部12は、SWAPゲートの操作対象の第1の量子ビットが、判定対象の量子ゲートによるゲート操作前に所定の値である場合、操作対象の第2の量子ビットは、ゲート操作後には所定の値になると判定する。この場合、処理部12は、リストに第2の量子ビットを含める。
Furthermore, for example, when the quantum gate to be judged is a SWAP gate, the
また処理部12は、SWAPゲートの操作対象の第1の量子ビットが、判定対象の量子ゲートによるゲート操作前に所定の値であるかが不明な場合、操作対象の第2の量子ビットは、ゲート操作後には所定の値になるかは不明であると判定する。この場合、処理部12は、リストから第2の量子ビットを除外する。
Furthermore, when it is unclear whether the first quantum bit to be operated by the SWAP gate has a predetermined value before the gate operation by the quantum gate to be determined, the
このようにして、処理部12は、量子回路1aにSWAPゲートが含まれる場合にも、SWAPゲートによるゲート操作後に所定の値となる量子ビットのリストを適切に生成することができる。
In this way, even if the
生成されたリストは、例えば、複雑な量子ゲートを、基本量子ゲートで構成される等価回路に変換する処理に利用できる。例えば処理部12は、第1の量子ゲートを判定対象の量子ゲートとしたときに生成されたリストに基づいて、第1の量子ゲートのゲート操作後に所定の値である第3の量子ビットを特定する。そして処理部12は、第1の量子ゲートの次に実行する第2の量子ゲートを、第3の量子ビットを利用した、第2の量子ゲートと等価な量子回路に変換する。これにより、所定の値の量子ゲートを補助ビットとして利用でき、第2の量子ゲートが、量子ゲート数の少ない等価回路に変換される。
The generated list can be used, for example, in a process of converting a complex quantum gate into an equivalent circuit composed of basic quantum gates. For example, the
図1に示す量子回路1aでは、X-2回目のゲート操作後の段階で、状態が所定の値|0>である量子ビットは、4番目から7番目の量子ビットであるものとする。この場合、X-2回目のゲート操作後の段階で、1番目から3番目の量子ビットは、|0>であるか否かは不明である。
In
X-2回目のゲート操作後の|0>の量子ビットのリストは{4,5,6,7}である。量子回路1aでは、X-1回目のゲート操作として、量子ゲート2~4(アダマールゲート)によるゲート操作が行われる。量子ゲート2~4の操作が行われる5番目から7番目の量子ビットは、ゲート操作後に値が|0>であるかが不明となる。そこでX-2回目のゲート操作後のリスト{4,5,6,7}から、{5,6,7}が除外される。その結果、X-1回目のゲート操作後の|0>の量子ビットのリストは{4}となる。
The list of |0> quantum bits after the X-2th gate operation is {4, 5, 6, 7}. In
量子回路1aでは、X回目のゲート操作として、量子ゲート5(アダマールゲート)によるゲート操作が行われる。この場合、5番目の量子ビットには、|0>からアダマールゲートのゲート操作が2回行われたこととなる。その結果、5番目の量子ビットは、量子ゲート5のゲート操作により|0>に戻る。そこでX回目のゲート操作後のリスト{4}に{5}が追加される。その結果、X回目のゲート操作後の|0>の量子ビットのリストは{4,5}となる。
In
X+1回目のゲート操作では、量子ゲート(C3-NOTゲート)のゲート操作が行われる。多くの場合、C3-NOTゲートは基本量子ゲートではない。そこで、C3-NOTゲートは、C2-NOTゲートを組み合わせた等価回路に変換される。C3-NOTゲートの等価回路への変換では、補助ビットとして|0>の量子ビットが使用できれば、値が不明の量子ビットを補助ビットとして使用する場合よりも少ない量子ゲート数の等価回路に変換可能である。処理部12は、X回目のゲート操作後の|0>の量子ビットのリスト{4,5}を生成しているため、5番目の量子ビットが|0>であることを認識し、その量子ビットを補助ビットとして使用することができる。その結果、処理部12は、量子ゲート6を、最小の量子ゲート数の等価回路に変換できる。
In the X+1th gate operation, a quantum gate (C 3 -NOT gate) is operated. In many cases, the C 3 -NOT gate is not a basic quantum gate. Therefore, the C 3 -NOT gate is converted into an equivalent circuit that combines C 2 -NOT gates. In the conversion to an equivalent circuit of the C 3 -NOT gate, if a quantum bit of |0> can be used as an auxiliary bit, it is possible to convert it into an equivalent circuit with fewer quantum gates than when a quantum bit with an unknown value is used as an auxiliary bit. Since the
なおX+1回目のゲート操作において、ターゲットビットとなっている4番目の量子ビットは、X+1回目のゲート操作後には値が|0>か否かは不明となる。そこでX回目のゲート操作後のリスト{4,5}から{4}が削除される。その結果、X+1回目のゲート操作後の|0>の量子ビットのリストは{5}となる。 In addition, in the X+1th gate operation, it is unclear whether the value of the fourth quantum bit, which is the target bit, is |0> after the X+1th gate operation. Therefore, {4} is deleted from the list {4, 5} after the Xth gate operation. As a result, the list of quantum bits with |0> after the X+1th gate operation becomes {5}.
〔第2の実施の形態〕
第2の実施の形態は、量子回路における複雑なゲート操作を行う量子ゲートを基本量子ゲートに変換して、基本量子ゲートのみで構成された量子回路に従った量子計算を量子コンピュータに実行させるコンピュータシステムである。以下、値が|0>であることが分かっている量子ビットを、cleanな量子ビットまたはcleanビットと呼ぶ。また、値が|0>であるか否かが不明な量子ビットを、dirtyな量子ビットまたはdirtyビットと呼ぶ。
Second Embodiment
The second embodiment is a computer system that converts a quantum gate that performs complex gate operations in a quantum circuit into a basic quantum gate and causes a quantum computer to execute quantum calculations according to a quantum circuit composed only of basic quantum gates. Hereinafter, a quantum bit whose value is known to be |0> is called a clean quantum bit or clean bit. Also, a quantum bit whose value is unknown whether it is |0> or not is called a dirty quantum bit or dirty bit.
図2は、第2の実施の形態のシステム構成の一例を示す図である。当該システムは、古典コンピュータ100と量子コンピュータ200とを有する。古典コンピュータ100には、ネットワーク20を介して端末31,32,・・・が接続されている。端末31,32,・・・は、量子コンピュータ200による量子計算を依頼するユーザが使用するコンピュータである。古典コンピュータ100は、端末31,32,・・・から量子回路を受け付ける。量子回路は、ゲートなどの要素の配置によって量子ビットへの操作の順序を示すものである。量子ビットは、|0>の状態と|1>の状態との重ね合わせの状態を表現することが可能なビットである。
FIG. 2 is a diagram showing an example of a system configuration of the second embodiment. The system includes a
古典コンピュータ100は、端末31,32,・・・から受け付けた量子回路を、量子コンピュータ200で実行可能な量子回路に変換する。量子コンピュータ200で実行可能な量子回路は、例えば基本量子ゲートのみで記述された量子回路である。古典コンピュータ100は、変換後の量子回路の実行を量子コンピュータ200に指示する。また、古典コンピュータ100は、量子コンピュータ200から各量子ビットの測定結果を取得する。
The
量子コンピュータ200は、複数の量子ビットと複数の量子ビットそれぞれを操作するための装置を有する。量子コンピュータ200が有する複数の量子ビットは、例えば超伝導方式であってもよいし、イオントラップ方式であってもよい。また複数の量子ビットは、ダイヤモンドスピン方式であってもよい。量子ビットが超伝導方式の場合、量子コンピュータ200は、量子ビットを冷却するための冷凍機を有していてもよい。
量子コンピュータ200は、例えば古典コンピュータ100からの指示に応じて、量子ビットにマイクロ波を照射する。また、複数の量子ビットそれぞれを操作するための装置は、複数の量子ビットそれぞれの状態を測定し、古典コンピュータ100に送信する。
The
図3は、古典コンピュータのハードウェアの一構成例を示す図である。古典コンピュータ100は、CPU(Central Processing Unit)101によって装置全体が制御されている。CPU101は、プログラムの命令を実行するプロセッサである。なお、CPU101は複数のプロセッサコアを含んでもよい。また、CPU101は、複数のプロセッサであってもよく、MPU(Micro Processing Unit)、またはDSP(Digital Signal Processor)等であってもよい。また、CPU101がプログラムを実行することで実現する機能の少なくとも一部を、ASIC(Application Specific Integrated Circuit)、PLD(Programmable Logic Device)等の電子回路で実現してもよい。CPU101には、バス100aを介してRAM(Random Access Memory)102と複数の周辺機器が接続されている。
Figure 3 is a diagram showing an example of the hardware configuration of a classical computer. In the
RAM102は、古典コンピュータ100の主記憶装置である。RAM102には、CPU101に実行させるOS(Operating System)のプログラムやアプリケーションプログラムの少なくとも一部が一時的に格納される。また、RAM102には、CPU101による処理に利用する各種データが格納される。なお、古典コンピュータ100は、RAM以外の種類のメモリを備えてもよく、複数個のメモリを備えてもよい。
バス100aに接続されている周辺機器としては、HDD(Hard Disk Drive)103、GPU(Graphics Processing Unit)104、入力インタフェース105、光学ドライブ装置106、機器接続インタフェース107,108およびネットワークインタフェース109がある。
The peripheral devices connected to bus 100a include a HDD (Hard Disk Drive) 103, a GPU (Graphics Processing Unit) 104, an
HDD103は、古典コンピュータ100の補助記憶装置である。HDD103は、内蔵した磁気ディスクに対して、磁気的にデータの書き込みおよび読み出しを行う。HDD103には、OSのプログラム、アプリケーションプログラム、および各種データが格納される。なお、古典コンピュータ100は、フラッシュメモリやSSD(Solid State Drive)等の他の種類の補助記憶装置を備えてもよく、複数の補助記憶装置を備えてもよい。
The
GPU104には、モニタ21が接続されている。GPU104は、CPU101からの命令に従って、画像をモニタ21の画面に表示させる。モニタ21としては、有機EL(Electro Luminescence)を用いた表示装置や液晶表示装置等がある。
The monitor 21 is connected to the
入力インタフェース105には、キーボード22とマウス23とが接続されている。入力インタフェース105は、キーボード22やマウス23から送られてくる信号をCPU101に送信する。なお、マウス23は、ポインティングデバイスの一例であり、他のポインティングデバイスを使用することもできる。他のポインティングデバイスとしては、タッチパネル、タブレット、タッチパッド、トラックボール等がある。
The
光学ドライブ装置106は、レーザ光等を利用して、光ディスク24に記録されたデータの読み取りを行う。光ディスク24は、光の反射によって読み取り可能なようにデータが記録された可搬型の記録媒体である。光ディスク24には、DVD(Digital Versatile Disc)、DVD-RAM、CD-ROM(Compact Disc Read Only Memory)、CD-R(Recordable)/RW(ReWritable)等がある。
The
機器接続インタフェース107は、古典コンピュータ100に周辺機器を接続するための通信インタフェースである。例えば機器接続インタフェース107には、メモリ装置25やメモリリーダライタ26を接続することができる。メモリ装置25は、機器接続インタフェース107との通信機能を搭載した記録媒体である。メモリリーダライタ26は、メモリカード27へのデータの書き込み、またはメモリカード27からのデータの読み出しを行う装置である。メモリカード27は、カード型の記録媒体である。
The
機器接続インタフェース108は、古典コンピュータ100に量子コンピュータ200を接続するための通信インタフェースである。古典コンピュータ100は、機器接続インタフェース108を介して、量子ビットを制御するための指示を量子コンピュータ200に送信する。
The
ネットワークインタフェース109は、ネットワーク20に接続されている。ネットワークインタフェース109は、ネットワーク20を介して、他のコンピュータまたは通信機器との間でデータの送受信を行う。
The
古典コンピュータ100は、以上のようなハードウェア構成によって、第2の実施の形態の処理機能を実現することができる。なお、第1の実施の形態に示した量子回路設計支援装置10も、図3に示した古典コンピュータ100と同様のハードウェアにより実現することができる。また、CPU101は、第1の実施の形態に示した処理部12の一例である。
The
古典コンピュータ100は、例えばコンピュータ読み取り可能な記録媒体に記録されたプログラムを実行することにより、第2の実施の形態の処理機能を実現する。古典コンピュータ100に実行させる処理内容を記述したプログラムは、様々な記録媒体に記録しておくことができる。例えば、古典コンピュータ100に実行させるプログラムをHDD103に格納しておくことができる。CPU101は、HDD103内のプログラムの少なくとも一部をRAM102にロードし、プログラムを実行する。また、古典コンピュータ100に実行させるプログラムを、光ディスク24、メモリ装置25、メモリカード27等の可搬型記録媒体に記録しておくこともできる。可搬型記録媒体に格納されたプログラムは、例えば、CPU101からの制御により、HDD103にインストールされた後、実行可能となる。また、CPU101が、可搬型記録媒体から直接プログラムを読み出して実行することもできる。
The
上記のようなシステムにおいて、古典コンピュータ100は、端末31,32,・・・から量子計算のための量子ビットのゲート操作の手順が記述された量子回路を取得する。端末31,32,・・・から取得する量子回路は、基本量子ゲート以外の複雑な操作を行う量子ゲートを含んでいる。他方、量子コンピュータ200でのゲート操作は、基本量子ゲートのゲート操作に限られる。そこで古典コンピュータ100は、端末31,32,・・・から取得した量子回路に含まれる基本量子ゲート以外の量子ゲートを、量子コンピュータ200で実行可能な基本量子ゲートを用いた等価回路に変換する。そして古典コンピュータ100は、変換後の量子回路による量子計算を量子コンピュータ200に指示する。
In the above system, the
どのような量子ゲートが基本量子ゲートとなるのかは、システムによって異なる。第2の実施の形態に係るシステムでは、1量子ビットゲートのうち、アダマールゲート、NOTゲート、および回転ゲートが基本量子ゲートに含まれる。また2量子ビットゲートのうち、C-NOTゲート、および制御回転ゲートが基本量子ゲートに含まれる。さらに3量子ビットゲートのうち、C2-NOTゲートが基本量子ゲートに含まれる。 What kind of quantum gate is the basic quantum gate varies depending on the system. In the system according to the second embodiment, among the one-qubit gates, the basic quantum gates include the Hadamard gate, the NOT gate, and the rotation gate. Among the two-qubit gates, the basic quantum gates include the C-NOT gate and the controlled rotation gate. Furthermore, among the three-qubit gates, the basic quantum gate includes the C 2 -NOT gate.
基本量子ゲート以外の複雑なゲート操作を行う量子ゲートのうち、頻繁に利用される量子ゲートとしてCk-NOTゲートがある(kは3以上の整数)。Ck-NOTゲートは、k個の制御ビットがすべて|1>のときにターゲットビットの「0/1」を反転させる量子ゲートである。 Among quantum gates that perform complex gate operations other than basic quantum gates, a frequently used quantum gate is the C k -NOT gate (k is an integer equal to or greater than 3). The C k -NOT gate is a quantum gate that inverts the "0/1" of a target bit when all k control bits are |1>.
Ck-NOTゲートのゲート操作は、cleanな補助ビットとdirtyな補助ビットの数に応じて、最小数のC2-NOTゲートで構成された等価な量子回路で代替することができる。 The gate operation of the C k -NOT gate can be replaced with an equivalent quantum circuit composed of a minimum number of C 2 -NOT gates depending on the number of clean auxiliary bits and dirty auxiliary bits.
図4は、C3-NOTゲートの等価回路への変換の一例を示す図である。C3-NOTゲート41は、「c1」~「c3」の3つ量子ビットを制御ビットとし、「x」の量子ビットをターゲット量子ビットとする。C3-NOTゲート41は、cleanな補助ビットを使用できる場合、等価回路42に変換することができる。等価回路42は、3つのC2-NOTゲート42a~42cで構成されている。またC3-NOTゲート41は、cleanな補助ビットを使用できずdirtyな補助ビットを使用できる場合、等価回路43に変換することができる。等価回路43は、4つのC2-NOTゲート43a~43dで構成されている。
FIG. 4 is a diagram showing an example of conversion of a C 3 -NOT gate into an equivalent circuit. The C 3 -NOT gate 41 has three quantum bits, "c 1 " to "c 3 ", as control bits and a quantum bit, "x", as a target quantum bit. The C 3 -NOT gate 41 can be converted into an equivalent circuit 42 if clean auxiliary bits can be used. The equivalent circuit 42 is made up of three C 2 -
このように、cleanな補助ビットを使用できれば、C3-NOTゲート41を3つのC2-NOTゲート42a~42cに変換できる。それに対して、dirtyな補助ビットしか使用できなければ、C3-NOTゲート41を4つのC2-NOTゲート43a~43dに変換することとなる。すなわち、cleanな補助ビットを使用できれば、変換後の量子回路の量子ゲート数が削減できる。
In this way, if clean auxiliary bits can be used, the C 3 -NOT gate 41 can be converted into three C 2 -
図5は、C4-NOTゲートの等価回路への変換の一例を示す図である。C4-NOTゲート44は、「c1」~「c4」の4つの量子ビットを制御ビットとし、「x」の量子ビットをターゲット量子ビットとする。C4-NOTゲート44は、cleanな補助ビットを2つ使用できる場合、等価回路45に変換することができる。等価回路45は、5つのC2-NOTゲート45a~45eで構成されている。またC4-NOTゲート44は、cleanな補助ビットが1つとdirtyな補助ビットが1つ使用できる場合、等価回路46に変換することができる。等価回路46は、6個のC2-NOTゲート46a~46fで構成されている。さらにC4-NOTゲート44は、cleanな補助ビットを使用できずdirtyな補助ビットが2つ使用できる場合、等価回路47に変換することができる。等価回路47は、8個のC2-NOTゲート47a~47hで構成されている。
FIG. 5 is a diagram showing an example of conversion of a C 4 -NOT gate into an equivalent circuit. The C 4 -NOT gate 44 has four quantum bits, "c 1 " to "c 4 ", as control bits and a quantum bit, "x", as a target quantum bit. The C 4 -NOT gate 44 can be converted into an equivalent circuit 45 if two clean auxiliary bits can be used. The equivalent circuit 45 is composed of five C 2 -
このように、cleanな補助ビットを2つ使用できれば、C4-NOTゲート44を5つのC2-NOTゲート45a~45eに変換できる。cleanな補助ビットを1つしか使用できなければ、C4-NOTゲート44を6つのC2-NOTゲート46a~46fに変換することとなる。さらにdirtyな補助ビットしか使用できなければ、C4-NOTゲート44を8つのC2-NOTゲート47a~47hに変換することとなる。すなわち、使用可能なcleanな補助ビットの数が多いほど、変換後の量子回路の量子ゲート数が削減できる。
In this way, if two clean auxiliary bits can be used, the C 4 -NOT gate 44 can be converted into five C 2 -
図4、図5に示したように、cleanな量子ビットが分かっていれば、その量子ビットを補助ビットとして用いることで、Ck-NOTゲートを、少ないゲート数の等価回路に変換可能となる。そのためには、どの量子ビットがcleanな状態なのかを管理することが重要となる。 As shown in Figures 4 and 5, if a clean quantum bit is known, it is possible to convert a C k -NOT gate into an equivalent circuit with a smaller number of gates by using that quantum bit as an auxiliary bit. To do this, it is important to manage which quantum bits are in a clean state.
量子回路が量子ゲートを複数個含む場合において、どの量子ビットがcleanなのかが管理されない場合、すべての量子ビットの状態をdirtyとしてしか扱えない。その結果として、C3-NOTゲートであれば等価回路43(図4参照)に変換され、C4-NOTゲートであれば等価回路47(図5参照)に変換されることとなる。 When a quantum circuit includes multiple quantum gates, if it is not possible to manage which quantum bits are clean, the states of all quantum bits can only be treated as dirty. As a result, a C 3 -NOT gate is converted to an equivalent circuit 43 (see FIG. 4), and a C 4 -NOT gate is converted to an equivalent circuit 47 (see FIG. 5).
量子回路に含まれる基本量子ゲート以外の量子ゲートの数が少なければ、大きな問題にはならないが、回路記述言語で生成される量子回路には基本量子ゲート以外の量子ゲートが多数含まれることが多い。 If the number of quantum gates other than basic quantum gates contained in a quantum circuit were small, this would not be a big problem, but quantum circuits generated using circuit description languages often contain a large number of quantum gates other than basic quantum gates.
図6は、複数のCk-NOTゲートを用いた量子回路の一例を示す図である。量子回路48は、「x1」の量子ビットと「x2」の量子ビットについて、「x1=x2=1」のときに、量子ビット列「q=q8,・・・,q0」で表される数値(2進数表記)に「211」を加算する量子計算を示している。量子回路48には、多数のCk-NOTゲートが使用されている。このとき、どの量子ビットがcleanかがわからない場合、すべてのCk-NOTゲートについて、ゲート数が多い等価回路に変換することとなる。その結果、変換後の量子回路全体の量子ゲート数が非常に増えてしまう。 FIG. 6 is a diagram showing an example of a quantum circuit using multiple C k -NOT gates. The quantum circuit 48 shows a quantum calculation in which, for the quantum bit of "x 1 " and the quantum bit of "x 2 ", when "x 1 =x 2 =1", "211" is added to a numerical value (binary notation) represented by the quantum bit string "q=q 8 , ..., q 0 ". The quantum circuit 48 uses a large number of C k -NOT gates. In this case, if it is not known which quantum bit is clean, all the C k -NOT gates are converted into equivalent circuits with a large number of gates. As a result, the number of quantum gates in the entire quantum circuit after conversion increases significantly.
具体的には、量子回路48には、C2-NOTゲートが11個、C3-NOTゲートが16個、C4-NOTゲートが13個含まれている。このうち16個のC3-NOTゲートは、等価回路43によって64個のC2-NOTゲートに変換される。また13個のC4-NOTゲートは、等価回路47によって104個のC2-NOTゲートに変換される。その結果、18個の量子ビットに対する179個のC2-NOTゲートによるゲート操作を示す量子回路が生成される。 Specifically, quantum circuit 48 includes 11 C 2 -NOT gates, 16 C 3 -NOT gates, and 13 C 4 -NOT gates. Of these, the 16 C 3 -NOT gates are converted into 64 C 2 -NOT gates by equivalent circuit 43. Furthermore, the 13 C 4 -NOT gates are converted into 104 C 2 -NOT gates by equivalent circuit 47. As a result, a quantum circuit is generated that shows gate operations by 179 C 2 -NOT gates for 18 quantum bits.
なおcleanな補助ビットが不足する場合は、不足分のcleanな量子ビットを追加することができれば、Ck-NOTを最小数のC2-NOTゲートで構成された等価回路45に変換できる。 If there is a shortage of clean auxiliary bits, C k -NOT can be converted into an equivalent circuit 45 composed of a minimum number of C 2 -NOT gates if the required number of clean quantum bits can be added.
図7は、Ck-NOTゲートの変換のためにcleanな量子ビットを追加する場合の一例を示す図である。量子回路49では、cleanな2つの量子ビットが追加されている。追加した量子ビットを補助ビットとして用いれば、各Ck-NOTを最小数のC2-NOTゲートで構成された等価回路に変換可能である。この場合、cleanな量子ビットを追加するため、量子回路の実行に用いる量子ビット数が増えてしまう。量子コンピュータでは利用できる量子ビット数に限界がある。そのため、利用する量子ビット数が増加すると、変換後の量子回路を量子コンピュータに実行させることができない可能性がある。 FIG. 7 is a diagram showing an example of adding clean quantum bits to convert a C k -NOT gate. In the quantum circuit 49, two clean quantum bits are added. If the added quantum bits are used as auxiliary bits, each C k -NOT can be converted into an equivalent circuit composed of a minimum number of C 2 -NOT gates. In this case, the number of quantum bits used to execute the quantum circuit increases because clean quantum bits are added. There is a limit to the number of quantum bits that can be used in a quantum computer. Therefore, if the number of quantum bits used increases, there is a possibility that the quantum computer cannot execute the quantum circuit after conversion.
具体的には、量子回路49に含まれる16個のC3-NOTゲートは、等価回路42によって48個のC2-NOTゲートに変換される。また13個のC4-NOTゲートは、等価回路45によって65個のC2-NOTゲートに変換される。その結果、20個の量子ビットに対する124個のC2-NOTゲートによるゲート操作を示す量子回路が生成される。このように、cleanな量子ビットを補助ビットとして追加すれば、変換後の量子ゲート数は削減できるものの、量子ビットが増加する。その結果、使用できる量子ビットの不足により、量子回路を実行できないおそれがある。 Specifically, the 16 C 3 -NOT gates included in the quantum circuit 49 are converted into 48 C 2 -NOT gates by the equivalent circuit 42. The 13 C 4 -NOT gates are converted into 65 C 2 -NOT gates by the equivalent circuit 45. As a result, a quantum circuit is generated that shows gate operations by 124 C 2 -NOT gates for 20 quantum bits. In this way, if clean quantum bits are added as auxiliary bits, the number of quantum gates after conversion can be reduced, but the number of quantum bits increases. As a result, there is a risk that the quantum circuit cannot be executed due to a shortage of available quantum bits.
そこで古典コンピュータ100にcleanビット管理機能を導入し、古典コンピュータ100が量子回路に用いる各量子ビットについてのゲート操作ごとに、ゲート操作後の状態がcleanかdirtyかを管理する。
Therefore, a clean bit management function is introduced to the
一般的に各量子ビットの初期状態はcleanである。その後のゲート操作でdirtyの状態となった量子ビットであっても、状態を|0>にするゲート操作が実行された場合、その量子ビットはcleanとなる。 Generally, the initial state of each quantum bit is clean. Even if a quantum bit becomes dirty due to a subsequent gate operation, if a gate operation is performed that changes the state to |0>, the quantum bit will become clean.
図8は、量子ビットの状態遷移の一例を示す図である。量子ビットの初期状態を|0>とすると、量子コンピュータ200に量子回路が入力された段階(ゲート操作前)では、すべての量子ビットはcleanである。量子コンピュータ200で入力された量子回路内の量子ゲートの操作が実行されたとき、その量子ゲートのターゲットビットとなっている量子ビットはcleanからdirtyに変更されることがある。dirtyとなった量子ビットであっても、ある量子ゲートによってその量子ビットの状態が|0>に戻されたときは、その量子ビットはcleanとなる。
FIG. 8 is a diagram showing an example of the state transition of a quantum bit. If the initial state of a quantum bit is |0>, then when the quantum circuit is input to quantum computer 200 (before gate operation), all quantum bits are clean. When the operation of a quantum gate in the quantum circuit input to
例えば、量子回路51には、C7-NOTゲート51aと6個のアダマールゲート51b~51gが配置されている。C7-NOTゲート51aは、「c1」~「c7」の7個の量子ビットを制御ビットとし、「x」の量子ビットをターゲット量子ビットとする。C7-NOTゲート51aは、すべての制御ビットの状態が|1>であれば、ターゲットビットの状態を反転(|0>を|1>、または|1>を|0>に変換)させる。
For example, a quantum circuit 51 is arranged with a C 7 -
「a1」~「a5」の5個の量子ビットそれぞれに対しては、アダマールゲート51b~51fが配置されている。また「a1」の量子ビットには、さらにアダマールゲート51gが配置されている。
量子回路51において、ゲート操作を適用する前の段階では、すべての量子ビットの状態がcleanである。「a1」~「a5」の5個の量子ビットに対するアダマールゲート51b~51fのゲート操作を実行した後は、これらの「a1」~「a5」の5個の量子ビットはcleanからdirtyの量子ビットに状態が変化している。「a1」の量子ビットに対して2回目のアダマールゲート51gのゲート操作が実行されると、「a1」の量子ビットの状態がdirtyからcleanに変化する。
In the quantum circuit 51, before the gate operation is applied, the states of all quantum bits are clean. After the gate operations of the
量子回路51の例では、最後のC7-NOTゲート51aを等価回路に変換する場合、では、「a1」の量子ビットをcleanの補助ビットとして利用し、「a2」~「a5」の量子ビットをdirtyの補助ビットとして利用することができる。
In the example of quantum circuit 51, when the last C 7 -
このように各量子ビットは、初期状態ではcleanであるものの、何らかのゲート操作が行われるとdirtyとなる。dirtyとなった量子ビットであっても、前と同じゲート操作がもう一度実行された場合、状態はcleanとなる。 In this way, each quantum bit is initially clean, but becomes dirty when any gate operation is performed. Even if the quantum bit becomes dirty, if the same gate operation as before is performed again, the quantum bit will become clean.
またSWAPゲートの操作が行われた場合にも、dirtyの量子ビットの状態がcleanに変化する可能性がある。SWAPゲートは、2つの量子ビットの状態を交換する操作を行う量子ゲートである。例えばSWAPゲートの操作対象の一方の量子ビットの状態がcleanであり、他方の量子ビットの状態がdirtyの場合がある。この場合、SWAPゲートの適用により、cleanの量子ビットの状態がdirtyに変化し、dirtyの量子ビットの状態がcleanに変化する。 In addition, when a SWAP gate is operated, the state of a dirty quantum bit may also change to clean. A SWAP gate is a quantum gate that performs an operation to exchange the states of two quantum bits. For example, one quantum bit operated by a SWAP gate may be in a clean state, while the other quantum bit may be in a dirty state. In this case, application of the SWAP gate changes the state of the clean quantum bit to dirty, and the state of the dirty quantum bit to clean.
そこで古典コンピュータ100は、cleanビット管理機能により、cleanな量子ビットがターゲットビットとなる量子ゲートの操作が実行されたときには、その量子ビットをdirtyに変更する。また古典コンピュータ100は、SWAPゲートの操作が実行されたときには、操作対象の両者の量子ビットの状態を入れ替える。さらに古典コンピュータ100は、dirtyな量子ビットを|0>にする処理が実行されたときには、その量子ビットをcleanに変更する。
The
なおcleanビットに対する所定の量子ゲートの2回のゲート操作により、その量子ビットがcleanビットに戻すことができるゲート操作は、アダマールゲート以外にもある。例えばcleanビットに対してNOTゲートのゲート操作を2回実行すると、その量子ビットは、1回目のNOTゲート操作でdirtyビットとなるが2回目のNOTゲート操作によりcleanビットに戻る。 Note that there are other gate operations besides the Hadamard gate that can return a quantum bit to a clean bit by performing two gate operations of a specific quantum gate on the clean bit. For example, if a NOT gate operation is performed twice on a clean bit, the quantum bit becomes a dirty bit after the first NOT gate operation, but returns to a clean bit after the second NOT gate operation.
このようなcleanビット管理機能により、古典コンピュータ100は、量子ビットを増やさずに、量子回路に現れるすべてのCk-NOTゲートを、cleanな補助ビット数とdirtyな補助ビット数に応じた最適な等価回路に変換することができる。その結果、量子コンピュータ200での計算時間を削減できる。このことは、量子コンピュータ200の代わりに量子回路シミュレータを用いた場合も同様である。
With such a clean bit management function, the
図9は、各装置が有する機能の一例を示すブロック図である。端末31は、量子回路生成部31aを有する。量子回路生成部31aは、ユーザからの入力に従って回路記述言語で記述された量子回路を生成する。量子回路生成部31aが生成する量子回路には、基本量子ゲート以外の量子ゲートも利用される。量子回路生成部31aは、生成した量子回路を古典コンピュータ100に送信する。
FIG. 9 is a block diagram showing an example of the functions of each device. The terminal 31 has a quantum
古典コンピュータ100は、量子計算管理部110、cleanビット管理部120、および量子ゲート変換部130を有する。
量子計算管理部110は、端末31から送られた量子回路に応じた量子計算の実行を管理する。例えば量子計算管理部110は、端末31から送られた量子回路内に基本量子ゲート以外の量子ゲートがある場合、その量子ゲートの等価回路への変換を量子ゲート変換部130に指示する。また量子計算管理部110は、量子回路における各量子ゲートによる操作後の各量子ビットの状態(clean/dirty)の管理を指示する。量子計算管理部110は、基本量子ゲートのみで記述された量子回路が生成されると、その量子回路に基づく量子計算を量子コンピュータ200に指示する。そして量子計算管理部110は、量子コンピュータ200から計算結果を取得し、その計算結果を端末31に出力する。
The
The quantum
cleanビット管理部120は、量子回路において操作対象となっている量子ビットについての状態を管理する。例えばcleanビット管理部120は、量子回路の量子ゲートによる操作を先頭から順に解釈し、そのゲート操作後に、操作された量子ビットの状態がcleanになるのかdirtyになるのかを判断する。
The
量子ゲート変換部130は、量子回路に含まれる、基本量子ゲート以外の量子ゲートを、基本量子ゲートのみを用いた等価回路に変換する。その際、量子ゲート変換部130は、cleanビット管理部120から、変換対象の量子ゲートを実行する直前における各量子ビットの状態を取得する。そして量子ゲート変換部130は、補助ビットとして使用可能なcleanな量子ビットとdirtyな量子ビットとを特定し、それらの量子ビットを有効に利用した最小の等価回路に、変換対象の量子ゲートを変換する。
The quantum
なお、図9に示した各要素の機能は、例えば、その要素に対応するプログラムモジュールをコンピュータに実行させることで実現することができる。
次に、量子回路の最適化を伴う量子計算の実行手順について詳細に説明する。
The functions of each element shown in FIG. 9 can be realized, for example, by causing a computer to execute a program module corresponding to that element.
Next, a procedure for performing quantum computation involving optimization of a quantum circuit will be described in detail.
図10は、量子回路の最適化を伴う量子計算の実行手順の一例を示すフローチャートである。以下、図10に示す処理をステップ番号に沿って説明する。
[ステップS101]量子計算管理部110は、端末31,32,・・・のいずれかから計算対象の量子回路を取得する。量子計算管理部110は、取得した量子回路に基づいて、cleanビット管理のための情報の設定を、cleanビット管理部120に指示する。するとcleanビット管理部120は、指定された量子回路を解析し、cleanビットの管理に用いる回路情報を設定する。設定する回路情報は、例えば量子ビット数n、量子回路「QC」、初期状態I、clean化情報CIである。
10 is a flowchart showing an example of a procedure for performing quantum computation involving optimization of a quantum circuit. The process shown in FIG. 10 will be described below in order of step numbers.
[Step S101] The
量子ビット数nは、量子回路に現れる量子ビットの数である。量子ビット数nが、入力された量子回路を実行するための最小限の量子ビット数となる。
量子回路「QC」は、{ゲートの番号,量子ゲートの構成}を順に並べた情報である。量子ゲートの構成は、量子ゲートの種類、操作対象の量子ビットの番号などである。例えば「QC」は[{1,1番目の量子ビットにアダマールゲート},{2,1~10番目を制御ビットとして11番目をターゲットビットとするC10-NOTゲート},・・・]のような情報である。
The number of quantum bits n is the number of quantum bits that appear in the quantum circuit. The number of quantum bits n is the minimum number of quantum bits required to execute the input quantum circuit.
A quantum circuit "QC" is information that lists {gate number, quantum gate configuration} in order. The quantum gate configuration is the type of quantum gate, the number of the quantum bit to be operated on, etc. For example, "QC" is information such as [{1, Hadamard gate for the first quantum bit}, {2, C 10 -NOT gate with 1st to 10th bits as control bits and 11th bit as the target bit}, ...].
初期状態Iは、cleanな量子ビットの番号の集合である。例えば1,2,10番目がcleanな場合、初期状態Iは{1,2,10}となる。
clean化情報CIは、実行したときにターゲットビットの状態がcleanになる量子ゲートの識別番号の集合である。例えば5番目の量子ゲートと9番目の量子ゲートとについて、実行後のターゲットビットの状態がcleanになる場合、clean化情報CIは{5,9}となる。図8に示した量子回路51の例であれば、アダマールゲート51gの識別番号が、clean化情報CIに設定される。
The initial state I is a set of clean quantum bit numbers. For example, if the 1st, 2nd, and 10th quantum bits are clean, the initial state I is {1, 2, 10}.
The cleaning information CI is a set of identification numbers of quantum gates that make the state of the target bit clean when executed. For example, for the fifth quantum gate and the ninth quantum gate, if the state of the target bit after execution becomes clean, the cleaning information CI is {5, 9}. In the example of the quantum circuit 51 shown in FIG. 8, the identification number of the
[ステップS102]量子計算管理部110とcleanビット管理部120は、量子回路の最適化に用いる情報の初期状態を生成する。例えばcleanビット管理部120は、ゲート操作が行われるごとの量子ビットの状態変化の管理に用いる情報の初期状態を生成する。量子ビットの状態変化の管理に用いる情報には、cleanな量子ビットのリスト「cleanBitList」、dirtyな量子ビットのリスト「dirtyBitList」、「QC」に含まれる量子ゲートの個数「N」がある。
[Step S102] The
「cleanBitList」の初期値は、初期状態Iである(cleanBitList=I)。「dirtyBitList」の初期値は、全量子ビットのリストから初期状態Iに含まれる量子ビットを除外したものである(dirtyBitList={1,・・・,n}-I)。「N」には、「QC」に示される量子ゲートの識別番号の最大値が設定される。 The initial value of "cleanBitList" is the initial state I (cleanBitList = I). The initial value of "dirtyBitList" is the list of all quantum bits excluding the quantum bits included in the initial state I (dirtyBitList = {1, ..., n} - I). "N" is set to the maximum value of the quantum gate identification number shown in "QC".
また量子計算管理部110は、処理対象の量子ゲートが何番目の量子ゲートなのかを示す変数「i」に初期値を設定する。例えば「i」の初期値は「1」である(i=1)。
[ステップS103]量子計算管理部110は、「i」の値が「N+1」となっているか否かにより、基本量子ゲート以外の量子ゲートの等価回路への変換処理が終了したか否かを判定する。例えば量子計算管理部110は、「i==N+1」であれば、処理をステップS110に進める。また量子計算管理部110は、「i==N+1」でなければ、処理をステップS104に進める。
In addition, the
[Step S103] The quantum
[ステップS104]量子ゲート変換部130は、「QC」のi番目の量子ゲート「QC[i]」が等価回路への変換対象か否かを判断する。等価回路への変換対象の量子ゲートは、基本量子ゲート以外の量子ゲートである。量子ゲート変換部130は、等価回路への変換対象の量子ゲートであれば、処理をステップS105に進める。また量子ゲート変換部130は、等価回路への変換対象の量子ゲートでなければ、処理をステップS108に進める。
[Step S104] The quantum
[ステップS105]量子ゲート変換部130は、cleanな量子ビットの一時的なリスト「tmpCleanBitList」とdirtyな量子ビットの一時的なリスト「tmpDirtyBitList」を作成する。例えば量子ゲート変換部130は、「cleanBitList」からQC[i]の制御ビットとターゲットビットとの識別番号を削除したものを「tmpCleanBitList」とする。また量子ゲート変換部130は、「dirtyBitList」からQC[i]の制御ビットとターゲットビットとの識別番号を削除したものを「tmpDirtyBitList」とする。
[Step S105] The quantum
[ステップS106]量子ゲート変換部130は、QC[i]と「tmpCleanBitList」と「tmpDirtyBitList」とに基づいて、QC[i]の量子ゲートの等価回路への変換処理(量子ゲート変換)を実行する。量子ゲート変換の結果として得られる等価回路を「qc」とする。量子ゲート変換処理の詳細は後述する(図24参照)。
[Step S106] The quantum
[ステップS107]量子ゲート変換部130は、QC[i]を、量子ゲート変換処理で生成された等価回路「qc」に置き換える(QC[i]=qc)。
[ステップS108]cleanビット管理部120は、QC[i]のゲート操作が実行されたことに応じたcleanビット更新処理を行う。cleanビット更新処理の詳細は後述する(図11参照)。
[Step S107] The quantum
[Step S108] The
[ステップS109]量子計算管理部110は、変数「i」に1を加算し(i←i+1)、処理をステップS103に進める。
[ステップS110]量子計算管理部110は、量子コンピュータ200に量子回路に基づく量子計算の実行を指示する。
[Step S109] The
[Step S110] The
[ステップS111]量子計算管理部110は、量子コンピュータ200から計算結果を取得する。
[ステップS112]量子計算管理部110は、量子回路に基づく量子計算の結果を出力する。
[Step S<b>111 ] The
[Step S112] The
このようにして、量子ゲートごとに等価回路へ変換するか否かが判断され、変換する場合には等価回路に変換される。また1つの量子ゲートについて処理が終了するごとに、その量子ゲートによるゲート操作後の各量子ビットの状態が更新される。これにより、等価回路への変換時において、量子ゲート変換部130は、変換対象の量子ゲートのゲート操作実行時にcleanな量子ビットを正しく判断し、cleanな量子ビット数に応じて、より少ない量子ゲート数の等価回路へ変換することが可能となる。
In this way, a decision is made for each quantum gate as to whether or not to convert to an equivalent circuit, and if so, the circuit is converted to an equivalent circuit. Furthermore, each time processing is completed for one quantum gate, the state of each quantum bit after the gate operation by that quantum gate is updated. As a result, when converting to an equivalent circuit, the quantum
次に、cleanビット更新処理の手順について詳細に説明する。
図11は、cleanビット更新処理の手順の一例を示すフローチャートである。以下、図11に示す処理をステップ番号に沿って説明する。なお図11の処理においてQC[i]の量子ゲートは、QC[i]が等価回路「qc」に変換されていたとしても、変換前のi番目の量子ゲートを示すものとする。
Next, the procedure for the clean bit update process will be described in detail.
Fig. 11 is a flow chart showing an example of the procedure of the clean bit update process. The process shown in Fig. 11 will be explained below in order of step numbers. Note that in the process of Fig. 11, the quantum gate of QC[i] indicates the i-th quantum gate before conversion, even if QC[i] has been converted to the equivalent circuit "qc".
[ステップS201]cleanビット管理部120は、処理対象の量子ゲートであるQC[i]が等価回路「qc」に変換されているか否かを判断する。cleanビット管理部120は、変換されている場合、処理をステップS204に進める。またcleanビット管理部120は、変換されていない場合、処理をステップS202に進める。
[Step S201] The
[ステップS202]cleanビット管理部120は、QC[i]の量子ゲートがSWAPゲートか否かを判断する。cleanビット管理部120は、SWAPゲートであれば、処理をステップS203に進める。またcleanビット管理部120は、SWAPゲートでなければ、処理をステップS204に進める。
[Step S202] The clean
[ステップS203]cleanビット管理部120は、処理対象の量子ゲート(SWAPゲート)による操作対象の量子ビットの状態を入れ替える。例えばcleanビット管理部120は、操作対象の量子ビットの識別番号「j,k」の一方が「cleanBitList」に含まれ、他方が「dirtyBitList」に含まれる場合、それらの属する先のリストを入れ替える。
[Step S203] The
具体的にはcleanビット管理部120は、「cleanBitList」に含まれる操作対象の量子ビットの識別番号(「j」または「k」)を「cleanBitList」から削除すると共に、「dirtyBitList」に追加する。またcleanビット管理部120は、「dirtyBitList」に含まれる操作対象の量子ビットの識別番号(「j」または「k」)を「dirtyBitList」から削除すると共に、「cleanBitList」に追加する。
Specifically, the
cleanビット管理部120は、状態の入れ替えが終了すると、cleanビット更新処理を終了する。
[ステップS204]cleanビット管理部120は、QC[i]の量子ゲートにおけるターゲットビットの識別番号[j]が「cleanBitList」に含まれており、かつclean化情報CIには含まれていないという条件が満たされるか否かを判断する。cleanビット管理部120は、条件が満たされる場合、処理をステップS205に進める。またcleanビット管理部120は、条件が満たされない場合、処理をステップS206に進める。
When the state switching is completed, the
[Step S204] The
[ステップS205]cleanビット管理部120は、QC[i]の量子ゲートにおけるターゲットビットの識別番号[j]を「cleanBitList」から削除するとともに、「dirtyBitList」に追加する。その後、cleanビット管理部120は、cleanビット更新処理を終了する。
[Step S205] The
[ステップS206]cleanビット管理部120は、QC[i]の量子ゲートにおけるターゲットビットの識別番号[j]が「dirtyBitList」に含まれており、かつclean化情報CIにも含まれているという条件が満たされるか否かを判断する。cleanビット管理部120は、条件が満たされる場合、処理をステップS207に進める。またcleanビット管理部120は、条件が満たされない場合、cleanビット更新処理を終了する。
[Step S206] The
[ステップS207]cleanビット管理部120は、QC[i]の量子ゲートにおけるターゲットビットの識別番号[j]を「dirtyBitList」から削除するとともに、「cleanBitList」に追加する。その後、cleanビット管理部120は、cleanビット更新処理を終了する。
[Step S207] The
このようにして、各量子ゲートの操作が実行された後の量子ビットの状態(cleanかdirtyか)が適切に管理される。
図12は、cleanビット更新処理による初期の情報設定の一例を示す図である。図12の例では、図6に示す量子回路48の基本量子ゲート以外の量子ゲートを等価回路に変換する場合を想定している。
In this way, the state of the quantum bit (clean or dirty) after each quantum gate operation is performed is appropriately managed.
Fig. 12 is a diagram showing an example of initial information setting by clean bit update processing. In the example of Fig. 12, it is assumed that quantum gates other than the basic quantum gates of the quantum circuit 48 shown in Fig. 6 are converted into equivalent circuits.
量子回路48は、量子ビット「x1」、「x2」が共に|1>のときに、量子ビット列「q8,・・・,q0」(2進数表記)に「211」を加算する回路である。量子回路48では、7個のcleanな量子ビット「c1,・・・,c7」が、補助ビットとして使用可能である。 The quantum circuit 48 is a circuit that adds "211" to the quantum bit string " q8 , ..., q0 " (binary notation) when both quantum bits " x1 " and " x2 " are |1>. In the quantum circuit 48, seven clean quantum bits " c1 , ..., c7 " can be used as auxiliary bits.
量子回路48で使用する量子ビットの数は18個であり、n=18に設定される。これらの量子ビットのうち、cleanな量子ビット「c1,・・・,c7」の識別番号は、それぞれ「4,6,8,10,12,14,16」である。従って、初期状態Iには「I={4,6,8,10,12,14,16}」と設定される。 The number of quantum bits used in quantum circuit 48 is 18, and n is set to 18. Among these quantum bits, the identification numbers of clean quantum bits "c 1 , ..., c 7 " are "4, 6, 8, 10, 12, 14, 16", respectively. Therefore, the initial state I is set to "I={4, 6, 8, 10, 12, 14, 16}".
量子回路48に含まれる量子ゲートのうち、ターゲットビットの状態を|0>に変更するゲート操作を行うのは、順番が「20,23,27,30,32,36,39」の7個の量子ゲートである。従って、clean化情報CIには「CI={20,23,27,30,32,36,39}」と設定される。 Among the quantum gates included in quantum circuit 48, the seven quantum gates that perform the gate operation to change the state of the target bit to |0> are the ones in the order "20, 23, 27, 30, 32, 36, 39". Therefore, the cleaning information CI is set to "CI = {20, 23, 27, 30, 32, 36, 39}".
そして量子回路の最適化を行う前に、初期状態Iと同じ内容の「cleanBitList={4,6,8,10,12,14,16}」が生成される。またdirtyな量子ビットを示す「dirtyBitList={1,2,3,5,7,9,11,13,15,17,18}」が生成される。 Before optimizing the quantum circuit, "cleanBitList = {4, 6, 8, 10, 12, 14, 16}" is generated, which has the same contents as the initial state I. Also, "dirtyBitList = {1, 2, 3, 5, 7, 9, 11, 13, 15, 17, 18}" is generated, which indicates dirty quantum bits.
量子回路48に含まれる量子ゲートの数は40個であるため、ゲート数「N=40」に設定される。
「cleanBitList」と「dirtyBitList」とは、1つの量子ゲートについて等価回路への変換要否判断、および変換する場合の等価回路への変換が行われるごとに更新される。そして、量子ゲートを等価回路に変換する場合には、そのときの「cleanBitList」に基づいて「tmpCleanBitList」が生成される。「tmpCleanBitList」が、該当する量子ゲートの等価回路において、cleanな補助ビットとして使用可能な量子ビットを示している。また「dirtyBitList」に基づいて「tmpDirtyBitList」が生成される。「tmpDirtyBitList」は、該当する量子ゲートの等価回路において、dirtyな補助ビットとして使用可能な量子ビットを示している。
Since the quantum circuit 48 includes 40 quantum gates, the number of gates is set to "N=40".
The "cleanBitList" and "dirtyBitList" are updated each time a quantum gate is converted into an equivalent circuit and converted into an equivalent circuit. When a quantum gate is converted into an equivalent circuit, a "tmpCleanBitList" is generated based on the "cleanBitList" at that time. The "tmpCleanBitList" indicates quantum bits that can be used as clean auxiliary bits in the equivalent circuit of the corresponding quantum gate. The "tmpDirtyBitList" is generated based on the "dirtyBitList". The "tmpDirtyBitList" indicates quantum bits that can be used as dirty auxiliary bits in the equivalent circuit of the corresponding quantum gate.
図13は、tmpCleanBitListの状態遷移の一例を示す図である。tmpCleanBitListについての状態遷移表52の各列のラベルは、量子ゲートの番号を示している。「tmpCleanBitList」の状態遷移表52の各行のラベルは、量子ビットを示している。 FIG. 13 shows an example of the state transition of tmpCleanBitList. The labels of each column in state transition table 52 for tmpCleanBitList indicate the quantum gate number. The labels of each row in state transition table 52 for "tmpCleanBitList" indicate quantum bits.
状態遷移表52において、量子ゲートに対応する列に、その量子ゲートによる操作前の量子ビットの状態(cleanまたはdirty)が示されている。「制」と設定された量子ビットは、対応する量子ゲートの制御ビットである。「t」と設定された量子ビットは、対応する量子ゲートのターゲットビットである。「c」と設定された量子ビットはcleanな量子ビットであり、その量子ビットの識別番号が「tmpCleanBitList」に含まれる。設定が空白の量子ビットはdirtyな量子ビットであり、その量子ビットの識別番号が「tmpDirtyBitList」に含まれる。 In state transition table 52, the column corresponding to a quantum gate shows the state (clean or dirty) of the quantum bit before the operation by that quantum gate. A quantum bit set as "control" is the control bit of the corresponding quantum gate. A quantum bit set as "t" is the target bit of the corresponding quantum gate. A quantum bit set as "c" is a clean quantum bit, and the identification number of that quantum bit is included in "tmpCleanBitList". A quantum bit with a blank setting is a dirty quantum bit, and the identification number of that quantum bit is included in "tmpDirtyBitList".
図12、図13に示した例では、補助ビットとして使用できるdirtyビットは十分にある。そこで使用できるcleanビットの数に応じて、Ck-NOTゲートをどのような等価回路に変換するのかが決まる。 12 and 13, there are a sufficient number of dirty bits that can be used as auxiliary bits. Therefore, the type of equivalent circuit to which the C k -NOT gate is converted is determined according to the number of clean bits that can be used.
量子回路48の量子ゲートのうち、C2-NOTゲートは変換不要である。変換不要な量子ゲートは、「3,8,12,15,19,21,26,28,35,37,40」の計11個である。 Of the quantum gates in the quantum circuit 48, the C 2 -NOT gate does not require conversion. The quantum gates that do not require conversion are 11 in total: 3, 8, 12, 15, 19, 21, 26, 28, 35, 37, and 40.
C3-NOTゲートのうち、cleanビットを少なくとも1つ補助ビットとして使用できるものは、等価回路42(図4参照)に変換できる。少なくとも1つのcleanビットを使用できるC3-NOTゲートは、「1,2,7,22,24,27,29,31,33,36,38,39」の計12個である。等価回路42には3個の量子ゲートが含まれるため、変換後の合計の量子ゲート数は36個(12×3)となる。 Among the C 3 -NOT gates, those that can use at least one clean bit as an auxiliary bit can be converted into an equivalent circuit 42 (see FIG. 4). There are a total of 12 C 3 -NOT gates that can use at least one clean bit: "1, 2, 7, 22, 24, 27, 29, 31, 33, 36, 38, 39." As the equivalent circuit 42 includes three quantum gates, the total number of quantum gates after conversion is 36 (12 x 3).
C3-NOTゲートのうち、cleanビットを1つも使用できないものは、等価回路43(図4参照)に変換される。cleanビットを1つも使用できないC3-NOTゲートは、「11,14,17,20」の計4個である。等価回路43には4個の量子ゲートが含まれるため、変換後の合計の量子ゲート数は16個(4×4)である。 Among the C 3 -NOT gates, those which cannot use any clean bits are converted to an equivalent circuit 43 (see FIG. 4). There are a total of four C 3 -NOT gates which cannot use any clean bits: "11, 14, 17, 20". As the equivalent circuit 43 includes four quantum gates, the total number of quantum gates after conversion is 16 (4×4).
C4-NOTゲートのうち、少なくとも2個のcleanビットを補助ビットとして使用できるものは、等価回路45(図5参照)に変換できる。cleanビットを少なくとも2個使用できるC4-NOTゲートは、「4,5,6,9,25,30,32,34」の計8個である。等価回路45には5個の量子ゲートが含まれるため、変換後の合計の量子ゲート数は40個(5×8)である。 Among the C 4 -NOT gates, those that can use at least two clean bits as auxiliary bits can be converted into an equivalent circuit 45 (see FIG. 5). There are a total of eight C 4 -NOT gates that can use at least two clean bits: "4, 5, 6, 9, 25, 30, 32, 34." As the equivalent circuit 45 includes five quantum gates, the total number of quantum gates after conversion is 40 (5 x 8).
C4-NOTゲートのうち、cleanビットを1個のみ使用できるものは、等価回路46(図5参照)に変換できる。cleanビットを1個のみ使用できるC4-NOTゲートは、「10,23」の計2個である。等価回路46には6個の量子ゲートが含まれるため、変換後の合計の量子ゲート数は12個(6×2)である。 Among the C 4 -NOT gates, those that can use only one clean bit can be converted to an equivalent circuit 46 (see FIG. 5). There are two C 4 -NOT gates that can use only one clean bit, "10, 23". As the equivalent circuit 46 includes six quantum gates, the total number of quantum gates after conversion is 12 (6×2).
C4-NOTゲートのうち、cleanビットを1つも使用できないものは、等価回路47(図5参照)に変換される。cleanビットを1つも使用できないC4-NOTゲートは、「13,16,18」の計3個である。等価回路47には8個の量子ゲートが含まれるため、変換後の合計の量子ゲート数は24個(8×3)である。 Among the C 4 -NOT gates, those which cannot use any clean bits are converted to an equivalent circuit 47 (see FIG. 5). There are three C 4 -NOT gates which cannot use any clean bits: "13, 16, 18". As the equivalent circuit 47 includes eight quantum gates, the total number of quantum gates after conversion is 24 (8×3).
結果として量子回路48を基本量子ゲートのみで構成される量子ゲートに変換した場合の基本量子ゲート総数は「11+36+16+40+12+24=139」となる。
前述のように、cleanビットを管理していない場合には、すべてのC3-NOTゲートが等価回路43に変換され、すべてのC4-NOTゲートが等価回路47に変換される。その場合、変換後の量子回路の基本量子ゲート総数は179個である。すなわち、cleanビットを管理することで、量子回路の量子ゲート数が179個から139個に削減される。
As a result, when the quantum circuit 48 is converted into a quantum gate consisting of only basic quantum gates, the total number of basic quantum gates becomes "11+36+16+40+12+24=139".
As described above, when the clean bits are not managed, all the C 3 -NOT gates are converted to the equivalent circuit 43, and all the C 4 -NOT gates are converted to the equivalent circuit 47. In this case, the total number of basic quantum gates in the quantum circuit after the conversion is 179. That is, by managing the clean bits, the number of quantum gates in the quantum circuit is reduced from 179 to 139.
次に、基本量子ゲート以外の量子ゲートの等価回路への変換処理について詳細に説明する。
まず、使用できるcleanな補助ビットおよびdirtyな補助ビットそれぞれの数に応じた、適用可能な等価回路への変換方式について説明する。
Next, the conversion process to an equivalent circuit of a quantum gate other than a basic quantum gate will be described in detail.
First, a method of conversion to an applicable equivalent circuit according to the number of usable clean auxiliary bits and dirty auxiliary bits will be described.
図14は、使用可能な補助ビットの数と適用可能な変換方式との対応関係の一例を示す図である。変換方式適用表60には、cleanビット数とdirtyビット数とに応じて適用可能な変換方式が示されている。変換方式適用表60の横軸が使用可能なcleanビット数であり、縦軸が使用可能なdirtyビット数である。 FIG. 14 is a diagram showing an example of the correspondence between the number of available auxiliary bits and applicable conversion methods. Conversion method application table 60 shows applicable conversion methods according to the number of clean bits and the number of dirty bits. The horizontal axis of conversion method application table 60 is the number of available clean bits, and the vertical axis is the number of available dirty bits.
第1の変換方式は、最も量子ゲート数の少ない等価回路に変換可能な変換方式である。第1の変換方式は、k-2個のcleanな補助ビットを使って、Ck-NOTゲートを2k-3個のC2-NOTゲートに変換することができる変換方式である。第1の変換方式は、後述の他の変換方式よりも変換後の量子ゲート数が少なくなる。他方、第1の変換方式は、k-2個以上のcleanビットが使用可能な場合にしか適用できない。そこで、量子ゲート変換部130は、k-2個のcleanな補助ビットが使用可能な場合、第1の変換方式を適用する。
The first conversion method is a conversion method capable of converting into an equivalent circuit with the smallest number of quantum gates. The first conversion method is a conversion method capable of converting a C k -NOT gate into 2k-3 C 2 -NOT gates using k-2 clean auxiliary bits. The first conversion method results in a smaller number of quantum gates after conversion than the other conversion methods described below. On the other hand, the first conversion method can only be applied when k-2 or more clean bits are available. Therefore, the quantum
第2の変換方式は、cleanまたはdirtyな補助ビットを用いて等価回路に変換する変換方式である。第2の変換方式では、k-2個の補助ビットを使って、Ck-NOTゲートを4k-8個のC2-NOTゲートに変換することができる。第2の変換方式では、すべての補助ビットがdirtyでも適用可能であり、汎用性が高い。他方、補助ビットが不足する場合には、補助ビット(cleanビットとdirtyビットの合計)がk-2個となるまで、補助ビットとして使用する量子ビットの追加が求められる。また第2の変換方式は、第1の変換方式に比べて、ゲート数が2k-5個増加する。 The second conversion method is a conversion method that converts into an equivalent circuit using clean or dirty auxiliary bits. In the second conversion method, a C k -NOT gate can be converted into 4k-8 C 2 -NOT gates using k-2 auxiliary bits. In the second conversion method, all auxiliary bits can be applied even if they are dirty, and it is highly versatile. On the other hand, when the auxiliary bits are insufficient, it is required to add quantum bits to be used as auxiliary bits until the auxiliary bits (the sum of clean bits and dirty bits) become k-2. In addition, the second conversion method increases the number of gates by 2k-5 compared to the first conversion method.
第3の変換方式は、1個の補助ビット(cleanビットまたはdirtyビット)を用いて等価回路に変換する変換方式である。第3の変換方式は、少ない数の補助ビットで変換が可能である。他方、第1または第2の変換方式に比べてゲート数が4k~6k個増加する。 The third conversion method is a conversion method that converts to an equivalent circuit using one auxiliary bit (clean bit or dirty bit). The third conversion method allows conversion with a small number of auxiliary bits. On the other hand, the number of gates increases by 4k to 6k compared to the first or second conversion method.
第4の変換方式は、第1・第2・第3の変換方式の欠点を補うことができる変換方式である。第4の変換方式は、少なくとも1個のcleanビットを使用可能な場合に、使用可能な補助ビットを有効に利用してより少ない量子ゲート数の等価回路に変換することができる変換方式である。第4の変換方式は、cleanビットがk-2個未満の場合でも、補助ビットの追加なしに適用可能であり、cleanビットがk-2以上のcleanビットを使用する第1の変換方式の欠点を補うことができる。また第4の変換方式は、第2・第3の変換方式よりも少ない量子ゲート数の等価回路に変換可能であり、第2・第3の変換方式における量子ゲート数が増加するという欠点を補うことができる。 The fourth conversion method is a conversion method that can compensate for the shortcomings of the first, second, and third conversion methods. The fourth conversion method is a conversion method that can convert into an equivalent circuit with a smaller number of quantum gates by effectively using available auxiliary bits when at least one clean bit is available. The fourth conversion method can be applied without adding auxiliary bits even when there are fewer than k-2 clean bits, and can compensate for the shortcomings of the first conversion method that uses k-2 or more clean bits. The fourth conversion method can also convert into an equivalent circuit with a smaller number of quantum gates than the second and third conversion methods, and can compensate for the shortcoming of the second and third conversion methods that the number of quantum gates is increased.
k-2個以上のcleanビットが利用可能な場合には、第1の変換方式によって最小の量子ゲート数の等価回路に変換可能である。そのため、第4の変換方式は、cleanビット数cが「1≦c≦k-3」の場合に有効となる。 When k-2 or more clean bits are available, the first conversion method can be used to convert to an equivalent circuit with the minimum number of quantum gates. Therefore, the fourth conversion method is effective when the number of clean bits c is "1≦c≦k-3".
例えばC7-NOTゲート61を等価回路に変換する際に使用できる補助ビットとして、cleanビットが1個(c=1)、dirtyビットが4個(d=4)ある場合を想定する。
For example, assume that there is one clean bit (c=1) and four dirty bits (d=4) as auxiliary bits that can be used when converting the C 7 -
図15は、第1の変換方式によるC7-NOTゲートの等価回路の一例を示す図である。C7-NOTゲート61は制御ビットの数が7個である。この場合、第1の変換方式で使用するcleanビットの数は5個である。そのため、cleanビットが4個不足する。すなわち、C7-NOTゲート61を第1の変換方式で変換するには、4個のcleanビットを追加することとなる。
15 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate according to the first conversion method. The C 7 -
5個のcleanビットが補助ビットとして使用できる場合、第1の変換方式によって等価回路62を生成することができる。上位の制御ビットから順に制御ビットの組が生成され、組ごとにC2-NOTゲートの結果がcleanビットに設定される。操作結果が設定されたcleanビットも制御ビットとして、同様のゲート操作が繰り返される。そして、6個目のC2-NOTゲートによって、C7-NOTゲート61による操作と同じ操作が、ターゲットビットに対して行われる。
When five clean bits can be used as auxiliary bits, an equivalent circuit 62 can be generated by the first conversion method. Sets of control bits are generated starting from the most significant control bit, and for each set, the result of the C 2 -NOT gate is set as the clean bit. The clean bit to which the operation result is set is also used as the control bit, and a similar gate operation is repeated. Then, the sixth C 2 -NOT gate performs the same operation as that by the C 7 -
後半の5個のC2-NOTゲートは、cleanビットであった補助ビットのclean化を行う量子ゲートである。これらのC2-NOTゲートがあることで、等価回路62は、ゲート操作後の補助ビットの状態も含めて、C7-NOTゲート61と等価となる。
The latter five C 2 -NOT gates are quantum gates that clean the ancillary bits that were previously clean bits. Due to the presence of these C 2 -NOT gates, the equivalent circuit 62, including the state of the ancillary bits after the gate operation, becomes equivalent to the C 7 -
等価回路62では、dirtyビットは使用されない。そのためdirtyビットは無駄となる。またcleanビットを追加することとなるため、使用する量子ビット数が増加する。また第1の変換方式を適用するためには、17個の量子ビットが使用可能であることが条件となる。量子コンピュータ200の量子ビットにおいて余分に使用できる量子ビットが十分になければ、第1の変換方式を適用することはできない。
In the equivalent circuit 62, dirty bits are not used. Therefore, the dirty bits are wasted. Also, because clean bits are added, the number of quantum bits used increases. Furthermore, in order to apply the first conversion method, it is necessary that 17 quantum bits are available. If there are not enough extra quantum bits available in the
図16は、第2の変換方式によるC7-NOTゲートの等価回路の一例を示す図である。C7-NOTゲート61に第2の変換方式を適用する場合、k-2個(5個)の補助ビットが使用される。そこで、cleanビットもdirtyビットと同等に扱うことで、C7-NOTゲート61を、第2の変換方式で等価回路63に変換することができる。
16 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate by the second conversion method. When the second conversion method is applied to the C 7 -
等価回路63では、先頭の5個のC2-NOTゲートは、補助ビット(cleanビットまたはdirtyビット)とC7-NOTゲート61の制御ビットとの組を、該当C2-NOTゲートの制御ビットとしている。先頭の5個のC2-NOTゲートの制御ビットに重複はない。先頭のC2-NOTゲートのターゲットビットは、C7-NOTゲート61のターゲットビットである。2個目から5個目のC2-NOTゲートのターゲットビットは、直前のC2-NOTゲートで制御ビットとして使用された補助ビットである。6個目のC2-NOTゲートの制御ビットは、C7-NOTゲート61の制御ビットのうちの、先頭の5個のC2-NOTゲートで使用していない制御ビットである。6個目のC2-NOTゲートのターゲットは、5個目のC2-NOTゲートで制御ビットとして使用された補助ビットである。
In the equivalent circuit 63, the first five C 2 -NOT gates use a pair of an auxiliary bit (clean bit or dirty bit) and the control bit of the C 7 -
7個目から11個目までのC2-NOTゲートは、1個目から5個目までのC2-NOTゲートを逆順に並べたものである。12個目から20個目までのC2-NOTゲートは、2個目から10個目までのC2-NOTゲートを逆順に並べたものである。 The seventh to eleventh C 2 -NOT gates are the first to fifth C 2 -NOT gates arranged in reverse order. The twelfth to twentieth C 2 -NOT gates are the second to tenth C 2 -NOT gates arranged in reverse order.
等価回路63の11個目のC2-NOTゲートによって、C7-NOTゲート61による操作と同じ操作が、ターゲットビットに対して行われる。後半の9個のC2-NOTゲートは、補助ビットの状態を元に戻す量子ゲートである。これらのC2-NOTゲートがあることで、等価回路63は、ゲート操作後の補助ビットの状態も含めて、C7-NOTゲート61と等価となる。
The eleventh C 2 -NOT gate in the equivalent circuit 63 performs the same operation on the target bit as the C 7 -
第2の変換方式では、cleanビットがdirtyビットとして扱われるため、cleanビットが有効に利用できていない。そのため、使用する量子ビット数は13個に抑えられているものの、等価回路63の量子ゲート数が20個と多くなっている。 In the second conversion method, clean bits are treated as dirty bits, so the clean bits are not used effectively. Therefore, although the number of quantum bits used is limited to 13, the number of quantum gates in the equivalent circuit 63 is large at 20.
図17は、第3の変換方式によるC7-NOTゲートの等価回路の一例を示す図である。C7-NOTゲート61に第3の変換方式を適用する場合、1つの補助ビットが使用される。第3の変換方式では、1つの補助ビット(図17の例ではcleanビット)を用いて、C7-NOTゲート61を4つのC4-NOTゲートに分割した等価回路64が生成される。等価回路64に含まれるC4-NOTゲートそれぞれを等価回路47(図5参照)に変換することで、C2-NOTゲートのみから構成される等価回路65が生成される。
17 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate by the third conversion method. When the third conversion method is applied to the C 7 -
第3の変換方式では、cleanビットがdirtyビットとして扱われるため、cleanビットが有効に利用できていない。また補助ビットを1つしか使用せず、多くのdirtyビットも有効に利用できていない。そのため、使用する量子ビット数は13個に抑えられているものの、等価回路65の量子ゲート数が32個と多くなっている。 In the third conversion method, clean bits are treated as dirty bits, so the clean bits are not used effectively. Also, only one auxiliary bit is used, so many dirty bits are not used effectively. Therefore, although the number of quantum bits used is limited to 13, the number of quantum gates in the equivalent circuit 65 is large at 32.
そこで、量子ゲート変換部130は、与えられたcleanビットとdirtyビットを可能な限り使用してゲート数を最小化する。特に量子ゲート変換部130は、cleanビット数cが「c=1,…,k-1」の場合には、第4の変換方式により、より量子ゲート数が少ない等価回路への変換を行う。
The quantum
量子ゲート変換部130は、Ck-NOTのk個の制御ビット群C={c1,・・・,ck}から、第1の変換方式と同様にcleanビット数だけ、2個の量子ビットの組を生成する。量子ゲート変換部130は、生成した2個の量子ビットを制御ビットとし、cleanビットをターゲットビットとするC2-NOTゲートを、等価回路に追加する。追加したC2-NOTゲートでターゲットビットになったcleanビットを、制御ビット群Cに追加する。この場合、cleanビットがk-2個以上あれば、第1の変換方式と同じとなる。このような変換方針を、第4の変換方式の基本的な方針とする。
The quantum
図18は、第4の変換方式の基本的な方針によるC7-NOTゲートの等価回路の一例を示す図である。図18に示すように、k=7であり、cleanビット数「c=5」の場合、C7-NOTゲート61は、第1の変換方式(図15参照)と同様に、11個のC2-NOTゲートを含む等価回路71に変換される。
Fig. 18 is a diagram showing an example of an equivalent circuit of a C 7 -NOT gate according to the basic principle of the fourth conversion method. As shown in Fig. 18, when k=7 and the number of clean bits "c=5", the C 7 -
cleanビット数がk-5未満の場合には、量子ゲート変換部130は、Ck-NOTゲート61の制御ビット数を段階的に減らしていく。その際、制御ビットを適切にグループ分けしないと、変換後の量子回路の量子ゲート数を十分に減らすことができない。
When the number of clean bits is less than k-5, the quantum
例えば、cleanビット数分の制御ビットの組を用いたC2-NOTゲートと、それらのC2-NOTゲートに使用していない制御ビットを用いたCk-NOTゲートとを含む等価回路に変換することが考えられる。 For example, it is possible to convert to an equivalent circuit that includes a C 2 -NOT gate using a set of control bits equal to the number of clean bits, and a C k -NOT gate using control bits not used in those C 2 -NOT gates.
図19は、k-2個未満のcleanビットしかない場合における第4の変換方式によるC7-NOTゲートの等価回路の第1の例を示す図である。図19の例では、k=7に対してc=1である。この場合、C7-NOTゲート61は、2つのC2-NOTゲートと1つのC6-NOTゲートとを含む等価回路72に変換されている。
19 is a diagram showing a first example of an equivalent circuit of a C 7 -NOT gate by the fourth conversion method when there are less than k-2 clean bits. In the example of FIG. 19, c=1 for k=7. In this case, the C 7 -
ここで、中央のC6-NOTゲートをさらに等価回路に変換する場合、使用できる補助ビットとしては、dirtyビットが2個(c1とc2)しかない。そのためC6-NOTゲートの等価回路への変換では、第3の変換方式しか適用できない。第3の変換方式を適用すると、C6-NOTゲートが24個のC2-NOTゲートに変換される。結果として、C7-NOTゲート61は計26個のC2-NOTゲートに変換される。このように、第3の変換方式を適用することによってゲート数が多くなってしまう。
Here, when the central C 6 -NOT gate is further converted into an equivalent circuit, there are only two dirty bits (c 1 and c 2 ) that can be used as auxiliary bits. Therefore, only the third conversion method can be applied to convert the C 6 -NOT gate into an equivalent circuit. When the third conversion method is applied, the C 6 -NOT gate is converted into 24 C 2 -NOT gates. As a result, the C 7 -
そこで量子ゲート変換部130は、分割後の中央のCk-NOTゲートに対して第2の変換方式が適用できるように、変換対象のCk-NOTゲートの制御ビット群を複数の部分群に分割する。これにより、最終的に生成される等価回路の量子ゲート数が削減される。
Therefore, the quantum
図20は、k-2個未満のcleanビットしかない場合における第4の変換方式によるC7-NOTゲートの等価回路の第2の例を示す図である。図20の例では、k=7に対してc=1の場合に、C7-NOTゲート61が、2つのC3-NOTゲート72a,72cと1つのC5-NOTゲート72bとを含む等価回路72に変換されている。
20 is a diagram showing a second example of an equivalent circuit of a C 7 -NOT gate by the fourth conversion method when there are less than k-2 clean bits. In the example of Fig. 20, when c=1 for k=7, the C 7 -
C3-NOTゲート72aの等価回路への変換では、制御ビット{c4,c5,c6}をdirtyな補助ビットとして使用できる。そのため、C3-NOTゲート72aは、第2の変換方式を用いて4個のC2-NOTゲートに変換できる。
In converting the C 3 -
C5-NOTゲート72bの等価回路への変換では、制御ビット{c1,c2,c3}をdirtyな補助ビットとして使用できる。そのため、C5-NOTゲート72bは、第2の変換方式を用いて12個のC2-NOTゲートに変換できる。
In converting the C 5 -
C3-NOTゲート72cの等価回路への変換では、制御ビット{c4,c5,c6}をdirtyな補助ビットとして使用できる。そのため、C3-NOTゲート72cは、第2の変換方式を用いて4個のC2-NOTゲートに変換できる。
In converting the C 3 -
このように、最初にC2-NOTゲートを生成するのではなくC3-NOTゲートを生成することで、中央のCk-NOTゲートがC5-NOTゲートになる。これにより、等価回路72に含まれる各Ck-NOTゲートを等価回路に変換する際に、k-2個以上の補助ビットが使用可能となる。その結果、第2の変換方式により、C7-NOTゲートを計20個のC2-NOTゲートに変換できる。 In this way, by first generating a C 3 -NOT gate instead of a C 2 -NOT gate, the central C k -NOT gate becomes a C 5 -NOT gate. This makes it possible to use k-2 or more auxiliary bits when converting each C k -NOT gate included in the equivalent circuit 72 into an equivalent circuit. As a result, the second conversion method can convert the C 7 -NOT gate into a total of 20 C 2 -NOT gates.
cleanビット数cが2個以上使用可能な場合、量子ゲート変換部130は、Ck-NOTゲートを2c+1個の量子ゲートに分割する。このとき量子ゲート変換部130は、c+1個の整数「k1,・・・,kc+1」を決定する。量子ゲート変換部130は、Ck_1-NOT,・・・,Ck_c-NOT,Ck_c+1-NOT,Ck_c-NOT,・・・,Ck_1-NOTと分割する。なお上付きのkに続く_以降の文字はkの下付きの添字を示す。例えば、上付きの「k_1,・・・,k_c+1」は、それぞれ上付きの整数「k1,・・・,kc+1」を表している。
When the number of clean bits c is two or more, the quantum
量子ゲート変換部130は、分割後の量子ゲートの制御ビット数(分割後制御ビット数)を示す整数について、k1≧k2≧・・・≧kcを満たすもののうち、以下の2条件を満たすように決定する。ただしkc+1は、以下の式を満たす。
The quantum
[条件1]ck_c+1-NOTゲートに対して第2の変換方式が使用できる。つまり、dirtyビットがkc+1-2個確保できる。
[条件2]ki>c-i+2かつkj<c-j+2を満たす1≦i<j≦cが存在しない。
[Condition 1] The second conversion method can be used for the c k_c+1 -NOT gate, which means that k c+1 -2 dirty bits can be secured.
[Condition 2] There exists no such condition that 1≦i<j≦c such that k i >c−i+2 and k j <c−
このとき量子ゲート変換部130は、1≦i≦c-1でCk_i-NOTゲートをC2-NOTゲートに変換する際に、i+1番目からc番目までのcleanビットを使用できる。また1≦i≦c-1におけるCk_i-NOTゲートをC2-NOTゲートに変換する際にはdirtyビットが十分に確保できる。そのため、前述の「基本的な方針+第2の変換方式」を適用可能である。
In this case, the quantum
条件1は、制御ビットがたくさんあるCk_i-NOTゲートにできる限り多くのcleanビットを確保するための条件である。
条件2は、cleanビットを過不足なく使用するための条件である。もし、ki>c-i+2かつkj<c-j+2を満たす1≦i<j≦cが存在したとき、ki←ki-1,kj←kj+1とした新たな分割において、特にCk_j-NOTゲートの変換において当初の分割よりcleanビットを有効活用できていることが確認できる。すなわち量子ゲート変換部130は、条件2が満たされない場合、ki←ki-1,kj←kj+1と分割後制御ビット数を変更することにより、当初の分割より量子ゲート数を4つ削減できる。
図21は、c=2の場合における第4の変換方式による分割の一例を示す図である。図21の例では、C12-NOTゲート73を等価回路74に変換する場合が想定されている。そしてcleanビット数cは2個である(k=12,c=2)。この場合、第4の変換方式による分割で得られたCk_i-NOTゲートの分割後制御ビット数を示す整数は、「k1=k2=3,k3=8」となる。
Fig. 21 is a diagram showing an example of division by the fourth transformation method when c=2. In the example of Fig. 21, it is assumed that a C 12 -
「k1=3」であるため等価回路74の最初の量子ゲートは、C3-NOTゲート74aである。「k2=3」であるため等価回路74の2番目の量子ゲートは、C3-NOTゲート74bである。「k3=8」であるため等価回路74の3番目の量子ゲート(中央の量子ゲート)は、C8-NOTゲート74cである。「k2=3」であるため等価回路74の4番目の量子ゲートは、C3-NOTゲート74dである。「k1=3」であるため等価回路74の5番目の量子ゲートは、C3-NOTゲート74eである。
Since "k 1 = 3", the first quantum gate of the equivalent circuit 74 is a C 3 -
C3-NOTゲート74a,74eの等価回路への変換では、1つのcleanビットを補助ビットとして使用可能である。C3-NOTゲート74a,74eに対して第4の変換方式を適用することができる。そのためC3-NOTゲート74a,74eそれぞれは、第4の変換方式の基本的な方針に基づいて、cleanビットを用いて3つのC2ーNOTゲートを含む等価回路42(図4参照)に変換できる。C3-NOTゲート74b,74dの等価回路への変換では、1つのdirtyビットを補助ビットとして使用可能である。そのためC3-NOTゲート74b,74dそれぞれは、dirtyビットを用いて4つのC2ーNOTゲートを含む等価回路43(図4参照)に変換できる。C8-NOTゲート74cの等価回路への変換では、6個のdirtyビットを補助ビットとして使用可能である。そのためC8-NOTゲート74cは、第2の変換方式により24個のC2-NOTゲートに変換できる。
In the conversion to the equivalent circuit of the C 3 -
以上より、量子ゲート変換部130は、等価回路74内の各Ck-NOTゲートを等価回路に変換することで、C12-NOTゲート73を、合計38個のC2-NOTゲートを含む等価回路に変換することができる。
As described above, the quantum
図22は、c=3の場合における第4の変換方式による分割の一例を示す図である。図22の例では、C12-NOTゲート73を等価回路75に変換する場合が想定されている。そしてcleanビット数cは3個である(k=12,c=3)。この場合、第4の変換方式による分割位置を示す整数は、「k1=3,k2=k3=2,k3=8」となる。
Fig. 22 is a diagram showing an example of division by the fourth transformation method when c=3. In the example of Fig. 22, it is assumed that a C 12 -
「k1=3」であるため等価回路75の最初の量子ゲートは、C3-NOTゲート75aである。「k2=2」であるため等価回路75の2番目の量子ゲートは、C2-NOTゲート75bである。「k3=2」であるため等価回路75の3番目の量子ゲートは、C2-NOTゲート75cである。「k4=8」であるため等価回路75の4番目の量子ゲート(中央の量子ゲート)は、C8-NOTゲート75dである。「k3=2」であるため等価回路75の5番目の量子ゲートは、C2-NOTゲート75eである。「k2=2」であるため等価回路75の6番目の量子ゲートは、C2-NOTゲート75fである。「k1=3」であるため等価回路75の7番目の量子ゲートは、C3-NOTゲート75gである。
Since "k 1 =3", the first quantum gate of the equivalent circuit 75 is a C 3 -
C3-NOTゲート75a,75gの等価回路への変換では、1つのcleanビットを補助ビットとして使用可能である。そのためC3-NOTゲート75a,75gそれぞれは、cleanビットを用いて3つのC2ーNOTゲートを含む等価回路42(図4参照)に変換できる。C8-NOTゲート75dの等価回路への変換では、6個のdirtyビットを補助ビットとして使用可能である。そのためC8-NOTゲート75dは、第2の変換方式により24個のC2-NOTゲートに変換できる。
In converting the C 3 -
以上より、量子ゲート変換部130は、等価回路75内の各Ck-NOTゲートを等価回路に変換することで、C12-NOTゲート73を、合計34個のC2-NOTゲートを含む等価回路に変換することができる。
As described above, the quantum
次に、このような変換処理を実現するために量子ゲート変換部130が有する機能について説明する。
図23は、量子ゲート変換部が有する機能の一例を示す図である。量子ゲート変換部130は、量子ゲート変換管理部131、分割方法決定部132、および量子回路生成部133を有する。
Next, the functions of the quantum
23 is a diagram showing an example of functions of the quantum
量子ゲート変換管理部131は、分割方法決定部132と量子回路生成部133と連係し、入力されたCk-NOTゲートを等価回路「qc」に変換する。例えば量子ゲート変換管理部131には、Ck-NOTゲートを示す情報、「tmpCleanBitList」、「tmpDirtyBitList」が入力される。Ck-NOTゲートを示す情報には、制御ビットのリストC={c1,・・・,ck}とターゲットビットの識別番号「x」とが含まれる。「tmpCleanBitList」は、cleanビットとして使用可能な量子ビットのリスト「CA={ca1,・・・,cac}」である。cはcleanビット数である(ただし、1≦c≦k-3)。「tmpDirtyBitList」は、dirtyビットとして使用可能な量子ビットのリスト「DA={da1,・・・,dad}」である。dはdirtyビット数である。
The quantum gate
分割方法決定部132は、k,c,dの値に応じて、最終的なC2-NOTゲートの数が最小となるようなCk-NOTゲートの分割後の量子ゲートの制御ビット数(k1,・・・,kc+1)を決定する。
The division
量子回路生成部133は、分割方法決定部132で決定した分割後の量子ゲートの制御ビット数(k1,・・・,kc+1)を受け取り、Ck-NOTゲートの等価回路「qc」(C2-NOTゲートのみからなる)を出力する。
The quantum
次に、量子ゲート変換部130による量子ゲート変換処理の手順について詳細に説明する。
図24は、量子ゲート変換処理の手順の一例を示すフローチャートである。以下、図24に示す処理をステップ番号に沿って説明する。
Next, the procedure of the quantum gate conversion process performed by the quantum
24 is a flowchart showing an example of a procedure for quantum gate conversion processing. The processing shown in FIG. 24 will be described below in order of step numbers.
[ステップS301]量子ゲート変換管理部131は、cleanビット数cが0(c=0)であり、かつdirtyビット数dが1以上(d≧1)という条件が満たされるか否かを判断する。量子ゲート変換管理部131は、条件が満たされる場合、処理をステップS302に進める。また量子ゲート変換管理部131は、条件が満たされない場合、処理をステップS303に進める。
[Step S301] The quantum gate
[ステップS302]量子ゲート変換管理部131は、量子回路生成部133に対して、変換対象のCk-NOTゲートと等価の量子回路の生成を指示する。量子回路生成部133は、変換対象のCk-NOTゲートの等価回路「qc」を、第3の変換方式によって生成する。量子ゲート変換管理部131は、量子回路生成部133から等価回路「qc」を取得すると、処理をステップS307に進める。
[Step S302] The quantum gate
[ステップS303]量子ゲート変換管理部131は、cleanビット数cがk-2以上である(c≧k-2)という条件が満たされるか否かを判断する。量子ゲート変換管理部131は、条件が満たされる場合、処理をステップS304に進める。また量子ゲート変換管理部131は、条件が満たされない場合、処理をステップS305に進める。
[Step S303] The quantum gate
[ステップS304]量子ゲート変換管理部131は、量子回路生成部133に対して、変換対象のCk-NOTゲートと等価の量子回路の生成を指示する。量子回路生成部133は、変換対象のCk-NOTゲートの等価回路「qc」を、第1の変換方式によって生成する。量子ゲート変換管理部131は、量子回路生成部133から等価回路「qc」を取得すると、処理をステップS307に進める。
[Step S304] The quantum gate
[ステップS305]量子ゲート変換管理部131は、分割方法決定部132に対して、分割方法の決定を指示する。分割方法決定部132は、指示に従って、Ck-NOTゲートを分割して得られるCk_i-NOTゲートの分割後制御ビット数を決定する。量子ゲート変換管理部131は、分割方法決定部132から、分割後制御ビット数を示す整数の組を取得する。分割方法決定処理の詳細は後述する(図25参照)。
[Step S305] The quantum gate
[ステップS306]量子ゲート変換管理部131は、量子回路生成部133に、第4の変換方式でのCk-NOTゲートと等価な量子回路の生成を指示する。量子回路生成部133は、第4の変換方式によりCk-NOTゲートの等価回路「qc」を生成する。量子ゲート変換管理部131は、量子回路生成部133から等価回路「qc」を取得する。
[Step S306] The quantum gate
[ステップS307]量子ゲート変換管理部131は、等価回路「qc」を、変換対象のCk-NOTゲートの等価回路として出力する。
このように、第1の変換方式が適用可能な場合には、第1の変換方式によりCk-NOTゲートが等価回路に変換される。また適用可能な変換方式が第3の変換方式に限定される場合には、第3の変換方式によりCk-NOTゲートが等価回路に変換される。それ以外の場合には、第4の変換方式によりCk-NOTゲートが等価回路に変換される。
[Step S307] The quantum gate
In this way, when the first conversion method is applicable, the C k -NOT gate is converted into an equivalent circuit by the first conversion method. When the applicable conversion method is limited to the third conversion method, the C k -NOT gate is converted into an equivalent circuit by the third conversion method. In other cases, the C k -NOT gate is converted into an equivalent circuit by the fourth conversion method.
次に、分割方法決定処理の手順について詳細に説明する。
図25は、分割方法決定処理の手順の一例を示すフローチャートである。以下、図25に示す処理をステップ番号に沿って説明する。
Next, the division method determination process will be described in detail.
25 is a flowchart showing an example of a division method determination process. The process shown in FIG. 25 will be described below in order of step number.
[ステップS401]分割方法決定部132は、初期設定を行う。例えば分割方法決定部132は、k1=k2=・・・=kc=2とする。また分割方法決定部132は、kc+1を式(1)のように設定する。「k1,・・・,kc」が初期値「2」の場合、式(1)の右辺の「ki-1」はすべて1となり、右辺は「k-c」となる。すなわちkc+1の初期値は、変換対象のCk-NOTゲートの制御ビット数kからcleanビット数cを減算した値である。
[Step S401] The division
[ステップS402]分割方法決定部132は、変数jを「1」に初期化する(j=1)。
[ステップS403]分割方法決定部132は、以下の式(2)を満たすか否かにより終了判定を行う。
[Step S402] The division
[Step S403] The division
式(2)は、Ck_c+1-NOTゲートの実行時点でdirtyな補助ビットとして使用可能な量子ビットの数が、kc+1-2個以上あるという条件を示している。この条件は、第2の変換方式の適用条件である。Ck_c+1-NOTゲートの実行時点でdirtyな補助ビットとして使用可能なのは、DAに含まれる要素数と、Ck_1-NOTゲートからCk_c-NOTゲートまでの各量子ゲートで制御ビットとして使用される量子ビット数との合計である。 Equation (2) indicates a condition that the number of quantum bits usable as dirty auxiliary bits at the time of execution of the C k_c+1 -NOT gate is k c+1 -2 or more. This condition is an application condition of the second conversion method. The number of quantum bits usable as dirty auxiliary bits at the time of execution of the C k_c+1 -NOT gate is the sum of the number of elements included in the DA and the number of quantum bits used as control bits in each quantum gate from the C k_1 -NOT gate to the C k_c -NOT gate.
分割方法決定部132は、終了判定の条件が満たされた場合、処理をステップS407に進める。また分割方法決定部132は、終了判定の条件が満たされない場合、処理をステップS404に進める。
If the condition for the termination judgment is satisfied, the division
[ステップS404]分割方法決定部132は、kjに「1」を加算する(kj←kj+1)。また分割方法決定部132は、kc+1から「1」を減算する(kc+1←kc+1-1)。
[Step S404] The division
[ステップS405]分割方法決定部132は、kjがc-j+2以上か否かを判断する(kj≧c-j+2?)。分割方法決定部132は、kjがc-j+2以上であれば、処理をステップS406に進める。また分割方法決定部132は、kjがc-j+2未満であれば、処理をステップS403に進める。
[Step S405] The division
ステップS405の処理により、前述の条件2(ki>c-i+2かつkj<c-j+2を満たす1≦i<j≦cが存在しない。)が満たされる。すなわち、ステップS404でkjに「1」を加算した後に「kj≧c-j+2」となっていなければ、終了判定が満足しない限り、さらにkjに「1」が加算される。「kj≧c-j+2」が満たされるとそれ以上加算されないため「kj>c-j+2」とはならない。
The process of step S405 satisfies the above-mentioned condition 2 (there is no 1≦i<j≦c such that k i >c-
またCk_j-NOTゲートの等価回路への変換時に使用可能なcleanビット数「c-j」が少ない場合がある。例えば「c-j=0」の場合、kjについての初期値「kj=2」に対するステップS404による1回目の加算で「kj=3」となったときに「kj>c-j+2」となる。それに対して、Ck_p-NOTゲート(j<p≦c)の等価回路への変換時に使用可能なcleanビット数「c-p」は「c-j」よりも少ない(例えば「c-j=-1」)。そのため、例えば初期値のままの「kp=2」であっても「kp<c-j+2」とはならず、「kp<c-j+2」は満たされない。
Also, the number of clean bits "c-j" available when converting to an equivalent circuit of a C k_j -NOT gate may be small. For example, in the case of "c-j=0", when the initial value "k j =2" for k j is added for the first time in step S404 to "k j =3", "k j >c-
以上のことから、kj>c-j+2かつkp<c-p+2を満たす1≦j<p≦cは存在しない。jをiに置き換え、pをjに置き換えても同じであるため、ステップS405があることで条件2が満たされる。条件2が満たされることで、cleanビットが有効に活用され、等価回路に変換された後の量子ゲート数が削減される。
From the above, there is no 1≦j<p≦c that satisfies k j >c-
[ステップS406]分割方法決定部132は、jをcで除算した剰余に1を加算して得た値に、jを更新する(j←(j mod c)+1)。その後、分割方法決定部132は処理をステップS403に進める。
[Step S406] The division
[ステップS407]分割方法決定部132は、「k1,・・・,kc+1」を出力し、分割方法決定処理を終了する。出力された「k1,・・・,kc+1」は、分割後の量子ゲート数が2c+1であり、それぞれの制御ビット数が「k1,・・・,kc,kc+1,kc,,・・・,k1」となることを示している。
[Step S407] The division
このようにして、分割後のCk_1-NOTゲート、Ck_2-NOTゲート、・・・それぞれの制御ビットの数が決定される。決定された変換対象のCk-NOTゲートを決定された大きさの量子ゲートに分割することで、最終的に生成される等価回路の量子ゲート数を削減することができる。 In this way, the number of control bits is determined for each of the divided C k_1 -NOT gates, C k_2 -NOT gates, .... By dividing the determined C k -NOT gate to be converted into quantum gates of determined sizes, the number of quantum gates in the finally generated equivalent circuit can be reduced.
次に、第4の変換方式での量子回路生成処理の手順について詳細に説明する。
図26は、第4の変換方式での等価回路生成処理の手順の一例を示すフローチャートである。以下、図26に示す処理をステップ番号に沿って説明する。
Next, the procedure of the quantum circuit generation process in the fourth transformation method will be described in detail.
26 is a flow chart showing an example of the procedure of an equivalent circuit generation process in the fourth conversion method. The process shown in FIG. 26 will be described below in order of step numbers.
[ステップS501]量子回路生成部133は、分割後制御ビット数を示す整数の組「k1,,・・・,kc,kc+1」に従って、Ck-NOTゲートを分割する。分割処理により、Ck_1-NOTゲート、・・・、Ck_c-NOTゲート、Ck_c+1-NOTゲート、・・・、Ck_c-NOTゲート、・・・、Ck_1-NOTゲートが生成される。
[Step S501] The quantum
[ステップS502]量子回路生成部133は、空の等価回路「qc」を生成する(qc=[])。
[ステップS503]量子回路生成部133は、変数iに初期値「1」を設定する。
[Step S502] The quantum
[Step S503] The quantum
[ステップS504]量子回路生成部133は、変数iの値がcleanビット数c以下か否かを判断する。量子回路生成部133は、変数iの値がcleanビット数c以下であれば、処理をステップS505に進める。また量子回路生成部133は、変数iの値がcleanビット数cを超えている場合、処理をステップS508に進める。
[Step S504] The quantum
[ステップS505]量子回路生成部133は、Ck_i-NOTゲート(分割後のi番目の量子ゲート)を、C2-NOTゲートを用いた等価回路へ変換する処理(Ck_i-NOTゲート変換処理)を行う。変換処理で生成された等価回路を「circ」とする。Ck_i-NOTゲート変換処理の詳細は後述する(図27、図28参照)。なおCk_i-NOTゲート変換処理の過程で、Ck_i-NOTゲートにおいて制御ビットとなった量子ビットは制御ビットのリストCから削除される。
[Step S505] The quantum
[ステップS506]量子回路生成部133は、等価回路「qc」に等価回路「circ」を追加する。
[ステップS507]量子回路生成部133は、変数iに1を加算する(i←i+1)。その後、量子回路生成部133は処理をステップS504に進める。
[Step S506] The quantum
[Step S507] The quantum
[ステップS508]量子回路生成部133は、等価回路「qc」に含まれる量子ゲートを逆順に並べた量子回路「qcinv」を生成する。
[ステップS509]量子回路生成部133は、分割後の中央の量子ゲートであるCk_(c+1)-NOTゲートを、第2の変換方式でC2-NOTゲートを用いた等価回路へ変換する。Ck_(c+1)-NOTゲートの制御ビットは、制御ビットのリストCに残されている量子ビットである。Ck_(c+1)-NOTゲートのターゲットビットは、変換対象のCk-NOTゲートのターゲットビットxと同じである。
[Step S508] The quantum
[Step S509] The quantum
例えば量子回路生成部133は、制御ビットのリストCに含まれる要素の個数Lを「L=kc+1」とする。量子回路生成部133は、DAに含まれるdirtyビットのうちの先頭の2つを補助ビットとして利用して、第2の変換方式によりCk_(c+1)-NOTゲートを等価回路に変換する。量子回路生成部133は、変換によって生成された等価回路を「circ」とする。
For example, the quantum
[ステップS510]量子回路生成部133は、ステップS509で生成された等価回路「circ」を等価回路「qc」に追加する。
[ステップS511]量子回路生成部133は、ステップS508で生成した量子回路「qcinv」を等価回路「qc」に追加する。
[Step S510] The quantum
[Step S511] The quantum
このようにして、分割後の量子ゲートそれぞれが、C2-NOTゲートのみで構成された等価回路に変換される。その結果、変換対象の元のCk-NOTゲートの等価回路「qc」が生成される。 In this way, each of the divided quantum gates is converted into an equivalent circuit composed only of C 2 -NOT gates, resulting in the generation of an equivalent circuit "qc" of the original C k -NOT gate to be converted.
図27は、Ck_i-NOTゲート変換処理の手順の一例を示すフローチャート(1/2)である。以下、図27に示す処理をステップ番号に沿って説明する。
[ステップS601]量子回路生成部133は、等価回路「circ」を空欄にする(circ=[])。
27 is a flowchart (1/2) showing an example of the procedure of the C k_i -NOT gate conversion process. The process shown in FIG. 27 will be described below in order of step numbers.
[Step S601] The quantum
[ステップS602]量子回路生成部133は、kiが「2」か否かを判断する(ki=2?)。量子回路生成部133は、kiが「2」であれば処理をステップS603に進める。また量子回路生成部133は、kiが「2」でなければ処理をステップS607に進める。
[Step S602] The quantum
[ステップS603]量子回路生成部133は、Cの始めの2つの量子ビット(C[0],C[1])を制御ビットとし、CAのi番目の量子ビット(CA[i])をターゲットビットとするC2-NOTゲートを等価回路「circ」に追加する。
[Step S603] The quantum
[ステップS604]量子回路生成部133は、等価回路「circ」に追加したC2-NOTゲートにおける制御ビット(Cの始めの2つの量子ビット)をCから削除する。そして量子回路生成部133は、それらの量子ビットをDAに追加する。
[Step S604] The quantum
[ステップS605]量子回路生成部133は、等価回路「circ」に追加したC2-NOTゲートにおけるターゲットビットであるCA[i]を、DAに追加する。
[ステップS606]量子回路生成部133は、等価回路「circ」に追加したC2-NOTゲートにおけるターゲットビットであるCA[i]を、Cに追加する。その後、量子回路生成部133は、処理をステップS627(図28参照)に進める。
[Step S605] The quantum
[Step S606] The quantum
[ステップS607]量子回路生成部133は、Cの先頭からki個の量子ゲートのリストCtmpを作成する。
[ステップS608]量子回路生成部133は、空の量子回路「qctmp1」を作成する(qctmp1=[])。
[Step S607] The quantum
[Step S608] The quantum
[ステップS609]量子回路生成部133は、CからCtmpの要素を除外したリストをDAtmpとする(DAtmp←C\Ctmp)。
[ステップS610]量子回路生成部133は、ki-2とc-iとのうちの小さい方の値をpに設定する(p=min{ki-2,c-i})。
[Step S609] The quantum
[Step S610] The quantum
[ステップS611]量子回路生成部133は、jとiを「1」に初期化する(j=i=1)。
[ステップS612]量子回路生成部133は、jの値がi+p以下か否かを判断する(j≦i+p?)。量子回路生成部133は、jの値がi+p以下であれば、処理をステップS613に進める。また量子回路生成部133は、jの値がi+pを超えている場合、処理をステップS618に進める。
[Step S611] The quantum
[Step S612] The quantum
[ステップS613]量子回路生成部133は、Ctmpの先頭から2つの量子ビット(Ctmp[0],Ctmp[1])を制御ビットとし、CAのj番目の量子ビット(CA[j])をターゲットビットとするC2-NOTゲートを量子回路「qctmp1」に追加する。
[Step S613] The quantum
[ステップS614]量子回路生成部133は、量子回路「qctmp1」に追加したC2-NOTゲートの制御ビット(Ctmp[0],Ctmp[1])を、DAtmpに追加する。
[ステップS615]量子回路生成部133は、量子回路「qctmp1」に追加したC2-NOTゲートの制御ビット(Ctmp[0],Ctmp[1])を、Ctmpから削除する。
[Step S614] The quantum
[Step S615] The quantum
[ステップS616]量子回路生成部133は、量子回路「qctmp1」に追加したC2-NOTゲートのターゲットビット(CA[j])をCtmpに追加する。
[ステップS617]量子回路生成部133は、jの値に1を加算する(j←j+1)。その後、量子回路生成部133は、処理をステップS612に進める。
[Step S616] The quantum
[Step S617] The quantum
[ステップS618]量子回路生成部133は、Lにki-pを設定する(L←ki-p)。その後、量子回路生成部133は、処理をステップS621(図28参照)に進める。
[Step S618] The quantum
図28は、Ck_i-NOTゲート変換処理の手順の一例を示すフローチャート(2/2)である。以下、図28に示す処理をステップ番号に沿って説明する。
[ステップS621]量子回路生成部133は、L=2か否かを判断する(L=2?)。量子回路生成部133は、L=2であれば処理をステップS622に進める。また量子回路生成部133は、L=2でなければ処理をステップS623に進める。
28 is a flowchart (2/2) showing an example of the procedure of the C k_i -NOT gate conversion process. The process shown in FIG. 28 will be described below in order of step numbers.
[Step S621] The quantum
[ステップS622]量子回路生成部133は、Ctmpの先頭の2つの量子ビット(Ctmp[0],Ctmp[1])を制御ビットとし、CAのi番目の量子ビット(CA[i])をターゲットビットとするC2-NOTゲートを、等価回路「qctmp2」とする。その後、量子回路生成部133は、処理をステップS624に進める。
[Step S622] The quantum
[ステップS623]量子回路生成部133は、Ctmpの量子ビットを制御ビットとし、CAのi番目の量子ビットをターゲットビットとするCL-NOTゲートを、DAtmpの先頭のL-2個をdirtyビットとして第2の変換方式で等価回路に変換する。量子回路生成部133は、変換によって得られた等価回路「qctmp2」を出力する。
[Step S623] The quantum
[ステップS624]量子回路生成部133は、量子回路「qctmp1」内のC2-NOTゲートを逆順にならべた量子回路「qctmp1_inv」を生成する。
[ステップS625]量子回路生成部133は、等価回路「circ」に「qctmp1」,「qctmp2」,「qctmp1_inv」を追加する。
[Step S624] The quantum
[Step S625] The quantum
[ステップS626]量子回路生成部133は、Cの先頭からki個の要素をCから削除する。また量子回路生成部133は、Cから削除した要素をDAに追加する。さらに量子回路生成部133は、Cに、CAのi番目の要素(CA[i])を追加する。
[Step S626] The quantum
[ステップS627]量子回路生成部133は、等価回路「circ」を出力する。
図27、図28に示した処理により、cleanビット数分の量子回路(Ck_1-NOTゲート,・・・,Ck_c-NOTゲート)それぞれが、C2-NOTゲートを組み合わせた等価回路に変換され、変換後の等価回路が等価回路「circ」に追加される。
[Step S627] The quantum
By the processing shown in Figures 27 and 28, each of the quantum circuits (C k_1 -NOT gate, ..., C k_c -NOT gate) for the number of clean bits is converted into an equivalent circuit combining C 2 -NOT gates, and the converted equivalent circuit is added to the equivalent circuit "CIRC".
次に、Ck-NOTゲートの変換処理について具体例を用いて説明する。
図29は、Ck-NOTゲートの変換の一例を示す図である。変換対象のCk-NOTゲート61は、制御ビット数が「7」である(k=7)。そして、1個のcleanビットと4個のdirtyビットが使用できるものとする。
Next, the conversion process of the C k -NOT gate will be explained using a concrete example.
29 is a diagram showing an example of conversion of a C k -NOT gate. The C k -
量子ゲート変換部130への入力は、制御ビット「C={c1,・・・,c7}」、ターゲットビットx、tmpCleanBitList「CA={ca1}」、tmpDirtyBitList「DA={da1,・・・,da4}」である。量子ゲート変換管理部131は、まず分割方法決定部132に、「k=7」、「c=1」、「d=4」を入力する。
The inputs to the quantum
分割方法決定部132は、「k1=2」、「k2=6」の場合に終了判定の条件「k2-2≦d+k1」の左辺が「4」、右辺が「6」となり、終了判定の条件が満たされると判断する。そこで分割方法決定部132は、「k1=2」、「k2=6」を出力する。
When " k1 = 2" and " k2 = 6", the division
量子ゲート変換管理部131は、分割方法決定部132の出力結果に基づいて、量子回路生成部133に「C」、「CA」、「DA」、「k1=2」、「k2=6」を入力する。すると量子回路生成部133は、まず空の等価回路「qc=[]」を生成する。
The quantum gate
次に量子回路生成部133は、「i=1」として、「qc=[]」に、「c1,c2」を制御ビットとし、ca1をターゲットビットとするC2-NOTゲート76aを追加する。このとき量子回路生成部133は、制御ビットを「C={c3,・・・,c7}」と更新し、「tmpDirtyBitList」を「DA={da1,・・・,da4,c1,c2}」と更新する。さらに量子回路生成部133は、「qc」に含まれる量子ゲートを逆順に並べた量子回路「qcinv」を生成する。図29の例では、「qcinv」に含まれるのはC2-NOTゲート76cだけである。
Next, the quantum
量子回路生成部133は、「C={c3,・・・,c7}」のすべての量子ビットを制御ビットとし、xをターゲットビットとするC6-NOTゲートを、第2の変換方式により、C2-NOTゲートのみで構成される等価回路76bに変換する。その際、量子回路生成部133は、「DA={da1,・・・,da4,c1,c2}」をdirtyビットとする。量子回路生成部133は、生成した等価回路76bを「qc」に追加する。さらに量子回路生成部133は、「qc」に「qcinv」内のC2-NOTゲート76cを追加する。
The quantum
その結果、C2-NOTゲート61の等価回路76が出力される。出力された等価回路76の量子ビット数は「13」であり、ゲート数は「18」である。図15に示した第1の変換方式(量子ビット数「17」、量子ゲート数「11」)と比較すると、第4の変換方式の方が少ない量子ビット数で済んでいる。図16に示した第2の変換方式(量子ビット数「13」、量子ゲート数「20」)と比較すると、第4の変換方式の方が少ない量子ゲート数で済んでいる。図17に示した第3の変換方式(量子ビット数「13」、量子ゲート数「32」)と比較すると、第4の変換方式の方が少ない量子ゲート数で済んでいる。
As a result, an equivalent circuit 76 of the C 2 -
このように、第4の変換方式で変換を行うことで、使用する量子ビット数を増やすことができない条件下で、変換後の量子回路の量子ゲート数を最小にすることができる。量子ゲート数が少なくなることで、量子コンピュータ200による計算時間を短縮することができる。
In this way, by performing the conversion using the fourth conversion method, it is possible to minimize the number of quantum gates in the quantum circuit after conversion under the condition that the number of quantum bits used cannot be increased. By reducing the number of quantum gates, it is possible to shorten the calculation time by the
変換対象のCk-NOTゲートの制御ビット数kの数がさらに多い場合にも、同様に第4の変換方式を適用することで、使用する量子ビット数を増やさずに変換の量子ゲート数を削減することができる。例えば、図21に示したC12-NOTゲート73を変換するものとする。変換後の等価回路の量子ゲート数は、使用できるcleanビット数「c」とdirtyビット数「d」とに応じて変わる。
Even if the number of control bits k of the C k -NOT gate to be converted is larger, the number of quantum gates for conversion can be reduced without increasing the number of quantum bits used by applying the fourth conversion method in the same manner. For example, assume that the C 12 -
<c=0の場合>
1≦d≦k-3ならば、C12-NOTゲート73は、第3の変換方式により、72個のC2-NOTゲートの等価回路に変換可能である。d≧k-3ならば、第2の変換方式により40個のC2-NOTゲートの等価回路に変換可能である。
<When c=0>
If 1≦d≦k-3, the C 12 -
<c=1の場合>
d=0ならば、k1=6,k2=7となり、等価回路のC2-NOTゲート数は「52」となる。d=1ならば、k1=5,k2=8となり、等価回路のC2-NOTゲート数は「48」となる。d=2ならば、k1=5,k2=8となり、等価回路のC2-NOTゲート数は「48」となる。d=3ならば、k1=4,k2=9となり、等価回路のC2-NOTゲート数は「44」となる。d=4ならば、k1=4,k2=9となり、等価回路のC2-NOTゲート数は「44」となる。d=5ならば、k1=3,k2=10となり、等価回路のC2-NOTゲート数は「40」となる。d=6ならば、k1=3,k2=10となり、等価回路のC2-NOTゲート数は「40」となる。d≧7ならば、k1=2,k2=11となり、等価回路のC2-NOTゲート数は「38」となる。
<In the case of c=1>
If d=0, k 1 =6, k 2 =7, and the number of C 2 -NOT gates in the equivalent circuit is "52". If d=1, k 1 =5, k 2 =8, and the number of C 2 -NOT gates in the equivalent circuit is "48". If d=2, k 1 =5, k 2 =8, and the number of C 2 -NOT gates in the equivalent circuit is "48". If d=3, k 1 =4, k 2 =9, and the number of C 2 -NOT gates in the equivalent circuit is "44". If d=4, k 1 =4, k 2 =9, and the number of C 2 -NOT gates in the equivalent circuit is "44". If d=5, k 1 =3, k 2 =10, and the number of C 2 -NOT gates in the equivalent circuit is "40". If d=6, then k 1 =3, k 2 =10, and the number of C 2 -NOT gates in the equivalent circuit is 40. If d≧7, then k 1 =2, k 2 =11, and the number of C 2 -NOT gates in the equivalent circuit is 38.
<c=2の場合>
d=0,1ならば、k1=3,k2=3,k3=8となり、等価回路のC2-NOTゲート数は「38」となる。d=2,3ならば、k1=3,k2=2,k3=9となり、等価回路のC2-NOTゲート数は「36」となる。d≧4ならば、k1=2,k2=2,k3=10となり、等価回路のC2-NOTゲート数は「36」となる。
<When c=2>
If d=0,1, then k1 =3, k2 =3, k3 =8, and the number of C2 -NOT gates in the equivalent circuit is 38. If d=2,3, then k1 =3, k2 =2, k3 =9, and the number of C2 -NOT gates in the equivalent circuit is 36. If d≧4, then k1 =2, k2 =2, k3 =10, and the number of C2 -NOT gates in the equivalent circuit is 36.
<c=3の場合>
d=0ならば、k1=3,k2=2,k3=2,k4=8となり、等価回路のC2-NOTゲート数は「34」となる。d≧1ならば、k1=2,k2=2,k3=2,k4=9となり、等価回路のC2-NOTゲート数は「34」となる。
<When c=3>
If d = 0, then k 1 = 3, k 2 = 2, k 3 = 2, k 4 = 8, and the number of C 2 -NOT gates in the equivalent circuit is 34. If d ≥ 1, then k 1 = 2, k 2 = 2, k 3 = 2, k 4 = 9, and the number of C 2 -NOT gates in the equivalent circuit is 34.
<c=4~9の場合>
dの値にかかわらず、k1=・・・=kc=2,kc+1=12-cとなり、等価回路のC2-NOTゲート数は「40-2c」となる。
<When c=4 to 9>
Regardless of the value of d, k 1 = . . . = k c = 2, k c+1 = 12 - c, and the number of C 2 -NOT gates in the equivalent circuit is "40 - 2c".
<c=10の場合>
第1の変換方式により、等価回路のC2-NOTゲート数は「21」となる。
このように量子ゲート変換部130は、Ck-NOTゲートをできるだけ最小数のC2-NOTゲートの組合せに変換できる。
<When c=10>
According to the first conversion method, the number of C 2 -NOT gates in the equivalent circuit becomes "21".
In this way, the quantum
〔その他の実施の形態〕
第2の実施の形態では、量子回路に基づく量子計算を量子コンピュータ200で実行しているが、量子計算を古典コンピュータによる量子シミュレーションで実行することも可能である。その場合、量子コンピュータ200に代えて、量子シミュレーションを実効可能な古典コンピュータが用いられる。また第2の実施の形態に示した古典コンピュータ100が量子シミュレーションを実行してもよい。
Other embodiments
In the second embodiment, quantum computation based on a quantum circuit is executed by the
第2の実施の形態では、量子コンピュータ200においてC2-NOTゲートのゲート操作ができる場合が想定されているが、量子コンピュータ200がC2-NOTゲートのゲート操作ができない場合もあり得る。その場合には、古典コンピュータ100は、C2-NOTゲートを、さらに他の基本量子ゲートを組み合わせた等価回路に変換する。この場合であっても、第1・第2の実施の形態に示したように、予めCk-NOTゲートを少ない量子ゲート数のC2-NOTゲートに変換しておくことで、最終的に生成される量子回路のゲート数を減らすことができる。
In the second embodiment, it is assumed that the
第2の実施の形態では、等価回路において、補助ビット(cleanビットまたはdirtyビット)の状態を、使用前に戻すための量子回路を含んでいる。補助ビットを元に戻さなくてもよいことが分かっている場合には、使用前の状態に戻すための量子回路を等価回路から除外することも可能である。補助ビットを元に戻さなくてもよい場合とは、例えば、その補助ビットが測定対象ではなく、その補助ビットの以後の状態が測定対象の量子ビットに影響を与えることもない場合である。補助ビットの状態を使用前に戻すための量子回路を等価回路から除外することにより、量子ゲート数を削減できる。 In the second embodiment, the equivalent circuit includes a quantum circuit for returning the state of the auxiliary bit (clean bit or dirty bit) to the state before use. If it is known that the auxiliary bit does not need to be restored, it is also possible to exclude the quantum circuit for returning it to the state before use from the equivalent circuit. A case in which the auxiliary bit does not need to be restored is, for example, when the auxiliary bit is not the object of measurement and the subsequent state of the auxiliary bit does not affect the quantum bit that is the object of measurement. By excluding the quantum circuit for returning the auxiliary bit to the state before use from the equivalent circuit, the number of quantum gates can be reduced.
上記については単に本発明の原理を示すものである。さらに、多数の変形、変更が当業者にとって可能であり、本発明は上記に示し、説明した正確な構成および応用例に限定されるものではなく、対応するすべての変形例および均等物は、添付の請求項およびその均等物による本発明の範囲とみなされる。 The foregoing merely illustrates the principles of the present invention. Moreover, since numerous modifications and variations are possible to those skilled in the art, the present invention is not limited to the exact construction and application shown and described above, and all corresponding modifications and equivalents are deemed to be within the scope of the present invention as defined by the appended claims and their equivalents.
1a 量子回路
1b 初期値情報
2~6 量子ゲート
10 量子回路設計支援装置
11 記憶部
12 処理部
1a
Claims (8)
前記判定対象の量子ゲートごとに、前記判定対象の量子ゲートによるゲート操作後に前記所定の値になっている量子ビットを特定する、
処理をコンピュータに実行させる量子回路設計支援プログラム。 a quantum gate having an earlier order of gate operation in the quantum circuit is selected as a judgment target, and based on initial value information indicating whether each of a plurality of quantum bits operated by the quantum circuit has a predetermined value in an initial state, a judgment is made as to whether a quantum bit to be operated by the quantum gate to be judged has the predetermined value after the gate operation;
for each of the quantum gates to be determined, a quantum bit that has become the predetermined value after a gate operation by the quantum gate to be determined is identified;
A quantum circuit design support program that executes processing on a computer.
請求項1記載の量子回路設計支援プログラム。 In the process of identifying the quantum bit that has become the predetermined value, the quantum bit that has become the predetermined value after the gate operation by the quantum gate to be determined is identified based on whether the quantum bit to be operated by the quantum gate to be determined becomes the predetermined value after the gate operation, and whether a quantum bit other than the quantum bit to be operated has the predetermined value before the gate operation.
The quantum circuit design support program according to claim 1.
請求項1記載の量子回路設計支援プログラム。 In the process of determining whether the predetermined value is reached, if the gate operation by the quantum gate to be determined is an operation to change the state of the quantum bit to be operated to the predetermined value, it is determined that the quantum bit to be operated will become the predetermined value after the gate operation, and if the gate operation by the quantum gate to be determined is an operation other than an operation to change the state of the quantum bit to the predetermined value, it is determined that it is unclear whether the value will become the predetermined value after the gate operation.
The quantum circuit design support program according to claim 1.
請求項1記載の量子回路設計支援プログラム。 In the process of determining whether the predetermined value is reached, when the quantum gate to be determined is a swap gate, and a first quantum bit of the two quantum bits to be operated is the predetermined value before the gate operation by the quantum gate to be determined, it is determined that a second quantum bit of the quantum bits to be operated will be the predetermined value after the gate operation.
The quantum circuit design support program according to claim 1.
請求項4記載の量子回路設計支援プログラム。 In the process of determining whether the predetermined value is reached, when the quantum gate to be determined is a swap gate, and it is unclear whether the first quantum bit is at the predetermined value before the gate operation by the quantum gate to be determined, it is determined that it is unclear whether the second quantum bit will be at the predetermined value after the gate operation.
The quantum circuit design support program according to claim 4.
請求項1から5までのいずれかに記載の量子回路設計支援プログラム。 identifying a third quantum bit that is the predetermined value after a gate operation of the first quantum gate based on the list generated when the first quantum gate is set as the quantum gate to be determined, and converting a second quantum gate to be executed after the first quantum gate into a quantum circuit equivalent to the second quantum gate, using the third quantum bit;
6. A quantum circuit design support program according to claim 1.
前記判定対象の量子ゲートごとに、前記判定対象の量子ゲートによるゲート操作後に前記所定の値になっている量子ビットを特定する、
処理をコンピュータが実行する量子回路設計支援方法。 a quantum gate having an earlier order of gate operation in the quantum circuit is selected as a judgment target, and based on initial value information indicating whether each of a plurality of quantum bits operated by the quantum circuit has a predetermined value in an initial state, a judgment is made as to whether a quantum bit to be operated by the quantum gate to be judged has the predetermined value after the gate operation;
for each of the quantum gates to be determined, a quantum bit that has become the predetermined value after a gate operation by the quantum gate to be determined is identified;
A quantum circuit design support method in which processing is executed by a computer.
を有する量子回路設計支援装置。 a processing unit which determines whether a quantum bit to be operated by the quantum gate to be determined will become the predetermined value after gate operation based on initial value information indicating whether each of a plurality of quantum bits operated by the quantum circuit has a predetermined value in an initial state, and identifies, for each quantum gate to be determined, a quantum bit which has become the predetermined value after gate operation by the quantum gate to be determined;
A quantum circuit design support device having the above structure.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| PCT/JP2023/001368 WO2024154265A1 (en) | 2023-01-18 | 2023-01-18 | Quantum circuit design assistance program, quantum circuit design assistance method, and quantum circuit design assistance device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| PCT/JP2023/001368 WO2024154265A1 (en) | 2023-01-18 | 2023-01-18 | Quantum circuit design assistance program, quantum circuit design assistance method, and quantum circuit design assistance device |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2024154265A1 true WO2024154265A1 (en) | 2024-07-25 |
Family
ID=91955713
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/JP2023/001368 Ceased WO2024154265A1 (en) | 2023-01-18 | 2023-01-18 | Quantum circuit design assistance program, quantum circuit design assistance method, and quantum circuit design assistance device |
Country Status (1)
| Country | Link |
|---|---|
| WO (1) | WO2024154265A1 (en) |
Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2022522600A (en) * | 2019-03-08 | 2022-04-20 | インターナショナル・ビジネス・マシーンズ・コーポレーション | Compiling Quantum Algorithm |
| JP2022088600A (en) * | 2021-07-14 | 2022-06-14 | ベイジン バイドゥ ネットコム サイエンス テクノロジー カンパニー リミテッド | Processing method of quantum circuit, device, electronic device, storage medium and program |
| WO2022249963A1 (en) * | 2021-05-24 | 2022-12-01 | 国立大学法人東京大学 | Quantum circuit |
-
2023
- 2023-01-18 WO PCT/JP2023/001368 patent/WO2024154265A1/en not_active Ceased
Patent Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2022522600A (en) * | 2019-03-08 | 2022-04-20 | インターナショナル・ビジネス・マシーンズ・コーポレーション | Compiling Quantum Algorithm |
| WO2022249963A1 (en) * | 2021-05-24 | 2022-12-01 | 国立大学法人東京大学 | Quantum circuit |
| JP2022088600A (en) * | 2021-07-14 | 2022-06-14 | ベイジン バイドゥ ネットコム サイエンス テクノロジー カンパニー リミテッド | Processing method of quantum circuit, device, electronic device, storage medium and program |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JP7481075B2 (en) | Simulating quantum circuits on a computer using hierarchical storage | |
| CN113592093B (en) | Quantum state preparation circuit generation method and device, quantum operation chip and equipment | |
| CN103853596B (en) | For the method and system for migrating virtual machine between working group | |
| WO2020151129A1 (en) | Quantum machine learning framework construction method and apparatus, and quantum computer and computer storage medium | |
| CN110825375A (en) | Quantum program conversion method and device, storage medium and electronic device | |
| CN109858628A (en) | Compile method, apparatus, equipment and the computer readable storage medium of quantum circuit | |
| JP2022511716A (en) | Decentralized deep learning | |
| CN116187458A (en) | Quantum circuit processing method and device and electronic equipment | |
| Sonmez et al. | Activity uncrashing heuristic with noncritical activity rescheduling method for the discrete time-cost trade-off problem | |
| Ahmed et al. | Hybrid Genetic Algorithms for the Asymmetric Distance‐Constrained Vehicle Routing Problem | |
| KR20230132369A (en) | Reducing resources in quantum circuits | |
| Kaur et al. | Optimized quantum circuit partitioning across multiple quantum processors | |
| KR20230161898A (en) | Hybrid-computing resource optimization | |
| WO2024154265A1 (en) | Quantum circuit design assistance program, quantum circuit design assistance method, and quantum circuit design assistance device | |
| EP4475041A1 (en) | Information processing program, information processing method, and information processing device | |
| WO2024154266A1 (en) | Quantum circuit design support program, quantum circuit design support method, and quantum circuit design support device | |
| CN113518973B (en) | A flexible and fast all-reduce method for arbitrary tree topologies | |
| CN117313877B (en) | Quantum circuit processing method and device and electronic equipment | |
| CN113222158B (en) | A method and device for obtaining a quantum state | |
| WO2024189847A1 (en) | Processing device, processing method, and recording medium | |
| CN116738125A (en) | A method and device for solving differential equations using quantum circuits | |
| JP2022158010A (en) | Information processing system, information processing method, and information processing program | |
| Bieberich et al. | Bridging hpc and quantum systems using scientific workflows | |
| US20250157608A1 (en) | Identifying potential treatment paths using harmonic homology for disentangling multiway data interactions | |
| Bhattacharjee et al. | A survey report on recent progresses in nearest neighbor realization of quantum circuits |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 23917478 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |