Qiskit Algorithms (qiskit_algorithms
)#
Qiskit Algorithms is a library of quantum algorithms for quantum computing with Qiskit. These algorithms can be used to carry out research and investigate how to solve problems in different domains on simulators and near-term real quantum devices using shallow circuits.
The library includes some algorithms, for example the NumPyMinimumEigensolver
, which take
the same input as their quantum counterpart but solve the problem classically. This has utility in
the near-term, where problems are still tractable classically, to validate and/or act as a reference.
There are also classical optimizers
for use with variational algorithms such as VQE
.
This package also provides common building blocks for algorithms, such quantum circuit
gradients (gradients
) and fidelities of quantum states (state_fidelities
).
These elements are frequently used in a variety of applications, such as variational optimization,
time evolution and quantum machine learning.
The quantum algorithms here all use
Primitives
to execute quantum circuits. This can be an
Estimator
, which computes expectation values, or a Sampler
which computes
probability distributions. Refer to the specific algorithm for more information in this regard.
Algorithms#
The algorithms now presented are grouped by logical function, such
as minimum eigensolvers, amplitude amplifiers, time evolvers etc. Within each group, the
algorithms conform to an interface that allows them to be used interchangeably
by different applications. E.g. a Qiskit Nature application may take a minimum
eigensolver to solve a ground state problem, and require it to
conform to the MinimumEigensolver
interface. Any algorithm that conforms to
the interface, for example VQE
, can be used by this application.
Amplitude Amplifiers#
Algorithms based on amplitude amplification.
The amplification problem is the input to amplitude amplification algorithms, like Grover. |
|
The interface for amplification algorithms. |
|
Grover's Search algorithm. |
|
Grover Result. |
Amplitude Estimators#
Algorithms based on amplitude estimation.
The Amplitude Estimation interface. |
|
The results object for amplitude estimation algorithms. |
|
The Quantum Phase Estimation-based Amplitude Estimation algorithm. |
|
The |
|
The estimation problem is the input to amplitude estimation algorithm. |
|
The Faster Amplitude Estimation algorithm. |
|
The result object for the Faster Amplitude Estimation algorithm. |
|
The Iterative Amplitude Estimation algorithm. |
|
The |
|
The Maximum Likelihood Amplitude Estimation algorithm. |
|
The |
Eigensolvers#
Algorithms to find eigenvalues of an operator. For chemistry these can be used to find excited
states of a molecule, and qiskit-nature
has some algorithms that leverage chemistry specific
knowledge to do this in that application domain.
The eigensolver interface. |
|
Eigensolver result. |
|
The NumPy eigensolver algorithm. |
|
NumPy eigensolver result. |
|
The Variational Quantum Deflation algorithm. |
|
VQD Result. |
Gradients#
Algorithms to calculate the gradient of a quantum circuit.
Gradients (qiskit_algorithms.gradients) Algorithms to calculate the gradient of a quantum circuit. |
Minimum Eigensolvers#
Algorithms to find the minimum eigenvalue of an operator.
This set of these algorithms take an Estimator
primitive and can
solve for a general Hamiltonian.
The minimum eigensolver interface. |
|
Minimum eigensolver result. |
|
The NumPy minimum eigensolver algorithm. |
|
NumPy minimum eigensolver result. |
|
The Variational Quantum Eigensolver (VQE) algorithm. |
|
The Variational Quantum Eigensolver (VQE) result. |
|
The Adaptive Variational Quantum Eigensolver algorithm. |
|
AdaptVQE Result. |
This set of algorithms take a Sampler
primitive and can only
solve for a diagonal Hamiltonian, such as an Ising Hamiltonian of an optimization problem.
The Sampling Minimum Eigensolver Interface. |
|
Sampling Minimum Eigensolver Result. |
|
The Variational Quantum Eigensolver algorithm, optimized for diagonal Hamiltonians. |
|
The SamplingVQE Result. |
|
The Quantum Approximate Optimization Algorithm (QAOA). |
Optimizers#
Classical optimizers designed for use by quantum variational algorithms.
Optimizers (qiskit_algorithms.optimizers) Classical Optimizers. |
Phase Estimators#
Algorithms that estimate the phases of eigenstates of a unitary.
Run the Quantum Phase Estimation algorithm to find the eigenvalues of a Hermitian operator. |
|
Store and manipulate results from running HamiltonianPhaseEstimation. |
|
Set and use a bound on eigenvalues of a Hermitian operator in order to ensure phases are in the desired range and to convert measured phases into eigenvectors. |
|
Run the Quantum Phase Estimation (QPE) algorithm. |
|
Store and manipulate results from running PhaseEstimation. |
|
Run the Iterative quantum phase estimation (QPE) algorithm. |
State Fidelities#
Algorithms that compute the fidelity of pairs of quantum states.
State Fidelities (qiskit_algorithms.state_fidelities) Algorithms that compute the fidelity of pairs of quantum states. |
Time Evolvers#
Algorithms to evolve quantum states in time. Both real and imaginary time evolution is possible with algorithms that support them. For machine learning, Quantum Imaginary Time Evolution might be used to train Quantum Boltzmann Machine Neural Networks for example.
Interface for Quantum Real Time Evolution. |
|
Interface for Quantum Imaginary Time Evolution. |
|
Class for holding time evolution result. |
|
Time evolution problem class. |
|
The projected Variational Quantum Dynamics (p-VQD) Algorithm. |
|
The result object for the p-VQD algorithm. |
|
Classical Evolver for imaginary time evolution. |
|
Classical Evolver for real time evolution. |
|
Quantum Real Time Evolution using Trotterization. |
|
Variational Quantum Imaginary Time Evolution algorithm. |
|
Variational Quantum Real Time Evolution algorithm. |
|
The result object for the variational quantum time evolution algorithms. |
Variational Quantum Time Evolution#
Classes used by variational quantum time evolution algorithms -
VarQITE
and VarQRTE
.
Time Evolvers, Variational (qiskit_algorithms.time_evolvers.variational) |
Miscellaneous#
Various classes used by qiskit-algorithms that are part of and exposed by the public API.
Exceptions#
For Algorithm specific errors. |
Utility classes#
Utility classes and function used by algorithms.
This class is introduced for typing purposes and provides no additional function beyond that inherited from its parents. |
Global properties for algorithms. |