v0.14.0
Classes | Typedefs | Functions | Variables
poisson_2d_homogeneous.cpp File Reference
#include <poisson_2d_homogeneous.hpp>

Go to the source code of this file.

Classes

struct  Poisson2DHomogeneous
 

Typedefs

using PostProcFaceEle = PostProcBrokenMeshInMoab< DomainEle >
 

Functions

int main (int argc, char *argv[])
 [Run program] More...
 

Variables

constexpr auto field_name = "U"
 
constexpr int SPACE_DIM
 
static char help [] = "...\n\n"
 

Typedef Documentation

◆ PostProcFaceEle

Definition at line 23 of file poisson_2d_homogeneous.cpp.

Function Documentation

◆ main()

int main ( int  argc,
char *  argv[] 
)

[Run program]

[Main]

Examples
poisson_2d_homogeneous.cpp.

Definition at line 258 of file poisson_2d_homogeneous.cpp.

258  {
259 
260  // Initialisation of MoFEM/PETSc and MOAB data structures
261  const char param_file[] = "param_file.petsc";
262  MoFEM::Core::Initialize(&argc, &argv, param_file, help);
263 
264  // Error handling
265  try {
266  // Register MoFEM discrete manager in PETSc
267  DMType dm_name = "DMMOFEM";
268  CHKERR DMRegister_MoFEM(dm_name);
269 
270  // Create MOAB instance
271  moab::Core mb_instance; // mesh database
272  moab::Interface &moab = mb_instance; // mesh database interface
273 
274  // Create MoFEM instance
275  MoFEM::Core core(moab); // finite element database
276  MoFEM::Interface &m_field = core; // finite element interface
277 
278  // Run the main analysis
279  Poisson2DHomogeneous poisson_problem(m_field);
280  CHKERR poisson_problem.runProgram();
281  }
282  CATCH_ERRORS;
283 
284  // Finish work: cleaning memory, getting statistics, etc.
286 
287  return 0;
288 }

Variable Documentation

◆ field_name

constexpr auto field_name = "U"
constexpr

◆ help

char help[] = "...\n\n"
static
Examples
poisson_2d_homogeneous.cpp.

Definition at line 25 of file poisson_2d_homogeneous.cpp.

◆ SPACE_DIM

constexpr int SPACE_DIM
constexpr
Initial value:
Examples
poisson_2d_homogeneous.cpp.

Definition at line 15 of file poisson_2d_homogeneous.cpp.

EXECUTABLE_DIMENSION
#define EXECUTABLE_DIMENSION
Definition: plastic.cpp:13
MoFEM::CoreTmp< 0 >
Core (interface) class.
Definition: Core.hpp:82
MoFEM::CoreTmp< 0 >::Finalize
static MoFEMErrorCode Finalize()
Checks for options to be called at the conclusion of the program.
Definition: Core.cpp:112
MoFEM::DeprecatedCoreInterface
Deprecated interface functions.
Definition: DeprecatedCoreInterface.hpp:16
MoFEM::Interface
DeprecatedCoreInterface Interface
Definition: Interface.hpp:1975
CHKERR
#define CHKERR
Inline error check.
Definition: definitions.h:535
MoFEM::DMRegister_MoFEM
PetscErrorCode DMRegister_MoFEM(const char sname[])
Register MoFEM problem.
Definition: DMMoFEM.cpp:47
Poisson2DHomogeneous
Definition: poisson_2d_homogeneous.cpp:27
help
static char help[]
Definition: poisson_2d_homogeneous.cpp:25
MoFEM::CoreTmp< 0 >::Initialize
static MoFEMErrorCode Initialize(int *argc, char ***args, const char file[], const char help[])
Initializes the MoFEM database PETSc, MOAB and MPI.
Definition: Core.cpp:72
CATCH_ERRORS
#define CATCH_ERRORS
Catch errors.
Definition: definitions.h:372
MoFEM::Core
CoreTmp< 0 > Core
Definition: Core.hpp:1094