sot-torque-control
1.5.3
Collection of dynamic-graph entities aimed at implementing torque control on different robots.
|
|
Go to the documentation of this file.
7 #ifndef _POLY_ESTIMATOR_HH_
8 #define _POLY_ESTIMATOR_HH_
10 #include <Eigen/Dense>
19 void pinv(
const Eigen::MatrixXd& matrix_in, Eigen::MatrixXd& pseudo_inv,
const double& pinvtoler = 1.0e-6);
37 PolyEstimator(
const unsigned int& order,
const unsigned int& N,
const double& dt);
48 void estimate(std::vector<double>& estimee,
const std::vector<double>& data_element,
const double& time);
58 virtual void estimate(std::vector<double>& estimee,
const std::vector<double>& data_element) = 0;
68 virtual void estimateRecursive(std::vector<double>& estimee,
const std::vector<double>& data_element,
69 const double& time) = 0;
76 virtual void getEstimateDerivative(std::vector<double>& estimeeDerivative,
const unsigned int order) = 0;
131 std::vector<double>
t_;
135 std::vector<double>
x_;
double dt_
Sampling (control) time.
void estimate(std::vector< double > &estimee, const std::vector< double > &data_element, const double &time)
virtual void getEstimateDerivative(std::vector< double > &estimeeDerivative, const unsigned int order)=0
Eigen::VectorXd coeff_
Coefficients for the least squares solution.
void setWindowLength(const unsigned int &N)
bool dt_zero_
Indicate that dt is zero (dt is invalid)
void pinv(const Eigen::MatrixXd &matrix_in, Eigen::MatrixXd &pseudo_inv, const double &pinvtoler=1.0e-6)
std::vector< double > t_
Time vector setting the lowest time to zero (for numerical stability).
unsigned int N_
Window length.
unsigned int getWindowLength()
unsigned int order_
Order of the polynomial estimator.
unsigned int pt_
Circular index to each data and time element.
std::vector< double > time_list_
Time vector corresponding to each element in elem_list_.
virtual void estimateRecursive(std::vector< double > &estimee, const std::vector< double > &data_element, const double &time)=0
PolyEstimator(const unsigned int &order, const unsigned int &N, const double &dt)
std::vector< std::vector< double > > elem_list_
All the data (N elements of size dim)
virtual double getEsteeme()=0