I have, as promised, found a better form for XOR:
As I sit here chomping on a chicken wing, I can’t help but feel a touch of disappointment alongside the inevitable satisfaction at completing my mission. The previous solution – XOR(x.y) = (1-xy)(x + y) – was, I feel, more elegabt; the fact we were dealing with x/y symmetry, and that x and y could take only the values 1 and 0, seemed to almost leap out.
Talking of symmetry – I’ve just realised that I didn’t cover x => y, the only asymmetric elemental* logical operator.
So here, deduced by trial and error is the formula:
I lied though. Because, of course, => is not as elemental as one would hope, so:
x => y <–> NOT (x AND NOT(y)) = NOT(x AND (1-y)) = NOT(x(1-y)) = 1-(x-xy) = xy +1 -x
Thus demonstrating the usefulness of being able to represent logical operators analytically.