Simple
cx
cx(control: Qubit, target: Qubit)
Apply a controlled-X gate on two qubits.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
control
|
Qubit
|
The control qubit. |
required |
target
|
Qubit
|
The target qubit. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
200 201 202 203 204 205 206 207 208 |
|
cy
cy(control: Qubit, targets: Qubit)
Apply a controlled-Y gate on two qubits.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
control
|
Qubit
|
The control qubit. |
required |
targets
|
Qubit
|
The target qubit. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
211 212 213 214 215 216 217 218 219 |
|
cz
cz(control: Qubit, target: Qubit)
Apply a controlled-Z gate on two qubits.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
control
|
Qubit
|
The control qubit. |
required |
target
|
Qubit
|
The target qubit. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
189 190 191 192 193 194 195 196 197 |
|
h
h(qubit: Qubit)
Apply a Hadamard gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the Hadamard gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
132 133 134 135 136 137 138 139 |
|
rot
rot(phi: float, theta: float, omega: float, qubit: Qubit)
Apply a general single-qubit rotation on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
phi
|
float
|
Z rotation before Y (radians). |
required |
theta
|
float
|
Y rotation (radians). |
required |
omega
|
float
|
Z rotation after Y (radians). |
required |
qubit
|
Qubit
|
The qubit to apply the rotation to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
163 164 165 166 167 168 169 170 171 172 173 |
|
rx
rx(angle: float, qubit: Qubit)
Apply an RX rotation gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
angle
|
float
|
Rotation angle in radians. |
required |
qubit
|
Qubit
|
The qubit to apply the rotation to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
9 10 11 12 13 14 15 16 17 |
|
ry
ry(angle: float, qubit: Qubit)
Apply an RY rotation gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
angle
|
float
|
Rotation angle in radians. |
required |
qubit
|
Qubit
|
The qubit to apply the rotation to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
50 51 52 53 54 55 56 57 58 |
|
rz
rz(angle: float, qubit: Qubit)
Apply an RZ rotation gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
angle
|
float
|
Rotation angle in radians. |
required |
qubit
|
Qubit
|
The qubit to apply the rotation to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
91 92 93 94 95 96 97 98 99 |
|
s
s(qubit: Qubit)
Apply an S gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the S gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
112 113 114 115 116 117 118 119 |
|
s_dag
s_dag(qubit: Qubit)
Apply the adjoint of the S gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the adjoint S gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
122 123 124 125 126 127 128 129 |
|
shift
shift(angle: float, qubit: Qubit)
Apply a phase shift on the |1> state of a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
angle
|
float
|
Shift angle in radians. |
required |
qubit
|
Qubit
|
The qubit to apply the shift to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
152 153 154 155 156 157 158 159 160 |
|
sqrt_x
sqrt_x(qubit: Qubit)
Apply a sqrt(X) gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the sqrt(X) gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
30 31 32 33 34 35 36 37 |
|
sqrt_x_adj
sqrt_x_adj(qubit: Qubit)
Apply the adjoint of sqrt(X) on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the adjoint sqrt(X) gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
40 41 42 43 44 45 46 47 |
|
sqrt_y
sqrt_y(qubit: Qubit)
Apply a sqrt(Y) gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the sqrt(Y) gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
71 72 73 74 75 76 77 78 |
|
sqrt_y_adj
sqrt_y_adj(qubit: Qubit)
Apply the adjoint of sqrt(Y) on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the adjoint sqrt(Y) gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
81 82 83 84 85 86 87 88 |
|
t
t(qubit: Qubit)
Apply a T gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the T gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
142 143 144 145 146 147 148 149 |
|
u3
u3(theta: float, phi: float, lam: float, qubit: Qubit)
Apply the U3 gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
theta
|
float
|
Rotation angle around the Y axis in radians. |
required |
phi
|
float
|
Rotation angle around the Z axis in radians. |
required |
lam
|
float
|
Rotation angle around the Z axis in radians. |
required |
qubit
|
Qubit
|
The qubit to apply the U3 gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
176 177 178 179 180 181 182 183 184 185 186 |
|
x
x(qubit: Qubit)
Apply a Pauli-X gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the X gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
20 21 22 23 24 25 26 27 |
|
y
y(qubit: Qubit)
Apply a Pauli-Y gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the Y gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
61 62 63 64 65 66 67 68 |
|
z
z(qubit: Qubit)
Apply a Pauli-Z gate on a single qubit.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qubit
|
Qubit
|
The qubit to apply the Z gate to. |
required |
Source code in .venv/lib/python3.12/site-packages/bloqade/native/stdlib/simple.py
102 103 104 105 106 107 108 109 |
|