19 params.
addClassDescription(
"Marks the region inside or empty if it contains a reporter defined " 20 "point for refinement or coarsening.");
26 "inside", marker_states,
"How to mark elements containing a point");
28 "empty", marker_states,
"How to mark elements not containing a point");
35 _inside(parameters.
get<
MooseEnum>(
"inside").getEnum<MarkerValue>()),
36 _empty(parameters.
get<
MooseEnum>(
"empty").getEnum<MarkerValue>()),
47 _pl->enable_out_of_mesh_mode();
48 const auto npoints =
_x_coord.size();
50 mooseError(
"The coordinate vectors are a different size. \n",
59 for (std::size_t i = 0; i < npoints; ++i)
62 const auto elem = (*_pl)(pt);
registerMooseObject("MooseApp", ReporterPointMarker)
std::unique_ptr< libMesh::PointLocatorBase > _pl
Pointer to PointLocatorBase object.
FEProblemBase & _fe_problem
T * get(const std::unique_ptr< T > &u)
The MooseUtils::get() specializations are used to support making forwards-compatible code changes fro...
const Elem *const & _current_elem
Pointer to the current element being considered in the marker element-based loop. ...
const MarkerValue _inside
marker value to give elements containing a point
MarkerValue
This mirrors the main refinement flag values in libMesh in Elem::RefinementState but adds "dont_mark"...
const std::vector< Real > & _z_coord
z coordinate
const std::vector< Real > & _y_coord
y coordinate
virtual void markerSetup() override
Is called before any element looping is started so any "global" computation can be done...
static InputParameters validParams()
const MarkerValue _empty
marker for elements not containing points
Interface to allow object to consume Reporter values.
static MooseEnum markerStates()
Helper function for getting the valid refinement flag states a marker can use as a MooseEnum...
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
const std::vector< Real > & _x_coord
x coordinate
std::set< dof_id_type > _point_elems
list of sort uniqued elements containing points
Marks all elements as inside/empty if they do/don't contain a point.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
virtual MooseMesh & mesh() override
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
virtual MarkerValue computeElementMarker() override
virtual std::unique_ptr< libMesh::PointLocatorBase > getPointLocator() const
Proxy function to get a (sub)PointLocator from either the underlying libMesh mesh (default)...
ReporterPointMarker(const InputParameters ¶meters)
const ReporterMode REPORTER_MODE_REPLICATED
static InputParameters validParams()
The Reporter system is comprised of objects that can contain any number of data values.