PauliPropagator
Classical simulator for qubit (Pauli) operators.
Accepts a PauliOperator and a Circuit of
qubit gates; see MonomialPropagator for the shared
surface. The cutoff is qubit Pauli weight -- the number of qubits a retained term touches --
so cutoff_type is fixed and read-only here.
Attributes
attributenum_qubitsintNumber of qubits the propagator acts on.
Functions
func__init__(self, initial_operator, initial_state, *, cutoff, schrodinger_cutoff=None, lower_atol=None, upper_atol=None, comm=None) -> NoneInitialize the qubit propagator.
paramselfparaminitial_operatorPauliOperatorInitial qubit operator; its num_qubits sizes the simulator.
paraminitial_statelist[int] | np.ndarrayComputational-basis reference (indices of qubits set to 1).
paramcutoffintMaximum Pauli weight retained during evolution. The fully-paired exception
described on MajoranaPropagator.__init__
still applies.
paramschrodinger_cutoffint | None= NoneNone (default) keeps the Heisenberg picture; an integer selects
the Schrodinger picture and bounds the Pauli weight of the evolved state, including
its initialization from initial_state. Choose it at least as large as cutoff
for comparable accuracy.
paramlower_atolNone | float= NoneMonomials with |coeff| \< lower_atol are discarded during evolution.
paramupper_atolNone | float= NoneMonomials with |coeff| > upper_atol are kept regardless of weight.
paramcommMPI.Comm | None= NoneOptional MPI communicator (must outlive the propagator).
Returns
Nonefuncevolved_operator(self, parameters=None, *, atol=1e-12) -> PauliOperatorReturn the evolved operator as a PauliOperator.
paramselfparamparametersParameterValues= Noneparamatolfloat= 1e-12Returns
monoprop.pauli.PauliOperatorThe evolved qubit operator (Heisenberg picture) or evolved state (Schrodinger picture).
funcupdate_initial_operator(self, new_operator) -> NoneReplace coefficients of the initial operator (existing terms only).
paramselfparamnew_operatorPauliOperator:class:~monoprop.pauli.PauliOperator whose terms replace
the matching initial-operator coefficients.
Returns
None