Skip to content

Commit

Permalink
update docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
jcjaskula-aws committed Nov 28, 2023
1 parent e5eaa21 commit b8f0f33
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/braket/circuits/gates.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,12 @@ def gphase(
) -> Instruction | Iterable[Instruction]:
r"""Global phase gate.
If the gate is applied with control/negative control modifiers, it is translated in an
equivalent gate using the following definition: `phaseshift(λ) = ctrl @ gphase(λ)`.
The rightmost control qubit is used for the translation. If the polarity of the rightmost
control modifier is negative, the following identity is used:
`negctrl @ gphase(λ) q = x q; ctrl @ gphase(λ) q; x q`.
Unitary matrix:
.. math:: \mathtt{gphase}(\gamma) = e^(i \gamma) I_1.
Expand Down

0 comments on commit b8f0f33

Please sign in to comment.