ADORe
ADORe is a modular open source software library and toolkit for decision making, planning, control and simulation of automated vehicles
adore::fun::SetPointRequest Class Reference

#include <setpointrequest.h>

Collaboration diagram for adore::fun::SetPointRequest:
Collaboration graph

Public Member Functions

 SetPointRequest ()
 
virtual ~SetPointRequest ()
 
void push_back (const SetPoint &setPoint)
 
void append (const adoreMatrix< double, 1, 0 > &T, const adoreMatrix< double, 0, 0 > &X, int N, int maneuverID=0)
 
void setStartTime (double new_t0)
 
double getDuration () const
 
PlanarVehicleState10d interpolateReference (double t, adore::params::APVehicle *p) const
 
SetPoint interpolateSetPoint (double t, adore::params::APVehicle *p) const
 
void relocate (double deltaX, double deltaY, double new_PSI0)
 
void relocateTo (double newX0, double newY0, double new_PSI0)
 
void removeAfter (double t)
 
int numberOfDistinctManeuvers ()
 
void compress (int targetCount)
 
void copySetPointInterval (double t0, double t1, SetPointRequest &destination) const
 
void copyTo (SetPointRequest &destination) const
 
void copySetPointInterval (double t0, double t1, SetPointRequest &destination, int maneuverID) const
 
void copyTo (SetPointRequest &destination, int maneuverID) const
 
bool isActive (double t) const
 
bool isPending (double t) const
 
bool isDone (double t) const
 
int getActiveElementNumber (double t) const
 
adore::mad::LLinearPiecewiseFunctionM< double, 4 > getTrajectory ()
 
void cropAfterFirstStop (double vxslow)
 remove SetPoints after first stop Method looks for first downward zero crossing of vx and removes all SetPoints at zero crossing and after. More...
 

Public Attributes

std::vector< SetPointsetPoints
 
int setPointRequestID
 

Detailed Description

A description of a reference trajectory. Consisting of a queue of SetPoints, SetPointRequest defines the reference vehicle behavior during a longer time interval consisting of the sub-intervals of separate SetPoints.

Constructor & Destructor Documentation

◆ SetPointRequest()

adore::fun::SetPointRequest::SetPointRequest ( )
inline

◆ ~SetPointRequest()

virtual adore::fun::SetPointRequest::~SetPointRequest ( )
inlinevirtual

Member Function Documentation

◆ append()

void adore::fun::SetPointRequest::append ( const adoreMatrix< double, 1, 0 > &  T,
const adoreMatrix< double, 0, 0 > &  X,
int  N,
int  maneuverID = 0 
)
inline

Add N new SetPoints to the end of the trajectory. Data for new SetPoints is retrieved from a state matrix.

Parameters
Ttime steps
Xstate matrix of size #x * #T
Nnumber of SetPoints to be appended, step size is changed accordingly
maneuverIDmaneuver type
Here is the call graph for this function:
Here is the caller graph for this function:

◆ compress()

void adore::fun::SetPointRequest::compress ( int  targetCount)
inline

resize the spr to the desired number of setpoints

Here is the call graph for this function:

◆ copySetPointInterval() [1/2]

void adore::fun::SetPointRequest::copySetPointInterval ( double  t0,
double  t1,
SetPointRequest destination 
) const
inline

copy a SetPoints in a given time interval to a destination SetPointRequest

◆ copySetPointInterval() [2/2]

void adore::fun::SetPointRequest::copySetPointInterval ( double  t0,
double  t1,
SetPointRequest destination,
int  maneuverID 
) const
inline

copy a SetPoints in a given time interval to a destination SetPointRequest and change their maneuverID

◆ copyTo() [1/2]

void adore::fun::SetPointRequest::copyTo ( SetPointRequest destination) const
inline

copy all SetPoints to a destionation SetPointRequest

Here is the caller graph for this function:

◆ copyTo() [2/2]

void adore::fun::SetPointRequest::copyTo ( SetPointRequest destination,
int  maneuverID 
) const
inline

copy all SetPoints to a destionation SetPointRequest

◆ cropAfterFirstStop()

void adore::fun::SetPointRequest::cropAfterFirstStop ( double  vxslow)
inline

remove SetPoints after first stop Method looks for first downward zero crossing of vx and removes all SetPoints at zero crossing and after.

Parameters
vxslowterminal speed, defining the zero line for which zero crossing is detected
Here is the caller graph for this function:

◆ getActiveElementNumber()

int adore::fun::SetPointRequest::getActiveElementNumber ( double  t) const
inline

get the index of the SetPoint, which is active at time t

Here is the call graph for this function:

◆ getDuration()

double adore::fun::SetPointRequest::getDuration ( ) const
inline

◆ getTrajectory()

adore::mad::LLinearPiecewiseFunctionM<double,4> adore::fun::SetPointRequest::getTrajectory ( )
inline

Convert SetPointRequest to a state matrix representation with states [X,Y,PSI,vx].

Returns
a matrix of size 5 x N
Here is the caller graph for this function:

◆ interpolateReference()

PlanarVehicleState10d adore::fun::SetPointRequest::interpolateReference ( double  t,
adore::params::APVehicle p 
) const
inline

Retrieve the reference vehicle state for an exact time t. In the general case t is located between discrete time steps. The reference is then interpolated by forwards integration.

Parameters
tthe desired point of time
pvehicle parameters used for forwards integration
Here is the call graph for this function:
Here is the caller graph for this function:

◆ interpolateSetPoint()

SetPoint adore::fun::SetPointRequest::interpolateSetPoint ( double  t,
adore::params::APVehicle p 
) const
inline
Here is the call graph for this function:
Here is the caller graph for this function:

◆ isActive()

bool adore::fun::SetPointRequest::isActive ( double  t) const
inline

test whether SetPointRequest has a reference for time t

Here is the caller graph for this function:

◆ isDone()

bool adore::fun::SetPointRequest::isDone ( double  t) const
inline

test whether SetPointRequest ends before time t

◆ isPending()

bool adore::fun::SetPointRequest::isPending ( double  t) const
inline

test whether SetPointRequest has a reference for time t or starts after time t

◆ numberOfDistinctManeuvers()

int adore::fun::SetPointRequest::numberOfDistinctManeuvers ( )
inline

count the number of distinct maneuver ids

Here is the caller graph for this function:

◆ push_back()

void adore::fun::SetPointRequest::push_back ( const SetPoint setPoint)
inline
Here is the caller graph for this function:

◆ relocate()

void adore::fun::SetPointRequest::relocate ( double  deltaX,
double  deltaY,
double  new_PSI0 
)
inline

Rotate and translate the reference trajectory to another initial position.

Parameters
deltaXthe shift by X coordinate
deltaYthe shift by Y coordinate
new_PSI0the new initial heading/direction

q = R(psi)(p-p0)+p1

Here is the call graph for this function:

◆ relocateTo()

void adore::fun::SetPointRequest::relocateTo ( double  newX0,
double  newY0,
double  new_PSI0 
)
inline

Rotate and translate the reference trajectory to another initial position.

Parameters
newX0the new origin X coordinate
newY0the new origin Y coordinate
new_PSI0the new initial heading/direction
Here is the call graph for this function:
Here is the caller graph for this function:

◆ removeAfter()

void adore::fun::SetPointRequest::removeAfter ( double  t)
inline

Remove entries after a certain point of time

Parameters
tmaximum time to be contained
Here is the caller graph for this function:

◆ setStartTime()

void adore::fun::SetPointRequest::setStartTime ( double  new_t0)
inline

shift the reference trajectory in time

Parameters
new_t0the new start time
Here is the caller graph for this function:

Member Data Documentation

◆ setPointRequestID

int adore::fun::SetPointRequest::setPointRequestID

id of reference trajectory, incremented with each update to track changes

◆ setPoints

std::vector<SetPoint> adore::fun::SetPointRequest::setPoints

SetPoints, ordered by time


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