![]() |
The Quantum Exact Simulation Toolkit v4.3.0
|
Functions for applying general many-qubit diagonal matrices, as DiagMatr. More...
Functions | |
| void | applyControlledDiagMatr (Qureg qureg, int control, int *targets, int numTargets, DiagMatr matrix) |
| void | applyControlledDiagMatrPower (Qureg qureg, int control, int *targets, int numTargets, DiagMatr matrix, qcomp exponent) |
| void | applyDiagMatr (Qureg qureg, int *targets, int numTargets, DiagMatr matrix) |
| void | applyDiagMatrPower (Qureg qureg, int *targets, int numTargets, DiagMatr matrix, qcomp exponent) |
| void | applyMultiControlledDiagMatr (Qureg qureg, int *controls, int numControls, int *targets, int numTargets, DiagMatr matrix) |
| void | applyMultiControlledDiagMatrPower (Qureg qureg, int *controls, int numControls, int *targets, int numTargets, DiagMatr matrix, qcomp exponent) |
| void | applyMultiStateControlledDiagMatr (Qureg qureg, int *controls, int *states, int numControls, int *targets, int numTargets, DiagMatr matrix) |
| void | applyMultiStateControlledDiagMatrPower (Qureg qureg, int *controls, int *states, int numControls, int *targets, int numTargets, DiagMatr matrix, qcomp exponent) |
Functions for applying general many-qubit diagonal matrices, as DiagMatr.
| void applyControlledDiagMatr | ( | Qureg | qureg, |
| int | control, | ||
| int * | targets, | ||
| int | numTargets, | ||
| DiagMatr | matrix ) |
Applies a singly-controlled arbitrarily-sized diagonal unitary matrix upon the targets of qureg.
- See applyDiagMatr() for information about the base operation,
targetsandmatrix.
- See applyControlledCompMatr1() for information about the
controlqubit.
Definition at line 303 of file operations.cpp.
Referenced by applyControlledDiagMatr().
| void applyControlledDiagMatrPower | ( | Qureg | qureg, |
| int | control, | ||
| int * | targets, | ||
| int | numTargets, | ||
| DiagMatr | matrix, | ||
| qcomp | exponent ) |
Applies a singly-controlled arbitrarily-sized diagonal unitary matrix, raised to the power exponent, upon the targets of qureg.
- See applyDiagMatr() for information about
targetsandmatrix.
- See applyDiagMatrPower() for information about
exponent.- See applyControlledCompMatr1() for information about the
controlqubit.
Definition at line 366 of file operations.cpp.
Referenced by applyControlledDiagMatrPower().
Applies an arbitrarily-sized diagonal unitary matrix upon the targets of qureg.
qureg, use applyFullStateDiagMatr().targets are specified in increasing order.Definition at line 298 of file operations.cpp.
Referenced by applyDiagMatr().
| void applyDiagMatrPower | ( | Qureg | qureg, |
| int * | targets, | ||
| int | numTargets, | ||
| DiagMatr | matrix, | ||
| qcomp | exponent ) |
Applies an arbitrarily-sized diagonal unitary matrix, raised to the power exponent, upon the targets of qureg.
qureg, use applyFullStateDiagMatrPower().targets are specified in increasing order.This function is equivalent to applyDiagMatr() except that matrix is raised to the given exponent.
Definition at line 352 of file operations.cpp.
Referenced by applyDiagMatrPower().
| void applyMultiControlledDiagMatr | ( | Qureg | qureg, |
| int * | controls, | ||
| int | numControls, | ||
| int * | targets, | ||
| int | numTargets, | ||
| DiagMatr | matrix ) |
Applies a multiply-controlled arbitrarily-sized diagonal unitary matrix upon the targets of qureg.
- See applyDiagMatr() for information about
targetsandmatrix.
- See applyMultiControlledCompMatr1() for information about
controls.
Definition at line 308 of file operations.cpp.
Referenced by applyMultiControlledDiagMatr().
| void applyMultiControlledDiagMatrPower | ( | Qureg | qureg, |
| int * | controls, | ||
| int | numControls, | ||
| int * | targets, | ||
| int | numTargets, | ||
| DiagMatr | matrix, | ||
| qcomp | exponent ) |
Applies a multiply-controlled arbitrarily-sized diagonal unitary matrix, raised to the power exponent, upon the targets of qureg.
- See applyDiagMatr() for information about
targetsandmatrix.
- See applyDiagMatrPower() for information about
exponent.- See applyMultiControlledCompMatr1() for information about
controls.
Definition at line 380 of file operations.cpp.
Referenced by applyMultiControlledDiagMatrPower().
| void applyMultiStateControlledDiagMatr | ( | Qureg | qureg, |
| int * | controls, | ||
| int * | states, | ||
| int | numControls, | ||
| int * | targets, | ||
| int | numTargets, | ||
| DiagMatr | matrix ) |
Applies an arbitrarily-controlled arbitrarily-sized diagonal unitary matrix upon the targets of qureg, conditioned upon the controls being in the corresponding states.
- See applyDiagMatr() for information about
targetsandmatrix.
- See applyMultiStateControlledCompMatr1() for information about
controlsandstates.
Definition at line 313 of file operations.cpp.
Referenced by applyMultiStateControlledDiagMatr().
| void applyMultiStateControlledDiagMatrPower | ( | Qureg | qureg, |
| int * | controls, | ||
| int * | states, | ||
| int | numControls, | ||
| int * | targets, | ||
| int | numTargets, | ||
| DiagMatr | matrix, | ||
| qcomp | exponent ) |
Applies an arbitrarily-controlled arbitrarily-sized diagonal unitary matrix, raised to the power exponent, upon the targets of qureg, conditioned upon the controls being in the corresponding states.
- See applyDiagMatr() for information about
targetsandmatrix.
- See applyDiagMatrPower() for information about
exponent.- See applyMultiStateControlledCompMatr1() for information about
controlsandstates.
Definition at line 394 of file operations.cpp.
Referenced by applyControlledDiagMatrPower(), applyDiagMatrPower(), applyMultiControlledDiagMatrPower(), and applyMultiStateControlledDiagMatrPower().