|q⟩ Bad Qubits

← Question Bank

Multiple choice
This circuit prepares qubit 0 in some state. What expectation value ⟨Z⟩ does it have along the Bloch Z-axis?
⚛ The apparatus
const J = 1.0, t = 0.5, theta = 2 * J * t;
const c = circuit(2);
c.x(1); // start in |01>
// exp(-i theta/2 Z⊗Z)
c.cx(0, 1); c.rz(theta, 1); c.cx(0, 1);
// exp(-i theta/2 X⊗X) = (H⊗H) exp(-i theta/2 Z⊗Z) (H⊗H)
c.h(0); c.h(1);
c.cx(0, 1); c.rz(theta, 1); c.cx(0, 1);
c.h(0); c.h(1);
// exp(-i theta/2 Y⊗Y) = (RX(pi/2)⊗RX(pi/2)) exp(-i theta/2 Z⊗Z) (RX(-pi/2)⊗RX(-pi/2))
c.rx(Math.PI / 2, 0); c.rx(Math.PI / 2, 1);
c.cx(0, 1); c.rz(theta, 1); c.cx(0, 1);
c.rx(-Math.PI / 2, 0); c.rx(-Math.PI / 2, 1);
return c;

Commit your prediction for ⟨Z⟩ of qubit 0 — then run it.