QubitUnitary

Module: pennylane

class QubitUnitary(U, wires)[source]

Apply an arbitrary fixed unitary matrix.

Details:

  • Number of wires: The operation can act on any number of wires.
  • Number of parameters: 1
  • Gradient recipe: None
Parameters:
  • U (array[complex]) – square unitary matrix
  • wires (Sequence[int] or int) – the wire(s) the operation acts on