MCPcopy Create free account
hub / github.com/QuEST-Kit/QuEST / main

Function main

examples/tutorials/min_example.c:11–29  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9#include "quest.h"
10
11int main(void) {
12
13 initQuESTEnv();
14 reportQuESTEnv();
15
16 Qureg qureg = createForcedQureg(20);
17 reportQuregParams(qureg);
18
19 initRandomPureState(qureg);
20 reportQureg(qureg);
21
22 qreal prob = calcTotalProb(qureg);
23 reportScalar("Total probability", prob);
24
25 destroyQureg(qureg);
26 finalizeQuESTEnv();
27
28 return 0;
29}

Callers

nothing calls this directly

Calls 10

initQuESTEnvFunction · 0.85
reportQuESTEnvFunction · 0.85
createForcedQuregFunction · 0.85
reportQuregParamsFunction · 0.85
initRandomPureStateFunction · 0.85
reportQuregFunction · 0.85
calcTotalProbFunction · 0.85
reportScalarFunction · 0.85
destroyQuregFunction · 0.85
finalizeQuESTEnvFunction · 0.85

Tested by

no test coverage detected