14 #include "libmesh/edge_edge2.h" 15 #include "libmesh/unstructured_mesh.h" 24 "lattice subchannel arrangement");
37 _n_channels(other_mesh._n_channels),
38 _n_gaps(other_mesh._n_gaps),
39 _n_assemblies(other_mesh._n_assemblies),
40 _side_bypass_length(other_mesh._side_bypass_length),
41 _nodes(other_mesh._nodes),
42 _gapnodes(other_mesh._gapnodes),
43 _gap_to_chan_map(other_mesh._gap_to_chan_map),
44 _chan_to_gap_map(other_mesh._chan_to_gap_map),
45 _chan_to_pin_map(other_mesh._chan_to_pin_map),
46 _pin_to_chan_map(other_mesh._pin_to_chan_map),
47 _sign_id_crossflow_map(other_mesh._sign_id_crossflow_map),
48 _gij_map(other_mesh._gij_map),
49 _pin_mesh_exist(other_mesh._pin_mesh_exist)
52 mooseError(
name(),
": The number of assemblies cannot be less than 1 in both directions. ");
55 std::unique_ptr<MooseMesh>
89 i = std::min(i, (
int)(
_nx - 1));
92 j = std::min(
j, (
int)(
_ny - 1));
104 return j * (
_nx - 1) + i;
116 i = std::min(i, (
int)(
_nx - 2));
119 j = std::min(
j, (
int)(
_ny - 2));
121 return j * (
_nx - 1) + i;
126 unsigned int nx,
unsigned int ny, Real
pitch, Real elev, std::vector<Point> & pin_centers)
128 mooseAssert(nx >= 2,
"Number of channels in x-direction must be 2 or more.");
129 mooseAssert(ny >= 2,
"Number of channels in y-direction must be 2 or more.");
133 for (
unsigned int iy = 0; iy < ny - 1; iy++)
134 for (
unsigned int ix = 0; ix < nx - 1; ix++)
135 pin_centers.push_back(Point(
pitch * ix - offset_x,
pitch * iy - offset_y, elev));
static InputParameters validParams()
Base class for inter-wrapper meshes.
static InputParameters validParams()
unsigned int getPinIndexFromPoint(const Point &p) const override
Return a pin index for a given physical point p
virtual unsigned int channelIndex(const Point &point) const override
virtual std::unique_ptr< MooseMesh > safeClone() const override
virtual const std::string & name() const
unsigned int _nx
Number of assemblies in the -x direction.
std::unique_ptr< T > copyConstruct(const T &object)
virtual void buildMesh() override
virtual unsigned int pinIndex(const Point &p) const override
unsigned int getSubchannelIndexFromPoint(const Point &p) const override
Return a inter-wrapper index for a given physical point p
static const std::string pitch
QuadInterWrapperMesh(const InputParameters ¶meters)
Creates the mesh of an inter-wrapper around square assemblies.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
unsigned int _ny
Number of assemblies in the -y direction.
void mooseError(Args &&... args) const
static const std::complex< double > j(0, 1)
Complex number "j" (also known as "i")
registerMooseObject("SubChannelApp", QuadInterWrapperMesh)
Real _assembly_pitch
Distance between neighboring assemblies.
static void generatePinCenters(unsigned int nx, unsigned int ny, Real pitch, Real elev, std::vector< Point > &pin_centers)
Generate pin centers.