65 lines
2.6 KiB
Plaintext
65 lines
2.6 KiB
Plaintext
---
|
||
title: phase_estimation (latest version)
|
||
description: API reference for qiskit.circuit.library.phase_estimation in the latest version of qiskit
|
||
in_page_toc_min_heading_level: 1
|
||
python_api_type: class
|
||
python_api_name: qiskit.circuit.library.phase_estimation
|
||
---
|
||
|
||
<span id="phase-estimation" />
|
||
|
||
# phase\_estimation
|
||
|
||
<Class id="qiskit.circuit.library.phase_estimation" isDedicatedPage={true} github="https://github.com/Qiskit/qiskit/tree/stable/1.3/qiskit/circuit/library/phase_estimation.py#L108-L177" signature="qiskit.circuit.library.phase_estimation(num_evaluation_qubits, unitary, name='QPE')" modifiers="class">
|
||
Bases:
|
||
|
||
Phase Estimation circuit.
|
||
|
||
In the Quantum Phase Estimation (QPE) algorithm \[1, 2, 3], the Phase Estimation circuit is used to estimate the phase $\phi$ of an eigenvalue $e^{2\pi i\phi}$ of a unitary operator $U$, provided with the corresponding eigenstate $|\psi\rangle$. That is
|
||
|
||
$$
|
||
U|\psi\rangle = e^{2\pi i\phi} |\psi\rangle
|
||
$$
|
||
|
||
This estimation (and thereby this circuit) is a central routine to several well-known algorithms, such as Shor’s algorithm or Quantum Amplitude Estimation.
|
||
|
||
**Parameters**
|
||
|
||
* **num\_evaluation\_qubits** ([*int*](https://docs.python.org/3/library/functions.html#int "(in Python v3.13)")) – The number of evaluation qubits.
|
||
* **unitary** ([*QuantumCircuit*](qiskit.circuit.QuantumCircuit "qiskit.circuit.quantumcircuit.QuantumCircuit")) – The unitary operation $U$ which will be repeated and controlled.
|
||
* **name** ([*str*](https://docs.python.org/3/library/stdtypes.html#str "(in Python v3.13)")) – The name of the circuit.
|
||
|
||
**Return type**
|
||
|
||
[*QuantumCircuit*](qiskit.circuit.QuantumCircuit "qiskit.circuit.quantumcircuit.QuantumCircuit")
|
||
|
||
**Reference Circuit:**
|
||
|
||
```python
|
||
from qiskit.circuit import QuantumCircuit
|
||
from qiskit.circuit.library import phase_estimation
|
||
unitary = QuantumCircuit(2)
|
||
unitary.x(0)
|
||
unitary.y(1)
|
||
circuit = phase_estimation(3, unitary)
|
||
circuit.draw('mpl')
|
||
```
|
||
|
||

|
||
|
||
**References:**
|
||
|
||
**\[1]: Kitaev, A. Y. (1995). Quantum measurements and the Abelian Stabilizer Problem. 1–22.**
|
||
|
||
[quant-ph/9511026](http://arxiv.org/abs/quant-ph/9511026)
|
||
|
||
**\[2]: Michael A. Nielsen and Isaac L. Chuang. 2011.**
|
||
|
||
Quantum Computation and Quantum Information: 10th Anniversary Edition (10th ed.). Cambridge University Press, New York, NY, USA.
|
||
|
||
**\[3]: Qiskit**
|
||
|
||
[textbook](https://github.com/Qiskit/textbook/blob/main/notebooks/ch-algorithms/quantum-phase-estimation.ipynb)
|
||
</Class>
|
||
|