Quantum gates are the elementary operations for the qubits of a quantum computer.
They are comparable to the logic gates for classical bits. In contrast to the Boolean operators, all quantum gates are reversible, so there is always an inverse operation that can undo all computation steps. There is also a much wider variety of possible operations for qubits.
A quantum gate for a single qubit is described by a unitary matrix:
U=(acbd)a,b,c,d∈C
The operation on a state ∣ψ⟩=α∣0⟩+β∣1⟩ corresponds to the multiplication of the matrix U with the state vector:
U∣ψ⟩=U(α∣0⟩+β∣1⟩)=(acbd)(αβ)=(aα+bβcα+dβ)=(aα+bβ)∣0⟩+(cα+dβ)∣1⟩
Executing two operators U and \ (V ) one after the other is equivalent to an operator resulting from the matrix multiplication of U and V:
V⋅U=(a′c′b′d′)⋅(acbd)=(a′a+b′cc′a+d′ca′b+b′dc′b+d′d)
Since the operators are unitary matrices U, the adjoint matrix U† corresponds to the inverse operator. (The quantum gate U† thus reverses the effect of the gate U.)
U†U†⋅U=(a∗b∗c∗d∗)=I=(1001)
where I is the identity operator or unit matrix and z∗ denotes the complex conjungate of z.
Hadamard-Gate
The Hadamard gate is one of the most fundamental operations in quantum computing.
The Hadamard gate for single qubit is described in the {∣0⟩,∣1⟩} basis by the following matrix:
HH∣0⟩H∣1⟩=21(111−1)=21(∣0⟩+∣1⟩)≡∣+⟩=21(∣0⟩−∣1⟩)≡∣−⟩
The basis states ∣0⟩ and ∣1⟩ are converted by the Hadamard gate into a superposition. You can also understand this operation as a transition between the bases {∣0⟩,∣1⟩} and {∣+⟩,∣−⟩}. The Hadamard matrix is self-adjoint (H†=H), so that the two-time application of the Hadamard gate gives the identity (H⋅H=H†⋅H=I ).
Phase-Shift
The phase-shift Rϕ is a whole family of single-qubit gates. It is described by the following matrix in the {∣0⟩,∣1⟩} basis:
RϕRϕ∣0⟩Rϕ∣1⟩=(100exp(iϕ))=∣0⟩=exp(iϕ)∣1⟩
where exp(iϕ)=cos(ϕ)+isin(ϕ). This operation leaves the amplitudes of the state vector unchanged and only introduces a phase shift between the vector components by the angle ϕ∈[−π,π]. The adjoint matrix yields Rϕ†=R−ϕ such that R−ϕ⋅Rϕ=I.
Of particular importance are the phase shift gates T=Rπ/4, S=Rπ/2 and Z=Rπ.
Pauli-Gates
The Pauli gates are a family of three operators with the matrices
XYZ=(0110)=(0i−i0)=(100−1)
The X gate is the quantum mechanical equivalent to the classical NOT operator and interchanges the basis states so that X∣0⟩=∣1⟩ and X∣1⟩=∣0⟩ (bit-flip).
The Z gate performs a special phase-shift operation around the angle π (phase-flip). The Y gate is a combination of bit and phase flip. The Pauli matrices are self-adjoint and obey the algebra X⋅X=Y⋅Y=Z⋅Z=−iX⋅Y⋅Z=I.
This discussion board is a place to discuss our Daily Challenges and the math and science
related to those challenges. Explanations are more than just a solution — they should
explain the steps and thinking strategies that you used to obtain the solution. Comments
should further the discussion of math and science.
When posting on Brilliant:
Use the emojis to react to an explanation, whether you're congratulating a job well done , or just really confused .
Ask specific questions about the challenge or the steps in somebody's explanation. Well-posed questions can add a lot to the discussion, but posting "I don't understand!" doesn't help anyone.
Try to contribute something new to the discussion, whether it is an extension, generalization or other idea related to the challenge.
Stay on topic — we're all here to learn more about math and science, not to hear about your favorite get-rich-quick scheme or current world events.
Markdown
Appears as
*italics* or _italics_
italics
**bold** or __bold__
bold
- bulleted - list
bulleted
list
1. numbered 2. list
numbered
list
Note: you must add a full line of space before and after lists for them to show up correctly
Easy Math Editor
This discussion board is a place to discuss our Daily Challenges and the math and science related to those challenges. Explanations are more than just a solution — they should explain the steps and thinking strategies that you used to obtain the solution. Comments should further the discussion of math and science.
When posting on Brilliant:
*italics*
or_italics_
**bold**
or__bold__
paragraph 1
paragraph 2
[example link](https://brilliant.org)
> This is a quote
\(
...\)
or\[
...\]
to ensure proper formatting.2 \times 3
2^{34}
a_{i-1}
\frac{2}{3}
\sqrt{2}
\sum_{i=1}^3
\sin \theta
\boxed{123}
Comments
Thanks for posting these, as well as the problems. It's cool to realize that this stuff is actually somewhat accessible to non-specialists.
Can anyone please tell me the latex code to write example in notes as in wiki.
@Calvin Lin, @Markus Michelmann