Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008 #ifndef ESCEKF_HPP_
00009 #define ESCEKF_HPP_
00010
00011 #include <labust/control/esc/EscPerturbationBase.hpp>
00012
00013 namespace labust{
00014 namespace control{
00015 namespace esc{
00016
00017
00018 class EscEkfGrad : public EscPerturbationBase<double> {
00019
00020 public:
00021
00022 EscEkfGrad(int ctrlNum, numericprecission Ts);
00023
00024 ~EscEkfGrad();
00025
00026 void initController(double sin_amp, double sin_freq, double corr_gain, double high_pass_pole, double low_pass_pole, double comp_zero, double comp_pole, double period, vector Q, vector R);
00027
00028 vector gradientEstimation(numericprecission cost_signal_filtered, vector additional_input);
00029
00030 vector controllerGain(vector postFiltered);
00031
00032 vector superimposePerturbation(vector control);
00033
00034 vector modelUpdate(vector state, vector input);
00035
00036 vector outputUpdate(vector state, vector input);
00037
00038
00039
00040
00041
00042 vector sin_amp_, sin_freq_, corr_gain_;
00043 vector control_ref_, signal_demodulated_old_, phase_shift_;
00044
00045 vector state_;
00046
00047
00048
00049 matrix A, L, H, M, Q, R;
00050 matrix Pk_plu, Pk_min, Kk;
00051 vector xk_plu, xk_min, hk;
00052
00053 vector input, input_past;
00054
00055
00056 vector yk;
00057
00058 Eigen::Vector3d n1, n2;
00059
00060 };
00061 }
00062 }
00063 }
00064
00065
00066
00067
00068 #endif