tqec.circuit.operations.measurement.RepeatedMeasurement

class RepeatedMeasurement(qubit: GridQubit, offsets: Interval)[source]

A unique representation for a repeated measurement in a quantum circuit.

This class aims at being able to represent a repeated measurement in a quantum circuit in a unique and easily usable way. Repeated measurements can be found when a stim.CircuitRepeatBlock contains measurements.

Note

This is not a global representation as the offsets is always relative to the end of the quantum circuit considered.

qubit

qubit on which the represented repeated measurement is performed.

Type:

cirq.devices.grid_qubit.GridQubit

offsets

an interval only containing negative offsets representing the number of measurements performed on the provided qubit after the represented measurement. A value of -1 means that the represented measurement is the last one applied on qubit.

Type:

tqec.templates.interval.Interval

Raises:

TQECException – if the provided offsetd contains positive entries.

__init__(qubit: GridQubit, offsets: Interval) None

Methods

__init__(qubit, offsets)

measurements()

offset_spatially_by(x, y)

offset_temporally_by(t)

Attributes

qubit

offsets