0
$\begingroup$

I've been coding QECC with qiskit recently. As I'm not very skilled in programming I encountered a lot of questions.

Now I'm trying to generate the logical error rate against physical error rate graph using qiskit. If I understand correctly, a logical error is one that anticommutes with logical operators, e.g. for the 7-qubit Steane code, X^7 and Z^7.

When I checked out other people's codes, they generally apply Pauli errors to gates, and track the propagation, at the end of the QECC circuit they obtain a Pauli operator, then check if it commutes with logical X and Z.

But for Qiskit this cannot be done ... what I'm getting is a statevector instead of specific error operator. How do I obtain logical error rate in this case?

$\endgroup$

1 Answer 1

0
$\begingroup$

But for Qiskit this cannot be done ... what I'm getting is a statevector instead of specific error operator. How do I obtain logical error rate in this case?

When you measure the qubits, your state vector is projected onto a state. You can compare this state to the state of the logical codewords.

But this is annoying to do. It is much easier and faster to simulate QEC by tracking Pauli errors through a circuit. This is a nice introduction: https://arxiv.org/pdf/quant-ph/9807006.pdf.

$\endgroup$
4
  • $\begingroup$ Thanks a lot. Yes I gave up using qiskit for this task ... tracking the Pauli error instead, but in this case how do I obtain fidelity? I'm not very experienced in coding. I know conceptually we check if the Pauli error is in the stabilizer space for each run. In terms of coding, how do I efficiently achieve this? $\endgroup$
    – AndyLiuin
    Jan 13 at 16:55
  • $\begingroup$ You need to run the following steps many times: 1) Sample an error and check if it flips the logical observable. 2) Check which detectors the error violates and pass this into a decoder. 3) Compare the prediction of the decoder to the actual value of the logical observable. I'm using terminology from Stim. I think this is a good place to start: github.com/quantumlib/Stim/blob/main/doc/getting_started.ipynb $\endgroup$
    – Peter-Jan
    Jan 13 at 17:12
  • $\begingroup$ Sorry just one more naive question ... what do you mean by "actual value of the logical observable" ... I still don't quite get after reading the documentation $\endgroup$
    – AndyLiuin
    Jan 13 at 17:59
  • $\begingroup$ The logical observable is a deterministic logical measurement. What I mean with the actual value of the logical observable is whether the deterministic logical measurement has been flipped or not. $\endgroup$
    – Peter-Jan
    Jan 17 at 9:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.