MRSL Motion Primitive Library  1.2
A motion primitive library for generating trajectory for mobile robots
Public Member Functions | Protected Attributes | List of all members
PolySolver< Dim > Class Template Reference

Trajectory generator back-end class. More...

#include <poly_solver.h>

Public Member Functions

 PolySolver (unsigned int smooth_derivative_order, unsigned int minimize_derivative, bool debug=false)
 Simple constructor. More...
 
bool solve (const vec_E< Waypoint< Dim >> &waypoints, const std::vector< decimal_t > &dts)
 Solve the trajector as defined in constructor. More...
 
std::shared_ptr< PolyTraj< Dim > > getTrajectory ()
 Get the solved trajectory.
 

Protected Attributes

unsigned int N_
 Number of coefficients of a polynomial.
 
unsigned int R_
 Order of derivative to optimize.
 
MatDf A_
 
MatDf Q_
 
bool debug_
 Enble output on screen.
 
std::shared_ptr< PolyTraj< Dim > > ptraj_
 Solved trajectory.
 

Detailed Description

template<int Dim>
class PolySolver< Dim >

Trajectory generator back-end class.

Given intermediate waypoints and associated time allocation, generate the n-th order polynomials

Constructor & Destructor Documentation

◆ PolySolver()

template<int Dim>
PolySolver< Dim >::PolySolver ( unsigned int  smooth_derivative_order,
unsigned int  minimize_derivative,
bool  debug = false 
)

Simple constructor.

Parameters
smooth_derivative_orderThe max derivative we want continuous
minimize_derivativeThe derivative to minimize

Member Function Documentation

◆ solve()

template<int Dim>
bool PolySolver< Dim >::solve ( const vec_E< Waypoint< Dim >> &  waypoints,
const std::vector< decimal_t > &  dts 
)

Solve the trajector as defined in constructor.

Parameters
waypointsIntermediate waypoints that the trajectory pass through
dtsTime allocation for each segment

Note that the element in dts is the time for that segment


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