https://mooseframework.inl.gov
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Protected Types | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
ControlDrumMeshGenerator Class Reference

Mesh generator for defining a reactor control drum that can be used in a Cartesian or hexagonal lattice with the option to be 2-D or 3-D. More...

#include <ControlDrumMeshGenerator.h>

Inheritance diagram for ControlDrumMeshGenerator:
[legend]

Public Types

typedef DataFileName DataFileParameterType
 

Public Member Functions

 ControlDrumMeshGenerator (const InputParameters &parameters)
 
std::unique_ptr< MeshBase > generate () override
 
void generateData () override
 
std::unique_ptr< CSG::CSGBasegenerateInternalCSG ()
 
std::unique_ptr< MeshBase > generateInternal ()
 
const std::set< MeshGeneratorName > & getRequestedMeshGenerators () const
 
const std::set< MeshGeneratorName > & getRequestedMeshGeneratorsForSub () const
 
void addParentMeshGenerator (const MeshGenerator &mg, const AddParentChildKey)
 
void addChildMeshGenerator (const MeshGenerator &mg, const AddParentChildKey)
 
const std::set< const MeshGenerator *, Comparator > & getParentMeshGenerators () const
 
const std::set< const MeshGenerator *, Comparator > & getChildMeshGenerators () const
 
const std::set< const MeshGenerator *, Comparator > & getSubMeshGenerators () const
 
bool isParentMeshGenerator (const MeshGeneratorName &name, const bool direct=true) const
 
bool isChildMeshGenerator (const MeshGeneratorName &name, const bool direct=true) const
 
bool isNullMeshName (const MeshGeneratorName &name) const
 
bool hasSaveMesh () const
 
bool hasOutput () const
 
const std::string & getSavedMeshName () const
 
bool hasGenerateData () const
 
bool hasGenerateCSG () const
 
bool isDataOnly () const
 
virtual bool enabled () const
 
std::shared_ptr< MooseObjectgetSharedPtr ()
 
std::shared_ptr< const MooseObjectgetSharedPtr () const
 
bool isKokkosObject () const
 
MooseAppgetMooseApp () const
 
const std::string & type () const
 
const std::string & name () const
 
std::string typeAndName () const
 
MooseObjectParameterName uniqueParameterName (const std::string &parameter_name) const
 
MooseObjectName uniqueName () const
 
const InputParametersparameters () const
 
const hit::Node * getHitNode () const
 
bool hasBase () const
 
const std::string & getBase () const
 
const TgetParam (const std::string &name) const
 
std::vector< std::pair< T1, T2 > > getParam (const std::string &param1, const std::string &param2) const
 
const TqueryParam (const std::string &name) const
 
const TgetRenamedParam (const std::string &old_name, const std::string &new_name) const
 
T getCheckedPointerParam (const std::string &name, const std::string &error_string="") const
 
bool haveParameter (const std::string &name) const
 
bool isParamValid (const std::string &name) const
 
bool isParamSetByUser (const std::string &name) const
 
void connectControllableParams (const std::string &parameter, const std::string &object_type, const std::string &object_name, const std::string &object_parameter) const
 
void paramError (const std::string &param, Args... args) const
 
void paramWarning (const std::string &param, Args... args) const
 
void paramWarning (const std::string &param, Args... args) const
 
void paramInfo (const std::string &param, Args... args) const
 
std::string messagePrefix (const bool hit_prefix=true) const
 
std::string errorPrefix (const std::string &) const
 
void mooseError (Args &&... args) const
 
void mooseDocumentedError (const std::string &repo_name, const unsigned int issue_num, Args &&... args) const
 
void mooseErrorNonPrefixed (Args &&... args) const
 
void mooseWarning (Args &&... args) const
 
void mooseWarning (Args &&... args) const
 
void mooseWarningNonPrefixed (Args &&... args) const
 
void mooseWarningNonPrefixed (Args &&... args) const
 
void mooseDeprecated (Args &&... args) const
 
void mooseDeprecated (Args &&... args) const
 
void mooseDeprecatedNoTrace (Args &&... args) const
 
void mooseInfo (Args &&... args) const
 
void callMooseError (std::string msg, const bool with_prefix, const hit::Node *node=nullptr, const bool show_trace=true) const
 
std::string getDataFileName (const std::string &param) const
 
std::string getDataFileNameByName (const std::string &relative_path) const
 
std::string getDataFilePath (const std::string &relative_path) const
 
const Parallel::Communicator & comm () const
 
processor_id_type n_processors () const
 
processor_id_type processor_id () const
 

Static Public Member Functions

static InputParameters validParams ()
 
static void addDepletionIDParams (InputParameters &parameters)
 
static bool hasGenerateData (const InputParameters &params)
 
static bool hasGenerateCSG (const InputParameters &params)
 
static void callMooseError (MooseApp *const app, const InputParameters &params, std::string msg, const bool with_prefix, const hit::Node *node, const bool show_trace=true)
 
static void setHasGenerateData (InputParameters &params)
 
static void setHasGenerateCSG (InputParameters &params)
 

Public Attributes

 usingCombinedWarningSolutionWarnings
 
const ConsoleStream _console
 

Static Public Attributes

static const std::string data_only_param
 
static const std::string type_param
 
static const std::string name_param
 
static const std::string unique_name_param
 
static const std::string app_param
 
static const std::string moose_base_param
 
static const std::string kokkos_object_param
 
static constexpr auto SYSTEM
 
static constexpr auto NAME
 

Protected Types

enum  DepletionIDGenerationLevel { DepletionIDGenerationLevel::Pin, DepletionIDGenerationLevel::Assembly, DepletionIDGenerationLevel::Drum, DepletionIDGenerationLevel::Core }
 specify the depletion id is generated at which reactor generation level More...
 

Protected Member Functions

void generateMetadata ()
 Define metadata associated with ControlDrumMeshGenerator. More...
 
unsigned int getDrumIdxFromRadialIdx (const unsigned int radial_idx, const Real elem_x, const Real elem_y)
 Get drum index from radial index of mesh element, drum index is used to retrieve region ID and block names for each element. More...
 
unsigned int getElemIntegerFromMesh (MeshBase &input_mesh, std::string extra_int_name, bool should_exist=false)
 Initializes extra element integer from id name for a given mesh and throws an error if it should exist but cannot be found within the mesh. More...
 
void initializeReactorMeshParams (const std::string reactor_param_name)
 Initializes and checks validity of ReactorMeshParams mesh generator object. More...
 
void printReactorMetadata (const std::string geometry_type, const std::string mg_name, const bool first_function_call=true)
 Print metadata associated with ReactorGeometryMeshBuilder object. More...
 
void printCoreMetadata (const std::string mg_name, const bool first_function_call)
 Print core-level metadata associated with ReactorGeometryMeshBuilder object. More...
 
void printAssemblyMetadata (const std::string mg_name, const bool first_function_call)
 Print assembly-level metadata associated with ReactorGeometryMeshBuilder object. More...
 
void printPinMetadata (const std::string mg_name)
 Print pin-level metadata associated with ReactorGeometryMeshBuilder object. More...
 
void printGlobalReactorMetadata ()
 Print global ReactorMeshParams metadata associated with ReactorGeometryMeshBuilder object. More...
 
template<typename T >
void printMetadataToConsole (const std::string metadata_name, const std::string mg_name)
 Print metadata with provided name that can be found with given mesh generator name. More...
 
template<typename T >
void print2dMetadataToConsole (const std::string metadata_name, const std::string mg_name)
 Print metadata with data type std::vector<std::vector<T>> and provided name that can be found with given mesh generator name. More...
 
void freeReactorParamsMesh ()
 Releases the mesh obtained in _reactor_params_mesh. More...
 
void freeReactorParamsCSG ()
 Releases the CSG base object obtained in _reactor_params_csg. More...
 
template<typename T >
bool hasReactorParam (const std::string param_name)
 Checks whether parameter is defined in ReactorMeshParams metadata. More...
 
template<typename T >
const TgetReactorParam (const std::string &param_name)
 Returns reference of parameter in ReactorMeshParams object. More...
 
void updateElementBlockNameId (MeshBase &input_mesh, Elem *elem, std::map< std::string, SubdomainID > &name_id_map, std::string elem_block_name, SubdomainID &next_free_id)
 Updates the block names and ids of the element in an input mesh according to a map of block name to block ids. More...
 
MeshGeneratorName callExtrusionMeshSubgenerators (const MeshGeneratorName input_mesh_name)
 Calls mesh subgenerators related to extrusion, renaming of top / bottom boundaries, and defining plane IDs. More...
 
void addDepletionId (MeshBase &input_mesh, const MooseEnum &option, const DepletionIDGenerationLevel generation_level, const bool extrude)
 add depletion IDs More...
 
std::vector< std::reference_wrapper< const CSG::CSGSurface > > getOuterRadialSurfacesForUnitCell (unsigned int radial_index, Real halfpitch, CSG::CSGBase &csg_obj)
 Get CSGSurfaces corresponding to hexagonal or square region with given halfpitch and centered around (0, 0, 0) More...
 
std::vector< std::reference_wrapper< const CSG::CSGSurface > > getAxialPlaneSurfaces (CSG::CSGBase &csg_obj)
 Get CSGSurfaces corresponding to axial planes of the extruded RGMB mesh. More...
 
const CSG::CSGLatticecreateRGMBLattice (const Real pitch, const std::vector< std::vector< std::reference_wrapper< const CSG::CSGUniverse >>> pattern, CSG::CSGBase &csg_obj)
 Create CSG lattice for assembly and core lattices. More...
 
virtual std::unique_ptr< CSG::CSGBasegenerateCSG ()
 
TcopyMeshProperty (const std::string &target_data_name, const std::string &source_data_name, const std::string &source_mesh)
 
TcopyMeshProperty (const std::string &source_data_name, const std::string &source_mesh)
 
std::unique_ptr< MeshBase > & getMesh (const std::string &param_name, const bool allow_invalid=false)
 
std::vector< std::unique_ptr< MeshBase > *> getMeshes (const std::string &param_name)
 
std::unique_ptr< MeshBase > & getMeshByName (const MeshGeneratorName &mesh_generator_name)
 
std::vector< std::unique_ptr< MeshBase > *> getMeshesByName (const std::vector< MeshGeneratorName > &mesh_generator_names)
 
std::unique_ptr< CSG::CSGBase > & getCSGBase (const std::string &param_name)
 
std::unique_ptr< CSG::CSGBase > & getCSGBaseByName (const MeshGeneratorName &mesh_generator_name)
 
std::vector< std::unique_ptr< CSG::CSGBase > *> getCSGBases (const std::string &param_name)
 
std::vector< std::unique_ptr< CSG::CSGBase > *> getCSGBasesByName (const std::vector< MeshGeneratorName > &mesh_generator_names)
 
void declareMeshForSub (const std::string &param_name)
 
void declareMeshesForSub (const std::string &param_name)
 
void declareMeshForSubByName (const MeshGeneratorName &mesh_generator_name)
 
void declareMeshesForSubByName (const std::vector< MeshGeneratorName > &mesh_generator_names)
 
std::unique_ptr< MeshBase > buildMeshBaseObject (unsigned int dim=libMesh::invalid_uint)
 
std::unique_ptr< ReplicatedMesh > buildReplicatedMesh (unsigned int dim=libMesh::invalid_uint)
 
std::unique_ptr< DistributedMesh > buildDistributedMesh (unsigned int dim=libMesh::invalid_uint)
 
void addMeshSubgenerator (const std::string &type, const std::string &name, Ts... extra_input_parameters)
 
void addMeshSubgenerator (const std::string &type, const std::string &name, InputParameters params)
 
void declareNullMeshName (const MeshGeneratorName &name)
 
void flagInvalidSolutionInternal (const InvalidSolutionID invalid_solution_id) const
 
InvalidSolutionID registerInvalidSolutionInternal (const std::string &message, const bool warning) const
 
const TgetMeshProperty (const std::string &data_name, const std::string &prefix)
 
const TgetMeshProperty (const std::string &data_name)
 
bool hasMeshProperty (const std::string &data_name, const std::string &prefix) const
 
bool hasMeshProperty (const std::string &data_name, const std::string &prefix) const
 
bool hasMeshProperty (const std::string &data_name) const
 
bool hasMeshProperty (const std::string &data_name) const
 
std::string meshPropertyName (const std::string &data_name) const
 
TdeclareMeshProperty (const std::string &data_name, Args &&... args)
 
TdeclareMeshProperty (const std::string &data_name, const T &data_value)
 
TdeclareMeshProperty (const std::string &data_name, Args &&... args)
 
TdeclareMeshProperty (const std::string &data_name, const T &data_value)
 
TsetMeshProperty (const std::string &data_name, Args &&... args)
 
TsetMeshProperty (const std::string &data_name, const T &data_value)
 
TsetMeshProperty (const std::string &data_name, Args &&... args)
 
TsetMeshProperty (const std::string &data_name, const T &data_value)
 

Static Protected Member Functions

static std::string meshPropertyName (const std::string &data_name, const std::string &prefix)
 

Protected Attributes

std::string _geom_type
 The type of geometry that is being described (Square or Hex, declared in the ReactorMeshParams object) More...
 
unsigned int _mesh_dimensions
 The number of dimensions the mesh is ultimately going to have (2 or 3, declared in the ReactorMeshParams object) More...
 
const subdomain_id_type _assembly_type
 The id number for the type of the assembly. More...
 
const Real _drum_inner_radius
 The inner radius of drum region. More...
 
const Real _drum_outer_radius
 The outer radius of drum region. More...
 
const bool _extrude
 Whether this mesh should be extruded to 3-D, making it the final structure in the reactor mesh. More...
 
std::vector< std::vector< subdomain_id_type > > _region_ids
 2-D vector (axial outer indexing, radial inner indexing) used to set "region_id" extra-element integer of the control drum mesh elements More...
 
bool _has_block_names
 Whether block names have been provided by user. More...
 
std::vector< std::vector< std::string > > _block_names
 2-D vector (axial outer indexing, radial inner indexing) used to set block names of pin mesh elements More...
 
Real _pad_start_angle
 Starting angle of drum pad region. More...
 
Real _pad_end_angle
 Ending angle of drum pad region. More...
 
bool _has_pad_region
 Whether pad start and end angles are provided by user. More...
 
std::unique_ptr< MeshBase > * _build_mesh
 The final mesh that is generated by the subgenerators; This mesh is generated by the subgenerators with only element and boundary IDs changed. More...
 
MeshGeneratorName _reactor_params
 The ReactorMeshParams object that is storing the reactor global information for this reactor geometry mesh. More...
 
MooseMesh *const _mesh
 
const bool & _enabled
 
MooseApp_app
 
Factory_factory
 
ActionFactory_action_factory
 
const std::string & _type
 
const std::string & _name
 
const InputParameters_pars
 
const Parallel::Communicator & _communicator
 

Detailed Description

Mesh generator for defining a reactor control drum that can be used in a Cartesian or hexagonal lattice with the option to be 2-D or 3-D.

Definition at line 18 of file ControlDrumMeshGenerator.h.

Member Enumeration Documentation

◆ DepletionIDGenerationLevel

specify the depletion id is generated at which reactor generation level

Enumerator
Pin 
Assembly 
Drum 
Core 

Definition at line 263 of file ReactorGeometryMeshBuilderBase.h.

264  {
265  Pin,
266  Assembly,
267  Drum,
268  Core
269  };

Constructor & Destructor Documentation

◆ ControlDrumMeshGenerator()

ControlDrumMeshGenerator::ControlDrumMeshGenerator ( const InputParameters parameters)

Definition at line 92 of file ControlDrumMeshGenerator.C.

94  _assembly_type(getParam<subdomain_id_type>("assembly_type")),
95  _drum_inner_radius(getParam<Real>("drum_inner_radius")),
96  _drum_outer_radius(getParam<Real>("drum_outer_radius")),
97  _extrude(getParam<bool>("extrude")),
98  _region_ids(getParam<std::vector<std::vector<subdomain_id_type>>>("region_ids"))
99 {
100  // Initialize ReactorMeshParams object
101  initializeReactorMeshParams(getParam<MeshGeneratorName>("reactor_params"));
102 
103  // Flexible stitching needs to be invoked in order to create control drum mesh
104  if (!getReactorParam<bool>(RGMB::flexible_assembly_stitching))
105  mooseError("'flexible_assembly_stitching' needs to be set to true in ReactorMeshParams in "
106  "order to use ControlDrumMeshGenerator");
107 
108  _geom_type = getReactorParam<std::string>(RGMB::mesh_geometry);
109  _mesh_dimensions = getReactorParam<unsigned int>(RGMB::mesh_dimensions);
110 
111  const auto drum_inner_intervals = getParam<unsigned int>("drum_inner_intervals");
112  const auto drum_intervals = getParam<unsigned int>("drum_intervals");
113  const auto num_sectors = getParam<unsigned int>("num_azimuthal_sectors");
114  const auto assembly_pitch = getReactorParam<Real>(RGMB::assembly_pitch);
115 
116  // Check drum pad parameters
117  if (isParamSetByUser("pad_start_angle"))
118  {
119  _pad_start_angle = getParam<Real>("pad_start_angle");
120  if (!isParamSetByUser("pad_end_angle"))
121  paramError("pad_start_angle",
122  "If 'pad_start_angle' is set, 'pad_end_angle' needs to also be set.");
123  _pad_end_angle = getParam<Real>("pad_end_angle");
124 
126  paramError("pad_start_angle",
127  "The difference between 'pad_end_angle' and 'pad_start_angle' must be between 0 "
128  "and 360 exclusive.");
129  _has_pad_region = true;
130  }
131  else
132  {
133  if (isParamSetByUser("pad_end_angle"))
134  paramError("pad_end_angle",
135  "If 'pad_end_angle' is set, 'pad_start_angle' needs to also be set.");
136  _has_pad_region = false;
137  }
138 
139  // Error checking for azimuthal node tolerance
140  const auto azimuthal_node_tolerance = getParam<Real>("azimuthal_node_tolerance");
141  if (!_has_pad_region && isParamSetByUser("azimuthal_node_tolerance"))
142  paramError("azimuthal_node_tolerance",
143  "This parameter is relevant only when pad start and end angles are defined");
144  if (_has_pad_region && MooseUtils::absoluteFuzzyGreaterEqual(2. * azimuthal_node_tolerance,
145  360. / (Real)num_sectors))
146  paramError("azimuthal_node_tolerance",
147  "Azimuthal node tolerance should be smaller than half the azimuthal interval size "
148  "as defined by 'num_azimuthal_sectors'");
149  if (_has_pad_region && MooseUtils::absoluteFuzzyGreaterEqual(2. * azimuthal_node_tolerance,
151  paramError("azimuthal_node_tolerance",
152  "Azimuthal node tolerance should be smaller than half the difference of the pad "
153  "angle range");
154 
155  // Check region IDs have correct size
156  const unsigned int n_radial_regions = _has_pad_region ? 4 : 3;
157  unsigned int n_axial_levels =
158  (_mesh_dimensions == 3)
159  ? getReactorParam<std::vector<unsigned int>>(RGMB::axial_mesh_intervals).size()
160  : 1;
161  if (_region_ids.size() != n_axial_levels)
162  mooseError("The size of region IDs must be equal to the number of axial levels as defined in "
163  "the ReactorMeshParams object");
164  if (_region_ids[0].size() != n_radial_regions)
165  {
166  std::string err_msg =
167  "'region_ids' parameter does not have the correct number of elements per axial zone. ";
168  err_msg += _has_pad_region
169  ? "For control drums with a pad region, 4 radial IDs need to be provided per "
170  "axial zone (drum inner, drum pad, drum ex-pad, and drum outer)"
171  : "For control drums with no pad region, 3 radial IDs need to be provided per "
172  "axial zone (drum inner, drum, and drum outer)";
173  paramError("region_ids", err_msg);
174  }
175 
176  // Check block names have the correct size
177  if (isParamValid("block_names"))
178  {
179  if (getReactorParam<bool>(RGMB::region_id_as_block_name))
180  paramError("block_names",
181  "If ReactorMeshParams/region_id_as_block_name is set, block_names should not be "
182  "specified in ControlDrumMeshGenerator");
183  _has_block_names = true;
184  _block_names = getParam<std::vector<std::vector<std::string>>>("block_names");
185  if (_region_ids.size() != _block_names.size())
186  mooseError("The size of block_names must match the size of region_ids");
187  for (const auto i : index_range(_region_ids))
188  if (_region_ids[i].size() != _block_names[i].size())
189  mooseError("The size of block_names must match the size of region_ids");
190  }
191  else
192  _has_block_names = false;
193 
194  // Check extrusion parameters
195  if (_extrude && _mesh_dimensions != 3)
196  paramError("extrude",
197  "In order to extrude this mesh, ReactorMeshParams/dim needs to be set to 3\n");
198  if (_extrude && (!hasReactorParam<boundary_id_type>(RGMB::top_boundary_id) ||
199  !hasReactorParam<boundary_id_type>(RGMB::bottom_boundary_id)))
200  mooseError("Both top_boundary_id and bottom_boundary_id must be provided in ReactorMeshParams "
201  "if using extruded geometry");
202 
203  // Define azimuthal angles explicitly based on num_azimuthal_sectors and manually add pad start
204  // angle and end angle if they are not contained within these angle intervals
205  std::vector<Real> azimuthal_angles;
206  const auto custom_start_angle = _has_pad_region ? _pad_start_angle : 0.;
207  const auto custom_end_angle =
208  _has_pad_region ? ((_pad_end_angle > 360) ? _pad_end_angle - 360. : _pad_end_angle) : 0.;
209  for (unsigned int i = 0; i < num_sectors; ++i)
210  {
211  Real current_azim_angle = (Real)i * 360. / (Real)num_sectors;
212  Real next_azim_angle = (Real)(i + 1) * 360. / (Real)num_sectors;
213  if (!_has_pad_region)
214  azimuthal_angles.push_back(current_azim_angle);
215  else
216  {
217  // When pad regions are involved, check if the current azimuthal node angle coincides with
218  // pad start/end angle to within tolerance. If it does, then shift the azimuthal node location
219  // to match the pad angle location. If it does not and the pad angle falls within the
220  // azimuthal sector, then create an additional node for the pad location
221  if (MooseUtils::absoluteFuzzyLessEqual(std::abs(current_azim_angle - custom_start_angle),
222  azimuthal_node_tolerance))
223  {
224  azimuthal_angles.push_back(custom_start_angle);
225  }
226  else if (MooseUtils::absoluteFuzzyLessEqual(std::abs(current_azim_angle - custom_end_angle),
227  azimuthal_node_tolerance))
228  {
229  azimuthal_angles.push_back(custom_end_angle);
230  }
231  else if (MooseUtils::absoluteFuzzyGreaterThan(custom_start_angle - current_azim_angle,
232  azimuthal_node_tolerance) &&
233  MooseUtils::absoluteFuzzyGreaterThan(next_azim_angle - custom_start_angle,
234  azimuthal_node_tolerance))
235  {
236  mooseWarning("pad_start_angle not contained within drum azimuthal discretization so "
237  "additional azimuthal nodes are created to align mesh with this angle");
238  azimuthal_angles.push_back(current_azim_angle);
239  azimuthal_angles.push_back(custom_start_angle);
240  }
241  else if (MooseUtils::absoluteFuzzyGreaterThan(custom_end_angle - current_azim_angle,
242  azimuthal_node_tolerance) &&
243  MooseUtils::absoluteFuzzyGreaterThan(next_azim_angle - custom_end_angle,
244  azimuthal_node_tolerance))
245  {
246  mooseWarning("pad_end_angle not contained within drum azimuthal discretization so "
247  "additional azimuthal nodes are created to align mesh with this angle");
248  azimuthal_angles.push_back(current_azim_angle);
249  azimuthal_angles.push_back(custom_end_angle);
250  }
251  else
252  azimuthal_angles.push_back(current_azim_angle);
253  }
254  }
255 
256  // Check drum radius parameters
258  paramError("drum_outer_radius", "Drum outer radius must be larger than the inner radius");
259  // Check if volume preserved radius of outer radius exceeds assembly halfpitch. In data driven
260  // mode, radius is assumed not to need volume preservation
261  auto radius_corrfac =
262  getReactorParam<bool>(RGMB::bypass_meshgen)
263  ? 1.0
265  if (_drum_outer_radius * radius_corrfac >= assembly_pitch / 2.)
266  paramError("drum_outer_radius",
267  "Volume-corrected outer radius of drum region must be smaller than half the "
268  "assembly pitch as "
269  "defined by 'ReactorMeshParams/assembly_pitch'");
270 
271  // No subgenerators will be called if option to bypass mesh generators is enabled
272  if (!getReactorParam<bool>(RGMB::bypass_meshgen))
273  {
274  const std::string block_name_prefix =
276 
277  {
278  // Invoke AdvancedConcentricCircleGenerator to define drum mesh without background region
279  auto params = _app.getFactory().getValidParams("AdvancedConcentricCircleGenerator");
280 
281  params.set<std::vector<Real>>("customized_azimuthal_angles") = azimuthal_angles;
282  params.set<std::vector<double>>("ring_radii") = {_drum_inner_radius, _drum_outer_radius};
283  params.set<std::vector<unsigned int>>("ring_intervals") = {drum_inner_intervals,
284  drum_intervals};
285  if (drum_inner_intervals > 1)
286  {
287  params.set<std::vector<subdomain_id_type>>("ring_block_ids") = {
291  params.set<std::vector<SubdomainName>>("ring_block_names") = {
292  block_name_prefix + "_R0_TRI", block_name_prefix + "_R0", block_name_prefix + "_R1"};
293  }
294  else
295  {
296  params.set<std::vector<subdomain_id_type>>("ring_block_ids") = {
298  params.set<std::vector<SubdomainName>>("ring_block_names") = {block_name_prefix + "_R0",
299  block_name_prefix + "_R1"};
300  }
301  params.set<bool>("create_outward_interface_boundaries") = false;
302 
303  addMeshSubgenerator("AdvancedConcentricCircleGenerator", name() + "_accg", params);
304  }
305  {
306  // Invoke FlexiblePatternGenerator to triangulate drum background region
307  auto params = _app.getFactory().getValidParams("FlexiblePatternGenerator");
308 
309  params.set<std::vector<MeshGeneratorName>>("inputs") = {name() + "_accg"};
310  params.set<std::vector<libMesh::Point>>("extra_positions") = {libMesh::Point(0, 0, 0)};
311  params.set<std::vector<unsigned int>>("extra_positions_mg_indices") = {0};
312  params.set<bool>("use_auto_area_func") = true;
313  // `verify_holes` is set to false to prevent false positive instances of points outside of
314  // defined holes, which can create test failures on certain dev environments
315  params.set<bool>("verify_holes") = false;
316  params.set<MooseEnum>("boundary_type") = (_geom_type == "Hex") ? "HEXAGON" : "CARTESIAN";
317  params.set<unsigned int>("boundary_sectors") =
318  getReactorParam<unsigned int>(RGMB::num_sectors_flexible_stitching);
319  params.set<Real>("boundary_size") = assembly_pitch;
320  params.set<boundary_id_type>("external_boundary_id") =
322  params.set<BoundaryName>("external_boundary_name") =
324  params.set<SubdomainName>("background_subdomain_name") = block_name_prefix + "_R2_TRI";
325  params.set<subdomain_id_type>("background_subdomain_id") = RGMB::CONTROL_DRUM_BLOCK_ID_OUTER;
326 
327  addMeshSubgenerator("FlexiblePatternGenerator", name() + "_fpg", params);
328 
329  // Pass mesh meta-data defined in subgenerator constructor to this MeshGenerator
330  copyMeshProperty<bool>("is_control_drum_meta", name() + "_fpg");
331  copyMeshProperty<Real>("pattern_pitch_meta", name() + "_fpg");
332  }
333  std::string build_mesh_name = name() + "_delbds";
334  {
335  // Invoke BoundaryDeletionGenerator to delete extra sidesets created by
336  // AdvancedConcentricCircleGenerator
337  auto params = _app.getFactory().getValidParams("BoundaryDeletionGenerator");
338 
339  params.set<MeshGeneratorName>("input") = name() + "_fpg";
340  params.set<std::vector<BoundaryName>>("boundary_names") = {"0", "2"};
341 
342  addMeshSubgenerator("BoundaryDeletionGenerator", build_mesh_name, params);
343  }
344  if (_extrude && _mesh_dimensions == 3)
345  build_mesh_name = callExtrusionMeshSubgenerators(build_mesh_name);
346 
347  // Store final mesh subgenerator
348  _build_mesh = &getMeshByName(build_mesh_name);
349  }
350 
352 }
std::unique_ptr< MeshBase > & getMeshByName(const MeshGeneratorName &mesh_generator_name)
const bool _extrude
Whether this mesh should be extruded to 3-D, making it the final structure in the reactor mesh...
void paramError(const std::string &param, Args... args) const
const T & getParam(const std::string &name) const
static const std::string region_id_as_block_name
const SubdomainName DRUM_BLOCK_NAME_PREFIX
const subdomain_id_type CONTROL_DRUM_BLOCK_ID_PAD
const InputParameters & parameters() const
T & set(const std::string &name, bool quiet_mode=false)
std::unique_ptr< MeshBase > * _build_mesh
The final mesh that is generated by the subgenerators; This mesh is generated by the subgenerators wi...
static constexpr boundary_id_type ASSEMBLY_BOUNDARY_ID_START
static const std::string mesh_geometry
void initializeReactorMeshParams(const std::string reactor_param_name)
Initializes and checks validity of ReactorMeshParams mesh generator object.
InputParameters getValidParams(const std::string &name) const
const subdomain_id_type CONTROL_DRUM_BLOCK_ID_OUTER
std::string _geom_type
The type of geometry that is being described (Square or Hex, declared in the ReactorMeshParams object...
static const std::string assembly_pitch
Factory & getFactory()
const T & getReactorParam(const std::string &param_name)
Returns reference of parameter in ReactorMeshParams object.
const std::string & name() const
int8_t boundary_id_type
static const std::string mesh_dimensions
void addMeshSubgenerator(const std::string &type, const std::string &name, Ts... extra_input_parameters)
MeshGeneratorName callExtrusionMeshSubgenerators(const MeshGeneratorName input_mesh_name)
Calls mesh subgenerators related to extrusion, renaming of top / bottom boundaries, and defining plane IDs.
std::vector< std::vector< std::string > > _block_names
2-D vector (axial outer indexing, radial inner indexing) used to set block names of pin mesh elements...
bool _has_pad_region
Whether pad start and end angles are provided by user.
static const std::string top_boundary_id
ReactorGeometryMeshBuilderBase(const InputParameters &parameters)
const Real _drum_outer_radius
The outer radius of drum region.
const subdomain_id_type CONTROL_DRUM_BLOCK_ID_INNER_TRI
bool _has_block_names
Whether block names have been provided by user.
static const std::string flexible_assembly_stitching
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
MooseApp & _app
const subdomain_id_type CONTROL_DRUM_BLOCK_ID_INNER
static const std::string axial_mesh_intervals
void generateMetadata()
Define metadata associated with ControlDrumMeshGenerator.
void mooseWarning(Args &&... args) const
void mooseError(Args &&... args) const
const subdomain_id_type _assembly_type
The id number for the type of the assembly.
const BoundaryName ASSEMBLY_BOUNDARY_NAME_PREFIX
Real _pad_start_angle
Starting angle of drum pad region.
bool isParamValid(const std::string &name) const
static const std::string bypass_meshgen
unsigned int _mesh_dimensions
The number of dimensions the mesh is ultimately going to have (2 or 3, declared in the ReactorMeshPar...
Real radiusCorrectionFactor(const std::vector< Real > &azimuthal_list, const bool full_circle=true, const unsigned int order=1, const bool is_first_value_vertex=true)
Makes radial correction to preserve ring area.
static const std::string num_sectors_flexible_stitching
bool isParamSetByUser(const std::string &name) const
auto index_range(const T &sizable)
static const std::string bottom_boundary_id
Real _pad_end_angle
Ending angle of drum pad region.
const Real _drum_inner_radius
The inner radius of drum region.
std::vector< std::vector< subdomain_id_type > > _region_ids
2-D vector (axial outer indexing, radial inner indexing) used to set "region_id" extra-element intege...

Member Function Documentation

◆ addDepletionId()

void ReactorGeometryMeshBuilderBase::addDepletionId ( MeshBase &  input_mesh,
const MooseEnum option,
const DepletionIDGenerationLevel  generation_level,
const bool  extrude 
)
protectedinherited

add depletion IDs

Parameters
input_meshinput mesh
optionoption for specifying level of details
generation_leveldepletion id is generated at which reactor generator level
extrudewhether input mesh is extruded, if false, assume that input mesh is defined in 2D and do not use 'plane_id` in depletion id generation

Definition at line 130 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::generate(), generate(), and CoreMeshGenerator::generate().

134 {
135  // prepare set of extra elem ids for depletion ID generation
136  std::vector<ExtraElementIDName> id_names = {};
137  if (extrude)
138  id_names.push_back("plane_id");
139  if (generation_level == DepletionIDGenerationLevel::Core)
140  {
141  if (option == "pin")
142  id_names.insert(id_names.end(), {"assembly_id", "pin_id"});
143  else if (option == "pin_type")
144  id_names.insert(id_names.end(), {"assembly_id", "pin_type_id"});
145  else if (option == "assembly")
146  id_names.push_back("assembly_id");
147  else if (option == "assembly_type")
148  id_names.push_back("assembly_type_id");
149  }
150  else if (generation_level == DepletionIDGenerationLevel::Assembly)
151  {
152  if (option == "pin")
153  id_names.push_back("pin_id");
154  else if (option == "pin_type")
155  id_names.push_back("pin_type_id");
156  else
157  paramError("depletion_id_type",
158  "'assembly_id' or 'assembly_type_id' is not allowed in depletion ID generation at "
159  "assembly level");
160  }
161  else if (generation_level == DepletionIDGenerationLevel::Drum)
162  {
163  if (option == "pin_type")
164  id_names.push_back("pin_type_id");
165  else
166  paramError("depletion_id_type",
167  "Only 'pin_type' is allowed in depletion ID generation at "
168  "drum level");
169  }
170  else if (generation_level == DepletionIDGenerationLevel::Pin)
171  mooseError("Depletion ID generation is not supported at pin level yet in RGMB");
172  id_names.push_back("region_id");
173  // no block restriction
174  std::set<SubdomainID> block_ids = {};
175  // create depletion IDs
176  // depletion IDs will be assigned in the following order:
177  // regions (materials) within pin -> pins in assembly -> assemblies in core -> axial planes
178  std::unordered_map<dof_id_type, dof_id_type> depl_ids =
179  MooseMeshUtils::getExtraIDUniqueCombinationMap(input_mesh, block_ids, id_names);
180  // assign depletion ids to elements
181  const auto depl_id_index = input_mesh.add_elem_integer("depletion_id");
182  for (Elem * const elem : input_mesh.active_element_ptr_range())
183  elem->set_extra_integer(depl_id_index, depl_ids.at(elem->id()));
184 }
std::unordered_map< dof_id_type, dof_id_type > getExtraIDUniqueCombinationMap(const MeshBase &mesh, const std::set< SubdomainID > &block_ids, std::vector< ExtraElementIDName > extra_ids)
void paramError(const std::string &param, Args... args) const
void mooseError(Args &&... args) const

◆ addDepletionIDParams()

void ReactorGeometryMeshBuilderBase::addDepletionIDParams ( InputParameters parameters)
staticinherited

Definition at line 35 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::validParams(), validParams(), and CoreMeshGenerator::validParams().

36 {
37  params.addParam<bool>(
38  "generate_depletion_id", false, "Determine wheter the depletion ID is assigned.");
39  MooseEnum depletion_id_option("assembly assembly_type pin pin_type");
40  params.addParam<MooseEnum>("depletion_id_type",
41  depletion_id_option,
42  "Determine level of details in depletion ID assignment.");
43  params.addParamNamesToGroup("generate_depletion_id depletion_id_type", "Depletion ID assignment");
44 }

◆ callExtrusionMeshSubgenerators()

MeshGeneratorName ReactorGeometryMeshBuilderBase::callExtrusionMeshSubgenerators ( const MeshGeneratorName  input_mesh_name)
protectedinherited

Calls mesh subgenerators related to extrusion, renaming of top / bottom boundaries, and defining plane IDs.

Parameters
input_mesh_namename of input 2D mesh generator to extrude
Returns
name of final output 3D mesh generator

Definition at line 187 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::AssemblyMeshGenerator(), ControlDrumMeshGenerator(), CoreMeshGenerator::CoreMeshGenerator(), and PinMeshGenerator::PinMeshGenerator().

189 {
190  std::vector<Real> axial_boundaries = getReactorParam<std::vector<Real>>(RGMB::axial_mesh_sizes);
191  const auto top_boundary = getReactorParam<boundary_id_type>(RGMB::top_boundary_id);
192  const auto bottom_boundary = getReactorParam<boundary_id_type>(RGMB::bottom_boundary_id);
193 
194  {
195  auto params = _app.getFactory().getValidParams("AdvancedExtruderGenerator");
196 
197  params.set<MeshGeneratorName>("input") = input_mesh_name;
198  params.set<Point>("direction") = Point(0, 0, 1);
199  params.set<std::vector<unsigned int>>("num_layers") =
200  getReactorParam<std::vector<unsigned int>>(RGMB::axial_mesh_intervals);
201  params.set<std::vector<Real>>("heights") = axial_boundaries;
202  params.set<BoundaryName>("bottom_boundary") = std::to_string(bottom_boundary);
203  params.set<BoundaryName>("top_boundary") = std::to_string(top_boundary);
204  addMeshSubgenerator("AdvancedExtruderGenerator", name() + "_extruded", params);
205  }
206 
207  {
208  auto params = _app.getFactory().getValidParams("RenameBoundaryGenerator");
209 
210  params.set<MeshGeneratorName>("input") = name() + "_extruded";
211  params.set<std::vector<BoundaryName>>("old_boundary") = {
212  std::to_string(top_boundary),
213  std::to_string(bottom_boundary)}; // hard coded boundary IDs in patterned mesh generator
214  params.set<std::vector<BoundaryName>>("new_boundary") = {"top", "bottom"};
215  addMeshSubgenerator("RenameBoundaryGenerator", name() + "_change_plane_name", params);
216  }
217 
218  const MeshGeneratorName output_mesh_name = name() + "_extrudedIDs";
219  {
220  auto params = _app.getFactory().getValidParams("PlaneIDMeshGenerator");
221 
222  params.set<MeshGeneratorName>("input") = name() + "_change_plane_name";
223 
224  std::vector<Real> plane_heights{0};
225  for (Real z : axial_boundaries)
226  plane_heights.push_back(z + plane_heights.back());
227 
228  params.set<std::vector<Real>>("plane_coordinates") = plane_heights;
229 
230  std::string plane_id_name = "plane_id";
231  params.set<std::string>("id_name") = "plane_id";
232 
233  addMeshSubgenerator("PlaneIDMeshGenerator", output_mesh_name, params);
234  }
235 
236  return output_mesh_name;
237 }
T & set(const std::string &name, bool quiet_mode=false)
InputParameters getValidParams(const std::string &name) const
static const std::string axial_mesh_sizes
Factory & getFactory()
const T & getReactorParam(const std::string &param_name)
Returns reference of parameter in ReactorMeshParams object.
const std::string & name() const
void addMeshSubgenerator(const std::string &type, const std::string &name, Ts... extra_input_parameters)
static const std::string top_boundary_id
MooseApp & _app
static const std::string axial_mesh_intervals
static const std::string bottom_boundary_id

◆ createRGMBLattice()

const CSG::CSGLattice & ReactorGeometryMeshBuilderBase::createRGMBLattice ( const Real  pitch,
const std::vector< std::vector< std::reference_wrapper< const CSG::CSGUniverse >>>  pattern,
CSG::CSGBase csg_obj 
)
protectedinherited

Create CSG lattice for assembly and core lattices.

This method does not set the outer universe of the lattice

Parameters
pitchlattice pitch
patternpattern of universes in the lattice
csg_objreference to CSGBase object

Definition at line 311 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::generateCSG(), and CoreMeshGenerator::generateCSG().

315 {
316  // Create lattice based on whether it is hexagonal or Cartesian
317  std::string lat_name = name() + "_lattice";
318  std::unique_ptr<CSG::CSGLattice> lat_ptr;
319  const auto mesh_geometry = getReactorParam<std::string>(RGMB::mesh_geometry);
320  if (mesh_geometry == "Square")
321  lat_ptr = std::make_unique<CSG::CSGCartesianLattice>(lat_name, pitch, pattern);
322  else // _geom_type == "Hex"
323  lat_ptr = std::make_unique<CSG::CSGHexagonalLattice>(lat_name, pitch, pattern);
324 
325  auto & assembly_lattice = csg_obj.addLattice(std::move(lat_ptr));
326  return assembly_lattice;
327 }
static const std::string assembly_lattice
static const std::string mesh_geometry
const std::string & name() const
static const std::string pitch
const LatticeType & addLattice(std::unique_ptr< LatticeType > lattice)
assign the same reporting IDs for all tiles in the pattern with same input

◆ freeReactorParamsCSG()

void ReactorGeometryMeshBuilderBase::freeReactorParamsCSG ( )
protectedinherited

Releases the CSG base object obtained in _reactor_params_csg.

This must be called in any object that derives from this one, because the MeshGenerator system requires that all meshes that are requested from the system are moved out of the MeshGenerator system and into the MeshGenerator that requests them. In our case, we move it into this MeshGenerator and then release (delete) it.

Definition at line 81 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::generateCSG(), PinMeshGenerator::generateCSG(), and CoreMeshGenerator::generateCSG().

82 {
83  _reactor_params_csg->reset();
84 }
std::unique_ptr< CSG::CSGBase > * _reactor_params_csg

◆ freeReactorParamsMesh()

void ReactorGeometryMeshBuilderBase::freeReactorParamsMesh ( )
protectedinherited

Releases the mesh obtained in _reactor_params_mesh.

This must be called in any object that derives from this one, because the MeshGenerator system requires that all meshes that are requested from the system are moved out of the MeshGenerator system and into the MeshGenerator that requests them. In our case, we move it into this MeshGenerator and then release (delete) it.

Definition at line 75 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::generate(), PinMeshGenerator::generate(), generate(), and CoreMeshGenerator::generate().

76 {
77  _reactor_params_mesh->reset();
78 }
std::unique_ptr< MeshBase > * _reactor_params_mesh
The dummy param mesh that we need to clear once we&#39;ve generated (in freeReactorMeshParams) ...

◆ generate()

std::unique_ptr< MeshBase > ControlDrumMeshGenerator::generate ( )
overridevirtual

Implements MeshGenerator.

Definition at line 374 of file ControlDrumMeshGenerator.C.

375 {
376  // Must be called to free the ReactorMeshParams mesh
378 
379  // If bypass_mesh is true, return a null mesh. In this mode, an output mesh is not
380  // generated and only metadata is defined on the generator, so logic related to
381  // generation of output mesh will not be called
382  if (getReactorParam<bool>(RGMB::bypass_meshgen))
383  {
384  auto null_mesh = nullptr;
385  return null_mesh;
386  }
387 
388  // This generate() method will be called once the subgenerators that we depend on are
389  // called. This is where we reassign subdomain ids/name in case they were merged when
390  // stitching pins into an assembly. This is also where we set region_id and
391  // assembly_type_id element integers.
392 
393  // Define all extra element names and integers
394  std::string plane_id_name = "plane_id";
395  std::string region_id_name = "region_id";
396  std::string pin_type_id_name = "pin_type_id";
397  std::string assembly_type_id_name = "assembly_type_id";
398  const std::string default_block_name =
400 
401  auto pin_type_id_int = getElemIntegerFromMesh(*(*_build_mesh), pin_type_id_name);
402  auto region_id_int = getElemIntegerFromMesh(*(*_build_mesh), region_id_name);
403  auto assembly_type_id_int = getElemIntegerFromMesh(*(*_build_mesh), assembly_type_id_name);
404 
405  unsigned int plane_id_int = 0;
406  if (_extrude)
407  plane_id_int = getElemIntegerFromMesh(*(*_build_mesh), plane_id_name, true);
408 
409  // Get next free block ID in mesh in case subdomain ids need to be remapped
410  auto next_block_id = MooseMeshUtils::getNextFreeSubdomainID(*(*(_build_mesh)));
411  std::map<std::string, SubdomainID> rgmb_name_id_map;
412 
413  // Loop through all mesh elements and set region ids and reassign block IDs/names
414  // if they were merged during pin stitching
415  for (auto & elem : (*_build_mesh)->active_element_ptr_range())
416  {
417  elem->set_extra_integer(assembly_type_id_int, _assembly_type);
418  const dof_id_type z_id = _extrude ? elem->get_extra_integer(plane_id_int) : 0;
419 
420  // Assembly peripheral element (background / duct), set subdomains according
421  // to user preferences and set pin type id to RGMB::MAX_PIN_TYPE_ID - peripheral index
422  // Region id is inferred from z_id and peripheral_idx
423  const auto base_block_id = elem->subdomain_id();
424  const auto base_block_name = (*_build_mesh)->subdomain_name(base_block_id);
425 
426  // Check if block name has correct prefix
427  std::string prefix = RGMB::DRUM_BLOCK_NAME_PREFIX + std::to_string(_assembly_type) + "_R";
428  if (!(base_block_name.find(prefix, 0) == 0))
429  continue;
430 
431  // Radial index is integer value of substring after prefix
432  const unsigned int radial_idx = std::stoi(base_block_name.substr(prefix.length()));
433 
434  // Drum index distinguishes between elements in pad and ex-pad regions that have the same radial
435  // index
436  const unsigned int drum_idx =
437  getDrumIdxFromRadialIdx(radial_idx, elem->true_centroid()(0), elem->true_centroid()(1));
439  elem->set_extra_integer(pin_type_id_int, pin_type);
440 
441  const auto elem_rid = _region_ids[z_id][drum_idx];
442  elem->set_extra_integer(region_id_int, elem_rid);
443 
444  // Set element block name and block id
445  auto elem_block_name = default_block_name;
446  if (getReactorParam<bool>(RGMB::region_id_as_block_name))
447  elem_block_name += "_REG" + std::to_string(elem_rid);
448  else if (_has_block_names)
449  elem_block_name += "_" + _block_names[z_id][drum_idx];
450  if (elem->type() == TRI3 || elem->type() == PRISM6)
451  elem_block_name += RGMB::TRI_BLOCK_NAME_SUFFIX;
453  *(*_build_mesh), elem, rgmb_name_id_map, elem_block_name, next_block_id);
454  }
455 
456  if (getParam<bool>("generate_depletion_id"))
457  {
458  const MooseEnum option = getParam<MooseEnum>("depletion_id_type");
460  }
461 
462  // Mark mesh as not prepared, as block ID's were re-assigned in this method
463  (*_build_mesh)->unset_is_prepared();
464 
465  return std::move(*_build_mesh);
466 }
void updateElementBlockNameId(MeshBase &input_mesh, Elem *elem, std::map< std::string, SubdomainID > &name_id_map, std::string elem_block_name, SubdomainID &next_free_id)
Updates the block names and ids of the element in an input mesh according to a map of block name to b...
const bool _extrude
Whether this mesh should be extruded to 3-D, making it the final structure in the reactor mesh...
static const std::string region_id_as_block_name
const SubdomainName DRUM_BLOCK_NAME_PREFIX
unsigned int getElemIntegerFromMesh(MeshBase &input_mesh, std::string extra_int_name, bool should_exist=false)
Initializes extra element integer from id name for a given mesh and throws an error if it should exis...
std::unique_ptr< MeshBase > * _build_mesh
The final mesh that is generated by the subgenerators; This mesh is generated by the subgenerators wi...
void addDepletionId(MeshBase &input_mesh, const MooseEnum &option, const DepletionIDGenerationLevel generation_level, const bool extrude)
add depletion IDs
static const std::string pin_type
const SubdomainName TRI_BLOCK_NAME_SUFFIX
TRI3
std::vector< std::vector< std::string > > _block_names
2-D vector (axial outer indexing, radial inner indexing) used to set block names of pin mesh elements...
void freeReactorParamsMesh()
Releases the mesh obtained in _reactor_params_mesh.
bool _has_block_names
Whether block names have been provided by user.
unsigned int getDrumIdxFromRadialIdx(const unsigned int radial_idx, const Real elem_x, const Real elem_y)
Get drum index from radial index of mesh element, drum index is used to retrieve region ID and block ...
const subdomain_id_type _assembly_type
The id number for the type of the assembly.
static const std::string bypass_meshgen
PRISM6
SubdomainID getNextFreeSubdomainID(MeshBase &input_mesh)
const subdomain_id_type MAX_PIN_TYPE_ID
uint8_t dof_id_type
std::vector< std::vector< subdomain_id_type > > _region_ids
2-D vector (axial outer indexing, radial inner indexing) used to set "region_id" extra-element intege...

◆ generateData()

void ReactorGeometryMeshBuilderBase::generateData ( )
inlineoverridevirtualinherited

Reimplemented from MeshGenerator.

Definition at line 119 of file ReactorGeometryMeshBuilderBase.h.

119 {};

◆ generateMetadata()

void ControlDrumMeshGenerator::generateMetadata ( )
protected

Define metadata associated with ControlDrumMeshGenerator.

Definition at line 355 of file ControlDrumMeshGenerator.C.

Referenced by ControlDrumMeshGenerator().

356 {
357  // Declare metadata for use in downstream mesh generators
359  declareMeshProperty(RGMB::pitch, getReactorParam<Real>(RGMB::assembly_pitch));
364  std::vector<Real> drum_pad_angles =
365  _has_pad_region ? std::vector<Real>({_pad_start_angle, _pad_end_angle}) : std::vector<Real>();
367  std::vector<Real> drum_radii = std::vector<Real>({_drum_inner_radius, _drum_outer_radius});
371 }
static const std::string drum_radii
static const std::string assembly_type
const bool _extrude
Whether this mesh should be extruded to 3-D, making it the final structure in the reactor mesh...
static const std::string is_single_pin
static const std::string assembly_pitch
static const std::string drum_block_names
static const std::string extruded
static const std::string drum_pad_angles
std::vector< std::vector< std::string > > _block_names
2-D vector (axial outer indexing, radial inner indexing) used to set block names of pin mesh elements...
static const std::string pitch
bool _has_pad_region
Whether pad start and end angles are provided by user.
const Real _drum_outer_radius
The outer radius of drum region.
static const std::string is_homogenized
static const std::string is_control_drum
const subdomain_id_type _assembly_type
The id number for the type of the assembly.
Real _pad_start_angle
Starting angle of drum pad region.
T & declareMeshProperty(const std::string &data_name, Args &&... args)
static const std::string drum_region_ids
unsigned int _mesh_dimensions
The number of dimensions the mesh is ultimately going to have (2 or 3, declared in the ReactorMeshPar...
Real _pad_end_angle
Ending angle of drum pad region.
const Real _drum_inner_radius
The inner radius of drum region.
std::vector< std::vector< subdomain_id_type > > _region_ids
2-D vector (axial outer indexing, radial inner indexing) used to set "region_id" extra-element intege...

◆ getAxialPlaneSurfaces()

std::vector< std::reference_wrapper< const CSG::CSGSurface > > ReactorGeometryMeshBuilderBase::getAxialPlaneSurfaces ( CSG::CSGBase csg_obj)
protectedinherited

Get CSGSurfaces corresponding to axial planes of the extruded RGMB mesh.

Parameters
csg_objReference to CSGBase object for adding defined surfaces to
Returns
vector of surfaces that correspond to axial planes of extruded RGMB mesh

Definition at line 279 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::generateCSG(), PinMeshGenerator::generateCSG(), and CoreMeshGenerator::generateCSG().

280 {
281  std::vector<std::reference_wrapper<const CSG::CSGSurface>> surfaces_by_axial_region;
282  const auto axial_boundaries = getReactorParam<std::vector<Real>>(RGMB::axial_mesh_sizes);
283  Real axial_level = 0.;
284 
285  // Check if axial planes have been defined in CSGBase based on a surface name we expect
286  // to find
287  auto axial_surf_name = RGMB::CSG_AXIAL_PLANE_PREFIX + "0";
288  const auto has_axial_surfaces = csg_obj.hasSurface(axial_surf_name);
289 
290  for (const auto i : make_range(axial_boundaries.size() + 1))
291  {
292  axial_surf_name = RGMB::CSG_AXIAL_PLANE_PREFIX + std::to_string(i);
293  if (has_axial_surfaces)
294  // Surface should exist in CSGBase, retrieve from object
295  surfaces_by_axial_region.push_back(csg_obj.getSurfaceByName(axial_surf_name));
296  else
297  {
298  // Surface has not been defined, create it and add to CSGBase
299  axial_level += (i != 0) ? axial_boundaries[i - 1] : 0.;
300  std::unique_ptr<CSG::CSGSurface> plane_surf_ptr =
301  std::make_unique<CSG::CSGPlane>(axial_surf_name, 0, 0, 1, axial_level);
302  const auto & plane_surf = csg_obj.addSurface(std::move(plane_surf_ptr));
303  surfaces_by_axial_region.push_back(plane_surf);
304  }
305  }
306 
307  return surfaces_by_axial_region;
308 }
static const std::string CSG_AXIAL_PLANE_PREFIX
const CSGSurface & getSurfaceByName(const std::string &name) const
static const std::string axial_mesh_sizes
const CSGSurface & addSurface(std::unique_ptr< CSGSurface > surf)
bool hasSurface(const std::string &name) const
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
IntRange< T > make_range(T beg, T end)

◆ getDrumIdxFromRadialIdx()

unsigned int ControlDrumMeshGenerator::getDrumIdxFromRadialIdx ( const unsigned int  radial_idx,
const Real  elem_x,
const Real  elem_y 
)
protected

Get drum index from radial index of mesh element, drum index is used to retrieve region ID and block names for each element.

Definition at line 469 of file ControlDrumMeshGenerator.C.

Referenced by generate().

472 {
473  // By default, drum index will match radial index unless a pad region is defined
474  unsigned int drum_idx = radial_idx;
475  if (_has_pad_region)
476  {
477  if (radial_idx == 1)
478  {
479  // This is an element in the drum region, use drum angle to determine whether it belongs to
480  // pad or ex-pad region Note: drum angle of 0 degrees starts in positive y-direction and
481  // increments in clockwise direction, which is consistent
482  // with how AdvancedConcentricCircleMeshGenerator defines azimuthal angles
483  Real drum_angle = std::atan2(elem_x, elem_y) * 180. / M_PI;
484  if (drum_angle < 0)
485  drum_angle += 360;
486 
487  // If _pad_end_angle does not exceed 360 degrees, check if drum angle lies within
488  // _pad_start_angle and _pad_end_angle. Drum index needs to be incremented if element in
489  // ex-pad region
490  if (_pad_end_angle <= 360)
491  {
492  if ((drum_angle < _pad_start_angle) || (drum_angle > _pad_end_angle))
493  ++drum_idx;
494  }
495  else
496  {
497  // If _pad_end_angle exceeds 360 degrees, check two intervals - _pad_start_angle to 360, and
498  // 0 to _pad_end_angle - 360 Drum index needs to be incremented if element in ex-pad region
499  if ((drum_angle < _pad_start_angle) && (drum_angle > _pad_end_angle - 360.))
500  ++drum_idx;
501  }
502  }
503  else if (radial_idx == 2)
504  {
505  // Element is in outer drum region, drum index needs to be incremented to account for presence
506  // of ex-pad region
507  ++drum_idx;
508  }
509  }
510  return drum_idx;
511 }
bool _has_pad_region
Whether pad start and end angles are provided by user.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
Real _pad_start_angle
Starting angle of drum pad region.
Real _pad_end_angle
Ending angle of drum pad region.

◆ getElemIntegerFromMesh()

unsigned int ReactorGeometryMeshBuilderBase::getElemIntegerFromMesh ( MeshBase &  input_mesh,
std::string  extra_int_name,
bool  should_exist = false 
)
protectedinherited

Initializes extra element integer from id name for a given mesh and throws an error if it should exist but cannot be found within the mesh.

Parameters
input_meshinput mesh
extra_int_nameextra element id name
should_existwhether extra element integer should already exist in mesh
Returns
extra element integer

Definition at line 87 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::generate(), PinMeshGenerator::generate(), generate(), and CoreMeshGenerator::generate().

90 {
91  if (input_mesh.has_elem_integer(extra_int_name))
92  return input_mesh.get_elem_integer_index(extra_int_name);
93  else
94  {
95  if (should_exist)
96  mooseError("Expected extruded mesh to have " + extra_int_name + " extra integers");
97  else
98  return input_mesh.add_elem_integer(extra_int_name);
99  }
100 }
void mooseError(Args &&... args) const

◆ getOuterRadialSurfacesForUnitCell()

std::vector< std::reference_wrapper< const CSG::CSGSurface > > ReactorGeometryMeshBuilderBase::getOuterRadialSurfacesForUnitCell ( unsigned int  radial_index,
Real  halfpitch,
CSG::CSGBase csg_obj 
)
protectedinherited

Get CSGSurfaces corresponding to hexagonal or square region with given halfpitch and centered around (0, 0, 0)

Parameters
radial_indexRadial index of hex / square region, for surface naming
halfpitchHalfpitch of square or hexagon
csg_objReference to CSGBase object for adding defined surfaces to
Returns
vector of surfaces that correspond to hexagonal or square region

Definition at line 240 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::generateCSG(), and PinMeshGenerator::generateCSG().

243 {
244  std::vector<std::reference_wrapper<const CSG::CSGSurface>> duct_surfaces;
245  const auto mesh_geometry = getReactorParam<std::string>(RGMB::mesh_geometry);
246  const auto n_azim_surfaces = mesh_geometry == "Square" ? 4 : 6;
247 
248  // Convert halfpitch to radius (distance from vertex to center)
249  const Real angle_offset_degrees = mesh_geometry == "Square" ? 45. : 30.;
250  const Real angle_offset_radians = angle_offset_degrees * (M_PI / 180.);
251  const auto radius = halfpitch / std::cos(angle_offset_radians);
252 
253  Real angle_increment_radians = 360. / n_azim_surfaces * (M_PI / 180.);
254 
255  for (const auto i : make_range(n_azim_surfaces))
256  {
257  const auto surf_name =
258  name() + "_radial_duct_" + std::to_string(radial_index) + "_surf_" + std::to_string(i);
259 
260  // Define 3 points on the surface
261  const auto current_angle = i * angle_increment_radians + angle_offset_radians;
262  const auto next_angle = (i + 1) * angle_increment_radians + angle_offset_radians;
263  libMesh::Point p0(radius * std::cos(current_angle), radius * std::sin(current_angle), 0.);
264  libMesh::Point p1(radius * std::cos(next_angle), radius * std::sin(next_angle), 0.);
265  libMesh::Point p2 = (p0 + p1) / 2.;
266  // Place third point above the two others to form a vertical plane
267  p2(2) = angle_offset_degrees;
268 
269  std::unique_ptr<CSG::CSGSurface> duct_surf_ptr =
270  std::make_unique<CSG::CSGPlane>(surf_name, p0, p1, p2);
271  const auto & duct_surf = csg_obj.addSurface(std::move(duct_surf_ptr));
272  duct_surfaces.push_back(duct_surf);
273  }
274 
275  return duct_surfaces;
276 }
static const std::string mesh_geometry
const std::string & name() const
const CSGSurface & addSurface(std::unique_ptr< CSGSurface > surf)
const double radius
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
IntRange< T > make_range(T beg, T end)

◆ getReactorParam()

template<typename T >
const T & ReactorGeometryMeshBuilderBase::getReactorParam ( const std::string &  param_name)
protectedinherited

Returns reference of parameter in ReactorMeshParams object.

Template Parameters
Tdatatype of metadata value associated with metadata name
Parameters
param_namename of ReactorMeshParams parameter
Returns
reference to parameter defined in ReactorMeshParams metadata

Definition at line 330 of file ReactorGeometryMeshBuilderBase.h.

Referenced by AssemblyMeshGenerator::AssemblyMeshGenerator(), ReactorGeometryMeshBuilderBase::callExtrusionMeshSubgenerators(), ControlDrumMeshGenerator(), PinMeshGenerator::generateMetadata(), and PinMeshGenerator::PinMeshGenerator().

331 {
332  return getMeshProperty<T>(param_name, _reactor_params);
333 }
MeshGeneratorName _reactor_params
The ReactorMeshParams object that is storing the reactor global information for this reactor geometry...

◆ hasReactorParam()

template<typename T >
bool ReactorGeometryMeshBuilderBase::hasReactorParam ( const std::string  param_name)
protectedinherited

Checks whether parameter is defined in ReactorMeshParams metadata.

Template Parameters
Tdatatype of metadata value associated with metadata name
Parameters
param_namename of ReactorMeshParams parameter
Returns
whether parameter is defined in ReactorMeshParams metadata

Definition at line 323 of file ReactorGeometryMeshBuilderBase.h.

324 {
325  return hasMeshProperty<T>(param_name, _reactor_params);
326 }
MeshGeneratorName _reactor_params
The ReactorMeshParams object that is storing the reactor global information for this reactor geometry...

◆ initializeReactorMeshParams()

void ReactorGeometryMeshBuilderBase::initializeReactorMeshParams ( const std::string  reactor_param_name)
protectedinherited

Initializes and checks validity of ReactorMeshParams mesh generator object.

Parameters
reactor_param_namename of ReactorMeshParams mesh generator

Definition at line 52 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::AssemblyMeshGenerator(), ControlDrumMeshGenerator(), CoreMeshGenerator::CoreMeshGenerator(), and PinMeshGenerator::PinMeshGenerator().

53 {
54  _reactor_params = reactor_param_name;
55 
56  // Ensure that the user has supplied a valid ReactorMeshParams object
57  _reactor_params_mesh = &getMeshByName(reactor_param_name);
59  mooseError("The reactor_params mesh is not of the correct type");
60 
61  if (!hasMeshProperty<unsigned int>("mesh_dimensions", _reactor_params) ||
62  !hasMeshProperty<std::string>("mesh_geometry", _reactor_params))
63  mooseError("The reactor_params input must be a ReactorMeshParams type MeshGenerator\n Please "
64  "check that a valid definition and name of ReactorMeshParams has been provided.");
65 
66  // Set reactor_params_name metadata for use by future mesh generators
67  declareMeshProperty("reactor_params_name", std::string(_reactor_params));
68 
69  // Store CSGBase object if we are in CSG only mode
72 }
std::unique_ptr< MeshBase > & getMeshByName(const MeshGeneratorName &mesh_generator_name)
std::unique_ptr< MeshBase > * _reactor_params_mesh
The dummy param mesh that we need to clear once we&#39;ve generated (in freeReactorMeshParams) ...
bool getCSGOnly() const
MeshGeneratorName _reactor_params
The ReactorMeshParams object that is storing the reactor global information for this reactor geometry...
MooseApp & _app
std::unique_ptr< CSG::CSGBase > * _reactor_params_csg
void mooseError(Args &&... args) const
std::unique_ptr< CSG::CSGBase > & getCSGBaseByName(const MeshGeneratorName &mesh_generator_name)
T & declareMeshProperty(const std::string &data_name, Args &&... args)
MeshGeneratorSystem & getMeshGeneratorSystem()

◆ print2dMetadataToConsole()

template<typename T >
void ReactorGeometryMeshBuilderBase::print2dMetadataToConsole ( const std::string  metadata_name,
const std::string  mg_name 
)
protectedinherited

Print metadata with data type std::vector<std::vector<T>> and provided name that can be found with given mesh generator name.

Template Parameters
Tdatatype of elements in 2-D vector to output
Parameters
metadata_nameName of metadata to output
mg_nameName of mesh generator that stores metadata

◆ printAssemblyMetadata()

void ReactorGeometryMeshBuilderBase::printAssemblyMetadata ( const std::string  mg_name,
const bool  first_function_call 
)
protectedinherited

Print assembly-level metadata associated with ReactorGeometryMeshBuilder object.

Parameters
mg_namename of mesh generator associated with assembly
whetherthis is the original function call, which will trigger additional output messages

◆ printCoreMetadata()

void ReactorGeometryMeshBuilderBase::printCoreMetadata ( const std::string  mg_name,
const bool  first_function_call 
)
protectedinherited

Print core-level metadata associated with ReactorGeometryMeshBuilder object.

Parameters
mg_namename of mesh generator associated with core
first_function_callwhether this is the original function call, which will trigger additional output messages

◆ printGlobalReactorMetadata()

void ReactorGeometryMeshBuilderBase::printGlobalReactorMetadata ( )
protectedinherited

Print global ReactorMeshParams metadata associated with ReactorGeometryMeshBuilder object.

◆ printMetadataToConsole()

template<typename T >
void ReactorGeometryMeshBuilderBase::printMetadataToConsole ( const std::string  metadata_name,
const std::string  mg_name 
)
protectedinherited

Print metadata with provided name that can be found with given mesh generator name.

Template Parameters
Tdatatype of metadata value to output
Parameters
metadata_nameName of metadata to output
mg_nameName of mesh generator that stores metadata

◆ printPinMetadata()

void ReactorGeometryMeshBuilderBase::printPinMetadata ( const std::string  mg_name)
protectedinherited

Print pin-level metadata associated with ReactorGeometryMeshBuilder object.

Parameters
mg_namename of mesh generator associated with assembly

◆ printReactorMetadata()

void ReactorGeometryMeshBuilderBase::printReactorMetadata ( const std::string  geometry_type,
const std::string  mg_name,
const bool  first_function_call = true 
)
protectedinherited

Print metadata associated with ReactorGeometryMeshBuilder object.

Parameters
geometry_typetype of geometry (pin / assembly / core) under consideration
mg_namename of mesh generator associated with this object
first_function_callwhether this is the original function call, which will trigger additional output messages

◆ updateElementBlockNameId()

void ReactorGeometryMeshBuilderBase::updateElementBlockNameId ( MeshBase &  input_mesh,
Elem *  elem,
std::map< std::string, SubdomainID > &  name_id_map,
std::string  elem_block_name,
SubdomainID next_free_id 
)
protectedinherited

Updates the block names and ids of the element in an input mesh according to a map of block name to block ids.

Updates the map if the block name is not in the map

Parameters
input_nameinput mesh
elemiterator to mesh element
name_id_mapmap of name-id pairs used in mesh
elem_block_nameblock name to set for element
next_free_idnext free block id to use if block name does not exist in map

Definition at line 103 of file ReactorGeometryMeshBuilderBase.C.

Referenced by AssemblyMeshGenerator::generate(), PinMeshGenerator::generate(), generate(), and CoreMeshGenerator::generate().

109 {
110  SubdomainID elem_block_id;
111  if (name_id_map.find(elem_block_name) == name_id_map.end())
112  {
113  // Block name does not exist in mesh yet, assign new block id and name
114  elem_block_id = next_free_id++;
115  elem->subdomain_id() = elem_block_id;
116  input_mesh.subdomain_name(elem_block_id) = elem_block_name;
117  name_id_map[elem_block_name] = elem_block_id;
118  }
119  else
120  {
121  // Block name exists in mesh, reuse block id
122  elem_block_id = name_id_map[elem_block_name];
123  elem->subdomain_id() = elem_block_id;
124  }
125 
126  input_mesh.unset_has_cached_elem_data();
127 }
subdomain_id_type SubdomainID

◆ validParams()

InputParameters ControlDrumMeshGenerator::validParams ( )
static

Definition at line 23 of file ControlDrumMeshGenerator.C.

24 {
26 
27  params.addRequiredParam<MeshGeneratorName>(
28  "reactor_params",
29  "The ReactorMeshParams MeshGenerator that is the basis for this component mesh.");
30  params.addRequiredParam<subdomain_id_type>(
31  "assembly_type",
32  "The assembly type integer ID to use for this control drum definition. "
33  "This parameter should be uniquely defined for each ControlDrumMeshGenerator "
34  "and AssemblyMeshGenerator structure in the RGMB workflow.");
35  params.addParam<bool>("extrude",
36  false,
37  "Determines if this is the final step in the geometry construction"
38  " and extrudes the 2D geometry to 3D. If this is true then this mesh "
39  "cannot be used in further mesh building in the Reactor workflow");
40  params.addRequiredRangeCheckedParam<Real>(
41  "drum_inner_radius", "drum_inner_radius>0", "Inner radius of drum region");
42  params.addRequiredRangeCheckedParam<Real>(
43  "drum_outer_radius", "drum_outer_radius>0", "Outer radius of drum region");
44  params.addRangeCheckedParam<unsigned int>(
45  "drum_inner_intervals",
46  1,
47  "drum_inner_intervals>0",
48  "Number of radial mesh intervals in region up to inner drum radius");
49  params.addRangeCheckedParam<unsigned int>(
50  "drum_intervals", 1, "drum_intervals>0", "Number of radial mesh intervals in drum region");
51  params.addRangeCheckedParam<Real>("pad_start_angle",
52  "pad_start_angle>=0 & pad_start_angle < 360",
53  "Starting angle of drum pad region");
54  params.addRangeCheckedParam<Real>(
55  "pad_end_angle", "pad_end_angle>0 & pad_end_angle < 720", "Ending angle of drum pad region");
56  params.addRequiredRangeCheckedParam<unsigned int>(
57  "num_azimuthal_sectors",
58  "num_azimuthal_sectors>2",
59  "Number of azimuthal sectors to sub-divide the drum region into");
60  params.addRequiredParam<std::vector<std::vector<subdomain_id_type>>>(
61  "region_ids",
62  "IDs for each radial and axial zone for assignment of region_id extra element "
63  "id. "
64  "Inner indexing is radial zones (drum inner/drum/drum outer), outer indexing is axial");
65  params.addParam<std::vector<std::vector<std::string>>>(
66  "block_names",
67  "Block names for each radial and axial zone. "
68  "Inner indexing is radial zones (drum inner/drum/drum outer), outer indexing is axial");
69  params.addParam<Real>("azimuthal_node_tolerance",
70  0.1,
71  "(in degrees) The absolute tolerance for which to shift an azimuthal node "
72  "to match the pad start/end angles");
73 
74  params.addParamNamesToGroup("region_ids assembly_type", "ID assigment");
75  params.addParamNamesToGroup("drum_inner_radius drum_outer_radius drum_inner_intervals "
76  "drum_intervals num_azimuthal_sectors",
77  "Drum specifications");
78  params.addParamNamesToGroup("pad_start_angle pad_end_angle azimuthal_node_tolerance",
79  "Control pad specifications");
80 
81  params.addClassDescription(
82  "This ControlDrumMeshGenerator object is designed to generate "
83  "drum-like structures, with IDs, from a reactor geometry. "
84  "These structures can be used directly within CoreMeshGenerator to stitch"
85  "control drums into a core lattice alongside AssemblyMeshGenerator structures");
86  // depletion id generation params are added
87  addDepletionIDParams(params);
88 
89  return params;
90 }
static void addDepletionIDParams(InputParameters &parameters)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real

Member Data Documentation

◆ _assembly_type

const subdomain_id_type ControlDrumMeshGenerator::_assembly_type
protected

The id number for the type of the assembly.

Definition at line 42 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), generate(), and generateMetadata().

◆ _block_names

std::vector<std::vector<std::string> > ControlDrumMeshGenerator::_block_names
protected

2-D vector (axial outer indexing, radial inner indexing) used to set block names of pin mesh elements

Definition at line 60 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), generate(), and generateMetadata().

◆ _build_mesh

std::unique_ptr<MeshBase>* ControlDrumMeshGenerator::_build_mesh
protected

The final mesh that is generated by the subgenerators; This mesh is generated by the subgenerators with only element and boundary IDs changed.

Definition at line 73 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), and generate().

◆ _drum_inner_radius

const Real ControlDrumMeshGenerator::_drum_inner_radius
protected

The inner radius of drum region.

Definition at line 45 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), and generateMetadata().

◆ _drum_outer_radius

const Real ControlDrumMeshGenerator::_drum_outer_radius
protected

The outer radius of drum region.

Definition at line 48 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), and generateMetadata().

◆ _extrude

const bool ControlDrumMeshGenerator::_extrude
protected

Whether this mesh should be extruded to 3-D, making it the final structure in the reactor mesh.

Definition at line 51 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), generate(), and generateMetadata().

◆ _geom_type

std::string ControlDrumMeshGenerator::_geom_type
protected

The type of geometry that is being described (Square or Hex, declared in the ReactorMeshParams object)

Definition at line 36 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator().

◆ _has_block_names

bool ControlDrumMeshGenerator::_has_block_names
protected

Whether block names have been provided by user.

Definition at line 57 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), and generate().

◆ _has_pad_region

bool ControlDrumMeshGenerator::_has_pad_region
protected

Whether pad start and end angles are provided by user.

Definition at line 69 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), generateMetadata(), and getDrumIdxFromRadialIdx().

◆ _mesh_dimensions

unsigned int ControlDrumMeshGenerator::_mesh_dimensions
protected

The number of dimensions the mesh is ultimately going to have (2 or 3, declared in the ReactorMeshParams object)

Definition at line 39 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), and generateMetadata().

◆ _pad_end_angle

Real ControlDrumMeshGenerator::_pad_end_angle
protected

Ending angle of drum pad region.

Definition at line 66 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), generateMetadata(), and getDrumIdxFromRadialIdx().

◆ _pad_start_angle

Real ControlDrumMeshGenerator::_pad_start_angle
protected

Starting angle of drum pad region.

Definition at line 63 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), generateMetadata(), and getDrumIdxFromRadialIdx().

◆ _reactor_params

MeshGeneratorName ReactorGeometryMeshBuilderBase::_reactor_params
protectedinherited

The ReactorMeshParams object that is storing the reactor global information for this reactor geometry mesh.

Definition at line 261 of file ReactorGeometryMeshBuilderBase.h.

Referenced by ReactorGeometryMeshBuilderBase::getReactorParam(), ReactorGeometryMeshBuilderBase::hasReactorParam(), and ReactorGeometryMeshBuilderBase::initializeReactorMeshParams().

◆ _region_ids

std::vector<std::vector<subdomain_id_type> > ControlDrumMeshGenerator::_region_ids
protected

2-D vector (axial outer indexing, radial inner indexing) used to set "region_id" extra-element integer of the control drum mesh elements

Definition at line 54 of file ControlDrumMeshGenerator.h.

Referenced by ControlDrumMeshGenerator(), generate(), and generateMetadata().


The documentation for this class was generated from the following files: