28

I tried getting the answers in similar questions, everyone says that it's not necessary, but if $e$ is the identity element for any binary operation $*$, which is not associative and commutative, how can

$$a*e=a=e*a$$

when it is not commutative, i.e. $a*b \ne b*a$?

Even if we get a value by solving $a*e=a$. Will we get the same value by solving $e*a=a$ ? Please provide an example.

PM.
  • 5,409
Fullatron
  • 403

7 Answers7

85

Asserting that the operation $*$ is not commutative means that there are elements $a$ and $b$ such that $a*b\neq b*a$. It does not mean that $a*b\neq b*a$ for any two distinct elements $a$ and $b$. Therefore, an operation may well not be commutative and, even so, to have an identity element. There is no contradiction here.

For an example of a non-commutative and non-associative algebraic structure with an identity element, take, for instance, the octonions.

31

An operation is commutative if for any $a$ and $b$, we have $ab=ba$. Finding one pair $a,b$ such that $ab=ba$ doesn't prove the operation is commutative; this has to hold for every pair.

Consider the set $\{a,b,c\}$ whose binary operation $\cdot$ is given by the following: $$a\cdot a = a\,\,\,\,\,\,\,\,\,\,\, a\cdot b=b\,\,\,\,\,\,\,\,\,\,\,a\cdot c=c$$ $$b\cdot a = b\,\,\,\,\,\,\,\,\,\,\, b\cdot b=b\,\,\,\,\,\,\,\,\,\,\,b\cdot c=c$$ $$c\cdot a = c\,\,\,\,\,\,\,\,\,\,\, c\cdot b=b\,\,\,\,\,\,\,\,\,\,\,c\cdot c=a$$ This operation has $a$ as an identity element. However, it is not commutative (since $b\cdot c\neq c\cdot b$) and it is not associative (since $b\cdot(c\cdot c)=b\neq a =(b\cdot c)\cdot c$).

florence
  • 13,049
10

Actually, given any set $S$ and operation $*$ on it (so possibly neither associative nor commutative), we can simply extend this with a new symbol $\color{red}0$ (i.e., $\color{red}0\notin S$) and on the set $S':=S\cup\{\color{red}0\}$ define an operation $\color{red}*$ by $$x\color{red}*y:=\begin{cases}x&\text{if }y=\color{red}0\\ y&\text{if }x=\color{red}0\\x*y&\text{otherwise} \end{cases}$$ Then $\color{red}*$ is not associative/commutative if $*$ is not associative/commutative. But $\color{red}0$ is neutral.

  • Nice. Since all operators with identity can be viewed as arising from this process and because the probability that a randomly choses operator on a set with $n$ elements is either commutative or associative tends to $0$ as $n \rightarrow \infty$, you can show that most operators with identity are neither associative nor commutative. – John Coleman Jun 21 '17 at 13:21
  • @JohnColeman, not all operations admitting an identity arise in this way. For instance the group $\mathbb{Z}/(2)$ does not. If it did, we would have $1+1=1$, but instead $1+1=0$. – Joshua Tilley Jul 11 '22 at 22:32
8

It is possible. $*$ not being commutative means that $a*b\neq b*a$ for some $a,b$, not for all of them. So you may have $a*e=e*a=a$ without contradicting that $*$ is not commutative.

Evargalo
  • 2,652
  • 9
  • 11
8

Without looking for esoteric and/or ad hoc examples, there is one you are certainly familiar with. The identity matrix is the identity element for matrix multiplication, which is not commutative. We have $A\,I=I\,A=A $ while in general $A\,B \neq B\,A $.

Luca Citi
  • 1,879
  • 14
  • 14
  • This is nice, because although the OP mentioned nonassociativity, the only property invoked in her/his argument is noncommutativity. Therefore matrix addition is a good, familiar example. –  Jun 20 '17 at 21:45
  • @Ben Crowell, matrix multiplication, not addition. Addition is commutative. – aarbee May 07 '21 at 11:18
  • @Ben Crowell, Also, you work at Fullerton and the OP is Fullatron. What a coincidence! – aarbee May 07 '21 at 11:20
1

Isn't subtraction a binary function which has an identity ($x-0=x$) although it is not commutative ($5-0 > 0-5$) or associative ($5-(4-3) > (5-4)-3$)?

Chaim
  • 639
1

Can a binary operation have an identity element when it is not associative and commutative?

Yes. Any non-commutative loop is an example of such algebraic structure. I am surprised that, searching the word loop with Ctrl + F in this page just before answering, I found only one occurrence in the comment by Arthur.


(...) how can

$$a*e=a=e*a$$

when it is not commutative (...) ?

As in the accepted answer, the operation $*$ is by definition commutative on the set $A$, if and only if $$ a*b=b*a $$ for all $a,b\in A$.

No surprise if, in a given operation on a given set $A$, only some elements of $A$ commute with all the others: in a non-commutative binary operation with two-sided identity, the identity element commutes with all the others elements. Indeed, the definition of identity element $e$ for the binary operation $*$ on a set $A$ states: $$ a*e=a=e*a,\quad\forall\,a\in A. $$


Please provide an example.

Of course :) And, further, we can create without too much effort an example which is even less than a loop. The finite magma of order $4$ given by the Cayley table \begin{array}{c|cccc} * & 1 & 2 & 3 & 4\\ \hline 1 & \color{red}{1} & \color{red}{2} & \color{red}{3} & \color{red}{4}\\ 2 & \color{red}{2} & 4 & 3 & 3\\ 3 & \color{red}{3} & 3 & 4 & 2\\ 4 & \color{red}{4} & 1 & 1 & 1\\ \end{array} has the two-sided identity element $1$ while cancellation and division do not hold, it is not commutative since - e.g. - $2*4\ne 4*2$ and it is not even associative: $$ (2*3)*4=3*4=2\ne 4=2*2=2*(3*4). $$

MattAllegro
  • 3,434