25 "Outputs the IDs of every element intersected by a user-defined plane");
31 _p0(getParam<Point>(
"point")),
32 _normal(getParam<Point>(
"normal")),
33 _elem_ids(declareVector(
"elem_ids"))
47 std::vector<const Elem *> intersected_elems;
51 unsigned int num_elems = intersected_elems.size();
55 for (
unsigned int i = 0; i < num_elems; i++)
56 _elem_ids[i] = intersected_elems[i]->
id();
ElementsAlongPlane(const InputParameters ¶meters)
virtual void initialize() override
Called before execute() is ever called so that data can be cleared.
void elementsIntersectedByPlane(const libMesh::Point &p0, const libMesh::Point &normal, const libMesh::MeshBase &mesh, std::vector< const libMesh::Elem *> &intersected_elems)
Find all of the elements intersected by a plane.
This class is here to combine the VectorPostprocessor interface and the base class VectorPostprocesso...
VectorPostprocessorValue & _elem_ids
The elements that intersect the plane.
const Point & _normal
Normal vector to the plane.
void errorIfDistributedMesh(std::string name) const
Generate a unified error message if the underlying libMesh mesh is a DistributedMesh.
registerMooseObject("MooseApp", ElementsAlongPlane)
static InputParameters validParams()
static InputParameters validParams()
Get all of the elements that are intersected by a plane.
const Point & _p0
Point in the plane.
FEProblemBase & _fe_problem
Reference to the FEProblemBase for this user object.
virtual void execute() override
Find the elements.
virtual MooseMesh & mesh() override