https://mooseframework.inl.gov
MFEMBoundarySubMesh.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://mooseframework.inl.gov
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 #ifdef MFEM_ENABLED
11 
12 #include "MFEMBoundarySubMesh.h"
13 #include "MFEMProblem.h"
14 
16 
19 {
22 
23  params.addClassDescription("Class to construct an MFEMSubMesh formed from the subspace of the "
24  "parent mesh restricted to the set of user-specified boundaries.");
25  return params;
26 }
27 
29  : MFEMSubMesh(parameters),
30  MFEMBoundaryRestrictable(parameters, getMFEMProblem().mesh().getMFEMParMesh())
31 {
32 }
33 
34 void
36 {
37  _submesh = std::make_shared<mfem::ParSubMesh>(
38  mfem::ParSubMesh::CreateFromBoundary(getMesh(), getBoundaryAttributes()));
39 }
40 
41 #endif
Constructs and stores an mfem::ParSubMesh object as as a restriction of the parent mesh to the set of...
const mfem::Array< int > & getBoundaryAttributes()
const mfem::ParMesh & getMesh()
static InputParameters validParams()
MeshBase & mesh
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
static InputParameters validParams()
Definition: MFEMSubMesh.C:16
MFEMBoundarySubMesh(const InputParameters &parameters)
static InputParameters validParams()
Base class for construction of a mfem::ParSubMesh object.
Definition: MFEMSubMesh.h:22
registerMooseObject("MooseApp", MFEMBoundarySubMesh)
virtual void buildSubMesh() override
Constructs the submesh.
Base class for construction of an object that is restricted to a subset of boundaries of the problem ...
void addClassDescription(const std::string &doc_string)
This method adds a description of the class that will be displayed in the input file syntax dump...
std::shared_ptr< mfem::ParSubMesh > _submesh
Stores the constructed submesh.
Definition: MFEMSubMesh.h:39