I'm looking for a function that will replicate logical operators. In particular consider the AND operator. Then I am looking for a function z = f(x,y) such that $$x,y,z \in \{0,1\}$$
f(0,0)=0 f(1,0)=0 f(0,1)=0 f(1,1)=1
More importantly I need to generalize over a space where Xi,Yi ∈ {0,1} and I need to do this for other sorts of operators too. (X XOR Y AND Z for example.)
So given a vector Xi and a vector Yi I need to be able to generate Zi w