| 1025 | } |
| 1026 | |
| 1027 | CompMatr1 util_getExpPauliX(qreal angle) { |
| 1028 | |
| 1029 | qreal x = util_getPhaseFromGateAngle(angle); |
| 1030 | qreal c = std::cos(x); |
| 1031 | qreal s = std::sin(x); |
| 1032 | |
| 1033 | return getCompMatr1({ |
| 1034 | {qcomp(c,0), qcomp(0,s)}, |
| 1035 | {qcomp(0,s), qcomp(c,0)} |
| 1036 | }); |
| 1037 | } |
| 1038 | |
| 1039 | CompMatr1 util_getExpPauliY(qreal angle) { |
| 1040 |
no test coverage detected