20 params.
addRequiredParam<FunctionName>(
"torque",
"Torque as a function of shaft speed");
22 "Moment of inertia as a function of shaft speed");
25 "Computes the torque and moment of inertia of a shaft connected motor");
32 _torque_fn(getFunction(
"torque")),
33 _inertia_fn(getFunction(
"inertia")),
34 _shaft_speed(adCoupledScalarValue(
"shaft_speed"))
44 shaft_speed.derivatives();
54 shaft_speed.derivatives();
virtual void finalize() override
registerMooseObject("ThermalHydraulicsApp", ADShaftConnectedMotorUserObject)
const Function & _inertia_fn
Moment of inertia as a function of shaft speed.
virtual ADReal getTorque() const override
static InputParameters validParams()
const Function & _torque_fn
Torque as a function of shaft speed.
virtual Real timeDerivative(Real t, const Point &p) const
User object to provide data for a shaft-connected motor.
const ADVariableValue & _shaft_speed
Shaft speed.
DualNumber< Real, DNDerivativeType, true > ADReal
ADShaftConnectedMotorUserObject(const InputParameters ¶ms)
virtual ADReal getMomentOfInertia() const override
static InputParameters validParams()
virtual void initialize() override
Interface class for user objects that are connected to a shaft.
static InputParameters validParams()
virtual Real value(Real t, const Point &p) const
virtual void execute() override