11 #include "libmesh/quadrature_gauss.h" 27 "Type of the quadrature rule");
30 "Order of the volumetric quadrature. If unspecified, defaults to the " 31 "local element default order. This is not the problem default, which " 32 "is based on the order of the variables in the system.");
35 params.
set<
bool>(
"auto_sort") =
false;
37 params.
set<
bool>(
"auto_broadcast") =
true;
45 _mesh(_fe_problem.
mesh()),
65 unsigned int b_index = 0;
66 for (
const auto & sub_id :
blockIDs())
71 const FEFamily mapping_family = FEMap::map_fe_type(*elem);
72 const FEType fe_type(elem->default_order(), mapping_family);
73 std::unique_ptr<FEBase> fe =
FEBase::build(elem->dim(), fe_type);
76 auto qrule = QBase::build(
_q_type, elem->dim(), q_order);
77 fe->attach_quadrature_rule(qrule.get());
78 const auto & q_points = fe->get_xyz();
81 for (
const auto & q : q_points)
93 for (
const auto & elem :
_mesh.
getMesh().active_local_element_ptr_range())
96 const FEFamily mapping_family = FEMap::map_fe_type(*elem);
97 const FEType fe_type(elem->default_order(), mapping_family);
98 std::unique_ptr<FEBase> fe =
FEBase::build(elem->dim(), fe_type);
101 auto qrule = QBase::build(
_q_type, elem->dim(), q_order);
102 fe->attach_quadrature_rule(qrule.get());
103 const auto & q_points = fe->get_xyz();
106 for (
const auto & q : q_points)
std::unique_ptr< FEGenericBase< Real > > build(const unsigned int dim, const FEType &fet)
static MooseEnum getQuadratureOrderEnum()
Return the potential selections for the order of the quadrature, with an 'auto' default.
libMesh::Order _q_order
Order of the quadrature.
virtual void initialize() override
In charge of computing / loading the positions.
unsigned int numBlocks() const
Return the number of blocks for this object.
static InputParameters validParams()
void clearPositions()
Clear all positions vectors.
Positions objects are under the hood Reporters.
Positions of all the quadrature points.
T stringToEnum(const std::string &s)
QuadraturePointsPositions(const InputParameters ¶meters)
virtual const std::set< SubdomainID > & blockIDs() const
Return the block subdomain ids for this object Note, if this is not block restricted, this function returns all mesh subdomain ids.
virtual bool blockRestricted() const
Returns true if this object has been restricted to a block.
The following methods are specializations for using the libMesh::Parallel::packed_range_* routines fo...
bool _initialized
Whether the positions object has been initialized. This must be set by derived objects.
static InputParameters validParams()
static MooseEnum getQuadratureTypesEnum()
Return the possible selections for the type of the quadrature.
std::vector< std::vector< Point > > _positions_2d
2D storage for all the positions
dof_id_type n_active_local_elem() const
libMesh::QuadratureType _q_type
Type of the quadrature.
MeshBase & getMesh()
Accessor for the underlying libMesh Mesh object.
std::vector< Point > & _positions
For now, only the 1D vector will be shared across all ranks.
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
MooseMesh & _mesh
Reference to the mesh.
static InputParameters validParams()
virtual SimpleRange< element_iterator > active_local_subdomain_elements_ptr_range(subdomain_id_type sid)=0
An interface that restricts an object to subdomains via the 'blocks' input parameter.
virtual void finalize() override
In charge of reduction across all ranks & sorting for consistent output.
MOOSE now contains C++17 code, so give a reasonable error message stating what the user can do to add...
registerMooseObject("MooseApp", QuadraturePointsPositions)