PauliSumOp¶
- class PauliSumOp(primitive, coeff=1.0, grouping_type='None')[소스]¶
기반 클래스:
PrimitiveOp
Class for Operators backed by Terra’s
SparsePauliOp
class.- 매개변수
primitive (
SparsePauliOp
) – The SparsePauliOp which defines the behavior of the underlying function.coeff (
Union
[complex
,ParameterExpression
]) – A coefficient multiplying the primitive.grouping_type (
str
) – The type of grouping. If None, the operator is not grouped.
- 예외 발생
TypeError – invalid parameters.
Methods Defined Here
Return Operator addition of self and other, overloaded by
+
.Return a new Operator equal to the Operator's adjoint (conjugate transpose), overloaded by
~
.Return Operator Composition between self and other (linear algebra-style: A@B(x) = A(B(x))), overloaded by
@
.Evaluate Equality between Operators, overloaded by
==
.Evaluate the Operator's underlying function, either on a binary string or another Operator.
Return a
CircuitOp
equivalent to e^-iH for this operator H.Construct from a pauli_list with the form [(pauli_str, coeffs)]
Return True if the operator is hermitian.
Return this operator is zero operator or not.
Return a matrix representation iterator.
Returns the scalar multiplication of the Operator, overloaded by
*
, including support for Terra'sParameters
, which can be bound to values later (viabind_parameters
).Permutes the sequence of
PauliSumOp
.Return a set of strings describing the primitives contained in the Operator.
Simplify the primitive
SparsePauliOp
.Return tensor product between self and other, overloaded by
^
.Returns an
Instruction
equivalent to this Operator.Return NumPy representation of the Operator.
Returns a sum of
PauliOp
s equivalent to this Operator.Returns SciPy sparse matrix representation of the
PauliSumOp
.Attributes
- INDENTATION = ' '¶
- coeff¶
The scalar coefficient multiplying the Operator.
- 반환 형식
Union
[complex
,ParameterExpression
]- 반환
The coefficient.
- coeffs¶
Return the Pauli coefficients.
- grouping_type¶
Type of Grouping
- Type
Returns
- 반환 형식
str
- instance_id¶
Return the unique instance id.
- 반환 형식
int
- num_qubits¶
- 반환 형식
int
- parameters¶
- primitive: SparsePauliOp¶
The primitive defining the underlying function of the Operator.
- 반환 형식
Union
[QuantumCircuit
,Operator
,Pauli
,SparsePauliOp
,OperatorBase
]- 반환
The primitive object.
- settings¶
Return operator settings.
- 반환 형식
Dict