https://mooseframework.inl.gov
Loading...
Searching...
No Matches
ADDynamicViscosityMaterial.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
14
17{
19
20 params.addRequiredParam<MaterialPropertyName>("mu", "Dynamic viscosity property");
21 params.addRequiredParam<MaterialPropertyName>("v", "Specific volume property");
22 params.addRequiredParam<MaterialPropertyName>("e", "Specific internal energy property");
23
24 params.addRequiredParam<UserObjectName>("fp_1phase", "Single-phase fluid properties");
25
26 params.addClassDescription("Computes dynamic viscosity as a material property");
27
28 return params;
29}
30
32 : Material(parameters),
33
34 _mu_name(getParam<MaterialPropertyName>("mu")),
35 _mu(declareADProperty<Real>(_mu_name)),
36
37 _v(getADMaterialProperty<Real>("v")),
38
39 _e(getADMaterialProperty<Real>("e")),
40
41 _fp_1phase(getUserObject<SinglePhaseFluidProperties>("fp_1phase"))
42{
43}
44
45void
registerMooseObject("ThermalHydraulicsApp", ADDynamicViscosityMaterial)
Computes dynamic viscosity.
const ADMaterialProperty< Real > & _v
Specific volume.
static InputParameters validParams()
ADMaterialProperty< Real > & _mu
const SinglePhaseFluidProperties & _fp_1phase
Single-phase fluid properties.
const ADMaterialProperty< Real > & _e
Specific internal energy.
ADDynamicViscosityMaterial(const InputParameters &parameters)
virtual void computeQpProperties() override
void addRequiredParam(const std::string &name, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)
unsigned int _qp
static InputParameters validParams()
Common class for single phase fluid properties.