surface_sim.layouts.unrot_surface_code_rectangle#

unrot_surface_code_rectangle(distance_x, distance_z, logical_qubit_label='L0', init_point=(0, 0), init_data_qubit_id=1, init_zanc_qubit_id=1, init_xanc_qubit_id=1, init_ind=0, init_logical_ind=0, interaction_order={'x_type': ['north', 'west', 'east', 'south'], 'z_type': ['north', 'east', 'west', 'south']})[source]#

Generates a rotated surface code layout.

Parameters:
distance_x

The logical X distance of the code.

distance_z

The logical Z distance of the code.

logical_qubit_label

Label for the logical qubit, by default "L0".

init_point

Coordinates for the bottom left (i.e. southest west) data qubit. By default (1, 1).

init_data_qubit_id

Index for the bottom left (i.e. southest west) data qubit. By default 1, so the label is "D1".

init_zanc_qubit_id

Index for the bottom left (i.e. southest west) Z-type ancilla qubit. By default 1, so the label is "Z1".

init_xanc_qubit_id

Index for the bottom left (i.e. southest west) X-type ancilla qubit. By default 1, so the label is "X1".

init_ind

Minimum index that is going to be associated to a qubit.

init_logical_ind

Minimum index that is going to be associated to a logical qubit.

interaction_order

Dictionary specifying the interaction order for the x_type and z_type stabilizers. The possible interaction directions are: "north", "west", "south", and "east".

Returns:
Layout

The layout of the code.