Trax3 3.1.0
trax track library
Loading...
Searching...
No Matches
trax::TractionForceCharacteristic Struct Referenceabstract

Function that defines the characteristic behaviour of a motor to change its maximum available tracktion force with velocity. More...

#include <C:/Trend/Development/Trax3/Code/trax/rigid/TractionForceCharacteristic.h>

Public Types

enum class  TractionType : char {
  unknown = 0 , mechanic , hydrodynamic , electric ,
  steam , speedsteps , other
}
 Some exemplaric traction types. More...

Public Member Functions

virtual TractionType GetTractionType () const noexcept=0
virtual One operator() (Velocity velocity) const noexcept=0
 Mapping function.
virtual decltype(Power{}/Force{}) MaximumPowerFraction () const noexcept=0
virtual Velocity MaximumVelocity () const noexcept=0
virtual void AddSpeedStep (Velocity velocity, One value)=0
 Add a velocity/value pair to the characteristic.
virtual void GetSpeedSteps (std::vector< std::pair< Velocity, One > > &speedsteps) const =0
 Get all the speedsteps.
 TractionForceCharacteristic (const TractionForceCharacteristic &)=delete
 TractionForceCharacteristic (TractionForceCharacteristic &&)=delete
TractionForceCharacteristic & operator= (const TractionForceCharacteristic &)=delete
TractionForceCharacteristic & operator= (TractionForceCharacteristic &&)=delete

Static Public Member Functions

static dclspc std::unique_ptr< TractionForceCharacteristic > Make (TractionType type=TractionType::speedsteps, Velocity vmax=0_mIs, Velocity vtransit=0_mIs) noexcept

Detailed Description

Function that defines the characteristic behaviour of a motor to change its maximum available tracktion force with velocity.

The Factory provides one sample implementation for each TractionType. These are:

/// mechanic:
/// f = fstep for vstep <= v < vnextstep
///
/// hydrodynamic:
/// f = fstep + (fnextstep - fstep) (v - vstep)/(vnextstep - vstep)  for vstep <= v < vnextstep
///
/// electric:
/// f = a/(v+x) - y
/// with:
/// x = sqrt( (vm-vt)(a + (vm-vt)/4) ) - (vm+vt)/2 with vt < vm
/// y = a / (vm+x)
/// f = a(vm-v)/(v+x)(vm+x)
///
/// steam:
/// as electric with vt = 0
/// 

Member Enumeration Documentation

◆ TractionType

Some exemplaric traction types.

Enumerator
mechanic 

mechanical gear with different discrete gear settings

hydrodynamic 

continuous linear gear settings

electric 

constant traction force followed by hyperbolic decline

steam 

hyperbolic decline from the start

Member Function Documentation

◆ MaximumPowerFraction()

virtual decltype(Power{}/Force{}) trax::TractionForceCharacteristic::MaximumPowerFraction ( ) const
pure virtualnoexcept
Returns
The maximum power the engine can develop with the characteristic divided by the maximum traction force (just multiply with max force to yield power)

◆ MaximumVelocity()

virtual Velocity trax::TractionForceCharacteristic::MaximumVelocity ( ) const
pure virtualnoexcept
Returns
The maximum velocity the engine can theoretically achieve under the assumtion that no work has to be done by her.

◆ operator()()

virtual One trax::TractionForceCharacteristic::operator() ( Velocity velocity) const
pure virtualnoexcept

Mapping function.

The characteristic gets multiplied with the maximum torque. A value of 1 means that the maximum torques are applied as specified by the Wheelsets attached to a WheelFrame. Typically the value will drop linearly or hyperbolically if the absolute value of velocity gets high; it might get even negative at some extreme point.

Parameters
velocityVelocity along the track.
Returns
Factor in the range [-1,1].

The documentation for this struct was generated from the following file: