Uncertainty Problems (qiskit.aqua.components.uncertainty_problems
)¶
Uncertainty is present in most realistic applications, and often it is necessary to evaluate the behavior of a system under uncertain data. For instance, in finance, it is of interest to evaluate expected value or risk metrics of financial products that depend on underlying stock prices, economic factors, or changing interest rates. Classically, such problems are often evaluated using Monte Carlo simulation. However, Monte Carlo simulation does not converge very fast, which implies that large numbers of samples are required to achieve estimators of reasonable accuracy and confidence. In quantum computing, amplitude estimation can be used instead, which can lead to a quadratic speed-up. Thus, millions of classical samples could be replaced by a few thousand quantum samples.
Amplitude estimation is a derivative of quantum phase estimation applied to a particular
operator \(A\). \(A\) is assumed to operate on (n+1) qubits (+ possible ancillas) where
the n qubits represent the uncertainty (see uncertainty_models
) and
the last qubit is used to represent the (normalized) objective value as its amplitude.
In other words, \(A\) is constructed such that the probability of measuring a ‘1’ in the
objective qubit is equal to the value of interest.
Aqua has several amplitude estimation algorithms:
AmplitudeEstimation
,
IterativeAmplitudeEstimation
and
MaximumLikelihoodAmplitudeEstimation
.
Since the value of interest has to be normalized to lie in [0, 1], an uncertainty problem also provides a function:
def value_to_estimator(self, value):
return value
which is used to map the result of amplitude estimation to the range of interest. The standard implementation is just the identity and can be overridden when needed.
Uncertainty Problem Base Classes¶
UncertaintyProblem
is the base class from which further
base classes for univariate and multivariate problems are
derived
The abstract Uncertainty Problem component. |
|
Univariate uncertainty problem. |
|
Multivariate Uncertainty Problem. |
Univariate Problems¶
Univariate Piecewise Linear Objective Function. |