qiskit_qec.codes.all_small_codes¶
- all_small_codes(n=None, k=None, index=None, info_only=False, list_only=False, **kwargs)[source]¶
Returns all small codes.
- Parameters:
n (Union[int,List[int],None], optional) – _description_. Defaults to None.
k (Union[int,List[int],None], optional) – _description_. Defaults to None.
index (Union[int,List[int],None], optional) – _description_. Defaults to None.
info_only (bool, optional) – _description_. Defaults to False.
list_only (optional) – If True then a list will always be returned. Defaults to False
**kwargs – desc
- Returns:
codes or properties matches query
- Return type:
Union[Code, List[Code], Properties, List[Properties]]
Example
>>> all_small_codes(4) [<qiskit_qec.codes.stabsubsystemcodes.StabSubSystemCode at 0x13e304f40>, <qiskit_qec.codes.stabsubsystemcodes.StabSubSystemCode at 0x13e30a490>, <qiskit_qec.codes.stabsubsystemcodes.StabSubSystemCode at 0x13e30a880>, <qiskit_qec.codes.stabsubsystemcodes.StabSubSystemCode at 0x13e30aa60>]
>>> code = all_small_codes(4,is_css=False) >>> code.gauge_group.generators PauliList(['Z0X1Z2', 'Y0Y1X3', 'Z1X2Z3'])
>>> code_info = all_small_codes(4,is_css=False, info_only=True) >>> code_info.info [[4,1]]-8 StabSubSystemCode ------------------------------------------------------------------------------- isotropic_generators : ['Z0X1Z2', 'Y0Y1X3', 'Z1X2Z3'] logical_ops : ['Z2X3', 'Z0Z3'] is_subsystem : 1 index : 8 code_type : StabSubSystemCode aut_group_size : 24 is_decomposable : 0 weight_enumerator : [1, 0, 0, 4, 3] is_css : 0 uuid : e6e4edd6-2ec6-467f-9187-0cc64bc51f1a is_degenerate : 0 d : 2 is_gf4linear : 0 k : 1 n : 4
Note
This is the equivalent to the GAP method AllSmallGroups but for codes