Skip to main content

find_stab

Decompose a ZX-graph into a sum of stabilizer components. This is the main entry point for stabilizer rank decomposition. It first removes U3 phases, then decomposes T gates via BSS decompositions, producing a sum of scalar graphs. Parameters:
  • graph (BaseGraph) — The ZX graph to decompose.
  • strategy (DecompositionStrategy) — Decomposition strategy. Must be one of “cat5”, “bss”, “cutting”.
Returns:
  • list[BaseGraph] — A list of scalar graphs whose sum equals the original graph.

find_stab_magic

Recursively decompose ZX-graphs into stabilizer components via magic-state removal.

find_stab_u3

Recursively decompose ZX-graphs by removing U3 phases.