v0.14.0
Loading...
Searching...
No Matches
Classes | Typedefs | Functions | Variables
mixed_poisson.cpp File Reference
#include <MoFEM.hpp>
#include <BasicFiniteElements.hpp>

Go to the source code of this file.

Classes

struct  MixedPoisson
 
struct  MixedPoisson::CommonData
 
struct  MixedPoisson::OpError
 

Typedefs

using DomainEle = PipelineManager::FaceEle
 
using DomainEleOp = DomainEle::UserDataOperator
 
using EntData = EntitiesFieldData::EntData
 
using OpHdivHdiv
 
using OpHdivU
 
using OpDomainSource
 

Functions

double sqr (double x)
 
int main (int argc, char *argv[])
 [OpError]
 

Variables

static char help [] = "...\n\n"
 

Typedef Documentation

◆ DomainEle

Definition at line 18 of file mixed_poisson.cpp.

◆ DomainEleOp

Definition at line 19 of file mixed_poisson.cpp.

◆ EntData

Definition at line 20 of file mixed_poisson.cpp.

◆ OpDomainSource

◆ OpHdivHdiv

using OpHdivHdiv
Initial value:
FormsIntegrators< DomainEleOp >::Assembly< PETSC >::BiLinearForm< GAUSS >::OpMass< 1, SPACE_DIM > OpMass
Examples
mixed_poisson.cpp.

Definition at line 22 of file mixed_poisson.cpp.

◆ OpHdivU

using OpHdivU
Initial value:
Examples
mixed_poisson.cpp, and phase.cpp.

Definition at line 24 of file mixed_poisson.cpp.

Function Documentation

◆ main()

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

[OpError]

[Register MoFEM discrete manager in PETSc]

[Register MoFEM discrete manager in PETSc

[Create MoAB]

< mesh database

< mesh database interface

[Create MoAB]

[Create MoFEM]

< finite element database

< finite element database interface

[Create MoFEM]

[MixedPoisson]

[MixedPoisson]

Definition at line 568 of file mixed_poisson.cpp.

568 {
569 // Initialisation of MoFEM/PETSc and MOAB data structures
570 const char param_file[] = "param_file.petsc";
572
573 // Add logging channel for example problem
574 auto core_log = logging::core::get();
575 core_log->add_sink(
577 LogManager::setLog("EXAMPLE");
578 MOFEM_LOG_TAG("EXAMPLE", "MixedPoisson");
579
580 try {
581 //! [Register MoFEM discrete manager in PETSc]
582 DMType dm_name = "DMMOFEM";
583 CHKERR DMRegister_MoFEM(dm_name);
584 //! [Register MoFEM discrete manager in PETSc
585
586 //! [Create MoAB]
587 moab::Core mb_instance; ///< mesh database
588 moab::Interface &moab = mb_instance; ///< mesh database interface
589 //! [Create MoAB]
590
591 //! [Create MoFEM]
592 MoFEM::Core core(moab); ///< finite element database
593 MoFEM::Interface &m_field = core; ///< finite element database interface
594 //! [Create MoFEM]
595
596 //! [MixedPoisson]
597 MixedPoisson ex(m_field);
598 CHKERR ex.runProblem();
599 //! [MixedPoisson]
600 }
602
604}
std::string param_file
#define CATCH_ERRORS
Catch errors.
#define CHKERR
Inline error check.
PetscErrorCode DMRegister_MoFEM(const char sname[])
Register MoFEM problem.
Definition DMMoFEM.cpp:47
static LoggerType & setLog(const std::string channel)
Set ans resset chanel logger.
#define MOFEM_LOG_TAG(channel, tag)
Tag channel.
static char help[]
Core (interface) class.
Definition Core.hpp:82
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
static MoFEMErrorCode Finalize()
Checks for options to be called at the conclusion of the program.
Definition Core.cpp:112
Deprecated interface functions.
static boost::shared_ptr< SinkType > createSink(boost::shared_ptr< std::ostream > stream_ptr, std::string comm_filter)
Create a sink object.
static boost::shared_ptr< std::ostream > getStrmWorld()
Get the strm world object.

◆ sqr()

double sqr ( double x)
inline
Examples
mixed_poisson.cpp.

Definition at line 29 of file mixed_poisson.cpp.

29{ return x * x; }

Variable Documentation

◆ help

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

Definition at line 14 of file mixed_poisson.cpp.