Line data Source code
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 "TriSubChannelBaseIC.h" 11 : #include "TriSubChannelMesh.h" 12 : #include "FEProblemBase.h" 13 : 14 : InputParameters 15 930 : TriSubChannelBaseIC::validParams() 16 : { 17 930 : return InitialCondition::validParams(); 18 : } 19 : 20 478 : TriSubChannelBaseIC::TriSubChannelBaseIC(const InputParameters & params) 21 478 : : InitialCondition(params), _mesh(getMesh(_fe_problem.mesh())) 22 : { 23 478 : } 24 : 25 : const TriSubChannelMesh & 26 478 : TriSubChannelBaseIC::getMesh(const MooseMesh & mesh) const 27 : { 28 478 : const auto m = dynamic_cast<const TriSubChannelMesh *>(&mesh); 29 478 : if (m) 30 478 : return dynamic_cast<const TriSubChannelMesh &>(mesh); 31 : else 32 0 : mooseError(name(), 33 : ": This initial condition works only with triangular subchannel geometry. Update " 34 : "your input file to use TriSubChannelMesh in the mesh block."); 35 : }