Step–by–Step Derivation
Throughout this sub-problem
• \(p\) = physical two–qubit depolarising probability per CNOT.
• Only the two CNOTs, \(CNOT_{21}\) and \(CNOT_{03}\), are faulty; the single–qubit \(H\) gates are taken to be perfect.
• After the circuit finishes we measure the two stabilisers
\[
S_X = XXXX, \qquad S_Z = ZZZZ
\]
and keep the run ( “post–select’’ ) only when both outcomes are \(+1\).
• Logical fidelity is then
\[
\Pr\!\bigl[\hbox{final logical state }=
|\Phi^+\rangle_{AB}\, \bigl|\, \text{accepted}\bigr], \qquad
|\Phi^+\rangle_{AB}= \tfrac{|00\rangle_{AB}+|11\rangle_{AB}}{\sqrt2}.
\]
- Classification of a single two–qubit Pauli error
For one CNOT a depolarising channel
\(\mathcal D_p\) acts on the same two qubits.
After the gate the error operator \(E\) is
• \(E = I\) with probability \(1-p\),
• one of the \(15\) non–identity Paulis, each with probability \(p/15\).
For every such \(E\) record the commutation parities
\[
c_Z(E)=
\begin{cases}
0 & \text{if }E\text{ commutes with }S_Z,\\
1 & \text{if }E\text{ anticommutes with }S_Z,
\end{cases}
\qquad
c_X(E)=
\begin{cases}
0 & \text{if }E\text{ commutes with }S_X,\\
1 & \text{if }E\text{ anticommutes with }S_X.
\end{cases}
\]
Enumerating the 16 two-qubit Paulis gives four equally sized classes
(Class label \(\equiv (c_Z,c_X)\)):
0 = (0,0), 1 = (1,0), 2 = (0,1), 3 = (1,1)
Probabilities for a single gate
\[
\begin{aligned}
P_0 &= (1-p)+3\frac{p}{15}=1-\frac{4p}{5},\\
P_1 &=P_2=P_3 = 4\frac{p}{15}.
\end{aligned}
\tag{1}
\]
- Two faulty CNOTs: acceptance probability
Errors after the first and second CNOT are \(E_1,E_2\) (independent).
After both have occurred the combined error is \(E_{\text{tot}}=E_2E_1\).
Because \(E_1\) acts only on qubits (2,1) and \(E_2\) only on (0,3),
the commutation signs add mod 2:
\[
c_{Z,X}(E_{\text{tot}})=c_{Z,X}(E_1)\oplus c_{Z,X}(E_2).
\]
“Accept’’ \(\Longleftrightarrow\) \(c_Z(E_{\text{tot}})=c_X(E_{\text{tot}})=0\),
which happens iff the two individual errors belong to the same class.
Hence
\[
P_{\text{acc}}(p)=\sum_{i=0}^{3}P_i^2
\,=\,\bigl(1-\tfrac{4p}{5}\bigr)^2
+3\Bigl(\tfrac{4p}{15}\Bigr)^2
=1-\frac{8p}{5}+\frac{64p^{2}}{75}.
\tag{2}
\]
- Logical effect of the accepted errors
(a) Class 0 operators (commute with both stabilisers) are
\[
\{I,\,X\!X,\,Y\!Y,\,Z\!Z\}
\]
on the relevant qubit pair. On qubits $(1,2)$ they equal, inside the code space,
\[
I,\;X_A X_B,\;Y_A Y_B,\;Z_A Z_B,
\]
and on qubits $(0,3)$ they are the same up to the stabiliser $S_X$.
Therefore **any product of two class-0 operators is**
\[
S\;\bigl\{I,\,X_A X_B,\,Y_A Y_B,\,Z_A Z_B\bigr\},\qquad S\in\langle S_X,S_Z\rangle,
\]
i.e. it either does nothing or multiplies the logical state by a
stabiliser of $|\Phi^+\rangle_{AB}$. These cases give unit overlap with
the target state.
(b) Accepted errors from classes 1, 2 or 3 always act as a single-qubit
logical Pauli (\(X_A,\,Z_A,\,X_B,\,Z_B\) or their products).
Each maps \(|\Phi^+\rangle_{AB}\) to an orthogonal Bell state,
giving zero overlap.
Consequently the conditional logical fidelity is
\[
F_{\text{log}}(p)=
\frac{\Pr\!\left[\text{both errors in class }0\right]}
{P_{\text{acc}}(p)}
=\frac{P_0^{\,2}}{P_{\text{acc}}(p)}.
\tag{3}
\]
- Putting the algebra together
Insert (1) and (2) into (3):
\[
\boxed{F_{\text{log}}(p)=
\frac{\bigl(1-\tfrac{4}{5}p\bigr)^{2}}
{\bigl(1-\tfrac{4}{5}p\bigr)^{2}+\,\dfrac{16}{75}p^{2}}
=\frac{75-120p+48p^{2}}{75-120p+64p^{2}}
}.
\]
Series expansion for small \(p\) (notice the absence of a linear term):
\[
F_{\text{log}}(p)=1-\frac{16}{75}p^{2}+O(p^{3}).
\]
Final Answer:
After post-selecting on the \([[4,2,2]]\) code stabilisers, the logical two-qubit state fidelity is
\[
F_{\text{logical}}(p)=
\frac{\bigl(1-\tfrac{4}{5}p\bigr)^{2}}
{\bigl(1-\tfrac{4}{5}p\bigr)^{2}+\,\dfrac{16}{75}\,p^{2}}
=\frac{75-120p+48p^{2}}{75-120p+64p^{2}}.
\]