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\).

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
  1. Step-by-Step Derivation
  • Ideal state prepared by the circuit:
  • Start from |0000⟩.
  • Apply H2 then CNOT21: this prepares a Bell state on qubits (2,1),
\[ |\Phi^+\rangle_{21} = \frac{|00\rangle_{21} + |11\rangle_{21}}{\sqrt{2}}. \]
  • Apply H0 then CNOT03: this prepares a Bell state on qubits (0,3),
\[ |\Phi^+\rangle_{03} = \frac{|00\rangle_{03} + |11\rangle_{03}}{\sqrt{2}}. \]
  • Hence the final ideal 4-qubit state is a product of Bell pairs:
\[ |\psi_{\text{ideal}}\rangle = |\Phi^+\rangle_{03} \otimes |\Phi^+\rangle_{21}. \]
  • Stabilizer of the ideal state:
  • For a Bell state |Φ+⟩ on a pair (a,b), the stabilizer is generated by {X_a X_b, Z_a Z_b}, and the full stabilizer group on that pair is
\[ \{I I,\; X X,\; Y Y,\; Z Z\}\quad\text{(up to global phase)}. \]
  • Therefore the full 4-qubit stabilizer factorizes as
\[ \mathcal{S} = \langle X_0 X_3, Z_0 Z_3 \rangle \otimes \langle X_1 X_2, Z_1 Z_2 \rangle. \]
  • Noise model and its action:
  • After each CNOT gate, a two-qubit depolarizing error acts on the same two qubits: with probability 1−p no error (I I), and with probability p a uniformly random non-identity two-qubit Pauli from the 15 possibilities is applied.
  • The error after CNOT21 acts on qubits (2,1) and commutes with the later gates (H0, CNOT03), which act only on (0,3). Thus it does not propagate. The error after CNOT03 acts on (0,3) at the very end.
  • Hence the final error is a tensor product
\[ E_{\text{tot}} = E_{03} \otimes E_{21}, \]
where E03 and E21 are independent two-qubit Pauli errors on (0,3) and (2,1), respectively.
  • Fidelity with a stabilizer state under a Pauli channel:
  • For a pure stabilizer state |ψ⟩ and a Pauli error E, we have ⟨ψ|E|ψ⟩ ∈ {0, ±1}. It equals ±1 iff E is in the stabilizer (up to phase), and 0 otherwise. Therefore, for a Pauli mixture,
\[ = \sum_E \Pr(E)\, |\langle \psi_{\text{ideal}} | E | \psi_{\text{ideal}} \rangle|^2 \]
  • Because the stabilizer factorizes and the errors on the two pairs are independent,
\[ F = \Pr(E_{03} \in \mathcal{S}_{03}) \cdot \Pr(E_{21} \in \mathcal{S}_{21}). \]
  • Single-pair success probability:
  • On a Bell pair, among the 15 non-identity two-qubit Paulis, exactly 3 are in the stabilizer: {X X, Y Y, Z Z}.
  • Thus, for one pair,
\[ = (1-p) + p \cdot \frac{3}{15} \]
  • Total fidelity:
  • Since the two pairs are independent,
\[ \]
  1. Mathematical Typesetting - All mathematics above is typeset in LaTeX.

  2. Conventions and Units - No units are involved; fidelity is dimensionless.

  3. Final Answer: F(p) = (1 - 4p/5)^2 = 1 - (8/5)p + (16/25)p^2.

User #3

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
  1. Step-by-Step Derivation
  • Ideal encoded state (noiseless):
  • As in Subproblem 1, the circuit prepares
\[ \]
  • The code stabilizers are \(S_X=XXXX\) and \(S_Z=ZZZZ\). The logical Bell-state stabilizers are
\[ X_A X_B = X_1 X_2,\qquad Z_A Z_B = Z_1 Z_2, \]
so the logical Bell label is read off from the Bell-state label on qubits 1–2 when the state lies in the code space.
  • Noise model and its reduction to Bell labels:
  • After each CNOT there is a two-qubit depolarizing error on the gate’s qubits. Thus the final error is
\[ E_{\text{tot}}=E_{03}\otimes E_{21}, \]
with $E_{03}$ and $E_{21}$ independent two-qubit Paulis, each equal to $II$ with probability $1-p$ and otherwise uniformly one of the 15 non-identity Paulis with probability $p/15$.
  • For a single Bell pair, applying a two-qubit Pauli maps \(|\Phi^+\rangle\) to exactly one of the four Bell states. The 16 two-qubit Paulis partition into four cosets (modulo the Bell stabilizer \(\{II,XX,YY,ZZ\}\)), each coset mapping \(|\Phi^+\rangle\) to a fixed Bell state. Hence for one pair:
\[ \]
  • Post-selection (detectable errors discarded):
  • Measuring \(S_X\) and \(S_Z\) and keeping only \(+1\) outcomes accepts an error \(E_{\text{tot}}\) iff it commutes with both stabilizers. Equivalently, in terms of the two Bell pairs, the measurement outcomes are the products of the \(X\!\otimes\!X\) and \(Z\!\otimes\!Z\) eigenvalues on pairs (0,3) and (2,1). Thus acceptance occurs iff both pairs end in the same Bell label:
\[ \text{accept} \iff L_{03}=L_{21}\in\{\Phi^+,\Phi^-,\Psi^+,\Psi^-\}. \]
  • Therefore the acceptance probability is
\[ P_{\text{acc}}=\sum_{L}\Pr(L_{03}=L)\Pr(L_{21}=L)=q^2+3r^2. \]
  • Logical state upon acceptance and logical fidelity:
  • Conditional on acceptance, the code state lies in the code space and has logical Bell label equal to the common pair label. Hence the logical Bell-state fidelity with the target \(|\Phi^+\rangle_{AB}\) is the conditional probability that the common label is \(\Phi^+\):
\[ F_L(p)=\Pr\big(L=\Phi^+\,\big|\,\text{accept}\big)=\frac{q^2}{q^2+3r^2}. \]
  • Substituting \(q=1-\frac{4p}{5}\) and \(r=\frac{4p}{15}\) gives
\[ \]
  • Small-\(p\) expansion (showing the error-detecting benefit):
\[ F_L(p)=1-\frac{16}{75}p^2+O(p^3), \]
i.e., the logical infidelity is quadratic in $p$ after post-selection.
  1. Mathematical Typesetting - All relevant expressions are provided in LaTeX.

  2. Conventions and Units - Fidelity is dimensionless; no units.

  3. Final Answer: \(F_L(p)=\dfrac{\left(1-\frac{4p}{5}\right)^2}{\left(1-\frac{4p}{5}\right)^2+3\left(\frac{4p}{15}\right)^2} =\dfrac{1-\frac{8}{5}p+\frac{16}{25}p^2}{1-\frac{8}{5}p+\frac{64}{75}p^2} =1-\dfrac{16}{75}p^2+O(p^3).\)

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 = ((1 - sp.Rational(4, 5)*p)**2) / (((1 - sp.Rational(4, 5)*p)**2) + 3*(sp.Rational(4, 15)*p)**2)
    # ---------------------------------------------------------------

    return F_logical