The problem asks for the logical state fidelity of a prepared logical \(|00\rangle_{AB}\) state in the [[4,2,2]] code, assuming post-selection on two conditions:
- The ancilla qubit (qubit 4) measures \(|0\rangle\).
- All detectable errors in the code are post-selected against. This means the final 4-qubit state (physical qubits 0,1,2,3) must be a \(+1\) eigenstate of both stabilizers \(S_1\) and \(S_2\).
Let’s first determine the ideal final state. The circuit operations are applied in reverse order to the equation given:
\[
|\psi_{init}\rangle = |00000\rangle_{01234}
\]
- Apply \(H_1\):
\[
|\psi_1\rangle = |0\rangle_0 \frac{1}{\sqrt{2}}(|0\rangle_1+|1\rangle_1) |0\rangle_2 |0\rangle_3 |0\rangle_4 = \frac{1}{\sqrt{2}}(|00000\rangle + |01000\rangle)
\]
- Apply \(CNOT_{12}\) (control 1, target 2):
\[
|\psi_2\rangle = \frac{1}{\sqrt{2}}(|00000\rangle + |01100\rangle)
\]
- Apply \(CNOT_{10}\) (control 1, target 0):
\[
|\psi_3\rangle = \frac{1}{\sqrt{2}}(|00000\rangle + |11100\rangle)
\]
- Apply \(CNOT_{23}\) (control 2, target 3):
\[
|\psi_4\rangle = \frac{1}{\sqrt{2}}(|00000\rangle + |11110\rangle)
\]
- Apply \(CNOT_{34}\) (control 3, target 4):
\[
|\psi_5\rangle = \frac{1}{\sqrt{2}}(|00000\rangle + |11111\rangle)
\]
- Apply \(CNOT_{04}\) (control 0, target 4):
\[
|\psi_{final}\rangle = \frac{1}{\sqrt{2}}(|00000\rangle + |11110\rangle)
\]
(The first term $|00000\rangle$ remains $|00000\rangle$ because control qubit 0 is $|0\rangle$. The second term $|11111\rangle$ becomes $|11110\rangle$ because control qubit 0 is $|1\rangle$, flipping target qubit 4 from $|1\rangle$ to $|0\rangle$.)
Now, we apply the post-selection conditions to this ideal state:
- Ancilla measurement \(M_4\) yields \(|0\rangle\): Since the ancilla qubit 4 is in state \(|0\rangle\) in both terms of \(|\psi_{final}\rangle\), the measurement outcome is always \(|0\rangle\) and the state on qubits 0,1,2,3 is:
\[
|\psi_{0123}\rangle = \frac{1}{\sqrt{2}}(|0000\rangle + |1111\rangle)
\]
- Check if this state is the logical \(|00\rangle_{AB}\) and satisfies the stabilizer conditions.
The stabilizers are \(S_1 = X_0 X_1 X_2 X_3\) and \(S_2 = Z_0 Z_1 Z_2 Z_3\).
\[
S_1 |\psi_{0123}\rangle = \frac{1}{\sqrt{2}}(X_0 X_1 X_2 X_3 |0000\rangle + X_0 X_1 X_2 X_3 |1111\rangle) = \frac{1}{\sqrt{2}}(|1111\rangle + |0000\rangle) = +1 \cdot |\psi_{0123}\rangle
\]
\[
S_2 |\psi_{0123}\rangle = \frac{1}{\sqrt{2}}(Z_0 Z_1 Z_2 Z_3 |0000\rangle + Z_0 Z_1 Z_2 Z_3 |1111\rangle) = \frac{1}{\sqrt{2}}(|0000\rangle + (-1)^4 |1111\rangle) = +1 \cdot |\psi_{0123}\rangle
\]
This state is a $+1$ eigenstate of both stabilizers, meaning it is in the code space.
The logical operators for the code are $Z_A = Z_0 Z_1 I_2 I_3$ and $Z_B = Z_0 I_1 Z_2 I_3$.
\[
Z_A |\psi_{0123}\rangle = \frac{1}{\sqrt{2}}(Z_0 Z_1 |0000\rangle + Z_0 Z_1 |1111\rangle) = \frac{1}{\sqrt{2}}(|0000\rangle + (-1)^2 |1111\rangle) = +1 \cdot |\psi_{0123}\rangle
\]
\[
Z_B |\psi_{0123}\rangle = \frac{1}{\sqrt{2}}(Z_0 Z_2 |0000\rangle + Z_0 Z_2 |1111\rangle) = \frac{1}{\sqrt{2}}(|0000\rangle + (-1)^2 |1111\rangle) = +1 \cdot |\psi_{0123}\rangle
\]
Since it is a $+1$ eigenstate of $Z_A$ and $Z_B$, $|\psi_{0123}\rangle$ is indeed the logical $|00\rangle_{AB}$ state.
Now, let’s consider the effect of errors. Each of the 5 CNOT gates is followed by a two-qubit depolarizing error channel. This means with probability \((1-p)\), no error occurs, and with probability \(p\), one of the 15 non-identity two-qubit Paulis acts on the qubits involved in the CNOT (each with probability \(p/15\)). We analyze this to first order in \(p\).
The fidelity calculation relies on determining which errors are undetected by the ancilla measurement and the code stabilizers, and what effect these errors have on the logical state.
An error is detected if:
- The ancilla qubit 4 measures \(|1\rangle\).
- The 4-qubit state (on qubits 0,1,2,3) is not a \(+1\) eigenstate of \(S_1\) or \(S_2\).
Let \(E\) be a two-qubit Pauli error that occurs after one of the CNOT gates. This error \(E\) propagates through the rest of the circuit to become an effective Pauli operator \(E'_{final}\) acting on the ideal final state \(|\psi_{final}\rangle = |00\rangle_L \otimes |0\rangle_4\).
The resulting state is \(E'_{final} |\psi_{final}\rangle\).
Ancilla detection:
If \(E'_{final}\) has an \(X_4\) or \(Y_4\) component on the ancilla qubit 4, then \(E'_{final} |\psi_{final}\rangle\) will have qubit 4 in a \(|1\rangle\) state (or a superposition with \(|1\rangle\)). Any measurement of \(|1\rangle\) on qubit 4 means the error is detected, and this preparation is discarded. Thus, only errors \(E'_{final}\) with \(I_4\) or \(Z_4\) components on qubit 4 will pass the ancilla post-selection.
If \(E'_{final} = P_{0123} \otimes Z_4\), then \(E'_{final} |\psi_{final}\rangle = P_{0123} |00\rangle_L \otimes Z_4 |0\rangle_4 = P_{0123} |00\rangle_L \otimes |0\rangle_4\).
If \(E'_{final} = P_{0123} \otimes I_4\), then \(E'_{final} |\psi_{final}\rangle = P_{0123} |00\rangle_L \otimes |0\rangle_4\).
In both cases, after post-selection on ancilla \(M_4=|0\rangle\), the resulting 4-qubit state is \(P_{0123} |00\rangle_L\).
Code detection:
Now we need to check if this state \(P_{0123} |00\rangle_L\) is detected by the code stabilizers.
An error is undetected by the code if \(P_{0123}\) commutes with both \(S_1\) and \(S_2\), and leaves the code space invariant.
An error is a logical error if \(P_{0123}\) commutes with both \(S_1\) and \(S_2\), and maps \(|00\rangle_L\) to an orthogonal logical state (e.g. \(|10\rangle_L\)).
Let’s check the logical operators provided in the problem for their commutation with the stabilizers:
\(X_A = X_0 I_1 X_2 I_3\)
\(X_B = X_0 X_1 I_2 I_3\)
\(Z_A = Z_0 Z_1 I_2 I_3\)
\(Z_B = Z_0 I_1 Z_2 I_3\)
Stabilizers: \(S_1 = X_0 X_1 X_2 X_3\), \(S_2 = Z_0 Z_1 Z_2 Z_3\).
-
For \(X_A = X_0 X_2\):
\(X_A S_1 = (X_0 X_2) (X_0 X_1 X_2 X_3) = X_0^2 X_1 X_2^2 X_3 = X_1 X_3\).
\(S_1 X_A = (X_0 X_1 X_2 X_3) (X_0 X_2) = X_0 (X_1 X_0) X_2 X_3 X_2 = X_0 (-X_0 X_1) X_2 X_3 X_2 = -X_1 X_2 X_3 X_2 = -X_1 X_3\).
Since \(X_A S_1 = -S_1 X_A\), \(X_A\) anti-commutes with \(S_1\).
If an error causes an effective \(X_A\) operation on \(|00\rangle_L\), the resulting state \(X_A |00\rangle_L\) will be a \(-1\) eigenstate of \(S_1\): \(S_1 (X_A |00\rangle_L) = (S_1 X_A) |00\rangle_L = (-X_A S_1) |00\rangle_L = -X_A (S_1 |00\rangle_L) = -X_A |00\rangle_L\).
Thus, an effective \(X_A\) error is detected by the code.
-
For \(X_B = X_0 X_1\):
\(X_B S_1 = (X_0 X_1) (X_0 X_1 X_2 X_3) = X_0^2 X_1^2 X_2 X_3 = X_2 X_3\).
\(S_1 X_B = (X_0 X_1 X_2 X_3) (X_0 X_1) = X_0 X_1 X_0 X_1 X_2 X_3 = X_0 (-X_0 X_1) X_1 X_2 X_3 = -X_1^2 X_2 X_3 = -X_2 X_3\).
\(X_B\) anti-commutes with \(S_1\). Thus, an effective \(X_B\) error is detected by the code.
-
For \(Z_A = Z_0 Z_1\):
\(Z_A S_1 = (Z_0 Z_1) (X_0 X_1 X_2 X_3) = (Z_0 X_0) (Z_1 X_1) X_2 X_3 = (-X_0 Z_0) (-X_1 Z_1) X_2 X_3 = X_0 Z_0 X_1 Z_1 X_2 X_3\).
\(S_1 Z_A = (X_0 X_1 X_2 X_3) (Z_0 Z_1) = (X_0 Z_0) (X_1 Z_1) X_2 X_3 = (-Z_0 X_0) (-Z_1 X_1) X_2 X_3 = Z_0 X_0 Z_1 X_1 X_2 X_3\).
\(Z_A S_1 = S_1 Z_A\). So \(Z_A\) commutes with \(S_1\).
Let’s check \(Z_A S_2\):
\(Z_A S_2 = (Z_0 Z_1) (Z_0 Z_1 Z_2 Z_3) = Z_0^2 Z_1^2 Z_2 Z_3 = Z_2 Z_3\).
\(S_2 Z_A = (Z_0 Z_1 Z_2 Z_3) (Z_0 Z_1) = Z_0 Z_1 Z_0 Z_1 Z_2 Z_3 = Z_0^2 Z_1^2 Z_2 Z_3 = Z_2 Z_3\).
\(Z_A S_2 = S_2 Z_A\). So \(Z_A\) commutes with \(S_2\).
Since \(Z_A\) commutes with both stabilizers, an effective \(Z_A\) error is not detected by the code.
However, \(Z_A |00\rangle_L = |00\rangle_L\), so this specific error does not cause a logical fidelity loss. (\(Z_A\) is the stabilizer for the logical \(|0\rangle_A\) state).
-
For \(Z_B = Z_0 Z_2\):
\(Z_B S_1 = (Z_0 Z_2) (X_0 X_1 X_2 X_3) = (Z_0 X_0) X_1 (Z_2 X_2) X_3 = (-X_0 Z_0) X_1 (-X_2 Z_2) X_3 = X_0 Z_0 X_1 X_2 Z_2 X_3\).
\(S_1 Z_B = (X_0 X_1 X_2 X_3) (Z_0 Z_2) = (X_0 Z_0) X_1 (X_2 Z_2) X_3 = (-Z_0 X_0) X_1 (-Z_2 X_2) X_3 = Z_0 X_0 X_1 Z_2 X_2 X_3\).
\(Z_B S_1 = S_1 Z_B\). So \(Z_B\) commutes with \(S_1\).
Let’s check \(Z_B S_2\):
\(Z_B S_2 = (Z_0 Z_2) (Z_0 Z_1 Z_2 Z_3) = Z_0^2 Z_1 Z_2^2 Z_3 = Z_1 Z_3\).
\(S_2 Z_B = (Z_0 Z_1 Z_2 Z_3) (Z_0 Z_2) = Z_0 Z_1 Z_0 Z_2 Z_2 Z_3 = Z_0^2 Z_1 Z_2^2 Z_3 = Z_1 Z_3\).
\(Z_B S_2 = S_2 Z_B\). So \(Z_B\) commutes with \(S_2\).
Similarly, \(Z_B\) commutes with both stabilizers, and \(Z_B |00\rangle_L = |00\rangle_L\). So this does not cause a logical fidelity loss.
Summary of logical operators action:
* \(X_A, X_B\) (and their combinations \(Y_A, Y_B\)) anti-commute with \(S_1\). Thus, any effective error that behaves like \(X_A, X_B, Y_A, Y_B\) is detected by the code stabilizers.
* \(Z_A, Z_B\) (and their combinations) commute with both \(S_1\) and \(S_2\). However, \(Z_A |00\rangle_L = |00\rangle_L\) and \(Z_B |00\rangle_L = |00\rangle_L\). So these errors do not change the logical state \(|00\rangle_L\).
This implies that any single Pauli error that propagates through the circuit and passes the ancilla post-selection, resulting in a state \(P_{0123} |00\rangle_L\):
* If \(P_{0123}\) would change the logical state (e.g., to \(|10\rangle_L\)), it must be an effective \(X_A, Y_A, X_B, Y_B\) or their products. All these operators anti-commute with \(S_1\), meaning the error will be detected by the code. Therefore, such a preparation will be discarded.
* If \(P_{0123}\) is an identity or a stabilizer (\(I, S_1, S_2, S_1S_2\)) or a logical \(Z\) operator (\(Z_A, Z_B\)), it results in the original logical state \(|00\rangle_L\). In this case, there is no fidelity loss.
Therefore, for any single two-qubit depolarizing error, if the ancilla measures \(|0\rangle\) and the code stabilizers both measure \(+1\), the final logical state must be the ideal \(|00\rangle_{AB}\) state. No single error can result in a different logical state that is undetected.
The logical state fidelity \(F\) is defined as \(F = \frac{\langle 00|_L \rho_{succ} |00\rangle_L}{\mathrm{Tr}(\rho_{succ})}\), where \(\rho_{succ}\) is the density matrix of the state after post-selection.
Since all successfully post-selected states are \(|00\rangle_L\), \(\rho_{succ}\) is proportional to \(|00\rangle_L \langle 00|_L\).
Thus, the fidelity is 1.
This result holds to first order in \(p\), as we only considered single errors. If higher-order errors were considered, it is possible for two errors, for example, to effectively cancel their detection syndrome and form an undetected logical error. However, based on the problem’s formulation and typical fault-tolerance analysis focusing on leading order \(p\), the conclusion remains \(F=1\).
The final answer is \(\boxed{1}\).