Polinomial5
Class that implements a 5th order polinomial section. More...
#include <Polinomial5.h>
Inherits from PathSection
Public Functions
Name | |
---|---|
Polinomial5(std::array< double, 5 > a, std::array< double, 5 > b, double c) Constructor for the Polinomial5 class, that receives the desired plane for the polinomial. |
|
virtual Eigen::Vector3d | eq_pd(double t) override The Path section equation. |
virtual Eigen::Vector3d | eq_d_pd(double t) override First derivative of the path section equation with respect to the path parameter t. |
virtual Eigen::Vector3d | eq_dd_pd(double t) override Second derivative of the path section equation with respect to the path parameter t. |
virtual double | getClosestPointGamma(Eigen::Vector3d & coordinate) override Method for getting the gamma of the closes point to the path. |
Additional inherited members
Public Functions inherited from PathSection
Name | |
---|---|
virtual double | tangent(double t) Default method for computing the tangent to the path section. |
virtual double | curvature(double t) Default method for computing the curvature. The default implementation implements the general formula to compute the curvature based on the derivative equations of the path. |
virtual double | derivative_norm(double t) Default method for computing the norm of the derivative. |
bool | can_be_composed() Method to return whether a pathSection can be composed with other path sections or not. |
double | limitGamma(double t) Method to limit the gamma between the minimum and maximum value By default the maximum gamma is a very high number. |
double | getMaxGammaValue() Method used to get the maximum gamma allowed by the path section By the default is the maximum valid number possible in c++. |
double | getMinGammaValue() Method used to get the minimum gamma allowed by the path section By default is the minimum valid number possible in c++. |
virtual | ~PathSection() Virtual destructor for the abstract class. |
Protected Functions inherited from PathSection
Name | |
---|---|
PathSection(bool can_be_composed) Constructor for the abstract class i NOTE: this class is virtual, therefore an object of type PathSection cannot be instantiated in memory. Only derivatives of the class PathSection. |
|
bool | setMaxGammaValue(double gamma_max) Method to update the max of the gamma parameter Validates if the value received is greater than gamma_min. |
bool | setMinGammaValue(double gamma_min) Method to update the min value of the gamma parameter Validades if the value is received is smaller than gamma_max. |
double | GradientDescent(double gamma_o, Eigen::Vector3d & x_pos, double tolerance) Method that implements the gradient descent to minimize the error of |
double | getInitialGammaEstimate(Eigen::Vector3d & x_pos, int num_partitions, double min_val, double max_val) Method to get an initial estimate for the gamma. It divides the section into n sections and search for local minimums in the function that computes the distance of the vehicle inside those sections. |
double | bisection(Eigen::Vector3d & x_pos, double a, double b) Method to implement bisection method |
Detailed Description
class Polinomial5;
Class that implements a 5th order polinomial section.
Author:
- Marcelo Jacinto
- Joao Quintas
- Joao Cruz
- Hung Tuan
Version: 1.0a
Date: 2021
Copyright: MIT
This class is used as a part of the sections library
Public Functions Documentation
function Polinomial5
Polinomial5(
std::array< double, 5 > a,
std::array< double, 5 > b,
double c
)
Constructor for the Polinomial5 class, that receives the desired plane for the polinomial.
Parameters:
- offset The 2D start point of the arc
function eq_pd
virtual Eigen::Vector3d eq_pd(
double t
) override
The Path section equation.
Parameters:
- t The path parameter
Return: An Eigen::Vector3d with the equation of the path with respect to the path parameter
Reimplements: PathSection::eq_pd
function eq_d_pd
virtual Eigen::Vector3d eq_d_pd(
double t
) override
First derivative of the path section equation with respect to the path parameter t.
Parameters:
- t The path parameter t
Return: An Eigen::Vector3d with the equation of the partial derivative with respect to the path parameter
Reimplements: PathSection::eq_d_pd
function eq_dd_pd
virtual Eigen::Vector3d eq_dd_pd(
double t
) override
Second derivative of the path section equation with respect to the path parameter t.
Parameters:
- t The path parameter t
Return: An Eigen::Vector3d with the equation of the second order partial derivative with respect to the path parameter
Reimplements: PathSection::eq_dd_pd
function getClosestPointGamma
virtual double getClosestPointGamma(
Eigen::Vector3d & coordinate
) override
Method for getting the gamma of the closes point to the path.
Parameters:
- The coordinate of the vehicle in the 3D space
Return: A double with the gamma corresponding to the closest point in the path
Reimplements: PathSection::getClosestPointGamma
Updated on 2022-09-15 at 17:51:29 +0000