Is there a good way to mathematically write a CNOT operation over non-neighboring qubits in a circuit?
How to derive the CNOT matrix for a 3-qubit system where the control & target qubits are not adjacent?