ngnrsaa / qflex

Flexible Quantum Circuit Simulator (qFlex) implements an efficient tensor network, CPU-based simulator of large quantum circuits.
Apache License 2.0
97 stars 24 forks source link

Allow lone qubits, but log a warning. #274

Closed 95-martin-orion closed 4 years ago

95-martin-orion commented 4 years ago

Fixes #273.

With this change, qubits that have no interactions with other qubits can be included in a circuit and will affect the final amplitude correctly. A warning message will be logged, since this often suggests an error in input file formatting (simulating a single disconnected qubit isn't particularly useful).