Classes | Public Member Functions | Private Types | Private Attributes | List of all members
multi_robot_router::RouteCoordinatorTimed::Timeline Class Reference

Classes

struct  seg_occupation_t
 

Public Member Functions

bool addCrossingSegment (const uint32_t _startTime, const int32_t _endTime, const uint32_t _segId, const uint32_t _robotNr, const uint32_t _robotSize, const bool &_mainSeg)
 adds a segment in a crossing (neighbours > 1) to the timeline and checks if the occupation is valid More...
 
bool addSegment (const uint32_t _startTime, const int32_t _endTime, const uint32_t _segId, const uint32_t _robotNr, const uint32_t _robotSize, bool _mainSeg)
 adds a segment to the timeline and checks if the occupation is valid More...
 
bool checkCrossingSegment (const uint32_t _startTime, const int32_t _endTime, const uint32_t _segId, const uint32_t _robotNr, const uint32_t _robotSize, int32_t &_lastCollisionRobot) const
 checks if a robot can enter a segment at a specific time if located in a crossing (neighbours > 1) More...
 
bool checkSegment (const uint32_t _startTime, const int32_t _endTime, const uint32_t _segId, const uint32_t _robotNr, const uint32_t _robotSize, int32_t &_lastCollisionRobot) const
 checks if a robot can enter a segment at a specific time More...
 
int32_t findSegId (const int32_t _robot, const uint32_t _timestep) const
 returns the segment id at which the robot is at timepoint _potential More...
 
std::vector< std::pair< uint32_t, float > > getListOfRobotsHigherPrioritizedRobots (const uint32_t _robot, const uint32_t _segId, const int32_t _potential) const
 returns all robots which pass the segment before the given robot and a given time More...
 
uint32_t getSize () const
 returns the length of the timeline (max Time) More...
 
int32_t getTimeUntilRobotOnSegment (const int32_t _robotNr, const uint32_t _segId) const
 returns the time point, when a robot leaves a vertex More...
 
void removeRobot (const uint32_t _robot)
 removes a Robot from the Routing Table More...
 
void reset (const std::vector< Segment > &_graph, const uint32_t _nrRobots)
 resets the planning session of multiple robots More...
 
 Timeline ()
 

Private Types

typedef struct multi_robot_router::RouteCoordinatorTimed::Timeline::seg_occupation_t seg_occupation
 

Private Attributes

uint32_t maxTime_ = 0
 
uint32_t nrRobots_ = 0
 
std::vector< std::vector< uint32_t > > robotSegments_
 
std::vector< float > segmentSpace_
 
std::vector< std::vector< seg_occupation > > timeline_
 
uint32_t tmpRobot_ = 0
 

Detailed Description

Definition at line 40 of file route_coordinator_timed.h.

Member Typedef Documentation

Constructor & Destructor Documentation

multi_robot_router::RouteCoordinatorTimed::Timeline::Timeline ( )

Definition at line 223 of file route_coordinator_timed.cpp.

Member Function Documentation

bool multi_robot_router::RouteCoordinatorTimed::Timeline::addCrossingSegment ( const uint32_t  _startTime,
const int32_t  _endTime,
const uint32_t  _segId,
const uint32_t  _robotNr,
const uint32_t  _robotSize,
const bool &  _mainSeg 
)

adds a segment in a crossing (neighbours > 1) to the timeline and checks if the occupation is valid

Parameters
_startTimethe time when the robot enters the segment
_endTimethe time when the robot leaves the segment
_segIdthe segment id
_robotNrthe robot Id
_robotSizethe robot Size
_mainSegsaves if this is a main segment (A segment which is passed by the robot and not overlapping with the path)
Returns
true if a segment is added to the timeline

Definition at line 269 of file route_coordinator_timed.cpp.

bool multi_robot_router::RouteCoordinatorTimed::Timeline::addSegment ( const uint32_t  _startTime,
const int32_t  _endTime,
const uint32_t  _segId,
const uint32_t  _robotNr,
const uint32_t  _robotSize,
bool  _mainSeg 
)

adds a segment to the timeline and checks if the occupation is valid

Parameters
_startTimethe time when the robot enters the segment
_endTimethe time when the robot leaves the segment
_segIdthe segment id
_robotNrthe robot Id
_robotSizethe robot Size
_mainSegsaves if this is a main segment (A segment which is passed by the robot and not overlapping with the path)
Returns
true if a segment is added to the timeline

Definition at line 241 of file route_coordinator_timed.cpp.

bool multi_robot_router::RouteCoordinatorTimed::Timeline::checkCrossingSegment ( const uint32_t  _startTime,
const int32_t  _endTime,
const uint32_t  _segId,
const uint32_t  _robotNr,
const uint32_t  _robotSize,
int32_t &  _lastCollisionRobot 
) const

checks if a robot can enter a segment at a specific time if located in a crossing (neighbours > 1)

Parameters
_startTimethe time the current robot enters the segment
_endTimethe time the current robot leaves the segment
_segIdthe segment to check
_robotNrthe id of the robot to check
_robotSizethe diameter of the robot
_lastCollisionRobotreturns the robot wich causes a collision (if no collision -1)
Returns
if the vertex is free for the given timespan

Definition at line 279 of file route_coordinator_timed.cpp.

bool multi_robot_router::RouteCoordinatorTimed::Timeline::checkSegment ( const uint32_t  _startTime,
const int32_t  _endTime,
const uint32_t  _segId,
const uint32_t  _robotNr,
const uint32_t  _robotSize,
int32_t &  _lastCollisionRobot 
) const

checks if a robot can enter a segment at a specific time

Parameters
_startTimethe time the current robot enters the segment
_endTimethe time the current robot leaves the segment
_segIdthe segment to check
_robotNrthe id of the robot to check
_robotSizethe diameter of the robot
_lastCollisionRobotreturns the robot wich causes a collision (if no collision -1)
Returns
if the vertex is free for the given timespan

Definition at line 289 of file route_coordinator_timed.cpp.

int32_t multi_robot_router::RouteCoordinatorTimed::Timeline::findSegId ( const int32_t  _robot,
const uint32_t  _timestep 
) const

returns the segment id at which the robot is at timepoint _potential

Parameters
_robotthe robot id
_potentialthe timepoint on the robots path execution
Returns
the segment where the robot is located at time _potential

Definition at line 382 of file route_coordinator_timed.cpp.

std::vector< std::pair< uint32_t, float > > multi_robot_router::RouteCoordinatorTimed::Timeline::getListOfRobotsHigherPrioritizedRobots ( const uint32_t  _robot,
const uint32_t  _segId,
const int32_t  _potential 
) const

returns all robots which pass the segment before the given robot and a given time

Parameters
_robotthe robotId
_segIdthe Vertex to check
_potentialthe maximum potential
Returns
all robots which pass the vertex befor _robot and before _potential

Definition at line 418 of file route_coordinator_timed.cpp.

uint32_t multi_robot_router::RouteCoordinatorTimed::Timeline::getSize ( ) const

returns the length of the timeline (max Time)

Returns
the least time a segmetn is occupied

Definition at line 377 of file route_coordinator_timed.cpp.

int32_t multi_robot_router::RouteCoordinatorTimed::Timeline::getTimeUntilRobotOnSegment ( const int32_t  _robotNr,
const uint32_t  _segId 
) const

returns the time point, when a robot leaves a vertex

Parameters
_robotNrthe robotId
_segIdthe segmentId where the time is searched
Returns
the time the robot leaves the segment (-1 means it is a goal Vertex and is occupied forever)

Definition at line 403 of file route_coordinator_timed.cpp.

void multi_robot_router::RouteCoordinatorTimed::Timeline::removeRobot ( const uint32_t  _robot)

removes a Robot from the Routing Table

Parameters
_robotthe robot to remove

Definition at line 451 of file route_coordinator_timed.cpp.

void multi_robot_router::RouteCoordinatorTimed::Timeline::reset ( const std::vector< Segment > &  _graph,
const uint32_t  _nrRobots 
)

resets the planning session of multiple robots

Parameters
_graphthe graph
_nrRobotsthe nr of robots to plan

Definition at line 227 of file route_coordinator_timed.cpp.

Member Data Documentation

uint32_t multi_robot_router::RouteCoordinatorTimed::Timeline::maxTime_ = 0
private

Definition at line 147 of file route_coordinator_timed.h.

uint32_t multi_robot_router::RouteCoordinatorTimed::Timeline::nrRobots_ = 0
private

Definition at line 148 of file route_coordinator_timed.h.

std::vector<std::vector<uint32_t> > multi_robot_router::RouteCoordinatorTimed::Timeline::robotSegments_
private

Definition at line 145 of file route_coordinator_timed.h.

std::vector<float> multi_robot_router::RouteCoordinatorTimed::Timeline::segmentSpace_
private

Definition at line 146 of file route_coordinator_timed.h.

std::vector<std::vector<seg_occupation> > multi_robot_router::RouteCoordinatorTimed::Timeline::timeline_
private

Definition at line 144 of file route_coordinator_timed.h.

uint32_t multi_robot_router::RouteCoordinatorTimed::Timeline::tmpRobot_ = 0
private

Definition at line 150 of file route_coordinator_timed.h.


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


tuw_multi_robot_router
Author(s): Benjamin Binder
autogenerated on Mon Jun 10 2019 15:42:49