Research on HMM-based Exoskeleton Robot Falling Prediction Algorithm

Exoskeleton robot is essentially a wearable robot. In recent years, the research of exoskeleton robots has become a new hot spot, and has gradually been widely used in military, medical and civilian fields. However, the balance and safety issues of power-assisted exoskeleton robots need to be solved urgently. At present, although there are many researches on exoskeleton robots at home and abroad, the research on the falling problem of assisted lower limb exoskeleton robots is not in-depth. Existing studies on falls are mainly focused on the detection of falls, while the prediction of falls is relatively small, and these studies rely more on a single sensor, and its accuracy needs to be improved. In response to the status quo, This paper proposes a fall prediction algorithm based on HMM to study the fall behaviour of the exoskeleton human-machine system in advance, it provides a reference for the anti-fall measures of the exoskeleton robot and aims to effectively reduce the damage of the human-machine system.


Introduction
Since the 21st century, with the development of high-performance microprocessors, motors and a variety of high-precision sensors, the research on exoskeleton robots has gradually matured. As a wearable robot, exoskeleton robots have achieved unprecedented development in the military, medical and civilian field [1]. The term exoskeleton comes from biology, and with the development of technology, this concept has been applied to the field of robotics, and the integration of mechanical structure, information-coupling and automatic control technology has produced this kind of mechanical equipment worn outside the human body [2]. The main function of exoskeleton robots is to improve human exercise endurance and upper limit of weight, or to help the disabled and the elderly to walk [3].
Currently, exoskeleton robots have many applications in various fields, but there are still many problems to be solved on the road to commercialization. Among them, the balance and safety of exoskeleton robots are a difficult point. Based on this, this project mainly studies the fall methods and characteristics of the assisted lower extremity exoskeleton robot. By collecting data from multiple types of sensors on the exoskeleton robot, different fall behaviours are predicted and experimentally verified.

Mechanism analysis of man-machine system falling
Before analysing the fall process, the human-machine system fall needs to be defined. Here, the exoskeleton man-machine system fall is defined as: unintentionally falling on the ground or other lower positions due to terrain or the man-machine system itself [4]. The fall process of the human-machine system is generally divided into an initial state, an unbalanced state, an obstacle impact state, and a relatively stable state after falling to the ground. The various processes of falling behaviour are carried 2 out according to time. During the period, the more characteristic ones should be the changes in the orientation of the human-machine system and the drastic changes caused by collisions with low-power objects. When predicting the fall of the human-machine system, it is necessary to grasp the characteristics of the exoskeleton human-machine system before the first impact.
To study the kinematic characteristics of the fall behaviour of the exoskeleton human-machine system, the coordinates of each part need to be defined first [5]. The front of the exoskeleton robot is set to the positive direction of the x-axis, the left side is set to the positive direction of the y-axis, and the vertical upward direction is set to the positive direction of the z-axis, as shown in figure 1. The force changes during the movement of the human-machine system can be reflected by acceleration. Due to the different positions of its own motion or collision with surrounding objects, the force and acceleration changes of different body parts may be different. The force changes during the movement of the human-machine system can be reflected by acceleration. Due to the different positions of its own motion or collision with surrounding objects, the force and acceleration changes of different body parts may be different. Select the part that is more concentrated and stable in the impact force during different falls, then the change process of acceleration of this part can be used to describe the fall process. For example, select the acceleration of the waist and define the acceleration along the x axis as . Similarly, we get the acceleration of the waist as ⃗ = ( , , ), and the acceleration is: a = (a x 2 + a y 2 + a z 2 )

Hidden Markov model
Hidden Markov Model (HMM) is a statistical analysis model. Founded in the 1970s [6], after decades of development, it has been successfully used in speech recognition, behaviour recognition, text recognition and fault diagnosis. Hidden Markov model describes the process of generating a random sequence of unobservable states randomly from a hidden Markov chain, and then generating an observable random sequence from each state. Any HMM can be described by a formula: Next, how to apply HMM to the fall prediction of the human-machine system? First, we need to build a fall process model of the man-machine system. Secondly, the data collected by the humanmachine system acceleration sensor is fused and extracted as the observation sequence of the model, and the model parameters are estimated through the learning problem. Finally, through model matching, 3 the acquired acceleration time series belong to the model probability of the fall process. The following will introduce the method of solving the two problems of parameter estimation and probability estimation in the prediction problem.

Forward algorithm
The forward algorithm will first find the formula of the local state recursion during calculation, and then gradually advances the optimal solution of the sub-problem to the optimal solution of the entire problem, which is essentially a dynamic programming algorithm [7].
First, define the hidden state at time as ( = ), and the probability that the sequence of the observed state is = { 1 , 2 , ⋯ , } is the forward probability. Recorded as: Figure 2 illustrates the recursive principle of the forward algorithm: ( ) is the observed sequence = { 1 , 2 , ⋯ , } , and when the hidden state at time is ,the hidden state at time + 1 is the probability of . So =1 ( ) is the observed sequence = { 1 , 2 , ⋯ } , the probability that the hidden state at time + 1 is . According to the forward probability definition, +1 ( ) is that the hidden state at + 1 is , and the sequence of the observed state is = { 1 , 2 , … , +1 } . The probability that observation sequence = { , 2 , ⋯ , } has been observed at time and the observation state at time ( | ) = ∑ α ( ) =1 (6) From this, the time complexity of the forward algorithm is ( 2 ). Therefore, the total probability formula is:

Fall prediction algorithm based on HMM
The falling process of the human-machine system is a movement state that can be combined in chronological order. However, the current state cannot be judged by simply setting the threshold value directly through the acceleration signal. It is necessary to analyse the characteristics of the fall process through the change of acceleration [8]. In this paper, the HMM method is used to establish a probabilistic mathematical model for the fall process to realize the prediction of the fall process of the man-machine system.
(1) Data sample division By repeatedly collecting data at each stage of the fall process of the human-machine system, the samples collected during the fall process are divided into training sample sets, statistical sample sets, and test sample sets. See table 1 for specific division and composition. (2) Feature extraction of acceleration signal First, perform feature extraction on the back three-axis acceleration signal in the training sample set [9]. According to formula (1), the three-axis acceleration signal is converted into a combined acceleration signal and the obtained acceleration signal is pre-processed, and then the data of each sampling point of the combined acceleration time series is merged into a group, and the sampling points The mean value of is used to characterize the resultant acceleration data in this × time period. Here, because the value of m is 3, the algorithm calculation process can be simple and time-sensitive. Therefore, the expression of the resultant acceleration can be obtained: ( ) = mean(∑ = × ), = 1,2, ⋯ , (8) Through experimental analysis, when the human body is standing or walking normally, the combined speed is generally about 9.8 ∕ 2 . When the human body falls, the combined acceleration can reach 8 times the acceleration of gravity. Therefore, it is necessary to use a piecewise function to express the total acceleration value in sections and convert the acceleration value of each section into a label.
The value range of is [0, +∞), and the number of labels is an integer . Based on the above analysis, [9,11] 2 ⁄ can be used as the first segment. The instantaneous acceleration will far exceed the normal acceleration, so [20, +∞] 2 ⁄ is used as the last segment. According to multiple experiments, take = 8 , and set [0, 9). And [11,20) are divided into six segments. Finally, the piecewise function of the characteristic time series is: 4 , ( ) ∈ [9,11) + 5 , ( ) ∈ [3 + 11,3 + 14) 8 , ( ) ∈ [20, +∞) among them = 0,1,2， = 0,1,2.   After many experiments on the statistical sample set, table 2 shows the maximum value of the model λ matching probability under each behaviour mode. After many adjustments, a pair of relatively suitable thresholds is obtained: 1 = 0.41， 2 = 0.67. When ( | ) ∈ [0, 1 ), it can be judged that the current human-machine system is in a normal state of motion; when ( | ) ∈ [ 1 , 2 ) , further judgment is required, which is recorded as state 1; ( | ) ∈ [ 2 , 1], it can be judged that the current human-machine system is in the state of falling weightless, which is recorded as state 2.  figure 4. At the beginning, the resultant acceleration is about 9.8m s 2 ⁄ , and the prediction algorithm judges that it is in state 0, that is, the normal standing stage. When the falling behaviour is just beginning, the combined acceleration has a slower downward trend, and the prediction algorithm judges that it is in state 1, that is, a relatively unstable state. When the combined acceleration drops to about 5 2 ⁄ , the prediction algorithm judges that it is in state 2, that is, the state of falling weightless. When the acceleration increases sharply, the prediction algorithm judges that the state returns to 0. In summary, the model based on the HMM pattern recognition method before the impact of the fall and collision can better identify the early actions of the fall and achieve certain prediction purposes.

Conclusions
This article is a research on the fall prediction algorithm of the assisted lower limb exoskeleton robot. In the research process, the fall behaviour and characteristics of the assisted lower extremity exoskeleton human-machine system are analysed first, and the falls are classified and the stability margin changes during the fall are discussed; The improved algorithm based on HMM is used to predict different fall behaviours and perform experimental verification. The main idea of the improved algorithm is to first analyse the acceleration time series with the HMM-based fall prediction model, analysing the risk of falling, then the values selected for further verification and identification of the type fall prediction algorithm according to whether a fall risk of falling. The improved fall prediction algorithm has a relatively high accuracy rate, and it can predict the occurrence of falling behaviour in a relatively short time. This laid the foundation for the subsequent study of fall protection measures.