function U = dr11(x1,x0)

%dr=dressed cnot
%This function calculates
%the dressed cnot (-1)^{n_{x1}(1) n_{x0}(0)},
%that acts on two bits called 1 and 0.
%n_{x1} is the number operator for 3d real vector x1, 
%i.e., n_{x1} = (1 - sigma_{x1})/2. For example, n=(1-sigz)/2
%Note that (-1)^{n_{x1}(1) n_{x0}(0)} is a generalization 
%of CNOT = (-1)^{n_z(1) n_x(0)}.


sig_0 = sig(x0);
sig_1 = sig(x1);

U=1/2*(eye(4) + kron(sig_1,eye(2)) + kron(eye(2),sig_0) - kron(sig_1,sig_0));

 