|
1 | 1 | program example_matmul
|
2 | 2 | use stdlib_intrinsics, only: stdlib_matmul
|
3 | 3 | complex :: x(2, 2), y(2, 2), z(2, 2)
|
4 |
| - x = reshape([(0, 0), (1, 0), (1, 0), (0, 0)], [2, 2]) |
| 4 | + |
| 5 | + x = reshape([(0, 0), (1, 0), (1, 0), (0, 0)], [2, 2]) ! pauli x-matrix |
5 | 6 | y = reshape([(0, 0), (0, 1), (0, -1), (0, 0)], [2, 2]) ! pauli y-matrix
|
6 |
| - z = reshape([(1, 0), (0, 0), (0, 0), (-1, 0)], [2, 2]) |
| 7 | + z = reshape([(1, 0), (0, 0), (0, 0), (-1, 0)], [2, 2]) ! pauli z-matrix |
7 | 8 |
|
8 | 9 | print *, stdlib_matmul(x, y) ! should be iota*z
|
9 | 10 | print *, stdlib_matmul(y, z, x) ! should be iota*identity
|
|
0 commit comments