Description

Base class for a vehicle subsystem.

It managemes the part's name, visualization assets, and contact material.

#include <ChPart.h>

Inheritance diagram for chrono::vehicle::ChPart:

Public Member Functions

 ChPart (const std::string &name)
 Construct a vehicle subsystem with the specified name. More...
 
const std::string & GetName () const
 Get the name identifier for this track shoe subsystem.
 
void SetName (const std::string &name)
 Set the name identifier for this track shoe subsystem.
 
void SetVisualizationType (VisualizationType vis)
 Set the visualization mode for this subsystem.
 
virtual void AddVisualizationAssets (VisualizationType vis)
 Add visualization assets to this subsystem, for the specified visualization mode.
 
virtual void RemoveVisualizationAssets ()
 Remove all visualization assets from this subsystem.
 
void SetContactFrictionCoefficient (float friction_coefficient)
 Set coefficient of friction. More...
 
void SetContactRestitutionCoefficient (float restitution_coefficient)
 Set coefficient of restitution. More...
 
void SetContactMaterialProperties (float young_modulus, float poisson_ratio)
 Set contact material properties. More...
 
void SetContactMaterialCoefficients (float kn, float gn, float kt, float gt)
 Set contact material coefficients. More...
 
float GetCoefficientFriction () const
 Get coefficient of friction for contact material.
 
float GetCoefficientRestitution () const
 Get coefficient of restitution for contact material.
 
float GetYoungModulus () const
 Get Young's modulus of elasticity for contact material.
 
float GetPoissonRatio () const
 Get Poisson ratio for contact material.
 
float GetKn () const
 Get normal stiffness coefficient for contact material.
 
float GetKt () const
 Get tangential stiffness coefficient for contact material.
 
float GetGn () const
 Get normal viscous damping coefficient for contact material.
 
float GetGt () const
 Get tangential viscous damping coefficient for contact material.
 

Static Public Member Functions

static ChMatrix33 TransformInertiaMatrix (const ChVector<> &moments, const ChVector<> &products, const ChMatrix33<> &vehicle_rot, const ChMatrix33<> &body_rot)
 Utility function for transforming inertia tensors between centroidal frames. More...
 

Protected Attributes

std::string m_name
 
float m_friction
 contact coefficient of friction
 
float m_restitution
 contact coefficient of restitution
 
float m_young_modulus
 contact material Young modulus
 
float m_poisson_ratio
 contact material Poisson ratio
 
float m_kn
 normal contact stiffness
 
float m_gn
 normal contact damping
 
float m_kt
 tangential contact stiffness
 
float m_gt
 tangential contact damping
 

Constructor & Destructor Documentation

chrono::vehicle::ChPart::ChPart ( const std::string &  name)

Construct a vehicle subsystem with the specified name.

Parameters
[in]namename of the subsystem

Member Function Documentation

void chrono::vehicle::ChPart::SetContactFrictionCoefficient ( float  friction_coefficient)

Set coefficient of friction.

The default value is 0.7

void chrono::vehicle::ChPart::SetContactMaterialCoefficients ( float  kn,
float  gn,
float  kt,
float  gt 
)

Set contact material coefficients.

These values are used directly to compute contact forces (if the containing system is so configured and if the SMC contact method is being used). The default values are: kn=2e5, gn=40, kt=2e5, gt=20

Parameters
[in]knnormal contact stiffness
[in]gnnormal contact damping
[in]kttangential contact stiffness
[in]gttangential contact damping
void chrono::vehicle::ChPart::SetContactMaterialProperties ( float  young_modulus,
float  poisson_ratio 
)

Set contact material properties.

These values are used to calculate contact material coefficients (if the containing system is so configured and if the SMC contact method is being used). The default values are: Y = 2e5 and nu = 0.3

Parameters
[in]young_modulusYoung's modulus of elasticity
[in]poisson_ratioPoisson ratio
void chrono::vehicle::ChPart::SetContactRestitutionCoefficient ( float  restitution_coefficient)

Set coefficient of restitution.

The default value is 0.1

ChMatrix33 chrono::vehicle::ChPart::TransformInertiaMatrix ( const ChVector<> &  moments,
const ChVector<> &  products,
const ChMatrix33<> &  vehicle_rot,
const ChMatrix33<> &  body_rot 
)
static

Utility function for transforming inertia tensors between centroidal frames.

It converts an inertia matrix specified in a centroidal frame aligned with the vehicle reference frame to an inertia matrix expressed in a centroidal body reference frame.

Parameters
momentsmoments of inertia in vehicle-aligned centroidal frame
productsproducts of inertia in vehicle-aligned centroidal frame
vehicle_rotvehicle absolute orientation matrix
body_rotbody absolute orientation matrix