The next design step aims to develop a sliding mode observer that provides both, an estimate of the unmeasured system state, i.e. the piston velocity
\(x_{2}\), and the external load force
\(F_{\mathrm{ext}}\). The observer is based on higher order sliding mode (HOSM) differentiators of arbitrary order proposed by Levant [
9]. A HOSM differentiator allows real time robust exact time-differentiation of the measured system output up to any desired order
\(n\) supposing that its
\(n\)th derivative has known Lipschitz constant
\(L\). An exact differentiator provides output signals
\(z_{i}\)
\((i=0,1,\ldots,n)\) coinciding with the first
\(n\) time-derivatives of a noise-free input signal
\(x_{0}\) within finite time. Denoting the estimation error by
$$\begin{aligned} \sigma_{0}&:=z_{0}-x_{0}, \end{aligned}$$
(27)
the recursive form of the
\(n\)th order HOSM differentiator is written as
$$\begin{aligned} \begin{aligned} \dot {z}_{0}&=-\mu_{0}|\sigma|^{\frac{n}{n+1}} \mathrm{sign}(\sigma )+z_{1}, \\ \dot {z}_{1}&=-\mu_{1} |\sigma|^{\frac{n-1}{n+1}}\mathrm{sign}(\sigma )+z_{2}, \\ &\vdots \\ \dot {z}_{n}&=-\mu_{n} \mathrm{sign}({\sigma}). \end{aligned} \end{aligned}$$
(28)
The estimation error dynamics is captured by the differential inclusion
$$\begin{aligned} \begin{aligned} \dot {\sigma}_{i}&=-\mu_{i}| \sigma|^{\frac{n-i+1}{n+1}}\mathrm {sign}(\sigma)+\sigma_{i+1}, \\ \dot {\sigma}_{n}&\in-\mu_{n}\mathrm{sign}({\sigma})+[-L,L], \end{aligned} \end{aligned}$$
(29)
where
\(\sigma_{i}:=z_{i}-x_{i}\) and
$$\begin{aligned} \dot {x}_{k-1}=x_{k} \quad\text{with } k=1,\ldots,n+1. \end{aligned}$$
(30)
It is well known that the accuracy of this differentiator in the presence of noise is given by
$$\begin{aligned} |\sigma_{i}|=\mathcal{O} \bigl(\varepsilon^{\frac{n+1-i}{n+1}} \bigr) \end{aligned}$$
(31)
which is shown to be asymptotically optimal in the presence of infinitesimal input noises, see [
10]. For the implementation at the hydraulic setup it is more likely to consider a discrete time version of the differentiator. Typically, the Euler numerical scheme is applied to obtain a discrete time version of (
28). However it is known from literature, that this causes differentiation accuracy deterioration and therefore, in this paper, a proper discretization scheme preserving the accuracy properties of (
28) is used. This discrete time differentiator is given by
$$\begin{aligned} \begin{aligned} {z}_{i,k+1}&={z}_{i,k}-\tau \mu_{0}|\sigma|^{\frac{n-i}{n+1}}\mathrm {sign}(\sigma)+\sum \limits _{j=1}^{n-i}\frac{\tau^{j}}{j!} z_{j+i,k} \\ {z}_{n,k+1}&=z_{n,k}-\tau\mathrm{sign}({\sigma}), \end{aligned} \end{aligned}$$
(32)
see [
10]. Under constant sampling, with sampling step size
\(\tau\), the accuracies
$$\begin{aligned} |\sigma_{i}|\leq\bar{\mu}_{i}\rho^{n-i+1},\quad \rho=\mathrm{max}\bigl\{ \tau,\,\varepsilon^{\frac{1}{n+1}}\bigr\} \end{aligned}$$
(33)
are established in finite time. Therein the positive constants
\(\bar{\mu}_{i}\) depend only on the differentiator parameters
\(\mu_{i}\).
For the design purpose consider the dynamics of the piston movement captured by Eq. (
17) expressed as
$$\begin{aligned} \dot {x}_{1}&=x_{2}, \\ \dot {x}_{2}&=\frac{1}{m_{k}} (F_{L}-F_{r}-F_{\mathrm{ext}} ), \end{aligned}$$
(34)
where
\(x_{1}\) is measured. In order to reconstruct the piston velocity
\(x_{2}\) and the bounded external load force
\(F_{\mathrm{ext}}\) a differentiator of minimum order two is required. Motivated by relation (
33), a 3rd order differentiator is implemented. Hence, the order artificially is increased by one which yields improved estimates in the presence of noise and sampling. In particular the observer for system (
35) based on the differentiator reads as
$$\begin{aligned} \begin{aligned} \dot {z}_{0}&=-\mu_{0}|z_{0}-x_{1}|^{\frac{3}{4}} \mathrm {sign}(z_{0}-x_{1})+z_{1}, \\ \dot {z}_{1}&=-\mu_{1}|z_{0}-x_{1}|^{\frac{1}{2}} \mathrm {sign}(z_{0}-x_{1})+z_{2}+ \frac{1}{m_{k}} (F_{L}-\hat{F_{r}} ), \\ \dot {z}_{2}&=-\mu_{2}|z_{0}-x_{1}|^{\frac{1}{4}} \mathrm {sign}(z_{0}-x_{1})+z_{3}, \\ \dot {z}_{3}&=-\mu_{3}\mathrm{sign}(z_{0}-x_{1}). \end{aligned} \end{aligned}$$
(35)
Introducing the observer estimation error
\(e_{0}:=z_{0}-x_{1}\) the estimation error dynamics is given by
$$\begin{aligned} \begin{aligned} \dot {e}_{0}&=-\mu_{0}|e_{0}|^{\frac{3}{4}} \mathrm{sign}(e_{0})+e_{1}, \\ \dot {e}_{1}&=-\mu_{1}|e_{0}|^{\frac{1}{2}} \mathrm{sign}(e_{0})+e_{2}, \\ \dot {e}_{2}&=-\mu_{2}|e_{0}|^{\frac{1}{4}} \mathrm{sign}(e_{0})+e_{3}, \\ \dot {e}_{3}&=-\mu_{3}\mathrm{sign}(e_{0})+ \frac{1}{m_{k}}\ddot {F}_{\mathrm{ext}}. \end{aligned} \end{aligned}$$
(36)
where
\(e_{1}:=z_{1}-x_{2}\),
\(e_{2}:=z_{2}+\frac{F_{\mathrm{ext}}}{m_{k}}\) and
\(e_{3}=z_{3}+\frac{1}{m_{k}}\dot {F}_{\mathrm{ext}}\). It should be noted, that the friction force
\(F_{r}\) is assumed to be compensated by
\(\hat{F}_{r}\) exactly and it is supposed that
$$\begin{aligned} \bigl\vert \ddot {F}_{\mathrm{ext}}(t)\bigr\vert \leq L m_{k}, \qquad\forall t\geq0. \end{aligned}$$
(37)
Note that the structure of Eq. (
36) is equivalent to (
29). Hence, the estimation errors converge to zero within finite time. Consequently the velocity and the external force are recovered by
$$\begin{aligned} \hat{x}_{2}=z_{1}, \qquad\hat{F}_{\mathrm{ext}}=m_{k}z_{2}, \end{aligned}$$
(38)
respectively. According to the discrete time differentiator in Eq. (
32) the observer is implemented as
$$\begin{aligned} \begin{aligned} {z}_{0,k+1}&={z}_{0,k}- \tau\mu_{0}|e_{0,k}|^{\frac{3}{4}}\mathrm {sign}(e_{0,k}) \\ &\quad +\tau z_{1,k}+\frac{\tau^{2}}{2}z_{2,k}+ \frac{\tau ^{3}}{3!}z_{3,k}, \\ {z}_{1,k+1}&={z}_{1,k}-\tau\mu_{1}|e_{0,k}|^{\frac{2}{4}} \mathrm {sign}(e_{0,k}) \\ &\quad +\tau z_{2,k}+\frac{\tau^{2}}{2}z_{3,k}+\tau \frac {1}{m_{k}} (F_{L}-\hat{F_{r}} ), \\ {z}_{2,k+1}&={z}_{2,k}-\tau\mu_{2}|e_{0,k}|^{\frac{1}{4}} \mathrm {sign}(e_{0,k})+\tau z_{3,k}, \\ {z}_{3,k+1}&={z}_{3,k}-\tau\mu_{3} \mathrm{sign}(e_{0,k}). \end{aligned} \end{aligned}$$
(39)