12#ifndef BELFEM_CL_FEM_KERNEL_HPP
13#define BELFEM_CL_FEM_KERNEL_HPP
65 const uint mFieldOffset ;
68 Mesh * mSubMesh =
nullptr;
74 bool mOwnParameters = false ;
90 bool mOwnCommTables = false ;
91 bool mOwnMesh = false ;
92 bool mOwnSubmesh = false ;
326 BELFEM_ASSERT( mCommRank == 0,
"Only master may call the comm table." );
327 return mCommTables( aProc );
347 return mFieldOffset ;
355 return mBoundaryConditions ;
365 for (
id_t tID : tBC->domains())
373 BELFEM_ERROR(
false,
"Sideset is not associated to a boundary contition") ;
382 return mCommRank == 0 ? mMesh : mSubMesh ;
390 return mDofManagers.size();
398 return mCommRank == 0 ;
406 return mController != nullptr ;
418 return this->
mesh()->node( aID );
422 return this->
mesh()->edge( aID );
426 return this->
mesh()->face( aID );
#define BELFEM_ERROR(aCheck,...)
Definition assert.hpp:264
#define BELFEM_ASSERT(aCheck,...)
Definition assert.hpp:244
Cell is a wrapper around the standard vector.
Definition cl_Cell.hpp:42
Hash map (unordered key-value).
Definition cl_Map.hpp:75
Base class for all materials in BELFEM.
Definition cl_Material.hpp:279
Top-level container for all mesh entities.
Definition cl_Mesh.hpp:60
mesh::Facet * facet(const id_t aID)
Definition cl_Mesh.hpp:1428
mesh::Element * element(const id_t aID)
Definition cl_Mesh.hpp:1352
Nonlinear iteration controller: relaxation, timestep adaptation and convergence policy.
Definition cl_FEM_Controller.hpp:38
this class creates the DOFs based on the passed equation object.
Definition cl_FEM_DofManager.hpp:55
Prototype for Integrator of Weak Form Governing Equation.
Definition cl_IWG.hpp:81
Creates IWG instances by equation type.
Definition cl_IwgFactory.hpp:30
Cell< PhysicalBoundaryCondition * > & boundary_conditions()
expose the boundary condition container
Definition cl_FEM_Kernel.hpp:353
Kernel(KernelParameters *aKernelParameters)
Definition cl_FEM_Kernel.cpp:46
const Cell< const mesh::CommTable * > & comm_tables() const
Definition cl_FEM_Kernel.hpp:331
const KernelParameters * params()
expose parameter object
Definition cl_FEM_Kernel.cpp:641
PhysicalBoundaryCondition * boundary_condition(id_t aID)
expose a boundary condition for a specific sideset ID
Definition cl_FEM_Kernel.hpp:361
bool is_master() const
Definition cl_FEM_Kernel.hpp:396
Material * material(const string &aLabel)
returns the material object registered under aLabel ( add_material ).
Definition cl_FEM_Kernel.cpp:745
Controller * controller()
Definition cl_FEM_Kernel.cpp:1209
void compute_element_volumes()
Definition cl_FEM_Kernel.cpp:865
bool has_controller() const
true once set_controller() has attached a Controller; callers that may legitimately run without one a...
Definition cl_FEM_Kernel.hpp:404
IWG * create_equation(const IwgType aEquationType, const ModelDimensionality aModelDimensionality=ModelDimensionality::UNDEFINED, const Vector< id_t > aBlocks={}, const Vector< id_t > aSideSets={})
Definition cl_FEM_Kernel.cpp:549
void claim_parameter_ownership(const bool aFlag=true)
if this flag is set, the kernel will destroy the parameters
Definition cl_FEM_Kernel.cpp:793
void set_controller(Controller *aController)
Definition cl_FEM_Kernel.cpp:1201
DofManager * create_field(IWG *aEquation)
Definition cl_FEM_Kernel.cpp:612
uint number_of_dof_managers() const
Definition cl_FEM_Kernel.hpp:388
DofManager * dofmgr(const uint aIndex=0)
expose a field
Definition cl_FEM_Kernel.cpp:737
void add_material(const string aLabel, Material *aMaterial)
manually add a material to the kernel.
Definition cl_FEM_Kernel.cpp:758
void compute_boundary_conditions(real aTime)
Compute the boundary condition and update the Dofs at a given time.
Definition cl_FEM_Kernel.cpp:782
const uint & field_offset() const
returns the number of fields that existed before Kernel was created
Definition cl_FEM_Kernel.hpp:345
Mesh * mesh()
returns the mesh on the master and the submesh on other
Definition cl_FEM_Kernel.hpp:380
void add_boundary_condition(PhysicalBoundaryCondition *aBC)
manually add the BCs to the kernel.
Definition cl_FEM_Kernel.cpp:773
const proc_t & number_of_procs() const
Definition cl_FEM_Kernel.hpp:337
const mesh::CommTable * comm_table(const uint aProc) const
Definition cl_FEM_Kernel.hpp:324
void add_equation(IWG *aEquation)
special function to add an equation that has already been created.
Definition cl_FEM_Kernel.cpp:604
Definition cl_FEM_KernelParameters.hpp:29
Definition cl_FEM_PhysicalBoundaryCondition.hpp:37
Definition cl_Mesh_Basis.hpp:33
Definition cl_CommTable.hpp:25
Definition cl_IFB_LINE3.hpp:21
USER GUIDES:
Definition cl_Capacitor.cpp:16
IwgType
Definition en_IWGs.hpp:64
unsigned int uint
Definition typedefs.hpp:30
unsigned int id_t
Definition typedefs.hpp:41
ModelDimensionality
Definition en_IWGs.hpp:20
@ UNDEFINED
Definition en_IWGs.hpp:25
int proc_t
Definition commtypes.hpp:29
EntityType
Definition Mesh_Enums.hpp:116
@ NODE
Definition Mesh_Enums.hpp:117
@ FACE
Definition Mesh_Enums.hpp:119
@ EDGE
Definition Mesh_Enums.hpp:118
@ FACET
Definition Mesh_Enums.hpp:121
@ ELEMENT
Definition Mesh_Enums.hpp:122
double real
Definition typedefs.hpp:36