Identity gate

The Identity gate is a single-qubit operation that leaves the basis states 0|0\rangle and 1|1\rangle unchanged. I=(1001)I = \begin{pmatrix} 1 & 0 \ 0 & 1 \end{pmatrix}

For simulations, this gate is useful in combination with the error_model instruction. Because it represents a specific action on a qubit (do nothing), the depolarizing error model will take this gate into account when distributing errors on the qubits. This can be used as a simple version of decoherence of the qubit.

Note that more sophisticated error models might be needed to model more accurately the effects of decoherence, leakage, etc.

Syntax:

        
          I q[0] # execute Identity gate on qubit 0