Eulers number for geometry made up of planar polygons which are defined in terms of edges and vertices is
Where V, E, and F are the number of vertices, edges, and faces respectively.
For a closed surface the Eulers number is always equal to 2.
This forms a simple test for the closure of computer generated facet geometry.