NumPyEigensolver
class NumPyEigensolver(operator=None, k=1, aux_operators=None)
The NumPy Eigensolver algorithm.
NumPy Eigensolver computes up to the first eigenvalues of a complex-valued square matrix of dimension , with .
Operators are automatically converted to MatrixOperator
as needed and this conversion can be costly in terms of memory and performance as the operator size, mostly in terms of number of qubits it represents, gets larger.
Parameters
- operator (
Union
[OperatorBase
,LegacyBaseOperator
,None
]) – Operator instance. If None is supplied it must be provided later before run() is called. Allowing None here permits the algorithm to be configured and used later when operator is available, say creating an instance an letting application stack use this algorithm with an operator it creates. - k (
int
) – How many eigenvalues are to be computed, has a min. value of 1. - aux_operators (
Optional
[List
[Union
[OperatorBase
,LegacyBaseOperator
,None
]]]) – Auxiliary operators to be evaluated at each eigenvalue
Attributes
aux_operators
Type: Optional[List[Optional[qiskit.aqua.operators.operator_base.OperatorBase]]]
returns aux operators
Return type
Optional
[List
[Optional
[OperatorBase
]]]
k
Type: int
returns k (number of eigenvalues requested)
Return type
int
operator
Type: Optional[qiskit.aqua.operators.operator_base.OperatorBase]
returns operator
Return type
Optional
[OperatorBase
]
random
Return a numpy random.
Methods
run
NumPyEigensolver.run()
Execute the classical algorithm.
Returns
results of an algorithm.
Return type
dict
supports_aux_operators
NumPyEigensolver.supports_aux_operators()
If will process auxiliary operators or not
Return type
bool