Building your own DEC at home
Sharif Elcott, Peter Schröder · 2006
The methods of Discrete Exterior Calculus (DEC) have given birth to many new algorithms applicable to areas such as fluid simulation, deformable body simulation, and others. Despite the (possibly intimidating) mathematical theory that went into deriving these algorithms, in the end they lead to simple, elegant, and straightforward implementations. However, readers interested in implementing them should note that the algorithms presume the existence of a suitable simplicial complex data structure. Such a data structure needs to support local traversal of elements, adjacency information for all dimensions of simplices, a notion of a dual mesh, and all simplices must be oriented. Unfortunately, most publicly available tetrahedral mesh libraries provide only unoriented representations with little more than vertex-tet adjacency information (while we need vertex-edge, edge-triangle, edge-tet, etc.). For those eager to implement and build on the algorithms presented in this course without having to worry about these details, we provide an implementation of a DEC-friendly tetrahedral mesh data structure in C++. This chapter documents the ideas behind the implementation.