}
//for (int i = 0; i < qubitCountPow2; i++) printf("]%i -> %i: %f[\n", rsorting[i], sorting[i], psisquared_sorted[i]);
free(psisquared);
- for (int i = 0; i < qubitCountPow2; i++)
- {
- printf("]%f[\n", psisquared_sorted[i]);
- }
unsigned short *stats = malloc(sizeof(unsigned short) * qubitCountPow2);
for (int i = 0; i < qubitCountPow2; i++) stats[i] = 0;
for (int i = 0; i < (ctx->bsampling_shots); i++)
*chunk = malloc(QANSEL_QUANTIS_CHUNK_SIZE);
FILE* f = fopen("/dev/qrandom0", "r");
unsigned char c = fgetc(f);
- while (c == 0x00) c = fgetc(f) - 1;
- (*chunk)[0] = c;
+ while (c == 0x00) c = fgetc(f);
+ (*chunk)[0] = c & rand();
for (int i = 0; i < QANSEL_QUANTIS_CHUNK_SIZE - 1; i++)
{
- (*chunk)[i + 1] = fgetc(f) - 1;
+ (*chunk)[i + 1] = fgetc(f) & rand();
}
fclose(f);
}
\ No newline at end of file