https://mooseframework.inl.gov
ADFlowJunctionFlux1Phase.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 
12 
13 registerMooseObject("ThermalHydraulicsApp", ADFlowJunctionFlux1Phase);
14 
17 {
19 
20  params.addRequiredParam<unsigned int>("connection_index", "Index of the connected flow channel");
21  params.addRequiredParam<std::string>("junction", "Junction component name");
22  MooseEnum equation("mass=0 momentum=1 energy=2");
24  "equation", equation, "Equation for which to query flux vector");
25 
26  params.addClassDescription(
27  "Retrieves an entry of a flux vector for a connection attached to a 1-phase junction");
28 
29  return params;
30 }
31 
33  : SideIntegralPostprocessor(parameters),
34 
35  _connection_index(getParam<unsigned int>("connection_index")),
36  _junction_name(getParam<std::string>("junction")),
37  _junction_uo_name(_junction_name + ":junction_uo"),
38  _junction_uo(getUserObjectByName<ADFlowJunctionUserObject>(_junction_uo_name)),
39  _equation_index(getParam<MooseEnum>("equation"))
40 {
41 }
42 
43 Real
45 {
46  const auto & flux = _junction_uo.getFlux(_connection_index);
48 }
const unsigned int _connection_index
Index of the connected flow channel.
registerMooseObject("ThermalHydraulicsApp", ADFlowJunctionFlux1Phase)
static InputParameters validParams()
virtual Real computeQpIntegral() override
auto raw_value(const Eigen::Map< T > &in)
const unsigned int _equation_index
Index within flux vector to query.
void addRequiredParam(const std::string &name, const std::string &doc_string)
ADFlowJunctionFlux1Phase(const InputParameters &parameters)
const ADFlowJunctionUserObject & _junction_uo
Junction user object.
Provides common interfaces for flow junction user objects.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
Retrieves an entry of a flux vector for a connection attached to a 1-phase junction.
void addClassDescription(const std::string &doc_string)
virtual const std::vector< ADReal > & getFlux(const unsigned int &connection_index) const =0
Gets the flux vector for a connection.
static InputParameters validParams()
void ErrorVector unsigned int