qsim:: unitary:: UnitaryCalculatorBasic

#include <unitary_calculator_basic.h>

Quantum circuit unitary calculator without vectorization.

Summary

Constructors and Destructors

UnitaryCalculatorBasic (ForArgs &&... args)

Public types

State using
Unitary
StateSpace using
Unitary using
typename UnitarySpace::Unitary
UnitarySpace using
fp_type using
typename UnitarySpace::fp_type

Public functions

ApplyControlledGate (const std::vector< unsigned > & qs, const std::vector< unsigned > & cqs, uint64_t cmask, const fp_type *matrix, Unitary & state) const
void
Applies a controlled gate using non-vectorized instructions.
ApplyGate (const std::vector< unsigned > & qs, const fp_type *matrix, Unitary & state) const
void
Applies a gate using non-vectorized instructions.

Public static functions

SIMDRegisterSize ()
unsigned

Public types

State

Unitary State

StateSpace

UnitarySpace StateSpace

Unitary

typename UnitarySpace::Unitary Unitary

UnitarySpace

UnitarySpaceBasic< For, FP > UnitarySpace

fp_type

typename UnitarySpace::fp_type fp_type

Public functions

ApplyControlledGate

void ApplyControlledGate(
  const std::vector< unsigned > & qs,
  const std::vector< unsigned > & cqs,
  uint64_t cmask,
  const fp_type *matrix,
  Unitary & state
) const 

Applies a controlled gate using non-vectorized instructions.

Details
Parameters
qs
Indices of the qubits affected by this gate.
cqs
Indices of control qubits.
cmask
Bit mask of control qubit values.
matrix
Matrix representation of the gate to be applied.
state
The state of the system, to be updated by this method.

ApplyGate

void ApplyGate(
  const std::vector< unsigned > & qs,
  const fp_type *matrix,
  Unitary & state
) const 

Applies a gate using non-vectorized instructions.

Details
Parameters
qs
Indices of the qubits affected by this gate.
matrix
Matrix representation of the gate to be applied.
state
The state of the system, to be updated by this method.

UnitaryCalculatorBasic

 UnitaryCalculatorBasic(
  ForArgs &&... args
)

Public static functions

SIMDRegisterSize

unsigned SIMDRegisterSize()

Details
Returns
The size of SIMD register if applicable.