I have a very simple unstructured mesh composed of two triangles (four vertices) with one shared edge using a DMPlex:
/|\ / | \ \ | / \|/ After distributing this mesh to two processes, each process owns a triangle. However one process owns tree vertices, while the last vertex is owned by the other process. The problem occurs after uniformly refining the dm. The mesh now looks like this: /|\ /\|/\ \/|\/ \|/ The new center vertex is now not listed as a ghost vertex but instead exists as two individual points. Is there any way that this new center vertex could be created as a ghost vertex during refinement? Kind regards, Morten Ps. Here are some code snippets for getting global point index and test of point is a ghost point: int localToGlobal(DM dm, PetscInt point){ const PetscInt* array; ISLocalToGlobalMapping ltogm; DMGetLocalToGlobalMapping(dm,<ogm); ISLocalToGlobalMappingGetIndices(ltogm, &array); PetscInt res = array[point]; if (res < 0){ // if ghost res = -res +1; } return res; } bool isGhost(DM dm, PetscInt point){ const PetscInt* array; ISLocalToGlobalMapping ltogm; DMGetLocalToGlobalMapping(dm,<ogm); ISLocalToGlobalMappingGetIndices(ltogm, &array); return array[point]<0; }