This project is archived
Qiskit Finance is no longer maintained and this documentation is no longer updated. It is kept online for reference only, and the code it describes may not work with current versions of Qiskit. See the project repository for more information.
FixedIncomePricing#
- class FixedIncomePricing(num_qubits, pca_matrix, initial_interests, cash_flow, rescaling_factor, bounds, uncertainty_model)[source]#
Bases:
EstimationApplicationAn estimation application for the fixed income pricing problem. evaluate the expected value of the total value \(V\) of the assets
\[V = \sum_{t=1}^T \frac{c_t}{(1+r_t)^t}.\]- [1]: Woerner, S., & Egger, D. J. (2018).
Quantum Risk Analysis. arXiv:1806.06893
- Parameters:
num_qubits (List[int]) – A list specifying the number of qubits used to discretize the assets.
pca_matrix (ndarray) – The PCA matrix for the changes in the interest rates, \(\delta_r\).
initial_interests (List[int]) – The initial interest rates / offsets for the interest rates.
rescaling_factor (float) – The scaling factor used in the Taylor approximation.
bounds (List[Tuple[float, float]]) – The list of the tuple of the bounds, (min, max), for return values the assets can attain.
attain. (The bounds for return values the assets can) –
uncertainty_model (QuantumCircuit) – A circuit for encoding a problem distribution
Methods
- interpret(result)[source]#
Convert the calculation result of the problem (
qiskit_algorithms.AmplitudeEstimatorResult) to the answer of the problem.- Parameters:
result (AmplitudeEstimatorResult) – The calculated result of the problem
- Returns:
The estimation value after the post_processing.
- Return type:
- to_estimation_problem()[source]#
Convert a problem instance into a
qiskit_algorithms.EstimationProblem- Returns:
The
qiskit_algorithms.EstimationProblemcreated from the Fixed problem instance.- Return type: