v0.15.0
Loading...
Searching...
No Matches
nonlinear_dynamic_elastic.cpp File Reference
#include <MoFEM.hpp>
#include <MatrixFunction.hpp>
#include <HenckyOps.hpp>

Go to the source code of this file.

Classes

struct  ElementsAndOps< DIM >
 
struct  ElementsAndOps< 2 >
 
struct  ElementsAndOps< 3 >
 
struct  Example
 [Example] More...
 
struct  Monitor
 [Push operators to pipeline] More...
 

Typedefs

using DomainEle = ElementsAndOps<SPACE_DIM>::DomainEle
 
using PostProcEle = PostProcBrokenMeshInMoab<DomainEle>
 
using OpMass
 
using OpInertiaForce
 
using DomainNaturalBC
 
using OpBodyForceVector
 

Functions

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

Variables

constexpr int SPACE_DIM
 
constexpr double rho = 1
 
constexpr double omega = 2.4
 
constexpr double young_modulus = 1
 
constexpr double poisson_ratio = 0.25
 
static char help [] = "...\n\n"
 [Check]
 

Typedef Documentation

◆ DomainEle

◆ DomainNaturalBC

◆ OpBodyForceVector

◆ OpInertiaForce

◆ OpMass

◆ PostProcEle

Function Documentation

◆ main()

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

[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]

[Example]

[Example]

Definition at line 444 of file nonlinear_dynamic_elastic.cpp.

444 {
445
446 // Initialisation of MoFEM/PETSc and MOAB data structures
447 const char param_file[] = "param_file.petsc";
448 MoFEM::Core::Initialize(&argc, &argv, param_file, help);
449
450 // Add logging channel for example
451 auto core_log = logging::core::get();
452 core_log->add_sink(
454 LogManager::setLog("EXAMPLE");
455 MOFEM_LOG_TAG("EXAMPLE", "example");
456
457 try {
458
459 //! [Register MoFEM discrete manager in PETSc]
460 DMType dm_name = "DMMOFEM";
461 CHKERR DMRegister_MoFEM(dm_name);
462 //! [Register MoFEM discrete manager in PETSc
463
464 //! [Create MoAB]
465 moab::Core mb_instance; ///< mesh database
466 moab::Interface &moab = mb_instance; ///< mesh database interface
467 //! [Create MoAB]
468
469 //! [Create MoFEM]
470 MoFEM::Core core(moab); ///< finite element database
471 MoFEM::Interface &m_field = core; ///< finite element database interface
472 //! [Create MoFEM]
473
474 //! [Example]
475 Example ex(m_field);
476 CHKERR ex.runProblem();
477 //! [Example]
478 }
480
482}
#define CATCH_ERRORS
Catch errors.
#define CHKERR
Inline error check.
PetscErrorCode DMRegister_MoFEM(const char sname[])
Register MoFEM problem.
Definition DMMoFEM.cpp:43
static LoggerType & setLog(const std::string channel)
Set ans resset chanel logger.
#define MOFEM_LOG_TAG(channel, tag)
Tag channel.
static char help[]
[Check]
[Example]
Definition plastic.cpp:216
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:118
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.

Variable Documentation

◆ help

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

[Check]

Definition at line 442 of file nonlinear_dynamic_elastic.cpp.

◆ omega

double omega = 2.4
constexpr

Definition at line 43 of file nonlinear_dynamic_elastic.cpp.

◆ poisson_ratio

double poisson_ratio = 0.25
constexpr

Definition at line 45 of file nonlinear_dynamic_elastic.cpp.

◆ rho

double rho = 1
constexpr

Definition at line 42 of file nonlinear_dynamic_elastic.cpp.

◆ SPACE_DIM

int SPACE_DIM
constexpr
Initial value:
=
#define EXECUTABLE_DIMENSION
Definition plastic.cpp:13

Definition at line 23 of file nonlinear_dynamic_elastic.cpp.

◆ young_modulus

double young_modulus = 1
constexpr

Definition at line 44 of file nonlinear_dynamic_elastic.cpp.