Template Class ProfileGenerator#

Inheritance Relationships#

Base Type#

Derived Types#

Class Documentation#

template<typename T>
class ProfileGenerator : public Karana::Core::BaseWithVars#

ProfileGenerator base class.

Template Parameters:

T – The type that the ProfileGenerator produces, e.g., double, UnitQuaternion, etc.

Subclassed by Karana::Models::ConstantProfileGenerator< T >, Karana::Models::CubicSplineProfileGenerator< T >, Karana::Models::LinearProfileGenerator< T >

Public Functions

inline ProfileGenerator(std::string_view name, const T &u)#

ProfileGenerator constructor.

Parameters:
  • name – The name of this profile generator.

  • u – A representative sample value for the velocity.

virtual const T &getQ(const Karana::Math::Ktime &t) = 0#

Get the profile coordinate for the provided time.

Parameters:

t – The current time

Returns:

The profile coordinate at the provided time.

virtual const T &getU(const Karana::Math::Ktime &t) = 0#

Get the profile velocity for the provided time.

Parameters:

t – The current time

Returns:

The profile velocity at the provided time.

virtual const T &getUdot(const Karana::Math::Ktime &t) = 0#

Get the profile acceleration for the provided time.

Parameters:

t – The current time

Returns:

The profile acceleration at the provided time.

Protected Functions

inline T _init_zero(const T &value)#

Get an initial value of zero based on the type.

Parameters:

value – The value to use as a template to set zeros for.

Returns:

A value of type T that is zero.

inline virtual Karana::Core::ks_ptr<Karana::Core::BaseVars> _getVars() const override#

Create the vars for this object.

Returns:

The vars for this object.

Protected Attributes

T _u#

The profile velocity.