[Math] Binary operation commutative, associative, and distributive over multiplication

binary operationselementary-number-theory

Is there any binary operation that is commutative, associative, and distributive over multiplication?

I asked this question in my head a while ago, and I posted it in various forums. However, having not found an answer, it has once again sparked my interest. I'm not looking for any trivial functions, and any base set would work for me ($\Bbb{Z}$, $\Bbb{Q}$, or $\Bbb{R}$), so long as it contains the integers.

*EDIT* OK, the operation doesn't have to be commutative, but it does have to be both left and right distributive over multiplication. (Does both left and right distributivity imply commutativity?)

*EDIT 2* I'm looking for a binary function that maps two integers to another integer, or two positive integers to another positive integer. I only realized this after the first answer was posted, so I apologize.

Best Answer

The nicest way to do this if we restrict our attention to positive integers is to take something similar to Zander's answer... but work with prime powers. It should be able to be extended to positive rationals, if you're careful.

It works like this: if you have two integers of the form $$ a = \prod_{i=1}^n p_i^{k_i} $$ and $$ b = \prod_{i=1}^n p_i^{m_i} $$ where $n$ is simply the index of the highest prime present in the pair of integers (that is, it's an arbitrary number for representing the primes in question), then we define our operation as $$ a\circ b = \prod_{i=1}^n p_i^{k_i\times m_i} $$ With this operation, we have commutativity (obvious). We have associativity: $$ (a\circ b)\circ c = a\circ (b\circ c) = \prod_{i=1}^n p_i^{k_i\times m_i\times l_i} $$ We have distributivity: $$ a\circ (b\times c) = \prod_{i=1}^n p_i^{k_i\times (m_i+l_i)} = \prod_{i=1}^n p_i^{k_i\times m_i}\times \prod_{i=1}^n p_i^{k_i\times l_i} $$ (and similarly for the right-distributivity).

Interestingly, this operation maps any pair of coprime integers to one, and more generally the result of this operation on any pair of integers will produce an integer having only prime factors present in both the original integers. Some specific examples...

$$ p^m \circ p^n = p^{mn}\\ 100\circ 750 = 62500\\ 224\circ 147 = 49 $$

Related Question