Skip to content

Commit da3670d

Browse files
authored
Update q_fourier_transform.py
1 parent f94b14b commit da3670d

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

quantum/q_fourier_transform.py

+4-6
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,19 @@
1-
import math
21
import numpy as np
32
from qiskit import Aer, ClassicalRegister, QuantumCircuit, QuantumRegister, execute
43

5-
64
def quantum_fourier_transform(number_of_qubits: int = 3) -> dict:
75
"""
8-
Build and simulate the Quantum Fourier Transform (QFT) circuit
6+
Build and simulate the Quantum Fourier Transform (QFT) circuit
97
for a given number of qubits using the Qiskit framework.
10-
8+
119
Args:
1210
number_of_qubits (int): The number of qubits for the QFT circuit.
1311
1412
Returns:
1513
dict: A dictionary containing the counts of measurement results.
16-
14+
1715
Raises:
18-
ValueError: If the number of qubits is less than or equal to 0,
16+
ValueError: If the number of qubits is less than or equal to 0,
1917
greater than 10, or not an integer.
2018
TypeError: If the input is not an integer.
2119
"""

0 commit comments

Comments
 (0)