Dimension-Independent Data Structures for Arbitrary Simplicial Complexes David Canino (canino.david@gmail.com) The Incidence Simplicial (IS) data structure The Generalized Indexed data structure with Adjacencies (IA*)
Directed Graph Representation for a Topological Data Structure A topological data structure can be described in terms of what simplices and what topological relations ~ k,m are directly encoded. A topological data structure, describing a simplicial complex Σ, can be represented as a directed graph G Σ =(N Σ,A Σ ), where: each node n σ in N Σ corresponds to a simplex σ each arc (n σ,n σ ) in A Σ corresponds to a topological relation ~ k,m between simplices σ and σ Any arc can be classified with respect to the topological relation ~ k,m it represents: boundary arc, if it corresponds to a boundary relation ~ k,m (with k>m) co-boundary arc, if it corresponds to a co-boundary relation ~ k,m (with k<m) adjacency arc, if it corresponds to an adjacency relation ~ k,k (with m=k) We define three spanning subgraphs of graph G Σ =(N Σ,A Σ ), namely: the boundary graph, formed by all nodes and boundary arcs the co-boundary graph, formed by all nodes and co-boundary arcs the adjacency graph, formed by all nodes and adjacency arcs
The Incidence Simplicial (IS) data structure The Incidence Simplicial (IS) data structure is a dimension-independent variant, restricted to simplicial complexes, of the Incidence Graph (IG), defined in Edelsbrunner, 1987. The IS data structure has been introduced recently in: L. De Floriani, A. Hui, D. Panozzo, D. Canino, A Dimension-Independent Data Structure for Simplicial Complexes, In Proceedings of the 19th International Meshing Roundtable (IMR 2010), pages 403-420, Springer, 2010 The IS data structure encodes abstract simplicial complexes of any dimension d, which are not necessarily embedded in any Euclidean space. It is an incidence-based data structure, and encodes all the simplices, plus a set of incidence relations for each simplex. Specifically, it encodes: boundary relation R p,p+1 (σ) for any p-simplex σ, with 0<p d (as in the incidence graph); partial co-boundary relation R* p,p+1 (σ) for any p-simplex σ, with 0 p<d, which consists of one arbitrary (p+1)-simplex incident at σ for each component in the star of σ, corresponding to one component in the link of σ.
The IS data structure (cont d) For instance, link of vertex v (in bold) is formed by two connected components, namely: vertex v, corresponding to top edge w in the star of v; triangle f t and edge e f, corresponding to tetrahedron t and to top triangle f, respectively. As a consequence, partial co-boundary relation R* 0,1 (v)=(w,e). Note that, for any maximal d-simplex, partial co-boundary relation R* d-1,d coincides with co-boundary relation R d-1,d, encoded in the IG data structure. The IS data structure is more compact than the incidence graph, since it encodes, for all simplices: the same immediate boundary relations as in the incidence graph a partial version of immediate co-boundary relations (as defined above) More mathematical details about the storage cost of the IS data structure can be found in our article.
Manifolds and the IS data structure The incidence graph may result in a verbose representation, which does not scale well to manifolds. On the contrary, when representing a manifold simplicial d-complex Σ through the IS data structure: immediate boundary relations R p,p-1 remain unchanged (wrt the incidence graph) immediate co-boundary relations R* p,p+1 are encoded as follows: only one (p+1)-simplex is encoded, for 0 p<d; one or two d-simplices are encoded in R d-1,d (like in the incidence graph). Recall that, in the incidence graph, all (p+1)-simplices in co-boundary relation R p,p+1 are encoded. Thus the IS data structure results in a more compact representation, which scales well to manifolds. In the incidence graph, co-boundary relation R 0,1 (v) encodes all edges incident at v (in bold lines). In the IS data structure, partial co-boundary relation R* 0,1 (v) encodes only one edge incident at v (in bold line).
The IS-Graph The IS-Graph is the graph-based representation of the IS data structure as directed graph: each node corresponds to a simplex, encoded in the IS data structure; each arc corresponds either to any immediate boundary relation R p,p-1 (IS Boundary arc), or to any partial co-boundary relation R* p,p+1 (IS Co-boundary arc). It is possible to define two spanning subgraphs of the IS-Graph, which we call: the IS Boundary Graph, which consists of all nodes and IS Boundary arcs; the IS Co-boundary Graph, which consists of all nodes and IS Co-boundary arcs. The IS-Graph is a spanning subgraph of the incidence graph, defined as follows: each node corresponds to a simplex, encoded in the IG data structure; each arc corresponds either to any immediate boundary relation R p,p-1 (IG Boundary arc), or to any co-boundary relation R p,p+1 (IG Co-boundary arc) Also in this case, it is possible to define two spanning subgraphs of the incidence graph, which we call: the IG Boundary Graph, which consists of all nodes and IG Boundary arcs (like in the IS-Graph); the IG Co-boundary Graph, which consists of all nodes and IG Co-boundary arcs.
The IS-Graph (An Example) IS Boundary Graph (but also IG Boundary Graph) IS Co-boundary Graph IG Co-boundary Graph
Boundary Relations in the IS data structure Let σ be a p-simplex and 0 q<p, then boundary relation R p,q (σ) can be retrieved by combining together boundary relations R k,k-1 (directly encoded) for k-faces of σ, with q<k p (like in the incidence graph). In the IS Boundary Graph, this operation is equivalent to visit nodes, describing simplices of dimension k (with q k<p), which are reachable from the node representing σ. In this traversal, all C p,q faces bounding σ are visited, where: Note that C p,q is a constant value, which depends only on p and q. Example: retrieving vertices in R 3,0 (t) We must traverse the IS Boundary Graph: first, we visit R 3,2 (t) (in red) then, we visit R 2,1 (in green) finally, we visit R 1,0 (in blue)
Co-boundary Relations in the IS data structure Let σ be a p-simplex and 0 p<q, then co-boundary relation R p,q (σ) is formed either by top q-simplices in the star of σ; or q-faces of top h-simplices (with h>q) incident at σ. Thus, the key operation consists of retrieving all top simplices, which are incident at σ, and select their faces in the star of σ. The starting point of this operation is given by partial co-boundary relations R* k,k+1, for p k<q (directly encoded). In order to solve this operation, we introduce the IS star-graph G σ of a p-simplex σ, which is a spanning subgraph of the IS-Graph, defined as follows: its nodes correspond to simplices in the star of σ; its arcs are either IS Boundary and IS Co-boundary arcs, which connect nodes, corresponding to simplices in the star of σ. Any co-boundary relation R p,q (σ) can be retrieved as the breadth-first traversal of graph G σ by visiting all arcs and nodes, recheable from node corresponding to σ, and by selecting nodes of G σ, describing q- simplices in the star of σ: Start from R* p,p+1 (σ) For any k-simplex, visit R* k,k+1 (σ) and R* k,k-1 (σ), restricted to the star of σ. At the end of this traversal, all nodes of G σ are visited, thus we visit all simplices in the star of σ. This operation is not optimal, unless for simplicial 2- and 3-complexes, embedded in the 3D space.
Co-boundary Relations in the IS data structure (Example) IS Boundary Graph IS Co-boundary Graph We consider the IS star graph G v, for vertex v=0, defined as the restriction of the IS Boundary and the Co-boundary Graphs to nodes corresponding to simplices in the star of v. IS Boundary Graph restricted to the star of v IS Co-boundary Graph restricted to the star of v
Co-boundary Relations in the IS data structure (Running Example) Suppose to retrieve all edges incident at vertex v=0, namely co-boundary relation R 0,1 (v). As mentioned above, it is necessary to perform a breadth-first traversal of the IS star-graph G v. Step 1: start from partial co-boundary relation R* 0,1 (0) visit partial co-boundary relation R* 1,2 (0,3) visit boundary relation R 2,1 (0,3,4). Step 2: visit partial co-boundary relation R* 1,2 (0,3) visit co-boundary relation R 2,3 (0,2,3) visit boundary relation R 2,1 (0,2,3).
Co-boundary Relations in the IS data structure (Running Example con td) Step 3: Step 4: visit boundary relation R 3,2 (0,1,23) visit boundary relation R 2,1 (0,1,2) visit boundary relation R 2,1 (0,1,3) At the end of this traversal, we retrieve edges in R 0,1 (0) = { (0,1), (0,2), (0,3), (0,4), (0,5) } (in red) In any case, it is necessary to visit all the top h-simplices (with h q) in the star of any p-simplex σ in order to retrieve all the q-simplices incident at σ.
The Generalized Indexed data structure with Adjacencies (IA*) The Generalized Indexed data structure with Adjacencies (IA*) is a dimension-independent variant, specific for representing non-manifold shapes discretized by simplicial complexes, of the Extended Indexed data structure with Adjacencies (EIA), defined in De Floriani, 2003. The IA* data structure has been introduced recently in: D. Canino, L. De Floriani, K. Weiss, IA*: an Adjacency-based Representation for Non-Manifold Simplicial Shapes in Arbitrary Dimensions, Computer & Graphics, 35(3):747-753, Elsevier Press, Shape Modeling International 2011 (SMI 2011), Poster The IA* data structure encodes abstract simplicial complexes of any dimension d, which are not necessarily embedded in any Euclidean space. It is an adjacency-based data structure, and encodes only vertices and top simplices, plus a subset of incidence relations for each vertex and a subset of adjacency relations, restricted to top simplices. The IA* data structure does not exploit any property, specific of the embedding space, like the radial ordering of triangles around an edge.
Definition of the IA* data structure Let Σ be a simplicial d-complex, then any p-cluster is a maximal (p-1)- connected subcomplex of Σ, such that two consecutive p-simplices share a (p-1)-face. For instance, triangles {f 1,f 2,f 3,f 4 } form a 2-cluster. The IA* data structure encodes all vertices and top simplices in Σ, plus the following relations: for every top p-simplex σ, boundary relation R p,0 (σ), such that 1 p d, which consists of vertices of σ. For instance, R 1,0 (w)={1,2} and R 2,0 (f 1 )={1,3,4}. For each vertex v: partial co-boundary relation R* 0,1 (v), which consists of all top edges incident at v. For instance, R*0,1(v)={w}. partial co-boundary relation R* 0,p (v), such that 1<p d, which consists of one arbitrary top p-simplex for each cluster of top p- simplices in the star of v. For instance, R 0,2 (v)={f 1,f 5 } and R 0,3 ={t 1 }.
Definition of the IA* data structure (cont d) For any top p-simplex σ, such that 2 p d, the IA* data structure also encodes partial adjacency relation R* p,p (σ), which consists of all top p- simplices in Σ, adjacent to σ through one of its (p-1)-faces. For instance, R* 2,2 (f 1 )={f 2,f 3,f 4 }, R* 2,2 (f 5 )={f 6 }, and R* 3,3 (t 1 )={t 2 }. Note that adjacency relation R* p,p (σ) may consist of more than one top p-simplex, e.g., R* 2,2 (f 1 ), thus it results in a verbose representation. In order to provide a compact representation of R* p,p (σ), the IA* data structure encodes, for any (p-1)-face τ of σ such that its star contains more than two top p-simplices (non-manifold adjacency), partial co-boundary relation R* p-1,p (τ), which consists of all top p-simplices in the star of τ. For instance, R* 1,2 (e)={f 1,f 2,f 3,f 4 }. In case of a non-manifold adjacency along a (p-1)-face τ of a top p- simplex σ, then R* p-1,p (τ) is encoded only once, and R* p,p (σ) along τ is encoded as a reference to R* p-1,p (τ)/σ. For instance, R 2,2 (f 1 )=R 1,2 (e)/f 1. Otherwise, adjacency relation R* p,p (σ) along one of its (p-1)-faces τ contains at most one reference to another top p-simplex adjacent to σ along τ (manifold adjacency). For instance, R* 2,2 (f 5 )={f 6 } and R* 3,3 (t 1 )={t 2 }.
Manifolds and the IA* data structure To the best of our experience, the IA* data structure is one of the most compact representations for non-manifold shapes, discretized by simplicial complexes (wrt the state of the art in 2011), as shown in our article, including an some mathematical details regarding its storage cost. When representing a simplicial d-complex Σ through the IA* data structure: there are only maximal d-simplices, and only boundary relations R d,0 are not empty; there is only one d-cluster in the star of each vertex v, namely in R* 0,d (v); partial co-boundary relation R* d-1,d (τ) is empty, for each (d-1)-face τ of any top d-simplex σ; there is at most one top d-simplex in adjacency relation R* d,d (σ) for each top d-simplex σ. As a consequence, when representing manifolds, the IA* data structure reduces to the EIA data structure, which scales well to manifolds.
The IA* Graph The IA*-Graph is the graph-based representation of the IA* data structure as directed graph: each node corresponds to one simplex, encoded in the IA* data structure, namely: vertices and top simplices; immediate faces τ of any top simplex σ such that R* p-1,p is not empty; each arc corresponds to one topological relation, encoded in the IA* data structure, namely: boundary relation R p,0 (IA* Boundary arc) for top simplices and vertices; co-boundary relations R* 0,p (IA* Co-boundary arc) for top simplices and vertices; adjacency relation R* p,p for top simplices, and partial co-boundary relation R* p-1,p for immediate (p-1)-faces of top p-simplices (IA* Adjacency arc). It is possible to define three spanning subgraphs of the IA*-Graph, which we call: the IA* Boundary Graph, which consists of all nodes corresponding to vertices and top simplices, plus IA* Boundary arcs; the IA* Co-boundary Graph, which consists of all nodes corresponding to vertices and top simplices, plus IA* Co-boundary arcs; the IA* Adjacency Graph, which consists of top simplices and their immediate faces, plus IA* Adjacency arcs.
The IA*-Graph (An Example) IA* Boundary Graph IA* Adjacency Graph IA* Co-boundary Graph
Boundary Relations in the IA* data structure Let σ be a top p-simplex, then boundary relation R p,0 (σ) is already encoded in the IA* data structure. On the contrary, a non top p-simplex σ is not directly encoded, and it must be represented implicitly. One of the most common representation consists of describing σ in terms of its vertices [v 0,,v p ]. In this context, it is necessary to exploit a rule for enumerating faces of a p-simplex σ in terms of its vertices. Usually, the i-th face of dimension (p-1) can be obtained by discarding vertex v i. Thus, boundary relation R p,q (σ) can be retrieved by generating all C p,q faces bounding σ in terms of its vertices where: Note that C p,q is a constant value, which depends only on p and q. IMPORTANT: we do not perform any explicit visit of the IA* Boundary Graph.
Retrieving Co-boundary Relations in the IA* data structure Let σ be a p-simplex and 0 p<q, then co-boundary relation R p,q (σ) is formed either by top q-simplices in the star of σ; or q-faces of top h-simplices (with h>q) incident at σ (as in the IS and EIA data structures). The key operation consists of retrieving top simplices, which are incident at any vertex v. The starting point of this operation is given by partial co-boundary relations R* 0,k, for p k d (directly encoded). In order to solve this operation, we introduce the IA* star-graph G v of any vertex v, which is a spanning subgraph of the IA*-Graph, defined as follows: its nodes correspond to top simplices in the star of v; its arcs are either IA* Co-boundary and IA* Adjacency arcs, which connect those nodes, corresponding to top simplices in the star of v. All top simplices in the star of v can be retrieved as the breadth-first traversal of graph G v by visiting all arcs and nodes, recheable from node corresponding to v, and by selecting nodes of G v, describing q- simplices in the star of v. For all 0<k d: start from each top k-simplex in R* 0,k (v), which represents one k-cluster in the star of v; exploit adjacency relation R* k,k in order to expand each k-cluster and retrieve its top k-simplices.
Co-boundary Relations in the IA* data structure (Example) IA* Co-boundary Graph IA* Adjacency Graph We consider the IA* star graph Gv, for vertex v=1, defined as the restriction of the IA* Co-boundary and the Adjacency Graphs to nodes corresponding to top simplices in the star of v. IA* Co-boundary Graph restricted to the star of v IA* Adjacency Graph restricted to the star of v
Co-boundary Relations in the IA* data structure (Running Example) Suppose to retrieve all top simplices incident at vertex v=1. As mentioned above, it is necessary to perform a breadth-first traversal of the IA* star-graph Gv. Step 2: expand 2-cluster, represented by top triangle (1,3,4) in partial co-boundary relation R*0,2(v), (in red) by exploiting partial co-boundary relation R*1,2 for non-manifold adjacency along edge (1,3) Step 1: start from top edge (1,2), encoded in partial co-boundary relation R*0,1(v)
Co-boundary Relations in the IA* data structure (Running Example cont d) Step 2: expand 2-cluster, represented by top triangle (1,8,9) in partial co-boundary relation R* 0,2 (v), by navigating on manifold adjacency along edge (1,9), namely adjacency relation R 2,2 (in blue) Step 3: expand 3-cluster, represented by tetrahedron (1,11,12,14) in partial co-boundary relation R* 0,3 (v), by navigating on manifold adjacency along triangle (1,12,14), namely adjacency relation R 3,3 (in green) At the end of this traversal, all nodes of graph G v, i.e., all top simplices incident at v, are visited, thus this operation is optimal in the IA* data structure. This operation is the basis for retrieving any co-boundary relation in the IA* data structure.
Other Co-boundary Relations in the IA* data structure Let v be a vertex, then co-boundary relation R 0.p (v), with 0<p d, can be retrieved in two steps: retrieve all top h-simplices (with h p) incident at v select their p-faces, which are also in the star of v. The time complexity of this operation is dominated by retrieving top simplices in the star of v (optimal only for simplicial 2- and 3-complexes embedded in the Euclidean 3D space) Let σ a p-simplex, then co-boundary relation R p,q (σ), with 0<p<q d, can be retrieved in two steps: retrieve all q-simplices in the star of one vertex v (arbitrary) on the boundary of σ, i.e., R 0,q (v) select q-simplices from R 0,q (v), which are also incident in the remaining vertices of σ The time complexity of this operation is dominated by retrieving top simplices in the star of any vertex v, thus it is not optimal in the IA* data structure.. The number of simplices incident at v is surely larger than the number of simplices incident at all vertices of σ. For instance, co-boundary relation R 1,2 (3,7)={f 4 }, but R 0,2 (3)={f 1,f 2,f 3,f 4 }.
Comparisons among the IG, the IS, and the IA* data structures It is interesting to compare the storage costs of the incidence graph, the IS and the IA* data structures, when representing non-manifold shapes, discretized by simplicial 2- and 3-complexes, not necessarily embedded in any Euclidean space. Experimental results show that the incidence graph is the most expensive and verbose representation among these. On the contrary, the IA* data structure is the most compact representation. For simplicial 2-complexes The incidence graph is about: 1.26 times more expensive than the IS data structure; 1.8 times more expensive than the IA* data structure. The IS data structure is about 1.4 times more expensive than the IA* data structure
Comparisons among the IG, the IS, and the IA* data structures (cont d) For simplicial 3-complexes For complexes in high dimensions The incidence graph is about: 1.39 times more expensive than the IS data structure; 3.2 times more expensive than the IA* data structure. The IS data structure is about 2.2 times more expensive than the IA* data structure The incidence graph tends to be almost the same as the IS data structure for high dimensions. The IG and the IS data structures tend to be extremely more expensive than the IA* data structure for high dimensions (for instance, up to, respectively, 160 and 100 times for 8D shapes).
The Mangrove Topological Data Structure (Mangrove TDS) Framework Fast prototyping of topological data structures with any property and representing simplicial complexes with any domain (including non-manifolds). Common graph-based representation (mangrove) of topological data structure, which can be dynamically customized at run-time (plugin-oriented architecture). Implicit representations of all simplices, not directly encoded in any adjacency-based data structure, which we call ghost simplices. The Mangrove TDS Library contains the complete implementation of this framework and of six topological data structures (also the IS and the IA* data structure). It is a GPL software: http://mangrovetds.sourceforge.net
Interesting Papers and References D. Canino, L. De Floriani, K. Weiss, IA*: an Adjacency-based Representation for Non-Manifold Simplicial Shapes in Arbitrary Dimensions, Computer & Graphics, 35(3):747-753, Elsevier Press, Shape Modeling International 2011 (SMI 2011), Poster L. De Floriani, D. Greenfieldboyce, and A. Hui, A Data Structure for Non-Manifold Simplicial d- complexes, In Proceedings of the 2nd Eurographics Symposium on Geometry Processing (SGP 04), pages 83-92, ACM Press, 2004 L. De Floriani and A. Hui, A Scalable Data Structure for Three-dimensional Non-manifold Objects, In Proceedings of the 1st Eurographics Symposium on Geometry Processing (SGP 03), pages 72-82, ACM Press, 2003 L. De Floriani and A. Hui, Data Structures for Simplicial Complexes: an Analysis and a Comparison, In Proceedings of the 3rd Eurographics Symposium on Geometry Processing (SGP 05), pages 119-128, ACM Press, 2005 L. De Floriani, A. Hui, D. Panozzo, D. Canino, A Dimension-Independent Data Structure for Simplicial Complexes, In Proceedings of the 19th International Meshing Roundtable, pages 403-420, Springer, 2010 L. De Floriani, P. Magillo, E. Puppo, and D. Sobrero, A Multi-resolution Topological Representation for Non-Manifold Meshes, CAD Journal, 36(2):141-159, 2003
Interesting Papers and References (cont d) H. Edelsbrunner, Algorithms in Combinatorial Geometry, Springer, 1987 A. Nabutovsky, Geometry of the Space of Triangulations of a Compact Manifold, Communications in Mathematical Physics, 18(1):303-330, 1996 A. Paoluzzi, F. Bernardini, C. Cattani, and V. Ferrucci, Dimension-independent Modeling with Simplicial Complexes, ACM Transactions on Graphics, 12(1):56-102, 1993 D. Sieger and M. Botsch, Design, Implementation, and Evaluation of the Surface_Mesh Data Structure, In Proceedings of the 20th International Meshing Roundtable, pages 533-550, Springer, 2011