Description

Base class for a drawbar-pull rig mechanism.

Derived classes implement different ways for measuring DBP.

#include <ChVehicleCosimDBPRig.h>

Inheritance diagram for chrono::vehicle::ChVehicleCosimDBPRig:

Public Types

enum  Type { Type::IMPOSED_SLIP, Type::IMPOSED_ANG_VEL }
 Type of DBP rig. More...
 

Public Member Functions

void SetVerbose (bool verbose)
 Set verbose flag.
 
void SetDBPFilterWindow (double window)
 Set window (in seconds) for the running average filter for drawbar pull reporting (default: 0.1 s).
 
void SetSlipFilterWindow (double window)
 Set window (in seconds) for the running average filter for slip reporting (default: 0.1 s).
 
void SetRampingIntervals (double delay, double ramp_time)
 Set the delay and ramping time intervals for reaching the prescribed angular velocity. More...
 
virtual void Initialize (std::shared_ptr< ChBody > chassis, double wheel_radius, double step_size)
 Construct and initialize the rig mechanism.
 
virtual void Advance (double step_size)
 Advance rig state by specified step size.
 
virtual Type GetType () const =0
 Get rig type.
 
double GetTimeDelay ()
 Get total time delay. More...
 
std::shared_ptr< ChFunctionGetMotorFunction () const
 Return the function specifying spindle angular speed.
 
double GetLocation () const
 Return current rig location.
 
double GetLinVel () const
 Return current rig linear speed.
 
virtual double GetAngVel () const =0
 Return current wheel angular speed.
 
double GetSlip () const
 Return current value of longitudinal slip.
 
virtual double GetDBP () const =0
 Return current raw drawbar-pull value.
 
double GetFilteredDBP () const
 Return current filtered drawbar-pull value.
 
double GetFilteredSlip () const
 Return current filtered slip value.
 

Protected Attributes

bool m_verbose
 verbose messages during simulation?
 
double m_time_delay
 initial interval with zero motor velocities
 
double m_time_ramp
 time interval to ramp up motor velocities to prescribed value
 
double m_wheel_radius
 wheel radius
 
std::shared_ptr< ChBodym_ground
 ground body
 
std::shared_ptr< ChBodym_carrier
 rig carrier body
 
std::shared_ptr< ChFunctionm_rot_motor_func
 imposed spindle angular speed
 

Member Enumeration Documentation

◆ Type

Type of DBP rig.

Enumerator
IMPOSED_SLIP 

rig of type ChVehicleCosimDBPRigImposedSlip

IMPOSED_ANG_VEL 

rig of type ChVehicleCosimDBPRigImposedAngVel

Member Function Documentation

◆ GetTimeDelay()

double chrono::vehicle::ChVehicleCosimDBPRig::GetTimeDelay ( )
inline

Get total time delay.

This is the total time necessary to bring motor velocities to their nominal values and is used to decide whether or not to generate rig output.

◆ SetRampingIntervals()

void chrono::vehicle::ChVehicleCosimDBPRig::SetRampingIntervals ( double  delay,
double  ramp_time 
)

Set the delay and ramping time intervals for reaching the prescribed angular velocity.

By default, the angular velocity is kept zero for 0.2 s and then increased to the prescribed value in 0.5 s.


The documentation for this class was generated from the following files:
  • /builds/uwsbel/chrono/src/chrono_vehicle/cosim/ChVehicleCosimDBPRig.h
  • /builds/uwsbel/chrono/src/chrono_vehicle/cosim/ChVehicleCosimDBPRig.cpp