dwave_networkx.algorithms.elimination_ordering.pegasus_elimination_order

pegasus_elimination_order(n, coordinates=False)[source]

Provides a variable elimination order for the Pegasus graph.

The treewidth of a Pegasus graph P(n) is lower-bounded by 12n-11 and upper bounded by 12-4 [#bbrr]_ .

Simple pegasus variable elimination order rules:
  • eliminate vertical qubits, one column at a time
  • eliminate horizontal qubits in each column once their adjacent vertical

qubits have been eliminated

Parameters:
  • n (int) – The size parameter for the Pegasus lattice.
  • coordinates (bool, optional (default False)) – If True, the elimination order is given in terms of 4-term Pegasus coordinates, otherwise given in linear indices.
Returns: