MatrixExpectation

class MatrixExpectation[source]

An Expectation converter which converts Operator measurements to be matrix-based so they can be evaluated by matrix multiplication.

Methods

MatrixExpectation.compute_variance(exp_op)

Compute the variance of the expectation estimator.

MatrixExpectation.convert(operator)

Accept an Operator and return a new Operator with the Pauli measurements replaced by Matrix based measurements.