"Exercise 5.1" sigmax = ((0,1),(1,0)) sigmay = ((0,-i),(i,0)) sigmaz = ((1,0),(0,-1)) I = ((1,0),(0,1)) a = (L12 + L21) / 2 b = i (L12 - L21) / 2 c = (L11 - L22) / 2 d = (L11 + L22) / 2 L = a sigmax + b sigmay + c sigmaz + d I L "Verify L" check(L == ((L11,L12),(L21,L22))) L12 = x + i y L21 = conj(L12) a = real(L12) b = -imag(L12) c = (L11 - L22) / 2 d = (L11 + L22) / 2 check(L == a sigmax + b sigmay + c sigmaz + d I) "ok"
Run