The free group construction is a way of endowing any set with a group structure. Intuitively we can think of the endowment as being the “least restrictive possible while still forming a valid group”.
Let A be a set. To construct the free group over A, we first construct the set of ‘group words’ over A as
w(A)=(A×Z)∗/∼
Here (A×Z)∗ is the set of finite sequences over A×Z. The relation ∼ is given by
⟨ … (x,e1) (x,e2) … ⟩⟨ … (x,0) … ⟩∼⟨ … (x,(e1+e2)) … ⟩∼⟨ … … ⟩
For instance, over A={1,2,3} we have ⟨(1,2) (2,0) (1,−4)⟩∼⟨(1,−2)⟩. (The idea behind w(A) is to think of a word ⟨(x1,e1) (x2,e2) … (xn,en)⟩ as representing the “group element” x1e1⋅x2e2⋯xnen but where we don’t yet know what group we’re working in.)
Over w(A) we define a ‘concatenation’ operation by lifting the concatenation operation on (A×Z)∗ through ∼; ie, we define [w1]⊕[w2]=[w1⊕w2].
Now we construct the free group over A as Free(A)=(w(A),⊕).
The free group functor F:Set→Grp is a functor that endows any given set with a group structure.
On objects the functor maps a set A to its induced free group Free(A). For a morphism f:A→B the functor produces a morphism given as follows
F(f):Free(A)[ ⟨(x1,e1) … (xn,en)⟩ ]∼A→Free(B)↦[ ⟨(f(x1),e1) … (f(xn),en)⟩ ]∼B