Add MeshTopology::ghost_mode()
Method
std::string MeshTopology::ghost_mode() const;
returning ['none', 'shared_vertex', 'shared_facet']
could be added. This can be helpful for user programs which need to check it and possibly also in DOLFIN internals.
The task seems to be pretty easy but there should be an agreement on the interface. For instance, one might want to use rather enum, but this doesn't play well with stringy parameters['ghost_mode']
.
More complicated task (not to be solved here) is providing ghost mode parameter at construction time. Usage of global parameter is not optimal.
Comments (9)
-
reporter -
Yes, it should be a property of the
Mesh
and not a global parameter. I'm also very happy with strings for things like this. -
Yes, it's bad as a parameter, but we always planned to change it.
I had something more abstract than
std::string MeshTopology::ghost_mode() const;
in mind. I'd like to return the type of 'ghost' connectivity, e.g. vertex-vertex versus facet-facet, and the depth (i.e., the number of ghost layers).
-
reporter Nice. Maybe more abstractly, mapping of connectivity to depth. One could like to have, for instance, 2 levels of vertex-vertex and 1 level of facet-facet simultaneously. Maybe a bit overkill.
-
We did something similar for colouring with a
std::vector
to represent the 'graph' connectivity. -
- removed milestone
Removing milestone: 1.7 (automated comment)
-
reporter The urgent need for this demonstrated by
#726. -
reporter -
assigned issue to
-
assigned issue to
-
reporter - changed status to resolved
Implemented simple
std::string Mesh::ghost_mode() const
in ec44213. Documented to be eventually removed/changed for internal library use.If in a need for more abstract description, please reopen or open a new issue.
- Log in to comment
@chris_richardson, @garth-wells, any opinion here?