%% June 2019
%% ENOC2020 template file for LaTeX modified by Sebastien Baguet, University of Lyon, France 
%% based on 
%% ENOC2017 template file for LaTeX modified by Gabor Csernak, Budapest University of Technology and Economics
%% ENOC2014 template file for LaTeX modified by Horst Ecker, Vienna University of Technology
%% ENOC2011 template file for LaTeX generated by Andrea Arena, Sapienza University of Rome
%% This file was generated with a LateX2e version.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass{enoc2020}
\usepackage{subfigure}
\usepackage{caption}
\usepackage{textcomp}

\title{Parametric study of a switching control model of stick balancing}

\author{\underline{Dalma J. Nagy}$^{\ast,{\dagger}}$, L\'aszl\'o Bencsik$^{{\dagger},{\ddagger}}$ and Tam\'as Insperger $^{\ast,{\dagger}}$}

\address{$^\ast$Department of Applied Mechanics, Budapest University of Technology and Economics, Budapest, Hungary\\  
$^{\dagger}$MTA-BME Lend\"ulet Human Balancing Research Group, Budapest, Hungary\\
$^{\ddagger}$MTA-BME Research Group on Dynamics of Machines and Vehicles, Budapest, Hungary
}

\abstract{We are interested in understanding the control mechanism employed by the central nervous system during stick balancing on the fingertip. 
Although this is a relatively simple balancing task, the underlying control law is still not yet fully understood. 
In this research, predictor feedback is applied in the mechanical model of stick balancing by taking into account the dead zone of human perception of the stick's state and the reaction delay.
Using these assumptions, we derive a switched control model whose behaviour is then investigated as the function of the system parameters.}

\begin{document}

\section{Introduction}

In recent years, the interest on studying human balancing from an engineering point of view is constantly growing \cite{Kowalczyk2012}. 
The results of this research can be beneficial in helping people living with balance disorders and in the therapeutic motor control development of children.
Stick balancing on the fingertip represents the key features of dynamic balancing, namely, an unstable equilibrium should be stabilized in the presence of reaction time delay and sensory uncertainty.
Therefore, in this paper the stick balancing task is studied by developing the mechanical model and performing numerical analysis using the semidiscretization method for time-delay systems \cite{InspergerBook}.
There are several control concepts to model the balancing mechanism, e.g. delayed PD controller \cite{Mehta2002}, PDA controller \cite{Insperger2014}, intermittent controller \cite{Gawthrop2013}.
Measured time signals of stick balancing tasks suggest that nonlinearities due to switching-type control may be a key feature of human balancing \cite{Nagy2019}.
Here, a switching-type predictor controller is applied to model the control force exerted by human subjects.



\section{Mechanical model and applied controller}

Our research group has developed a device, in order to have a simplified measurement setup, where planar stick balancing can be carried out by human subjects. 
The stick is mounted on a cart via a pin joint and the cart is only allowed to move along a 1-meter-long rail. 
Subjects sit in a chair so their shoulders are parallel to the rail, therefore, the balancing occurs in the subject's medio-lateral plane \cite{Nordin1989}. 
It is assumed, that humans move only their forearm in this balancing task and not their upper arm. %, i.e. rotating movement of the forearm occurs around the axis of rotation of the elbow.
The mechanical model of the system is shown in Fig.~\ref{fig:mechanical_model}a), where the forearm of the subject is modelled by a truncated cone \cite{Hanavan1964}. 
The inertia of the forearm and hand can be modelled by a cart of equivalent mass $m_{\rm a}$ which is added to the mass of the cart $m_{\rm c}$ and thus, the system is reduced to a two-degree-of-freedom pendulum-cart model shown in Fig.~\ref{fig:mechanical_model}b), where $m_{\rm e}=m_{\rm a}+m_{\rm c}$.

\begin{figure}[h]
		\centering
		\subfigure[]{\includegraphics[height=3.5cm]{3Dmechanical_model.pdf}}
		\hspace{2cm}
		\subfigure[]{\includegraphics[height=3.5cm]{mechanical_model_MSSP.pdf}}
		\captionsetup{justification=centering}
		\caption{a) Schematic 3D figure of the stick balancing task. 
		The cart is linearly driven on a rail and the stick is pinned onto the cart via a planar joint. 
		The subject controls the cart with their hand using a handle that is rigidly fixed to the cart. 
		b) Reduced mechanical model of the stick balancing task.}
		\label{fig:mechanical_model} 
\end{figure}

By taking the generalised coordinates $x$ - the position of the cart - and $\varphi$ - the angular deviation of the stick -, the equation of motion can be derived for the 2 DoF system. 
However, $x$ is a cyclic coordinate, and therefore can be eliminated from the equation. After linearisation, the equation of motion reads
\begin{equation}\label{eq:eq_of_motion}
%	\begin{bmatrix} m+m_{\rm e} & \frac{1}{2}ml\cos \varphi(t) \\ \frac{1}{2}ml\cos \varphi(t) & \frac{1}{3}ml^2 \end{bmatrix}
%	\begin{bmatrix}
%	\ddot x(t) \\ \ddot \varphi(t)
%	\end{bmatrix}
%	=
%	\begin{bmatrix}
%	\frac{1}{2}ml \dot \varphi^2(t) \sin \varphi(t) \\ \frac{1}{2}mgl \sin \varphi(t)
%	\end{bmatrix}
%	+
%	\begin{bmatrix}
%	F(t) \\ 0
%	\end{bmatrix},
%	\label{eq:lin_eq_motion}
	\ddot \varphi(t) = \frac{6g}{c\,l}\, \varphi(t) -\frac{6 F(t)}{(m+m_{\rm e})c\,l},
\end{equation}

where $c=4-3m/(m+m_{\rm e})$, $m$ is the mass of the stick, $l$ is the length of the stick, $m_e$ is the equivalent mass of the cart, $g$ is the gravitational acceleration and $F(t)$ is the control force applied by the human. 
When applying predictor feedback, it is assumed that the internal model of the human is exact, that is it matches the actual system parameters as a result of a long enough learning process.
In this case, the feedback of the predicted state eliminates the delay from the control loop \cite{Insperger2014} and the control force of the switching-type model predictor feedback is:
\begin{equation}
F(t) = \begin{cases}
0 & {\rm if} |\varphi(t-\tau)| < \Pi_{\varphi} \ {\rm and} \ |\dot \varphi(t-\tau)| < \Pi_{\dot \varphi}, \\
P\varphi(t) & {\rm if} |\varphi(t-\tau)| \geq \Pi_{\varphi} \ {\rm and}\  |\dot \varphi(t-\tau)|< \Pi_{\dot \varphi}, \\
D\dot \varphi(t) & {\rm if} |\varphi(t-\tau)| < \Pi_{\varphi} \ {\rm and}\  |\dot \varphi(t-\tau)| \geq \Pi_{\dot \varphi}, \\
P\varphi(t) + D\dot \varphi(t) & {\rm if} |\varphi(t-\tau)| \geq \Pi_{\varphi} \ {\rm and}\  |\dot \varphi(t-\tau)| \geq \Pi_{\dot \varphi}, \\
\end{cases}
\end{equation}
where it is assumed, that the angular deviation and the angular velocity of the stick is sensed by the human perception and the prediction is made based on these measured values. 
The human sensory dead zone is also accounted for in the model of the control force, hence the switching. % of the control force. 
Different sensory dead zones are applied for the angle and angular velocity of the stick denoted by $\Pi_{\varphi}$ and $\Pi_{\dot \varphi}$, respectively. 
The switching of the control force occurs with a time delay $\tau$, since it takes a finite time for the human to detect that the stick is out of the dead zone, which is equal to the reaction delay of the subject. 
Substituting $F(t)$ into Eq.~\eqref{eq:eq_of_motion} gives a nonlinear model of human balance control.

\section{Numerical study}

A numerical study on the stability of the system is carried out using the semidiscretization method \cite{InspergerBook} as a function of the system parameters $P$, $D$ and $\tau$. 
The values of $m_e=1.73$ [kg], $m=0.1$ [kg] and $l=0.9$ [m] are held constant during the analysis. 
The equivalent mass is determined by anthropometric data from \cite{deLeva1996} and by measuring $m_c=0.12$ [kg].
Because of the model predictor feedback, the discrete map corresponds to a sampled output system without any feedback delay, where the stability diagram depends on the sampling time $\Delta t$.
The sampling time was set to $\Delta t=0.01$ [s].
Fixed value of sensory dead zone is applied for the angle $\Pi_{\varphi}=1$ [deg] and the sensory threshold for the angular velocity is varied between $\Pi_{\dot \varphi}=0.02...2\ {\rm [deg/s]}$.
%\begin{table}[ht!]
%	\centering
%	\begin{tabular}{ p{1.2cm} p{1.2cm}  p{1.2cm} }
%		$m_{\rm e}$ [kg] & $m$ [kg] & $l$ [m]  \\
%		\hline
%		1.61 & 0.1 & 0.9 \\ 
%	\end{tabular}
%	\caption{Values of parameters held constant during the numerical analysis.}
%	\label{table:parameters}
%\end{table}

%\subsection{Electronic submission of the Extended Abstract in PDF format}

%In order to submit a Extended Abstract the presenting author must also submit a Summary. 
%All authors must use the ENOC 2020 online submission system, available via the ENOC 2020 homepage. All submissions must be uploaded and completed by \emph{November 20, 2019}.



%\section{Poster presentation}
%Authors of papers selected for presentation in poster format will be expected to present their work concurrently with the aid of a A0 poster during a dedicated poster session. The poster session will start with a quick presentation of all posters, during which the PDF version of each poster will be displayed and each presenting author will be given a maximum of 90 seconds to provide an attractive overview of its poster. \\ 
%The Conference will provide poster boards. The usable area of a poster panel will correspond the size of an A0 sheet, i.e., approximately 1.2 m (height) by 0.85m (width).\\ 
%Posters should be prepared directly on one sheet. Be warned that posters made by taping together several sheets tend to look amateurish. The lettering should be large enough to be read by someone standing 2 m back from the poster and the following text sizes are suggested. Title: 2-3 cm; Authors' names and affiliations: 2 cm; Section headings (ABSTRACT, RESULTS, etc.): 2 cm. The text itself should be approximately 10 mm high.  The use of more diagrams, colour, and fewer words is recommended for clarity. Use phrases and short sentences in "bullet points". It is recommended that the poster be divided into sections:  a one or two sentence abstract; problem definition and/or aims; methods; results; conclusions.

\section{Conclusions}
%Prepare Extended Abstract as a PDF file, visit the ENOC 2020 web page enoc2020.sciencesconf.org \cite{ENOC}, create a sciencesconf.org account (if you have not already done so), and submit your Abstract following the instructions. Confirmation by e-mail will be sent to your e-mail address.
The parametric study leads to the detection of solutions converging to pseudo-equilibria that lies on the switching line determined by the size of the dead zone for the angle if the sensory dead zone of the angular velocity is sufficiently small and $\tau=0$ [s].
However, if the size of the dead zone of the angular velocity is large, a stable periodic orbit determined by both sensory dead zones can be observed for the parameter combination $P=30$ [N], $D=5$ [Ns] and $\tau=0$ [s]. 
Nevertheless, $\tau=0$ [s] is not physiologically feasible for the case of human balancing.
For a feasible value of time delay a stable symmetric orbit with a long period is found for the control gains $P=30$ [N], $D=5$ [Ns], and $\tau=0.3$ [s].%, shown in Fig.~\ref{fig:num_sim}.

\begin{figure}[h]
	\centering
	\subfigure[]{\includegraphics[height=3.5cm]{solution.pdf}}
	\hspace{2cm}
	\subfigure[]{\includegraphics[height=3.5cm]{phase_space.pdf}}
	\captionsetup{justification=centering}
	\caption{a) Numerical solution for control parameters $\tau = 0.3$ [s], $P=30$ [N], $D=5$ [Ns].
		b) Stable symmetric orbit in phase plane for the numerical solution.}
	\label{fig:num_sim} 
\end{figure}

 
\begin{thebibliography}{99}

\bibitem{Kowalczyk2012}P. Kowalczyk, P. Gledinning, M. Brown, G. Medrano-Cerda, H. Dallali, J. Shapiro (2012) Modelling human balance using switched systems with linear feedback control. \emph{J. R. Soc. Interface} \textbf{9}:234-245.

\bibitem{InspergerBook}T. Insperger, G. Stepan (2011) Semi-Discreatization for Time-Delay Systems - Stability and Engineering Applications. Springer NY.?

\bibitem{Mehta2002}B. Mehta, S. Schaal (2002) Forward models in visuomotor control. \emph{Journal of Neurophysiology} \textbf{88}:942-953.

\bibitem{Insperger2014}T. Insperger, J. Milton,  G. Stepan (2014) Sensory uncertainty and stick balancing at the fingertip. \emph{Biological Cybernetics} \textbf{108}(1):85-101.

\bibitem{Gawthrop2013}P. Gawthrop, K.-L. Lee, N. O\textquotesingle Dwyer, M. Halaki (2013) Human stick balancing: an intermittent control explanation. \emph{Biological Cybernetics} \textbf{107}:637-652

\bibitem{Nagy2019}D. J. Nagy, L. Bencsik, T. Insperger (2019) Experimental estimation of tactile reaction delay during stick balancing using cepstral analysis. \emph{Mechanical Systems and Signal Processing} submitted manuscript

\bibitem{Nordin1989}M. Nordin, V. H. Frankel (1989) Basic biomechanics of the musculoskeletal system. Lea \& Febiger.

\bibitem{Hanavan1964} E. P. Hanavan (1964) A Mathematical Model of the Human Body.  {\em Technical Report},  Aerospace Medical Research Laboratory Wright-Patterson Air Force Base, Ohio

\bibitem{deLeva1996}P. de Leva (1996) Adjustments to Zatsiorsky-Seluyanov \textquotesingle s segment inertia parameters. \emph{Journal of Biomechanics} \textbf{29}(9):1223-1230


%\bibitem{Icer}  Icer D.F., Adams J.A. (1977) Mathematical Elements for Computer Simulation. McGraw Hill, NY.
%\bibitem{Nygus} Nygus, G. (1983) Numerical Analysis Using Finite Element Method.  {\em PhD Thesis},  NTU Mech.  Eng.  Dept., Lagos.
%\bibitem{ENOC}  ENOC 2020 web site, https://enoc2020.sciencesconf.org

\end{thebibliography}
 \end{document}
