Skip to content

Commit

Permalink
Update state_preparation.py
Browse files Browse the repository at this point in the history
incorporated Julien's changes!
  • Loading branch information
Hirmay authored Jun 22, 2024
1 parent f57d8f2 commit a2e6ca0
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions qiskit/circuit/library/data_preparation/state_preparation.py
Original file line number Diff line number Diff line change
Expand Up @@ -451,8 +451,8 @@ def __init__(
num_superpos_states (int):
A positive integer M = num_superpos_states (> 1) representing the number of computational
basis states with an amplitude of 1/sqrt(M) in the uniform superposition
state ($\frac{1}{\sqrt{M}} \sum_{j=0}^{M-1} \ket{j} $, where
$1< M <= 2^n$). Note that the remaining (2^n - M) computational basis
state (:math:`\frac{1}{\sqrt{M}} \sum_{j=0}^{M-1} \ket{j}`, where
:math:`1< M <= 2^n`). Note that the remaining (2^n - M) computational basis
states have zero amplitudes. Here M need not be an integer power of 2.
num_qubits (int):
Expand All @@ -477,8 +477,6 @@ def _define(self):
"""
Defines the gate operation.
Returns:
QuantumCircuit: The quantum circuit implementing the gate.
"""
qreg = QuantumRegister(self._num_qubits, "q")
qc = QuantumCircuit(self._num_qubits)
Expand Down

0 comments on commit a2e6ca0

Please sign in to comment.