https://mooseframework.inl.gov
SCMMassFlowRateIC.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 "SCMMassFlowRateIC.h"
11 
12 registerMooseObject("SubChannelApp", SCMMassFlowRateIC);
13 registerMooseObjectRenamed("SubChannelApp", MassFlowRateIC, "06/30/2025 24:00", SCMMassFlowRateIC);
14 
17 {
19  params.addClassDescription(
20  "Computes mass float rate from specified mass flux and cross-sectional area");
21  params.addRequiredCoupledVar("area", "Subchannel surface area [m^2]");
22  params.addRequiredParam<Real>("mass_flux", "Specified mass flux [kg/s-m^2]");
23  return params;
24 }
25 
27  : InitialCondition(parameters),
28  _mass_flux(getParam<Real>("mass_flux")),
29  _area(coupledValue("area"))
30 {
31 }
32 
33 Real
34 SCMMassFlowRateIC::value(const Point & /*p*/)
35 {
36  return _mass_flux * _area[_qp];
37 }
registerMooseObject("SubChannelApp", SCMMassFlowRateIC)
static InputParameters validParams()
Computes mass flow rate from specified mass flux and cross-sectional area.
static InputParameters validParams()
void addRequiredParam(const std::string &name, const std::string &doc_string)
const VariableValue & _area
Cross-sectional area.
SCMMassFlowRateIC(const InputParameters &parameters)
void addRequiredCoupledVar(const std::string &name, const std::string &doc_string)
registerMooseObjectRenamed("SubChannelApp", MassFlowRateIC, "06/30/2025 24:00", SCMMassFlowRateIC)
const Real & _mass_flux
Specified mass flux.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
void addClassDescription(const std::string &doc_string)
virtual Real value(const Point &p) override