Klamp't  0.8.1
Classes | Functions
Planning

Classes

class  ConstrainedInterpolator
 Construct a polyline between a and b such that each point is near the constraint C(x)=0. More...
 
class  SmoothConstrainedInterpolator
 Constructs a piecewise polynomial path between a and b such that each point is near the constraint C(x)=0. More...
 
struct  ConstraintChecker
 Checks for static constraints for a robot at a given stance. More...
 
struct  DistanceQuery
 A method for efficiently caching and updating distance computations using temporal coherence. More...
 
class  PlannerObjectiveBase
 A base class for objective functionals in time/config/velocity space. More...
 
class  TimeObjective
 An objective that measures path execution time. More...
 
class  TerminalTimeObjective
 A goal that measures absolute difference in terminal time (i.e., penalize stopping at a different time than specified). More...
 
class  ConfigObjective
 A goal that measures distance to a goal configuration qgoal. More...
 
class  VelocityObjective
 A goal that measures distance to a goal velocity vgoal. More...
 
class  CompositeObjective
 An objective that merges contributions from multiple other objective functions. More...
 
class  CartesianObjective
 A goal that measures point-to-point distance. More...
 
class  IKObjective
 A goal for an IK solution (including possibly rotation) More...
 
class  CartesianTrackingObjective
 Tracking a path in cartesian space. More...
 
class  RealTimePlanner
 A real-time planner. Supports constant time-stepping or adaptive time-stepping. More...
 
class  RobotConstrainedInterpolator
 Just like a ConstrainedInterpolator but only projects the active DOFs. Much faster for high-DOF system with sparse constraints. More...
 
class  RobotSmoothConstrainedInterpolator
 Just like a SmoothConstrainedInterpolator but only projects the active DOFs. Much faster for high-DOF system with sparse constraints. More...
 
class  RobotCSpace
 Implements a basic robot configuration space with only joint limit constraint testing. More...
 
class  ActiveRobotCSpace
 A CSpace for just a few dofs of a robot. Slightly faster than using a regular RobotCSpace then picking out subvectors. More...
 
class  SingleRobotCSpace
 A cspace consisting of a single robot configuration in a RobotWorld. Feasibility constraints are joint and collision constraints. More...
 
class  SingleRigidObjectCSpace
 A configuration space for a rigid object, treated like a robot. More...
 
class  TimeScaling
 Maps time into a given path parameter range (e.g., [0,1]) with joint space velocity and acceleration bounds. Stores a piecewise quadratic time scaling. Most users will use the TimeScaledBezierCurve class or OptimizeTimeScaling methods instead. More...
 
class  TimeScaledBezierCurve
 A convenience class that stores a Bezier curve and its time scaling. Useful for evaluating the scaled curve, and for plotting it. More...
 

Functions

bool MultiSmoothInterpolate (SmoothConstrainedInterpolator &interp, const vector< Vector > &pts, GeneralizedCubicBezierSpline &path)
 
bool MultiSmoothInterpolate (SmoothConstrainedInterpolator &interp, const vector< Vector > &pts, const Vector &dq0, const Vector &dq1, GeneralizedCubicBezierSpline &path)
 
bool AppendInterpolate (SmoothConstrainedInterpolator &interp, const Vector &pt, Real suffixDuration, GeneralizedCubicBezierSpline &path)
 
bool TimeOptimizePath (Robot &robot, const vector< Real > &oldtimes, const vector< Config > &oldconfigs, Real dt, vector< Real > &newtimes, vector< Config > &newconfigs)
 Optimizes a piecewise-linear path by first smoothing it, then time-optimizing it with the given resolution dt.
 
bool InterpolateConstrainedPath (Robot &robot, const Config &a, const Config &b, const vector< IKGoal > &ikGoals, vector< Config > &path, Real xtol=1e-2)
 Generates a constrained piecewise linear path between two configurations while satisfying the constraints in ikGoals.
 
bool InterpolateConstrainedPath (Robot &robot, const vector< Config > &milestones, const vector< IKGoal > &ikGoals, vector< Config > &path, Real xtol=1e-2)
 Generates a constrained piecewise linear path between many configurations while satisfying the constraints in ikGoals.
 
void SmoothDiscretizePath (Robot &robot, const vector< Config > &oldconfigs, int n, vector< Real > &times, vector< Config > &configs)
 Given a list of milestones oldconfigs, constructs a smooth interpolating path and discretizes it uniformly with resolution n. The output times map to the range [0,1].
 
bool InterpolateConstrainedMultiPath (Robot &robot, const MultiPath &path, vector< GeneralizedCubicBezierSpline > &paths, Real xtol=1e-2)
 Given a coarsely discretized multipath, produces a finely discretized, smooth curve with appropriate tangents across contact states. More...
 
bool DiscretizeConstrainedMultiPath (Robot &robot, const MultiPath &path, MultiPath &out, Real xtol=1e-2)
 Given a coarsely discretized multipath, produces a finely discretized multipath that satisfies contact constraints. More...
 
bool GenerateAndTimeOptimizeMultiPath (Robot &robot, MultiPath &multipath, Real xtol, Real dt)
 Given a multipath, time-scales it to minimize execution time given the robot's velocity and acceleration bounds. More...
 
void EvaluateMultiPath (Robot &robot, const MultiPath &multipath, Real t, Config &q, Real xtol=0, Real contactol=1e-3, int numIKIters=100)
 Evaluate the multipath at time t with a smooth interpolator, possibly solving intermediate contact constraints. If the path has no resolution, or resolution > xtol, an IK solver is invoked to solve for the path's contact constraints.
 
bool OptimizeTimeScaling (const GeneralizedCubicBezierSpline &path, const Vector &vmin, const Vector &vmax, const Vector &amin, const Vector &amax, TimeScaling &scaling)
 Optimizes the given path according to velocity and acceleration bounds. The resulting time scaling is constrained to start and stop at 0 velocity. More...
 

Detailed Description

Function Documentation

bool AppendInterpolate ( SmoothConstrainedInterpolator interp,
const Vector &  pt,
Real  suffixDuration,
GeneralizedCubicBezierSpline &  path 
)

Adds a smooth path to the given point at the end of the provided path. The path extension has duration suffixDuration.

bool DiscretizeConstrainedMultiPath ( Robot robot,
const MultiPath path,
MultiPath out,
Real  xtol = 1e-2 
)

Given a coarsely discretized multipath, produces a finely discretized multipath that satisfies contact constraints.

See also
InterpolateConstrainedMultiPath
bool GenerateAndTimeOptimizeMultiPath ( Robot robot,
MultiPath multipath,
Real  xtol,
Real  dt 
)

Given a multipath, time-scales it to minimize execution time given the robot's velocity and acceleration bounds.

The geometric path is discretized with resolution xtol, and the time scaling is discretized with resolution dt.

bool InterpolateConstrainedMultiPath ( Robot robot,
const MultiPath path,
vector< GeneralizedCubicBezierSpline > &  paths,
Real  xtol = 1e-2 
)

Given a coarsely discretized multipath, produces a finely discretized, smooth curve with appropriate tangents across contact states.

Each segment must begin and end at transitions. xtol is the discretization resolution.

This can be applied to increase the resolution of already discretized paths, or just to produce a set of splines interpolating the path. It will check the path's "resolution" setting and discretize if empty or the resolution is greater than xtol.

Warning: the space and manifold members of the bezier paths will be bogus pointers. If you need to use them, you will need to set them to appropriate RobotCSpace and RobotGeodesicManifold objects (see code for GenerateAndTimeOptimizeMultiPath in RobotTimeScaling.cpp for an example).

bool MultiSmoothInterpolate ( SmoothConstrainedInterpolator interp,
const vector< Vector > &  pts,
GeneralizedCubicBezierSpline &  path 
)

Interpolates through several points smoothly using the given interpolator. The output durations are such that point i corresponds precisely to path parameter i.

bool MultiSmoothInterpolate ( SmoothConstrainedInterpolator interp,
const vector< Vector > &  pts,
const Vector &  dq0,
const Vector &  dq1,
GeneralizedCubicBezierSpline &  path 
)

Interpolates through several points smoothly using the given interpolator. The output durations are such that point i corresponds precisely to path parameter i. The endpoint derivatives are set to dq0 and dq1, respectively.

bool OptimizeTimeScaling ( const GeneralizedCubicBezierSpline &  path,
const Vector &  vmin,
const Vector &  vmax,
const Vector &  amin,
const Vector &  amax,
TimeScaling scaling 
)

Optimizes the given path according to velocity and acceleration bounds. The resulting time scaling is constrained to start and stop at 0 velocity.

Note: most Klamp't users will want to use the much more convenient functions in RobotTimeScaling.h.