[petsc-users] interpolate HDF5 mesh
Matthew Knepley
knepley at gmail.com
Thu Dec 20 09:40:57 CST 2018
On Thu, Dec 20, 2018 at 9:33 AM Yann JOBIC via petsc-users <
petsc-users at mcs.anl.gov> wrote:
> Dear Petsc Users,
>
> When i'm using DMPlexCreateBoxMesh, my code works fine. However, when i
> load the "exact" same mesh from an HDF5 file, it's not working anymore
> (Nonlinear solve did not converge due to DIVERGED_FNORM_NAN iterations 0).
>
> The mesh view when i use DMPlexCreateBoxMesh looks like (i labeled my
> boudary nodes):
>
> /* generated with DMPlexCreateBoxMesh */
> DM Object: Mesh 1 MPI processes
> type: plex
> Mesh in 3 dimensions:
> 0-cells: 216
> 1-cells: 540
> 2-cells: 450
> 3-cells: 125
> Labels:
> Faces: 6 strata with value/size (2 (121), 4 (121), 3 (121), 6 (121),
> 5 (121), 7 (121))
> boundary: 1 strata with value/size (1 (602))
> depth: 4 strata with value/size (0 (216), 1 (540), 2 (450), 3 (125))
> Face Sets: 6 strata with value/size (6 (25), 5 (25), 3 (25), 4 (25),
> 1 (25), 2 (25))
> marker: 1 strata with value/size (1 (450))
>
> And when i use DMPlexCreateFromFile, or DMLoad, i have :
>
> /* generated with H5 file */
> fin label DM
> DM Object: Mesh 1 MPI processes
> type: plex
> Mesh in 3 dimensions:
> 0-cells: 216
> 1-cells: 540
> 2-cells: 450
> 3-cells: 125
> Labels:
> Faces: 6 strata with value/size (2 (121), 4 (121), 6 (121), 7 (121),
> 5 (121), 3 (121))
> boundary: 1 strata with value/size (1 (602))
> depth: 4 strata with value/size (0 (216), 1 (540), 2 (450), 3 (125))
>
> It looks like my DM is not interpolated. Am i wrong ?
>
Its interpolated (you have 4 kinds of k-cells, instead of 2). However, you
are missing your
Face Sets marker, which probably means boundary conditions are not getting
applied.
Thanks,
Matt
> It's strange, because when i use DMPlexCreateFromFile, i put PETSC_TRUE
> for interpolation.
>
> Even after loading the mesh, i used DMPlexInterpolate, which return a
> new DM (not null).
>
> Do you know what's happening here ?
> Maybe my DIVERGED_FNORM_NAN comes from another part of the code ?
> (however only the mesh is changing)
>
> Thanks,
>
> Yann
>
--
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20181220/733969e8/attachment.html>
More information about the petsc-users
mailing list