cirq.CliffordState

class cirq.CliffordState(qubit_map, initial_state=0)[source]

A state of the Clifford simulation.

The state is stored using two complementary representations:
Anderson’s tableaux form and Bravyi’s CH-form.
The tableaux keeps track of the stabilizer operations, while the
CH-form allows access to the full wavefunction (including phase).

Gates and measurements are applied to each representation in O(n^2) time.

__init__(qubit_map, initial_state=0)[source]

Initialize self. See help(type(self)) for accurate signature.

Methods

apply_single_qubit_unitary(op)

apply_unitary(op)

copy()

destabilizers()

Returns the destabilizer generators of the state. These

perform_measurement(qubits, prng[, …])

stabilizers()

Returns the stabilizer generators of the state. These

to_numpy()

wave_function()