[petsc-users] Probelm with DMPlexExtractSubMesh
Aldo Bonfiglioli
aldo.bonfiglioli at unibas.it
Thu Nov 6 00:41:33 CST 2025
Dear all,
I am having troubles in using DMPlexExtractSubMesh to extract the
different strata of the Face Sets of a given mesh.
When run on the enclosed tetrahedral mesh of the unit cube generated
with gmsh
> Face Sets: 6 strata with value/size (1 (246), 2 (246), 3 (246), 4
> (246), 5 (242), 6 (242))
>
I would expect 246 "points" on stratum 3, but when I DMview the subdm
(and plot it) the surface mesh looks incomplete
> DM Object: patch_03 1 MPI process
> type: plex
> patch_03 in 2 dimensions:
> Cells are at height 1
> Number of 0-cells per rank: 122
> Number of 1-cells per rank: 325
> Number of 2-cells per rank: 204
> Number of 3-cells per rank: 204 [204]
> Labels:
> celltype: 4 strata with value/size (0 (122), 1 (325), 3 (204), 12 (204))
> depth: 4 strata with value/size (0 (122), 1 (325), 2 (204), 3 (204))
> Cell Sets: 1 strata with value/size (1 (204))
> Face Sets: 1 strata with value/size (3 (204))
> Edge Sets: 2 strata with value/size (1 (8), 5 (8))
>
see also patch_03.pdf
What am I doing wrong?
A simple reproducer (compiles with petsc-3.24.0) and the gmsh mesh are
enclosed.
Thanks,
Aldo
--
Dr. Aldo Bonfiglioli
Associate professor of Fluid Mechanics
Dipartimento di Ingegneria
Universita' della Basilicata
V.le dell'Ateneo Lucano, 10 85100 Potenza ITALY
tel:+39.0971.205203 fax:+39.0971.205215
web:https://urldefense.us/v3/__http://docenti.unibas.it/site/home/docente.html?m=002423__;!!G_uCfscf7eWS!aMKmGG4aim9XcbNSnDyHUkDyhUkQHGZ-u-xX2C-sycYUMmtTij6AwqsQbZPXJSvPp9KUfgwRJK2Ok6Me2BLgO0en1w4QF2fHo7s$
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20251106/7a2b8176/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: submesh_xmple.F90
Type: text/x-fortran
Size: 3882 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20251106/7a2b8176/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cube6.msh
Type: model/mesh
Size: 186084 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20251106/7a2b8176/attachment-0001.msh>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch_03.pdf
Type: application/pdf
Size: 160538 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20251106/7a2b8176/attachment-0001.pdf>
More information about the petsc-users
mailing list