()
| 1461 | |
| 1462 | |
| 1463 | def test_u3_ctrl(): |
| 1464 | |
| 1465 | kernel = cudaq.make_kernel() |
| 1466 | qubits = kernel.qalloc(2) |
| 1467 | kernel.u3(np.pi / 2, 0., np.pi, qubits[0]) |
| 1468 | kernel.cu3(np.pi, np.pi, np.pi / 2, qubits[0], qubits[1]) |
| 1469 | |
| 1470 | counts = cudaq.sample(kernel) |
| 1471 | assert (len(counts) == 2) |
| 1472 | assert ('00' in counts) |
| 1473 | assert ('11' in counts) |
| 1474 | |
| 1475 | |
| 1476 | @skipIfNvidiaFP64NotInstalled |