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

Function getRandomPhase

tests/utils/random.cpp:82–87  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

80
81
82qreal getRandomPhase() {
83
84 // accuracy of PI does not matter here
85 qreal pi = 3.14159265358979323846;
86 return getRandomReal(-2*pi, 2*pi);
87}
88
89
90int getRandomInt(int min, int maxExcl) {

Callers 2

getRandomUnitComplexFunction · 0.85
getRandomRemainingArgsFunction · 0.85

Calls 1

getRandomRealFunction · 0.70

Tested by

no test coverage detected