https://mooseframework.inl.gov
TriInterWrapperBaseIC.C
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 #include "TriInterWrapperBaseIC.h"
11 #include "TriInterWrapperMesh.h"
12 #include "FEProblemBase.h"
13 
16 {
18 }
19 
21  : InitialCondition(params), _mesh(getMesh(_fe_problem.mesh()))
22 {
23 }
24 
27 {
28  TriInterWrapperMesh * m = dynamic_cast<TriInterWrapperMesh *>(&mesh);
29  if (m)
30  return dynamic_cast<TriInterWrapperMesh &>(mesh);
31  else
32  mooseError(name(),
33  ": This initial condition works only with triangular subchannel geometry. Update "
34  "your input file to use TriInterWrapperMesh in the mesh block.");
35 }
T & getMesh(MooseMesh &mesh)
function to cast mesh
Definition: SCM.h:35
MeshBase & mesh
static InputParameters validParams()
static InputParameters validParams()
virtual const std::string & name() const
TriInterWrapperMesh & getMesh(MooseMesh &mesh)
Check that mesh is TriInterWrapperMesh and if not, report an error.
TriInterWrapperBaseIC(const InputParameters &params)
void mooseError(Args &&... args) const
Mesh class for triangular, edge and corner inter_wrappers for hexagonal lattice fuel assemblies...