Is it possible to define an associative binary operation $*$ on $\mathbb{Z}$ such that $x*x*y=y*x*x=y$ for $x,y \in \mathbb{Z}$ ?
Asked
Active
Viewed 48 times
2
-
@Peter Um, what? $2\times 2\times 3\not=3$ . . . – Noah Schweber Oct 05 '16 at 18:47
-
I overlooked the "=y" at the end. – Peter Oct 05 '16 at 18:48
1 Answers
4
Bitwise xor has this property. It's commutative, too, and extends to the reals.
-
1@ Mnemonic , can you please prove this rigorously . I need a formal proof that bitwise xor indeed works . :) – learner_008 Oct 05 '16 at 18:58
-
2
-
1It's defined bitwise, so you can consider each bit separately. Then there are only four cases to check. – Oct 05 '16 at 19:09