14 {
16
17 try {
18
19 moab::Core mb_instance;
20 moab::Interface &moab = mb_instance;
21
23 char mesh_out_file[255] = "out.h5m";
24 PetscBool flg_file = PETSC_FALSE;
25 ierr = PetscOptionsBegin(PETSC_COMM_WORLD,
"",
"none",
"none");
27 CHKERR PetscOptionsString(
"-my_file",
"mesh file name",
"",
"mesh.h5m",
29 CHKERR PetscOptionsString(
"-output_file",
"output mesh file name",
"",
30 "out.h5m", mesh_out_file, 255, PETSC_NULL);
31 ierr = PetscOptionsEnd();
33
34 const char *option;
35 option = "";
37
38 ParallelComm *pcomm = ParallelComm::get_pcomm(&moab,
MYPCOMM_INDEX);
39 if (pcomm == NULL)
40 pcomm = new ParallelComm(&moab, PETSC_COMM_WORLD);
41
42
45
49
53 << "Print all meshsets (old and added from meshsets "
54 "configurational file)";
55 for (auto cit = meshsets_interface_ptr->getBegin();
56 cit != meshsets_interface_ptr->getEnd(); cit++)
58
59 CHKERR moab.write_file(mesh_out_file);
60 }
62
64
65 return 0;
66}
#define CATCH_ERRORS
Catch errors.
#define MYPCOMM_INDEX
default communicator number PCOMM
#define CHKERR
Inline error check.
#define MOFEM_LOG(channel, severity)
Log.
SeverityLevel
Severity levels.
#define MOFEM_LOG_TAG(channel, tag)
Tag channel.
#define MOFEM_LOG_CHANNEL(channel)
Set and reset channel.
static MoFEMErrorCodeGeneric< PetscErrorCode > ierr
implementation of Data Operators for Forces and Sources
static MoFEMErrorCode Initialize(int *argc, char ***args, const char file[], const char help[])
Initializes the MoFEM database PETSc, MOAB and MPI.
Deprecated interface functions.
Interface for managing meshsets containing materials and boundary conditions.
MoFEMErrorCode setMeshsetFromFile(const string file_name, const bool clean_file_options=true)
add blocksets reading config file
MoFEMErrorCode getInterface(IFACE *&iface) const
Get interface reference to pointer of interface.