50 lines
1.6 KiB
Plaintext
50 lines
1.6 KiB
Plaintext
---
|
||
title: NumPyLSsolver
|
||
description: API reference for qiskit.aqua.algorithms.NumPyLSsolver
|
||
in_page_toc_min_heading_level: 1
|
||
python_api_type: class
|
||
python_api_name: qiskit.aqua.algorithms.NumPyLSsolver
|
||
---
|
||
|
||
# NumPyLSsolver
|
||
|
||
<Class id="qiskit.aqua.algorithms.NumPyLSsolver" isDedicatedPage={true} github="https://github.com/qiskit-community/qiskit-aqua/tree/stable/0.9/qiskit/aqua/algorithms/linear_solvers/numpy_ls_solver.py" signature="NumPyLSsolver(matrix, vector)" modifiers="class">
|
||
Bases: `qiskit.aqua.algorithms.classical_algorithm.ClassicalAlgorithm`
|
||
|
||
The Numpy LinearSystem algorithm (classical).
|
||
|
||
This linear system solver computes the eigenvalues of a complex-valued square matrix $A$ of dimension $n \times n$ and the solution to the systems of linear equations defined by $A\overrightarrow{x}=\overrightarrow{b}$ with input vector $\overrightarrow{b}$.
|
||
|
||
This is a classical counterpart to the [`HHL`](qiskit.aqua.algorithms.HHL "qiskit.aqua.algorithms.HHL") algorithm.
|
||
|
||
**Parameters**
|
||
|
||
* **matrix** (`Union`\[`List`\[`List`\[`float`]], `ndarray`]) – The input matrix of linear system of equations
|
||
* **vector** (`Union`\[`List`\[`float`], `ndarray`]) – The input vector of linear system of equations
|
||
|
||
## Methods
|
||
|
||
### run
|
||
|
||
<Function id="qiskit.aqua.algorithms.NumPyLSsolver.run" signature="NumPyLSsolver.run()">
|
||
Execute the classical algorithm.
|
||
|
||
**Returns**
|
||
|
||
results of an algorithm.
|
||
|
||
**Return type**
|
||
|
||
dict
|
||
</Function>
|
||
|
||
## Attributes
|
||
|
||
### random
|
||
|
||
<Attribute id="qiskit.aqua.algorithms.NumPyLSsolver.random">
|
||
Return a numpy random.
|
||
</Attribute>
|
||
</Class>
|
||
|