Advanced Meshing Examples
After learning about some of the advanced meshing tools, it is useful to see examples of "what's possible". This chapter contains images and small snippet examples of "what's possible".
Possible Advanced Reactor Geometries
This tutorial covers the generation of mostly standard geometries, but many reactor designs involve features which were not covered previously. Using the tools covered in this section, MOOSE can generate quite complex geometries illustrated here. The key mesh generators required are listed briefly.
Molten Salt Reactor Experiment (MSRE) 2D lattice
PolygonConcentricCircleMeshGenerator is utilized for producing circular and triangular-shaped regions within the lattice.
FillBetweenSidesetsGenerator is employed for generating mesh to fill in the regions between the regions generated by PolygonConcentricCircleMeshGenerator.

Figure 1: Molten Salt Reactor Experiment (MSRE) 2D lattice.
KRUSTY heat-pipe cooled microreactor 2D core
ParsedCurveGenerator is used for creating the outline of complex shapes before mesh generation.
XYDelaunayGenerator is employed for meshing the irregular areas.
PeripheralTriangleMeshGenerator is utilized to add layers of triangular mesh onto an existing circular mesh.
CircularBoundaryCorrectionGenerator is used to adjust a discretized circle to match the true circle's volume.

Figure 2: KRUSTY heat pipe-cooled microreactor 2D core.
Modular High Temperature Gas Cooled Reactor (MHTGR)
PolygonConcentricCircleMeshGenerator and PatternedHexMeshGenerator generate pins and assemblies
XYDelaunayGenerator generates control rod holes and reflector assemblies
StitchedMeshGenerator merges control rod holes with fuel and reflector assemblies
HexagonConcentricCircleAdaptiveBoundaryMeshGenerator generates ducts for reflector assembly that can be stitched with other assembles.
PatternedHexMeshGenerator generates a lattice of fuel and reflector assemblies into the core
PeripheralRingMeshGenerator adds a circular boundary surrounding the core
AdvancedExtruderGenerator performs 2D to 3D extrusion for the core
DepletionIDGenerator sets up assembly-wise depletion zones

Figure 3: MHTGR 2D mesh.

Figure 4: MHTGR 2D mesh, zoomed in.
2D Pebble Bed Reactor with Streamlines
FillBetweenPointVectorsGenerator generates pebble bed streamlines
CartesianMeshGenerator and FillBetweenSidesetsGenerator generates rectangular meshes and trapezoid meshes
StitchedMeshGenerator merges core components
CombinerGenerator combines outer walls of core barrel and RPV

Figure 5: 2D generic pebble bed reactor meshes for Pronghorn (left) and Griffin (right) with flow streamlines from top inlet to bottom conical outlet.
Boundary Layers and Biasing
During the mesh refinement process, it is common to require finer discretizations in one region and coarser discretizations in another region. The boundary layer and biasing features available in the Reactor Module allow the user to refine the mesh in areas of interest for the physics problem at hand.
Mesh Biasing
Mesh biasing applies non-uniform meshing subintervals within a specific region. For example, a fuel pin may generally require an axial meshing size of 5 cm, but at the very top and bottom of the active fuel zone where the power shape has a larger gradient, the user may require finer grids. This is possible using mesh biasing parameters available in AdvancedExtruderGenerator.

Figure 6: A 3D mesh generated by extruding a 2D square mesh using AdvancedExtruderGenerator with axial biasing in the top (green) and bottom (white) axial blocks.
Listing 1: Axial mesh biasing example.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/ax_bias.i)Similarly, the user may want to radially bias the mesh where solution gradients are known to be high, for example at the edge of a fuel pin or control rod. This is possible using mesh biasing parameters in PolygonConcentricCircleMeshGenerator as well as PeripheralRingMeshGenerator.

Figure 7: A hexagonal pin mesh generated by PolygonConcentricCircleMeshGenerator with radial biasing in both the outmost ring block (red) and background block (blue).
Listing 2: Radial mesh biasing example.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/rad_bias_pccmg.i)
Figure 8: A peripheral ring mesh with radial biasing added to a hexagonal pin mesh.
Listing 3: Peripheral ring radial mesh biasing example.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/rad_bias_prmg.i)Mesh Boundary Layers
Boundary layers are commonly needed in thermal-hydraulic applications, where the thickness of the mesh near a wall must be a certain size, uniformly, regardless of the width of the meshed region. Boundary layers are possible using PolygonConcentricCircleMeshGenerator and PeripheralRingMeshGenerator.

Figure 9: A hexagonal pin mesh generated by PolygonConcentricCircleMeshGenerator with boundary layers created in both the outmost ring block (outer boundary layer, red) and background block (inner boundary layer, blue).
Listing 4: PolygonConcentricCircleMeshGenerator boundary layer example.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/bdry_layer_pccmg.i)Stitching Assemblies with Different Pin Numbers
Typical reactor cores are comprised of many different assembly types, each with different numbers of pins. When the pins are explicitly meshed, the number of nodes on the assembly boundary is determined by a combination of the number pins as well as the pin azimuthal discretization. It is difficult to find a reasonably low azimuthal discretization for each assembly such that all assemblies have the same number of nodes on their boundaries.
The best approach for this situation is to use PatternedHexPeripheralModifier to strip the outermost layer off each assembly and replace it with a transition layer with a set number of nodes on the outermost boundary. Doing this to each assembly will ensure that all assemblies have the same number of boundary nodes and can be easily stitched. An example follows.

Figure 10: PatternedHexPeripheralModifier is used to adjust the boundary node count on each assembly to be consistent with each other and therefore stitchable.
Listing 5: Assemblies with different pin numbers example.
(modules/reactor/test/tests/meshgenerators/patterned_hex_peripheral_modifier/patterned.i)Oversized Pin
Some assemblies contain an oversized pin which intrudes on neighboring unit pin cells. Here, we describe one possible approach to mesh this situation.
First, define the regular small fuel pins and place them into the assembly as a full lattice. Next, delete the dummy unit pin cells, making sure to assign the newly created hole boundary a specific boundary name.
Separately, the oversized pin should be defined as its own object, remembering to remove the background region which is created by default in PolygonConcentricCircleMeshGenerator. This mesh will serve as the "hole" for XYDelaunayGenerator.
Finally, XYDelaunayGenerator is used to mesh the regions between the assembly (with deleted dummies) and the oversized pin. This is done by giving XYDelaunayGenerator the assembly mesh and the oversized pin mesh and specifying via input parameters that the region between the assembly mesh and the oversized pin mesh should be triangulated. The oversized pin mesh is placed into the geometry at this time as well.

Figure 11: An assembly mesh with an oversized pin in the center. The mesh is generated by modifying the output of PatternedHexMeshGenerator by replacing the central region with a mesh generated by XYDelaunayGenerator.
Listing 6: Oversized pin example.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/oversize.i)Filling Between Curves using "FillBetweenSidesetsGenerator"
The MSRE 2D lattice case pictured in tutorial04-adv_ex_fbsg was constructed using the FillBetweenSidesetsGenerator to connect "quarter" circular pins, as shown in tutorial04-adv_ex_fbsg. First, ConcentricCircleMeshGenerator (a predecessor of PolygonConcentricCircleMeshGenerator which has a different set of input options and works only for square pin cells) was used to create two quarter pins. Each quarter pin mesh initially contains two duplicate "quarter pin" shaped blocks, and then one of the duplicate blocks is deleted in order to be able to label the sideset on the curved boundary as curve_1
and curve_2
in the two pins, respectively. This is the simplest possible procedure with the current Mesh system in MOOSE, but could be improved in the future. These two pins were translated in space to move them apart from each other, and then FillBetweenSidesetsGenerator was used to mesh the area between curve_1
and curve_2
.

Figure 12: An example of using FillBetweenSidesetsGenerator to connect quarter circular-shapedsquare meshes.
Triangulation of Odd-Shaped Regions Using "ParsedCurveGenerator" and "XYDelaunayGenerator"
This example demonstrates how to place a control drum object in an arbitrary position in a core that may overlap subdomain boundaries.
First, the center assembly is created using regular pins and procedures.

Figure 13: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, patterned pins.
Listing 8: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, patterned pins.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/pcg_xyd.i)Next, two circular peripheral regions are added using PeripheralTriangleMeshGenerator (yellow, purple zones).

Figure 14: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, patterned pins with rings.
Listing 9: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, patterned pins with rings.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/pcg_xyd.i)Next, the complex boundary shape which is the outer edge of the light blue zone is defined using ParsedCurveGenerator and analytic piecewise functions. The interior of this boundary is then filled in, including the center assembly, using XYDelaunayGenerator.

Figure 15: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, patterned pins with irregular peripheral region.
Listing 10: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, patterned pins with irregular peripheral region.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/pcg_xyd.i)The control drum object is defined including the absorber arc using PolygonConcentricCircleMeshGenerator and AzimuthalBlockSplitGenerator, then the background region of the control drum is deleted to leave only the circular part. This mesh is then translated into the desired position of the final mesh using TransformGenerator. The small red pin is defined similarly (not requiring AzimuthalBlockSplitGenerator).

Figure 16: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, three holes for XYDelaunayGenerator.
Listing 11: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, three holes for XYDelaunayGenerator.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/pcg_xyd.i)The outer boundary of the dark blue zone is then generated using ParsedCurveGenerator and analytical functions. XYDelaunayGenerator is again used to fill the dark blue regions, keeping the light blue region and assembly, control drum, and small pin.

Figure 17: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, second XYDelaunayGenerator.
Listing 12: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, second XYDelaunayGenerator.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/pcg_xyd.i)Finally, a circular peripheral region is added at the end using PeripheralTriangleMeshGenerator (yellow).

Figure 18: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, complete.
Listing 13: An example of using XYDelaunayGenerator with curve meshes generated by ParsedCurveGenerator, complete.
(tutorials/tutorial04_meshing/app/test/tests/adv_examples/pcg_xyd.i)