# 量子コンピューティングの概要¶

Quantum computing represents a new paradigm in computation that utilizes the fundamental principles of quantum mechanics to perform calculations. If you are reading this then you have undoubtedly heard that the promise of quantum computation lies in the possibility of efficiently performing a handful of tasks such as prime factorization, quantum simulation, search, optimization, and algebraic programs such as machine learning; computations that at size are beyond the capabilities of even the largest of classical computers.

The power of quantum computing rests on two cornerstones of quantum mechanics, namely interference and entanglement that highlight the wave- and particle-like aspects of quantum computation, respectively. Qiskit is an SDK for performing quantum computations that utilize these quantum mechanical principles using the language of quantum circuits. Comprised of quantum gates, instructions, and classical control logic, quantum circuits allow for expressing complex algorithms and applications in a abstract manner that can be executed on a quantum computer. At its core, Qiskit is a quantum circuit construction, optimization, and execution engine. Additional algorithm and application layers leverage quantum circuits, often in concert with classical computing resources, to solve problems in optimization, quantum chemistry, physics, machine learning, and finance. In what follows, we give a very brief overview of quantum computing, and how Qiskit is used at each step. Interested readers are directed to additional in-depth materials for further insights.

## Interference¶

Like a classical computer, a quantum computer operates on bits. However, while classical bits can only be found in the states 0 and 1, a quantum bit, or qubit, can represent the values 0 and 1, or linear combinations of both. These linear combinations are known as superpositions (or superposition states).

To see how this resource is utilized in quantum computation we first turn to a classical analog: noise cancellation. Noise cancellation, as done in noise cancelling headphones for example, is performed by employing superposition and the principle of interference to reduce the amplitude of unwanted noise by generating a tone of approximately the same frequency and amplitude, but out of phase by a value of $$\pi$$ (or any other odd integer of $$\pi$$).

## 量子回路¶

Quantum circuits enable a quantum computer to take in classical information and output a classical solution, leveraging quantum principles such as interference and entanglement to perform the computation.

• 解決したい問題

• 量子回路の記述を生成する古典的なアルゴリズム

• 量子ハードウェア上で実行される量子回路

• それが生成する問題に対しての古典的な出力解

Quantum gates form the primitive operations on quantum data. Quantum gates represent information preserving, reversible transformations on the quantum data stored in qubits. These 「unitary」 transformations represent the quantum mechanical core of a quantum circuit. Some gates such as $$X$$ (also written as $$\oplus$$) and $$CX$$ have classical analogs such as bit-flip and $$XOR$$ operations, respectively, while others do not. The Hadamand ($$H$$) gate, along with the parameterized rotates $$rX(\theta)$$ and $$rY(\theta)$$, generate superposition states, while gates such as $$Z$$, $$rZ(\theta)$$, $$S$$, and $$T$$ impart phases that can be used for interference. Two-qubit gates like the $$CX$$ gate are used to generate entanglement between pairs of qubits, or to 「kick」 the phase from one qubit ot another. In contrast to gates, operations like 「measurement」, represented by the meter symbol in a box with a line connecting to a 「target」 wire, extract partial information about a qubit’s state, often losing the phase, to be able to represent it as a classical bit and write that classical bit onto the target wire (often a fully classical wire in some readout device). This is the typical way to take information from the quantum data into a classical device. Note that with only $$H$$, $$rZ(\theta)$$, $$CX$$, and measurement gates, i.e. a universal gate set, we can construct any quantum circuit, including those efficiently computing the dynamics of any physical system in nature.

ワークロードの中には、量子回路と古典計算を交互に配置した、拡張シーケンスを含むものがあり、例えば変分量子アルゴリズムでは最適化ループ内で量子回路を実行します。このようなワークロードでは、量子回路をパラメータ化し、回路実行と古典計算の間の遷移を効率的に行うことで、システムの性能を大幅に向上させることができます。そこで、計算時間を高速化するために開発されたハードウェアを用いて、量子回路を繰り返し利用するアルゴリズムを用いた計算を near-time computation と定義します。 near-time computation では、古典計算は量子計算のコヒーレンスよりも長い時間スケールで行われます。これは、古典的な計算が量子デバイスのデコヒーレンス時間内に行われる real-time computation とは対照的です。

qr = QuantumRegister(3, 'q')
cr = ClassicalRegister(2, 'zx_meas')
qc = QuantumCircuit(qr,cr)
qc.reset(range(3))
qc.barrier()
qc.h(1)
qc.cx([1,0],[2,1])
qc.h(0)
qc.barrier()
qc.measure([0,1], [0,1])
qc.barrier()
qc.z(2).c_if(cr, 1)
qc.x(2).c_if(cr, 2)


## 量子コンピューター¶

Quantum computers which are programmed using quantum circuits can be constructed out of any quantum technology that allows for defining qubit elements, and can implement single- and multi-qubit gate operations with high-fidelity. At present, architectures based on superconducting circuits, trapped-ions, semiconducting quantum-dots, photons, and neutral atoms, are actively being developed, and many are accessible to users over the internet. Qiskit is agnostic with respect to the underlying architecture of a given quantum system, and can compile a quantum circuit to match the entangling gate topology of a quantum device, map the circuit instructions into the native gate set of the device, and optimize the resulting quantum circuit for enhanced fidelity.