How can I make a 4x4 switch out of 2x2 switches?
First we optionally swap adjacent pairs, then staggered pairs, then adjacent pairs again.

For example, the rotation ABCD -> DABC is achieved through the three stages like this:


Swap both pairs: BADC
Swap B and D: DABC
No-op.


are switches, they let us swap the inner pair and outer pair.