Class PathRestriction
Defined in File PathRestriction.h
Class Documentation
-
class PathRestriction
Representation of path restriction (union of fibers over a base path).
Class represents path restriction by keeping a set of discrete base path states. To access states inbetween, we use the interpolateBasePath method. To find a feasible section over a path restriction, we use the strategy pattern FindSection, which has different implementations.
To use this class, you need to set a base path (setBasePath), then you can search for sections over this base path (using hasFeasibleSection). Internally, this calls the FindSection algorithm, which can be changed in Constructor method. Please see the class ompl::multilevel::FindSection for details on finding feasible sections.
- External documentation
A. Orthey and M. Toussaint, Section Patterns: Efficiently Solving Narrow Passage Problems using Multilevel Motion Planning, arXiv:2010.14524 [cs.RO], 2020 [PDF]
Public Functions
-
PathRestriction() = delete
-
PathRestriction(BundleSpaceGraph*)
-
virtual ~PathRestriction()
-
virtual void clear()
-
const std::vector<base::State*> &getBasePath() const
Return discrete states representation of base path.
-
void setFindSectionStrategy(FindSectionType type)
Choose algorithm to find sections over restriction.
-
bool hasFeasibleSection(Configuration*const, Configuration*const)
Check if feasible section exists between xStart and xGoal.
NOTE: “const ptr*” means that the pointer itself is const “ptr* const” means that the content of the pointer is const (but ptr can change)
-
BundleSpaceGraph *getBundleSpaceGraph()
Return pointer to underlying bundle space graph.
-
double getLengthBasePath() const
Length of base path.
-
unsigned int size() const
Return number of discrete states in base path.
-
double getLengthIntermediateBasePath(int k)
Length between base state indices k and k+1.
-
double getLengthBasePathUntil(int k)
Cumulative length until base state index k.
-
int getBasePathLastIndexFromLocation(double d)
Given a position d in [0, lengthbasepath_], return the index of the nearest state on base path before d.
-
void interpolateBasePath(double t, base::State *&state) const
Interpolate state on base path at position t in [0, lengthbasepath_] (using discrete state representation)
-
virtual void print(std::ostream&) const
Protected Attributes
-
BundleSpaceGraph *bundleSpaceGraph_
Pointer to associated bundle space.
-
double lengthBasePath_ = {0.0}
Length of set base path.
-
std::vector<double> lengthsIntermediateBasePath_
Intermediate lengths between states on base path.
-
std::vector<double> lengthsCumulativeBasePath_
Cumulative lengths between states on base path.
-
FindSectionPtr findSection_
Strategy to find a feasible section (between specific elements on fiber at first base path index and fiber at last base path index)
Friends
-
friend std::ostream &operator<<(std::ostream&, const PathRestriction&)