The mesh class provides methods to construct a mesh by specifying nodal coordinates and node indices which make up elements, and also routines for generic calculations related to the mesh structure, such as integration of a scalar- or vector-valued function over an element group, or calculation of the mass or stiffness matrix for an element group. It can create meshes in any number of dimensions, and elements of arbitrary polynonial order spectral discretization. Its methods are as follows: