ObstacleAwareVelocityLimit Class Reference

The maximum permissible linear velocity as a function of the distance to the closest obstacle. More...

#include <armarx/navigation/algorithms/ObstacleAwareVelocityLimit.h>

Classes

struct  Parameters
 

Public Member Functions

std::vector< floatat (const core::Positions &positions) const
 
float at (const Eigen::Vector2f &position) const
 The limit at a position in the costmap's global frame.
 
float atDistance (float obstacleDistance) const
 The limit for a given distance to the closest obstacle [mm].
 
 ObstacleAwareVelocityLimit (const Costmap &costmap, const Parameters &params)
 
const Parametersparams () const noexcept
 

Detailed Description

The maximum permissible linear velocity as a function of the distance to the closest obstacle.

The limit decays from maxVelocity in free space to maxVelocity / (1 + weight) at zero clearance:

\[  v_{max}(d) = \frac{v_{max}}{1 + w \left(1 - \frac{\min(d, d_{max})}{d_{max}}\right)^{e}}
\]

This used to live as a private member function of global_planning::SPFAImpl, duplicated once more in its final velocity clamp. It is a standalone concept, so it lives here and can be used to verify a trajectory produced by any planner: for a path that respects the limit, at(position) >= velocity holds at every trajectory point.

Note
The referenced costmap must outlive this object.

Definition at line 52 of file ObstacleAwareVelocityLimit.h.

Constructor & Destructor Documentation

◆ ObstacleAwareVelocityLimit()

ObstacleAwareVelocityLimit ( const Costmap & costmap,
const Parameters & params )

Definition at line 35 of file ObstacleAwareVelocityLimit.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ at() [1/2]

std::vector< float > at ( const core::Positions & positions) const

Definition at line 64 of file ObstacleAwareVelocityLimit.cpp.

+ Here is the call graph for this function:

◆ at() [2/2]

float at ( const Eigen::Vector2f & position) const

The limit at a position in the costmap's global frame.

Cells without costmap information (masked out) are treated as zero clearance, i.e. the most restrictive limit. Not knowing how far away the obstacles are is not a reason to drive fast.

Definition at line 56 of file ObstacleAwareVelocityLimit.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ atDistance()

float atDistance ( float obstacleDistance) const

The limit for a given distance to the closest obstacle [mm].

Definition at line 44 of file ObstacleAwareVelocityLimit.cpp.

+ Here is the caller graph for this function:

◆ params()

const ObstacleAwareVelocityLimit::Parameters & params ( ) const
noexcept

Definition at line 73 of file ObstacleAwareVelocityLimit.cpp.

+ Here is the caller graph for this function:

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