xref: /petsc/src/dm/impls/plex/tutorials/ex2.c (revision 4663dae6020ed40d417a3314b7d84f74d0cdce91)
1 static char help[] = "TEST REMOVED\n\n";
2 
3 #include <petscdmplex.h>
4 
5 static PetscErrorCode CreateMesh(MPI_Comm comm, DM *dm)
6 {
7   PetscFunctionBeginUser;
8   PetscCall(DMCreate(comm, dm));
9   PetscCall(DMSetType(*dm, DMPLEX));
10   PetscCall(DMSetFromOptions(*dm));
11   PetscCall(DMViewFromOptions(*dm, NULL, "-dm_view"));
12   PetscFunctionReturn(0);
13 }
14 
15 int main(int argc, char **argv)
16 {
17   DM             dm;
18 
19   PetscCall(PetscInitialize(&argc, &argv, NULL,help));
20   PetscCall(CreateMesh(PETSC_COMM_WORLD, &dm));
21   PetscCall(DMDestroy(&dm));
22   PetscCall(PetscFinalize());
23   return 0;
24 }
25 
26 /*TEST
27 
28 TEST*/
29