Std.Diagnostics
The Std.Diagnostics namespace contains the following functions and operations:
Name | Description |
---|---|
CheckAllZero | Checks whether all qubits in the provided array are in the $|0⟩$ state. Returns true if they are. |
CheckOperationsAreEqual | Given two operations, checks that they act identically for all input states. |
CheckZero | Checks whether a qubit is in the $|0⟩$ state, returning true if it is. |
DumpMachine | Dumps the current target machine's status. |
DumpOperation | Given an operation, dumps the matrix representation of the operation action on the given number of qubits. |
DumpRegister | Dumps the current target machine's status associated with the given qubits. |
Fact | Checks whether a given condition is true, failing with a message if it is not. |
StartCountingFunction | Starts counting the number of times the given function is called. Fails if the function is already being counted. |
StartCountingOperation | Starts counting the number of times the given operation is called. Fails if the operation is already being counted. |
StartCountingQubits | Starts counting the number of qubits allocated. Fails if qubits are already being counted. |
StopCountingFunction | Stops counting the number of times the given function is called and returns the count. Fails if the function was not being counted. |
StopCountingOperation | Stops counting the number of times the given operation is called and returns the count. Fails if the operation was not being counted. |
StopCountingQubits | Stops counting the number of qubits allocated and returns the count. Fails if the qubits were not being counted. |