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

Function leftapplyDiagMatr

quest/src/api/multiplication.cpp:206–215  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

204extern "C" {
205
206void leftapplyDiagMatr(Qureg qureg, int* targets, int numTargets, DiagMatr matrix) {
207 validate_quregFields(qureg, __func__);
208 validate_targets(qureg, targets, numTargets, __func__);
209 validate_matrixDimMatchesTargets(matrix, numTargets, __func__); // also validates fields and is-sync
210
211 bool conj = false;
212 qcomp exponent = 1;
213 auto qubits = util_getVector(targets, numTargets);
214 localiser_statevec_anyCtrlAnyTargDiagMatr(qureg, {}, {}, qubits, matrix, exponent, conj);
215}
216
217void rightapplyDiagMatr(Qureg qureg, int* targets, int numTargets, DiagMatr matrix) {
218 validate_quregFields(qureg, __func__);

Callers

nothing calls this directly

Calls 5

validate_quregFieldsFunction · 0.85
validate_targetsFunction · 0.85
util_getVectorFunction · 0.85

Tested by

no test coverage detected