qiskit-documentation/docs/api/qiskit/0.29/qiskit.optimization.applica...

25 lines
1.2 KiB
Plaintext
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
title: stable_set (v0.29)
description: API reference for qiskit.optimization.applications.ising.stable_set in qiskit v0.29
in_page_toc_min_heading_level: 2
python_api_type: module
python_api_name: qiskit.optimization.applications.ising.stable_set
---
<span id="module-qiskit.optimization.applications.ising.stable_set" />
<span id="qiskit-optimization-applications-ising-stable-set" />
# qiskit.optimization.applications.ising.stable\_set
Convert stable set instances into Pauli list. We read instances in the Gset format, see [https://web.stanford.edu/\~yyye/yyye/Gset/](https://web.stanford.edu/~yyye/yyye/Gset/) , for compatibility with the maxcut format, but the weights on the edges as they are not really used and are always assumed to be 1. The graph is represented by an adjacency matrix.
**Functions**
| | |
| ------------------------ | ----------------------------------------------------------- |
| `get_graph_solution`(x) | Get graph solution from binary string. |
| `get_operator`(w) | Generate Hamiltonian for the maximum stable set in a graph. |
| `stable_set_value`(x, w) | Compute the value of a stable set, and its feasibility. |