https://mooseframework.inl.gov
ElementGroupCentroidPositions.h
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 #pragma once
11 
12 // Moose includes
13 #include "Positions.h"
14 #include "BlockRestrictable.h"
15 
20 {
21 public:
24  virtual ~ElementGroupCentroidPositions() = default;
25 
26  void initialize() override;
27 
29 
33  {
34  return MooseEnum("block extra_id block_and_extra_id", "block");
35  }
38 
41 
43  std::vector<ExtraElementIDName> _extra_id_names;
45  std::vector<unsigned int> _extra_id_indices;
47  std::vector<std::vector<unsigned int>> _extra_id_group_indices;
48 
49 private:
50  unsigned int id(const Elem & elem, unsigned int id_index, bool use_subdomains);
51 };
ElementGroupCentroidPositions(const InputParameters &parameters)
std::vector< ExtraElementIDName > _extra_id_names
The names of the extra element ids to use to make groups.
void initialize() override
In charge of computing / loading the positions.
unsigned int id(const Elem &elem, unsigned int id_index, bool use_subdomains)
static MooseEnum groupTypeEnum()
{ How to group elements, to compute centroids for these groups
Positions objects are under the hood Reporters.
Definition: Positions.h:20
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
virtual ~ElementGroupCentroidPositions()=default
Positions from centroids of groups of elements (subdomains, extra element ids) in the mesh...
MooseMesh wraps a libMesh::Mesh object and enhances its capabilities by caching additional data and s...
Definition: MooseMesh.h:88
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
Definition: MooseEnum.h:33
std::vector< std::vector< unsigned int > > _extra_id_group_indices
The particular extra id values, for each extra id of interest.
An interface that restricts an object to subdomains via the &#39;blocks&#39; input parameter.
const InputParameters & parameters() const
Get the parameters of the object.
std::vector< unsigned int > _extra_id_indices
The indices of the extra element ids to use to make groups.