|
Sequential Quantum Gate Decomposer
v1.9.6
Powerful decomposition of general unitarias into one- and two-qubit gates gates
|
A class to create general random unitary matrices according to arXiv:1303.5904v1. More...
#include <Random_Unitary.h>

Public Member Functions | |
| Matrix | Construct_Unitary_Matrix () |
| Construct a random unitary with internally generated float64 parameters. More... | |
| Matrix | Construct_Unitary_Matrix (double *vartheta, double *varphi, double *varkappa) |
| Construct a float64 unitary from explicit parameter arrays (arXiv:1303.5904v1). More... | |
| Matrix_float | Construct_Unitary_Matrix (float *vartheta, float *varphi, float *varkappa) |
| Construct a float32 unitary from explicit parameter arrays (native float32, no precision conversion). More... | |
| Matrix | Construct_Unitary_Matrix (double *parameters) |
| Construct a float64 unitary from a packed parameter array of (dim+1)*(dim-1) elements (vartheta | varphi | varkappa contiguous). More... | |
| void | print (const std::stringstream &sstream, int verbose_level=1) const |
| Call to print output messages in the function of the verbosity level. More... | |
| Random_Unitary (int dim_in) | |
| Constructor. More... | |
| void | set_debugfile (std::string debugfile) |
| Call to set the debugfile name. More... | |
| void | set_verbose (int verbose_in) |
| Call to set the verbose attribute. More... | |
Public Attributes | |
| bool | debug |
| Logical variable. Set true to write output messages to the 'debug.txt' file. More... | |
| std::string | debugfile_name |
| String variable. Set the debug file name. More... | |
| int | dim |
| The number of rows in the created unitary. More... | |
| int | verbose |
| Set the verbosity level of the output messages. More... | |
A class to create general random unitary matrices according to arXiv:1303.5904v1.
Internal helpers (Omega, M, Q, E_alpha_beta, I_alpha_beta, gamma, kronecker, convert_indexes) are implementation details and live in an anonymous namespace in the .cpp; they are not part of the public API.
Definition at line 57 of file Random_Unitary.h.
| Random_Unitary::Random_Unitary | ( | int | dim_in | ) |
Constructor.
Constructor of the class.
| dim_in | The number of rows in the random unitary to be created. |
| dim_in | The number of rows in the random unitary to be created. |
Definition at line 315 of file Random_Unitary.cpp.
| Matrix Random_Unitary::Construct_Unitary_Matrix | ( | ) |
Construct a random unitary with internally generated float64 parameters.
Definition at line 332 of file Random_Unitary.cpp.


| Matrix Random_Unitary::Construct_Unitary_Matrix | ( | double * | vartheta, |
| double * | varphi, | ||
| double * | varkappa | ||
| ) |
Construct a float64 unitary from explicit parameter arrays (arXiv:1303.5904v1).
Construct a float64 unitary from explicit parameter arrays.
| vartheta | array of dim*(dim-1)/2 elements |
| varphi | array of dim*(dim-1)/2 elements |
| varkappa | array of dim-1 elements |
Definition at line 364 of file Random_Unitary.cpp.
| Matrix_float Random_Unitary::Construct_Unitary_Matrix | ( | float * | vartheta, |
| float * | varphi, | ||
| float * | varkappa | ||
| ) |
Construct a float32 unitary from explicit parameter arrays (native float32, no precision conversion).
| vartheta | array of dim*(dim-1)/2 elements |
| varphi | array of dim*(dim-1)/2 elements |
| varkappa | array of dim-1 elements |
Definition at line 378 of file Random_Unitary.cpp.
| Matrix Random_Unitary::Construct_Unitary_Matrix | ( | double * | parameters | ) |
Construct a float64 unitary from a packed parameter array of (dim+1)*(dim-1) elements (vartheta | varphi | varkappa contiguous).
Construct a float64 unitary from a packed parameter array.
| parameters | array of (dim+1)*(dim-1) elements |
| parameters | array of (dim+1)*(dim-1) elements (vartheta | varphi | varkappa contiguous) |
Definition at line 389 of file Random_Unitary.cpp.
|
inherited |
Call to print output messages in the function of the verbosity level.
| sstream | The stringstream input to store the output messages. |
| verbose_level | Integer input. High level means write more to the standart output, 0 means write nothing. The default value is set to 1. |
Definition at line 55 of file logging.cpp.
|
inherited |
Call to set the debugfile name.
| debugfile | String variable. Set the debugfile name. |
Definition at line 95 of file logging.cpp.

|
inherited |
Call to set the verbose attribute.
| verbose_in | Integer variable. Set the number to specify the verbosity level for output messages. |
Definition at line 85 of file logging.cpp.

|
inherited |
|
inherited |
| int Random_Unitary::dim |
The number of rows in the created unitary.
Definition at line 61 of file Random_Unitary.h.
|
inherited |
1.8.13