Quiz: Error Mitigation

Answers with explanations at the end.


1. Give three differences between error mitigation and error correction. Which one explains why mitigation is useless for Grover's algorithm?

2. True or false: with enough shots, error mitigation lets you run arbitrarily deep circuits.

3. Why is measurement error the only error channel that can be undone by classical linear algebra?

4. In the assignment matrix $A$, does $A_{ij}$ mean "probability of observing $i$ given prepared $j$" or the reverse? Which of rows or columns must sum to 1?

5. A $4\times4$ assignment matrix has diagonal entries ~0.985, single-flip off-diagonals ~0.010, and corner entries ~0.0001. Why are the corners a hundred times smaller, and what does the overall structure imply about the condition number?

6. Why prefer np.linalg.solve(A, p) over np.linalg.inv(A) @ p?

7. Readout mitigation applied to a Bell state on qubits [9, 8] increased the L1 error from 1.0305 to 1.0654. The pair has an ECR gate error of 1.0. Explain the failure in one sentence.

8. The assignment matrix for a layout containing a stuck qubit has rank 2 instead of 4. State what rank deficiency means physically, and whether more shots would help.

9. In that same matrix, two rows are identically zero and two columns are nearly identical. Explain what each of those two facts tells you about the hardware.

10. How many calibration circuits does full readout mitigation require for 20 qubits? Name two techniques that avoid this cost and state the assumption each makes.

11. Global folding maps $U \to U(U^\dagger U)^k$. Why is this the identity mathematically, and what does it multiply the gate count by?

12. You fold a transpiled ISA circuit and the primitive rejects it with IBMInputValueError: The instruction sxdg ... is not supported. What went wrong and what is the fix?

13. Three extrapolators returned 0.92950, 0.92975, and 0.93039. Is this tight agreement evidence that the extrapolation is trustworthy, that it is untrustworthy, or something else?

14. A circuit containing no gates at all returned $\langle ZZZZ\rangle = +0.96228$ when the true value is exactly $+1$. What is the 0.038 discrepancy, and why can ZNE never remove it?

15. Write the two-term decomposition of the error as a function of the noise scale factor $\lambda$, and identify which term ZNE removes.

16. ZNE improved a raw expectation value by 14% and a readout-mitigated one by 42%. Nothing about the ZNE changed. Explain the difference, and state the general ordering rule it implies.

17. Dynamical decoupling inserted 4 X gates into a depth-213 circuit and changed the result by 0.0000. The pass ran without error and inserted 132 delay instructions. What happened, and what single check would have caught it?

18. When DD was forced to engage (254 X gates), the result got worse by 0.0623. Explain why this is the correct output of the simulation and why it says nothing about DD on real hardware.

19. Pauli twirling does not reduce the error rate at all. Give two reasons to enable it anyway.

20. Rank these four by error reduction per extra shot, on a shallow circuit: readout mitigation, ZNE, PEC, choosing a better qubit layout. Justify the top entry.


Answers

1. Mitigation fixes the expectation value while correction fixes the state; mitigation needs no extra qubits while correction needs 100–1000× per logical qubit; mitigation's shot overhead grows with depth while correction's does not. The first difference explains Grover: Grover needs a single correct bitstring out of the machine, and mitigation only ever improves an average over many runs — it never repairs an individual shot.

2. False. The shot overhead grows with depth, eventually exponentially. Mitigation buys a constant factor of room in front of the exponential wall; it does not move the wall.

3. Because measurement error acts after the quantum state has already collapsed to classical bits. It is a classical stochastic process mapping true bitstrings to observed ones, fully described by a stochastic matrix — so it can be inverted. Gate errors act on the quantum state itself and cannot be undone by post-processing the counts.

4. $A_{ij} = P(\text{observe } i \mid \text{prepared } j)$. Columns must sum to 1: given a definite prepared state $j$, the observed outcome is some bitstring with total probability 1.

5. The corners are double bit-flips, and readout errors are approximately independent — two simultaneous flips have probability ~$0.01^2 = 10^{-4}$, a hundred times rarer than one. The structure is strongly diagonally dominant, so the condition number is near 1 (measured 1.03) and the inversion barely amplifies statistical noise.

6. solve is both more numerically accurate and faster — it does not form the inverse explicitly. The difference grows as $A$ gets larger and worse-conditioned, which is exactly the regime where you are already losing accuracy.

7. Readout mitigation only removes readout error, and on that pair the dominant error was a dead entangling gate — so the inversion applied a correction for a problem that was not the problem and contributed only amplified statistical noise.

8. Rank deficiency means the measurement is a non-injective map: two distinct prepared states produce the same output distribution, so no post-processing can distinguish them. The deficit counts the qubits whose information was destroyed — here, one. More shots do not help; the information was never recorded.

9. Two zero rows mean those two outcomes never occur — the stuck qubit always reports 1, so every outcome with that bit equal to 0 is impossible. Two identical columns mean preparing $|00\rangle$ and $|01\rangle$ gives indistinguishable output, because the bit that differs between them is precisely the stuck one.

10. $2^{20} = 1{,}048{,}576$ circuits. Tensored mitigation needs ~2 circuits and assumes readout errors are independent across qubits (ignoring correlated readout error). M3 never forms the full matrix, working only in the subspace of bitstrings actually observed and solving iteratively.

11. $U^\dagger U = I$, so $U(U^\dagger U)^k = U$ for any $k$ — the circuit computes the same thing. It multiplies the gate count by $2k+1$, so the noise scales while the answer does not.

12. Folding requires circuit.inverse(), and inverting an ISA circuit produces gates outside the device basis (sxdg is the inverse of sx). Fold the logical circuit first, then transpile each folded version — passing the same initial_layout to all of them, so you compare noise levels rather than layouts.

13. Something else — it is evidence the extrapolation is working correctly. Divergence among extrapolators is the warning sign that you are extrapolating past what the data supports; agreement means the fit is well-determined. Since they converged on 0.930 rather than 1.000, the fit was right and the question was incomplete — a term existed that folding does not scale.

14. It is readout error. Folding multiplies the number of gates while leaving the number of measurements unchanged, so the readout contribution is identical at every scale factor. Extrapolating in gate count cannot remove a term that is constant in gate count.

15. $\text{error}(\lambda) = \lambda\,\varepsilon_{\text{gate}} + \varepsilon_{\text{readout}}$. ZNE removes the first term; the second survives extrapolation untouched.

16. Applied to the raw signal, extrapolation targets $\lambda\varepsilon_{\text{gate}}$ while $\varepsilon_{\text{readout}}$ sits underneath as an irreducible floor. Removing that floor first leaves a signal that is entirely scalable, so extrapolation applies to all of it. General rule: remove the noise a technique cannot scale before applying a technique that works by scaling noise.

17. PadDynamicalDecoupling defaults to skip_reset_qubits=True, and ALAP scheduling pushes operations as late as possible — so the idle period landed at the start of the circuit on qubits still in their reset state, and DD skipped all of it. The check: count the inserted pulses (isa_dd.count_ops()["x"] - isa.count_ops()["x"]). Expect hundreds; a handful means it is not engaging.

18. DD works against correlated, slowly-varying noise — a pulse echo reverses a dephasing that is still present when the echo arrives. NoiseModel.from_backend is Markovian: memoryless and uncorrelated. There is nothing for an echo to reverse, so the 254 pulses contribute only their own gate error. The simulation is correct; it simply lacks the physics DD exists to address, so it cannot evaluate the technique either way.

19. (a) It converts coherent errors — which accumulate linearly and can conspire constructively — into stochastic Pauli errors, which accumulate as a random walk; it turns a worst case into an average case. (b) ZNE and PEC both assume a noise model, and twirling makes the actual noise match the assumed one, so the expensive techniques work as advertised. It is free, so leave it on.

20. Layout choice first — it costs zero extra shots and Chapter 12 measured a 3.4× swing in correctness, larger than anything in this chapter. Then readout mitigation (−64% for a handful of circuits), then ZNE (−14% raw, −42% after readout mitigation, for 3–12× the cost), then PEC (exact but $\gamma^{2d}$ — unaffordable beyond small circuits). The top entry wins because it is the only one that is free.