D-D connectivity should be redefined

Issue #505 resolved
Chris Richardson created an issue

At present, statements like:

Edge edge;
EdgeIterator e(edge); 

will produce an iterator over all edges connected to edge via vertices, i.e. D-0-D connectivity.

In practice, this is hardly ever needed, and a lot of code ends up having special cases.

Really, EdgeIterator(edge) should just iterate over one Edge, i.e. edge.

Comments (7)

  1. Prof Garth Wells

    I just added some code that, once again, required a special case to handle the current behaviour. I've lost count of the 'special cases' now, so we really should make the change proposed in this Issue.

  2. Jan Blechta

    I don't have strong opinion here but my feeling is that in the context of FEM D-D is best interpreted as D-(D-1)-D.

    To your example with edges, Chris, edge-edge connectivity being 1-0-1 seems very natural to me in 1D where it is equivalent to cell-cell == cell-facet-cell. This corresponds well to D-(D-1)-D scheme.

  3. Prof Garth Wells

    The most compelling argument is that Chris' proposal removes the need for special cases in numerous places. It's good to have dimension-independent code, which Chris' suggestion makes possible.

    It also makes d0-d1 connectivity work consistently, rather than d-d magically being d-d1-d (where d1 is arbitrary) under the hood.

  4. Log in to comment