Skip to main content
14 votes
Accepted

Why can the QFT be replaced by Hadamard gates?

While the QFT and Hadamard transforms are different, their action on the input state $|00\ldots 0\rangle$ is identical; both produce the uniform superposition of all states. So, if you've got a choice ...
DaftWullie's user avatar
  • 59.4k
14 votes
Accepted

Why isn't $Ry(\pi/2)$ gate equivalent to Hadamard gate?

While Hadamard gate is defined as $$ H= \frac{1}{\sqrt{2}} \begin{pmatrix} 1 & 1 \\ 1 & -1 \end{pmatrix}, $$ $y$-rotation by $\pi/2$ leads to gate $$ Ry(\pi/2)= \frac{1}{\sqrt{2}} \begin{...
Martin Vesely's user avatar
10 votes

Why 2 $H$ gates in series create a probability of 100% for one value of the qubit and 0% of the second value of the qubit?

The reason for this is because the inverse of Hadamard gate is itself. That is, giving that $$ H = \dfrac{1}{\sqrt{2}} \begin{pmatrix} 1& 1\\ 1 & -1 \\ \end{pmatrix}$$ then $$ H^{-1} = \dfrac{...
KAJ226's user avatar
  • 13.9k
9 votes
Accepted

How do I prove that the Hadamard satisfies $H\equiv e^{i\pi H/2}$?

First of all, note that the statement, as written, is wrong (or rather, it is correct only as long as the "$\equiv$" symbol is taken to mean "equal up to a phase"). An easy way to see it is by ...
glS's user avatar
  • 25.6k
9 votes
Accepted

How do I apply the Hadamard gate to one qubit in a two-qubit pure state?

First, you should note that the Hadamaard gate is nothing more than a $2 \times 2$ Discrete Fourier Transform matrix (two-point DFT). That is the reason why, $H \bigg( \dfrac{|0\rangle + |1\rangle}{2}\...
KAJ226's user avatar
  • 13.9k
9 votes

Represent Hadamard gate in terms of rotations and reflections in Bloch sphere

but how about γ? Gamma doesn't show up on the Bloch sphere. It's a global phase. It's unobservable without conditioning the operation on a second qubit, in which case it turns into phase kickback ...
Craig Gidney's user avatar
  • 38.8k
8 votes
Accepted

Could the Hadamard gate have been constructed differently with similar characteristics?

The Hadamard gate has close ties to the discrete Fourier transform. Consider the DFT for an $N$-level system: $$\vert j \rangle = \frac{1}{\sqrt{N}} \sum\limits_{k=0}^{N-1} e^{\frac{i2 \pi j k}{N}} \...
Jonathan Trousdale's user avatar
8 votes
Accepted

Why is a Hadamard gate unitary?

The Hadamard gate is described by this matrix \begin{equation} H=\frac{1}{\sqrt{2}} \begin{pmatrix} 1 & 1 \\ 1 & -1 \end{pmatrix} \end{equation} Conjugate transpose of $H$ is again $H$. Hence ...
Martin Vesely's user avatar
8 votes
Accepted

How are the IBM's and Google's Hadamard gates fabricated and operated?

A Hadamard gate isn't usually a physical object that you pass qubits through. In the case of superconducting qubits, the Hadamard gate is performed by bouncing microwaves off of the qubits. It doesn't ...
Craig Gidney's user avatar
  • 38.8k
8 votes
Accepted

What Hamiltonians generate Hadamard and CNOT matrices?

Let us denote Hadamard with $H$ and the two Hamiltonians as $\mathcal H_H$ and $\mathcal H_{CNOT}$, i.e. $$ H = \exp (-i\mathcal{H}_H) \\ CNOT = \exp (-i\mathcal{H}_{CNOT}). $$ We will make use of the ...
Adam Zalcman's user avatar
8 votes

How do you represent a Hadamard gate as a product of $R_x$ and $R_y$ gates?

If you're not concerned with global phase then the following works using only two rotation gates: \begin{align} R_y\left(-\frac{\pi}{2}\right) R_x\left(\pi\right) &= \exp \left(i\frac{\pi}{4}Y\...
forky40's user avatar
  • 7,183
7 votes

Is there a gate that puts a qubit into superposition with a not so purely probabalistic (50 50) outcome?

You can use $Ry$ gate to prepare a qubit in superposition with arbitrary probabilities. When you apply the gate on qubit in state $|0\rangle$, you get a qubit in superposition $$ |\psi\rangle = \cos(\...
Martin Vesely's user avatar
7 votes
Accepted

How to translate the Hadamard gate matrix into Dirac notation?

First remember that each matrix element can be written as outer products in Dirac notation: $$|0\rangle\langle 0| = \begin{bmatrix}1 & 0 \\ 0 & 0 \end{bmatrix},|1\rangle\langle 1| = \begin{...
user1271772 No more free time's user avatar
6 votes

What are the $|+\rangle$ and $|-\rangle$ states?

The $|+⟩$ and $|-⟩$ are states given by the following decomposition in the Z-basis: \begin{equation} \begin{aligned} |+⟩ &= \frac{1}{\sqrt{2}} \Big(|0⟩ + |1⟩\Big)\\ |-⟩ &= \frac{1}{\sqrt{2}} ...
luigi's user avatar
  • 61
6 votes

How do 2 Hadamard gates act on a single qubit?

If you apply the same gate twice on a state $|\psi\rangle$ you will get out the state $|\psi\rangle$ if the hermitian of the gate is the same as the gate. In your case, you applied the Hadamard gate, $...
auden's user avatar
  • 3,459
6 votes
Accepted

What is the intuition of using Hadamard gate in quantum fourier transform?

The intuition, roughly speaking, is that the only way that you're going to get some difference between classical and quantum computing is if you are able to prepare qubits in a superposition. If you ...
DaftWullie's user avatar
  • 59.4k
6 votes

How do I prove that the Hadamard satisfies $H\equiv e^{i\pi H/2}$?

For questions like this, the conventional physics notation is easier to work with than the QIT gate notation. Define $\vec \sigma = (\sigma_1,\sigma_2,\sigma_3)$ to represent the three Pauli matrices ...
Jonathan Trousdale's user avatar
6 votes

How to visualize Hadamard gate as $X$-$Z$-$X$ decomposition?

As mentioned in the other answer, the Hadamard gate is a pi rotation (180 degree) around the $X + Z$ axis. That is, it is a 180 degree rotation around the purple axis indicated in the below figure: ...
KAJ226's user avatar
  • 13.9k
6 votes
Accepted

Initial state preparation for Hadamard test

You could almost do it. In fact, the following circuit would work: You can convince yourself that what you do is in fact applying the unitary $\mathbf{VUV^\dagger}$, which will allow you to evaluate ...
Tristan Nemoz's user avatar
  • 6,702
6 votes
Accepted

Can we use Hadamard test to estimate phases?

So QPE using $\mathcal{O}(1/\epsilon)$ queries to $U$ outputs an estimate of the eigenphase $\theta$ given a corresponding eigenvector with additive error and $\Omega(1)$ probability. The method using ...
dylan7's user avatar
  • 324
6 votes
Accepted

Commutation rules between Pauli $X$ and controlled-Hadamard

There are two cases: $X$ on the controlled qubit and $X$ on the target. $X$ on the controlled qubit For the first case, note that for any controlled unitary $CU$, we have $$ (X_1\otimes I_2)\circ ...
Adam Zalcman's user avatar
6 votes
Accepted

Is the plus state a magic state for the Hadamard gate?

Start with a state $|\psi\rangle|+\rangle$. Measure the operator $X_1Z_2$ using either lattice surgery or an ancilla qubit and $CZ,CX$ gates. Call this result $m_{xz}$ Then measure the first qubit in ...
Jahan Claes's user avatar
6 votes
Accepted

What is the intuition behind uniform Hadamard superposition?

The first Hadamard gates applied to a fiducial all-zero's ket on $n$ qubits serve to prepare your input register into the uniform superposition over all $2^n$ basis states. The last Hadamard gates ...
Mark Spinelli's user avatar
6 votes
Accepted

Hadamard transform on state

This is a little fiddly to get right the first time. Let's start by rewriting eq (3) as $$ \sum_{b\in\{0,1\}}\alpha_b|b\rangle\otimes X^{x_{b,y}}|0\rangle. $$ Now, it probably helps to think of this $...
DaftWullie's user avatar
  • 59.4k
5 votes

Could the Hadamard gate have been constructed differently with similar characteristics?

You can easily check that $H^1=XHX$, which is another way to say that $H^1$ is the same as $H$ modulo swapping $|0\rangle$ and $|1\rangle$. This means that it is a different gate. On the other hand, ...
glS's user avatar
  • 25.6k
5 votes
Accepted

Projecting $\lvert ++ \rangle$ on Bell Basis

The Hadamard gate is: $$\frac{1}{\sqrt 2} \left(|0\rangle \langle 0 | + |0\rangle\langle 1| + |1\rangle \langle 0| - |1\rangle \langle 1|\right)$$ And since $|+\rangle$ is $\frac{1}{\sqrt 2}\left(|0\...
Mahathi Vempati's user avatar
5 votes
Accepted

Analysis of the second Hadamard in the Detusch-Jozsa Algorithm

If you look at the formula you want to prove term-by-term, you'll notice that the sum and the $(-1)^f(x)$ part is the same in both formulas; you just need to show that $$H^{\otimes n} |x\rangle = \...
Mariia Mykhailova's user avatar
5 votes
Accepted

How should I understand the change of qubit's basis as a rotation?

Hadamard gate can be interpreted as a rotation in 3D Euclidean space (on Bloch sphere) by angle $\pi$ around X+Z axis. The qubit rotation by angle $\theta$ around axis pointed by unit vector $\textbf{...
kludg's user avatar
  • 3,214
5 votes
Accepted

Simple algebraic explanation for normalizing states

The coefficient $\frac{1}{\sqrt{2^3}}$ is the normalization factor: if you have a 3-qubit state that is an equal superposition of 8 basis states, its norm still has to be 1; thus the squared amplitude ...
Mariia Mykhailova's user avatar
5 votes
Accepted

$H = e^{i\pi/4} \sqrt{iNOT}$?

It cannot be the case that $H=e^{i\pi/4}\sqrt{iNOT}$. Whatever your interpretation of $iNOT$ (I'd agree with your definition), just square the thing. $H^2=I$, the identity, and so it is certainly not ...
DaftWullie's user avatar
  • 59.4k

Only top scored, non community-wiki answers of a minimum length are eligible