Function Pennylane::LightningKokkos::Util::wires2Parity

Function Documentation

inline auto Pennylane::LightningKokkos::Util::wires2Parity(const std::size_t num_qubits, const std::vector<std::size_t> &wires) -> std::pair<KokkosIntVector, KokkosIntVector>

Compute the parities and shifts for multi-qubit operations.

Parameters
  • num_qubits – Number of qubits in the state vector.

  • wires – List of target wires.

Returns

std::pair<KokkosIntVector, KokkosIntVector> Parities and shifts for multi-qubit operations.