mindquantum.core.gates.NoiseGate

View Source On Gitee
class mindquantum.core.gates.NoiseGate(name, n_qubits, obj_qubits=None, ctrl_qubits=None)[source]

Noise gate class.

Parameters
  • name (str) – the name of this gate.

  • n_qubits (int) – how many qubits is this gate.

  • obj_qubits (int, list[int]) – Specific which qubits the gate act on.

  • ctrl_qubits (int, list[int]) – Specific the control qubits. Default, None.

on(obj_qubits, ctrl_qubits=None)[source]

Define which qubit the gate act on.

Parameters
  • obj_qubits (int, list[int]) – Specific which qubits the gate act on.

  • ctrl_qubits (int, list[int]) – Control qubit for noise gate should always be None.