Let be a path-connected open set, and fix a base point .
Consider the set of all closed curves in based at , i.e., continuous maps with . Call this set .
Define a relation on by:
This is an equivalence relation. The fundamental group of at is the quotient set
equipped with the binary operation induced by concatenation of loops:
where traverses then at double speed. This operation is well-defined on homotopy classes, associative, has identity the constant loop at , and inverses via reversal.
If is path-connected, is independent of (up to isomorphism) and denoted simply . A set is simply connected if and only if (the trivial group).