State Overlap
PauliPropagation.filter! — Methodfilter!(psum::PauliSum, filterfunc::Function)Filter a PauliSum in-place by removing all Pauli strings that satisfy the filterfunc.
PauliPropagation.filter — Methodfilter(psum::PauliSum, filterfunc::Function)Return a filtered PauliSum by removing all Pauli strings that satisfy the filterfunc.
PauliPropagation.orthogonaltoplus — Methodorthogonaltoplus(pstr)Calculates the overlap of a Pauli string with the plus state |+><+|
PauliPropagation.orthogonaltozero — Methodoverlapwithzero(pstr)Calculates the overlap of a Pauli string with the zero state |0><0|
PauliPropagation.overlapbyorthogonality — Methodoverlapbyorthogonality(pstr::PauliString, orthogonalfunc::Function)Overlap an integer Pauli string with a state or operator via function that returns true if the Pauli string is orthogonal and hence has overlap 0. An example orthogonalfunc is containsXorY which returns true if the Pauli string contains an X or Y Pauli. If not orthogonal, then the overlap is 1. This is particularly useful for overlaps with stabilizer states.
PauliPropagation.overlapbyorthogonality — Methodoverlapbyorthogonality(pstr::PauliString, orthogonalfunc::Function)Overlap a PauliString with a state or operator via function that returns true if the PauliString is orthogonal and hence has overlap 0. An example orthogonalfunc is containsXorY which returns true if the PauliString contains an X or Y Pauli. If not orthogonal, then the overlap is the coefficient of the PauliString. This is particularly useful for overlaps with stabilizer states.
PauliPropagation.overlapbyorthogonality — Methodoverlapbyorthogonality(psum::PauliSum, orthogonalfunc::Function)Overlap a PauliSum with a state or operator via function that returns true if a Pauli string is orthogonal and hence doesn't contribute. An example orthogonalfunc is containsXorY which returns true if a Pauli string contains an X or Y Pauli. If not orthogonal, then a Pauli string contributes with its coefficient. This is particularly useful for overlaps with stabilizer states.
PauliPropagation.overlapwithcomputational — Methodoverlapwithcomputational(pstr::PauliString, onebitinds)Calculates the overlap of a Pauli string with the computational basis state which has one-bits at all specified onebitinds and zero-bits elsewhere. For example, overlapwithcomputational(pstr, [1,2,4]) returns the overlap with |1101000...> and will be either zero or plus/minus pstr.coeff.
PauliPropagation.overlapwithcomputational — Methodoverlapwithcomputational(psum::PauliSum, onebitinds)Calculates the overlap of a Pauli sum with the computational basis state which has one-bits at all specified indices and zero-bits elsewhere. For example, overlapwithcomputational(psum, [1,2,4]) returns the overlap with |1101000...>
PauliPropagation.overlapwithmaxmixed — Methodoverlapwithmaxmixed(psum::PauliSum)Calculates the overlap of a PauliSum with the maximally mixed state 1/2^n I.
PauliPropagation.overlapwithpaulisum — Methodoverlapwithpaulisum(psum1::PauliSum, psum2::PauliSum)Calculates the overlap between two PauliSums. Important: We assume 'normalized' Pauli strings, i.e. such that Tr[P^2] = 1 for any n-qubit Pauli string P. If one Pauli sum represents e.g. a normalized quantum state, the result will need to be scaled by 2^n.
PauliPropagation.overlapwithplus — Methodoverlapwithplus(psum)Calculates the overlap of a Pauli sum with the plus state |+><+|
PauliPropagation.overlapwithzero — Methodoverlapwithzero(psum)Calculates the overlap of a Pauli sum with the zero state |0><0|
PauliPropagation.plusfilter! — Methodzerofilter!(psum)Filter a Pauli sum in-place with only Pauli strings that are not orthogonal to the plus state |+><+|.
PauliPropagation.plusfilter — Methodplusfilter(psum)Return a filtered Pauli sum with only Pauli strings that are not orthogonal to the plus state |+><+|.
PauliPropagation.zerofilter! — Methodzerofilter!(psum)Filter a Pauli sum in-place with only Pauli strings that are not orthogonal to the zero state |0><0|.
PauliPropagation.zerofilter — Methodzerofilter(psum)Return a filtered Pauli sum with only Pauli strings that are not orthogonal to the zero state |0><0|.