Next Article in Journal
Chiral Liquid Crystal Microdroplets for Sensing Phospholipid Amphiphiles
Next Article in Special Issue
Wearable Flexible Electronics Based Cardiac Electrode for Researcher Mental Stress Detection System Using Machine Learning Models on Single Lead Electrocardiogram Signal
Previous Article in Journal
Cell-Membrane Biomimetic Indocyanine Green Liposomes for Phototheranostics of Echinococcosis
Previous Article in Special Issue
An Ultra-Low Power Surface EMG Sensor for Wearable Biometric and Medical Applications
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

A Differentiable Dynamic Model for Musculoskeletal Simulation and Exoskeleton Control

1
Department of Biomedical Engineering, National Yang Ming Chiao Tung University, Taipei 11221, Taiwan
2
School of Medicine, National Yang Ming Chiao Tung University, Taipei 11221, Taiwan
3
Department of Neurological Surgery, Neurological Institute, Taipei Veterans General Hospital, Taipei 11217, Taiwan
4
Department of Neurological Surgery, University of Washington, Seattle, WA 98195-6470, USA
5
Biomedical Engineering Research and Development Center, National Yang Ming Chiao Tung University, Taipei 11221, Taiwan
6
The Ph.D. Program for Neural Regenerative Medicine, College of Medical Science and Technology, Taipei Medical University, Taipei 11031, Taiwan
7
Department of Physical Medicine and Rehabilitation, China Medical University Hospital, Taichung 404332, Taiwan
8
School of Chinese Medicine, College of Chinese Medicine, China Medical University, Taichung 406040, Taiwan
9
Department of Neurology, Hualien Tzu Chi Hospital, Buddhist Tzu Chi Medical Foundation, Hualien 97002, Taiwan
10
Department of Neurology, School of Medicine, Tzu Chi University, Hualien 97004, Taiwan
11
School of Electrical and Computer Engineering, Georgia Institute of Technology, Atlanta, GA 30332, USA
*
Authors to whom correspondence should be addressed.
These authors contributed equally to this work.
Biosensors 2022, 12(5), 312; https://doi.org/10.3390/bios12050312
Submission received: 31 March 2022 / Revised: 5 May 2022 / Accepted: 6 May 2022 / Published: 9 May 2022
(This article belongs to the Special Issue Wearable EMG Sensors for Smart Applications)

Abstract

:
An exoskeleton, a wearable device, was designed based on the user’s physical and cognitive interactions. The control of the exoskeleton uses biomedical signals reflecting the user intention as input, and its algorithm is calculated as an output to make the movement smooth. However, the process of transforming the input of biomedical signals, such as electromyography (EMG), into the output of adjusting the torque and angle of the exoskeleton is limited by a finite time lag and precision of trajectory prediction, which result in a mismatch between the subject and exoskeleton. Here, we propose an EMG-based single-joint exoskeleton system by merging a differentiable continuous system with a dynamic musculoskeletal model. The parameters of each muscle contraction were calculated and applied to the rigid exoskeleton system to predict the precise trajectory. The results revealed accurate torque and angle prediction for the knee exoskeleton and good performance of assistance during movement. Our method outperformed other models regarding the rate of convergence and execution time. In conclusion, a differentiable continuous system merged with a dynamic musculoskeletal model supported the effective and accurate performance of an exoskeleton controlled by EMG signals.

1. Introduction

The exoskeleton, a wearable device, was designed according to the physical and cognitive interactions of the users. Exoskeletons have been developed for diverse medical purposes, including strength augmentation [1], rehabilitating neurological impairment [2], and assisting daily activities caused by neuro-musculoskeletal disorders [3]. In each application, the design of the exoskeleton would be based on the understanding of the users’ intention to control the device to achieve precise execution of the intended movement.
Thus, for patients with stroke or spinal cord injury, decoding motor signals from electromyography (EMG) or neural signals from electrocorticography (ECoG) [4,5] would be crucial for controlling exoskeletons and helpful by assisting these patients in restoring daily functions. The effect of the muscle spindle on muscle tension can be mathematically quantified as a neuromuscular model and combined with control theory to optimize the system for a human limb to operate the device [6,7]. This creates the potential for developing the exoskeleton-assisted rehabilitation approach into a personalized therapy.
For controlling an exoskeleton, several physiological signal sources, including force sensors [8] or biomedical signals, such as EMG [9] and electroencephalography (EEG) [10], were used with excellent performance. In the preceding study, the force sensor systems used over hip-mounted exoskeletons for elders with walking difficulties caused by muscle weakness. The results demonstrated that the sensor system can generate torque in the walking-assistant actuator from the direct measurement of the hip-assistance force and that the gait-assistance exoskeleton system can control the delivered power and torque for the user [8].
However, in that study, the coordination and interaction between physical activity and cognitive control was limited for the force sensor system because the predetermined trajectory could not synchronize the user’s intension to actively coordinate the muscle movements simultaneously. The force sensor system could only be activated by the predetermined trajectory of the exoskeleton when the actual output was lower than the threshold or deviated from the predetermined trajectory. The unsynchronized interaction, as well as a large time delay, between physical movements and the force sensors increased the risk of tripping [11].
For EEG to be used as the input to control the exoskeleton, direct brain signal recording has been measured on the scalp. In previous studies, the exoskeleton could be controlled via the brain-computer interface by using EEG signals [12,13]. However, because of brain pathology, including stroke, Parkinson’s disease, or brain injury, EEG signals varied across subjects and their use had to be highly customized and needed a long learning period, rendering the approach inefficient for real-time applications [14]. This necessitated the design of a control algorithm that can detect the user’s intention fast and does not rely on a predetermined trajectory.
To overcome the limitations posed by the time delay between the user’s intentions and the force sensor system, it is crucial to directly decode biomedical signals recorded from the nervous system or the musculoskeletal system. EMG signals are relatively easy to obtain and contain the information about body movement. Other investigators have used machine learning or neural networks to learn and predict the joint angles [15] and torques [16,17,18] of the human body during movement.
In one example, the artificial neural network technique was applied to EMG signals to predict the joint torque estimation model, and the trained model was used in the arm rehabilitation device aiding limb-paralyzed patients. Although the methods of machine learning or neural networks had performed well on decoding, their “black-box” transformation of the biomedical signals was lacking biomechanical explanation, which remains a source of controversy in these applications.
The Hill-type muscle model [19], built of contractile, series elastic, and parallel elastic components, offers a clear biomechanical explanation of the mechanical responses representing muscle behaviors [20,21]. An application of the Hill-type muscle model was shown to be capable of accurately simulating gait in a three-dimensional (3D) model, according to the EMG signals recorded from healthy populations [22].
For a more advanced application to not only healthy subjects but also paralyzed patients, a Hill-type muscle model, complete with output activation and torque-angles, was used to determine the muscle parameters for biomechanical computer simulations. This method was able to provide adaptive control and generate muscle responses in real-time. Thus, the Hill-type muscle model implements a biomechanical mechanism for natural and reliable interaction between assistance and estimation [23,24], and could also be considered in the design of exoskeleton control [24,25].
Although the control of neuromuscular stimulation and the exoskeleton can be done cooperatively, it requires an accurate and robust system to identify the parameters. To improve the accuracy of the identified parameters, an iterative method of the sequential least-squares quadratic programming (SLSQP) [26,27,28] with approximate gradients and second-order derivatives was used to optimize the parameters of the musculoskeletal model. However, using gradient approximation in the musculoskeletal model for parameter tuning and muscle force estimation required more iterations, and therefore more computational time.
To make it practicable, the musculoskeletal model had to be simplified [29]. Due to the challenges of analyzing complex models, gradient-free methods such as linear optimization, genetic algorithms [30,31], and the Nelder–Mead (NM) algorithm [11,23,25] were often used to optimize parameters in the musculoskeletal models. However, the adjusted parameters obtained with gradient-free methods can easily diverge, making the initialization of parameters challenging.
To tackle the challenges described above, we introduced the method of differentiable systems [32] applied to spring-damper models in 2D and 3D, which also was used for adjoint optimization on 3D rigid body engines [33], and the integration of articulated body dynamics into deep-learning frameworks and gradient-based optimization of neural networks that operated on articulated bodies [34]. Our proposed model was tested with healthy people for control of the knee exoskeleton in flexion–extension movements, which merged a differentiable continuous system with a dynamic musculoskeletal model to support an effective and accurate performance for an exoskeleton controlled by EMG signals.
The main biological and engineering contributions of this study are as follows. First, we propose a differentiable continuous system control that achieves assist-as-needed control by integrating the dynamics of musculoskeletal models and analyzing the interaction between the user and the exoskeleton. Second, in this continuous system, we implement an analytical gradient and updating mechanism for the muscular excitation parameters. As a result, and in contrast to previous gradient approximation methods and gradient-free methods, our proposed model is capable of providing the robust and accurate gradients needed to obtain the parameters in the musculoskeletal model.

2. Materials and Methods

2.1. Myoelectric Processor

Subjects used a wearable and wireless EMG amplifier (Artise Biomedical Co., Ltd., Taiwan) equipped with eight bipolar signal channels that were connected with medical grade button snap cables, common in clinical practice, to pairs of surface electrodes (Red Dot™, 3M, Maplewood, MN, USA) located on the targeted muscle tissues. Body ground was applied on the leg to increase the signal-to-noise ratio.
The acquired EMG signals were amplified by a 12× programmable gain, sampled at 1000 Hz, digitized at 24-bit with delta-sigma ADC (Texas Instruments, Dallas, TX, USA), and transmitted to a customized radio-frequency receiver dongle connected to the computer as a COM port input. The baud rate was configured at 921,600 bits/s to enable high-speed transmission. Sampled data was labeled by time stamp and channel counter, passed through an error-control mechanism [35] to achieve highly synchronized and simultaneous recording. The raw EMG signal filtered in the DC to 262 Hz frequency pass-band was recorded and streamed to a real-time processing program for exoskeleton feedback.

2.2. Experimental Setup

In this study, the knee exoskeleton (KneeBOTM, FREE Bionics Taiwan Inc., Hsinchu, Taiwan) was applied to a single knee joint in a human-in-the-loop environment as shown in Figure 1. The experimental environment combined the EMG signals, the angle of torque from the exoskeleton, and the angle for knee movement of the subject into a single computational platform.
The purpose of the exoskeleton was to support flexion and extension movements involving the knee joint. The subject was in the sitting position with the hip and knee flexed naturally as shown in Figure 2A. There are eight anatomically separate muscle–tendon units supporting the knee joint, including the rectus femoris (RF); the vastus muscle (VM) group, including the vastus lateralis, vastus medialis, and vastus intermedius; the semitendinosus; the semimembranosus; and the biceps femoris (BF), including both short and long heads.
While the semitendinosus was assumed to have the same activation as the semimembranosus [36], the semitendinosus muscle group (ST) included the semitendinosus and the semimembranosus. In this study, four pairs of surface EMG electrodes were positioned at skin locations above the muscles of RF, VM, BF, and ST as shown in Figure 2B,C, which were used to measure the EMG activity during flexion–extension movements of knee. The study was reviewed and approved by the Taipei Veterans General Hospital Institutional Review Board (IRB2020-10-001). All recoded EMG data are made available at the repository (https://doi.org/10.5281/zenodo.6516777), assessed on 29 April 2022.
During data acquisition, signals from the exoskeleton and the EMG electrodes were recorded simultaneously. First, the subject was asked to release the force. The knee in full extension (0 degrees) and flexion (100 degrees) was completely supported by the exoskeleton. Furthermore, the subject could move the knee freely without support from the exoskeleton.
After analyzing the parameters of the exoskeleton and EMG signals, we evaluated the performance (validation phase) while the subject was moving the knee with simultaneous exoskeleton support. The schematics of the experiment is shown in Figure 3, and the details of the methods are described in the sections below. A summary table to identify the corresponding physiological interpretations of the inertial parameters for the differentiable musculoskeletal model is presented in Table 1.

2.3. Preprocessing

To eliminate movement artifacts, the EMG data acquired from the four muscles were processed in the following three steps. First, the raw EMG data were filtered by a fourth-order Butterworth band-pass (20–450 Hz) filter. Second, full-wave rectification and an 8-Hz low-pass second-order Butterworth filter were applied to obtain the EMG signal envelope. Third, the filtered EMG signal was normalized with respect to the muscle’s maximum voluntary contraction level.
After the above three steps the smoothed normalized EMG signal e ( t ) , with an amplitude range in [0, 1], was used to determine the neural activation u ( t ) and muscle activation a ( t ) . Since muscle activation takes time to generate force, there is a time lag between the two. The delayed transformation of EMG signals e ( t ) to neural activation u ( t ) was formalized by a damped linear second-order differential equation expressed in discrete form as a recursive filter (Equation (1)) [36,37],
u ( t ) = α e ( t d ) β 1 u ( t 1 ) β 2 u ( t 2 ) ,
where α represents the muscle gain coefficient; β 1 and β 1 are the muscle recurrence coefficients; and d is the electromechanical delay. At the motor unit level, the increase in muscle force was associated with an exponential increase in the firing rate. Equation (2) formalizes this nonlinear relationship between neural activation u(t) and muscle activation a(t), where A represents the nonlinear shape factor with the 3 < A < 0 constraint.
a ( t ) = e x p A u ( t ) 1 e x p A 1
Since muscle torque cannot be measured invasively, the torque obtained from the motion equation was used as the substitute when adjusting the muscular parameters. This required the three inertia parameters of the motion equation (the rotation inertia, J ; the damping, B ; and the stiffness, K , of the knee joint at full extension of the lower-limb) to be identified in advance. The motion equation, illustrated in Figure 2A, is defined in Equation (5) below. The identification process was conducted without human-exerted muscle torque, i.e., τ h ( t i ) = 0 , while the subject’s lower-limb was moved by the exoskeleton.
First, K was determined in static conditions as the exoskeleton moved from angular position θ = 120 to 0 in 15 steps. In static conditions, the velocity θ ˙ and acceleration θ ¨ of the exoskeleton equals 0 by definition: θ ˙ ( t i ) = θ ( t i ) ¨ = 0 . With these values substituted into the motion equation (Equation (5)), the identification of K can be expressed as Equation (3):
a r g m i n K   1 2 i = 1 N y ( t i ) K ( θ ( t i ) θ r ) 2 ,
where y ( t i ) = τ e ( t i ) τ g ( t i ) sin ( θ ( t i ) θ r ) is the conversion of the gravitational torque, τ g ( t i ) = m g r c m , and the exoskeletal torque, τ e ( t i ) , from the electrical current sensor representation on the exoskeleton. Here, m , g , r c m ,   and   θ r are the mass, gravity, moment arm, and rest position, respectively, while N is the number of acquired samples, and t i is the time of the i -th acquired sample.
Next, J and B were determined in dynamic conditions, while the exoskeleton was moving from θ = 90 to 0 at a variable frequency between 0.01 and 0.5 Hz. The identification of these two parameters, similarly to that of K , is formalized in Equation (4),
a r g m i n J , B   1 2 i = 1 N y ( t i ) ( J θ ¨ ( t i ) + B θ ˙ ( t i ) ) 2 ,
where y ( t i ) = τ e ( t i ) τ g ( t i ) sin ( θ ( t i ) θ r ) K ( θ ( t i ) θ r ) . The optimization problems in Equations (3) and (4) were solved by the Levenberg–Marquardt algorithm. Since the motor encoder on the exoskeleton can only measure the angular position and velocity with noise, we used the parameterized Fourier series to calculate the smooth (“noise-free”) angular velocity and acceleration [38].

2.4. Wearable Exoskeleton Modeling

Since the motion of the knee exoskeleton is similar to the pendulum, the model dynamics can be derived using the same principles of mechanics. Using Lagrangian mechanics [39,40], the motion equation of the knee exoskeleton is derived as Equation (5),
τ ( t ) = J θ ¨ ( t ) + B θ ˙ ( t ) + E p θ = τ e ( t ) + τ h ( t ) ,
where the potential energy, E p = 1 2 K ( θ ( t ) θ r ) 2 τ g cos ( θ ( t ) θ r ) , corresponds to the resting position θ r = π 2 , and the inertial parameters J , B   and   K were as described in the preprocessing. The exoskeleton torque, τ e ( t ) , was converted from the motor current.
The total muscle torque τ h ( t ) is estimated by Equation (6), where the superscript j denotes the j -th muscle.
τ h ( t ) = j = 1 8 F m t ( j ) ( a ( j ) ( t ) , l ( j ) ( t ) ) ,
In the Hill-type muscle model, the F m t force generated by the muscle–tendon contraction was mainly determined by the circuit composed of a contractile element (CE) and two non-linear spring elements, one in parallel element (PE) and another in series element (SE) [19,41] as formalized in Equation (7):
F m t ( a ( t ) , l ( t ) ) = F s e ( t ) = F m ( t ) cos ( α ) = [ F c e ( t ) + F p e ( t ) ] cos ( α ) = [ f l ( l ( t ) ) f v ( v ( t ) ) a ( t ) + f p e ( l ( t ) ) ] F max cos ( α )
For simplicity, we only present the equation derived for one muscle that lets us omit the superscript j . In this model, α represents the pennation angle; l ( t ) represents the normalized muscle length, calculated as the current muscle length divided by the length while the muscle contraction is the maximum ( l ( t ) = L ( t ) L ); and v ( t ) represent the normalized velocity of muscle contraction ( v ( t ) = L ˙ ( t ) L ), i.e., the change of the muscle length.
In this study, a Hill-type muscle model can be simulated by the active (contractile) and passive (noncontractile) muscle components [42,43]. The relationship between contraction force and muscle length ( l ( t ) ) is formalized by the Gaussian function (Equation (8)) for active muscle contraction [44] and an exponential function (Equation (9)) for passive muscle contraction [45], where γ , k , and ε were shape parameters of the functions.
f l ( l ( t ) ) = e x p ( ( l ( t ) 1 ) 2 γ )  
f p e ( l ( t ) ) = e x p k ( l ( t ) 1 ) ε 1 e x p k 1 ,  
The force–strain relationship of a tendon is determined by an exponential function within an initial nonlinear toe region followed by a linear function outside (Equation (10)),
f s e ( l t ( t ) ) = { f t o e e x p k 1 ( e x p k t o e ε ε t o e 1 ) , ε ε t o e k l i n ( ε ε t o e ) + f t o e , ε > ε t o e
where l t ( t ) represents tendon strain; ε t o e is the threshold tendon strain above which the tendon exhibits linear behavior; k t o e is the exponential shape factor; k l i n is the linear shape factor, and ε is the strain normalized by l s l a c k , the slack length, and calculated as ε = l t ( t ) l s l a c k .
The formal relationship between the v ( t ) muscle contraction velocity and the F t ( t ) force arising from muscle–tendon contraction can be derived from by Equations (7)–(10) as stated in Equation (11):
f v ( v ( t ) ) = F s e ( t ) f p e ( l ( t ) ) a ( t ) f l ( l ( t ) )  
The v ( t ) muscle contraction velocity is determined from the inverse transform of Equation (11) and formalized, after some modification [41], in Equation (12):
v ( l ( t ) , f c e ( t ) , a ( t ) ) = ( 0.25 + 0.75 a ) V max f c e ( t ) a ( t ) f l ( l ( t ) ) b
where a and b are shape parameters.
The force of active muscle contraction is derived, in turn, from the inverse transform of from Equation (12), i.e., by Equation (13):
f c e ( t ) = v 1 ( f l ( l ( t ) ) , a ( t ) )
To this end, the force of muscle–tendon contraction required by Equation (7) is demonstrated as F m t ( a ( t ) , l ( t ) ) = [ f c e ( t ) + f p e ( l ( t ) ) ] F max cos ( α ) and is adopted for each muscle in Equation (6).
However, each user had different muscle properties; therefore, each muscle in the model needs to be calibrated for the parameters. The Hill’s muscle model requires three parameters to scale generic curves for active and passive force generation: the optimal fiber length L , maximum isometric force F max , and tendon slack length l s l a c k [46]. The adjoint method [47], which we describe next, is used to determine these parameters.

2.5. Differentiable Musculoskeletal Parameters Estimation

Muscle torque cannot be measured directly in an invasive manner. To estimate muscle torque, it was necessary to use statistical inference consistent with physiological and physical explanations. Under the condition that the knee joint of the subject is in the same position as the exoskeleton joint, rearranging Equation (5) yields the functional relationship between muscle torque and the angular acceleration of the joint generated by muscle torque as stated in Equation (14):
h ( τ h ( t ) ) = J 1 ( τ h ( t ) B θ ˙ ( t ) E p θ )
The angular position of the trajectory can be computed using this equation from the inputs of muscle torque τ h ( t ) 00 as part of the forward dynamics model. The muscle skeleton model is formalized as a system of differential equations (Equation (15)):
{ d l ( t ) d t = v ( l ( t ) , f c e ( t ) , a ( t ) ) d θ ˙ ( t ) d t = h ( τ h ( t ) ) d θ ( t ) d t = θ ˙ ( t )
In this system of differential equations, the first component, the velocity of muscle contraction, is calculated from Equation (12). The second component, angular acceleration, requires the muscle length, integrated from first component, to compute the muscle torque τ h ( t ) from Equation (6). The third component, angular velocity, is integrated from the second component. This set of differential equations can be solved using the Runge–Kutta–Fehlberg method for predicting the system state. During motion, the assistive torque, τ e ( t ) , is regulated by the motor’s proportional–integral–derivative (PID) controller (Equation (16)). In control theory, the PID controller is the mature method, and its formal analysis, such as via the Laplace transformation, can refer to Equation (16) [48].
τ e ( t ) = K p e ^ ( t ) + K i 0 t e ^ ( μ ) d μ + K d d e ^ ( t ) d t
In the PID controller, K p represents the proportional gain; K i is the integral gain; and K d is the derivative gain; these three are tuning parameters. The tracking error, e ^ ( t ) , also known as the control feedback, is the difference between the target position and the position predicted by integrating Equation (15), where the target position θ * ( t ) is manually specified in advance.
To estimate the unmeasurable muscle torque, τ h ( t ) , from the measurable angular velocity of trajectory, θ ˙ ( t ) , the model was set up by maximum-a-posteriori (MAP) estimation, and maximized posterior probability (Equation (17)):
τ h ^ = argmax τ h   p ( τ h θ ˙ ) = argmin τ h log   p ( θ ˙ τ h ) log   p ( τ h ) ,
where τ h and θ ˙ represent the τ h ( t ) and θ ˙ ( t ) time series, respectively.
In Equation (17), the prior probability log p ( τ h ) was set to 0 , signifying that we did not make any assumptions about muscle torque. The conditional probability log p ( θ ˙ τ h ) requires computing the forward dynamics model, which implies calculating the optimally angular velocity θ ˙ ( t ) from the unmeasurable muscle torque τ h ( t ) . To overcome this obstacle, the conditional probability was recast as the integrals ( ) (Equation (18)):
( z ˙ , θ ˙ ) = 0 t z ˙ ( μ , τ h ) θ ˙ ( μ ) 2 d μ ,  
and z ˙ ( ) (Equation (19)), which was used to explain the angular velocity of the muscle skeleton by integrating Equation (15):
z ˙ ( t , τ h ) = h ( τ h ( t 0 ) ) + 0 t h ( τ h ( μ ) ) d μ  
Here, τ h was modeled by Hill’s muscle (Equation (6)), and was adjusted based on each subject’s muscle parameters [46]. The muscle parameters for adjusting the muscle torque included optimal fiber length, maximum isometric force, and tendon slack length, respectively ( ω = {   L , F max , l s l a c k   } ). With Equations (18) and (19), the MAP estimation of Equation (17) becomes equivalent to solving the constrained optimization problem, formalized by Equation (20) below:
a r g m i n ω   1 N i = 1 N ( z ˙ i , θ ˙ i )   s , t .   d z ˙ ( t i ) d t = h ( τ h ( t i , ω ) ) ,   h ( τ h ( t 0 ) ) = θ ¨ ( t 0 ) z ˙ i = z ˙ ( t i , τ h ) ,   i = 1 , 2 , . N ,
where, assuming that N samples were acquired, z ˙ i represents the angular velocity of the i -th acquired sample, and t i , the time of the i -th acquired sample.
In order to solve Equation (20) using an iterative algorithm, such as a stochastic gradient descent or adaptive moment estimation (Adam) [49], it was necessary to derive the gradient of the muscle parameters ω . We used the Lagrangian Multiplier method to obtain the Lagrangian (Equation (21)) from Equation (20),
= ( z ˙ , θ ˙ ) + 0 t λ ( μ ) [ d z ˙ ( μ ) d t h ( τ h ( μ , ω ) ) ] d μ  
and then used the Karush–Kuhn–Tucker conditions to derive the gradient. The detailed derivation can be found in the adjoint method [47]. In brief, the analytical gradient can be calculated by the algorithm consisting of these four steps: (1) Solve z ˙ ( t , τ h ) from time 0 to t   (Equation (19)). (2) Determine λ ( t ) (Equation (22)). (3) Solve λ ( t ) from time t to 0 (Equation (23)). (4) Calculate the Lagrangian gradient in the muscle parameters (Equation (24)). For simplicity, only the equations resulting for N = 1 are presented, and the subscript i is omitted:
z ˙ ( t ) + λ ( t ) = 0
d λ ( t ) d t + ( h ( τ h ( t , ω ) ) z ˙ ( t ) ) λ ( t ) = 0
ω = t 0 λ ( μ ) h ( τ h ( μ , ω ) ) ω d μ
The performance of our proposed model was evaluated in two different sets of tests. In the first set of tests, conducted under muscle contraction, the torques and angles predicted in each muscle were compared with real data. In the second set of tests, the efficiency of our proposed method was evaluated by the rate of convergence and execution time and compared with those of other models on an equal basis.

3. Results

3.1. Parameters Estimated in the Motion Equation

In exoskeleton control, the joint torque generated by the muscle force was estimated to predict the movement trajectory. To obtain an estimate of the muscle-generated torque in a non-invasive manner, we identified the parameters of the motion equation (Equation (5)) in advance from the recorded angular position and velocity of the trajectory. The five identified parameters in the motion equation are summarized in Table 2. Three of the parameters (the inertia J , damping B , and stiffness K ) were calculated as described in the preprocessing. The remaining two, the mass m and the center of mass r c m of the exoskeleton, were measured manually.
Table 3 summarized the estimates for the three muscle parameters used in the Hill’s model (Equation (7)), including optimal fiber length L , tendon slack length l s l a c k , and maximum isometric force F max . The first column lists the anatomical grouping of the eight muscles from which the EMG signals were obtained via four electrodes. The values of the muscle parameters that we identified were similar to those obtained by physiological measurements in previous studies [46].
The process used for the optimization of the muscle parameters is illustrated for predicted position in Figure 4A. Initially, the predicted position obtained using the unadjusted muscle parameters (solid blue line) was a poor approximation of the reference trajectory generated by the subject (dashed line). As the number of iterations increased, the estimated muscle parameters were better adapted to the subject’s generated trajectory. A similar iterative improvement was observed in the predicted torque as shown in Figure 4B).

3.2. Prediction Results

In the model simulation, the time interval of the prediction ranged from 2 to 25 s, the EMG signals were served as inputs to the model, and the model outputs were the predicted trajectory and joint torque. The solid line in Figure 5A represents the predicted trajectory obtained by numerical integration of the third term of Equation (15). The dashed line represents the trajectory measured from the subject used as the reference trajectory. The goal of our optimization was to adjust the muscle parameters so that the predicted trajectory was an increasingly good approximation to the reference trajectory.
The predicated joint torque (Figure 5B) was calculated from Equation (6) by using the muscle activation and predicted muscle length. The predicted torque was becoming increasingly similar to the reference torque, mirroring what was seen for the predicted trajectory. Figure 5C,E show, for the four muscle groups defined in Table 3, the average muscle length predicted by numerical integration (first term in Equation (15)). Similarly, Figure 5D,F shows the muscle activation, a ( t ) , calculated from the EMG signals using Equation (2).

3.3. Performance Analysis: Convergence and Execution Time

We compared the performance of the analytical gradient method and three other gradient update methods. Two gradient-free methods, Nelder–Mead (NM) [50] and Adaptive Nelder–Mead (ANM) [51], were also included in the comparison because in earlier studies they were used to adjust the parameters of Hill’s muscle model [11,23,25]. To measure performance, 10 sets of perturbed muscle parameters were generated as the initial model parameters using uniformly distributed additive noise with a lower bound of 5   [ cm ] and an upper bound of 5   [ cm ] .
These noise terms were added to the value of the identified parameters listed in Table 3. In the experiment, each method shared the same 10 sets of the perturbed muscle parameters (24 muscle parameters in a set, thus, 240 in total), and the parameters were optimized for the same subject’s measured trajectory. Figure 6 shows the predicted trajectory and torque identified from the 10 sets of the perturbed muscle parameters.
The solid lines represent the average position and torque determined from the 10 sets of the identified muscle parameters, and the shadow area maps the maximum and minimum values for the angle and torque. The dotted lines represent the subject’s measured position and torque, used as the convergence target for optimizing the muscle parameters. As seen in Figure 6A, each method’s predicted trajectory (solid lines) was close to the reference position (dashed line).
The same is seen for the torque (Figure 6B). Thus, each method could optimize muscle parameters that fit the subject’s movement trajectory comparably. Furthermore, the shaded areas of each method were small, meaning that the 10 sets of the muscle parameters identified by each method generated trajectories and torques that converged to the reference trajectory and torque.
Although the movement trajectories and torques predicted by each method were convergent, the identified muscle parameters may be divergent. Since the movement trajectory was from the same subject, even different initial muscle parameters should converge to similar muscle parameters. We compare the convergence results of the analytical gradient method (Equation (23)) and the gradient-free methods for the optimal muscle length in VM (Figure 7A) and ST (Figure 7B). During the iterative process, the shaded area was gradually reduced by the analytical gradient. In contrast, the shaded area was only slightly reduced and could even be diverged by the two gradient-free method. A similar observation was made for the calculated tendon slack lengths for VM and ST as shown in Figure 7C,D, respectively.
Predicting the trajectory and torque using Hill’s muscle model was complex because it involved numerical integration. Prior studies usually adopted gradient-free methods to update muscle parameters, thereby, avoiding the complexity of the analysis and the computational effort associated with numerical integration [23,25,31]. To compare the execution time of the analytical gradient method with alternative methods, we selected two gradient-free methods, NM and ANM, and three gradient approximation methods, CG [52], Truncated Newton (TNC) [52,53], and Sequential Least-Squares Programming (SLSQP) [54].
In the CG, TNC, and SLSQP, the two-point finite-difference method (FDM) was used to approximate the gradient [55], the popular method for the numerical approximation of the gradient. The results of this comparison are summarized in Table 4. Not surprisingly, the two gradient-free methods (NM and ANM) took the shortest average execution time and lowest number of evaluations. While the three gradient approximation methods (SLSQP, TNC, and CG) performed much worse, our analytical gradient method was competitive with the gradient-free methods. Interestingly, although the CG evaluated the loss most frequently on average, its execution time was sublinear in iterations because the just-in-time (JIT) compilation’s cache function compressed it.

4. Discussion

In this study, we proposed a differentiable continuous system control that integrates the dynamics of musculoskeletal models and analyzed the interaction mechanisms between the subject and the exoskeleton to achieve assist-as-needed control. This approach has several advantages, including faster convergence, increased accuracy and stability of predicted outcomes. For convergence, both muscle contraction and rigid body dynamic equations were applied in our model to improve calculating gradients. Updating the direction based on the loss value around the parameter made convergence faster in our model than in gradient-free methods, such as the NM method [50].
We considered both the muscle contraction and the rigid body dynamic equation to calculate analytical gradients in our model, and the calculated values of the muscle parameters (Table 3) were close to those reported by others [22,46,56]. The optimization results (Figure 4) showed that the trajectory and torque obtained from the adjusted muscle parameters were close predictions of the measured positions and torques. In earlier models [11,36,37], the torque was calculated from the motion equation through inverse dynamics transformation, which takes longer to compute.
In comparison, the step of inverse dynamics transformation is eliminated in our model, and calculating the torque only requires the measured angle for parameter estimation. According to the results in Figure 6, the torque derived from the predicted trajectory through the inverse equation of motion afterwards was similar to the torque expected from the reference trajectory. This means that our training framework can implicitly and automatically estimate the torque during motion.
The iterative update of the muscle parameters was performed using the analytic gradient based on the muscle contraction and rigid body dynamic equations. Unlike the gradient-free methods, the analytical gradients method makes use of the dynamic equation and can generate the specified torque and angle leading to stable convergence of the muscle parameters as shown in Figure 7.
The analytical gradient obtained the convergent results by calculating the gradients from the muscle contraction and motion equation with the two dynamic equations putting constrains on the results. In contrast, NM and ANM were gradient-free methods, relying only on the magnitude of the changes in the loss value to determine the direction of parameter update. The benefit of using the muscle contraction and motion equation is that the outputs satisfy the laws of physics. Thus, the use of analytical gradients to estimate muscle parameters could provide a more fault-tolerant and robust initial parameter setting process in practice.
We compared the execution time for different parameter-updating methods (Table 4). The gradient approximation methods required multiple evaluations per iteration. This suggests that the simple two-point finite-difference-method (FDM), which was used to compute each parameter separately, becomes impractically time-consuming when applied to calculating loss functions in a high-dimensional parameter space. In contrast, the analytical gradient has an analytic solution, and for each iteration, it requires only two evaluations of the loss function: forward inference and backward propagation. The bottleneck in the computation time was in the evaluation of the loss function (Equation (17) in the Section 2.5), which involved time-consuming numerical integrals.
Therefore, to compare the speed of the different update methods, we selected to evaluate only the loss function (the same for all methods) on the same hardware platform (an Apple Macbook pro M1 CPU; eight cores). The programs were implemented with the JAX package [56] and accelerated with JIT compilation. The results of this experiment (Table 4) showed that the analytical gradients method was competitive with the gradient-free methods in execution time.
Our proposed model merged a differentiable continuous system with a dynamic musculoskeletal model to support an effective and accurate performance for an exoskeleton controlled by EMG signals. This approach could be used to shorten the training time for controlling exoskeleton across different subjects. However, there are limitations to our study. First, this was a pilot study that included a small number of subjects. Second, the EMG signals used to control the model were recorded from only five healthy subjects. More subjects, including healthy and unhealthy ones, will have to be included in a follow-up to our study.

5. Conclusions

To overcome the time lag between the user intention and exoskeleton motion, we applied a differentiable continuous systems approach to a dynamic musculoskeletal model using EMG signals. The trajectories, including the torque and angles during muscle contraction, predicted by the proposed model were similar to the real movement. Moreover, our model outperformed others regarding the convergence rate and execution time. Our study demonstrates an effective and accurate method to decode EMG signals that serves the exoskeleton application. Future extensions of our proposed framework can be for deep neural networks with backpropagation and providing forward inference with biomechanical explanations.

Author Contributions

Conceptualization, C.-H.K. and J.-W.C.; methodology, C.-H.K. and J.-W.C.; software, S.-W.L.; validation, Y.Y., Y.-H.L. and P.-C.C.; investigation, C.-H.K. and J.-W.C.; resources, C.-F.W., Y.-C.L. and C.-L.L.; writing—original draft preparation, C.-H.K. and J.-W.C.; writing—review and editing, C.-L.L., C.-F.W. and Y.-Y.C.; visualization, Y.Y., Y.-H.L. and P.-C.C.; supervision, C.-F.W., S.-H.L. and Y.-Y.C.; project administration, C.-F.W., S.-H.L. and Y.-Y.C. All authors have read and agreed to the published version of the manuscript.

Funding

This work was supported in part by the Ministry of Science and Technology of Taiwan (MOST 111-2622-8-A49-011-TE2, 111-2321-B-A49-005, 110-2622-E-A49A-501 and 109-2221-E-010-004-MY2).

Institutional Review Board Statement

This study was approved by the Institutional Review Boards (IRBs) of Taipei Veterans General Hospital. The informed consent process was undertaken by the study coordinator. All participants gave consent to participate in the study.

Informed Consent Statement

Informed consent was obtained from the subjects involved in the study. Written informed consent has been obtained from the subjects to publish this paper.

Data Availability Statement

All recoded EMG data in this study are made available at the online repository (https://doi.org/10.5281/zenodo.6516777), assessed on 29 April 2022.

Acknowledgments

The authors would like to thank Taipei Veterans General Hospital for providing facilities. We also are grateful for FREE Bionics Taiwan Inc. for their technical support regarding knee exoskeletons and helpful discussion.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Zoss, A.B.; Kazerooni, H.; Chu, A. Biomechanical design of the berkeley lower extremity exoskeleton (bleex). IEEE/ASME Trans. Mechatron. 2006, 11, 128–138. [Google Scholar] [CrossRef]
  2. Maciejasz, P.; Eschweiler, J.; Gerlach-Hahn, K.; Jansen-Troy, A.; Leonhardt, S. A survey on robotic devices for upper limb rehabilitation. J. NeuroEngineering Rehabil. 2014, 11, 3. [Google Scholar] [CrossRef] [Green Version]
  3. Pazzaglia, M.; Molinari, M. The embodiment of assistive devices—from wheelchair to exoskeleton. Phys. Life Rev. 2016, 16, 163–175. [Google Scholar] [CrossRef] [PubMed]
  4. Kuo, C.H.; Blakely, T.M.; Wander, J.D.; Sarma, D.; Wu, J.; Casimo, K.; Weaver, K.E.; Ojemann, J.G. Context-dependent relationship in high-resolution micro-ecog studies during finger movements. J. Neurosurg. 2019, 132, 1358–1366. [Google Scholar] [CrossRef] [PubMed]
  5. Kuo, C.H.; Casimo, K.; Wu, J.; Collins, K.; Rice, P.; Chen, B.W.; Yang, S.H.; Lo, Y.C.; Novotny, E.J.; Weaver, K.E.; et al. Electrocorticography to investigate age-related brain lateralization on pediatric motor inhibition. Front. Neurol. 2022, 13, 747053. [Google Scholar] [CrossRef]
  6. McRuer, D.T.; Magdaleno, R.E.; Moore, G.P. A neuromuscular actuation system model. IEEE Trans. Man-Mach. Syst. 1968, 9, 61–71. [Google Scholar] [CrossRef]
  7. Mulder, M.; Pool, D.M.; Abbink, D.A.; Boer, E.R.; Zaal, P.M.T.; Drop, F.M.; van der El, K.; van Paassen, M.M. Manual control cybernetics: State-of-the-art and current trends. IEEE Trans. Hum.-Mach. Syst. 2018, 48, 468–485. [Google Scholar] [CrossRef]
  8. Choi, H.; Seo, K.; Hyung, S.; Shim, Y.; Lim, S.C. Compact hip-force sensor for a gait-assistance exoskeleton system. Sensors 2018, 18, 566. [Google Scholar] [CrossRef] [Green Version]
  9. Lyu, M.; Chen, W.-H.; Ding, X.; Wang, J.; Pei, Z.; Zhang, B. Development of an emg-controlled knee exoskeleton to assist home rehabilitation in a game context. Front. Neurorobotics 2019, 13, 67. [Google Scholar] [CrossRef] [Green Version]
  10. Pfurtscheller, G.; Guger, C.; Müller, G.; Krausz, G.; Neuper, C. Brain oscillations control hand orthosis in a tetraplegic. Neurosci. Lett. 2000, 292, 211–214. [Google Scholar] [CrossRef]
  11. Fleischer, C.; Hommel, G. A human—exoskeleton interface utilizing electromyography. IEEE Trans. Robot. 2008, 24, 872–882. [Google Scholar] [CrossRef]
  12. Elnady, A.M.; Zhang, X.; Xiao, Z.G.; Yong, X.; Randhawa, B.K.; Boyd, L.; Menon, C. A single-session preliminary evaluation of an affordable bci-controlled arm exoskeleton and motor-proprioception platform. Front. Hum. Neurosci. 2015, 9, 168. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  13. Li, Z.; Yuan, Y.; Luo, L.; Su, W.; Zhao, K.; Xu, C.; Huang, J.; Pi, M. Hybrid brain/muscle signals powered wearable walking exoskeleton enhancing motor ability in climbing stairs activity. IEEE Trans. Med. Robot. Bionics 2019, 1, 218–227. [Google Scholar] [CrossRef]
  14. Tiboni, M.; Borboni, A.; Vérité, F.; Bregoli, C.; Amici, C. Sensors and actuation technologies in exoskeletons: A review. Sensors 2022, 22, 884. [Google Scholar] [CrossRef] [PubMed]
  15. Chen, J.; Zhang, X.; Cheng, Y.; Xi, N. Surface emg based continuous estimation of human lower limb joint angles by using deep belief networks. Biomed. Signal Processing Control. 2018, 40, 335–342. [Google Scholar] [CrossRef]
  16. Hahn, M.E. Feasibility of estimating isokinetic knee torque using a neural network model. J. Biomech. 2007, 40, 1107–1114. [Google Scholar] [CrossRef]
  17. Jali, M.H.; Izzuddin, T.A.; Bohari, Z.H.; Sulaima, M.F.; Sarkawi, H. Predicting emg based elbow joint torque model using multiple input ann neurons for arm rehabilitation. In Proceedings of the 2014 UKSim-AMSS 16th International Conference on Computer Modelling and Simulation, Cambridge, UK, 26–28 March 2014; pp. 189–194. [Google Scholar]
  18. Liu, Y.; Shih, S.M.; Tian, S.L.; Zhong, Y.J.; Li, L. Lower extremity joint torque predicted by using artificial neural network during vertical jump. J. Biomech. 2009, 42, 906–911. [Google Scholar] [CrossRef]
  19. Zajac, F.E. Muscle and tendon: Properties, models, scaling, and application to biomechanics and motor control. Crit. Rev. Biomed. Eng. 1989, 17, 359–411. [Google Scholar]
  20. Haeufle, D.F.B.; Günther, M.; Bayer, A.; Schmitt, S. Hill-type muscle model with serial damping and eccentric force–velocity relation. J. Biomech. 2014, 47, 1531–1536. [Google Scholar] [CrossRef]
  21. Hill, A.V. The heat of shortening and the dynamic constants of muscle. Proc. R. Soc. London. Ser. B-Biol. Sci. 1938, 126, 136–195. [Google Scholar]
  22. Rajagopal, A.; Dembia, C.L.; DeMers, M.S.; Delp, D.D.; Hicks, J.L.; Delp, S.L. Full-body musculoskeletal model for muscle-driven simulation of human gait. IEEE Trans. Biomed. Eng. 2016, 63, 2068–2079. [Google Scholar] [CrossRef] [PubMed]
  23. Ao, D.; Song, R.; Gao, J. Movement performance of human-robot cooperation control based on emg-driven hill-type and proportional models for an ankle power-assist exoskeleton robot. IEEE Trans. Neural. Syst. Rehabil. Eng. 2017, 25, 1125–1134. [Google Scholar] [CrossRef] [PubMed]
  24. Zhang, L.; Li, Z.; Hu, Y.; Smith, C.; Farewik, E.M.G.; Wang, R. Ankle joint torque estimation using an emg-driven neuromusculoskeletal model and an artificial neural network model. IEEE Trans. Autom. Sci. Eng. 2021, 18, 564–573. [Google Scholar] [CrossRef]
  25. Yao, S.; Zhuang, Y.; Li, Z.; Song, R. Adaptive admittance control for an ankle exoskeleton using an emg-driven musculoskeletal model. Front. Neurorobot. 2018, 12, 16. [Google Scholar] [CrossRef] [PubMed]
  26. Rockenfeller, R.; Herold, J.L.; Götz, T. Parameter estimation and experimental design for hill-type muscles: Impulses from optimization-based modeling. Math. Biosci. 2020, 327, 108432. [Google Scholar] [CrossRef]
  27. Zee, M.d.; Heinen, F.; Sørensen, S.N.; King, M.A.; Lewis, M.G.C.; Rasmussen, J. Parameter Estimations of the Hill Model in Subject-Specific Musculoskeletal Models: How Many Measurements Do We Need? In Proceedings of the XVI International Symposium on Computer Simulation in Biomechanics, Gold Coast, QLD, Australia, 20–22 July 2017. [Google Scholar]
  28. Ohlsson, M.L.; Gulliksson, M.E. Least Squares Approach to Inverse Problems in Musculoskeletal Biomechanics; Technical Report; Mid Sweden University: Ostersund, Sweden, 2009; ISSN 1650-5387. [Google Scholar]
  29. Wu, Q.; Wang, X.; Chen, B.; Wu, H. Development of a minimal-intervention-based admittance control strategy for upper extremity rehabilitation exoskeleton. IEEE Trans. Syst. Man Cybern.Syst. 2018, 48, 1005–1016. [Google Scholar] [CrossRef]
  30. Cavallaro, E.E.; Rosen, J.; Perry, J.C.; Burns, S. Real-time myoprocessors for a neural controlled powered exoskeleton arm. IEEE Trans. Biomed. Eng. 2006, 53, 2387–2396. [Google Scholar] [CrossRef]
  31. Buongiorno, D.; Barsotti, M.; Barone, F.; Bevilacqua, V.; Frisoli, A. A linear approach to optimize an emg-driven neuromusculoskeletal model for movement intention detection in myo-control: A case study on shoulder and elbow joints. Front. Neurorobot 2018, 12, 74. [Google Scholar] [CrossRef]
  32. Degrave, J.; Hermans, M.; Dambre, J.; Wyffels, F. A differentiable physics engine for deep learning in robotics. Front. Neurorobot. 2019, 13, 6. [Google Scholar] [CrossRef] [Green Version]
  33. Erez, T.; Tassa, Y.; Todorov, E. Simulation tools for model-based robotics: Comparison of bullet, havok, mujoco, ode and physx. In Proceedings of the 2015 IEEE International Conference on Robotics and Automation (ICRA), Seattle, WA, USA, 26–30 May 2015; pp. 4397–4404. [Google Scholar]
  34. Qiao, Y.-L.; Liang, J.; Koltun, V.; Lin, M.C. Efficient differentiable simulation of articulated bodies. In Proceedings of the 38th International Conference on Machine Learning, Virtual Event, 18–24 July 2021. [Google Scholar]
  35. Chuang, C.H.; Lu, S.W.; Chao, Y.P.; Peng, P.H.; Hsu, H.C.; Hung, C.C.; Chang, C.L.; Jung, T.P. Near-zero phase-lag hyperscanning in a novel wireless eeg system. J. Neural. Eng. 2021, 18, 066010. [Google Scholar] [CrossRef]
  36. Lloyd, D.G.; Besier, T.F. An emg-driven musculoskeletal model to estimate muscle forces and knee joint moments in vivo. J. Biomech. 2003, 36, 765–776. [Google Scholar] [CrossRef]
  37. Buchanan, T.S.; Lloyd, D.G.; Manal, K.; Besier, T.F. Neuromusculoskeletal modeling: Estimation of muscle forces and joint moments and movements from measurements of neural command. J. Appl. Biomech. 2004, 20, 367–395. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  38. Swevers, J.; Ganseman, C.; Tukel, D.B.; Schutter, J.d.; Brussel, H.V. Optimal robot excitation and identification. IEEE Trans. Robot. Autom. 1997, 13, 730–740. [Google Scholar] [CrossRef] [Green Version]
  39. Rifai, H.; Hassani, W.; Mohammed, S.; Amirat, Y. Bounded control of an actuated lower limb orthosis. In Proceedings of the 2011 50th IEEE Conference on Decision and Control and European Control Conference, Orlando, FL, USA, 12–15 December 2011. [Google Scholar]
  40. Hassani, W.; Mohammed, S.; Rifaï, H.; Amirat, Y. Powered orthosis for lower limb movements assistance and rehabilitation. Control. Eng. Pract. 2014, 26, 245–253. [Google Scholar] [CrossRef]
  41. Thelen, D.G. Adjustment of muscle mechanics model parameters to simulate dynamic contractions in older adults. J. Biomech. Eng. 2003, 125, 70–77. [Google Scholar] [CrossRef] [Green Version]
  42. Audu, M.L.; Davy, D.T. The influence of muscle model complexity in musculoskeletal motion modeling. J. Biomech. Eng. 1985, 107, 147–157. [Google Scholar] [CrossRef]
  43. Magnusson, S.P.; Simonsen, E.B.; Aagaard, P.; Kjaer, M. Biomechanical responses to repeated stretches in human hamstring muscle in vivo. Am. J. Sports Med. 1996, 24, 622–628. [Google Scholar] [CrossRef]
  44. Gordon, A.M.; Huxley, A.F.; Julian, F.J. The variation in isometric tension with sarcomere length in vertebrate muscle fibres. J. Physiol. 1966, 184, 170–192. [Google Scholar] [CrossRef]
  45. Epstein, M.; Herzog, W. Theoretical Models of Skeletal Muscle: Biological and Mathematical Considerations; Wiley: Chichester, NY, USA, 1998. [Google Scholar]
  46. Arnold, E.M.; Ward, S.R.; Lieber, R.L.; Delp, S.L. A model of the lower limb for analysis of human movement. Ann. Biomed. Eng. 2010, 38, 269–279. [Google Scholar] [CrossRef] [Green Version]
  47. Zhuang, J.; Dvornek, N.; Li, X.; Tatikonda, S.; Papademetris, X.; Duncan, J. Adaptive checkpoint adjoint method for gradient estimation in neural ode. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, Virtual Event, 13–18 July 2020. [Google Scholar]
  48. Marlin, T.E. Process Control: Designing Processes and Control Systems for Dynamic Performance, 2nd ed.; McGraw-Hill Science/Engineering/Math: New York, NY, USA, 2000; pp. 267–301. ISBN 978-0-07-040492-2. [Google Scholar]
  49. Kingma, D.P.; Adam, B.J. A method for stochastic optimization. arXiv 2014, arXiv:1412.6980. [Google Scholar]
  50. Nelder, J.A.; Mead, R. A simplex method for function minimization. Comput. J. 1965, 7, 308–313. [Google Scholar] [CrossRef]
  51. Gao, F.; Han, L. Implementing the nelder-mead simplex algorithm with adaptive parameters. Comput. Optim. Appl. 2012, 51, 259–277. [Google Scholar] [CrossRef]
  52. Conjugate Gradient Methods. In Numerical Optimization; Nocedal, J.; Wright, S.J. (Eds.) Springer New York: New York, NY, USA, 2006; pp. 101–134. [Google Scholar]
  53. Nash, S.G. Newton-type minimization via the lanczos method. SIAM J. Numer. Anal. 1984, 21, 770–788. [Google Scholar] [CrossRef]
  54. Kraft, D. A Software Package for Sequential Quadratic Programming; Technical Report DFVLR-FB 88-28; Institut für Dynamik der Flugsysteme: Oberpfaffenhofen, Germany, 1988. [Google Scholar]
  55. Moin, P. Fundamentals of Engineering Numerical Analysis, 2nd ed.; Cambridge University Press: Cambridge, UK, 2010; ISBN 978-0-51-178143-8. [Google Scholar]
  56. Ward, S.R.; Eng, C.M.; Smallwood, L.H.; Lieber, R.L. Are current measurements of lower extremity muscle architecture accurate? Clin. Orthop. Relat. Res. 2009, 467, 1074–1082. [Google Scholar] [CrossRef] [Green Version]
Figure 1. Illustration of the human-in-the-loop environment for the wearable knee exoskeleton. The position, θ ( t ) , of the observed subject was measured to adjust the subject’s lower-limb force. A control algorithm adjusted the control input based on the EMG signals, e ( t ) , position, θ ( t ) , and motor torque, τ e ( t ) . The signals generated in this environment were transmitted by using the Bluetooth protocol.
Figure 1. Illustration of the human-in-the-loop environment for the wearable knee exoskeleton. The position, θ ( t ) , of the observed subject was measured to adjust the subject’s lower-limb force. A control algorithm adjusted the control input based on the EMG signals, e ( t ) , position, θ ( t ) , and motor torque, τ e ( t ) . The signals generated in this environment were transmitted by using the Bluetooth protocol.
Biosensors 12 00312 g001
Figure 2. The knee exoskeleton and the electrode positions targeting specific muscles. (A) The participant performs the rotatory movement at the knee with a flexion–extension angle of 45 degrees while wearing the knee exoskeleton. (B) Positions of the surface electrodes for RF and VM (left thigh, anterior view). (C) Positions of the surface electrodes for BF and ST (left thigh, posterior view).
Figure 2. The knee exoskeleton and the electrode positions targeting specific muscles. (A) The participant performs the rotatory movement at the knee with a flexion–extension angle of 45 degrees while wearing the knee exoskeleton. (B) Positions of the surface electrodes for RF and VM (left thigh, anterior view). (C) Positions of the surface electrodes for BF and ST (left thigh, posterior view).
Biosensors 12 00312 g002
Figure 3. Schematics of differentiable musculoskeletal parameter estimation and control in the closed-loop system. Above the gray dashed line indicates the stage of the parameter estimation, which was performed offline by using the recorded EMG signals and trajectory positions. The muscle parameters were updated by using the gradient derived from the analysis, depicted by the black solid line and the red dashed line. Below the gray dashed line indicate the control stage, represented by a solid black line, use the identified musculoskeletal parameters to predict the trajectory positions and adjust the assisted torques.
Figure 3. Schematics of differentiable musculoskeletal parameter estimation and control in the closed-loop system. Above the gray dashed line indicates the stage of the parameter estimation, which was performed offline by using the recorded EMG signals and trajectory positions. The muscle parameters were updated by using the gradient derived from the analysis, depicted by the black solid line and the red dashed line. Below the gray dashed line indicate the control stage, represented by a solid black line, use the identified musculoskeletal parameters to predict the trajectory positions and adjust the assisted torques.
Biosensors 12 00312 g003
Figure 4. The process of optimizing muscle parameters by the iterative improvement of the predicted trajectory and torque. (A) Predicted position plotted against the iteration number. (B) Predicted torque plotted against the iteration number.
Figure 4. The process of optimizing muscle parameters by the iterative improvement of the predicted trajectory and torque. (A) Predicted position plotted against the iteration number. (B) Predicted torque plotted against the iteration number.
Biosensors 12 00312 g004
Figure 5. (A) The predicted trajectory (solid line) and measured trajectory (dashed line). (B) Total torque of RF, VM, ST, and BF. The predicted torque (solid line) and the reference torque (dashed line) were calculated from (A) using the Equation (6). (C) Predicted muscle length of RF (blue) and VM (orange). (D) Muscle activation of RF (blue) and VM (orange) converted from EMG signals. (E) Predicted muscle length of ST (blue) and BF (orange). (F) Muscle activation of ST (blue) and BF (orange) computed from EMG signals (Equation (2)).
Figure 5. (A) The predicted trajectory (solid line) and measured trajectory (dashed line). (B) Total torque of RF, VM, ST, and BF. The predicted torque (solid line) and the reference torque (dashed line) were calculated from (A) using the Equation (6). (C) Predicted muscle length of RF (blue) and VM (orange). (D) Muscle activation of RF (blue) and VM (orange) converted from EMG signals. (E) Predicted muscle length of ST (blue) and BF (orange). (F) Muscle activation of ST (blue) and BF (orange) computed from EMG signals (Equation (2)).
Biosensors 12 00312 g005
Figure 6. Convergence analysis of predicted trajectory and torque. (A) Predicted position. (B) Predicted joint torque.
Figure 6. Convergence analysis of predicted trajectory and torque. (A) Predicted position. (B) Predicted joint torque.
Biosensors 12 00312 g006
Figure 7. Convergence analysis of the identified muscle parameters. (A) Optimal muscle fiber length in VM. (B) Optimal muscle fiber length in ST. (C) Tendon slack length of VM. (D) Tendon slack length of ST.
Figure 7. Convergence analysis of the identified muscle parameters. (A) Optimal muscle fiber length in VM. (B) Optimal muscle fiber length in ST. (C) Tendon slack length of VM. (D) Tendon slack length of ST.
Biosensors 12 00312 g007
Table 1. List of the time-dependent parameters of the adopted muscle contraction and rigid-body dynamics.
Table 1. List of the time-dependent parameters of the adopted muscle contraction and rigid-body dynamics.
SymbolDescriptionEquation Number
e ( t d ) Filtered EMG signal d time steps earlier(1)
u ( t 1 ) Neural activation one time step earlier(1)
a ( j ) ( t ) Muscle activation of j-th muscle at time t(6)
l ( j ) ( t ) Muscle length of j-th muscle at time t(6)
F m t ( j ) ( a ( j ) ( t ) , l ( j ) ( t ) ) Muscle–tendon force of j-th muscle at time t(6)
τ g ( t i ) Gravitational torque at the i-th sample of time t(3), (4)
τ e ( t i ) Exoskeleton torque at the i-th sample of time t(3), (4)
τ h ( t i ) Human (or muscle) torque at the i-th sample of time t(3), (4), (20)
θ ( t i ) ,   θ ˙ ( t i ) ,   θ ¨ ( t i ) Angular position, velocity, and acceleration, respectively, at the i-th sample of time t(3), (4), (20)
h ( τ h ( t i ) ) Predicted angular acceleration at the i-th sample of time t(20)
z ˙ ( t i , τ h ) Predicted angular velocity at the i-th sample of time t(20)
Table 2. The five identified parameters of the wearable exoskeleton in the motion equation.
Table 2. The five identified parameters of the wearable exoskeleton in the motion equation.
J   ( k g . m 2 ) B   ( N m s r a d ) K   ( N m r a d ) m   ( k g ) r c m   ( m )
0.07 1.51.275.50.16
Table 3. The identified muscle parameters in Hill’s model.
Table 3. The identified muscle parameters in Hill’s model.
GroupsMusclesComparison L   ( c m ) l s l a c k   ( c m ) F max   ( N )
RFRectous femoris_9.832.8850
Prev7.634.6848
VMVastus lateralis_ 9.6 12.9 2260
Prev 9.9 13.0 2255
Vastus medialis_ 10.6 12.4 1445
Prev 9.7 11.2 1443
Vastus intermedius_ 11.5 11.3 1025
Prev 9.9 10.6 1024
STSemimembranosus_ 13.4 42.3 1092
Prev 8.0 34.8 1162
Semitendinosus_ 22.3 22.7 315
Prev 20.1 24.5 301
BFBiceps long head_ 8.4 31.9701
Prev 9.8 32.2 705
Biceps short head_ 9.5 9.1 327
Prev 11.0 10.4315
In the Comparison column, a dash (_) indicates the row of parameters identified in our study and the abbreviation Prev indicates the parameters measured in a previous study [46].
Table 4. Comparison of the computational efficiency and speed of gradient-free, gradient approximation, and gradient analytic methods.
Table 4. Comparison of the computational efficiency and speed of gradient-free, gradient approximation, and gradient analytic methods.
NMANMSLSQPTNCCG(Ours)
Gradientfreefreeapprox.approx.approx.analytic
#Eval/iter1.31.429.41255332
Sec/iter0.080.090.562.514.720.15
The number of evaluations (#Eval/iter) and execution time in seconds (Sec/iter) of the loss function in each iteration. Each value in the table was calculated by averaging 100 iterations.
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Kuo, C.-H.; Chen, J.-W.; Yang, Y.; Lan, Y.-H.; Lu, S.-W.; Wang, C.-F.; Lo, Y.-C.; Lin, C.-L.; Lin, S.-H.; Chen, P.-C.; et al. A Differentiable Dynamic Model for Musculoskeletal Simulation and Exoskeleton Control. Biosensors 2022, 12, 312. https://doi.org/10.3390/bios12050312

AMA Style

Kuo C-H, Chen J-W, Yang Y, Lan Y-H, Lu S-W, Wang C-F, Lo Y-C, Lin C-L, Lin S-H, Chen P-C, et al. A Differentiable Dynamic Model for Musculoskeletal Simulation and Exoskeleton Control. Biosensors. 2022; 12(5):312. https://doi.org/10.3390/bios12050312

Chicago/Turabian Style

Kuo, Chao-Hung, Jia-Wei Chen, Yi Yang, Yu-Hao Lan, Shao-Wei Lu, Ching-Fu Wang, Yu-Chun Lo, Chien-Lin Lin, Sheng-Huang Lin, Po-Chuan Chen, and et al. 2022. "A Differentiable Dynamic Model for Musculoskeletal Simulation and Exoskeleton Control" Biosensors 12, no. 5: 312. https://doi.org/10.3390/bios12050312

APA Style

Kuo, C. -H., Chen, J. -W., Yang, Y., Lan, Y. -H., Lu, S. -W., Wang, C. -F., Lo, Y. -C., Lin, C. -L., Lin, S. -H., Chen, P. -C., & Chen, Y. -Y. (2022). A Differentiable Dynamic Model for Musculoskeletal Simulation and Exoskeleton Control. Biosensors, 12(5), 312. https://doi.org/10.3390/bios12050312

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop