English
Languages
English
Shortcuts



to_ising

to_ising(quad_prog)[source]

Return the Ising Hamiltonian of this problem.

Variables are mapped to qubits in the same order, i.e., i-th variable is mapped to i-th qubit. See https://github.com/Qiskit/qiskit-terra/issues/1148 for details.

Returns

The qubit operator for the problem offset: The constant value in the Ising Hamiltonian.

Return type

qubit_op

Raises