Checkpoint-2

System #0

You are a physics research assistant specializing in solving complex, research-level problems using precise, step-by-step reasoning.

Input Problems will be provided in Markdown format.

Output (Markdown format)

  1. Step-by-Step Derivation - Show every non-trivial step in the solution. Justify steps using relevant physical laws, theorems, or mathematical identities.
  2. Mathematical Typesetting - Use LaTeX for all mathematics: $...$ for inline expressions, $$...$$ for display equations.
  3. Conventions and Units - Follow the unit system and conventions specified in the problem.
  4. Final Answer - At the end of the solution, start a new line with “Final Answer:”, and present the final result.

    For final answers involving values, follow the precision requirements specified in the problem. If no precision is specified: - If an exact value is possible, provide it (e.g., \$\sqrt(2)\$, \$\pi/4\$). - If exact form is not feasible, retain at least 12 significant digits in the result.

  5. Formatting Compliance - If the user requests a specific output format (e.g., code, table), provide the final answer accordingly.

User #1

Problem setup:

In quantum error correction, you encode quantum states into logical states made of many qubits in order to improve their resilience to errors. In quantum error detection, you do the same but can only detect the presence of errors and not correct them. In this problem, we will consider a single [[4,2,2]] quantum error detection code, which encodes two logical qubits into four physical qubits, and investigate how robust logical quantum operations in this code are to quantum errors.

Our convention is that the four physical qubits in the [[4,2,2]] code are labelled 0,1,2,3. The two logical qubits are labelled A and B. The stabilizers are \(XXXX\) and \(ZZZZ\), where \(X\) and \(Z\) are Pauli matrices. The logical \(X\) and \(Z\) operators on the two qubits are \(X_A = XIXI\), \(X_B=XXII\), \(Z_A = ZZII\), \(Z_B = ZIZI\), up to multiplication by stabilizers.

We will consider different state preparation circuits consisting of controlled not \(CNOT_{ij}\) gates, where \(CNOT_{ij}\) has control qubit \(i\) and target qubit \(j\). As a simple model of quantum errors in hardware, we will suppose that each \(CNOT_{ij}\) gate in the circuit has a two qubit depolarizing error channel following it that produces one of the 15 non-identity two-qubit Paulis with equal probability \(p/15\). The probability \(p\) indicates the probability of an error in a single two-qubit gate. We will assess the logical infidelity of certain state preparation protocols as a function of the physical infidelity \(p\).

Checkpoints

Checkpoint 1

Suppose that we wish to prepare a logical two-qubit GHZ state \((|00\rangle_{AB}+|11\rangle_{AB})/\sqrt{2}\) in the [[4,2,2]] code. To do so, we use the following state preparation circuit:

\[ (CNOT_{03}) (H_0) (CNOT_{21}) (H_2). \]

Note that this equation is written in matrix multiplication order, while the quantum operations in the circuit occur in the reverse order (from right-to-left in the above equation). \(H\) is a single-qubit Hadamard gate.

What is the physical state fidelity of the final physical 4-qubit state at the end of the circuit as a function of the two-qubit gate error rate \(p\)?

Assistant #2
Reasoning (model)

Analyzing Physical State Fidelity in a Noisy Circuit

As an expert in the field, I’m tasked with calculating the fidelity of a specific state preparation circuit, taking into account the presence of two-qubit depolarizing errors. My approach involves several key steps:

  1. Understanding the Target Logical State: My goal is to create the logical GHZ state, which is a superposition of |00> and |11>. I need to determine the mapping of this logical state to a physical 4-qubit representation using the [[4,2,2]] code properties.

  2. Circuit Analysis: The circuit comprises of a sequence of operations: \((CNOT_{03}) (H_0) (CNOT_{21}) (H_2)\). Since these are applied from right to left, I need to understand what state would be produced step-by-step.

  3. Error Modeling: I’ll be modeling the errors in the circuit using the two-qubit depolarizing error channel applied after each CNOT gate.

  4. Fidelity Calculation: To quantify the performance of this noisy circuit, I will be calculating the fidelity which is the overlap between the ideal target state and the noisy state. If the ideal state is pure \(|\psi\rangle\), then the fidelity \(F = \langle\psi|\rho_{noisy}|\psi\rangle\).

Decoding the Circuit and Error:

The code space is defined by two stabilizers: \(S_1 = X_0 X_1 X_2 X_3\) and \(S_2 = Z_0 Z_1 Z_2 Z_3\). I’ll use logical operators \(X_A, X_B, Z_A, Z_B\).

Step 1. Encoding the Logical GHZ State:

I’ll proceed to determine the physical representation of the logical state through circuit application. The circuit will be applied to the state \(|0000\rangle\), and then each step will be followed by the error channels, generating the noisy state. First I calculate the ideal state produced:

  1. \(H_2: |0000\rangle \rightarrow \frac{1}{\sqrt{2}}(|0000\rangle+|0010\rangle)\).
  2. \(CNOT_{21}: \frac{1}{\sqrt{2}}(|0000\rangle+|0010\rangle) \rightarrow \frac{1}{\sqrt{2}}(|0000\rangle+|0110\rangle)\).
  3. \(H_0: \frac{1}{\sqrt{2}}(|0000\rangle+|0110\rangle) \rightarrow \frac{1}{2}(|0000\rangle+|1000\rangle+|0110\rangle+|1110\rangle)\).
  4. \(CNOT_{03}: \frac{1}{2}(|0000\rangle+|1000\rangle+|0110\rangle+|1110\rangle) \rightarrow \frac{1}{2}(|0000\rangle+|1001\rangle+|0110\rangle+|1111\rangle)\). So the ideal final state is: \(\frac{1}{2}(|0000\rangle+|1001\rangle+|0110\rangle+|1111\rangle)\). Verifying that this is a valid logical GHZ state is important. The logical GHZ must satisfy \(X_A X_B |\psi_{GHZ}\rangle = |\psi_{GHZ}\rangle\) and \(Z_A Z_B |\psi_{GHZ}\rangle = |\psi_{GHZ}\rangle\), and also the stabilizers \(S_1, S_2\) must give the state back.

Step 2: Accounting for the Noise.

The fidelity calculation involves carefully tracking the state through the circuit and the depolarizing errors. The state undergoes:

\(\rho_{noisy} = \mathcal{D}_{03}(CNOT_{03} H_0 \mathcal{D}_{21}(CNOT_{21} H_2 |0000\rangle\langle0000| H_2^\dagger) H_0^\dagger CNOT_{03}^\dagger)\).

Here I used \(\mathcal{D}\) for the depolarizing error channels. Since the fidelity is \(F = \langle\psi_{ideal}|\rho_{noisy}|\psi_{ideal}\rangle\), this can be simplified by repeatedly using the cyclic property of the trace and the channel structure. The fidelity can be rewritten to consider the expectation values of the Pauli operations.

To simplify the calculation of the noisy state, and since the

The problem asks us to calculate the physical state fidelity of a specific quantum circuit designed to prepare a logical GHZ state, given a model of two-qubit depolarizing errors following each CNOT gate.

The state preparation circuit, applied to the initial state \(|0000\rangle\), is:

\[ U_{circ} = (CNOT_{03}) (H_0) (CNOT_{21}) (H_2) \]

The operations are applied from right to left, starting with \(|0000\rangle\).

1. Determine the ideal final physical state:

Let’s trace the initial state \(|0000\rangle\) through the ideal circuit: * Initial state: \(|\psi_{init}\rangle = |0000\rangle\). * After \(H_2\) (on qubit 2): \(|\psi_A\rangle = H_2 |0000\rangle = |00\rangle_0 \frac{|0\rangle_2+|1\rangle_2}{\sqrt{2}} |0\rangle_3 = \frac{1}{\sqrt{2}}(|0000\rangle+|0010\rangle)\). * After \(CNOT_{21}\) (control qubit 2, target qubit 1): \(CNOT_{21} |0000\rangle = |0000\rangle\). \(CNOT_{21} |0010\rangle = |0110\rangle\). \(|\psi_B\rangle = CNOT_{21} |\psi_A\rangle = \frac{1}{\sqrt{2}}(|0000\rangle+|0110\rangle)\). * After \(H_0\) (on qubit 0): \(H_0 |0000\rangle = \frac{1}{\sqrt{2}}(|0000\rangle+|1000\rangle)\). \(H_0 |0110\rangle = \frac{1}{\sqrt{2}}(|0110\rangle+|1110\rangle)\). \(|\psi_C\rangle = H_0 |\psi_B\rangle = \frac{1}{2}(|0000\rangle+|1000\rangle+|0110\rangle+|1110\rangle)\). * After \(CNOT_{03}\) (control qubit 0, target qubit 3): \(CNOT_{03} |0000\rangle = |0000\rangle\). \(CNOT_{03} |1000\rangle = |1001\rangle\). \(CNOT_{03} |0110\rangle = |0110\rangle\). \(CNOT_{03} |1110\rangle = |1111\rangle\). The ideal final physical state is: \(|\psi_{ideal}\rangle = CNOT_{03} |\psi_C\rangle = \frac{1}{2}(|0000\rangle+|1001\rangle+|0110\rangle+|1111\rangle)\).

2. Model the noisy evolution and calculate the fidelity:

Let the initial state be \(\rho_0 = |0000\rangle\langle0000|\). The circuit has two CNOT gates: \(CNOT_{21}\) and \(CNOT_{03}\). Each is followed by a two-qubit depolarizing channel \(\mathcal{D}_{ij}\) with error rate \(p\). The depolarizing channel on two qubits \(i, j\) is defined as:

\[ \mathcal{D}_{ij}(\rho) = (1-p) \rho + \frac{p}{15} \sum_{P \in \mathcal{P}_{ij} \setminus \{I \otimes I\}} P \rho P \]

where \(\mathcal{P}_{ij}\) is the set of 16 two-qubit Pauli operators acting on qubits \(i,j\) and identity on other qubits.

Let \(U_1=H_2\), \(U_2=CNOT_{21}\), \(U_3=H_0\), \(U_4=CNOT_{03}\). The evolution of the density matrix is:

  1. \(\rho_1 = U_1 \rho_0 U_1^\dagger = |\psi_A\rangle\langle\psi_A|\).
  2. \(\rho_2 = U_2 \rho_1 U_2^\dagger = |\psi_B\rangle\langle\psi_B|\).
  3. \(\rho_{err,1} = \mathcal{D}_{21}(\rho_2)\). (Depolarizing error on qubits 2,1 after \(CNOT_{21}\))
  4. \(\rho_3 = U_3 \rho_{err,1} U_3^\dagger\).
  5. \(\rho_4 = U_4 \rho_3 U_4^\dagger\).
  6. \(\rho_{noisy} = \mathcal{D}_{03}(\rho_4)\). (Depolarizing error on qubits 0,3 after \(CNOT_{03}\))

The physical state fidelity is \(F = \langle\psi_{ideal}|\rho_{noisy}|\psi_{ideal}\rangle = \text{Tr}(|\psi_{ideal}\rangle\langle\psi_{ideal}| \rho_{noisy})\). Let \(\Pi_{ideal} = |\psi_{ideal}\rangle\langle\psi_{ideal}|\).

We can expand the fidelity using linearity:

\[ F = \text{Tr}\left(\Pi_{ideal} \left[ (1-p)\rho_4 + \frac{p}{15} \sum_{j=1}^{15} P_j^{(03)} \rho_4 P_j^{(03)} \right]\right) \]
\[ F = (1-p) \text{Tr}(\Pi_{ideal} \rho_4) + \frac{p}{15} \sum_{j=1}^{15} \text{Tr}(\Pi_{ideal} P_j^{(03)} \rho_4 P_j^{(03)}) \]

Let’s analyze \(\text{Tr}(\Pi_{ideal} \rho_4)\):

\[ \text{Tr}(\Pi_{ideal} \rho_4) = \text{Tr}(\Pi_{ideal} U_4 \rho_3 U_4^\dagger) = \text{Tr}(U_4^\dagger \Pi_{ideal} U_4 \rho_3) \]

Since \(\Pi_{ideal} = U_4 U_3 U_2 U_1 \rho_0 U_1^\dagger U_2^\dagger U_3^\dagger U_4^\dagger\), we have \(U_4^\dagger \Pi_{ideal} U_4 = U_3 U_2 U_1 \rho_0 U_1^\dagger U_2^\dagger U_3^\dagger = |\psi_C\rangle\langle\psi_C|\). So, \(\text{Tr}(\Pi_{ideal} \rho_4) = \langle\psi_C|\rho_3|\psi_C\rangle\).

Now expand \(\rho_3 = U_3 \rho_{err,1} U_3^\dagger\):

\[ \langle\psi_C|\rho_3|\psi_C\rangle = \langle\psi_C|U_3 \rho_{err,1} U_3^\dagger|\psi_C\rangle = \text{Tr}(U_3^\dagger |\psi_C\rangle\langle\psi_C| U_3 \rho_{err,1}) \]

Since \(U_3^\dagger |\psi_C\rangle\langle\psi_C| U_3 = |\psi_B\rangle\langle\psi_B|\), this becomes \(\langle\psi_B|\rho_{err,1}|\psi_B\rangle\). Then, substituting \(\rho_{err,1} = \mathcal{D}_{21}(\rho_2)\):

\[ \langle\psi_B|\rho_{err,1}|\psi_B\rangle = (1-p)\langle\psi_B|\rho_2|\psi_B\rangle + \frac{p}{15}\sum_{k=1}^{15}\langle\psi_B|P_k^{(21)}\rho_2 P_k^{(21)}|\psi_B\rangle \]

Since \(\rho_2=|\psi_B\rangle\langle\psi_B|\), we have \(\langle\psi_B|\rho_2|\psi_B\rangle = 1\). And \(\langle\psi_B|P_k^{(21)}\rho_2 P_k^{(21)}|\psi_B\rangle = |\langle\psi_B|P_k^{(21)}|\psi_B\rangle|^2\).

So, the fidelity can be expressed as:

\[ F = (1-p)\left[ (1-p) + \frac{p}{15} \sum_{k=1}^{15} |\langle\psi_B|P_k^{(21)}|\psi_B\rangle|^2 \right] + \frac{p}{15} \sum_{j=1}^{15} \text{Tr}(P_j^{(03)} \Pi_{ideal} P_j^{(03)} U_4 \rho_3 U_4^\dagger) \]

The second term can be further simplified. Let \(M_j = P_j^{(03)} \Pi_{ideal} P_j^{(03)}\). \(\text{Tr}(M_j U_4 \rho_3 U_4^\dagger) = \text{Tr}(U_4^\dagger M_j U_4 \rho_3)\). \(U_4^\dagger M_j U_4 = U_4^\dagger P_j^{(03)} U_4 U_4^\dagger \Pi_{ideal} U_4 U_4^\dagger P_j^{(03)} U_4 = (U_4^\dagger P_j^{(03)} U_4) |\psi_C\rangle\langle\psi_C| (U_4^\dagger P_j^{(03)} U_4)\). Let \(\tilde{P}_j^{(03)} = U_4^\dagger P_j^{(03)} U_4\). Then the second sum is \(\frac{p}{15} \sum_j \text{Tr}(\tilde{P}_j^{(03)} |\psi_C\rangle\langle\psi_C| \tilde{P}_j^{(03)} \rho_3)\). Using \(\rho_3 = U_3 \rho_{err,1} U_3^\dagger\): \(\text{Tr}(\tilde{P}_j^{(03)} |\psi_C\rangle\langle\psi_C| \tilde{P}_j^{(03)} U_3 \rho_{err,1} U_3^\dagger) = \text{Tr}(U_3^\dagger \tilde{P}_j^{(03)} |\psi_C\rangle\langle\psi_C| \tilde{P}_j^{(03)} U_3 \rho_{err,1})\). Let \(\hat{P}_j^{(03)} = U_3^\dagger \tilde{P}_j^{(03)} U_3\). This becomes \(\text{Tr}(\hat{P}_j^{(03)} |\psi_B\rangle\langle\psi_B| \hat{P}_j^{(03)} \rho_{err,1})\). Substituting \(\rho_{err,1} = (1-p)\rho_2 + \frac{p}{15}\sum_k P_k^{(21)}\rho_2 P_k^{(21)}\): The terms contribute \(p(1-p)\frac{1}{15} \sum_j |\langle\psi_B|\hat{P}_j^{(03)}|\psi_B\rangle|^2\) and \(p^2\frac{1}{15^2} \sum_j\sum_k |\langle\psi_B|\hat{P}_j^{(03)}P_k^{(21)}|\psi_B\rangle|^2\).

The exact fidelity expression is:

\[ F = (1-p)^2 + (1-p)\frac{p}{15} \sum_{k=1}^{15} |\langle\psi_B|P_k^{(21)}|\psi_B\rangle|^2 + (1-p)\frac{p}{15} \sum_{j=1}^{15} |\langle\psi_{ideal}|P_j^{(03)}|\psi_{ideal}\rangle|^2 + \frac{p^2}{15^2} \sum_{j=1}^{15}\sum_{k=1}^{15} |\langle\psi_{ideal}|P_j^{(03)} U_4 U_3 P_k^{(21)} U_2 U_1 |0000\rangle|^2 \]

Let’s evaluate each sum:

Term 1: \(\sum_{k=1}^{15} |\langle\psi_B|P_k^{(21)}|\psi_B\rangle|^2\) \(|\psi_B\rangle = \frac{1}{\sqrt{2}}(|0000\rangle+|0110\rangle)\). This can be written as \(|0\rangle_0 \otimes \frac{1}{\sqrt{2}}(|00\rangle_{12}+|11\rangle_{12}) \otimes |0\rangle_3\). Let \(|\chi\rangle_{12} = \frac{1}{\sqrt{2}}(|00\rangle_{12}+|11\rangle_{12})\). The operator \(P_k^{(21)}\) acts on qubits 1 and 2, so \(P_k^{(21)} = I_0 \otimes P'_{12} \otimes I_3\). So, \(\langle\psi_B|P_k^{(21)}|\psi_B\rangle = \langle\chi|_{12} P'_{12} |\chi\rangle_{12}\). For the Bell state \(|\chi\rangle_{12}\), the expectation values of two-qubit Paulis are non-zero only for \(P'_{12} \in \{II, XX, YY, ZZ\}\). \(\langle\chi|XX|\chi\rangle = 1\) \(\langle\chi|YY|\chi\rangle = -1\) \(\langle\chi|ZZ|\chi\rangle = 1\) The sum is over 15 non-identity Paulis. So, we exclude \(II\). \(\sum_{k=1}^{15} |\langle\psi_B|P_k^{(21)}|\psi_B\rangle|^2 = |1|^2 + |-1|^2 + |1|^2 = 3\).

Term 2: \(\sum_{j=1}^{15} |\langle\psi_{ideal}|P_j^{(03)}|\psi_{ideal}\rangle|^2\) \(|\psi_{ideal}\rangle = \frac{1}{2}(|0000\rangle+|1001\rangle+|0110\rangle+|1111\rangle)\). The operator \(P_j^{(03)}\) acts on qubits 0 and 3, so \(P_j^{(03)} = P'_0 \otimes I_{12} \otimes P'_3\). Let’s check the expectation values for \(P'_0 P'_3\): \(\langle\psi_{ideal}|X_0 X_3|\psi_{ideal}\rangle = 1\) \(\langle\psi_{ideal}|Y_0 Y_3|\psi_{ideal}\rangle = -1\) \(\langle\psi_{ideal}|Z_0 Z_3|\psi_{ideal}\rangle = 1\) All other 12 two-qubit Paulis on qubits 0 and 3 (e.g., \(X_0 I_3\), \(I_0 Z_3\), \(X_0 Z_3\), etc.) yield an expectation value of 0 due to the structure of \(|\psi_{ideal}\rangle\). For example, \(\langle\psi_{ideal}|X_0 I_3|\psi_{ideal}\rangle = \frac{1}{4} (\langle0000|+\langle1001|+\langle0110|+\langle1111|) (X_0 I_3) (|0000\rangle+|1001\rangle+|0110\rangle+|1111\rangle)\). \(X_0 I_3 |\psi_{ideal}\rangle = \frac{1}{2}(|1000\rangle+|0001\rangle+|1110\rangle+|0111\rangle)\). This is orthogonal to \(|\psi_{ideal}\rangle\), so the inner product is 0. Thus, \(\sum_{j=1}^{15} |\langle\psi_{ideal}|P_j^{(03)}|\psi_{ideal}\rangle|^2 = |1|^2 + |-1|^2 + |1|^2 = 3\).

Term 3: \(\frac{p^2}{15^2} \sum_{j=1}^{15}\sum_{k=1}^{15} |\langle\psi_{ideal}|P_j^{(03)} U_4 U_3 P_k^{(21)} U_2 U_1 |0000\rangle|^2\) Let \(U_{DC} = U_4 U_3 = CNOT_{03} H_0\). The term inside the sum is \(|\langle\psi_{ideal}|P_j^{(03)} U_{DC} P_k^{(21)} |\psi_B\rangle|^2\). Using \(|\psi_{ideal}\rangle = U_{DC} |\psi_B\rangle\), this becomes: \(|\langle U_{DC} \psi_B | P_j^{(03)} U_{DC} P_k^{(21)} |\psi_B\rangle|^2 = |\langle \psi_B | U_{DC}^\dagger P_j^{(03)} U_{DC} P_k^{(21)} |\psi_B\rangle|^2\). Let \(M_j = U_{DC}^\dagger P_j^{(03)} U_{DC} = H_0 CNOT_{03} P_j^{(03)} CNOT_{03} H_0\). The operator \(P_j^{(03)}\) acts only on qubits 0 and 3. The conjugation by \(CNOT_{03}\) keeps the operator localized to qubits 0 and 3. The conjugation by \(H_0\) (only on qubit 0) also keeps the operator localized to qubits 0 and 3. So \(M_j\) acts only on qubits 0 and 3. \(M_j = M_{j(03)} \otimes I_{12}\). The operator \(P_k^{(21)}\) acts only on qubits 1 and 2. \(P_k^{(21)} = I_0 \otimes P'_{k(12)} \otimes I_3\). The state \(|\psi_B\rangle = |0\rangle_0 \otimes |\chi\rangle_{12} \otimes |0\rangle_3\). So, \(\langle\psi_B | M_j P_k^{(21)} |\psi_B\rangle = \langle 0_0 \chi_{12} 0_3 | (M_{j(03)} \otimes I_{12}) (I_0 \otimes P'_{k(12)} \otimes I_3) | 0_0 \chi_{12} 0_3 \rangle\). \(= \langle 0_0 0_3 | M_{j(03)} | 0_0 0_3 \rangle \langle \chi_{12} | P'_{k(12)} | \chi_{12} \rangle\). This allows us to factor the sum: \(\sum_{j,k} |\langle\psi_B | M_j P_k^{(21)} |\psi_B\rangle|^2 = \left( \sum_j |\langle 0_0 0_3 | M_{j(03)} | 0_0 0_3 \rangle|^2 \right) \left( \sum_k |\langle \chi_{12} | P'_{k(12)} | \chi_{12} \rangle|^2 \right)\).

The second factor is 3, as calculated for Term 1. For the first factor: \(\langle 0_0 0_3 | M_{j(03)} | 0_0 0_3 \rangle = \langle 0_0 0_3 | H_0 CNOT_{03} P_j^{(03)} CNOT_{03} H_0 | 0_0 0_3 \rangle\). Applying \(H_0\) to \(|0\rangle_0\) gives \(|+\rangle_0 = \frac{1}{\sqrt{2}}(|0\rangle_0+|1\rangle_0)\). So, this is \(\langle +_0 0_3 | CNOT_{03} P_j^{(03)} CNOT_{03} | +_0 0_3 \rangle\). The action of \(CNOT_{03}\) on \(|+\rangle_0 |0\rangle_3\) is \(CNOT_{03} \frac{1}{\sqrt{2}}(|00\rangle_{03}+|10\rangle_{03}) = \frac{1}{\sqrt{2}}(|00\rangle_{03}+|11\rangle_{03}) = |\Phi^+\rangle_{03}\). So, this term is \(\langle \Phi^+_{03} | P_j^{(03)} | \Phi^+_{03} \rangle\). The sum \(\sum_j |\langle \Phi^+_{03} | P_j^{(03)} | \Phi^+_{03} \rangle|^2\) is over 15 non-identity Paulis on qubits 0 and 3, in the Bell state \(|\Phi^+\rangle_{03}\). This is the same form as Term 2, so the sum is 3.

Therefore, the third term’s contribution is \(\frac{p^2}{15^2} \cdot (3 \times 3) = \frac{9p^2}{225} = \frac{p^2}{25}\).

3. Combine terms for total fidelity:

\[ F = (1-p)^2 + (1-p)\frac{p}{15}(3) + (1-p)\frac{p}{15}(3) + \frac{p^2}{25} \]
\[ F = (1-2p+p^2) + \frac{3p(1-p)}{15} + \frac{3p(1-p)}{15} + \frac{p^2}{25} \]
\[ F = (1-2p+p^2) + \frac{2p(1-p)}{5} + \frac{p^2}{25} \]
\[ F = 1 - 2p + p^2 + \frac{2}{5}p - \frac{2}{5}p^2 + \frac{1}{25}p^2 \]

Collect terms by powers of \(p\):

\[ F = 1 + \left(-2 + \frac{2}{5}\right)p + \left(1 - \frac{2}{5} + \frac{1}{25}\right)p^2 \]
\[ F = 1 + \left(\frac{-10+2}{5}\right)p + \left(\frac{25-10+1}{25}\right)p^2 \]
\[ F = 1 - \frac{8}{5}p + \frac{16}{25}p^2 \]

This expression can also be written as \(F = \left(1 - \frac{4}{5}p\right)^2\).

The final answer is \(\boxed{1 - \frac{8}{5}p + \frac{16}{25}p^2}\).

User #3

The correct answer is: $ F_{\rm{physical}}=(1-\frac{12}{15}p)^2 $

Now let’s solve the next Checkpoint.

Checkpoint 2

Suppose that we wish to prepare a logical two-qubit GHZ state \((|00\rangle_{AB}+|11\rangle_{AB})/\sqrt{2}\) in the [[4,2,2]] code. To do so, we use the following state preparation circuit:

\[ (CNOT_{03}) (H_0) (CNOT_{21}) (H_2). \]

Note that this equation is written in matrix multiplication order, while the quantum operations in the circuit occur in the reverse order (from right-to-left in the above equation). \(H\) is a single-qubit Hadamard gate.

What is the logical state fidelity of the final 2-qubit logical state at the end of the circuit as a function of the two-qubit gate error rate \(p\), assuming the state is post-selected on all detectable errors in the code?

Assistant #4
Reasoning (model)

Logical Fidelity in the Presence of Post-selection

Okay, so I’ve confirmed my initial calculations for Subproblem 1 were correct. Now onto the meat of Subproblem 2: figuring out the logical fidelity when we’re post-selecting on detectable errors. The core concept is that we’re working with a logical GHZ state and need to understand how it’s affected by noise and error correction.

First, I identified the key ingredients: the logical state itself, how the noise model (depolarizing errors after each CNOT gate) interacts with the code space, and the idea of “error detection” via post-selection. I know that the ideal GHZ state lives in the code space because it’s stabilized by the code’s stabilizers. I re-traced the noisy circuit’s action, just as I did in the previous problem. This time, however, I’m focusing on the undetectable errors.

For an error to be undetectable, it must commute with the stabilizers – these errors effectively “hide” within the code. After carefully analyzing the Pauli operators, I’ve concluded that the undetectable errors, the ones that don’t flip syndromes, are also those that preserve the logical state (only potentially introducing a phase). I used a detailed calculation method of listing the 15 two-qubit Paulis, and determining the probability.

By understanding that post-selecting means we only keep states that don’t produce a detectable syndrome, I was able to show that the logical fidelity equals 1 for any reasonable depolarizing probability. This result made me confident and excited, as it made sense based on how the code detects and corrects errors. I had to double-check a couple calculations involving which Paulis commute with which operators and made the right determination. The analysis was based on the fact that any errors within this model that are undetectable, due to the structure of the code, don’t corrupt the logical information.

To calculate the logical state fidelity with post-selection, we need to determine two quantities:

  1. The probability of success (\(P_{success}\)), which is the probability that no detectable error occurs.
  2. The overlap of the successfully prepared (unnormalized) state with the ideal target logical state, \(\langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle\).

The logical fidelity is then given by \(F_{logical} = \frac{\langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle}{P_{success}}\).

1. Ideal Target Physical State and its Logical Interpretation

From Subproblem 1, the ideal final physical state is:

\[ |\psi_{ideal}\rangle = \frac{1}{2}(|0000\rangle+|1001\rangle+|0110\rangle+|1111\rangle) \]

This state is stabilized by \(S_1 = X_0 X_1 X_2 X_3\) and \(S_2 = Z_0 Z_1 Z_2 Z_3\), confirming it is in the code space. The logical GHZ state \((|00\rangle_{AB}+|11\rangle_{AB})/\sqrt{2}\) is characterized by being a +1 eigenstate of \(X_A X_B\) and \(Z_A Z_B\). Given the logical operators: \(X_A = XIXI\), \(X_B=XXII\), \(Z_A = ZZII\), \(Z_B = ZIZI\). We find \(X_A X_B = (X_0 I_1 X_2 I_3)(X_0 X_1 I_2 I_3) = I_0 X_1 X_2 I_3 = X_1 X_2\). And \(Z_A Z_B = (Z_0 Z_1 I_2 I_3)(Z_0 I_1 Z_2 I_3) = I_0 Z_1 Z_2 I_3 = Z_1 Z_2\). Let’s check if \(|\psi_{ideal}\rangle\) is a +1 eigenstate of these: \(X_1 X_2 |\psi_{ideal}\rangle = \frac{1}{2}(|0110\rangle+|1111\rangle+|0000\rangle+|1001\rangle) = |\psi_{ideal}\rangle\). \(Z_1 Z_2 |\psi_{ideal}\rangle = \frac{1}{2}(|0000\rangle+|1001\rangle+|0110\rangle+|1111\rangle) = |\psi_{ideal}\rangle\). So, \(|\psi_{ideal}\rangle\) correctly represents the logical GHZ state.

2. Error Model and Detectable Errors

Each \(CNOT_{ij}\) gate is followed by a two-qubit depolarizing channel \(\mathcal{D}_{ij}\) with error rate \(p\). This means with probability \((1-p)\) no error occurs, and with probability \(p\), one of the 15 non-identity two-qubit Pauli operators \(P_k^{(ij)}\) acts on qubits \(i,j\) with equal probability \(p/15\).

Post-selection on all detectable errors means we discard any state that is an eigenstate of a stabilizer \(S\) with eigenvalue -1. If an error \(E\) occurs, the state becomes \(E|\psi_{ideal}\rangle\). This state is deemed ‘undetected’ if it remains in the code space, i.e., \(S_1 (E|\psi_{ideal}\rangle) = E|\psi_{ideal}\rangle\) and \(S_2 (E|\psi_{ideal}\rangle) = E|\psi_{ideal}\rangle\). Since \(S_1|\psi_{ideal}\rangle = |\psi_{ideal}\rangle\) and \(S_2|\psi_{ideal}\rangle = |\psi_{ideal}\rangle\), this condition simplifies to requiring that \(E\) commutes with both \(S_1\) and \(S_2\).

Let’s identify the non-identity Paulis for a given pair of qubits \((i,j)\) that commute with both stabilizers \(S_1\) and \(S_2\). * Errors after \(CNOT_{21}\) (acting on qubits 1 and 2): \(P_k^{(21)} = I_0 \otimes P_{12} \otimes I_3\). We need \(P_{12}\) to commute with \(X_1 X_2\) (from \(S_1\)) and \(Z_1 Z_2\) (from \(S_2\)). The Pauli operators \(P_{12}\) on qubits 1 and 2 that commute with both \(X_1 X_2\) and \(Z_1 Z_2\) are \(\{X_1 X_2, Y_1 Y_2, Z_1 Z_2\}\). There are \(M=3\) such operators. * Errors after \(CNOT_{03}\) (acting on qubits 0 and 3): \(P_j^{(03)} = P_{03} \otimes I_1 I_2\). We need \(P_{03}\) to commute with \(X_0 X_3\) (from \(S_1\)) and \(Z_0 Z_3\) (from \(S_2\)). The Pauli operators \(P_{03}\) on qubits 0 and 3 that commute with both \(X_0 X_3\) and \(Z_0 Z_3\) are \(\{X_0 X_3, Y_0 Y_3, Z_0 Z_3\}\). There are \(M=3\) such operators.

Any other single error (from \(P_k^{(21)}\) or \(P_j^{(03)}\)) will anticommute with at least one stabilizer, causing the state to be detected and discarded.

3. Action of Undetected Errors on the Logical State

Let’s examine the effect of these \(M=3\) undetected errors on \(|\psi_{ideal}\rangle\): * For \(P_{12} \in \{X_1 X_2, Y_1 Y_2, Z_1 Z_2\}\): * \(X_1 X_2 |\psi_{ideal}\rangle = |\psi_{ideal}\rangle\) * \(Y_1 Y_2 |\psi_{ideal}\rangle = -|\psi_{ideal}\rangle\) * \(Z_1 Z_2 |\psi_{ideal}\rangle = |\psi_{ideal}\rangle\) * For \(P_{03} \in \{X_0 X_3, Y_0 Y_3, Z_0 Z_3\}\): * \(X_0 X_3 |\psi_{ideal}\rangle = |\psi_{ideal}\rangle\) * \(Y_0 Y_3 |\psi_{ideal}\rangle = -|\psi_{ideal}\rangle\) * \(Z_0 Z_3 |\psi_{ideal}\rangle = |\psi_{ideal}\rangle\)

In all these cases, an undetected error transforms \(|\psi_{ideal}\rangle\) into \(\pm |\psi_{ideal}\rangle\). This means the logical state is preserved, possibly with a global phase, which does not affect fidelity (since fidelity is typically \(|\langle \psi | \phi \rangle|^2\)).

4. Calculating \(P_{success}\) and \(\langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle\)

Let \(N_E = 15\) be the number of non-identity 2-qubit Paulis for the depolarizing channel.

The noisy evolution can be broken down into four scenarios: * No error occurs on either CNOT: Probability: \((1-p)^2\). State: \(|\psi_{ideal}\rangle\). Contribution to \(P_{success}\): \((1-p)^2 \times 1 = (1-p)^2\). Contribution to \(\langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle\): \((1-p)^2 \times |\langle\psi_{ideal}|I|\psi_{ideal}\rangle|^2 = (1-p)^2 \times 1 = (1-p)^2\).

  • Error \(P_k^{(21)}\) after \(CNOT_{21}\) only (no error after \(CNOT_{03}\)): Probability for each specific \(P_k^{(21)}\): \((p/N_E)(1-p)\). Only \(M=3\) operators \(P_k^{(21)}\) are undetected. Total probability for this scenario: \(M \cdot \frac{p(1-p)}{N_E} = 3 \cdot \frac{p(1-p)}{15} = \frac{p(1-p)}{5}\). For each such \(P_k^{(21)}\), the state is \(P_k^{(21)}|\psi_{ideal}\rangle = \pm |\psi_{ideal}\rangle\). Contribution to \(\langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle\): Sum of \((p/N_E)(1-p) \cdot |\langle\psi_{ideal}|P_k^{(21)}|\psi_{ideal}\rangle|^2\). This is \(\frac{p(1-p)}{15} \sum_{k \in \{X_1X_2, Y_1Y_2, Z_1Z_2\}} |\langle\psi_{ideal}|P_k^{(21)}|\psi_{ideal}\rangle|^2 = \frac{p(1-p)}{15} (1^2 + (-1)^2 + 1^2) = \frac{p(1-p)}{15} \cdot 3 = \frac{p(1-p)}{5}\).

  • Error \(P_j^{(03)}\) after \(CNOT_{03}\) only (no error after \(CNOT_{21}\)): Probability for each specific \(P_j^{(03)}\): \((1-p)(p/N_E)\). Only \(M=3\) operators \(P_j^{(03)}\) are undetected. Total probability for this scenario: \(M \cdot \frac{(1-p)p}{N_E} = 3 \cdot \frac{p(1-p)}{15} = \frac{p(1-p)}{5}\). For each such \(P_j^{(03)}\), the state is \(P_j^{(03)}|\psi_{ideal}\rangle = \pm |\psi_{ideal}\rangle\). Contribution to \(\langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle\): \(\frac{p(1-p)}{15} \sum_{j \in \{X_0X_3, Y_0Y_3, Z_0Z_3\}} |\langle\psi_{ideal}|P_j^{(03)}|\psi_{ideal}\rangle|^2 = \frac{p(1-p)}{15} (1^2 + (-1)^2 + 1^2) = \frac{p(1-p)}{15} \cdot 3 = \frac{p(1-p)}{5}\).

  • Errors \(P_k^{(21)}\) and \(P_j^{(03)}\) both occur: Probability for each specific pair: \((p/N_E)^2\). Only \(M \times M = 9\) pairs result in undetected errors. Total probability for this scenario: \(M^2 \cdot (p/N_E)^2 = 9 \cdot (p/15)^2 = \frac{9p^2}{225} = \frac{p^2}{25}\). For each such pair, the state is \(P_j^{(03)} P_k^{(21)}|\psi_{ideal}\rangle\). Since \(P_j^{(03)}\) and \(P_k^{(21)}\) act on disjoint qubits, they commute. Since each individual error results in \(\pm |\psi_{ideal}\rangle\), their product also results in \(\pm |\psi_{ideal}\rangle\). Contribution to \(\langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle\): \(\sum_{j,k} (p/N_E)^2 |\langle\psi_{ideal}|P_j^{(03)} P_k^{(21)}|\psi_{ideal}\rangle|^2\). This is \(\frac{p^2}{15^2} \sum_{j,k} |\langle\psi_{ideal}|P_j^{(03)}|\psi_{ideal}\rangle|^2 |\langle\psi_{ideal}|P_k^{(21)}|\psi_{ideal}\rangle|^2 = \frac{p^2}{225} (3 \times 3) = \frac{9p^2}{225} = \frac{p^2}{25}\).

Summing up the contributions:

\[ P_{success} = (1-p)^2 + \frac{p(1-p)}{5} + \frac{p(1-p)}{5} + \frac{p^2}{25} \]
\[ P_{success} = (1-2p+p^2) + \frac{2p-2p^2}{5} + \frac{p^2}{25} \]
\[ P_{success} = 1 - 2p + p^2 + \frac{2}{5}p - \frac{2}{5}p^2 + \frac{1}{25}p^2 \]
\[ P_{success} = 1 + \left(-2 + \frac{2}{5}\right)p + \left(1 - \frac{2}{5} + \frac{1}{25}\right)p^2 \]
\[ P_{success} = 1 - \frac{8}{5}p + \frac{16}{25}p^2 = \left(1 - \frac{4}{5}p\right)^2 \]

The value of \(\langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle\) is found to be exactly the same:

\[ \langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle = (1-p)^2 + \frac{p(1-p)}{5} + \frac{p(1-p)}{5} + \frac{p^2}{25} = \left(1 - \frac{4}{5}p\right)^2 \]

Finally, the logical state fidelity is:

\[ F_{logical} = \frac{\langle\psi_{ideal}|\rho_{post}|\psi_{ideal}\rangle}{P_{success}} = \frac{\left(1 - \frac{4}{5}p\right)^2}{\left(1 - \frac{4}{5}p\right)^2} \]

For any \(p < 5/4\) (which is always true since \(p \in [0,1]\) for a probability), this ratio is 1.

The final answer is \(\boxed{1}\).

User #5

Populate your final answer into the code template provided below. This step is purely for formatting/display purposes. No additional reasoning or derivation should be performed. Do not import any modules or packages beyond what is provided in the template.

import sympy as sp

p = sp.symbols('p')

def answer(p):
    r"""
    Return the expression of logical state fidelity of the final 2-qubit logical state
    at the end of the circuit as a function of the two-qubit gate error rate $p$ in Sympy format.

    Inputs
    ----------
    p: sympy.Symbol, the two-qubit gate error rate, $p$

    Outputs
    ----------
    F_logical: sympy.Expr, the logical state fidelity as a function of $p$
    """

    # ------------------ FILL IN YOUR RESULTS BELOW ------------------
    F_logical = ...  # a SymPy expression of inputs
    # ---------------------------------------------------------------

    return F_logical
Assistant #6
import sympy as sp

p = sp.symbols('p')

def answer(p):
    r"""
    Return the expression of logical state fidelity of the final 2-qubit logical state
    at the end of the circuit as a function of the two-qubit gate error rate $p$ in Sympy format.

    Inputs
    ----------
    p: sympy.Symbol, the two-qubit gate error rate, $p$

    Outputs
    ----------
    F_logical: sympy.Expr, the logical state fidelity as a function of $p$
    """

    # ------------------ FILL IN YOUR RESULTS BELOW ------------------
    F_logical = sp.Integer(1)
    # ---------------------------------------------------------------

    return F_logical