TPBGroupedWeightedPauliOperator.simplify¶
- TPBGroupedWeightedPauliOperator.simplify(copy=False)¶
Merge the paulis whose bases are identical and the pauli with zero coefficient would be removed.
Note
This behavior of this method is slightly changed, it will remove the paulis whose weights are zero.
- Parameters
copy (bool) – simplify on a copy or self
- Returns
the simplified operator
- Return type