Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/QuEST-Kit/QuEST
/ getRelDif
Function
getRelDif
tests/utils/compare.cpp:64–68 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
62
}
63
64
qreal getRelDif(qcomp a, qcomp b) {
65
66
qreal denom = std::min({std::abs(a), std::abs(b)});
67
return getAbsDif(a,b) / denom;
68
}
69
70
71
bool doScalarsAgree(qcomp a, qcomp b) {
Callers
4
doScalarsAgree
Function · 0.85
REPORT_AMP_AND_FAIL
Function · 0.85
REPORT_SCALAR_AND_FAIL
Function · 0.85
REPORT_ELEM_AND_FAIL
Function · 0.85
Calls
1
getAbsDif
Function · 0.85
Tested by
no test coverage detected