pygsti.modelmembers.term.RankOneTerm#
- class RankOneTerm(rep, evotype)#
Bases:
objectAn operation, like a gate, that maps a density matrix to another density matrix but in a restricted way.
While a RankOneTerm doesn’t have to map pure states to pure states, its action can be written:
rho -> A*rho*B
Where A and B are unitary state operations. This means that if rho can be written rho = |psi1><psi2| then the action of a RankOneTerm preserves the separable nature or rho (which need not always be a valid density matrix since it can be just a portion of one).
A RankOneTerm anticipates its application to “separable” (as defined above) states, and can even be used to represent such a separable state or an analogous POVM effect. This occurs when the first element of pre_ops and post_ops is a preparation or POVM effect vector instead of a gate operation.
Note that operations are stored in composition (time) order rather than matrix order, and that adjoint operations are stored in post_ops so that they can be applied directly to the adjoint of the “bra” part of the state (which is a “ket” - a usual state).
Finally, a coefficient (usually a number or a
Polynomial) is held, representing the prefactor for this term as a part of a larger density matrix evolution.- Parameters:
rep (SVTermRep or SBTermRep) – The term representation object the acts as the core of this term.
Methods
__init__(rep, evotype)copy()Copies this term.
torep()Access to the underlying representation object.
- copy()#
Copies this term.
- Return type:
- torep()#
Access to the underlying representation object.