https://mooseframework.inl.gov
ADMaterialFunctionProductMaterial.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 
11 #include "Function.h"
12 
14 
17 {
19 
20  params.addRequiredParam<MaterialPropertyName>("mat_prop_product", "Product material property");
21  params.addRequiredParam<MaterialPropertyName>("mat_prop_scale", "Scale material property");
22  params.addRequiredParam<FunctionName>("function", "Function in product");
23 
24  params.addClassDescription("Computes the product of a material property and a function.");
25 
26  return params;
27 }
28 
30  const InputParameters & parameters)
31  : Material(parameters),
32 
33  _product(declareADProperty<Real>(getParam<MaterialPropertyName>("mat_prop_product"))),
34  _scale(getADMaterialProperty<Real>("mat_prop_scale")),
35  _function(getFunction("function"))
36 {
37 }
38 
39 void
41 {
43 }
const MooseArray< Point > & _q_point
ADMaterialProperty< Real > & _product
Product.
ADMaterialFunctionProductMaterial(const InputParameters &parameters)
void addRequiredParam(const std::string &name, const std::string &doc_string)
unsigned int _qp
static InputParameters validParams()
Real & _t
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
void addClassDescription(const std::string &doc_string)
registerMooseObject("ThermalHydraulicsApp", ADMaterialFunctionProductMaterial)
Computes the product of a material property and a function.
virtual Real value(Real t, const Point &p) const
const ADMaterialProperty< Real > & _scale
Scale.