Class GearedCompoundBody#
Defined in File CECompoundBody.h
Inheritance Relationships#
Base Type#
public Karana::Dynamics::CECompoundBody(Class CECompoundBody)
Class Documentation#
-
class GearedCompoundBody : public Karana::Dynamics::CECompoundBody#
Constraint embedding class for a body pair connected by a gear.
This class is for a parent/child body pair with 1 dof hinge with a gear ratio relating the outboard body hinge coordinates to those of the inboard body. The inboard body coordinates are treated as the indepedent coordiantes.
Public Functions
-
virtual ~GearedCompoundBody()#
Destructor.
-
inline virtual std::string_view typeString() const noexcept override#
Returns the type string.
- Returns:
The type string.
-
GearedCompoundBody(std::string_view name, kc::ks_ptr<SubGraph> parent_subtree, kc::ks_ptr<SubGraph> bodies_tree)#
Constructs a GearedCompoundBody (to be retired)
-
inline void setGearRatio(double gear_ratio)#
Set the gear ratio.
- Parameters:
the – gear ratio
Public Static Functions
-
static kc::ks_ptr<GearedCompoundBody> create(std::string_view name, kc::ks_ptr<SubGraph> parent_subtree, kc::ks_ptr<SubGraph> component_bodies)#
Protected Functions
-
virtual void _updateDependentQ(const km::Vec &min_Q, bool global) const override#
Convert the input minimal coords Q into the full dependent Q for all the aggregated subhinges for the compound body
-
virtual km::Mat _constraintX() const override#
Return the X matrix that maps the min independent U to the full dependent U for the compound body
-
virtual km::Vec _constraintXdotU(const km::Vec &U) const override#
Return the Xdot*U product vector where Xdot is the time derivative of the X constraint matrix
- Parameters:
the – input U vector
- Returns:
the Xdot*U product
Protected Attributes
-
double _gear_ratio#
Return the X matrix pseudo inverse that maps the full dependent U for the compound body to the min independent U the ratio of the outboard subhinge coords rate to that for the inboard subhige
-
virtual ~GearedCompoundBody()#