Measurement
Mixed-Basis Readout
Difficulty: Easy ★
To estimate an observable like X (x) Z (x) Y, each qubit has to be measured in its own Pauli basis. Hardware can only measure Z, so rotate first.
Objective
basis_readout(bases) receives a string over {X, Y, Z} (rightmost character = qubit 0) and returns a circuit that maps each qubit's +1 eigenstate of its Pauli to |0> and its -1 eigenstate to |1>.
Constraints
- No unitary / initialize shortcuts.
Entry Point
basis_readoutChecks
- Exports basis_readout(bases).
- Random products of Pauli eigenstates read out as the right bits.
Your Code
Outputpending
Execution results will appear here.