Space group
The space group of a crystal or crystallographic group is a mathematical description of the symmetry inherent in the structure.  The word 'group' in the name comes from the mathematical notion of a group, which is used to build the set of space groups.

# Crystallography
The space groups in three dimensions are made from combinations of the 32 crystallographic point groups with the 14 Bravais lattices which belong to one of 7 crystal systems.  This results in a space group being some combination of the translational symmetry of a unit cell including lattice centering, and the point group symmetry operations of reflection, rotation and improper rotation (also called rotoinversion). Furthermore one must consider the screw axis and glide plane symmetry operations. These are called compound symmetry operations and are combinations of a rotation or reflection with a translation less than the unit cell size. The combination of all these symmetry operations results in a total of 230 unique space groups describing all possible crystal symmetries.

## Glide planes and screw axes
Two of the symmetry operations involved in the space groups are not contained in the corresponding point group or Bravais lattice. These are the compound symmetry operations called the glide plane and the screw axis.
A glide plane is a reflection in a plane, followed by a translation parallel with that plane. This is noted by a, b or c, depending on which axis the glide is along.  There is also the n glide, which is a glide along the half of a diagonal of a face, and the d glide, which is a fourth of the way along either a face or space diagonal of the unit cell. The latter is often called the diamond glide plane as it features in the diamond structure.
A screw axis is a rotation about an axis, followed by a translation along the direction of the axis.  These are noted by a number, n, to describe the degree of rotation, where the number is how many operations must be applied to complete a full rotation (e.g., 3 would mean a rotation one third of the way around the axis each time).  The degree of translation is then added as a subscript showing how far along the axis the translation is, as a portion of the parallel lattice vector.  So, 21 is a twofold rotation followed by a translation of 1/2 of the lattice vector.

## Notation
There are a number of methods of identifying space groups.  The International Union of Crystallography publishes a table (more correctly, a hefty tome of tables) of all space groups, and assigns each a unique number.  Other than this numbering scheme there are two main forms of notation, the Hermann-Mauguin notation and Schonflies notation.
The Hermann-Mauguin (or international) notation is the one most commonly used in crystallography, and consists of a set of four symbols.  The first describes the centering of the Bravais lattice (P, A, B, C, I, R or F).  The next three describe the most prominent symmetry operation visible when projected along one of the high symmetry directions of the crystal. These symbols are the same as used in point groups, with the addition of glide planes and screw axis, described above.  By way of example, the space group of quartz is P3121, showing that it exhibits primitive centering of the motif (i.e., once per unit cell), with a threefold screw axis and a twofold rotation axis.  Note that it does not explicitly contain the crystal system, although this is unique to each space group (in the case of P3121, it is trigonal).
In HM notation the first symbol (31 in this example) denotes the symmetry along the major axis (c-axis in trigonal cases), the second (2 in this case) along axes of secondary importance (a and b) and the third symbol the symmetry in another direction. In the trigonal case there also exists a space group P3112. In this space group the twofold axes are not along the a and b-axes but in a direction rotated by 30o.

# Group theory
Mathematically, a space group is a  symmetry group or symmetry group type of n-dimensional structures with translational symmetry in n independent directions, such as, for n = 3, a crystal. Only discrete symmetry groups are included in the categorization; i.e.,  infinitely fine structure or homogeneity in one or more directions is excluded. This comes from the necessity to describe discrete sets of 'points' (i.e. atoms or ions in a crystal), as opposed to continuous media (see Symmetry in physics for the latter case). See the articles Bravais lattices, Crystals, and Translation (geometry) for a fuller discussion.
Two symmetry groups are of the same crystallographic space group type if they are the same up to an affine transformation of space that preserves orientation. Thus e.g. a change of angle between translation vectors does not affect the space group type if it does not add or remove any symmetry. A more formal definition involves conjugacy, see Symmetry group.
Two symmetry groups are of the same affine space group type if they are the same up to an affine transformation, even if that inverts orientation.
This can be expressed by saying that two symmetry groups which are chiral and each other's mirror image, are of different crystallographic space group type, but of the same affine space group type.
In 1D and 2D space groups of the same affine space group type are also of the same crystallographic space group type, but in 3D this need not be the case: in 2D, the mirror image of a rotation is a reversed rotation, which is in the group anyway, and the mirror image of a mirror is still a mirror, but the mirror image of a righthand screw operation is a lefthand one, not the inverse of the righthand screw operation.
The Bieberbach theorem states that in each dimension all affine space group types are different even as abstract groups (as opposed to e.g. Frieze groups, of which two are isomorphic with Z).
The term "space group" is often used for space group type. It is often clear from the context what is meant. However, when considering subgroup relationships a specific symmetry group should not be confused with the space group type.

## Various dimensions
In 1D there are two space group types: those with and without mirror image symmetry, see symmetry groups in one dimension.
In 2D there are 17; these 2D space groups are also called wallpaper groups or plane groups.
In 3D there are 230 crystallographic space group types, which reduces to 219 affine space group types because of some types being different from their mirror image; these are said to differ by "enantiomorphous character" (e.g.  P3112 and  P3212). Usually "space group" refers to 3D. They are by themselves purely mathematical, but play a large role in crystallography.
In 4 dimensions there are 4895 crystallographic space group types, or 4783 affine space group types.
The number of affine space group types in n dimensions is given by sequence A004029 in OEIS; the number of crystallographic space group types in n dimensions is given by A006227.

## Double groups and time reversal
In addition to crystallographic space groups there are also magnetic space groups or double groups. These symmetries contain an element known as time reversal. They are of importance in magnetic structures that contain ordered unpaired spins, i.e. ferro-, ferri- or antiferromagnetic structures as studied by neutron diffraction. The time reversal element flips a magnetic spin while leaving all other structure the same and it can be combined with a number of other symmetry elements. Including time reversal there are 1651 magnetic space groups in 3D. 

## Grouping by point group
A symmetry group consists of isometric affine transformations; each is given by an orthogonal matrix and a translation vector (which may be the zero vector). Space groups can be grouped by the matrices involved, i.e. ignoring the translation vectors (see also Euclidean group). This corresponds to discrete symmetry groups with a fixed point: the point groups. However, not all point groups are compatible with translational symmetry; those that are compatible are called the crystallographic point groups. This is expressed in the crystallographic restriction theorem. (In spite of these names,  this is a geometric limitation, not just a physical one.)
In 1D both space group types correspond to their own "crystallographic point group".
In 2D the 17 wallpaper groups are grouped according to 10 associated crystallographic point groups: 1-, 2-, 3-, 4-, and 6-fold rotational symmetry, each with or without reflections. Thus a wallpaper group with  glide reflection axes is associated with the same point group as the wallpaper group with reflection axes parallel to these glide reflection axes.
In 3D this gives a grouping of the 230 space group types into 32 crystal classes, one for each associated crystallographic point group. A space group with a screw axis is in the same crystal class as one with a corresponding pure axis of rotation. Similarly a space group with a glide plane is in the same crystal class as one with a corresponding pure reflection.
In addition to translations, and the point operations of reflection, rotation and improper rotation, there are combinations of reflections and rotations with translation: the screw axis and the glide plane.
The number of crystallographic point groups in n dimensions is given by OEIS:A004028.

## Further categorizing
Space groups are categorized by Bravais lattice and  crystal class. However, for some combinations there are multiple space groups, while other combinations are not possible.
The 230 space group types can be subdivided in two categories:
- 73 symmorphic space group types: a space group is symmorphic if all symmetries can be described in terms of rotation axes and reflection planes all through the same point (including rotoreflections), without screw axes and glide planes). Equivalently, a space group is symmorphic if it is equivalent to a semidirect product of its point group with its translation subgroup.
- 157 nonsymmorphic space group types.
Conway and Thurston gave another classification of the space groups, where they divided the 230 groups into reducible and irreducible groups. The reducible groups fall into 17 classes corresponding to the 17 wallpaper groups, and the remaining 35 irreducible groups are classified separately.