Skip to content

KRproject-tech/Parameter_estimation_demo_by_UKF

Repository files navigation

Parameter_estimation_demo_by_UKF

Communication

Twitter

Language

Parameter estimation Demo by Unscented Kalman Filter (UKF) 12. Example of dynamics is for the 1 DoF arm with spring, damping, and frictional forces at a joint. Joint angle is measured, then, unknown damping and frictional coefficients are identified by UKF 34. In spite of discontinuous model of frictional force, UKF can be applied dislike Extended Kalman Filter (EKF).

Overview

Dynamics for the 1 DoF arm with spring, damping, and frictional forces at a joint is denoted as follows,

$$ J \ddot{\theta} + c \dot{\theta} + \mu {\rm sgn}{\dot{\theta}} + k \theta = u, $$

where damping and friction coefficients; $c$ and $\mu$ are unknown variables. From measured time series of data $y_m := \theta_m(t)$, these variables are identified by UKF.

Then, state space representation is denoted as,

$$ \begin{array}{c} {\bf \dot{x}} = f( {\bf x}, {\bf u}), \\ y = {\bf C} {\bf x}, \end{array} $$

where

$$ \begin{array}{c} {\bf x} = \left[ \begin{array}{c} x_1 \\ x_2 \\ \end{array} \right] := \left[ \begin{array}{c} \theta \\ \dot{\theta} \\ \end{array} \right], \\ f( {\bf x}, {\bf u}) := \left[ \begin{array}{c} x_2 \\ -J^{-1} c x_2 - J^{-1} \mu {\rm sgn} x_2 - J^{-1}k x_1 \\ \end{array} \right] + {\bf B} u, \\ \bf{B} := \left[ \begin{array}{c} 0 \\ J^{-1} \\ \end{array} \right], {\bf C} := \left[ \begin{array}{c} 1 \\ 0 \\ \end{array} \right]^T. \end{array} $$

Unknown damping and frictional coefficients are added to the expanded state vector as

$$ {\bf x_E} = \left[ \begin{array}{c} {\bf x} \\ x_3 \\ x_4 \\ \end{array} \right] := \left[ \begin{array}{c} {\bf x} \\ c \\ \mu \\ \end{array} \right]. $$

After that, the dynamics is discretized for time to apply UKF ("./functions/c2d_func.m" [3]).

図1

Usages

[Step 1] Edit parameters

Edit code in "param_setting.m".

[Step 2] Start analysis

Execute "demo.m".

Images

time_series_angle

Time series of state $x_1 := \theta (t)$.

untitled

Time series of output $y(t) := x_1(t)$

identified_parameters

Identified damping and friction coefficients; $c$ and $\mu$, and deviations; $\sigma_c$ and $\sigma_\mu$, respectively.

References

Footnotes

  1. Julier, S.J., Uhlmann, J.K., 2004. Unscented filtering and nonlinear estimation. Proc. IEEE 92 (3), 401–422.

  2. Julier, S.J., Uhlmann, J.K., Durrant-Whyte, H.F., 1995. A new approach for filtering nonlinear systems. In: Proceedings of 1995 American Control Conference. ACC’95 3, pp. 1628–1632. http://dx.doi.org/10.1109/ACC.1995.529783.

  3. 足立 修一,丸田 一郎,「カルマンフィルタの基礎」,東京電機大学出版局.

  4. Fluid force identification acting on snake-like robots swimming in viscous fluids, Journal of Fluids and Structures, Vol. 106 (2021).
    https://doi.org/10.1016/j.jfluidstructs.2021.103351

Releases

No releases published

Packages

No packages published

Languages