# Why does phase flip correction error? Why could any error be written as a linear combination of I, X, Z and ZX matrices?

I don't understand how it's being proven that error correction can be applied only to X, Z noises and this solves all errors?

Does this have to be with this set being universal? (Z is exactly like phase matrix or rotation matrix.)

Bonus question: When recovering a state in Shors code does it matter if I apply X, Z or Z, X?

• Any 2x2 matrix can be written as a linear combination of I,X,Z and ZX. Moreover, those 4 matrices form an orthogonal basis in matrix space of 2x2 matrices under Hilbert–Schmidt inner product. – Danylo Y Mar 9 at 8:33

2. You can still get upper bounds on how bad more flexible real quantum errors will be. An accidental 5 degree rotation around the Z axis of a qubit is no worse than a $$\sin^2(5^\circ)$$ chance of a Z error on that qubit.