30 #ifndef TOWR_VARIABLES_POLYNOMIAL_H_ 31 #define TOWR_VARIABLES_POLYNOMIAL_H_ 36 #include <Eigen/Dense> 65 explicit Polynomial(
int poly_order,
int poly_dim);
114 void SetDuration(
double duration);
121 void SetNodes(
const Node& n0,
const Node& n1);
132 VectorXd GetDerivativeOfPosWrtDuration(
double t)
const;
140 double GetDerivativeWrtStartNode(
Dx dfdt,
Dx node_deriv,
double t)
const;
148 double GetDerivativeWrtEndNode(
Dx dfdt,
Dx node_deriv,
double t)
const;
153 const double GetDuration()
const {
return T_; };
160 double GetDerivativeOfPosWrtStartNode(
Dx node_deriv,
double t_local)
const;
161 double GetDerivativeOfVelWrtStartNode(
Dx node_deriv,
double t_local)
const;
162 double GetDerivativeOfAccWrtStartNode(
Dx node_deriv,
double t_local)
const;
164 double GetDerivativeOfPosWrtEndNode(
Dx node_deriv,
double t_local)
const;
165 double GetDerivativeOfVelWrtEndNode(
Dx node_deriv,
double t_local)
const;
166 double GetDerivativeOfAccWrtEndNode(
Dx node_deriv,
double t_local)
const;
171 #endif // TOWR_VARIABLES_POLYNOMIAL_H_ Stores at state comprised of values and higher-order derivatives.
A polynomial of arbitrary order and dimension.
double T_
the total duration of the polynomial.
std::vector< Coefficients > CoeffIDVec
Node n1_
the start and final node comprising the polynomial.
Polynomial(int poly_order, int poly_dim)
Constructs a polynomial with zero coefficient values.
double GetDerivativeWrtCoeff(double t, Dx poly_deriv, Coefficients coeff) const
The derivative of the polynomial with respect to the coefficients.
std::vector< VectorXd > coeff_
virtual ~Polynomial()=default
Represents a Cubic-Hermite-Polynomial.
State GetPoint(double t) const
A node represents the state of a trajectory at a specific time.
Dx
< the values or derivative. For motions e.g. position, velocity, ...