15 VectorPostprocessorFunction,
24 "vectorpostprocessor_name",
"The name of the VectorPostprocessor that you want to use");
27 "VectorPostprocessor column tabulating the abscissa of the sampled function");
29 "VectorPostprocessor column tabulating the " 30 "ordinate (function values) of the sampled " 35 "Whether or not this Function should be synced to all processors when running in parallel.");
37 MooseEnum component(
"x=0 y=1 z=2 time=3",
"time");
41 "Component of the function evaluation point used to sample the VectorPostprocessor");
44 "Provides piecewise linear interpolation of from two columns of a VectorPostprocessor");
53 _argument_column(getVectorPostprocessorValue(
"vectorpostprocessor_name",
54 getParam<
std::string>(
"argument_column"),
55 getParam<bool>(
"parallel_sync"))),
56 _value_column(getVectorPostprocessorValue(
"vectorpostprocessor_name",
57 getParam<
std::string>(
"value_column"),
58 getParam<bool>(
"parallel_sync"))),
59 _component(getParam<
MooseEnum>(
"component")),
60 _fe_problem(*getCheckedPointerParam<
FEProblemBase *>(
"_fe_problem_base")),
66 _linear_interp = std::make_unique<LinearInterpolation>(_argument_column, _value_column);
68 catch (std::domain_error & e)
70 mooseError(
"In PiecewiseLinearFromVectorPostprocessor ", _name,
": ", e.what());
86 template <
typename T,
typename P>
93 const std::tuple<Real, unsigned int, unsigned int> now = {
Base class for function objects.
const unsigned int invalid_uint
const VectorPostprocessorValue & _argument_column
void mooseError(Args &&... args)
Emit an error message with the given stringified, concatenated args and terminate the application...
Function which provides a piecewise continuous linear interpolation of a data set provided as two col...
const MooseEnum & _component
static InputParameters validParams()
PiecewiseLinearFromVectorPostprocessor(const InputParameters ¶meters)
T valueInternal(const T &t, const P &p) const
virtual unsigned int nLinearIterations(const unsigned int nl_sys_num) const override
DualNumber< Real, DNDerivativeType, true > ADReal
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
registerMooseObject("MooseApp", PiecewiseLinearFromVectorPostprocessor)
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
registerMooseObjectRenamed("MooseApp", VectorPostprocessorFunction, "02/03/2024 00:00", PiecewiseLinearFromVectorPostprocessor)
virtual Real value(Real t, const Point &p) const override
Override this to evaluate the scalar function at point (t,x,y,z), by default this returns zero...
FEProblemBase & _fe_problem
used to get the current linear/non-linear iteration number
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
std::unique_ptr< LinearInterpolation > _linear_interp
virtual unsigned int nNonlinearIterations(const unsigned int nl_sys_num) const override
static InputParameters validParams()
Class constructor.
const VectorPostprocessorValue & _value_column
std::tuple< Real, unsigned int, unsigned int > _last_update
last iteration during which the linear interpolation was rebuilt