pygsti.tools.symplectic.pauli_z_measurement

pygsti.tools.symplectic.pauli_z_measurement#

pauli_z_measurement(state_s, state_p, qubit_index)#

Computes the probabilities of 0/1 (+/-) outcomes from measuring a Pauli operator on a stabilizer state.

Parameters:
  • state_s (numpy array) – The matrix over the integers mod 2 representing the stabilizer state

  • state_p (numpy array) – The ‘phase vector’ over the integers mod 4 representing the stabilizer state

  • qubit_index (int) – The index of the qubit being measured

Returns:

  • p0, p1 (float) – Probabilities of 0 (+ eigenvalue) and 1 (- eigenvalue) outcomes.

  • state_s_0, state_s_1 (numpy array) – Matrix over the integers mod 2 representing the output stabilizer states.

  • state_p_0, state_p_1 (numpy array) – Phase vectors over the integers mod 4 representing the output stabilizer states.