delphyne
SimpleCarParams< T > Class Template Referencefinal

Detailed Description

template<typename T>
class delphyne::SimpleCarParams< T >

Specializes BasicVector with specific getters and setters.

#include <src/gen/simple_car_params.h>

Inheritance diagram for SimpleCarParams< T >:
[legend]

Public Types

typedef SimpleCarParamsIndices K
 An abbreviation for our row index constants. More...
 

Public Member Functions

 SimpleCarParams ()
 Default constructor. More...
 
Implements CopyConstructible, CopyAssignable, MoveConstructible,

MoveAssignable

 SimpleCarParams (const SimpleCarParams &other)
 
 SimpleCarParams (SimpleCarParams &&other) noexcept
 
SimpleCarParamsoperator= (const SimpleCarParams &other)
 
SimpleCarParamsoperator= (SimpleCarParams &&other) noexcept
 
template<typename U = T>
std::enable_if< std::is_same< U, drake::symbolic::Expression >::value >::type SetToNamedVariables ()
 Create a drake::symbolic::Variable for each element with the known variable name. More...
 
SimpleCarParams< T > * DoClone () const final
 

Getters and Setters

const T & wheelbase () const
 The distance between the front and rear axles of the vehicle. More...
 
void set_wheelbase (const T &wheelbase)
 Setter that matches wheelbase(). More...
 
DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams< T > with_wheelbase (const T &wheelbase) const
 Fluent setter that matches wheelbase(). More...
 
const T & track () const
 The distance between the center of two wheels on the same axle. More...
 
void set_track (const T &track)
 Setter that matches track(). More...
 
DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams< T > with_track (const T &track) const
 Fluent setter that matches track(). More...
 
const T & max_abs_steering_angle () const
 The limit on the driving_command.steering angle input (the desired steering angle of a virtual center wheel); this element is applied symmetrically to both left- and right-turn limits. More...
 
void set_max_abs_steering_angle (const T &max_abs_steering_angle)
 Setter that matches max_abs_steering_angle(). More...
 
DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams< T > with_max_abs_steering_angle (const T &max_abs_steering_angle) const
 Fluent setter that matches max_abs_steering_angle(). More...
 
const T & max_velocity () const
 The limit on the car's forward speed. More...
 
void set_max_velocity (const T &max_velocity)
 Setter that matches max_velocity(). More...
 
DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams< T > with_max_velocity (const T &max_velocity) const
 Fluent setter that matches max_velocity(). More...
 
const T & max_acceleration () const
 The limit on the car's acceleration and deceleration. More...
 
void set_max_acceleration (const T &max_acceleration)
 Setter that matches max_acceleration(). More...
 
DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams< T > with_max_acceleration (const T &max_acceleration) const
 Fluent setter that matches max_acceleration(). More...
 
const T & velocity_limit_kp () const
 The smoothing constant for min/max velocity limits. More...
 
void set_velocity_limit_kp (const T &velocity_limit_kp)
 Setter that matches velocity_limit_kp(). More...
 
DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams< T > with_velocity_limit_kp (const T &velocity_limit_kp) const
 Fluent setter that matches velocity_limit_kp(). More...
 
drake::boolean< T > IsValid () const
 Returns whether the current values of this vector are well-formed. More...
 
void GetElementBounds (Eigen::VectorXd *lower, Eigen::VectorXd *upper) const final
 
static const std::vector< std::string > & GetCoordinateNames ()
 See SimpleCarParamsIndices::GetCoordinateNames(). More...
 

Member Typedef Documentation

◆ K

An abbreviation for our row index constants.

Constructor & Destructor Documentation

◆ SimpleCarParams() [1/3]

Default constructor.

Sets all rows to their default value:

  • wheelbase defaults to 2.700 m.
  • track defaults to 1.521 m.
  • max_abs_steering_angle defaults to 0.471 rad.
  • max_velocity defaults to 45.0 m/s.
  • max_acceleration defaults to 4.0 m/s^2.
  • velocity_limit_kp defaults to 10.0 Hz.

◆ SimpleCarParams() [2/3]

SimpleCarParams ( const SimpleCarParams< T > &  other)

◆ SimpleCarParams() [3/3]

SimpleCarParams ( SimpleCarParams< T > &&  other)
noexcept

Member Function Documentation

◆ DoClone()

SimpleCarParams<T>* DoClone ( ) const
final

◆ GetCoordinateNames()

static const std::vector<std::string>& GetCoordinateNames ( )
static

◆ GetElementBounds()

void GetElementBounds ( Eigen::VectorXd *  lower,
Eigen::VectorXd *  upper 
) const
final

◆ IsValid()

drake::boolean<T> IsValid ( ) const

Returns whether the current values of this vector are well-formed.

◆ max_abs_steering_angle()

const T& max_abs_steering_angle ( ) const

The limit on the driving_command.steering angle input (the desired steering angle of a virtual center wheel); this element is applied symmetrically to both left- and right-turn limits.

Note
max_abs_steering_angle is expressed in units of rad.
max_abs_steering_angle has a limited domain of [0.0, +Inf].

◆ max_acceleration()

const T& max_acceleration ( ) const

The limit on the car's acceleration and deceleration.

Note
max_acceleration is expressed in units of m/s^2.
max_acceleration has a limited domain of [0.0, +Inf].

◆ max_velocity()

const T& max_velocity ( ) const

The limit on the car's forward speed.

Note
max_velocity is expressed in units of m/s.
max_velocity has a limited domain of [0.0, +Inf].

◆ operator=() [1/2]

SimpleCarParams& operator= ( const SimpleCarParams< T > &  other)

◆ operator=() [2/2]

SimpleCarParams& operator= ( SimpleCarParams< T > &&  other)
noexcept

◆ set_max_abs_steering_angle()

void set_max_abs_steering_angle ( const T &  max_abs_steering_angle)

Setter that matches max_abs_steering_angle().

◆ set_max_acceleration()

void set_max_acceleration ( const T &  max_acceleration)

Setter that matches max_acceleration().

◆ set_max_velocity()

void set_max_velocity ( const T &  max_velocity)

Setter that matches max_velocity().

◆ set_track()

void set_track ( const T &  track)

Setter that matches track().

◆ set_velocity_limit_kp()

void set_velocity_limit_kp ( const T &  velocity_limit_kp)

Setter that matches velocity_limit_kp().

◆ set_wheelbase()

void set_wheelbase ( const T &  wheelbase)

Setter that matches wheelbase().

◆ SetToNamedVariables()

std::enable_if<std::is_same<U, drake::symbolic::Expression>::value>::type SetToNamedVariables ( )

Create a drake::symbolic::Variable for each element with the known variable name.

This is only available for T == drake::symbolic::Expression.

◆ track()

const T& track ( ) const

The distance between the center of two wheels on the same axle.

Note
track is expressed in units of m.
track has a limited domain of [0.0, +Inf].

◆ velocity_limit_kp()

const T& velocity_limit_kp ( ) const

The smoothing constant for min/max velocity limits.

Note
velocity_limit_kp is expressed in units of Hz.
velocity_limit_kp has a limited domain of [0.0, +Inf].

◆ wheelbase()

const T& wheelbase ( ) const

The distance between the front and rear axles of the vehicle.

Note
wheelbase is expressed in units of m.
wheelbase has a limited domain of [0.0, +Inf].

◆ with_max_abs_steering_angle()

DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams<T> with_max_abs_steering_angle ( const T &  max_abs_steering_angle) const

Fluent setter that matches max_abs_steering_angle().

Returns a copy of this with max_abs_steering_angle set to a new value.

◆ with_max_acceleration()

DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams<T> with_max_acceleration ( const T &  max_acceleration) const

Fluent setter that matches max_acceleration().

Returns a copy of this with max_acceleration set to a new value.

◆ with_max_velocity()

DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams<T> with_max_velocity ( const T &  max_velocity) const

Fluent setter that matches max_velocity().

Returns a copy of this with max_velocity set to a new value.

◆ with_track()

DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams<T> with_track ( const T &  track) const

Fluent setter that matches track().

Returns a copy of this with track set to a new value.

◆ with_velocity_limit_kp()

DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams<T> with_velocity_limit_kp ( const T &  velocity_limit_kp) const

Fluent setter that matches velocity_limit_kp().

Returns a copy of this with velocity_limit_kp set to a new value.

◆ with_wheelbase()

DRAKE_VECTOR_GEN_NODISCARD SimpleCarParams<T> with_wheelbase ( const T &  wheelbase) const

Fluent setter that matches wheelbase().

Returns a copy of this with wheelbase set to a new value.


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