I'm wondering if I can "make up" an identity element, like so:

I can define an element I such that any element x + I is equal to x, i.e.: I can redefine my set as [the old set] union with {I}, and redefine my binary operation such that if one of the operands is I, then the result is the other operand. Then I will have an identity element.

For example, imagine the set of integers greater than 100 and addition; this forms a semigroup but has no identity. I can define a new element I (it doesn't have any "numerical value" but it doesn't need to). Then I say 100 + I = 100, 101 + I = 101, etc. Of course, I wouldn't be able to do multiplication or take the square root of I, but those operations aren't a part of my semigroup anyways.

  • $\begingroup$ Note that the fact this is true is part of the formalized math library that is Lean's mathlib. The result in question is with_zero.add_monoid, so named because the adjoined element "I" acts like a 0. $\endgroup$
    – Eric
    May 9 at 13:05
  • $\begingroup$ @Eric: Zero is different from identity element. $\endgroup$
    – spin
    May 9 at 13:57
  • $\begingroup$ If you're writing your semigroup operation as $+$ as this question does, then all I'm saying is it can be convenient to write your monoid identity as $0$. $\endgroup$
    – Eric
    May 9 at 14:15

2 Answers 2


Yes, this construction works, and is the standard way to embed a semigroup without identity into a monoid.

Given a semigroup $S$ without identity, let $u \not\in S$. Then you can define a binary operation on $S \cup \{u\}$ by extending the binary operation on $S$: define $ux = xu = x$ for all $x \in S \cup \{u\}$.

To show that this makes $S \cup \{u\}$ into a monoid with identity $u$, you just need to prove that the binary operation on $S \cup \{u\}$ is associative. That should be an easy exercise.

It might also be instructive to think about what happens if you do this construction in the case where $S$ already has an identity.


Yes, you can always do it!

Suppose $(S, .)$ is a semigroup (i.e., $.$ an associative binary operation). Then consider the set $S'=S\cup\{*\}$ together with the binary operation $.'$ satisfying

  • $a.'b=a.b$ for all $a, b\in S$
  • $a.'*=*.'a=a$ for all $a\in S$
  • $*.'*=*$

Now, it is an easy exercise to prove $(S', .')$ is a monoid, and the obvious inclusion mapping $\iota : (S, .)\to (S', .')$ with $\iota(a.b)=a.'b$ is a semigroup homomorphism.

Also, you can go a bit further and notice this semigroup homomorphism is universal in the sense that any semigroup homomorphism $\varphi: S\to M$ to a monoid $M$, there is a unique monoid homomorphism $\varphi': S'\to M$ such that $\varphi=\varphi'\iota.$ Pictorially,

enter image description here

The natural mathematical domain that discusses this type of construction is "category theory", but I will not go into details.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.