For example, a subgroup of a group *G* is a subset *S* of *G* such that:

- the identity
*e*of*G*belongs to*S*(so that*S*is closed under the identity constant operation); - whenever
*x*belongs to*S*, so does*x*^{-1}(so that*S*is closed under the inverse operation); - whenever
*x*and*y*belong to*S*, so does*x***y*(so that*S*is closed under the group's multiplication operation).

The term **subalgebra** is also used in the context of specific types of algebras such as associative algebras and Lie algebras. In those contexts, you should think specifically of the algebraic structures relevant to them.