Reference: Simple Qubricks¶
Contents¶
QFT ¶
Bases: Qubrick
Qubrick to compute the quantum Fourier transform.
compute ¶
compute(
target: Qubits,
ctrl: Qubits | int = 0,
do_bit_reverse: bool = True,
error_param: float = 0,
)
Compute the QFT.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
target
|
Qubits
|
The register to perform QFT on. |
required |
ctrl
|
Qubits or None
|
Optional quantum control. |
0
|
do_bit_reverse
|
bool
|
Optionally enable/disable for trailing bit reversal. |
True
|
error_param
|
float
|
Optional error parameter for all rotations. |
0
|
Note
error_param sets the precision of each angle in the QFT (not the overall error).
CondInvert ¶
Bases: Qubrick
Basic ~ (bitwise inversion).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
name
|
str
|
A name for this Qubrick |
None
|
**kwargs
|
Any
|
Settings for this qubrick. A full list can be seen in the QubrickSettings dataclass. |
{}
|
compute ¶
Not implemented. CondInvert requires no gates and so can be resolved via the inline operation.