Skip to main content

lifted_product_binary_checks

Function lifted_product_binary_checks 

Source
pub fn lifted_product_binary_checks(
    group: &FiniteGroupSpec,
    left: &[Vec<GroupAlgebraElement>],
    right: &[Vec<GroupAlgebraElement>],
) -> Result<LiftedProductBinaryChecks>
Expand description

Build binary CSS checks using commuting left/right regular actions.

Ring-level rows are ordered as the Kronecker constructors emit them: for A kron I_q, rows are (a_row, q_index) and columns are (a_col, q_index) with the left index major; for I_p kron B, rows are (p_index, b_row) and columns are (p_index, b_col). The binary lift then expands every ring column into a contiguous |G| basis block.

For support element g and basis row x, the left action places a 1 at g^-1 x, while the right action places a 1 at x g. The binary CSS check order is:

  • H_X = [left_lift(A kron I), right_lift(I kron B^T)]
  • H_Z = [right_lift(I kron inverse_entries(B)), left_lift(inverse_transpose(A) kron I)]

This fixes the left qubit block before the right qubit block and makes the extra involutions explicit for callers comparing ring and binary outputs.