Skip to main contentIBM Quantum Documentation
This page is from an old version of Qiskit SDK and does not exist in the latest version. We recommend you migrate to the latest version. See the release notes for more information.

qiskit.aqua.components.uncertainty_problems.MultivariateProblem

class MultivariateProblem(uncertainty_model, aggregation_function, univariate_objective, conditions=None)

GitHub

Multivariate Uncertainty Problem.

Constructor.

Parameters

  • uncertainty_model (MultivariateDistribution) – multivariate uncertainty model
  • aggregation_function (CircuitFactory) – aggregation function that maps the multiple dimension to an aggregated value
  • univariate_objective (UnivariatePiecewiseLinearObjective) – objective function applied to the aggregated value
  • conditions (Union[List[Tuple[int, CircuitFactory]], ndarray, None]) – list of pairs (int, CircuitFactory) = target dimension of uncertainty model and condition to be satisfied to apply the aggregation

__init__

__init__(uncertainty_model, aggregation_function, univariate_objective, conditions=None)

Constructor.

Parameters

  • uncertainty_model (MultivariateDistribution) – multivariate uncertainty model
  • aggregation_function (CircuitFactory) – aggregation function that maps the multiple dimension to an aggregated value
  • univariate_objective (UnivariatePiecewiseLinearObjective) – objective function applied to the aggregated value
  • conditions (Union[List[Tuple[int, CircuitFactory]], ndarray, None]) – list of pairs (int, CircuitFactory) = target dimension of uncertainty model and condition to be satisfied to apply the aggregation

Methods

__init__(uncertainty_model, …[, conditions])Constructor.
build(qc, q[, q_ancillas, params])Adds corresponding sub-circuit to given circuit
build_controlled(qc, q, q_control[, …])Adds corresponding controlled sub-circuit to given circuit
build_controlled_inverse(qc, q, q_control[, …])Adds controlled inverse of corresponding sub-circuit to given circuit
build_controlled_inverse_power(qc, q, …[, …])Adds controlled, inverse, power of corresponding circuit.
build_controlled_power(qc, q, q_control, power)Adds controlled power of corresponding circuit.
build_inverse(qc, q[, q_ancillas])Adds inverse of corresponding sub-circuit to given circuit
build_inverse_power(qc, q, power[, q_ancillas])Adds inverse power of corresponding circuit.
build_power(qc, q, power[, q_ancillas])Adds power of corresponding circuit.
get_num_qubits()returns number of qubits
get_num_qubits_controlled()returns number of qubits controlled
required_ancillas()returns required ancillas
required_ancillas_controlled()returns required ancillas controlled
value_to_estimation(value)value to estimate

Attributes

num_target_qubitsReturns the number of target qubits

build

build(qc, q, q_ancillas=None, params=None)

Adds corresponding sub-circuit to given circuit

Parameters

  • qc (QuantumCircuit) – quantum circuit
  • q (list) – list of qubits (has to be same length as self._num_qubits)
  • q_ancillas (list) – list of ancilla qubits (or None if none needed)
  • params (list) – parameters for circuit

build_controlled

build_controlled(qc, q, q_control, q_ancillas=None, use_basis_gates=True)

Adds corresponding controlled sub-circuit to given circuit

Parameters

  • qc (QuantumCircuit) – quantum circuit
  • q (list) – list of qubits (has to be same length as self._num_qubits)
  • q_control (Qubit) – control qubit
  • q_ancillas (list) – list of ancilla qubits (or None if none needed)
  • use_basis_gates (bool) – use basis gates for expansion of controlled circuit

build_controlled_inverse

build_controlled_inverse(qc, q, q_control, q_ancillas=None, use_basis_gates=True)

Adds controlled inverse of corresponding sub-circuit to given circuit

Parameters

  • qc (QuantumCircuit) – quantum circuit
  • q (list) – list of qubits (has to be same length as self._num_qubits)
  • q_control (Qubit) – control qubit
  • q_ancillas (list) – list of ancilla qubits (or None if none needed)
  • use_basis_gates (bool) – use basis gates for expansion of controlled circuit

build_controlled_inverse_power

build_controlled_inverse_power(qc, q, q_control, power, q_ancillas=None, use_basis_gates=True)

Adds controlled, inverse, power of corresponding circuit. May be overridden if a more efficient implementation is possible

build_controlled_power

build_controlled_power(qc, q, q_control, power, q_ancillas=None, use_basis_gates=True)

Adds controlled power of corresponding circuit. May be overridden if a more efficient implementation is possible

build_inverse

build_inverse(qc, q, q_ancillas=None)

Adds inverse of corresponding sub-circuit to given circuit

Parameters

  • qc (QuantumCircuit) – quantum circuit
  • q (list) – list of qubits (has to be same length as self._num_qubits)
  • q_ancillas (list) – list of ancilla qubits (or None if none needed)

build_inverse_power

build_inverse_power(qc, q, power, q_ancillas=None)

Adds inverse power of corresponding circuit. May be overridden if a more efficient implementation is possible

build_power

build_power(qc, q, power, q_ancillas=None)

Adds power of corresponding circuit. May be overridden if a more efficient implementation is possible

get_num_qubits

get_num_qubits()

returns number of qubits

get_num_qubits_controlled

get_num_qubits_controlled()

returns number of qubits controlled

num_target_qubits

Returns the number of target qubits

required_ancillas

required_ancillas()

returns required ancillas

required_ancillas_controlled

required_ancillas_controlled()

returns required ancillas controlled

value_to_estimation

value_to_estimation(value)

value to estimate

Was this page helpful?
Report a bug or request content on GitHub.