Daedalus.scl.Sztaki.hu Diploma Csercsik David

Embed Size (px)

Citation preview

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    1/82

    Analysis and Control of a Simple NonlinearLimb Model

    by

    Dávid Csercsik

    Submitted to the department of Control Engineering andInformation Technology in partial fulfillment of the requirements

    for the degree of 

    Master of Science in Electrical Engineering

    at the

    Budapest University of Technology and Economics

    Supervisor: Department Consultant:

    Prof. Katalin Hangos Dr. István Harmati

    Systems and Control Laboratory Department of Control EngineeringComputer and Automation and Information Technology

    Research Institute Budapest Faculty of Control Engineeringand Informatics

    Budapest University of Technologyand Economics

    BME2005

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    2/82

    Contents

    1 Introduction 51.1 Literature review on human locomotion analysis and control . 51.2 Notation list . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61.3 Structure of the diploma work . . . . . . . . . . . . . . . . . . 7

    2 Construction of a simple limb model in state-space 82.1 Limb and muscle modelling . . . . . . . . . . . . . . . . . . . 82.2 System description . . . . . . . . . . . . . . . . . . . . . . . . 8

    2.2.1 Modelling assumptions . . . . . . . . . . . . . . . . . . 92.3 Muscle properties . . . . . . . . . . . . . . . . . . . . . . . . . 10

    2.3.1 Force-length characteristics (F L(lCE )) . . . . . . . . . 102.3.2 Force-contraction velocity characteristics (F v(vCE )) . . 112.3.3 Passive force (F PE ) . . . . . . . . . . . . . . . . . . . . 122.3.4 Muscle activation (q ) . . . . . . . . . . . . . . . . . . 132.3.5 Muscle force (F CE ) . . . . . . . . . . . . . . . . . . . . 13

    2.4 Tendon properties . . . . . . . . . . . . . . . . . . . . . . . . . 142.4.1 The tendon’s dynamical equations . . . . . . . . . . . . 14

    2.5 Dynamic equations at the limb level . . . . . . . . . . . . . . . 142.5.1 Forces . . . . . . . . . . . . . . . . . . . . . . . . . . . 142.5.2 Joint torques . . . . . . . . . . . . . . . . . . . . . . . 15

    2.5.3 Movement . . . . . . . . . . . . . . . . . . . . . . . . . 152.6 State-space model equations and its variables . . . . . . . . . 17

    2.6.1 Variables in the state-space model . . . . . . . . . . . . 172.6.2 State-space equations . . . . . . . . . . . . . . . . . . . 172.6.3 The domain of the model and the model parameters . . 19

    2.7 Model verification . . . . . . . . . . . . . . . . . . . . . . . . . 212.8 A biological extension: A simple Gamma-loop model . . . . . 24

    2.8.1 The simplified model of the Gamma-loop . . . . . . . . 242.8.2 Simulation results . . . . . . . . . . . . . . . . . . . . . 26

    3 Model analysis 283.1 Linear analysis . . . . . . . . . . . . . . . . . . . . . . . . . . 303.1.1 Linearization around a steady-state point . . . . . . . . 303.1.2 Analysis of the linearized model at the first steady-

    state point . . . . . . . . . . . . . . . . . . . . . . . . . 313.1.3 Analysis of the linearized model at the second steady-

    state point . . . . . . . . . . . . . . . . . . . . . . . . . 333.2 Relative degree . . . . . . . . . . . . . . . . . . . . . . . . . . 34

    3.2.1 The structure graph . . . . . . . . . . . . . . . . . . . 35

    1

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    3/82

    3.3 Controllability . . . . . . . . . . . . . . . . . . . . . . . . . . . 36

    3.3.1 Algorithm for constructing the controllability distribu-tion . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36

    3.3.2 Structural controllability and observability . . . . . . . 373.3.3 Structural controllability analysis of the model . . . . . 37

    3.4 Observability . . . . . . . . . . . . . . . . . . . . . . . . . . . 373.4.1 Algorithm for constructing the observability

    co-distribution . . . . . . . . . . . . . . . . . . . . . . . 373.4.2 Structural observability analysis of the model . . . . . 38

    3.5 Stability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 393.5.1 Lyapunov-stability . . . . . . . . . . . . . . . . . . . . 39

    3.5.2 Strong asymptotic -stability . . . . . . . . . . . . . . . 393.5.3 Lyapunov’s first theorem . . . . . . . . . . . . . . . . . 393.5.4 Estimating the stability region in the neighborhood

    of the steady-state point with quadratic Lyapunov-function candidate . . . . . . . . . . . . . . . . . . . . 40

    3.6 Zero dynamics . . . . . . . . . . . . . . . . . . . . . . . . . . . 423.6.1 Zero dynamics state-space equations . . . . . . . . . . 443.6.2 Computing the zeroing input . . . . . . . . . . . . . . 453.6.3 Zero-dynamics analysis results . . . . . . . . . . . . . . 45

    4 Controller design 464.1 Performance specification . . . . . . . . . . . . . . . . . . . . . 46

    4.1.1 Control aims . . . . . . . . . . . . . . . . . . . . . . . 464.1.2 Control domain . . . . . . . . . . . . . . . . . . . . . . 464.1.3 Disturbances . . . . . . . . . . . . . . . . . . . . . . . 46

    4.2 Linear SISO LQ regulator . . . . . . . . . . . . . . . . . . . . 484.2.1 Simulation results of the SISO LQ conroller . . . . . . 50

    4.3 Linear MISO LQ regulator . . . . . . . . . . . . . . . . . . . . 524.3.1 Simulation results of the MISO LQ controller without

    disturbance . . . . . . . . . . . . . . . . . . . . . . . . 524.3.2 Trajectory following results of the MISO LQ controller

    with disturbance . . . . . . . . . . . . . . . . . . . . . 544.3.3 Regulation results of the MISO LQ controller with dis-

    turbance . . . . . . . . . . . . . . . . . . . . . . . . . . 554.4 Input-Output linearization . . . . . . . . . . . . . . . . . . . . 56

    4.4.1 Simulation results of the IOL-PP controller withoutdisturbance . . . . . . . . . . . . . . . . . . . . . . . . 58

    4.4.2 Trajectory following results of the IOL-PP controllerwith disturbance . . . . . . . . . . . . . . . . . . . . . 59

    2

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    4/82

    4.4.3 Regulation results of the IOL-PP controller with dis-

    turbance . . . . . . . . . . . . . . . . . . . . . . . . . . 604.5 Fuzzy Inference System . . . . . . . . . . . . . . . . . . . . . . 61

    4.5.1 Basic concepts in fuzzy theory . . . . . . . . . . . . . . 614.5.2 The applied fuzzy controller . . . . . . . . . . . . . . . 664.5.3 Simulation results of the fuzzy controller without dis-

    turbance . . . . . . . . . . . . . . . . . . . . . . . . . . 694.5.4 Trajectory following results of the Fuzzy controller with

    disturbance . . . . . . . . . . . . . . . . . . . . . . . . 704.5.5 Regulation results of the Fuzzy controller with distur-

    bance . . . . . . . . . . . . . . . . . . . . . . . . . . . 71

    4.6 Comparison of the different control methods . . . . . . . . . . 724.6.1 Comparison of the results without disturbance . . . . . 724.6.2 Comparison of the results with disturbance . . . . . . . 734.6.3 Comparison results: a discussion . . . . . . . . . . . . 74

    5 Conclusions and future work 75

    6 Acknowledgements 76

    7 Appendix 777.1 The gamma-loop . . . . . . . . . . . . . . . . . . . . . . . . . 77

    7.1.1 Muscle spindles . . . . . . . . . . . . . . . . . . . . . . 777.1.2 The servomechanical Gamma-loop . . . . . . . . . . . . 78

    3

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    5/82

    Abstract

    Motivation and Aim:Even the simplest limb model exhibits strongly nonlinear dynamic behavior that

    calls for applying the results of nonlinear systems and control theory. The analysisand control of limb models are important in the fields of designing and control-ling artificial limbs, muscle prosthesis and in neuro-physiological investigations.The aim of this study is to investigate the possibility to applying input-outputlinearization [11] for nonlinear control of a simple limb model.

    Material and Methods:A nonlinear input-affine state-space model has been developed for a simple one-

     joint system with a flexor and an extensor muscle (see figure 1) which is suitable fornonlinear systems analysis and control. The model takes the nonlinear propertiesof the force-length relation and the force-contraction velocity relation into account.

    Exerted forces depend linearly on the activation state of muscles, and a vis-coelestic tendon is considered following the principles in [28], [24] and [22]. Thismodel has been extended with a simple model of the gamma-loop mechanism, butonly the non-extended model is used for the control studies. The inputs of themodel are the normalized activation signal of muscles, the output is the joint angle,and the number of state variables is 8.

    As preliminary model analysis we performed stability, controllability and ob-servability analysis of the linearized model around steady-state points. Moreover,the relative degree of the model and the stability of its zero-dynamics [3] werealso determined. Both regulating and servo controllers were designed for the sim-ple limb model and were compared to the standard reference case being an LQ-controller designed for the locally linearized system. A pole-placement control wasdesigned for the input-output linearized system, and also a fuzzy controller wasdesigned.

    Result:The model was verified against engineering intuition and proved to be suitable

    for controller design purposes. The model analysis showed that the nonlinear limb

    model was controllable and was in the edge of stability because of the Hamlitonianproperties of the model. The relative degree of the model is 3 for both of the inputswith a stable zero dynamics. Therefore input-output linearization was applicableand a 3rd order linear system was obtained in the new coordinates. A simple pole-placement controller was designed for this input-output linearized model. Boththe pole-placement, the fuzzy, and the reference LQ-controller were suitable forcontrol purposes but the fuzzy and the LQ-controller were more sensitive to thedisturbances.

    4

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    6/82

    1 Introduction

    ”Human locomotion is a complex movement of a body. For a successful move-ment, interactions among muscular-skeletal system and central nervous sys-tem (CNS) are needed. The CNS controls the movement by sending activation signals to the correct skeletal muscle at correct moment. The effect of this signal is that the muscle initiates a movement by exerting force to a body segment. Even in the case of a simple movement the contribution of a large number of muscles of different size and shape is necessary. A common move-ment such as locomotion require more muscles. With a feedback system that uses different kind of receptors, the CNS controls the movement. In healthy 

    humans all these complex coordinated actions lead unconsciously to a smooth movement.” [8]The study of human locomotion has gained more attention recently with

    the developement of analytic and computational tools with which to examineit. A much researched subject within the field today is the effort to modelhuman motor control systems using control theoretic methods. Analytic,computational, and experimental studies of locomotion can produce modelsthat provide further insight into the design and functioning of human motorcontrol systems, as well as provide directions for research into diagnostics andtherapies for muscle- and nerve-related disorders affecting these systems.

    The aim of this work is to investigate the difficulties related to the con-trol of a such strongly nonlinear system, as a human limb, and to design acontroller for a simple nonlinear limb model. For this aim we need a modelsuitable for the mathematical tools of linear and nonlinear control theoryand system analysis - a nonlinear state space model.

    1.1 Literature review on human locomotion analysisand control

    Several control models exist that take different important aspects of humanlocomotion control into account, in various cases of control tasks. The mostrelevant results of recent investigations on locomotion analysis and controlare listed and summarized in the following list:

    •   A multi level control model including timing and learning was devel-oped by Levine and Loeb [18].

    •  A study proposed by Levine and Zajac [20] has shown, that in the caseof the pedaling problem, the control to achieve maximal accelerationfor a simple skeletal system is bang-bang.

    5

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    7/82

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    8/82

    Hungarian scientific background of locomotion analysis:

    Modelling of limb movement patterns based on neuronal activity has beendeveloped in Hungary for some years. Differential neuro-muscular-skeletalstructures have been studied by Laczko et al. [15, 14, 13] using mathematicalmodels and computer simulation.

    A neuro-mechanical model was developed by Fazekas in [6, 7]. It takesinto account the one and two-joint muscles. It handles the force-length andforce-frequency relationship, passive force, geometric and inertial propertiesof the limb, the maximal isometric forces and the gravitational effect.

    1.3 Structure of the diploma work

    The description of the construction method and the derived equations of the simple limb model can be found in chapter 2. Chapter 3 describes theanalysis results of the simple limb model. In chapter 4 the description, andresults of the applied control methods can be found. Conclusions of the workand possible future works are summarized in chapter 5.

    7

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    9/82

    2 Construction of a simple limb model in state-

    space

    2.1 Limb and muscle modelling

    Our aim is to create a model of a simple one-joint system with a flexor andan extensor muscle (see in figure 1) which is suitable for nonlinear systemsanalysis and control.

    The models of dynamics of a one-joint system with two muscles containsthe equations of multi-rigid-limb system and the equations of the dynamicsof muscle contraction. The crucial component of this system is the model

    that generates the exerting muscle forces.

    Muscle modelling:Different muscle models exist that focus different important aspects of 

    muscle functioning. In some of the models individual muscle characteristicsare used, and some of the models deal with generalized muscle characteristicsthat are valid for all muscle. But most of the existing models deal only witha partial functioning of the muscle such as a force depending on the musclelength or muscle geometry or firing rates of nerves etc.

    There are some models that deal with the movement pattern generation

    according to the force exertion and neuronal input. For example Cheng [3]created this kind of model.

    A simple nonlinear limb model:In this chapter the model equations are derived from first engineering (med-

    ical) principles based on the detailed model of Fazekas [8], Zajac [28] and VanSoest [21]. Therefore the equations are transformed into a state-space modelform.

    2.2 System description

    A simple two dimensional limb is considered that consists of two musclesand one joint. The schematic picture of the limb is shown in figure 1. Theinput of the model consists of the activation signal or stimuling signal of eachmuscles as a function of time. Activation signals are normalized, i.e. theirvalues are between zero and one.

    In general case, the output of the model is the joint angle.

    8

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    10/82

    Figure 1: The system

    2.2.1 Modelling assumptions

    •  Dimension: The model is two dimensional.

    •  Structure: We model 2 muscles, one joint.

    •  Segments: The bones are totally rigid.

    •  Gravity: Gravity appears in the direction -y only.

    •  Geometry: We do not model the geometry of bones and the muscle.

    •   Muscle Properties: The model takes into account only the followingproperties of the muscle: Force-length dependency, Force-contractionvelocity dependency, Passive Force. The characteristics are the same

    by the flexor, and the extensor muscle.

    •  Moment arms: Moment arms are constants.

    •  Aponeurosis: There is not aponeurosis.

    •  Pennate effect: We do not deal with the pennate effect.

    •  Tendon: We suppose viscoelastic tendon.

    9

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    11/82

    •  Fatigue: In general case, we do not model fatigue, potentialization and

    short time histories in the muscles.

    •  Activation dynamics: We use first-order activation dynamics model.

    •  Viscosity: We do not model viscosity in the muscle.

    2.3 Muscle properties

    To construct a state-space limb model, at first we need to examine the proper-ties of its components (muscles, tendon, etc). We start with the mathematicalequations describing the behaviour of the muscles.

    2.3.1 Force-length characteristics (F L(lCE ))

    The equation describes the quotient of the actual force, and the maximalforce of the muscle, at given length (lCE ). We use a parabolic function:

    F L(lCE ) = c

    lCE 

    loptCE 

    2− 2c

    lCE 

    loptCE 

    + c + 1 (1)

    where lCE   [m] is the actual length of the muscle, loptCE  [m] is the optimal length

    of the muscle, at which it can produce it’s maximal force. The coefficient  c

    is defined by:   c =  −  1

    ω2   where ω  is a constant, describing the range of length,where the muscle is able to work. As Soest [22], we define  ω  = 0.56 .

    The equation (1) is only valid in the range of 1 − ω ≤

    lCEloptCE

    ≤ 1 + ω

    outside this range FL is 0. We can see the characteristics in figure 2.

    0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.50

    0.2

    0.4

    0.6

    0.8

    1

    lCE

       F   /

       F  m  a  x

    Figure 2:   F L(lCE )

    10

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    12/82

    2.3.2 Force-contraction velocity characteristics (F v(vCE ))

    The force produced by a muscle depends on its actual contraction velocity.We use a similar function to Hill’equation [10], extended by Van Soest [21]that is:

    F v(vCE ) =

    (1+Aref )Bref vCE

    loptCE

    +Bref − Aref    if  vCE    > 0

    c1−vCE

    loptCE

    −c3− c2   otherwise

    (2)

    where

    c1  =  −Bref (1−F asy)2

    2+2Aref , c2  =  −F asy, c3 =

      Bref (1−F asy)2+2Aref 

    Furthermore, vCE   is the actual contraction velocity of the muscle (posi-tive, if the muscle is contracting, and negative if the muscle is extracting),Aref  and Bref  are constants, F asy is a constant, which shows at excentric con-traction the quotient of the actual available force, and the maximal isometricforce.

    This function is not continously differentiable, so to avoid the problems,we use an approximating smooth function that fits to the requirements of nonlinear analysis (the parameters of the function were found in experimental

    ways):

    F v(vCE ) = −3/2 arctan(9/5 vCE  −  925

    )π−1 +   167200

      (3)

    The original and the approximated functions are shown in figure 3.

    −3 −2 −1 0 1 2 30

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    1.4

    1.6

    vCE

      [m/s]

       F   /   F

       m   a   x

    equation of Hillaxpproximation

    Figure 3:   F v(vCE ) and its approximation

    11

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    13/82

    2.3.3 Passive force (F PE )

    For describing the passive force  F PE  as a function of   lCE    we use modifiedsigmoid functions for both the flexor and extensor muscles:

    F PE  = (1 − sigm[7(−lCE  + 0.3333)]10)F maxPE    (4)

    where the function identifier ’sigm’ stands for the function:

    y = sigm[x] =   11+e−100x

    with  F maxPE    being the maximal passive force. We denote the flexor muscle’s

    passive force by  F PE 1  and the extensor muscle’s passive force by  F PE 2.

    1.04 1.06 1.08 1.1 1.12 1.14 1.160

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    1

    lCE

     /lCE

    opt

       F   P   E

       /   F   P   E  m  a  x

    Figure 4: The function  F PE 

    12

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    14/82

    2.3.4 Muscle activation (q )

    The differential equation of the muscle shows the connection between  q (t), theactivation state of the muscle and the activation signal  u(t). With u(t) ∈  [0, 1]the equation taken from Zajac [28] is:

    dq 

    dt  = −

      1

    τ act(β  + [1 − β ]u(t)

    q  +

      1

    τ actu(t) (5)

    where  τ act  [s] is the activation time, showing how quick the muscle reacts onthe external activation signal coming from the nerval system.   β  is a constant,describing the correlation between the decrease of the activation state andthe external activation signal. If  β  = 1 then the external activation signaldoes not affect the decrease of the activation state, if  β  = 0 then it stronglyaffects it.   q 1(t) denotes the activation state of the flexor muscle, and  q 2(t)denotes the activation state of the extensor muscle.

    2.3.5 Muscle force (F CE )

    We can compute the force of the muscle with the characteristics above in thefollowing form:

    F CE  = F maxF L(lCE )F v(vCE )q  + F PE    (6)

    where  F max   is the maximal force of the muscle. We use F CE 1  for the flexormuscle’s force and  F CE 2  for the extensor muscle’s force.

    F CE 1 =  F maxF L(lCE 1)F v(vCE 1)q 1 + F PE 1

    F CE 2 =  F maxF L(lCE 2)F v(vCE 2)q 2 + F PE 2   (7)

    where q 1 is the flexor muscle’s activation state  q 2 is the extensor muscle’s acti-vation state, lCE 1  [m] is the length of the flexor muscle,  lCE 2  [m] is the lengthof the extensor muscle,   vCE 1   [m/s] is the contraction velocity of the flexor

    muscle and  vCE 2  [m/s] is the contraction velocity of the extensor muscle.

    13

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    15/82

    2.4 Tendon properties

    2.4.1 The tendon’s dynamical equations

    We need tendons to transport the force from the muscles to the bones. Wedescribe the tendon’s behaviour with the following equations:

    ∂lT ∂t

      = vT ∂vT ∂t

      = −kt(lT −l

    slackt   )+sT vT −F T 

    zT 

    (8)

    where the first equation is valid only, if  lT   > lslackT    .   lT  [m] is the actual length

    of the tendon,   lslackT    [m] is the tendon’s length in the case, when forces do

    not appear.   vT   [m/s] is the extracting velocity of the tendon (it is positive,if the tendon extracts),   kT   [N/m] is the elasticity constant of the tendon,sT   [Ns/m] and   z T   [Ns

    2/m] are constants referring to the dynamics of thetendon,  F T  [N] is the force acting on the tendon.

    2.5 Dynamic equations at the limb level

    2.5.1 Forces

    Besides the force of the muscle, we use a sigmoid function for modelling theforces of ligaments and bones in the end-positions of the joint. These func-

    tions are sigmoid in both of the angle of the joint and in the angle velocityto take unelastic properties (the properties making the joint available to dis-sipate motion energy) of the joint into account. The equation for describingthe forces of the ligaments is as follows:

    F lig  = F maxlig   sigm[0.3(α − ρ)]sigm[0.5ω] (9)

    where  α   [rad] is the external joint angle,  F maxlig   [N ] is the maximum force of the ligaments and bones,  ρ  [rad] is a constant, describing at which angle theforce appears and  ω   [rad/s] is the joint angle velocity. We use  F lig1   for theforce, which appears at 0 angle, when the limb can not be more extended (at

    the maximum length of the flexor muscle), so it wants to flex the limb, andF lig2  for the extensor ligamental force.

    The flexing forces can be computed as:

    F flexor = F CE 1 + F lig1   (10)

    The extending forces can be computed as:

    F extensor  = F CE 2 + F lig2   (11)

    14

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    16/82

    We suppose, for the sake of simplicity, that the forces of the ligaments

    and bones appear at the same point as the forces of the muscle.Furthermore, apart from the most extended and most flexed states, we

    can neglect the forces of ligaments (and in some cases the passive force too),to further simplify the model for symbolic analysis.

    In this model the force of the tendon is of the same size as the force of themuscle and ligaments, it just appears in the opposite direction. For example:F T 1  = −F flexor  where  F T 1   [N] is the tendon’s force.

    2.5.2 Joint torques

    The movement is determined not directly by the forces conveyed by thetendon, but by their torques. For example the flexor tendon’s torque can bewritten as:

    M 1  =  −F T 1d =  F flexord   (12)

    where  d  [m] is the moment arm, the distance between the axis of the joint,and the point, where the forces appear.The resultant joint torque can be computed as:

    M  = M 1 − M 2   (13)

    2.5.3 Movement

    Now we know how the forces are generated, and transported to the bones.Let us then examine how the limb moves. We use the form of Newton’s IIlaw applied to rotation movement as follows:

    ∂α∂t

      = ω

    ∂ω∂t

      =   1Θ+ml2

    COM 

    (M  + mlCOM cos(α + ξ )gy)(14)

    where   α   [rad] is the joint angle,   ξ   [rad] is the angle between the globalcoordinate-system’s   x  axis, and the not-moving upper segment of the limb(in our model  ξ   is always equal to  −π/2),  ω   [rad/s] is the angle velocity, Θ[kgm2] is the moment of inertia defined to the mass-centre point of the bone,m [kg] is the mass of the moving limb part,  lCOM  [m] is the distance betweenthe moving limb part’s center of mass point and the joint axis,  M  [Nm] is theresulting joint torque, and  g   = [gx, gy] [m/s

    2] is the vector of gravitationalacceleration.

    15

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    17/82

    What’s left, is to define the connection between the joint angle, and

    the muscle length. For the limb the actuator system does not matter, soat the level of the segments we talk about muscle-tendon complexes. So,what we can directly compute from the joint angle, is the length of thesemuscle-tendon complexes. We will denote these muscle-tendon complexeswith  CE  + T   in the subscript. We can compute the length of the muscle-tendon complexes approximately with the following equations:

    In the case of flexor muscle:

    lCE +T   =  d2 + (d prox)2 − 2dd proxsinα(t)

    2

      +  d2 + (ddist)2 − 2dddistsinα(t)

    2(15)

    In the case of extensor muscle:

    lCE +T   =

     d2 + (d prox)2 + 2dd proxsin

    α(t)

    2  +

     d2 + (ddist)2 + 2dddistsin

    α(t)

    2(16)

    where   lCE +T   [m] is the length of the muscle-tendon complex,   d   [m] is themoment arm,  d prox [m] is the distance between the joint, and the origin of 

    the muscle,   ddist

    [m] is the distance between the joint, and the insertion of the muscle,  α   [rad]is the joint angle. The extracting velocity of the muscle-tendon complex can be computed as:

    vCE +T  = dlCE +T 

    dt  (17)

    From these values we can compute the length, and contraction velocityof the muscles, if we know the length and extraction velocity of the tendons.Both for flexor and extensor muscles:

    lCE (t) = lCE +T (t) − lT (t)

    vCE (t) = vCE +T (t) + vT (t)(18)

    16

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    18/82

    2.6 State-space model equations and its variables

    2.6.1 Variables in the state-space model

    We have the following state variables:

    •   Joint angle:   α  [rad]

    •   Joint angle velocity  ω   [rad/s]

    •  Muscle activation state (for flexor and extensor muscle):   q 1,  q 2

    •  Tendon length (of the flexor and the extensor muscle):   lT 1, lT 2   [m]

    •   Tendon extracting velocity (for flexor and extensor muscle):   vT 1, vT 2[m/s]

    So we get:   x = [q 1   q 2   α ω lT 1   lT 2   vT 1   vT 2]T 

    We have the following input variables:

    •   Flexor muscle’s activation signal:   u1(t)

    •   Extensor muscle’s activation signal:   u2(t)

    The output of the model is the joint angle:   y=α=x3

    2.6.2 State-space equations

    dq1dt

      = −  1τ act

    (β  + [1 − β ]u1(t))

    q 1 +  1τ act

    u1(t)

    dq2dt

      = −  1τ act

    (β  + [1 − β ]u2(t))

    q 2 +  1τ act

    u2(t)

    dαdt

      = ω

    dωdt

      =   1Θ+ml2

    COM 

    (M (q 1, q 2, α , ω , lT 1, lT 2, vT 1, vT 2) + mlCOM cos(α + ξ )gy)

    dlT 1dt

      = vT 1

    dlT 2dt

      = vT 2

    dvT 1dt

      = −kt(lT 1−lslackt   )+sT lT 1−F flexor(q1,α,ω,lT 1,vT 1)

    zT 

    dvT 2dt

      = −kt(lT 2−l

    slackt   )+sT vT 2−F extensor(q2,α,ω,lT 2,vT 2)

    zT 

    (19)

    17

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    19/82

    With the notation of   x1,x2...,x8   for state space variables the equations

    are as follows:

    dx1dt

      = −  1τ act

    (β  + [1 − β ]u1(t))

    x1 +  1τ act

    u1(t)

    dx2dt

      = −  1τ act

    (β  + [1 − β ]u2(t))

    x2 +  1τ act

    u2(t)

    dx3dt

      = x4

    dx4dt

      =   1Θ+ml2

    COM 

    (M (x1, x2, x3, x4, x5, x6, x7, x8) + mlCOM cos(x3 + ξ )gy)

    dx5dt

      = x7

    dx6dt

      = x8

    dx7dt

      = −kt(x5−lslackt   )+sT x7−F flexor(x1,x3,x4,x5,x7)

    zT 

    dx8dt

      = −kt(x6−lslackt   )+sT x8−F flexor(x2,x3,x4,x6,x8)

    zT 

    (20)

    y = x3

    18

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    20/82

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    21/82

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    22/82

    2.7 Model verification

    The model verification has been performed by simulation where the modelresponse has been tested against engineering intuition. The following testcase was used: The activation signal of the flexor muscle was equal to 1 fromt=0 to t=0.5, 0 from t=0.5 to t=1, 0.5 from t=1 to t=1.5 and 0.6 from t=1.5to t=2. The extensor muscle’s activation signal was equal to 0 from t=0 tot=0.5, 1 from t=0.5 to t=1, 0.5 from t=1 to t=1.5 and 0.1 from t=1.5 tot=2, as it can be seen in the following figure.

    0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 20

    0.2

    0.4

    0.6

    0.8

    1

    1.2u

    1u

    2

    Figure 5: The muscle activation signals

    The muscle activation states are shown in figure 6, as functions of time(q 1  is the flexor muscle’s activation,  q 2  is the extensor’s):

    0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 20

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    1q1,q2

    t [s]

       q   1 ,   q

       2

    q1q2

    Figure 6: The muscle activation states

    21

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    23/82

    Figure 7 shows  α  and  ω  as functions of time:

    0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2−30

    −25

    −20

    −15

    −10

    −5

    0

    5

    10

    15alpha,omega

    t [s]

      a   l  p   h  a   [  r  a   d   ] ,  o  m  e  g  a   [  r  a   d   /  s   ]

    alphaomega

    Figure 7:   α and  ω

    The length of the tendons -  lT 1  (the flexor muscle’s tendon) and  lT 2   (the

    extensor muscle’s tendon) - are depicted in figure 8:

    0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 20.1

    0.101

    0.102

    0.103

    0.104

    0.105

    0.106

    0.107

    0.108

    0.109l1,l2

    t [s]

       l   1   [  m   ] ,   l   2   [  m   ]

    l1l2

    Figure 8: The length of the tendons

    The length of the muscles are seen in figure 9 with   lCE 1  being the flexormuscle’s length and  lCE 2  being the extensor muscle’s length:

    22

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    24/82

    0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 20.15

    0.2

    0.25

    0.3

    0.35

    0.4

    0.45

    0.5lCEf,lCEe

    t [s]

       l   C   E   f   [   m   ] ,   l   C   E   e   [   m   ]

    lCEf

    lCEe

    Figure 9: The length of the muscles

    In figures 7 and 8 we can clearly see the strong forces of the ligamentsappearing at the maximal flexed/extended states.

    Taking into account the aim of the model construction, the simplifica-tions used in the construction process and the simulation results, the modelbehaves as one expects, thus the model is verified and is acceptable for con-troller design purposes.

    23

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    25/82

    2.8 A biological extension: A simple Gamma-loop model

    The   γ -loop is a well known solution in human and other species for someproblems emerging in muscle actuation. The short description of the mech-anism, and its componetents can be found in the appendix. (see more in[23])

    Figure 10: The servomechanical  γ -loop as depicted in [23]

    2.8.1 The simplified model of the Gamma-loop

    Simplifying assumptions

    •  The receptors of the muscle spindles can sense only the length differ-ence between the muscle fibers inside the muscle spindles   ls, and thesurrounding muscle fibers, of which length are commensurable to theworking muscle length  lCE .

    •  The activation signal of the spinal neurons is linear in the signal of themuscle spindles’s detector.

    24

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    26/82

    •   In this case, there’s no other input to the system, only the muscle

    spindle’s activation signals.

    In this case, we can extend our model with two more state-space variables:With the lengths of the muscle fibers of the muscle spindles (ls1  in the caseof the flexor muscle, and  ls2   in the case of the extensor muscle).

    If we suppose, that the normal length of the muscle spindles (and thesurrounding muscle fibers) is always one tenth of the working muscle, we candescribe the behavior of the new variables with the following equations:

    dls1

    dt   = cP (lCE 1/10 − ls1) − cGus1(t)dls2dt

      = cP (lCE 1/10 − ls2) − cGus2(t) (21)

    where cP   [1/s] is a constant showing how quick the length of the muscle spin-dles (and the muscle fibers inside the muscle spindles) follows the length of the working muscle (lCE 1,   lCE 2),  cG   is a constant showing how sensitive themuscle spindle is to the external activation signal of the descending tracts,and  us(t) is the activation signal of the descending tracts acting on the themuscle fibers inside the muscle spindles. If we consider the normalized valuesof  lCE 1/10 − ls1 and  lCE 2/10 − ls2 as the signals of the muscle spindles’s recep-tors we can compute the activation states of the working muscles (denotedwith  q 1  and  q 2   in the equation (20)):

    q 1 = cG(lCE 1/10 − ls1)

    q 2 = cG(lCE 2/10 − ls2) (22)

    25

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    27/82

    2.8.2 Simulation results

    We act on the flexor muscle’s spindle with the following activation signal:

    0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.50

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    t [s]

      u   f

    Figure 11: the activation signal of the flexor muscle’s spindle

    We can see the muscle lengths, and the length of the muscle spindles(multiplied with 10 for the better comparability) in the next figure:

    0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.50.05

    0.1

    0.15

    0.2

    0.25

    0.3

    0.35

    0.4

    t [s]

       l   e   n   g   t   h   s   [   m   ]

    lCE1

    ,lCE2

    ,10ls1

    ,10ls2

    lCE1

     

    lCE2

     

    10ls1

    10ls2

    Figure 12: the length of the muscles and the muscle spindles

    26

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    28/82

    In the next two figures, we can see the working muscles’s activity states

    (q 1  and  q 2) the angle, and the angle velocity of the joint:

    0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5−0.1

    0

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9q1,q2

    t [s]

       q   2 ,   q

       2

    q1q2

    Figure 13: the activation state of the working muscles

    0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5−3

    −2

    −1

    0

    1

    2

    3

    4alfa,w

    t [s]

       a   l   f   a   [   r   a   d   ] ,   w

        [   r   a   d   /   s   ]

    Figure 14: joint angle and velocity

    We can see, that in the beginning as the joint angle decreases the flexormuscle begins to extract. The flexor muscle’s spindle follows the extractionwith a little delay, so it generates a little activity in the flexor muscle - andso a little force, slowing down the decreasing of the joint angle a bit. As theactivation signal’s impulse reaches the flexor muscle’s spindle, it contracts,generating a big activation state growing in the flexor muscle, that increasesthe joint angle.

    We can see, that in general case, the γ -loop mechanism prevents the jointfrom sudden movements, providing more smooth movement of the limb.

    Furthermore, the mechanism increases the   relative degree   (see later) of the system.

    27

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    29/82

    3 Model analysis

    The aim of the model analysis is to determine the dynamic properties, thatinfluence the controller design (stability controllability, observability, zerodynamics etc.).

    Let us write the state-space model in the following input affine form, thatcan be obtained from equation (20):

    ẋ =  f (x) +m

    i=1 gi(x)ui(t)

    y  =  h(x)(23)

    where:

    f (x) =

    −   1τ act

    βx1

    −   1τ act

    βx2

    x4

    1Θ+ml2com

    (M (x1, x2, x3, x4, x5, x6, x7, x8) + mlcomcos(x3)gy

    x7

    x8

    −kT (x5−l

    slackT 

      )+sT x7−F flextor(x1,x3,x4,x5,x7)

    zT 

    −kT (x6−l

    slackT 

      )+sT x8−F flextor(x2,x3,x4,x6,x8)

    zT 

    28

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    30/82

    g1(x) =

    −   1tauact (1 − β )x1 +   1tauact

    0

    0

    0

    0

    0

    0

    0

    g2(x) =

    0

    −   1tauact

    (1 − β )x2 +  1tauact

    0

    0

    0

    0

    0

    0

    0

    h(x) = x3

    We can observe, that the state function  f  is nonlinear, but both the inputfunctions  g1  and  g2  and the output function  h  are linear.

    29

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    31/82

    3.1 Linear analysis

    The well-known standard methods of linear analysis can only be applied forlinear time-invariant (LTI) systems with the following state-space model:

    ẋ =  Ax + Buy  =  C x

      (24)

    3.1.1 Linearization around a steady-state point

    We call  x0(u0) a steady-state point of the system, if 

    ẋ =  f (x)|x0 +

    mi=1

    gi(x)ui(t)|u0  = 0

    From the input-affine state space model in equation (23) we can obtain a LTImodel by linearizing it locally around a steady-state point  x0(u0), as in [2].

    Let us take the centered variables:

    x̃ =  x − x0   ũ =  u − u0

    To obtain the LTI model form:

    ˙̃x =  Ãx̃ +  B̃ũ

    ỹ  =  C̃ ̃x  (25)

    we can compute the matrixes  Ã,  B̃  and  C̃  in the neighborhood of the steady-state point (x0, u0) in the following way:

    à=  J (f,x)|x(0) + J (g,x)|x(0)u(0)

    B̃ = g(x0)

    C̃  = J (h,x)|x(0)

    (26)

    where  J (v,x) is the Jacobian-matrix of the multivariate function  v:

    J (v,x) j,i   =

     ∂v j∂xi

    30

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    32/82

    Two steady-state points were selected for linear analysis purposes:

    •  The most extended steady-state of the limb (very low effect of gravity)- both of the muscles are totally inactive.

    •   π/2 joint angle (no effects of ligaments and passive force)

    3.1.2 Analysis of the linearized model at the first steady-statepoint

    Equation (27) contains the state matrix  Ã   in the first steady state point:

    Ã = 104∗

    −0.0042 0 0 0 0 0 0 00   −0.0042 0 0 0 0 0 00 0 0 0.0001 0 0 0 0

    0.0112   −0.0102   −0.0047   −0.0004   −0.000 0.000 0 00 0 0 0 0 0 0.0001 00 0 0 0 0 0 0 0.0001

    0.052 0   −0.0004   −0.0002   −1.25 0   −1.25 00 0.0048 0.000 0.000 0   −1.25 0   −1.25

    (27)The rank of  A is 8.We obtain the following results at the steady-space point in the neigh-

    borhood of the most extended state of the limb:Steady-state conditions (in case of  u1 = u2 = 0):

    x1,0 = 0x2,0 = 0x3,0 ≃ 0.004516x4,0 = 0x5,0 ≃ 0.1

    x6,0 = 0.1x7,0 = 0x8,0 = 0

    (28)

    The  Ã martix’s eigenvalues are the following:

    31

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    33/82

    103

    −1.245−0.005−0.0022 + 0.0065i−0.0022 − 0.0065i−1.2450−0.005−0.0417−0.0417

    (29)

    If the eigenvalues of the state-matrix  Ã   have negative real part, then thelinear system is stable, and this is the case in the first steady-state point.

    Next we analyze the controllability and observability testmatrices, con-structed from the  Ã,  B̃  and  C̃  matrices of the linearized system - see [17].

    In the first steady-state point:

    B̃  =

    65.7255 00 83.3330 00 0

    0 00 00 00 0

    ,   C̃  = [0 0 1 0 0 0 0 0]

    Controllability testmatrix:

    M c  = [B AB......An−1B] (30)

    If the rank of the controllability testmatrix is equal to   n   (the number of 

    states) the system is state-controllable, which means also output controlla-bility in our case.

    Observability testmatrix:

    M 0  =

    C CA

    ...CAn−1

    (31)

    32

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    34/82

    If the rank of the observability testmatrix is equal to  n (the number of states)the system is observable.

    The results of the analysis in the first steady-state point is as follows::

    •  The linearized system is stable.

    •  The linearized system is controllable.

    •  The linearized system is observable.

    3.1.3 Analysis of the linearized model at the second steady-statepoint

    We can find an another steady state-point at  π/2 joint angle with the follow-ing steady-state conditions (of course, in this case the flexor muscle is active- we take a case, when only the flexor muscle is active -  u1  = 0.0554 - andthe extensor muscle is totally inactive -  u2 = 0):

    x1(0) = 0.1050x2(0) = 0x3(0) = π/2

    x4(0) = 0x5(0) = 0.101439x6(0) = 0.1x7(0) = 0x8(0) = 0

    (32)

    In this point:

    Ã = 104∗

    −0.0052 0 0 0 0 0 0 00   −0.0042 0 0 0 0 0 00 0 0 0.0001 0 0 0 0

    0.0095   −0.0083   −0.0009 0.000   −0.0206 0.000   −0.0037 00 0 0 0 0 0 0.0001 00 0 0 0 0 0 0 0.0001

    0.0045 0   −0.0004 0.000   −1.2597 0   −0.1267 00 0.0039 0.000 0.000 0   −1.2500 0   −0.1250

    (33)

    The rank of the matrix  Ã in this case is 8.

    33

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    35/82

    The eigenvalues are as follows:

    103

    −1.25700.0000 + 0.0030i0.0000 − 0.0030i−0.0100−1.2399−0.0101−0.0520−0.0420

    (34)

    ˜B,

     ˜C  are the same as above, and  M C , M O  are computed the same way. Theresults of the analysis in the second steady-state point is as follows:

    •  The linearized system is at the edge of stability(it has a pole-pair with 0 real-part)

    •  The linearized system is controllable

    •  The linearized system is observable

    3.2 Relative degree

    The SISO (single input, single output) nonlinear system

    ẋ =  f (x) + g(x)u

    y  =  h(x) (35)

    has  relative degree r  at a point  x0 if 

    1.   LgLkf h(x) = 0 for all x in a neigborhood of  x

    0 and all  k > r − 1

    2.   LgLr−1f    h(x

    0) = 0

    where   Lgh(x) =  dh(x)

    dx  g(x) is the Lie-derivative of  h(x) along  g. Instead of 

    performing the Lie-derivatives we can easily determine the  relative degreeof a system, using graph-theoretic methods [2]. We have to determine thelength of the shortest directed path from the input to the output vertex inthe structure graph (see below) , and this length -1 is the  relative degree of the system.

    34

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    36/82

    3.2.1 The structure graph

    The structure graph of a system is constructed in the following way:

    •   The vertices of the graph are the state-variables, the input variables,and the output variables.

    •  A directed path leads form the vertex V 1  to the vertex V 2  if and only if the variable V 2  depends on V 1  (If  V 2  is a state-variable, this means thatV 1  can be found in the state-equation describing the time derivative of V 2. An output variable depends on a state variable if and only if thestate variable can be found in it’s output equation).

    Figure 15 shows the structure graph of our simple limb model.In our case the length of the shortest directed path from  u1  (or form u2)

    to  y   is 4, therefore the relative degree of the system is 3.

       

     

     

     

     

     

     

     

     

    Figure 15: The structure graph

    35

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    37/82

    3.3 Controllability

    In general case we study the controllability of the original nonlinear state-space model (see in equation (20)) with the tool of the controllability distri-bution (∆c) (see [11]).

    3.3.1 Algorithm for constructing the controllability distribution

    1.  Starting point 

    ∆0  = span{g1, g2}   (36)

    2.   Development of the controllability distribution 

    ∆k  = ∆k−1 m

    i=0

    [gi, ∆k−1] (37)

    where:[gi, ∆k−1] = span{[gi, φ1], ..., [gi, φl]}

    where   φ1...φl   are the vectors spanning ∆k−1, and [f, g] denotes the Lie-product of  f   and  g :

    [f, g](x) =  ∂g(x)∂x

      f (x) − ∂f (x)∂x

      g(x)

    ∂g(x)∂x

      is the Jacobian matrix of the function g  with respect to its independentvariable  x .

    3.   Stopping condition 

    If ∆k  = ∆k−1, then ∆c = ∆k

    If the dimension of the controllability distribution is equal to  n  (the numberof states), then the system is controllable.

    In our case the symbolic expressions needed for computing of the con-trollability distribution are so complex, that it is impossible to determinethe Lie-brackets with the available methods, so we use another method forcontrollability analysis.

    36

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    38/82

    3.3.2 Structural controllability and observability

    Structural controllability and observability [2] apply for a set of systems withthe same structure, i.e. with the same structure graph.

    A set of linear or linearized systems with structure matrixes ([ A ],[ B  ],[ C  ])is structurally controllable or observable if 

    •  The matrix [ A ] is of full structural rank (maximal possible rank within the class specified by the structure matrix)

    •   The system structure graph S is input connectable or output connectable.For controllability there should be at least one directed path from any of 

    the input variables to each of the state variables. For observability there should be at least one directed path from each of the state variables toone of the state variables.

    Structural controllability implies that the points where the system is notcontrollable are forming a set with 0 measure.

    3.3.3 Structural controllability analysis of the model

    Because the rank of the matrix  Ã  of the linearized system is 8 in both in-vestigated steady-state points, it’s structural rank is 8. We can apply the

    structural controllability method for the entire set of the locally linearizedsystems.We can see in figure 15 , that we can find directed paths from the inputs

    to the states, so the system is structurally controllable. This is in a goodagreement with the results of the linear controllability analysis (see section3.1).

    3.4 Observability

    3.4.1 Algorithm for constructing the observabilityco-distribution

    Similarly to the controllability-analysis, in the general case we study the ob-servability of the model with the observability co-distribution Ωo.

    1.  Starting point 

    Ω0 = span{g1, g2}   (38)

    2.   Development of the observability co-distribution 

    37

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    39/82

    Ωk  = Ωk−1 m

    i=0

    LgiΩk−1   (39)

    where:   LgiΩk−1   is the Lie-derivative of Ωk−1   along  gi, and the expansion tothe spanned sub-space is the same as above.

    3.   Stopping condition If Ωk  = Ωk−1, then Ωo  = Ωk

    If the dimension of the controllability distribution is equal to  n  (the numberof states), the system is controllable.

    3.4.2 Structural observability analysis of the model

    Similarly to the controllability, we study structural observability. In figure15 we can find directed paths from the states to the output, so the system isstructurally observable. This is in a good agreement with the results of thelinear observability analysis (see section 3.1)

    38

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    40/82

    3.5 Stability

    We can easily determine the stability of a linear system, by analyzing itseigenvalues as in section 2.1. In the nonlinear case, we use the Lyapunov-theory.

    3.5.1 Lyapunov-stability

    definiton:If   ξ (t) is a solution of the differential equation ẋ   =   f (x, t), we say that

    the solution  ξ (t) is a Lyapunov stable solution, if for  ∀   t0  ∈   [a, ∞) and for∀   ε > 0  ∃   δ (ε, t0) >  0, that if  x(t) is a solution and

    x(t0) − ξ (t0) < δ (ε, t0), then  ∀   t ∈  [t0, ∞)   x(t) − ξ (t) < ε.

    3.5.2 Strong asymptotic -stability

    definiton:If  ξ (t) is a solution of the differential equation ẋ =  f (x, t), we say that the

    solution  ξ (t) = 0 is a strong asymptotic-stable solution, if for  ∀   t0  ∈ [a, ∞)and for  ∀   ε > 0  ∃   δ (ε, t0) >  0, that if  x(t) is a solution andx(t0) − ξ (t0) < δ (ε, t0), then  ∀   t ∈  [t0, ∞)   x(t) − ξ (t) → 0.

    3.5.3 Lyapunov’s first theorem

    Let us suppose, that x0  is a steady-state point and  V  (x) is a positive definitescalar-valued function (Lyapunov-function). If 

    V̇  (t, x) = dV (t, x(t))

    dt  ≤ 0

    then the steady-state point is Lyapunov-stable.

    If 

    V̇  (t, x) =  dV (t, x(t))dt

     

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    41/82

    3.5.4 Estimating the stability region in the neighborhood

    of the steady-state point with quadratic Lyapunov-functioncandidate

    Let us take take the second steady-space point, and the following quadraticLyapunov function candidate:

    V  [x(t)] = (x − x∗)T Q(x − x∗) (40)

    where   x∗ is equal to the vector (32), and   Q   is a diagonal unit weightingmatrix. This results in the Lyapunov-function candidate:

    V  [x(t)] = (x1 − 0.105)2 +  x22 + (x3 − 1/2 π)

    2 +  x24+ (x5 − 0.101)

    2 + (x6 − 0.1)2 +  x27 +  x

    28   (41)

    If we compute   dV  dt

      , we can give a conservative estimation of the stabilityregion. The points were   dV  

    dt  is negative, belong to the strong asymptotically

    stable region of the steady-state point.

    dV 

    dt  =

     ∂V 

    ∂x

    dx

    dt  =

     ∂V 

    ∂xf̄ (x) (42)

    where  f̄ (x) = f (x) + g(x)C (x) with  C (x) beeing the static feedback law.In the case of the first steady-state point  C (x) = u1 = 0.0554.

    At the steady-space point (32) the value of   ∂V  ∂t

      is of course zero, becausethe system is on the edge of stability.Along α =  x3, lT 1  =  x5 and lT 2 = x6 the function

      dV  dt

      does not change, becauseof the Hamiltonian properties of the system (the description of Hamiltoniansystems can be found in [9]).

    We can study the behavior of   dV  dt

      in the neighborhood of the state-point

    described in (32), along the directions parallel to the axes  x1, x2, x4, x7, x8.So, we can get cuts of the function (42). The following figures depict   dV  

    dt  as

    a function of state-space variable pairs.

    40

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    42/82

    0

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7 −0.4

    −0.3

    −0.2

    −0.1

    0

    0.1

    0.2

    0.3

    −1000

    −500

    0

    500

    1000

    ω [rad/s]

    q1

       d   V   /   d   t

    Figure 16: The change of   ∂V  ∂t   along  q 1  and  ω

    0

    0.1

    0.20.3

    0.4

    −0.1

    0

    0.1

    0.20.3

    0.4

    −140

    −120

    −100

    −80

    −60

    −40

    −20

    0

    q1

    q2

       d   V   /   d   t

    Figure 17: The change of   ∂V  ∂t

      along  q 1  and  q 2

    0

    0.1

    0.2

    0.3

    0.4

    −0.4−0.3

    −0.2−0.1

    00.1

    0.20.3

    −800

    −600

    −400

    −200

    0

    200

    400

    600

    q2

    ω [rad/s]

       d   V   /   d   t

    Figure 18: The change of   ∂V  ∂t

      along  q 2  and  ω

    41

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    43/82

    −0.2−0.1

    00.1

    0.20.3

    0.40.5

    −0.4

    −0.2

    0

    0.2

    0.4−8000

    −7000

    −6000

    −5000

    −4000

    −3000

    −2000

    −1000

    0

    q1

    vT1

     [m/s]

       d   V   /   d   t

    Figure 19: The change of   ∂V  ∂t   along  vT 1  and  q 1

    3.6 Zero dynamics

    We call the systems behavior  zero dynamics  in the case, when its is outputforced to be identically zero (all time derivatives of the output are zero). Weneed to examine the zero dynamics’s stability for controller design purposes.

    Let us study the zero-dynamics for the input-output pair:   u1  (the flexormuscle’s activation signal), and  h(x) = x3 − π/2. In this case  y  ≡ 0 outputmeans 90◦  joint angle.

    α =  x3  ≡  π/2 ⇒  ẋ3  = 0 ⇒  ω  =  x4  ≡ 0  ⇒  ẋ4  = 0

    From equation (20):

    ẋ4  =  1

    Θ + ml2COM (M  + mlCOM cos(x3 + ξ )gy) = 0 (43)

    with  α =  π/2 and  ξ  =  −π/2 we get  cos(α + ξ ) = 1.

    Next we define a constant denoted by  H 1:

    mlCOM gy.

    = H 1  <  0 where  gy  = −10m/ss.

    Equation (43) can be equal to 0, if only if the joint torque   M   is equal toH 1, thus equation (43) implies

    M  = −H 1

    42

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    44/82

    We know from equation (12) that:

    M  = M f  − M e  = F flexord − F extd = (F CE 1 + F lig1)d − (F CE 2 + F lig2)d

    In the position α  =  π/2 we can neglect the forces of ligaments (because theyonly appear at the position near to the maximal flexed/extended states),and we suppose, that the extensor muscle is totally inactive, so we can alsoneglect  F CE 2. This simplifies the equation above to

    M  = F CE 1d = (F maxF L(lCE )F v(vCE )x1 + F PE )d

    Passive force of the muscle does also not appear in this position, so we neglectit, and obtain the simplified equation for the joint torque:

    M  = F CE 1d = (F maxF L(lCE )F v(vCE )x1)d   (44)

    If   α  ≡  π/2,   d prox =  ddist = 0.2m  and  d  = 0.01 we can compute the flexormuscle’s length from (18) as:

    lCE  = 0.3368 − x5

    So, we can determinate F L(lCE ), which will only depend on  x5=lT 1  by usingequation (1).

    Furthermore, if 

    1 − ω ≤

    lCEloptCE

    ≤ 1 + ω

    then we can compute the flexor muscle’s contracting velocity from the time

    derivative of the muscle length:

    vCE  =  dlCE

    dt

    If we take  α =  π/2, vCE  will depend only on  x7 =  vT 1

    Next we can compute  F v(vCE ) by using the equation (3).

    43

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    45/82

    From equation (44) and  M  = −H 1  we get:

    −H 1dF maxF L(lCE (x5))F v(vCE (x7))

     = x1.

    =  −H 2

    F L(lCE (x5))F v(vCE (x7))  (45)

    where  H 2  is a newly defined constant.

    In this case zero-dynamics means that the torques originating from the ten-don’s dynamics have to be balanced by the change of muscle activation state.The states of tendon change the length (and so the contracting velocity) of muscles - in this way they change the muscle’s force. This means the change

    of the joint torques. The muscle activation also changes the muscle’s force,balancing the equilibrium of the joint torques.

    3.6.1 Zero dynamics state-space equations

    With the simplifications of the zero dynamics above, and from equation (20)we can write the zero-dynamics state-space model in the following form:

    ẋ1  =  dq1dt

      = −  1τ act

    (β  + [1 − β ]u1(t))

      −H 2FL(lCE (x5))F v(vCE (x7))

     +   1τ act

    u1(t)

    ẋ2  =   dq2dt   = 0

    ẋ3  =  dαdt

      = x4 = 0

    ẋ4  =  dωdt

      =   1Θ+ml2

    COM 

    ((F maxF L(lCE (x5))F v(vCE (x7))  −H 2

    FL(lCE (x5))F v(vCE (x7)))d + H 1) = 0

    ẋ5  =  dlT 1dt

      = x7

    ẋ6  =  dlT 2dt

      = x8

    ẋ7  =  dvT 1

    dt  = −

    kt(x5−lslackt   )+sT x7−(F maxFL(lCE (x5))F v(vCE (x7)))   −H 2FL(lCE (x5))F v(vCE (x7))zT 

    = −kt(x5−lslackt   )+sT x7+F maxH 2

    zT 

    ẋ8  =  dvT 2

    dt  = −

    kt(x6−lslackt   )+sT x8zT 

    (46)

    44

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    46/82

    3.6.2 Computing the zeroing input

    If we know the form of  q 1  = x1  as the function of time in equation (45), wecan compute it’s time-derivative:

    dx1dt

      =  d

    dt

    −H 2F L(lCE )(x5)F v(vCE )(x7)

      (47)

    =   H 21

    (F L(lCE )(x5)F v(vCE )(x7))2  ·

    ·

    F v(vCE )(x7)

     d

    dtF L(lCE )(x5) + F L(lCE )(x5)

     d

    dtF v(vCE )(x7)

    By the derivation rule of composite functions we can compute   ddt

    F L(lCE (x5))which will depend on  x5  and  x7.

    Similarly, we can also compute   ddt

    F v(vCE ).

    If we susbstitue the results to (47) we can compute   dx1dt

      .

    If we take the firs the first equation of (46), and we know the form of   ∂x1∂t   ,we can compute the zeroing input as follows:

    dx1dt

      = −  1

    τ actβx1 +

      1

    τ act[1 − β ]x1 +

      1

    τ act

    u(t)

    and therefore

    u(t) =dx1dt

      +   1τ act

    βx1

    −   1τ act

    [1 − β ]x1 +  1τ act

    (48)

    where  τ act  and  β  are the same as in equation (5).

    3.6.3 Zero-dynamics analysis results

    If we apply the input described in equation (48) to the open-loop system, wecan notice that the output is indeed identically zero.

    If we analyze the zero-dynamics in some points of the state-space (thiswas done mostly in steady-state points) we get the result that the linearizedzero-dynamics is stable in every investigated case. So we can suppose, thatthe zero-dynamics of the system is stable. This result is important for input-output type controller design.

    45

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    47/82

    4 Controller design

    The aim of this chapter is to propose different controllers to the simple limbmodel and to investigate and compare their performance. For this purposewe return back to the original model (γ -loop not included) described in equa-tion (20). In addition, we suppose that all of the state-space variables areavailable for the control system for a state feedback.

    4.1 Performance specification

    Any controller design starts with the explicite definition of the criteria forthe control system’s performance.

    4.1.1 Control aims

    Based on the most simple tasks a human upper limb should perform, wedetermine three basic tasks for the control system:

    •  Stability: We expect the closed loop system to be stable in the regionwe apply the selected control method.

    •   Regulation and Trajectory following: We expect the applied controlsolving this two basic tasks in limb movement control.

    •   Disturbance-rejection: We expect the controller being not seriouslysensitive for disturbances.

    4.1.2 Control domain

    Our aim is to control the output of the system in the neighborhood of  α =  π/2angle. The values of other the state-space variables can change in the domain

    described in section 2.6.3. The value of the actuation signal can changebetween 0 and 1 as described in 2.3.4 and 2.6.3.

    4.1.3 Disturbances

    We complete the model with three disturbances:

    •  An external mass on the edge of the moving limb-part: This can be aweight lifted by the limb.

    46

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    48/82

    •  A simplified fatigue model - the drift of the τ act parameter: As with time

    the ATP concentration decreases in the working muscle, the activationtime increases.

    •  Spontaneous muscle activity: This phenomenon can be considered forexample, as a simplified effect of the Parkinson’s disease.

    The state-space equations, modified by the disturbances are in the fol-lowing form:

    ẋ1  = −

      1τ act(t)

    (β  + [1 − β ]u1(t))

    x1 +  1τ act(t)

    u1(t) + d1(t)

    ẋ2  = −

      1τ act(t)

    (β  + [1 − β ]u2(t))

    x2 +   1τ act(t)u2(t) + d2(t)

    ẋ3  = x4

    ẋ4  =  1

    Θ+ml2COM 

    (M (x1, x2, x3, x4, x5, x6, x7, x8)

    +mlCOM cos(x3 + ξ )gy + mDlfacos(x3 + ξ )gy)

    ẋ5  = x7

    ẋ6  = x8

    ẋ7  = −kt(x5−lslackt   )+sT x7−F flextor(x1,x3,x4,x5,x7)

    zT 

    ẋ8  = −kt(x6−lslackt   )+sT x8−−F extensor(x2,x3,x4,x6,x8)

    zT 

    (49)

    where mD  is the external mass,  lfa is the length of the moving limb-part (theforearm),  d1(t) and  d2(t) are the spontaneous muscle activities as functionsof time.

    47

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    49/82

    Figure 20: The system with the external mass

    4.2 Linear SISO LQ regulator

    In order to design a linear SISO (single input, single output) LQ regulator

    [17] we use the linearized system model obtained around the steady-statepoint at  π/2 rad and the centered variables x̃  =  x −  x0   ũ  =  u − u0, as inequation (26). We use the flexor muscle’s activation signal as the only inputto the system. The other input,  u2   is set to be identically zero.

    x1(0) = 0.4031x2(0) = 0x3(0) = π/2x4(0) = 0x5(0) = 0.101439

    x6(0) = 0.1x7(0) = 0x8(0) = 0

    (50)

    u0 = 0.2528

    We can apply an LQ servo controller (see below) to minimize the cost func-tion:  

     (x̃′Qx̃ + ũ′Rũ)   dt   (51)

    48

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    50/82

    If A,B and C are the matrices of the linearized system as in section 4 .1

    (denoted there by  Ã,  B̃,  C̃ ) we design an LQ controller that is in the form of a state feedback  u(t) = −Kx(t) for the linearized system.The extended state space model used for designing the LQ-servo controlleris as follows:

     ẋ(t)ż (t)

    =

      A   0−C    0

      x(t)z (t)

    +

      B

    0

    y(t) =   C    0

      x(t)z (t)

      (52)

    where ż (t) = r(t) − y(t) and  r(t) is the reference signal of the system.

    We use the following matrices for the penalty function:

    Q =

    1 0 0 0 0 0 0 0 00 1 0 0 0 0 0 0 00 0 0.1 0 0 0 0 0 0

    0 0 0 0.01 0 0 0 0 00 0 0 0 1 0 0 0 00 0 0 0 0 1 0 0 00 0 0 0 0 0 1 0 00 0 0 0 0 0 0 1 00 0 0 0 0 0 0 0 100000

    (53)

    R = 10

    The penalty matrices’s values were found in experimental ways, takingthe importance of reference following into account.

    Solving the Ricatti-equation with MATLAB (command   lqr ), we obtainthe following value for K:

    K  = [1.168   − 1.219 7.060 0.287 1.722   − 0.000   − 0.006   − 0.000   − 100.000]

    49

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    51/82

    4.2.1 Simulation results of the SISO LQ conroller

    In this case (used as reference case) no disturbances were used. In the fol-lowing figure we can see the reference signal and the output of the system.On the figures the real (decentered) values of the variables are shown.

    0 0.5 1 1.5 2 2.51.35

    1.4

    1.45

    1.5

    1.55

    1.6

    1.65

    1.7

    1.75

    1.8alfa,r

    t [s]

       a   l   f   a   [   r

       a   d   ] ,   r   [   r   a   d   ]

    alfar − reference signal

    Figure 21: The output and the reference signal

    In this case the reference signal was  r(t) =   π2

     +   π16

    sin(3t)

    The muscle activation states (q 1,   q 2) and the muscle activation signals (oractuation signals -  u1, u2) are depicted in the following figures:

    0 0.5 1 1.5 2 2.50

    0.05

    0.1

    0.15

    0.2

    0.25

    q1,q

    2

    t [s]

      q   1 ,  q   2

    q1

    q2

    0 0.5 1 1.5 2 2.50

    0.05

    0.1

    0.15

    0.2

    0.25

    0.3

    0.35

    0.4

    0.45

    u1,u

    2

    t [s]

      u   1 ,  u   2

    u1

    u2

    Figure 22: Muscle activation states and muscle activation signals

    If we use the same reference signal, and the following matrices for thepenalty function,

    50

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    52/82

    Q =

    1 0 0 0 0 0 0 0 00 1 0 0 0 0 0 0 00 0 0.1 0 0 0 0 0 00 0 0 0.01 0 0 0 0 00 0 0 0 1 0 0 0 00 0 0 0 0 1 0 0 00 0 0 0 0 0 1 0 00 0 0 0 0 0 0 1 00 0 0 0 0 0 0 0 1000

    (54)

    R = 1

    we get the results depicted on the following figures:

    0 0.5 1 1.5 2 2.51.35

    1.4

    1.45

    1.5

    1.55

    1.6

    1.65

    1.7

    1.75

    1.8alfa,r

    t [s]

      a   l   f  a

       [  r  a   d   ] ,  r   [  r  a   d   ]

    alfar − reference signal

    0 0.5 1 1.5 2 2.50

    0.02

    0.04

    0.06

    0.08

    0.1

    0.12

    0.14

    0.16

    0.18

    q1,q

    2

    t [s]

      q   1 ,  q   2

    q1

    q2

    Figure 23: The output, the reference signal and the muscle activations

    We can see, that the closed loop system follows the reference signal withmore delay. The appearance of the delay in the trajectory following can beexplained with the system’s relative degree (3). In other words between theinput and the output 3 integrators can be found.

    51

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    53/82

    4.3 Linear MISO LQ regulator

    We are able to use both of the muscle activity signals as input, and extendthe LQ-servo controller to the MISO (multiple input, single output) system,for more efficiency and roboustness with the same linearization method as insection 4.1.

    We use the same Q as in equation (54) for the penalty function, and:

    R =

      10 0

    0 10

      (55)

    Solving the Ricatti-equation with MATLAB, we get the following value forK:

    K  =

      0.554   −0.498 3.924 0.137 0.702   −0.011   −0.003 0   −62.934−0.632 0.730   −4.885   −0.174   −0.942   −0.008 0.003 0 77.713

    4.3.1 Simulation results of the MISO LQ controller without dis-

    turbanceIn this case the reference signal was the same as above -

    r(t) = π

    2 +

      π

    16sin(3t)

    In the following figure we can see the reference signal and the output of the system:

    52

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    54/82

    0 0.5 1 1.5 2 2.51.35

    1.4

    1.45

    1.5

    1.55

    1.6

    1.65

    1.7

    1.75

    1.8alfa,r

    t [s]

      a   l   f  a   [  r  a   d   ] ,  r   [  r  a   d   ]

    alfar − reference signal

    Figure 24: The output and the reference signal by MISO LQ control

    The muscle activation states, and activation signals are shown in thefigures below, as functions of time:

    0 0.5 1 1.5 2 2.5−0.05

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    0.3

    0.35

    q1,q

    2

    t [s]

      q   1 ,  q   2

    q1

    q2

    0 0.5 1 1.5 2 2.50

    0.05

    0.1

    0.15

    0.2

    0.25

    0.3

    0.35

    u1,u

    2

    t [s]

      u   1 ,  u   2

    u1

    u2

    Figure 25: Muscle activation states, and activation signals

    We can see that if the control uses both of the muscles, the result is moreaccurate trajectory following.

    53

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    55/82

    4.3.2 Trajectory following results of the MISO LQ controller with

    disturbance

    If we use the same LQ servo-regulator and the same reference signal as inthe previous subsection (4.3.1), and apply the following disturbances:

    •  1 kg mass on the end of the limb (twice as far from the joint as themass centre of the moving limb part)

    •  Fatigue - Drift of  τ act:   τ act(t) = (1 + 0.5t)τ act

    then we get the results shown in the the following figures:

    0 0.5 1 1.5 2 2.51.35

    1.4

    1.45

    1.5

    1.55

    1.6

    1.65

    1.7

    1.75

    1.8

    1.85alfa,r

    t [s]

       a   l   f   a   [   r   a   d   ] ,   r   [   r   a   d   ]

    alfar − reference signal

    Figure 26: The output and the reference signal

    0 0.5 1 1.5 2 2.50

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    q1,q

    2

    t [s]

       q   1 ,   q   2

    q1

    q2

    0 0.5 1 1.5 2 2.50

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    u1,u

    2

    t [s]

      u   1 ,  u   2

    u1

    u2

    Figure 27: Muscle activation states, and activation signals

    54

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    56/82

    4.3.3 Regulation results of the MISO LQ controller with distur-

    bance

    If the reference signal is constant, we apply   d1(t) and   d2(t) for generatingspontaneous muscle activation for disturbance. This method can be consid-ered, for example, as a simple model of the effect of the Parkinson’s disease.

    d1(t) = |1.5 ∗ sin(14 ∗ t) ∗ sin(16 ∗ t)|

    d2(t) = |1.5 ∗ sin(15 ∗ t) ∗ sin(17 ∗ t)|

    The results are depicted in the following figures:

    0 0.5 1 1.5 2 2.51.55

    1.6

    1.65

    1.7

    1.75

    1.8alfa,r

    t [s]

       a   l   f   a   [   r   a   d   ] ,   r   [   r   a   d   ]

    alfar − reference signal

    Figure 28: The output and the reference signal

    0 0.5 1 1.5 2 2.50

    0.05

    0.1

    0.15

    0.2

    0.25

    0.3

    0.35

    q1,q

    2

    t [s]

      q   1 ,  q   2

    q1

    q2

    0 0.5 1 1.5 2 2.50.06

    0.08

    0.1

    0.12

    0.14

    0.16

    0.18

    0.2

    0.22

    0.24

    u1,u

    2

    t [s]

      u   1 ,  u   2

    u1

    u2

    Figure 29: Muscle activation states, and activation signals

    55

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    57/82

    4.4 Input-Output linearization

    In this section we use only the flexor muscle’s activation signal as input tothe system (the extensor muscle’s activation signal is identicaly zero), to geta SISO (single input single output) structure.

    As described in [9] for a nonlinear n-dimensional SISO system with rela-tive degree  r < n  we need to apply the feedback

    u =  1

    LgLr−1f    h(x)

    (−Lrf h(x) + v(t)) (56)

    and a suitable nonlinear co-ordinate transformation to obtain:

    •  a linear subsystem of order  r  which is influenced by the chosen inputu - including the external input  v(t) and

    •  a nonlinear subsystem described by the zero dynamics

    This means, that the state-space model of the input-output linearized closedloop system is the following in the new co-ordinates:

    ż 1   =   z 2   ˙z r+1 = q r+1(z )

    ż 2   =   z 3   ˙z r+2 = q r+2(z )

    ... ...

    ˙z r−1   =   z r   ż n  =  q (z )

    ż r   =   v y  =  z 1

    (57)

    where  Lf h(x) denotes the Lie-derivative of  h(x) along  f .In our case r=3, so a three dimensional subsystem will be linear in the new

    coordinates z 1, z 2, z 3.   z 1, z 2, z 3  can be determined by using the co-ordinate-transformation  z i = L

    i−1f    h(x).

    The remaining part is described by the zero dynamics, which has to bestable to apply the control. In section 3.6 we have investigated the stabilityof the zero dynamics and have found that is stable.

    After input-output linearization (IOL) we can apply any kind of the linearcontrollers, for example a pole-placement control (PP) for  v(t) as the newinput, with the correction of the reference signal   r(t) as described in [17].The signal flow diagram of the pole-placement servo controller applied tothe input-output linearized system is depicted in figure 30 . If we choosethe poles to   P 1,2,3   =   −50, we get the the result   K   = [125000 7500 150],Nx = [1;0; 0], Nu = 0.

    56

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    58/82

    If we use poles with lower magnitude, the reference following will be less

    accurate (more delay appears), and if we use greater ones, the actuationsignal will be larger. This contradicts to the control requirements describedin section 2.3.4 (the value of the actuation signal can be only in the range of [0, 1]).

    Figure 30: Input-output linearization and pole placement control withreference signal

    57

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    59/82

    4.4.1 Simulation results of the IOL-PP controller without distur-

    bance

    If we apply the control solutions described above, we get the following results:

    0 0.5 1 1.5 2 2.51.35

    1.4

    1.45

    1.5

    1.55

    1.6

    1.65

    1.7

    1.75

    1.8alfa,reference signal

    t [s]

      a   l   f  a ,  r  e   f  s .

    alfareference signal

    Figure 31:   α  and the reference signal by input-output linearization controlwith pole-placement

    0 0.5 1 1.5 2 2.50

    0.02

    0.04

    0.06

    0.08

    0.1

    0.12

    0.14

    q1,q

    2

    t [s]

      q   1 ,  q   2

    q1

    q2

    0 0.5 1 1.5 2 2.50.05

    0.055

    0.06

    0.065

    0.07

    0.075

    0.08

    u1

    t [s]

      u   1

    Figure 32: Muscle activation states, and activation signals

    58

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    60/82

    4.4.2 Trajectory following results of the IOL-PP controller with

    disturbance

    If we use the same disturbances as in section 4.3.2 and the same referencesignal with the poles P 1,2,3 =  −50 we get the following results:

    Figure 33:   α  and the reference signal by input-output linearization control

    with pole-placement

    0 0.5 1 1.5 2 2.50

    0.02

    0.04

    0.06

    0.08

    0.1

    0.12

    0.14

    q1,q

    2

    t [s]

      q   1 ,  q   2

    q1

    q2

    0 0.5 1 1.5 2 2.50.05

    0.055

    0.06

    0.065

    0.07

    0.075

    0.08

    u1

    t [s]

      u   1

    Figure 34: Muscle activation states, and activation signals

    59

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    61/82

    4.4.3 Regulation results of the IOL-PP controller with distur-

    bance

    We use the same functions for d1(t) and d2(t) as described in subsection 4.3.3,and set the poles to  P 1,2,3  =  −50. The results can be seen on the followingtwo figures:

    0 0.5 1 1.5 2 2.5

    1.6

    1.7

    1.8

    1.9alfa,reference signal

    t [s]

       a   l   f   a ,   r

       e   f   s .

    alfareference signal

    Figure 35:   α  and the reference signal by input-output linearization control

    and pole-placement

    0 0.5 1 1.5 2 2.50

    0.05

    0.1

    0.15

    0.2

    0.25

    0.3

    0.35

    0.4

    0.45

    q1,q

    2

    t [s]

      q   1 ,  q   2

    q1

    q2

    0 0.5 1 1.5 2 2.50

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    1

    u1

    t [s]

      u   1

    Figure 36: Muscle activation states, and activation signals

    The activation of the extensor muscle originates only from the used dis-turbance.

    60

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    62/82

    4.5 Fuzzy Inference System

    Soft-computing methods are also quite prevalent for controlling nonlinear sys-tems [16], because of the application of these methods do not need the explicitknowledge of mathematical model of the system. We study the acceptabil-ity of a simple Fuzzy-controller for the model, with rules and membershipfunctions designed in intuitive and experimental ways.

    4.5.1 Basic concepts in fuzzy theory

    At first, we define the basic concepts used in the theory of fuzzy systems,and fuzzy control.

    Fuzzy set:The fuzzy set A  defines on a set  X  the degree of belonging to A  for the ele-

    ments x  ∈  X .   A can be defined with the pair (X, µA), where µA  :  X  → [0, 1]is the membership function of  A.

    The main difference between the fuzzy and the ’conventional’ set theory isthe continual membership function. In ’conventional’ set theory an elementis either member of the set, or it is not. In fuzzy set theory for example avalue of a temperature-variable can be the member of the  warm  set with 0.5

    degree.

    Operations on fuzzy sets:In our case we use the following operations:

    •   Union:   µA∪B(x) = max (µA(x), µB(x))

    •   Intersection:   µA∩B(x) = min (µA(x), µB(x))

    •   Complement:   µA  = 1 − µA(x)

    Direct product of fuzzy sets:Let A1  be a fuzzy set on the set  X i  with the membership function µAi(xi),

    Ai   = (X i, µAi),   i  = 1, 2..., n. The membership function of the fuzzy directproduct A1 × A2 × ... × An   is defined by

    µA1×A2×...×An(x1, x2,...,xn) = µA1(x1) ∧ µA2(x2) ∧ ... ∧ µAn(xn)

    where  ∧ is a suitable T-norm, for example  min (see more in [16]).

    61

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    63/82

    Fuzzy relation:

    µR : X 1 × X 2 × ... × X n −→ [0, 1]

    R   fuzzy relation  ↔  (X 1 × X 2 × ... × X n, µR)

    where   µR(x1, x2,...,xn) defines the possibility of the elements   x1, x2,...,xnbeing in relation  R.

    Cylindrical extension:

    If the fuzzy relation R is defined on X i1×...×X ir  where (i1,...,ir) ⊂  1,...,n,then the  cylindrical extension  of R to the set  X 1 × ... × X n   is

    µce(R)(x1,...,xn)  .= µR(xi1,...,xir)

    Projection:If  R is a fuzzy relation defined on X 1×...×X n, the projection of the relation

    R to the space X i1 ×...×X ir  is a relation P   = P rojX i1×...×X ir , which relation’smembership function is with the notation { j1,...,jn−r} =  {1,...,n}/{i1,...,ir}

    µP (xi1 ,...,xir)  .= sup

    xj1,...,xj

    n−r

    µR(x1,...,xn)

    Fuzzy composition:Let it be

    X 1 × ... × X m−1 × X m−1 × ... × X r  the set of the fuzzy relation RX m × ... × X r × X r+1 × ... × X n  the set of the fuzzy relation SX 1 × ... × X m−1 × X r+1 × ... × X n  the set of the fuzzy relation  R ◦ S 

    We get the   fuzzy composition   with cylindrical extending (ce) both of therelations to the   X 1  × ...  ×  X n   product-space, take the intersection of therelations, and project the result to the  X 1 ×  ... × X m−1  × X r+1 × ...  × X nproduct-space.

    R ◦ S  = P rojX 1×...×X m−1×X r+1×...×X n[ce(R) ∩ ce(S )]

    µR◦S (x1,...,xm−1, xr,...,xn) = supxm,...,xr(µR(x1,...,xr) ∧ µS (xm,...,xn))

    Fuzzy composition is important in fuzzy controller design, becouse (as wewill later see) this method is the connection between the rules of a controller,and the input data.

    62

  • 8/17/2019 Daedalus.scl.Sztaki.hu Diploma Csercsik David

    64/82

    Fuzzy rule base:

    We use Mamdani-implication:   a →  b  ≈  a · b

    Implication:   R: If   x   is   A, then   y   is   B.   Ri   =   A   −→   B   is a relation overX  × Y .

    We have to note that this method is not compatible with the Bool-algebra,but it can be easily computed, and it is used in the most case in the practice.

    The projection of the relation   R   =   A  −→   B   to the   Y   fuzzy set gives thecomposition rule of the fuzzy implication:

    ProjY  (R) = P rojY  (A −→ B) = A ◦ B

    where  ◦  is the fuzzy composition.

    The general form of the fuzzy implication can be described with the R1, R2,...,Rnrelations (R =  ∪Ri) of the rule-base.

    Ri :   if x1   is X i1   and ... and xn   is X 

    in   then y is Y 

    i

    In the case of fuzzy control, the  R  =  ∪Ri  rule base (the summation of the

    if...then...   implications) from the linguistical statements of the professionalknowledge.

    Matching data to a relation:Let  x∗ j  the measured value of the variable  x j. Let  x

     j   match the  A j   fuzzyset. In the case of  Ri, let the fuzzy set  A j  be defined on the set  X 

    i j.

    In this case

    The cylindrical extended values of the input data:

    D =  ce(A1) ∪ ... ∪ ce(An),  µD(x1,...,xn, y) = µA1(x1) ∧ ... ∧ µAn(xn)

    The fuzzy form of the  Ri  Mamdani implication (as a relation):

    Ri  =  ce(X i1) ∪ ... ∪ ce(X