Main Content

このページの内容は最新ではありません。最新版の英語を参照するには、ここをクリックします。

ゲートベースの量子計算

ゲートベースの量子計算アルゴリズム
R2023a 以降

量子ゲートおよび回路を作成し、ローカル コンピューターで回路をシミュレーションし、Amazon® Web Services (AWS®) または IBM® Qiskit® Runtime Services を使用してリモート ハードウェアで回路を実行します。

クラス

すべて展開する

quantumCircuit量子計算回路
quantum.gate.SimpleGateSimple gate for quantum computing
quantum.gate.CompositeGateComposite gate for quantum computing
quantum.gate.QuantumStateState of qubits in quantum circuit
quantum.gate.QuantumMeasurementMeasurement result of quantum circuit
quantum.backend.QuantumDeviceAWSQuantum device available through AWS
quantum.backend.QuantumTaskAWSTask sent to AWS for execution on quantum device
quantum.backend.QuantumDeviceIBMQuantum device available through IBM (R2023b 以降)
quantum.backend.QuantumTaskIBMTask sent to IBM for execution on quantum device (R2023b 以降)

プロパティ

QuantumCircuitChart PropertiesQuantum circuit plot appearance and behavior (R2023b 以降)

関数

すべて展開する

1 つのターゲット量子ビットでのゲート

hGateHadamard gate
idGateIdentity gate
xGatePauli X gate
yGatePauli Y gate
zGatePauli Z gate

回転ゲート

rxGatex-axis rotation gate
ryGatey-axis rotation gate
rzGatez-axis rotation gate
r1Gatez-axis rotation gate with global phase
sGateS gate
siGateInverse S gate
tGateT gate
tiGateInverse T gate

1 つのコントロール量子ビットと 1 つのターゲット量子ビットをもつゲート

chGateControlled Hadamard gate
cnotGateCNOT gate (controlled X gate)
cxGateControlled X gate (CNOT gate)
cyGateControlled Y gate
czGateControlled Z gate

2 つの量子ビットの状態を入れ替えるゲート

swapGateSwap gate

制御された回転ゲート

crxGateControlled x-axis rotation gate
cryGateControlled y-axis rotation gate
crzGateControlled z-axis rotation gate
cr1GateControlled z-axis rotation gate with global phase

制御された制御 X ゲート

ccxGateControlled controlled X gate (CCNOT or Toffoli gate)

イジング カップリング ゲート

rxxGateIsing XX coupling gate
ryyGateIsing YY coupling gate
rzzGateIsing ZZ coupling gate

複合ゲートおよび特殊ゲート

compositeGateConstruct composite gate for quantum computing
qftGateQuantum Fourier transform gate
mcxGateMulti-controlled X gate

トピック

基本とワークフロー

適用

  • Graph Coloring with Grover's Algorithm
    This example shows how to use Grover's algorithm on a quantum computer to solve graph coloring problems. Grover's algorithm, also called the quantum search algorithm, is a fast method to perform unstructured searches. This example applies the algorithm to a problem where a bit string of a given length is classified as valid or invalid, and the goal is to retrieve one of the valid bit strings. The algorithm uses a state oracle to determine whether a bit string is valid. Although this application of Grover's algorithm is not the most efficient method to solve the graph coloring problem in practice, it illustrates how a quantum algorithm can be applied to a well-known problem.
  • Ground-State Protein Folding Using Variational Quantum Eigensolver (VQE)
    This example shows an efficient method for using qubits to encode a protein fold on a 3-D tetrahedral lattice [1], [2]. The ground-state is found through a simulated variational quantum eigensolver (VQE) routine. The VQE algorithm uses classical optimization to improve the initial guess of the ground state, and then a quantum computer calculates the expectation value. The final circuit from the simulation is run on a real QPU for comparison.
  • Solve XOR Problem Using Quantum Neural Network (QNN)
    This example shows how to solve the XOR problem using a trained quantum neural network (QNN). You use the network to classify the classical data of 2-D coordinates. A QNN is a machine learning model that combines quantum computing layers and classical layers. This example shows how to train such a hybrid network for a classification problem that is nonlinearly separable, such as the exclusive-OR (XOR) problem.
  • Quantum Monte Carlo (QMC) Simulation
    This example shows how to use Quantum Monte Carlo (QMC) simulation in MATLAB® to compute the mean of a function of a random variable. There are a broad range of tasks in finance and economics that depend on Monte Carlo simulation, from option pricing to macroeconomic stress testing. While this example does not explore computational efficiency, research shows that QMC offers a quadratic speed-up compared to classic Monte Carlo methods.