https://mooseframework.inl.gov
ReporterOffsetFunctionMaterial.h
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 #pragma once
11 
12 #include "Material.h"
13 #include "Function.h"
14 #include "ReporterInterface.h"
15 
16 template <bool>
20 
26 template <bool is_ad>
28 {
29 public:
31 
33 
34 protected:
35  virtual void computeQpProperties() override;
36 
38  const std::string _prop_name;
39 
42 
44  const bool _read_in_points;
48  // @{
50  const std::vector<Real> & _coordx;
52  const std::vector<Real> & _coordy;
54  const std::vector<Real> & _coordz;
56  const std::vector<Point> & _points;
57  // @}
58 
60  const Function & _func;
66  Real computeOffsetFunction(const Point & point_offset);
67 
68 private:
70  std::vector<Real> _zeros_vec;
71  std::vector<Point> _zeros_pts;
72 };
ReporterOffsetFunctionMaterialTempl< true > ADReporterOffsetFunctionMaterial
std::vector< Real > _zeros_vec
convenience vectors (these are not const because reporters can change their size) ...
ReporterOffsetFunctionMaterialTempl< false > ReporterOffsetFunctionMaterial
const std::vector< Real > & _coordx
Reporter offset locations for function.
This class defines a material with an associated offset function.
const std::vector< Real > & _coordy
y coordinate
const std::vector< Point > & _points
xyz point
Real computeOffsetFunction(const Point &point_offset)
Calculates the value of the function at the given offset point.
const std::vector< Real > & _coordz
z coordinate
typename GenericMaterialPropertyStruct< T, is_ad >::type GenericMaterialProperty
ReporterOffsetFunctionMaterialTempl(const InputParameters &parameters)
const std::string _prop_name
Base name of the material system.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
const Function & _func
The function being used for evaluation.
const InputParameters & parameters() const
const bool _read_in_points
bool if data format read in is points
GenericMaterialProperty< Real, is_ad > & _material
Misfit value at each quadrature point.