1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 |
| #include <quantum.h> | #include <stdlib.h> | int main(int argc, char *argv[]) | { | quantum_reg reg0 = quantum_new_qureg(1, 16); | quantum_reg regt = quantum_new_qureg(3, 32); | quantum_reg tmp1 = quantum_new_qureg(5, 48); | quantum_reg tmp2 = quantum_new_qureg(7, 64); | quantum_matrix H = quantum_new_matrix(9, 10); | float* w [] = { | (float*) malloc(sizeof(float)*256), | (float*) malloc(sizeof(float)*256), | (float*) malloc(sizeof(float)*256), | (float*) malloc(sizeof(float)*256), | 0}; | quantum_diag_time( | 1.5f, | ®0, | ®t, | &tmp1, | &tmp2, | H, | w); //target call | return 0; | } |
|