UNIVERSIDADE ESTADUAL DE CAMPINAS Faculdade de Engenharia El´etrica e de Computa¸c˜ao
Lucas Silva de Oliveira
Granular Feedback Linearization: An Approach using Participatory Learning
Realimenta¸c˜aoGranular Linearizante - Uma Abordagem por Aprendizagem Participativa
Campinas 2019 Lucas Silva de Oliveira
Granular Feedback Linearization: An Approach using Participatory Learning
Realimenta¸c˜aoGranular Linearizante - Uma Abordagem por Aprendizagem Participativa
Thesis submitted to the School of Electrical and Computer Engineering of the University of Campinas of the requirements for the de- gree of Doctor in Electrical Engineering, in the area of Automation.
Tese apresentada `aFaculdade de Engenharia El´etrica e da Computa¸c˜aoda Universidade Estadual de Campinas como parte dos req- uisitos exigidos para a obten¸c˜aodo t´ıtulo de Doutor em Engenharia El´etrica, na ´area de Automa¸c˜ao.
Supervisor/Orientador: Prof. Dr. Fernando Antˆonio Campos Gomide Co-supervisor/Coorientador: Prof. Dr. Valter J´unior de Souza Leite
Este exemplar corresponde `avers˜ao final da tese defendida pelo aluno Lucas Silva de Oliveira, e orientada pelo Prof. Dr. Fernando Antˆonio Campos Gomide.
Campinas 2019 Ficha catalográfica Universidade Estadual de Campinas Biblioteca da Área de Engenharia e Arquitetura Luciana Pietrosanto Milla - CRB 8/8129
Oliveira, Lucas Silva de, 1982- OL4g OliGranular feedback linearization : an approach using participatory learning / Lucas Silva de Oliveira. – Campinas, SP : [s.n.], 2019.
OliOrientador: Fernando Antônio Campos Gomide. OliCoorientador: Valter Júnior de Souza Leite. OliTese (doutorado) – Universidade Estadual de Campinas, Faculdade de Engenharia Elétrica e de Computação.
Oli1. Sistemas de controle por realimentação. 2. Controle robusto. 3. Sistemas de controle ajustável. 4. Sistemas de controle inteligente. 5. Algoritmos fuzzy. I. Gomide, Fernando Antônio Campos, 1951-. II. Leite, Valter Júnior de Souza. III. Universidade Estadual de Campinas. Faculdade de Engenharia Elétrica e de Computação. IV. Título.
Informações para Biblioteca Digital
Título em outro idioma: Realimentação granular linearizante : uma abordagem por aprendizagem participativa Palavras-chave em inglês: Feedback control systems Robust control Adaptive control systems Intelligent control systems Fuzzy algorithms Área de concentração: Automação Titulação: Doutor em Engenharia Elétrica Banca examinadora: Fernando Antônio Campos Gomide [Orientador] Adrião Duarte Dória Neto Cairo Lúcio Nascimento Júnior Matheus Souza Ricardo Coração de Leão Fontoura de Oliveira Data de defesa: 14-11-2019 Programa de Pós-Graduação: Engenharia Elétrica
Identificação e informações acadêmicas do(a) aluno(a) - ORCID do autor: https://orcid.org/0000-0002-0322-8276 - Currículo Lattes do autor: http://lattes.cnpq.br/1841799475396072
Powered by TCPDF (www.tcpdf.org) COMISSAO˜ JULGADORA - TESE DE DOUTORADO
Candidato: Lucas Silva de Oliveira RA:163693 Data da Defesa: 14 de novembro de 2019 T´ıtulo da Tese: “Granular Feedback Linearization: An Approach using Participatory Learning”
Prof. Dr. Fernando Antˆonio Campos Gomide Prof. Dr. Adri˜aoDuarte D´oria Neto Prof. Dr. Cairo L´ucio Nascimento J´unior Prof. Dr. Matheus Souza Prof. Dr. Ricardo Cora¸c˜aode Le˜aoFontoura de Oliveira
A ata de defesa, com as respectivas assinaturas dos membros da Comiss˜ao Julgadora, encontra-se no SIGA (Sistema de Fluxo de Disserta¸c˜ao/Tese) e na Secretaria de P´os- Gradua¸c˜ao da Faculdade de Engenharia El´etrica e de Computa¸c˜ao. Acknowledgements
Firstly, I would like to express my sincere gratitude to my advisor Professor Fer- nando Gomide for the continuous support of my Ph.D. study and related research, for his patience, motivation, complete trust and immense knowledge. I am also greatly fortunate to have the Professor Valter Leite as my co-supervisor. Apart from providing me with numerous research feedbacks, he has been a constant source of support and stimulation in the last years. I could not have imagined having better mentors for my Ph.D. study. I would like to thank the thesis committee members, Prof. Dr. Adri˜ao Duarte, Prof. Dr. Cairo Nascimento, Prof. Dr. Daniel Leite, Prof. Dr. Eric Rohmer, Prof. Dr. Matheus Souza, Prof. Dr. Ricardo Oliveira, and Profa. Dra. Rosangela Balini for their availability to evaluate and this work. I would like to acknowledge the University of Campinas and the Federal Center for Technological Education of Minas Gerais by the structure, opportunity, and for the finan- cial support. My sincere thanks also go to the teaching staff, in particular, the professors Eric Rohmer, Fabiano Fruett, and Lucas Gabrielli, who provided me an opportunity to adventure by news paths and experiences. I would like to take this opportunity to express immense gratitude to all those persons who have given their invaluable support and assistance. In special, I would like to thank my fellow labmates: Filipe Pedrosa, Jeferson Silva, Lino Filho, T´abitha Esteves, and Tisciane Perp´etuo, for the sleepless nights we were working together before the final test, and for all the fun we have had in the last three years. My gratitude extends to Anderson Bento, Ariany Oliveira, Ign´acio Scola, Luis Filipe, Michelle Castro and Wagner Cust´odio fellows from our Systems and Signals Laboratory group at CEFET/MG. Also, I thank my friends from the dance group Proibido Cochilar. In particular, I am grateful to Aline Ferreira, Bruna Zielinski, Fernanda Brito, Ricardo Zambon, Tha´ıssa Engel, and Wenderson Rocha for each new dance choreography and fun moments. Finally, I would like to acknowledge with gratitude, the support, and love of my family - my parents, Jos´eFrancisco and Maria da Concei¸c˜ao; my sister’s family, Cynthia, Jo˜ao Miguel and Warley and my girlfriend, Marcela. Also, I would like to thank my uncle’s family, Ana Maria, Alo´ısio, Aninha, and M´arcio for the words of encouragement. They all kept me going, and this thesis would not have been possible without them. Abstract
Feedback linearization is a powerful control method based on the exact cancellation of non- linearities of nonlinear systems. Real world systems are complex, nonlinear, time-variant, and the system models are subject to uncertainties caused by neglected dynamics and im- precise parameter values. Differences between actual systems and their models preclude exact cancellation, what induce unexpected behavior of feedback linearization closed-loop control such as offset error, limit cycle, and instability. This thesis develops a granu- lar feedback linearization control approach using participatory learning, a novel adaptive control approach whose aim is to improve robustness and adaptiveness of feedback lin- earization control. The approach uses evolving participatory learning and concepts of the granular computing to estimate modeling errors, and employes the error information to mitigate its effects in the feedback control loop. Three distinct approaches are developed: the first assumes that a model subject to additive uncertainties is available. The evolving participatory learning algorithm produces estimates of the additive disturbances needed to cancel the nonlinearities. The second approach does not require a model for the system at all. The control input is computed using evolving participatory learning to estimate the system nonlinearities directly. Inspired in the certainty equivalence principle, the esti- mates replace the true values of the nonliearities in the ideal, exact feedback linearization control law. The third approach uses a high-gain state observer in the feedback lineariza- tion control loop. The participatory learning algorithm uses estimated values of the state instead of the true ones to cancel the nonlinearities of the system. Local Lyapunov sta- bility analysis of the feedback linearization control system is studied. The performance of the approaches are evaluated using the level control of a surge tank, the angular position control of a fan and plate system, knee joint control using functional electric stimula- tion, and a DC motor driven rigid arm. Numerical and experimental results indicate that the granular feedback linearization with participatory learning significantly increases the robustness and adaptability of feedback linearization control.
Keywords: Feedback control systems; Robust control; Adaptive control systems; Intelli- gent control systems; Fuzzy algorithms. Resumo
A lineariza¸c˜ao de sistemas n˜aolineares por realimenta¸c˜ao baseia-se no princ´ıpio do cance- lamento exato das n˜ao linearidades presentes na dinˆamica do sistema. Em geral, sistemas reais s˜aocomplexos e seus modelos est˜aosujeitos a dinˆamicas negligenciadas na modela- gem, a incertezas nos parˆametros e a parˆametros variantes no tempo. Por essas raz˜oes, a lineariza¸c˜aopor realimenta¸c˜ao exata pode apresentar comportamento e desempenho indesej´aveis tais como, erro em regime permanente, comportamento c´ıclico, ou instabili- dade. A realimenta¸c˜ao granular linearizante com aprendizagem participativa ´euma nova abordagem de controle adaptativo baseado na aprendizagem participativa. Esta aborda- gem agrega robustez e adapta¸c˜ao `amalha de controle da lineariza¸c˜aopor realimenta¸c˜ao. A abordagem proposta usa o algoritmo de aprendizagem participativa e conceitos da computa¸c˜ao granular para estimar o erro de modelagem e mitigar seus efeitos em malha fechada. S˜ao investigadas trˆes topologias de controle distintas: a primeira assume que um modelo nominal do sistema ´econhecido e admitindo, por´em, incertezas param´etricas e dinˆamica negligenciada durante o processo de modelagem. A segunda topologia usa a t´ecnica da lineariza¸c˜aopor realimenta¸c˜ao, por´emsem conhecimento pr´evio do modelo do sistema a ser linearizado. Neste caso, o algoritmo de aprendizagem participativa ´eo ´unico respons´avel por determinar a lei de controle linearizante. A terceira topologia ´eum esquema de controle em que um estimador de estados de alto ganho ´eassociado `amalha de lineariza¸c˜aopor realimenta¸c˜ao. Neste caso, os estados estimados s˜aoutilizados durante a granulariza¸c˜aodo espa¸code estado e pelo algoritmo de aprendizagem participativa. E´ feita uma an´alise de estabilidade local da abordagem. O desempenho de cada uma das topologias de controle s˜ao avaliadas no controle do n´ıvel de tanque, controle da posi¸c˜ao angular de um bra¸corob´otico, da posi¸c˜ao angular de uma placa acionada por fluxo de ar, e controle de rota¸c˜aoangular da junta do joelho via estimula¸c˜ao funcional el´etrica. Simula¸c˜aoe verifica¸c˜aoexperimental de alguns dos processos estudados fazem parte da avalia¸c˜aode desempenho. Os resultados indicam que a realimenta¸c˜aogranular linearizante com aprendizagem participativa aumenta significativamente a robustez e adaptabilidade da lineariza¸c˜ao por realimenta¸c˜ao.
Palavras-chaves: Sistemas de controle por realimenta¸c˜ao; Controle robusto; Sistemas de controle ajust´avel; Sistemas de controle inteligente; Algoritmos fuzzy. List of Figures
Figure 2.1 – Tracking in feedback linearization ...... 25 Figure 2.2 – Granulation-degranulation...... 26 Figure 2.3 – Open-loop state observer...... 32 Figure 2.4 – Luenberger observer...... 33 Figure 3.1 – Robust granular feedback linearization — RGFL...... 37 Figure3.2–Surgetank...... 41 Figure 3.3 – RGFL tracking a square waveform reference trajectory...... 43 Figure 3.4 – RGFL tracking a sawtooth waveform reference trajectory...... 44 Figure 3.5 – RGFL tracking a triangular waveform reference trajectory...... 45 Figure 3.6 – Actual surge tank system...... 46 Figure 3.7 – Nonlinearity in the actual surge tank ...... 46 Figure 3.8 – Nominal surge tank behavior ...... 47 Figure 3.9 – Uncertain surge tank behavior ...... 48 Figure 3.10–Lower limb modelling using FES ...... 49 Figure 3.11–Maximal values to the bounded attraction region ...... 52 Figure 3.12–Knee joint behavior and performance ...... 53 Figure 3.13–Clustering process through knee joint experiment ...... 54 Figure 3.14–Inverted Pendulum...... 56 Figure 3.15–RGFL using eTS algorithm with 휎 = 0.3 ...... 57 Figure 3.16–Performance indexes of RGFL controller with eTS algorithm ...... 59 Figure 4.1 – ReGFL control...... 63 Figure 4.2 – ReGFL tracking a square waveform reference ...... 66 Figure 4.3 – ReGFL tracking a sawtooth waveform reference ...... 67 Figure 4.4 – ReGFL tracking a triangular waveform reference ...... 67 Figure 5.1 – RegHGO control...... 72 Figure 5.2 – Fan and plate system...... 73 Figure 5.3 – Behavior of the fan and plate system with RegHGO controller . . . . . 74 Figure 5.4 – Tracking and observer error of the RegHGO controller ...... 75 Figure 5.5 – Performance indexes of the RegHGO controller ...... 75 Figure 5.6 – Behavior of the rigid arm in continous work...... 78 Figure 5.7 – Behavior of the rigid arm in a batch process...... 79 List of Tables
Table 3.1 – Performance indexes of the controllers methods...... 45 Table 3.2 – Performance indexes for the actual surge tank experiments...... 48 Table 3.3 – Min and Max Values to normalize the ePL algorithm input...... 53 Table 3.4 – Performance indexes of the controllers...... 54 Table 3.5 – Tunig conditions of the eTS algorithm...... 55 Table 3.6 – Performance of the RGFL controller with eTS modeling...... 58 Table 4.1 – Performance indexes of the controllers...... 66 Table 5.1 – Constants and parameters values to the rigid arm simulation...... 77 Table 5.2 – Performance indexes of the controllers methods...... 78 List of abbreviations and acronyms
ARX Autoregressive models with exogenous variables
BFOF Bacterial foraging fuzzy tecnique
DC Direct current
EFL Exact feedback linearization
EFLHGO Extended high-gain observer associated with the linearizing feedback ePL Evolving participatory learning algorithm eTS Evonving Takagi-Sugeno algorithm
FES Functional electrical stimulation
FL Feedback linearization
FLHGO Input-output feedback linearization with high-gain observer
HGO High-gain observer
IAE Integral absolute error
ITAE Integral of time-weighted absolute error
IVE Integral of time-weighted variability of the error
IVU Integral of time-weighted variability of the signal control
LMI Linear matrix inequality
LQR Linear quadratic regulator
PLC Programmable logic controller
RGFL Robust granular feedback linearization
ReGFL Robust evolving granular feedback linearization
RegHGO ReGFL with high-gain observer
RLS Recursive least square algorithm
RMI Robust multi-inversion
RMSE Root mean square error SISO Single-input single-output
TS Takagi-Sugeno Contents
1 Introduction ...... 14 1.1 Background ...... 15 1.2 Objective ...... 18 1.3 Contributions and Publications ...... 18 1.4 Organization ...... 20 2 Methodological Background ...... 22 2.1 Exact Feedback Linearization ...... 22 2.1.1 Reference Tracking ...... 23 2.2 GranularComputing ...... 25 2.2.1 Evolving Takagi-Sugeno Models ...... 27 2.2.2 Evolving Participatory Learning ...... 29 2.3 State Observers ...... 31 2.4 Summary ...... 34 3 Robust Granular Feedback Linearization ...... 35 3.1 Robust Granular Controller ...... 35 3.2 Lyapunov Stability Analysis ...... 38 3.3 Performance Evaluation ...... 41 3.3.1 Surge Tank Simulation Experiments ...... 41 3.3.2 Actual Surge Tank Experiments ...... 44 3.3.3 Knee Joint Simulation Experiments ...... 49 3.3.4 Evaluation of RGFL Control with Evolving Takagi-Sugeno Modeling 54 3.4 Summary ...... 58 4 Robust Evolving Granular Feedback Linearization ...... 60 4.1 Introduction...... 60 4.2 Input-Output Linearization Idea ...... 61 4.3 Robust Evolving Granular Feedback Control with Input-Output Linearization 62 4.4 Performance Evaluation ...... 65 4.5 Summary ...... 68 5 Robust Evolving Granular Feedback Linearization with Observers ...... 69 5.1 Introduction...... 69 5.2 Robust Feedback linearization Control with Observers ...... 70 5.3 Performance Evaluation ...... 72 5.3.1 Fan and Plate System ...... 72 5.3.2 Rigid Arm Driven by DC Motor ...... 75 5.4 Summary ...... 79 6 Conclusion ...... 81 References ...... 83 A Appendix: S-Procedure ...... 91 14 1 Introduction
Nowadays, we deal with an increasing number of automated and intelligent pro- cesses and systems. Self-driving technology, intelligent houses, autonomous robotics and transportation systems, airplanes, trains, electric vehicles, smart agriculture, data-driven process control are examples of systems in which machines are augmented with connectiv- ity, sensors, and intelligence to improve decision making and control. In intelligent process control, modeling is a key to capture system dynamics, and to design control laws that ful- fill closed-loop performance and feasibility requirements. Particularly crucial in intelligent control areas are continuous adaptation and robust behavior once these features are es- sential to counteract for the effects of uncertainty and imprecision in system performance and closed-loop stability. Control theory is addressed in the literature from distinct points of view. An es- sential aspect of being considered is the nature of models used to describe a process. For instance, the process can be modeled using differential equations, rule-based approaches, graphical models, and neural networks, to mention but a few. Differential equations are particularly useful to model continuous processes. This thesis focuses on continuous non- linear processes and models. A nonlinear model-based control system design task is com- plicated, especially when adaptation and robustness are demanded. Intelligent and learning approaches are mean to improve the adaptability and ro- bustness of closed-loop control of nonlinear systems. These approaches render frameworks for online data processing using unique methods and algorithms to extract knowledge from data streams. Online data stream-based modeling essentially is a computational learning approach that simultaneously processes input data and extracts knowledge that governs the process behavior. This thesis focuses on evolving participatory learning for stream database modeling in the framework of granular computing. Participatory learning is a paradigm for computational learning systems whose basic premise is that learning takes place in an environment where learning itself depends on what has already been learned and believed so far. This fact means that every aspect of the learning process is affected by the compatibility between knowledge learning with the current input data. Granular computing means that the data space is organized in clusters and that each cluster has a local model in the form of a fuzzy functional rule. The collection of the fuzzy functional rules composes the model of the process. In particular, fuzzy functional rules with affine consequents are adopted, and the model output is found as a weighted average of the local models. This thesis develops a novel control approach within the framework of feedback linearization using granular evolving participatory learning. The primary research issue Chapter 1. Introduction 15 addressed is the use of granular participatory learning to model the imprecision of process models to mitigate its effects in the closed-loop system behavior. Lyapunov stability anal- ysis of the control approach is pursued to verify the closed-loop behavior of the control loop.
1.1 Background
Control systems have been used for more than 2000 years. Some of the earliest examples are water clocks described by Vitruvius and attributed to Ktesibios 270 B.C. (Bennett, 1996). During the development and continuous progress of society, new indus- trial processes, operation mechanisms, and machines have been created. Novel conceptual approaches, sound mathematical tools, and problems with new demands have been ob- served. The 18th century is recognized as the beginning of the Control Theory (Villa¸ca and Silveira, 2013). Remarkable results were obtained through these years, notably J. C. Maxwell, in 1868, and the analysis of the stability of Watt’s flyball governor (Denny, 2002). Maxwell’s technique was based on the linearization of the differential equations of motion to find a characteristic equation for the system. He studied the effect of the system parameters on stability and showed that the system is stable if the roots of the characteristic equation have negative real parts (Leine, 2009). Another example is the term “automatic feedback control”, which is considered a recent conception, but has be- come common-sense in the area of control theory and applications. Feedback control was used for the first time by Norbert Wiener and his colleagues in 1940’s (Mayr, 1970). A few years later, the Lyapunov stability theory was introduced as a methodology to study and analyze the stability of feedback control systems (Leine, 2009; Lyapunov, 1992). Modern control theory is associated with many other areas such as modeling, op- timization, artificial intelligence, and more recently, with machine learning. Traditionally, control systems are designed using a model to describe the controlled process dynamics. From the availability of many modeling approaches as a rule-based, graph, first-order logic, state machines, and formal languages, the design of closed-loop control systems for continuous process relies on the knowledge of differential equations. In this way, if the dynamics of the system are known precisely, then a white-box model is obtained. If the system is highly complex, a black-box model can be adopted. Black-box modeling uses an input signal to excite the process and to collect process output data to record the dynam- ics and develop a model from the input-output data. Gray-box modeling combines white and black-box modeling. In computer control applications, a discrete-time equivalent of the continuous process may be required as well. Often, the dynamics of actual physical processes are complex and imprecise, as mirrored by the dynamics of populations, climatic models, robotics systems, and turbulent Chapter 1. Introduction 16
fluid flows (Sastry, 1999). Complex dynamics can be approximated reasonably well by nonlinear models. Different from the linear models, nonlinear models are more abundant in the sense that many commonly observed phenomena, such as multiple operating points, limit cycles, bifurcations, and frequency entrainment (Khalil, 2002; Isidori, 1995) can be captured in their formulation. In this thesis, we are concerned with continuous nonlinear processes and systems. The literature addresses a significant number of nonlinear control techniques, but our attention here is on feedback linearization. Exact feedback linearization – EFL is a nonlinear control technique (Khalil, 2002; Isidori, 1995; Slotine and Li, 1991) whose purpose is to exactly cancel the nonlinearities of a nonlinear system or process. To come up with an equivalent linear system to which linear control laws and design tools can be employed. Exact nonlinearity cancellation makes EFL fragile whenever there are mismatches between the model used in design and the actual process. Mismatches are encountered whenever there are structural variability, parametric imprecision, or both (Sastry, 1999). In practice, EFL is prone to fail because the actual plant behavior and the nonlinear model used in the EFL control law design differ (Esfandiari and Khalil, 1992; Oliveira et al., 2017). Currently, we witness a myriad of works in the control systems literature addressing strategies to ensure the robustness of closed-loop feedback linearized systems. For instance, Wang (1996) develops indirect adaptive fuzzy controllers based on fuzzy IF-THEN rules to estimate and compute online the tracking control input. Alternatively, Guillard and Boul`es (2000) discusses an input/output feedback linearization approach to improve robustness during the design of the linearized control law. While Park et al. (2003) derives a robust indirect adaptive fuzzy controller mechanism using approximate bounds of reconstruction errors, Lavergne et al. (2005) introduces the robust-multi inversion – RMI scheme adding a compensation loop in the linearization feedback loop to mitigate modeling errors effects. Exact feedback is explored by Soares et al. (2011) in trajectory tracking control of a mobile robot whose controller gains are found via linear matrix inequalities – LMIs. Biomimicry of social bacterial foraging approach to developing an indirect adaptive controller is located in (Banerjee et al., 2011), whereas a compensation loop based upon the RMI approach is pursued in (Oliveira et al., 2015) using differential evolution (Chakraborty, 2008, Chap. 1) to find the controller gains. A scheme based on model reference adaptive control – MRAC and the evolving fuzzy participatory learning algorithm – ePL (Pedrycz and Gomide, 2007) appears in (Oliveira et al., 2017). Most current robust and adaptive control methods assume that all state variables are available for measurement, which often is not the case (Khalil, 2002, pp. 610). Sev- eral processes have their states inaccessible due to physical restrictions or high costs of sensors. An alternative in these cases is to use state observers, provided that the process is observable (Ciccarella et al., 1993). The observer is a mathematical model that uses measurements of the process output and the control input to estimate the values of the Chapter 1. Introduction 17 state variables. Observers result in a set of sequential signals that are less susceptible to noise and disturbances than the real output measurements (Ellis, 2002). An example is the Luenberger observer for state estimation of linear systems (Chen, 2013). Linear ob- servers compare the actual process output with the one produced by the model to yield an observer error. The design of the observer allows tuning a linear gain to ensure the exponential decay of the observer error to zero. Krener and Respondek (1985) have shown that, for a specific class of nonlinear systems, the Luenberger observer can be used to estimate the state of a linearizable system whenever the model of the nonlinear system is in the canonical form, that is, the model has a representation in the form of a chain of integrators. Khalil (2002, pp. 610) suggested the use of the high-gain observer – HGO with the feedback-linearized systems. The HGO has the same structure as the Luenberger observer but differs from it in the tuning procedure. If the nonlinear system model is locally Lipschitz, then the HGO observer lessens of the effect of uncertainties (Khalil, 2017a). HGO has been used in nonlinear system control by many authors (Farza et al., 2011; Freidovich and Khalil, 2006; Khalil, 2017a). In (Freidovich and Khalil, 2006; Khalil, 2017a), an extended HGO is used to guarantee the convergence of the system to a reference signal. Such a useful characteristic comes from the use of an additional state correspond- ing to the tracking error integrator. Alternatively, Chaji and Sani (2015) uses a high-gain observer with an input-output feedback linearization scheme to control the linear position of an electrical-hydraulic servo. Guermouche et al. (2015) suggested a new control scheme that uses the high-gain observer associated with the super-twisting algorithm to control the angular position of a DC motor. Recently, in (Chen et al., 2016; Kayacan and Fos- sen, 2019) proposed the use of high-gain observers to estimate the unknown or feedback linearization mismatch error to cancel their effects in the control loop. This thesis aims at developing robust adaptive control approaches to address the fragility of feedback linearization due to modeling mismatches. It introduces the use of evolving participatory learning and granular modeling frameworks to capture the missing dynamics of the controlled processes from data streams. The idea is to estimate modeling imprecision in real-time to counteract for its effects in the feedback control loop. The approaches suggested herein are evaluated using benchmarks found in the literature such as the level control of a surge tank (Slotine and Li, 1991; Banerjee et al., 2011; Wang, 1996; Franco et al., 2016), the angular position control of a fan and plate system (Kungwalrut et al., 2011; Simas et al., 1998; Dincel et al., 2014), the knee joint control with functional electrical stimulation (Davoodi and Andrews, 1998; Kirsch et al., 2017; Li et al., 2017; Previdi and Carpanzano, 2003), and a DC motor-driven rigid arm control (Guermouche et al., 2015; Mor´an and Viera, 2017; Bento et al., 2018; Beltran-Carbajal et al., 2014; Freidovich and Khalil, 2006; Khalil, 2017a). The results suggest that closed-loop control with feedback linearization associated with evolving participatory learning is a powerful Chapter 1. Introduction 18 method to improve robustness and adaptability of feedback linearizable processes and systems.
1.2 Objective
The main objective of the thesis is to develop novel approaches to improve the robustness and adaptability of nonlinear control systems designed for feedback linearizable processes using evolving granular modeling. Several research questions arose during the development of the research. They are:
∙ how to develop adaptive control using participatory learning;
∙ how to estimate imprecision of models using rule-based granular models;
∙ how to define the data space and how to granulate the data space;
∙ how to evaluate and bound modeling errors in closed-loop;
∙ how to analyze the closed-loop stability;
∙ how to adapt the controller when the dynamics system is unknown;
∙ how to use state estimation when states are not available;
∙ how the evolving participatory learning compares with alternative procedures;
∙ what are the conditions to use the novel robust adaptive controller in actual plants.
1.3 Contributions and Publications
The contributions of this thesis can be summarized by three central control ap- proaches: robust granular feedback linearization, robust evolving granular feedback lin- earization, and robust evolving granular with high-gain observers for linearizable feedback systems. The robust granular feedback linearization – RGFL introduces a novel control approach that employs the evolving participatory learning – ePL algorithm to improve robustness and adaptability of closed-loop, linearizable feedback systems. A new frame- work is developed to map data space granules to the space of control inputs. Information granulation means clustering the data space online using data streams to build fuzzy func- tional rules using participatory learning. Each cluster of the data space is a granule, and to each granule, there is an associated fuzzy functional rule. Clusters induce the membership Chapter 1. Introduction 19 functions of the rule antecedents, and affine functions form the rule consequents. This approach assumes the availability of a precise model of the process and the state vari- able values. Modeling imprecision is modeled as deviations from known nominal process models. An analytical framework is developed to analyze the stability of the closed-loop system using Lyapunov theory. The RGFL controller is extended, assuming that no information about the dynam- ics system is available. Therefore, the data space and data granulation are modified, and a new feedback linearization law similar to the certainty equivalence principle is developed. A novel mechanism to update the consequent parameters of the affine consequent models of the fuzzy functional rules is developed. The result is the robust evolving granular feed- back linearization – ReGFL controller. The advantage of the ReGFL controller over the RGFL relies on the fact that ReGFL does not require the parameters for the closed-loop operation to be specified. The robust evolving granular with high-gain observers – RegHGO extends further the RGFL, assuming that the system states are unavailable for measurement, but that information about the dynamics system is available. In this case, the data space becomes a space of estimated states, and granulation is done using state estimates. The RegHGO controller is obtained by adding a high-gain observer in the control loop. The publications produced as a result of the research reported in this thesis are listed next. Book chapter L. Oliveira, A. Bento, V. Leite , F. Gomide (2019) “Robust Evolving Granular Feedback Linearization”. In: Kearfott R., Batyrshin I., Reformat M., Ceberio M., Kreinovich V. (eds) Fuzzy Techniques: Theory and Applications. IFSA/NAFIPS 2019. Advances in Intelligent Systems and Computing, vol 1000. Springer, Cham. Journals L. Oliveira, A. Bento, V. Leite and F. Gomide, “Evolving granular feedback lineariza- tion: Design, analysis, and applications”, Applied Soft Computing Journal(2019) 105927, https://doi.org/10.1016/j.asoc.2019.105927. L. Oliveira, A. Bento, V. Leite and F. Gomide, (2019) “Evolving granular control with high-gain observers for feedback linearizable nonlinear systems”, Evolving Systems, 2019. (Submitted). International conferences L. Oliveira, V. Leite, J. Silva and F. Gomide, (2017) “Granular evolving fuzzy robust feedback linearization”, Evolving and Adaptive Intelligent Systems (EAIS), Ljubljana, 2017, pp. 1 − 8, doi: 10.1109/EAIS.2017.7954821. Chapter 1. Introduction 20
L. Oliveira, A. Bento, V. Leite , F. Gomide (2019) “Robust Evolving Granular Feed- back Linearization”. International Fuzzy Systems Association World Congress and North American Fuzzy Information Processing Society (IFSA/NAFIPS), Lafayette, 2019, pp. 1 − 12. L. Oliveira, A. Bento, V. Leite and F. Gomide, (2019) “Robust Granular Feedback Lin- earization”. International Conference on Fuzzy Systems (FUZZ-IEEE), New Orleans, 2019, pp. 1 − 6. A. Bento, L. Oliveira, V. Leite, I. R´ubio Scola and F. Gomide, (2019) “High-gain ob- server based robust evolving granular feedback linearization”. XIV Brazilian Conference on Dynamics, Control and Applications, S˜ao Carlos, 2019, pp. 1 − 7. A. Bento, L. Oliveira, V. Leite, and F. Gomide, (2019) “Comparisons of robust methods on feedback linearization through experimental tests”. 21푠푡 IFAC World Congress, Berlin, 2020. (Submitted) National conferences L. S. Oliveira, V. J. S. Leite, J. C. Silva and F. A. C. Gomide, (2017) “Robustez em lineariza¸c˜ao por realimenta¸c˜aogranular evolutiva”, XIII Simp´osio Brasileiro de Automa¸c˜ao Inteligente (SBAI), Porto Alegre, 2017, pp. 1739 − 1746. J. Silva, L. Oliveira, F. Gomide and V. Leite, (2018) “Avalia¸c˜aoexperimental da lineariza- ¸c˜ao por realimenta¸c˜ao granular evolutiva”, Fifth Brazilian Conference on Fuzzy Systems (CBSF), Fortaleza, 2018, pp. 359 − 370. A. Bento, L. Oliveira, V. Leite and F. Gomide, (2019) “Lineariza¸c˜aopor realimenta¸c˜ao granular robusta com algoritmo evolutivo Takagi-Sugeno: An´alise e avalia¸c˜ao de desem- penho” XIV Simp´osio Brasileiro de Automa¸c˜ao Inteligente (SBAI), Ouro Preto, 2019, pp. 1 − 7.
1.4 Organization
This thesis is organized into five chapters, as follows.
∙ This chapter presents a general statement problem addressed in this thesis, its main objectives, a summary of its main contributions, and a list of the publications pro- duced during the period.
∙ Chapter 2 gives a review of the methods and techniques that are needed to proceed with the development of the approaches developed in this thesis. These include the notions of feedback linearization, granular computing focusing on the evolving Chapter 1. Introduction 21
Takagi-Sugeno – eTS modeling, the evolving participatory learning – ePL modeling, and the high-gain state observer.
∙ Chapter 3 introduces the robust granular feedback linearization – RGFL controller. Disturbances originated by parametric imprecision and neglected dynamics during the modeling process are considered. An additional control signal produced by the ePL algorithm is introduced in the feedback linearization closed-loop. A mathemat- ical framework for stability analysis is developed based on the Lyapunov theory. Simulation results concerning with the level control of a surge tank, and angular position of the knee joint show how the RGFL perform. An experimental test is also reported for the real-time level control of the surge tank. RGFL control approach is evaluated against the evolving Takagi-Sugeno – eTS alternative.
∙ Chapter 4 develops the robust evolving granular feedback linearization – ReGFL controller. The control problem is formulated using the notion of input-output feed- back linearization. An approach to the certainty equivalence principle is introduced. ReGFL assumes that the model of the controlled process is unknown, and excludes the feedback linearization control law. In this case, ePL produces the closed-loop control signal. The performance of the proposed approach is evaluated using the surge tank.
∙ Chapter 5 introduces the high-gain state observer in the ReGFL approach. ReGFL assumes that the system states are unavailable. Robust evolving granular feedback linearization with high-gain observer – RegHGO uses estimated states to build the data space. Regulation of a fan and plate system, tracking the problem of a DC motor-driven robotic arm, is used to evaluate the closed-loop performance of ReGFL.
∙ Chapter 6 concludes the thesis summarizing its contributions, and suggesting future research directions. 22 2 Methodological Background
This chapter reviews the methods and techniques used to develop the robust gran- ular feedback linearization control approach. It starts a brief review of exact feedback linearization and recalls the class of evolving fuzzy functional models called evolving Takagi-Sugeno, and the notion of evolving participatory learning and algorithms. A short review of state observers and state estimation is also given.
2.1 Exact Feedback Linearization
The complexity of contemporary industrial processes and systems in energy, air- craft, robots, communications, and transportation is expanding, and nonlinear design of closed-loop controllers (Khalil, 2002) became critical to enhance performance and ensure robust and smooth operation. Exact feedback linearization – EFL concerns a modern view of geometric nonlinear control theory. Feedback linearization began with attempts to extend the concepts of controllability and observability of linear control theory to the nonlinear case (Guardabassi and Savaresi, 2001). EFL is a nonlinear control technique (Khalil, 2002; Isidori, 1995; Slotine and Li, 1991) whose purpose is to exactly cancel the nonlinearities of a nonlinear system or process to come up with an equivalent linear system to which linear control laws and design tools can be used. Consider single-input single-output – SISO nonlinear systems of the form:
x˙ = 푓(x) + 푔(x)푢 푦 = ℎ(x) (2.1)
푇 [︁ ]︁ 푛 with x = 푥1 푥2 ··· 푥푛 ∈ D ⊆ R is the state vector, 푢 and 푦 are the input and output of the system, respectively, and ℎ(x):D → R is the output function, and 푓(x) and 푔(x) ∈ D ⊆ R푛 are nonlinear functions of the states. Assume that ℎ(x), 푓(x) and 푔(x) functions are smooth vector fields on R푛, where by smooth function we mean an infinitely differentiable function (Sastry, 1999, pp. 385). If the system (2.1) has certain structural properties, it allows us to cancel nonlinearities by means of a state feedback control law (Isidori, 1995; Khalil, 2002):
푟 ℒ푓 ℎ(x) 1 푢 = − 푟−1 + 푟−1 푣 (2.2) ℒ푔ℒ푓 ℎ(x) ℒ푔ℒ푓 ℎ(x) Chapter 2. Methodological Background 23 and a diffeomorphism ⎡ ⎤ ℎ(x) ⎢ ⎥ ⎢ ⎥ ⎢ ℒ푓 ℎ(x) ⎥ z = 푀(x) = ⎢ ⎥ (2.3) 푑 ⎢ . ⎥ ⎢ . ⎥ ⎣ ⎦ 푟−1 ℒ푓 ℎ(x) where 푟 is the relative degree of the system, 푣 is the external reference input, and ℒ푓 ℎ(x) = 휕ℎ(x) 1 휕푥 푓(x) is called the Lie Derivative of ℎ with respect to 푓 or along 푓 (Sastry, 1999). This notation is convenient when is necessary to repeat the calculation of a sequency of the derivative with respect to same vector or a new one (Khalil, 2002). For instance, we have: 휕 (ℒ ℎ(x)) ℒ ℒ ℎ(x) = 푓 푔(x) 푔 푓 휕푥 휕 (ℒ ℎ(x)) ℒ2 ℎ(x) = ℒ ℒ ℎ(x) = 푓 푓(x) 푓 푓 푓 휕푥 (︁ 푟−1 )︁ 휕 ℒ푓 ℎ(x) ℒ푟 ℎ(x) = ℒ ℒ푟−1ℎ(x) = 푓(x) 푓 푓 푓 휕푥 0 ℒ푓 ℎ(x) = ℎ(x)
In this way, pluging (2.2) in (2.1) and using the diffeomorphism (2.3) we obtain the closed loop system,
(푛) 푧푑 = 푣
푦 = 푧푑1 , (2.4) which is linear and controllable, whereas verifies that 푔(x) ̸= 0 ∀x ∈ D ⊆ R푛. Once the linear system was obtained, we can impose new feedback controls (Isidori, 1995), like for instance
푣 = Kz푑, (2.5) [︁ ]︁ with K = 푘1 푘2 ··· 푘푛 is chosen in order to adress a specific set of eigenvalues, in other words, where the closed loop system has all its roots stricly in the left-half complex plane, which leads to stable exponentially stable dynamics, i.e (Slotine and Li, 1991).
2.1.1 Reference Tracking
Without loss of generality, assume that the nonlinear system (2.1) has relative degree 푟 = 푛. Thus it can be rewritten as (Khalil, 2002, pp. 506):
x˙ = 퐴x + 퐵훾(x)[푢 − 훼(x)] 푦 = 퐶x (2.6)
1For more details see in (Yano, 2015). Chapter 2. Methodological Background 24 where 퐴 ∈ R푛×푛, 퐵 ∈ R푛×1, and 퐶 ∈ R1×푛 are the system matrices. Functions 훼(x) ∈: R푛 → R and 훾(x) ∈: R푛 → R with 훾−1(x) ̸= 0 ∀x ∈ D are nonlinear, and defined in a set D ⊂ R푛 that contains the origin. In this way, the nonlinear functions can be rewritten as: 푓(x) = 퐴푥 − 퐵훾(x)훼(x) and 푔(x) = 퐵훾(x). If the pair (퐴,퐵) is controlable, then the system (2.6) can be feedback linearizable, and there exists a diffeomorphism (2.3) that transforms the system in
z˙ 푑 = 퐴푐z푑 + 퐵푐훾(x)[푢 − 훼(x)]
푦 = 퐶푐z푑. (2.7)
푛×푛 푛×1 1×푛 where 퐴푐 ∈ R , 퐵푐 ∈ R and 퐶푐 ∈ R is a canonical form representation of a chain 푟 푟−1 ℒ푓 ℎ(x) of 푛 integrators, with 훾(x) = ℒ푔ℒ푓 ℎ(x) and 훼(x) = − 푟−1 (Khalil, 2002, pp. 516). ℒ푔ℒ푓 ℎ(x) To garantee that the output system tracks the reference signal 푟(푡), we assume that:
∙ 푟(푡) is continuous, bounded for all 푡 ≥ 0, and infinitely differentiable function. Therefore, it can be written as: [︁ ]︁푇 r(푡) = 푟 푟˙ ··· 푟(푛−1) ,
∙ all signals 푟, ··· , 푟푛 are available online.
In this case, we may define news variables: 푇 [︁ (푛−1)]︁ e = z푑(푡) − r(푡) = 푒 푒˙ ··· 푒 (2.8)
푛 where e ⊆ D푒 ∈ R is the error of reference for each state 푥푖 described in the coordinates system z by the diffeomorphism (2.3). Note that the tracking error vector is a subset of
D, that is, D푒 ⊆ D by translation of the reference from the domain of the origin system (2.7). Pluging (2.8) in (2.7) the error dynamics is described by:
(푛) ˙e = 퐴푐e + 퐵푐훾(x)[푢 − 훼(x)] − 퐵푐푟 (푡). (2.9)
Assuming that the control signal can be computed by (2.2), with 훽 = 훾−1(x), and considering 푣 = 푟(푛)(푡) − Ke in (2.9), the dynamics of the tracking error becomes:
˙e = (퐴푐 − 퐵푐K)e, (2.10) with,
⎡ ⎤ ⎡ ⎤ 0 1 0 0 ··· 0 0 ⎢ ⎥ ⎢ ⎥ ⎢ ⎥ ⎢ ⎥ ⎢0 0 1 0 ··· 0⎥ ⎢0⎥ ⎢ ⎥ ⎢ ⎥ ⎢ ...... ⎥ ⎢ .⎥ 퐴푐 = ⎢ ...... ⎥ and 퐵푐 = ⎢ .⎥. ⎢ ⎥ ⎢ ⎥ ⎢ ⎥ ⎢ ⎥ ⎢0 0 0 0 ··· 1⎥ ⎢0⎥ ⎣ ⎦ ⎣ ⎦ 0 0 ········· 0 1 where the closed-loop system (퐴푐 − 퐵푐K) is Hurwitz. Figure 2.1 shows the closed-loop system to EFL in the tracking reference. Chapter 2. Methodological Background 25
− e 푣 푢 x˙ = 퐴x + 퐵훾(x)[푢 − 훼(x)] 푦 r(t) 푟(푛)(푡) − Ke 훼(x) + 훽(x)푣 푦 = 퐶x + z푑 x
x
푀(x)
Figure 2.1 – Reference tracking in exact feedback linearization.
2.2 Granular Computing
In the last decade, information granulation has emerged as a powerful tool for data analysis and information processing, which is in line with the way humans process information. The perception arises by structuring our knowledge, attitudes, and acquired evidence in terms of information granules that offer abstractions of the complex world and phenomena. Being abstract constructs, information granules, and their processing referred to as granular computing, provide problem solvers with a conceptual and algo- rithmic framework to deal with several real-world problems (Pedrycz and Chen, 2011). Granular computing is a term commonly associated with the area of intelligent computing directly related to the pioneering studies by Zadeh (Pedrycz, 2013). The notion of gran- ulation comes up from the direct and immediate requirement to abstract and summarize information and data to support several processes of comprehension and decision-making (Pedrycz and Gomide, 2007). In this work, the notion of information and data granules is understood as clustering data and processing clustered data. The level of information granularity depends of the problem in which such granules are used (Bargiela and Pedrycz, 2003). Generally, in modeling and control system areas, the data space is assembled from input and output data. A collection of granules or clusters partitions the data space (Silva et al., 2013) and identifies a corresponding cluster structure. For instance, the level control of surge tanks can use the level measurement and the tracking error values as the input data space. We can cluster the data space and assign to each cluster granules with fuzzy values such as low, medium, high, and very high. Granules can consider temporal information of the input and outputs. A granular environment G can be abstracted as:
G =< x,풢,V > (2.11) where V = [v1, v2, ··· , v푐] is a family of reference information, vi = [푣1, 푣2, ··· , 푣푝], 풢 is formal framework of information granules, x = [푥1, 푥2, ··· , 푥푝] is the input data, and 푝 is the input space dimension. When dealing with numeric data, we are concerned with their representation in Chapter 2. Methodological Background 26 terms of a collection of information granules (Pedrycz, 2013). If granulation is formally done within the framework of fuzzy set theory, then we can describe this representation process as a way to express input data x in terms of the granules, and depict the result in a 푝 dimensional hypercube:
푝 푝 풢 : x ∈ R → v ∈ [0,1] . (2.12)
Furthermore, v is understood as a cluster center representing the cluster. When recon- struction from the region of information granules or clusters of x is necessary, degranula- tion 풢−1 will result in the opposite of the granulation operation:
−1 푝 푝 풢 : v ∈ [0,1] → x ∈ R . (2.13)
These steps specify maps between the data space and the cluster space. Figure 2.2 depicts the granulation and degranulation mechanism.
Space of information granules
V ⊆ [0, 1]푝 풢−1
퐺푟푎푛푢푙푎푡푖표푛 퐷푒푔푟푎푛푢푙푎푡푖표푛
x ∈ R푛 Data space
Figure 2.2 – Granulation-degranulation.
Note that the mappings enable to compare the capabilities of the cluster to reflect the structure of the original data. In this sense, we can check if the recovered data ^x differs from the original data x. In practice ^x = 풢−1 (풢(x)) with the granulation and degranulation described by 풢 and 풢−1, respectively. Clustering methods are used to identify groups of similar objects in multivariate data sets collected from fields such as marketing, biomedical, and geospatial. They are different types of clustering methods, including the partitioning methods (Hand, 2013), hierarchical clustering (Arabie et al., 1996), fuzzy clustering (Pedrycz and Gomide, 2007), density-based clustering (Sander et al., 1998), and model-based clustering (Fraley and Raftery, 2002). In this thesis, we focus on the fuzzy clustering method.
In fuzzy clustering, a way to granulate a data set X = [x1, x2, ··· , x푁 ] in 푐 clusters represented by fuzzy sets with membership functions 휇푖(x), and cluster centers v푖, 푖 = Chapter 2. Methodological Background 27
1, ··· , 푐, is to solve the optimization problem (Pedrycz, 2013):
푁 푐 ∑︁ ∑︁ 2 minimize 휇푖(x푗)‖x − v푖‖ 휇푖,v푖 푗=1 푖=1 (2.14) 푐 푁 ∑︁ ∑︁ subject to 휇푖(x) = 1 0 < 휇푖(x푗) < 푝 푖=1 푗=1
If ‖x − v푖‖ is the Euclidean distance, then granulation step means to compute cluster centers v푖 and membership functions 휇푖(x) as follows: 1 휇푖(x푗) = 2 , (2.15) ∑︀푐 (︁ ‖x푗 −v푖‖ )︁ 푝−1 푗=1 ‖x푗 −v푗 ‖
∑︀푁 푚 푗=1 휇푖(x푗) x푗 v푖 = ∑︀푁 , (2.16) 푗=1 휇푖(x푗) where 푙 is the number of data points. The degranulation phase aims to reconstruct the original input data x from 휇푖 and vi. Therefore we have (Pedrycz and Gomide, 2007):
∑︀푐 푖=1 휇푖(x푗)v푖 ^xj = ∑︀푐 . (2.17) 푖=1 휇푖(x푗
2.2.1 Evolving Takagi-Sugeno Models
Evolving Takagi-Sugeno – eTS was developed in (Angelov and Filev, 2004) in the early 00s. The eTS modeling uses an online clustering method with the ability to update and to create new clusters. The idea is to translate a cluster and its respective local model into fuzzy functional rules. The online nature makes eTS different from the classic Takagi-Sugeno – TS fuzzy modeling approach in which the fuzzy rules and rule base are developed for a data set and remain fixed afterwards (Lughofer, 2011). The eTS algorithm uses fuzzy functional rules of the form:
푇 푘 푘 푘 [︁ 푘]︁ R푖 : IF x is 풜 THEN 푦 = 훾푖 1 x 푖 푖 (2.18) 푖 = 1, ··· , 푐푘,
푘 푝 푘 where R푖 is the 푖-th fuzzy rule, x ∈ R is the input data in the 푘-th step, 풜푖 is the 푘 membership function of the rule antecedent, 푦푖 is the output of the 푖-th fuzzy rule, 훾푖 is a vector of parameters, 푝 is the dimension space of the input, and 푐푘 is the number of fuzzy rules at step 푘. The eTS method is based on the subtractive clustering algorithm, which allows the recursive estimate of the potential index from a new data sample (Angelov, 2013). The potential is a measure of compatibility between a new data sample x푘 and the cluster *푘 center x푖 . The learning process may start with an empty rule-base (Angelov et al., 2004a). Chapter 2. Methodological Background 28
1 1 The first data sample x becomes the focal point of the first cluster, x1. The initial value of the potential of the first cluster is 푃1 = 1 and the parameters of the local linear model associated with this rule are null, 훾1 = 0. Because the consequent parameters are updated using the recursive least squares – RLS algorithm, the covariance matrix starts 푝×푝 with 푄1 = ΩI , where Ω is a large number. The remaining computations are recursively done as follows (Angelov and Filev, 2004):
푘 − 1 푃 푘 = , (2.19) z (푘 − 1)(휗푘 + 1) + 휎푘 − 2푣푘 in which 푝+1 푘−1 푝+1 푘 ∑︁ 푘 2 푘 ∑︁ ∑︁ 푖 2 휗 = (푥푗 ) ; 휎 = (푥푗) ; 푗=1 푖=1 푗=1
푝+1 푘−1 푘 ∑︁ 푘 푘 푘 ∑︁ 푖 푣 = 푥푗 훽푗 ; 훽푗 = 푥푗. 푗=1 푖=1 푘 푘 푘 푘 푘 Note that 휗 and 푣 are computed from the current data input x , and 훽푗 and 휎 are updated recursively (Lughofer, 2011):
푝+1 푘 푘−1 ∑︁ (︁ 푘−1)︁2 휎 = 휎 + 푥푗 , 푗=1 푘 푘−1 푘−1 훽푗 = 훽푗 + 푥푗 . (2.20)
The potential of the cluster centers are recursively updated (Angelov et al., 2004a) as follows: 푘−1 (푘 − 1) 푃 * 푘 x푖 푃x* = (︂ )︂, (2.21) 푖 푘−1 ∑︀푝+1 (︁ 푘−1)︁2 푘 − 2 + 푃 * 1 + 푑 x푖 푗=1 푗
푘 푘−1 *푘 푘 where 푃 * is the potential of the cluster center at 푘, and 푑 = 푥 − 푥 denotes the x푖 푗 푖푗 푗 projection of the distance segment between the data sample x푘 and the cluster centers *푘 x푖 in the 푥 axis.
푘 푘 The potential 푃 is compared with the potential 푃 * of the clusters, and they z x푖 must satisfy certain conditions to update the fuzzy rule base. If the MODIFY condition is satisfied, then the new data replaces the most compatible cluster center:
*푘 푘 x푠 ← x , where 푠 is such that {︁ 푘 }︁ 푠 = argmax 푃 * . x푖 푗 = 1, ··· , 푐푘 The consequents parameters are updated using the RLS algorithm (Ljung, 1999). If the UPGRADE condition is satisfied, then a new fuzzy rule is added to the rule base. If both conditions do not hold, then the current input data is ignored, and the rule-base remains Chapter 2. Methodological Background 29 unchanged. The literature suggests several ways to define the MODIFY and UPGRADE conditions (Angelov et al., 2004a; Lughofer, 2011; Angelov, 2013).
푘 If membership function 풜푖 of the antecedent is Gaussian, then output of the model is computed using (Angelov et al., 2004b):
2 x푘−x*푘 ‖ 푖 ‖ 푘 푘 − 2 푘 풜푖 (x ) = 푒 4휎 = 휇푖 , (2.22)
푇 ∑︀푐푘 푘 [︁ 푘]︁ 푖=1 휇푖 훾푖 1 x 푦푘 = , (2.23) ∑︀푐(푘) 푘 푖=1 휇푖 푘 푘 which 휇푖 is the activation degree of the 푖-th fuzzy rule, 푖 = 1, ··· , 푐 , and 휎 is a positive constant that bounds the influence zone of the 푖-th rule.
2.2.2 Evolving Participatory Learning
Evolving systems are self-adaptive structures with learning and summarization ca- pabilities (Leite et al., 2015). They update their structural components and parameters on-demand using stream data. The stream carries data about the process input, state, output variables, as well as the process behavior and operating conditions. Evolving sys- tems adapt their range of influence, and repeatedly update their structure and parameters to accommodate new information conveyed by data (Lughofer, 2011). A self-adaptive modeling framework is called participatory if the usefulness of each input datum in contributing to the learning process depends upon its compatibility with the current model structure. In fuzzy rule-based modeling, the number and the type of fuzzy rule in the rule base specify the model structure. The antecedent parts of fuzzy rules perform a partition of a 푝-dimensional input data space, and vice versa, if we are given a fuzzy partition, then we may construct a fuzzy rule for each of the fuzzy region of data space. Information granularity is one of the most fundamental notion to search for struc- ture in data. Given a finite set of data, clustering aims at finding cluster centers v푖 to properly characterize relevant fuzzy sets 풜푖 in the data space. These are required to form a fuzzy 푐-partition (George and Yuan, 1995) called a granulation of the data space. Evolving participatory learning (ePL) is a two-step self-adaptive modeling ap- proach introduced in (Lima et al., 2006). The first step uses participatory learning to cluster stream data online and identify the model structure. Because the number of rules is the same as the number of clusters, the cluster structure settles the model structure in a one-cluster, one-rule framework. The second step develops a fuzzy functional rule for each cluster found in the first step (Oliveira et al., 2017; Lughofer, 2011). Functional fuzzy Chapter 2. Methodological Background 30 rules are fuzzy rules whose antecedents are fuzzy sets, and the consequents are functions of the input variables:
푘 푘 푘 (︁ 푘)︁ R푖 : IF x is 풜푖 THEN 푦^푖 = 푓푖 x 푖 = 1, ··· , 푐푘,
푘 푘 푝 where R푖 is the i-th fuzzy rule, 푐 is the number of fuzzy rules at k, x ∈ [0,1] is the input, 푘 푘 푦^푖 is the output of the i-th rule, 풜푖 is a fuzzy set of the antecedent whose membership 푘 (︁ 푘)︁ (︁ 푘)︁ 푘 function is 풜푖 x , and 푓푖 x is a function of the input x , respectively. Similarly as in (︁ 푘)︁ eTS, here ePL modeling assumes 푓푖 x affine whose parameters are chosen to fit a local model for the 푖-th data cluster, that is, ePL also assigns to each granule a fuzzy functional rule with a local affine model (Lughofer, 2011; Oliveira et al., 2017). In ePL cluster centers 푘 v푖 are the modal values of Gaussian membership functions of the rule antecedent fuzzy sets as in (2.22).
푘 푝 Cluster centers are such that v푖 ∈ [0,1] . At each processing step after initializa- tion, the ePL clustering algorithm verifies whether a new cluster must be created, if an existing cluster should be updated to accommodate new data, or if redundant clusters should be deleted (Lima et al., 2010). The cluster structure is updated using a compati- 푘 푘 bility measure 휌푖 ∈ [0,1], and an arousal index 푎푖 ∈ [0,1] computed as follows: ‖x푘 − v푘‖ 휌푘 = 1 − √ 푖 , (2.24) 푖 푝
푘+1 푘 푘 푘 푎푖 = 푎푖 + 휗(1 − 휌푖 − 푎푖 ), (2.25) where 휗 ∈ [0,1] is the arousal rate. If the smallest arousal index value is higher than a threshold 휏 ∈ [0,1]: {︁ 푘+1}︁ argmin 푎푗 > 휏, 푗 = 1, ··· , 푐푘 then a new cluster is created. Otherwise, the cluster center most compatible with the current input data is updated using:
푘+1 푘+1 푘 (︁ 푘)︁[1−푎푠 ] (︁ 푘 푘)︁ v푠 = v푠 + 휉 휌푠 x − v푠 , 푘 푠 = argmax 휌푗 , (2.26) 푗 = 1, ··· , 푐푘 where 휉 ∈ [0,1] is a learning rate. The parameters of the local affine models are updated using the RLS algorithm. The fuzzy rule base is checked to verify redundant rules. The compatibility between cluster centers is computed using: ⃦ ⃦ ⃦ 푘 푘⃦ ⃦v푖 − v푗 ⃦ 휌푘 = 1 − √ (2.27) 푖푗 푝 Chapter 2. Methodological Background 31
(︁ 푘 )︁ 푘 푘 푘 where 푖 = 1, ··· , 푐 − 1 , and 푗 = 푖+1, ··· , 푐 . If the compatibility between v푖 and v푗 is 푘 higher than the threshold 휆 ∈ [0,1], that is, 휌푖푗 ≥ 휆, then the cluster center v푗 is declared redundant and is removed. Otherwise, the current cluster structure remains as it is. The overall output is computed as the weighted average of the individual rule outputs: ∑︀푐푘 휇푘푦푘 푦푘 = 푖=1 푖 푖 . (2.28) ∑︀푐푘 푘 푖=1 휇푖
2.3 State Observers
This section reviews the concepts of observability and state observer. Observability is concerned with whether or not the initial state can be recovered from the output of a linear system (Chen, 2013). Observers can be used to augment or replace sensors in control systems. Observers are algorithms that combine measured signals with process knowledge to estimate the values of the state variables (Ellis, 2002). The following definition and theorem summarize the notion of observability of lin- ear systems continuous, time-invariant systems, and give away to characterize observable linear systems (Simon, 2006).
Definition 2.3.1. A continuous time-invariant system is observable if for any initial state x(0) and time 푡 > 0 the initial state can be uniquely determined from the input 푢(훿푡) and output 푦(훿푡) for all 훿푡 ∈ [0,푡].
Definition 2.3.1 states that if a liner time-invariant system is observable, then any initial state can be found from input and output measurements. We can check the observability of continuous linear time-invariant systems using the following result (Ellis, 2002; Khalil, 2002; Simon, 2006):
Theorem 2.3.1. Consider the 푛-dimensional continuous linear time-invariant system
x˙ = 퐴x + 퐵푢 푦 = 퐶x (2.29) where 퐴 ∈ R푛×푛, 퐵 ∈ R푛×1, and 퐶 ∈ R1×푛 and let the matrix 푄 be ⎡ ⎤ 퐶 ⎢ ⎥ ⎢ ⎥ ⎢ 퐶퐴 ⎥ 푄 = ⎢ ⎥ . (2.30) ⎢ . ⎥ ⎢ . ⎥ ⎣ ⎦ 퐶퐴푛−1
The system is observable if only if 푄 has rank 푛. Chapter 2. Methodological Background 32
Assume that (2.29) is observable. The observer is a structure that combines the output (sensor measurements) and input (actuator signals) of a plant using a model of plant (Ellis, 2002). The state estimation problem can be summarized as follows: develop estimates ^x(t) of the state x(푡) from the input 푢(푡), output 푦(푡), and matrices 퐴, 퐵, and 퐶. A solution is to duplicate the system using its model:
푥^˙ = 퐴^x + 퐵푢 푦^ = 퐶^x, (2.31)
The result is the open loop observer shown in Figure 2.3.
푢(푡) x˙ = 퐴x + 퐵푢 푦(푡) 푦 = 퐶x
푥^˙ = 퐴^x + 퐵푢 ^x(푡) 푦^ = 퐶^x
Figure 2.3 – Open-loop state observer.
This methodology is called open-loop state observer. If the initial states are the same, then this approach estimates the system states x(푡) = ^x(푡) for all 푡 ≥ 0. There are two disadvantages with open-loop observers (Chen, 2013). First, it needs to compute the initial state whenever the state estimator is used, which is very inconvenient. Second, small differences between x(푡0) and ^x(푡0) may depart estimates from the actual state values. To avoid these disadvantages, Luenberger suggested a closed-loop state estimator of the following form (Ellis, 2002):
푥^˙ = 퐴^x + 퐵푢 + 퐿 [푦(푡) − 퐶^x] 푦^ = 퐶^x, (2.32) where 퐿 ∈ R푛×1 is the observer gain. Let the estimation error be:
x˜(푡) = x(푡) − ^x(푡). (2.33)
Thus, differentiating (2.33), and from (2.29), (2.32), and after some algebraic manipula- tion, the observer error dynamics becomes:
x˜˙ (푡) = (퐴 − 퐿퐶)x˜(푡) (2.34)
Therefore, if the closed-loop system matrix (퐴 − 퐿퐶) is Hurtwiz, then the observer error approches zero, lim푡→∞ ^x(푡) = x(푡). Figure 2.4 shows the Luenberger observer. The Luenberger observer scheme is ideal for linear time-invariant systems. Nonlin- ear systems in the form (2.1) can benefit from state observers using mechanisms similarly Chapter 2. Methodological Background 33
푢(푡) x˙ = 퐴x + 퐵푢 푦(푡) 푦 = 퐶x
+ 퐿 −
푥^˙ = 퐴^x + 퐵푢 + 퐿 [푦(푡) − 퐶^x] 푦^ = 퐶^x 퐶^x(푡) ^x(푡)
Figure 2.4 – Luenberger observer. as used for linear systems (Krener and Respondek, 1985; Freidovich and Khalil, 2008,
2006). The observer design requires the observability of the pair (퐴푐,퐶푐). The state ob- server is: ˙ x^ = 퐴푐x^ + 퐵푐[푓푛(x^) + 푔푛(x^)푢] + H(푦 − 퐶푐x^), (2.35) where 푓푛(x) and 푔푛(x) are known vector fields, and H is a high-gain matrix. The matrices
퐴푐, 퐵푐, and 퐶푐, with the appropriate dimensions, represent the dynamics of a chain of 푛 integrators:
⎡ ⎤ ⎡ ⎤ 0 1 0 ··· 0 0 ⎢ ⎥ ⎢ ⎥ ⎢ ⎥ ⎢ ⎥ ⎢0 0 1 ··· 0⎥ ⎢0⎥ ⎢ ⎥ ⎢ ⎥ [︁ ]︁ ⎢ ...... ⎥ ⎢ . ⎥ 퐴푐 = ⎢ . . . . . ⎥, 퐵푐 = ⎢ . ⎥, and 퐶푐 = 1 0 0 ··· 0 . ⎢ ⎥ ⎢ ⎥ ⎢ ⎥ ⎢ ⎥ ⎢0 0 0 ··· 1⎥ ⎢0⎥ ⎣ ⎦ ⎣ ⎦ 0 0 0 ··· 0 1
The state estimation error x˜ = x − x^ yields the error dynamics:
x˜˙ = (퐴푐 − H퐶푐) x˜ + 퐵푐훿, (2.36) where 훿 = [푓(x) − 푓푛(x^)] + [푔(x) − 푔푛(x^)] 푢 can be viewed as disturbance in the closed- loop caused by modeling errors. The asymptotic stability of the error is guaranteed by a suitable choice of a Hurwitz polynomial 2:
푟 (푟−1) 푠 + ℎ1푠 + ··· + ℎ푟−1푠 + ℎ푟 = 0 (2.37)
[︁ ]︁푇 where H = ℎ1 ℎ2 ··· ℎ푟 . Choosing gains such that ℎ푟 ≫ ℎ푟−1 ≫ · · · ≫ ℎ1, distur- bances are forced to decay rapidly (Khalil, 2002), that is, lim푡→∞ 훿(푡) = 0 within a short interval of time. A possible choice of the high-gain parameters is:
[︁ ]︁푇 푎1 푎2 푎푟 H(휖) = 휖 휖2 ··· 휖푟 (2.38)
2See (Khalil, 2017b, Chap. 02) for details. Chapter 2. Methodological Background 34
with 휖 ∈ (0,1], and 푎푖 are chosen such that the roots of
푟 (푟−1) 푠 + 푎1푠 + ··· + 푎푟−1푠 + 푎푟 = 0, (2.39) are in the open left-half plane. An alternative observer approach, called extended high-gain observer, can be de- veloped from (2.35) (Freidovich and Khalil, 2006; Khalil, 2017b). In such an approach, an additional state is added in the chain of integrators to lift the closed-loop system to R푛+1. In this case, from (2.38)-(2.39), the state observer (2.35) becomes: ˙ x^ = 퐴푐x^ + 퐵푐[^휒 + 푓푛(x^) + 푔푛(x^)푢] + H(휖)(푦 − 퐶푐x^), 푎 휒^˙ = 푟+1 (푦 − 퐶 x^). (2.40) 휖푟+1 푐 Therefore, the feedback linearization control law (2.2) can be expressed as: 1 푢 = (푣 − 푓(x^) − 휒^) . (2.41) 푔(x^)
The choice 푣 = Kx^ such that K turns the nominal closed-loop system asymptotically stable, ensures robust closed-loop behavior, and leads to exponentially stable closed-loop trajectories.
2.4 Summary
This chapter has addressed the methods and algorithms that are essential for the development of subsequent chapters. We reviewed the notions of feedback linearization, granular computing, evolving participatory learning, and state observers. Particular em- phasis was given to the evolving Takagi-Sugeno – eTS and the evolving participatory learning – ePL modeling algorithms. 35 3 Robust Granular Feedback Linearization
The process of linearization by state feedback involves the exact cancellation of nonlinearities expressed by the nonlinear functions 푓 and 푔. Its success relies on the pre- cise description of 푓 and 푔, what is unlikely to happen in practice (Isidori, 1995; Khalil, 2002; Sastry, 1999). This section develops the robust granular feedback linearization con- trol scheme. We assert the assumptions, and next we build the machinery needed to compensate the effects of modeling mismatches in feedback linearization control.
3.1 Robust Granular Controller
Section 2.1 introduced the notions of exact feedback linearization and closed-loop tracking control. Exact feedback linearization control assumes that a precise model of the process is available. The tracking error is:
푇 [︁ (푛−1)]︁ e = z푑(푡) − r(푡) = 푒 푒˙ ··· 푒 (3.1)
푇 [︁ (푛−1)]︁ 푛 where r(푡) = 푟 푟˙ ··· 푟 is the reference, and e ∈ D푒 ⊆ R is the error in the coordinate system z푑 through the diffeomorphism (2.3). The subset D푒 is a vector displacement of D. From (3.1) and (2.7) the error dynamics becomes:
(푛) ˙e = 퐴푐e + 퐵푐훾(x)[푢 − 훼(x)] − 퐵푐푟 (푡). (3.2)
푟 ℒ푓 ℎ(x) −1 If the control is computed as in (2.2), then using 훼(x) = − 푟−1 , 훾 (x) = ℒ푔ℒ푓 ℎ(x) 1 (푛) 푟−1 , 푣 = 푟 (푡) − 퐾e, and (3.2) the tracking error becomes: ℒ푔ℒ푓 ℎ(x)
˙e = (퐴푐 − 퐵푐퐾)e. (3.3)
However, if the nonlinearities 훼(x) and 훾(x) are not known precisely, but have their values affected by the disturbances Δ훾(x) and Δ훼(x) such that
훾(x) = 훾푛(x) + Δ훾(x),
훼(x) = 훼푛(x) + Δ훼(x), (3.4) where 훾푛(x) and 훼푛(x) are known nominal nonlinearities of the model used to design the control law, then replacing (2.2) in (2.7) and considering (3.4), assuming 푣 = 푟(푛)(푡)−퐾e, gives:
e˙ = (퐴푐 − 퐵푐퐾)e + 퐵푐푤 (3.5) Chapter 3. Robust Granular Feedback Linearization 36
where 푤 = Δ훾(x)[푢 − 훼푛(x) − Δ훼(x)] − 훾푛(x)Δ훼(x). Note that 푤 can be viewed as an exogenous disturbance of the closed-loop system that may cause unexpected behavior and closed-loop instability (Franco et al., 2006; Guillard and Boul`es, 2000; Leite et al., 2013). Additive uncertainties Δ훾(x) and Δ훼(x) in (3.4) cause mismatches between the tracking error dynamics (3.3) of the actual system, and the tracking error dynamics ob- tained when the nonlinearities of the nominal system is used to design the feedback linearized control. Looking at (3.3) and (3.5) we see that the mismatch is due to 푤 in (3.5). Because 푤 is unknown, the effects caused by Δ훾(x) and Δ훼(x) in 푤 can be reduced if an estimate 푤^ is obtained. Therefore, a compensation input signal of the form:
−1 푢푐 = −훾푛 푤^ (3.6) is added in the control loop, as shown in Figure 3.1. In this case, the compensation signal
푢푐 is used to mitigate the effects on the closed-loop caused by the additives disturbances shown in (3.4). The input signal 푢푐 is computed in the RGFL Algorithm Loop (dashed blue box in Figure 3.1), as follows:
1. Get the current values of 푦, x, and 푟(푡).
2. Compute the tracking error 푒1 = 푟(푡) − 푦.
3. Compute estimate 푤^ using the ePL algorithm of Section 2.2.2.
4. Compute the compensation input signal using (3.6).
The value 푤^ is estimated by the ePL algorithm which takes the state vector of the system (x) and the tracking error (푒1) as antecedents variables of the fuzzy functional [︁ ]︁ rules learned by ePL. Cluster centers v in the z = x 푒1 data space are the modal values of Gaussian membership functions of the fuzzy rules antecedents, v ∈ [0,1] ∀x ∈ D ⊆ 푛 R and 푒1 ∈ D푒 ⊆ R. These vectors are treated by the ePL algorithm at each sampling time, that is, at each step 푘. Therefore, whenever a new sample z푘 is input at step 푘, we have a collection of 푐푘 fuzzy functional rules:
푘 푘 푘 푘 푘 R푖 : IF z is 풜 THEN 푤^ = 휋 휒 + 퐾푝푒1 푖 푖 푖 푖 (3.7) 푖 = 1, . . . , 푐푘
푘 푘 푘 is developed by ePL to produce an estimate 푤^푖 of 푤푖 . Here 휋푖 is the vector of coefficients 푘 of the 푖-th consequent affine model, 퐾푝 is a proportional gain, and 휒푖 is a regressor vector built similarly as in autoregressive models with exogenous variables – ARX, namely:
푘 [︁ ]︁푇 휒 = 푤^푘−1 ··· 푤^푘−푛푤^ x푘−1 ··· x푘−푛푥 . (3.8)
푘 where 푛푤^ and 푛푥 are the order of the respective terms. Note that the output 푤^푖 of the 푘 푘 rule (3.7) is analogous to the output 푦푖 in (2.28), and likewise 푓(z ) in (2.28) is analogous Chapter 3. Robust Granular Feedback Linearization 37
RGFL Control Algorithm 푟(푡)
+ −훾−1(x) 푛 푒푃 퐿 푒 푤^ 1 − x x
푢푐 + + + 푢푠 푦 e 푇 푛−1 푣 −1 푢 x˙ = 푓(x) + 푔(x)푢푠 r(푡) −퐾 e + 푟 훼(x) + 훾푛 (x)푣 + 푦 = 푥1 z푑 x Feedback linearization loop
x 푀(x) State feedback control loop
Figure 3.1 – Robust granular feedback linearization — RGFL.
푘 푘 푘 to 푓(z ,푤^푖) = 휋푖 휒푖 + 퐾푝푒1. The vector of coefficients of the 푖-th consequent affine model is updated using the RLS algorithm with forgetting factor (Ljung, 1999, pp. 363):
Φ푘−1휒푘 Λ푘 = 푖 , 푖 푘 푇 푘−1 푘 (휒 ) Φ푖 휒 + 휁 푘 푘−1 푘 푘 휋푖 = 휋푖 + Λ푖 퐾푝푒1, ⎡ 푇 ⎤ 푘−1 푘 (︁ 푘)︁ 푘−1 1 Φ푖 휒 휒 Φ푖 Φ푘 = ⎢Φ푘−1 − ⎥ , (3.9) 푖 ⎣ 푖 푘 푇 푘−1 푘 ⎦ 휁 (휒 ) Φ푖 휒 + 휁
푘 푘 where Λ푖 is the Kalman gain, and Φ푖 is the covariance matrix. The output of the ePL is the weighted average of the local models of the rules consequents, that is:
푐푘 휇푘푤^푘 푤^푘 = ∑︁ 푖 푖 (3.10) ∑︀푐푘 푘 푖=1 푖=1 휇푖
푘 with membership values 휇푖 computed using (2.22). Algorithm 3.1 gives the detailed steps 푘 −1 to compute estimates 푤^푖 , and input signal 푢푐 = −훾푛 푤^. Note that if we add 푢푐 in the control loop, the new control input becomes 푢푠 (see Figure 3.1):
−1 푢푠 = 훼(x) + 훽푣 − 훾 (x)푤 ^ (3.11) ⏟ ⏞ ⏟ ⏞ 푢 푢푐
(푛) and, because 푢 = 푢푠 from (3.11), replacing 푢 in (2.7) considering (3.4) with 푣 = 푟 (푡) − 퐾e, we have:
e˙ = (퐴푐 − 퐵푐퐾)e + 퐵푐(푤 − 푤^). (3.12)
Therefore, if lim푡→∞ 푤^(푡) = 푤, then (3.12) approaches (3.3) which means that effects of modeling mismatches are successfully circumvented (Khalil, 2002; Lima et al., 2010; Lughofer, 2011). Next section shows that this is, under certain assumptions, the case. Chapter 3. Robust Granular Feedback Linearization 38
Algorithm 3.1 RGFL control algorithm. 푘 [︁ 푘 푘]︁ 푝 1: Input: z = x 푒1 ∈ [0,1] , ∀푘 ≥ 1 푘 2: Output: 푢^푐 3: Initialize the RGFL parameters: 휉,휗,휏,휆, 휎, 휁 and 퐾푝 4: Initialize the first cluster center: v1 ← z1 5: while 푘 ≤ ∞ do 6: z푘 ←Read new data. 7: 휒푘 ←Update the consequent vector using (3.8). 8: for 푖 = 1 to 푐푘 do 푘 9: Compute the compatibility index 휌푖 using (2.24) 푘+1 10: Compute the arousal index 푎푖 using (2.25) 11: end for {︁ 푘}︁ 12: if argmin 푎푗 > 휏 then 푗=1,··· ,푐푘 푘 13: v푐푘+1 ← z 14: else 푘 15: Update the most compatible cluster v푠 using (2.26) 푘 16: Update the parameters 휋푖 using (3.9) 17: end if 18: for 푖 = 1 to 푐푘 − 1 and 푗 = 푖 + 1 to 푐푘 do 푘 19: Compute the compatibility index 휌푖푗 using (2.27) 푘 20: if 휌푖푗 ≥ 휆 then 푘 21: Delete the cluster center v푗 22: Update the cluster number: 푐푘 = 푐푘 − 1 23: end if 24: end for 25: for 푖 = 1 to 푐푘 do 푘 26: Compute firing degree 휇푖 using (2.22) 27: end for 28: Compute estimate 푤^푘 using (3.10) 푘 29: Compute control signal 푢^푐 using (3.6) 30: Update the counter: 푘 = 푘 + 1 푘 31: Return 푢^푐 32: end while
3.2 Lyapunov Stability Analysis
In this section, we develop convex optimization procedures and conditions to verify the stability of the closed-loop system (3.12). The conditions can be used to guarantee that, under certain conditions, the closed loop control system tracks the reference. First 푛 we assume that all trajectories of e(푡) remain inside a set D푒 ⊆ R , which is the domain 푛 D ⊆ R of (2.7) shifted by the reference vector r(푡). Moreover, assume that 푤 =푤 ^ + 훿푤 where 훿푤 is the estimation error of the ePL algorithm whose values belong to the the set 풲 {︁ 푇 }︁ 풲 = 훿푤 ∈ R; 훿푤 훿푤 ≤ 휖0 . (3.13) which means that 훿푤(푡) is bounded by a quadratic norm (Tarbouriech et al., 2011). Also, assume that the estimation error of ePL vanishes, that is, lim푡→∞ 훿푤(푡) = 0 (Khalil, 2002, Chapter 3. Robust Granular Feedback Linearization 39
Cap. 9). Thus, the error equation (3.12) can be rewritten as follows:
˙e = (퐴푐 − 퐵푐퐾)e + 퐵푐훿푤. (3.14)
We note that (3.14) is a linear equation, and that 훿푤(푡) can be viewed as a disturbance in the closed-loop system induced by an exogenous signal. The stability of the closed-loop must be ensured for 훿푤 ∈ 풲 and under both 훿푤(푡) = 0 푡 ≥ 0 and 훿푤(0) ̸= 0. In addition, the closed-loop system must approach to the origin asymptotically. According to the Lyapunov stability principle (Rantzer, 2001), the continuous-time system (3.14) is locally stable (with 훿푤 = 0 ∀푡 ≥ 0 and e ∈ D푒) if there exists a function
푉 (e) and 휅0, 휅1, 휅2 ∈ 풦 and such that (Khalil, 2002, pp. 144):
1. 휅0(‖e(푡)‖) ≤ 푉 (e(푡)) ≤ 휅1(‖e(푡)‖) and ˙ 2. 푉 (e(푡)) ≤ −휅2(‖e(푡)‖),
for all e(푡) ∈ D푒. Functions 휅푖(‖e(푡)‖), 푖 ∈ {0, 1, 2}, are class 풦 functions, that is, 휅푖 :
[0, 푎) → [0, ∞) is strictly increasing, 휅푖(0) = 0, and ‖e(푡)‖ ≤ 푎 > 0 for e(푡) ∈ D푒. If (3.14) is (locally) stable, than there exists a Lyapunov function 푉 (e) = e푇 푃 e with a matrix 푇 푛×푛 0 < 푃 = 푃 ∈ R . From this function, we can define a compact level set ℛ(푃,휖1) ⊆ D푒 as follows: 푇 ℛ(푃,휖1) = {e ∈ D푒 : e 푃 e ≤ 휖1}. (3.15)
Because of the hypothesis that 푉 (e) is a Lyapunov function, we can conclude that ℛ(푃,휖1) is a contractive set with 휖1 > 0. Additionally, we can note that if e ∈ 휕ℛ(푃,휖1), then we 푇 푇 have 휖1 − e 푃 e ≥ 0. Similarly, from (3.13), we have 휖0 − 훿푤 훿푤 ≥ 0. Observe that the ˙ negativity of 푉 (e(푡)) must be fulfiled whenever 훿푤 ∈ 풲 and e ∈ 휕ℛ(푃,휖1) yielding, by S-procedure1 the following inequality:
˙ 푇 푇 푉 (e) + 휏1(휖0 − 푤 푤) + 휏2(e 푃 e − 휖1) < 0, (3.16)
˙ 푇 푇 where 푉 (e) = e˙ 푃 e + e 푃 e˙, 휏푗 > 0, 푗 = 1,2. Thus, in such a case, all trajectories of
(3.14) emanating from e(0) ∈ ℛ(푃,휖1) remains in ℛ(푃,휖1) for all 훿푤 ∈ 풲, meaning that the set ℛ(푃,휖1) is positively invariant.
푛 Assume that the subset D푒 ⊆ R can be described by a polyhedral ensemble given by, 푛 D푒 = {e ∈ R ; |풱(ℓ)e| ≤ 휈(ℓ)}, (3.17)
1×푛 where 휈(ℓ) > 0, 풱(ℓ) ∈ R , ℓ = 1,..., 푚˜ , and 푚˜ is the number of linear constraints 푛 required to limit the region D푒 ⊂ R .
1See explanation in the Appendix A. Chapter 3. Robust Granular Feedback Linearization 40
Theorem 3.1. Consider the error dynamics (3.14) under assumption (3.13). Assume 푛 there are positive real scalars 휖0, 휖1 , 휏1, 휏2, a state feedback gain 퐾 ∈ R , and a symmetric 푛×푛 positive definite matrix 푃 ∈ R . Let the domain D푒 be given by (3.17), and that the linear matrix inequalities
⎡ 푇 ⎤ (퐴푐 − 퐵푐퐾) 푃 + 푃 (퐴푐 − 퐵푐퐾) + 휏2푃 푃 퐵푐 ⎣ ⎦ < 0, (3.18) ⋆ −휏1
휖0휏1 − 휖1휏2 < 0, (3.19) and ⎡ ⎤ 푃 풱푇 (ℓ) ≥ 0, ℓ = 1,..., 푚,˜ (3.20) ⎣ 2 ⎦ ⋆ 휈(ℓ)/휖1 are verified. Then,
1. for 훿푤 = 0, the origin of (3.14) is locally exponentially stable;
2. for 훿푤 ̸= 0, with 훿푤 ∈ 풲, the trajectories of (3.14) emanating from e(0) ∈ ℰ(푃,휖1)
not leave the set ℛ(푃,휖1), for all 푡 ≥ 0;
3. the trajectories starting in e(0) ∈ ℰ(푃,휖1) do not leave the D푒.
Proof. Assume that with 푃 > 0 the inequality (3.18) is verified. Then 푉 (e) = e푇 푃 e veri- 2 2 fies that 휅0(‖e(푡)‖) ≤ 푉 (e(푡)) ≤ 휅1(‖e(푡)‖) with 휅0 = 휆min(푃 )‖e‖ and 휅1 = 휆max(푃 )‖e‖ for all e ∈ ℛ(푃,휖1), where 휆min and 휆max are the minimum and maximum eigenvalues of [︁ ]︁ 푃 , respectively. Left and right multiplying inequality (3.18) by e푇 푤푇 and its transpose to get 푇 푇 푇 푇 e˙ 푃 e + e 푃 e˙ − 휏1푤 푤 + 휏2e 푃 e < 0. (3.21) This fact with the verification of (3.19) means that (3.16) is verified. Moreover, in case ˙ 푇 푇 푇 of 푤(푡) = 0, inequality (3.21) ensures 푉 (e) = e˙ 푃 e + e 푃 e˙ ≤ −휏2e 푃 e = −휏2푉 (e), meaning that 푉 (e(푡)) ≤ 푒−휏2 푉 (e(0)). Therefore, the exponential stability of (3.14) is verified.
It remains to prove that the trajectories emanating from e(0) ∈ ℛ(푃,휖1) do not leave the region defined by (3.17). From the feasibility of (3.20), we apply Schur comple- ment to get 푇 −2 푇 −2 −1 풱(ℓ)풱(ℓ)휖1휈(ℓ) ≤ 푃 ⇔ 풱(ℓ)풱(ℓ)휈(ℓ) ≤ 휖1 푃.
푇 푇 푇 By pre- and post-multiplying by e(푡) and its transpose, we get e(푡) 풱(ℓ)풱(ℓ)e(푡) ≤ 2 −1 푇 휈(ℓ)휖1 e(푡) 푃 e(푡). Since −1 푇 휖1 e(푡) 푃 e(푡) ≤ 1, we can conclude that |풱(ℓ)e(푡)| ≤ 휈(ℓ) is ensured and, thus, the trajectories emanating from e(0) ∈ ℛ(푃,휖1) do not leave the subset D푒, completing the proof. Chapter 3. Robust Granular Feedback Linearization 41
It is worth to say that we can choose 휖1 = 1 without loss of generality in the conditions of Theorem 3.1. Therefore, a issue of interest is to verify the maximal allowed √ ePL error, 휖0, for given values of 휈 and 휏2. By replacing 휇 = 휖0휏1 in (3.19), we can solve the following optimization procedure:
min 휏1 − 휇 휏1,푃 (3.22) subject to 푃 > 0, (3.18) − (3.20).
The solution of this procedure leads to the maximization of 휖0 = 휇/휏1, and thus, to the maximization of the amplitude error of the ePL algorithm.
3.3 Performance Evaluation
This section evaluates the behavior and performance of robust granular feedback linearization – RGFL control using simulation and actual experiments concerning the level control of a surge tank, and simulation experiments for the angular position control of the knee of the lower limb system, and the tracking control of an inverted pendulum.
3.3.1 Surge Tank Simulation Experiments
This section addresses the level control problem of a surge tank. The surge tank model, depicted in Figure 3.2, is a benchmark adopted by many authors (Banerjee et al., 2011; Passino and Yurkovich, 1997; Silva et al., 2018; Oliveira et al., 2019) to evaluate feedback linearization control approaches. The following differential equation models the dynamics of the tank of Figure 3.2:
푞푖푛
ℎ
푞표푢푡 푐
Figure 3.2 – Surge tank.
√ −푐 2푔ℎ 1 ℎ˙ = + 푢 (3.23) 퐴(ℎ) 퐴(ℎ) where ℎ is the tank level (푚), 푔 is the gravity constant (푚/푠2), 푐 is the cross-sectional area of the output pipe (푚2), 푢 is the input control (푚3/푠), and 퐴(ℎ) is the cross-sectional Chapter 3. Robust Granular Feedback Linearization 42 area of the tank (푚2) given by: 퐴(ℎ) = 푎ℎ + 푏, where 푎 = 0.01 and 푏 = 0.2 (Banerjee et al., 2011). To address the level control problem as a tracking reference control problem, we can use here the control law (2.2), in discrete form, to obtain: √︁ ⎡ 푘 ⎤ 푘 푘 푘 푐 2푔ℎ 푢 = 퐴(ℎ ) ⎣푣 + ⎦ . (3.24) 퐴(ℎ푘)
The state feedback controller 푣푘 = −K푒푘 with gain K = 1.15 is used to stabilize the closed-loop system. We also assume that the actuator saturates at ±50 푚3/푠, that is:
⎧ ⎪50, if 푢푘 > 50 ⎪ ⎨⎪ 푘 푘 푢푠(푘) = 푢 , if − 50 ≤ 푢 ≤ 50 (3.25) ⎪ ⎪ ⎩⎪−50, if 푢푘 < −50
The simulation experiments use the discrete form of the tank model: √ [︃ 19.6ℎ푘 1 ]︃ ℎ푘+1 = ℎ푘 + 푇 −(1 + 휍 ) + (1 + 휍 ) 푢푘 (3.26) 0 0.01ℎ푘 + 0.2 1 0.01ℎ푘 + 0.2 where 푇 is the sampling time, 휍0 and 휍1 are assumed to be uncertain. Note that 휍0 and
휍1 play the role of Δ훼(x) and Δ훾(x) in (3.2) considering (3.4). The sampling time is 푇 = 0.1s, a value short enough to approximate reasonably well the continuous dynamics of the tank (Passino and Yurkovich, 1997). Performance of RGFL was evaluated against EFL for three references 푟(푡) trajectories with square, saw-tooth, and triangular waveform, respectively. These reference trajectories were suggested in (Banerjee et al., 2011; Passino, 2005). Two simulation scenarios were considered. First, we assume perfect knowledge of plant, that is, the values of 휍0 and 휍1 in (3.26) are null. We call it the exact nominal model. Second, we modify the tank model turning 휍0 = −0.05 and 휍1 = 0.10 to cause a (parametric) mismatch between the tank and the model used in the feedback linearization law. We call it the unknown model for short. Simulation results are shown in Figures 3.3, 3.4 and 3.5 with the following conven- tion: nominal exact tank model with EFL (blue line) and RGFL controller (green line), and unknown model with EFL (cyan line) and RGFL controller (red line). Reference trajectories 푟(푡) are plotted in black dashed line. The parameters of the ePL algorithm were chosen according to the guidelines offered in (Lughofer, 2011, Cap. 4): 휉 = 0.125, 휗 = 0.01, 휏 = 0.00125, 휆 = 0.85, and
휎 = 0.02. The RLS algorithm uses forgetting factor 휁 = 0.99 and gain 퐾푝 = 7.5. The LMIs (3.18) and (3.19) of Theorem 3.1 were solved by using the CVXOPT [︁ ]︁ [︁ ]︁ solver (Andersen et al., 2012, 2018) for 퐴푐 = −1.15 , 퐵푐 = −1 , 휏2 = 2.25, and 훿 = 1 and Chapter 3. Robust Granular Feedback Linearization 43
10
5 h (m )
0 0 20 40 60 80 100
10 /s) 3
u (m 0
0 20 40 60 80 100 5
4
3
2 Clusers number 1 0 20 40 60 80 100 Tim e (s)
Figure 3.3 – RGFL controller tracking a square waveform reference trajectory with nomi- nal exact tank model with EFL (blue line) and RGFL controller (green line), and unknown model with EFL (cyan line) and RGFL controller (red line). Reference trajectories 푟(푡) are plotted in black dashed line.
[︁ ]︁ the value of 휛 has been maximized. The result is 푃 = 0.0399 , 휛 = 1.40, and 휏1 = 1.60 which shows that the closed-loop control system is stable for 푤푇 푤 ≤ 1 (thus the ePL error must be less or equal to 1) and the trajectory of the error vector e remains e푇 푃 e ≤ 휛, √ i.e., the maximum allowed output error in this case is given by 휛푃 −1 ≈ 35.08m. Such an error value is larger than the ones usually verified in the control of the level. Figures 3.3, 3.4 and 3.5 give a qualitative view of the RGFL controller behavior. Clearly RGFL outperforms EFL in all scenarios. In particular, looking at Figure 3.5 it is clear that the tracking error is much smaller than the allowed maximum value computed before (35.08m). To further evaluate the RGFL approach, we quantify the closed-loop performance using classical control indexes as integral of absolute error – IAE and the integral of time-weighted absolute error – ITAE, and compare its performance with the indirect adaptive fuzzy certainty equivalence controller based upon bacterial foraging fuzzy technique – BFOF (Banerjee et al., 2011). The bacterial population size is 40. IAE and ITAE are computed as follows:
퐼퐴퐸 = ∑︁ | 푒(푘) | 푇 (3.27) 푘
퐼푇 퐴퐸 = ∑︁ | 푒(푘) | 푘푇 2 (3.28) 푘 Chapter 3. Robust Granular Feedback Linearization 44
10
8
6
h (m ) 4
2
0 0 20 40 60 80 100
20
15 /s) 3 10 u (m 5
0 0 20 40 60 80 100
4
3
2 Clusers number
1 0 20 40 60 80 100 Tim e (s)
Figure 3.4 – RGFL controller tracking a sawtooth reference trajectory with EFL (blue line) and RGFL controller (green line), and unknown model with EFL (cyan line) and RGFL controller (red line). Reference trajectories 푟(푡) are plotted in black dashed line.
where 푒(푘) = 푟(푘) − ℎ(푘). Table 3.1 summarizes the results. Note that BFOF relies on a high computational cost, once the number of rules is more significant than the proposed approach. The RGFL is noticeably superior to EFL and BFOF, especially for the unknown model case.
3.3.2 Actual Surge Tank Experiments
The RGFL scheme was evaluated in the real world, particularly in a real-time tracking control system scenario using the surge tank system depicted in Figure 3.6. This system has four tanks with a nominal capacity of the 200 l each, and two water reservoirs with a nominal capacity of 400 l each. To measure the level, each tank is equipped with a pressure sensor model 26푃 퐶퐵퐹 퐴6퐷. The control system responds to the control signal through two three-phase 1 HP hydraulic pumps commanded by two WEG CFW09 invert- ers. The controller is implemented using a low-cost computer, and the data acquisition is made via a Simatic S7-300 programmable logic controller – PLC. The computer and the PLC are connected via Ethernet protocol and the controller programming is developed in Python. Here we are interested to control the level of the tank - T3 because it is highly Chapter 3. Robust Granular Feedback Linearization 45
10
8
6
h (m ) 4
2
0 0 20 40 60 80 100
20
15 /s) 3 10 u (m 5
0 0 20 40 60 80 100
4
3
2 Clusers number
1 0 20 40 60 80 100 Tim e (s)
Figure 3.5 – RGFL controller tracking a triangular reference trajectory with EFL (blue line) and RGFL controller (green line), and unknown model with EFL (cyan line) and RGFL controller (red line). Reference trajectories 푟(푡) are plotted in black dashed line.
Table 3.1 – Performance indexes of the controllers methods.
푟(푡) System Method IAE ITAE # Rules BFOF 34.554 813.88 576 Nominal EFL 68.186 3589.4 - Model RGFL 10.861 518.63 5
Square Unknown EFL 511.34 25881 - Model RGFL 16.878 779.44 5 BFOF 52.930 1596.9 576 Nominal EFL 53.075 2570.2 - Model RGFL 8.8980 317.49 4 Unknown EFL 531.59 26759 - Saw-Tooth Model RGFL 14.551 618.25 4 BFOF 54.064 1789.8 576 Nominal EFL 54.584 2624.3 - Model RGFL 4.3849 112.44 4 Unknown EFL 479.77 24144 - Triangular Model RGFL 9.7100 330.95 4 nonlinear and complicated to be managed robustly. Tank T3 has a hard nonlinearity, as Figure 3.7 shows (Franco et al., 2016). Chapter 3. Robust Granular Feedback Linearization 46
Figure 3.6 – Actual surge tank system.
푞푖푛
70푐푚 ℎ
푞표푢푡 62푐푚
Figure 3.7 – Nonlinearity of the surge tank - T3.
The dynamics of the tank T3, determined experimentally, is: 17.1624푢 11.5228ℎ + 508.006 ℎ˙ = − (3.29) 퐴(ℎ) 퐴(ℎ) where ℎ ∈ [8, 70] is the level (푐푚), 푢 ∈ [0, 100] is the control signal sent to the pump (%), and 퐴(ℎ) is the cross-sectional area of the tank (푐푚2).
−(0.01(ℎ−8)−0.4)2 퐴(ℎ) = 1556.82 − 1349.1948 cos(2.5휋(0.01(ℎ − 8) − 0.4)푒 0.605 .
The experiments use the reference signal: ⎧ 3 ⎨⎪ℎ0(푖), if 0 ≤ 푡 ≤ 푖푡푠푡푒푝 푟(푡) = 4 ⎪ ℎ(푖+1)−ℎ(푖) 3 ⎩ 5 푡trans + ℎ0(푖), if 4 푖푡푠푡푒푝 < 푡 ≤ 푖푡푠푡푒푝 Chapter 3. Robust Granular Feedback Linearization 47
where 푖 = 1,..., 13 index a sequence of 13 values for setpoints, 푡푠푡푒푝 = 250푠 is the duration of each step, 푡trans ∈ [0,62]푠 is the transient time interval between setpoint values, and ℎ0 = [15 23 31 39 47 39 31 23 15 44 15 44 15] encode the 13 setpoint values. Two experiments were run using the EFL and the RGFL, and in both the nominal system (3.29) was used to compute control signals (2.2) and (3.6). The first experiment is performed under the same operating conditions as the ones assumed during the controllers design. In the second experiment, the tank output flow valve increases its flow 30%, but the models used to design the controllers remain the same as in the first experiment. Figures 3.8 and 3.9 show the results.
50 EFL RGFL 40
30
h(cm ) 20
10
0
80
70
60
50 u(%)
40
30
20
0 500 1000 1500 2000 2500 3000 3500 4000 Tim e (s)
Figure 3.8 – Surge tank level control: EFL (blue line) and RGFL (green line).
The state feedback controller is 푣푘 = −Ke푘 with gain K = 0.05, and the sampling time is 푇 = 1s. The parameters the ePL algorithm uses were chosen by trial and error following the guidelines found in (Lughofer, 2011, Chap. 3). All parameters values are in the range [0, 1]. Experimental evidence suggests to choose the Gaussian spread (훿푟) values about the same as the standard deviation of measurements, which in our case is ±2%. Thus, we set: 휉 = 0.05, 휗 = 0.0001, 휏 = 0.025, 휆 = 0.85, and 휎 = 0.02. The local RLS algorithm has forgetting factor 휁 = 0.98, and gain 퐾푝 = 0.04. A first order digital filter 푘 푘−1 푘 given by: ℎ푓 = 0.8ℎ푓 + 0.2ℎ is used to filter high frequency noise. By using Theorem 3.1, the LMIs (3.18) and (3.19) were solved by using the CVXOPT solver (Andersen et al., [︁ ]︁ [︁ ]︁ 2012, 2018) with 퐴푐 = −0.05 , 퐵푐 = −1 , 휏2 = 0.075, and 훿 = 1 and maximizing the value of 휛, that is, we are searching for the maximum output tracking error for which Theorem 3.1 ensures the robust stability of the controlled system. The optimal solution [︁ ]︁ found is 푃 = 0.0799 , 휛 = 85.35, and 휏1 = 6.40. Thus, we have a maximum error ≈ 32.66cm, which is much larger than what is achieved by the closed-loop system. Chapter 3. Robust Granular Feedback Linearization 48
50
40
30 h(cm ) 20
10 100
75
50 u(%)
25 RGFL EFL
3
2
1 Clusters Numbers 0 0 500 1000 1500 2000 2500 3000 3500 4000 Tim e (s)
Figure 3.9 – Surge tank level control: second experiment with EFL (blue line) and RGFL (green line).
Figure 3.8 gives a qualitative view of the result, and clearly shows that both RGFL and EFL controllers perform as expected. The output tracking error for this experiment reached the maximum absolute value of 2.7cm which is less than 10% of the maximum allowed error. Also note that, the maximum ePL error is required to be 푤푇 푤 ≤ 1. When the outflow of the surge tank is increased, Figure 3.9, the RGFL performs much better than EFL. Quantification of the performance of both controllers are done using normalized IAE and ITAE indexes: 퐼퐴퐸푥 퐼퐴퐸푛 = , 퐼퐴퐸푅퐺퐹 퐿
퐼푇 퐴퐸푥 퐼푇 퐴퐸푛 = , 퐼푇 퐴퐸푅퐺퐹 퐿 where 퐼퐴퐸푛 and 퐼푇 퐴퐸푛 are the normalized indexes, 퐼퐴퐸푥 and 퐼푇 퐴퐸푥 are the indexes of each controller: EFL or RGFL. Table 3.2 summarizes the results and assertss the superior performance of RGFL.
Table 3.2 – Performance indexes for the actual surge tank experiments.
Scenario Method 퐼퐴퐸푛 퐼푇 퐴퐸푛 # Rules EFL 2.55 3.24 - 1 RGFL 1 1 3 EFL 8.46 9.49 - 2 RGFL 1 1 3 Chapter 3. Robust Granular Feedback Linearization 49
3.3.3 Knee Joint Simulation Experiments
The focus of this section is on the control of the angular position of a knee joint using functional electrical stimulation – FES. Control of knee angle is a challenge for con- trol theoreticians, practitioners, and rehabilitation engineers, and is a major benchmark adopted by many authors (Davoodi and Andrews, 1998; Kirsch et al., 2017; Li et al., 2017; Previdi and Carpanzano, 2003). The dynamic of the knee joint can be modeled as an open kinematic chain composed of two rigid segments (Ferrarin and Pedotti, 2000): the thigh, and the shank/foot complex as shown in Figure 3.10.
V
Ta l
ɸ
Ɵ Ɵeq
mg
Figure 3.10 – The lower limb uses functional electrical stimulation of the quadriceps mus- cles to produce knee extension. The system uses electrodes in the surface of the thigh.
During FES stimulation the leg dynamics can be modeled as: ¨ 퐽휃 + 퐺 + 푇푠 = 푇푎 (3.30) where 퐽 is the inertial moment of the shank/foot complex, 휃, 휃,˙ 휃¨ ∈ R are the angular position, velocity, and acceleration of the shank-foot complex, 퐺 = 푚푔푙 sin(휃 + 휃푒푞) is the gravitational torque, 푚 is the mass of shank/foot complex, 푔 is the acceleration of the gravity, 푙 is the distance between the knee joint and the center of mass of the shank/foot complex, and 휃푒푞 is the equilibrium angle between the shank and the vertical axis. 푇푠 is the degenerative torque resulted from the stiffness and damping of the knee joint, and 푇푎 is the input of the system, that is, the torque produced by the quadriceps muscles due to the FES induced muscle contraction. Similarly as in previous studies (de Proen¸caet al., 2012; Franken et al., 1993; Giat et al., 1996; Mansour and Audu, 1986), the stiffness and the damping component is the exponential function depending of (휃 + 휃푒푞):
휋 (−퐸(휃+휃푒푞+ 2 )) ˙ 푇푠 = 휆푒 (휃 + 휃푒푞 − 휑) + 휔휃, (3.31) Chapter 3. Robust Granular Feedback Linearization 50 where 휆 and 퐸 are coefficients of the rigidity and damping components, 휑 is the elastic resting knee angle, and 휔 is the coefficient of the viscous friction. Note that all parameters needed to compute the degenerative torque have individualized values, and are unique for each patient. Moreover, as a patient recovers from an injury, these parameters are expected to change with the progress of the treatment. The FES input can be characterized by a first order transfer function (Ferrarin and Pedotti, 2000): 푇 (푠) 퐾 푎 = 푠 (3.32) 푃 (푠) 1 + 휂푠 with 푃 (푠) the electrical pulse signal caused by the voltage input (푉 ), 퐾푠 the static gain, and 휂 the time constant. Similarly as for degenerative torque parameters, the values of the static gain and the time constant are unique for each patient, as are pulse frequency and stimulation pattern (de Proen¸caet al., 2012; Peckham and Knutson, 2005). ˙ Let 푥1 = 휃 + 휃푒푞 be the angular position, 푥2 = 휃 the angular velocity, and 푥3 = 푇푎 be the torque necessary to move the leg. Pluging (3.31) and the inverse Laplace transform of (3.32) in (3.30) we get the following state space model of the lower limb:
⎡ ⎤ ⎡ ⎤ ⎡ ⎤ 푥˙ 1 푥2 0 ⎢ ⎥ ⎢ −퐸 푥 + 휋 ⎥ ⎢ ⎥ ⎢ ⎥ ⎢ 푥 −퐺(푥 )−휆푒 ( 1 2 )(푥 −휑)−휔푥 ⎥ ⎢ ⎥ ⎢푥˙ 2⎥ = ⎢ 3 1 1 2 ⎥ + ⎢ 0 ⎥ 푃, (3.33) ⎣ ⎦ ⎢ 퐽 ⎥ ⎣ ⎦ ⎣ −1 ⎦ −1 푥˙ 3 −휂 푥3 휂 퐾푠
푦 = 푥1. where 푦 is the output, and 푃 is the electrical pulse directed to quadriceps muscles to activate the knee. Here 푃 is the control input. The lower limb (3.33) is a nonlinear system that has the form shown in (2.1). Using the Euler approximation, the discrete lower limb model (3.33) becomes:
푘+1 ⎡ ⎤ ⎡ 푘 푘 ⎤ 푥1 푥1 + 푇 푥2 ⎢ ⎥ ⎢ [︁ (︁ )︁ (︁ )︁]︁⎥ ⎢ ⎥ ⎢ 푘 푇 푘 푘 푘 푘 ⎥ ⎢푥2⎥ = ⎢푥2 + 퐽 푥3 − 퐺 푥1 − 푇푠 푥1,푥2 ⎥ (3.34) ⎣ ⎦ ⎣ 푘 −1 [︁ 푘 푘]︁ ⎦ 푥3 푥3 + 푇 휂 퐾푠푃 − 푥3
푘 푘 From (3.34) and recalling that 푦 = 푥1, the Lie derivatives can be used to verify that the system own relative degree 푟 = 3. From the control law (2.2) and diffeomorphism (2.3) we can certify that the system is feedback linearizable2, which results in:
⎡ 푘 ⎤ 푥1 (︁ )︁ ⎢ ⎥ 푘 ⎢ 푘 ⎥ 푀 x = ⎢ 푥2 ⎥ , (3.35) ⎣ −1 [︁ 푘 (︁ 푘)︁ (︁ 푘 푘)︁]︁⎦ 퐽 푥3 − 퐺 푥1 − 푇푠 푥1,푥2
2The specific structural properties to allow feedback linearization are detailed in (Khalil, 2002, Cap. 13). Chapter 3. Robust Granular Feedback Linearization 51
(︁ 푘)︁ −1 훽 x = 퐽휂퐾푠 , (3.36)
(︁ )︁ 휂 [︂ [︂ 휋 푘 (︁ )︁ (︁ )︁]︂ 푘 푘 −퐸( 2 +푥1 ) 푘 푘 푘 훼 x = 푥2 휆푒 + 퐺 푥1 + 푇푠 푥1,푥2 + 퐾푠 ]︃ (3.37) 푥푘 휔 [︁ (︁ )︁ (︁ )︁]︁ 3 + 푥푘 − 퐺 푥푘 − 푇 푥푘,푥푘 , 휂 퐽 3 1 푠 1 2
The parameters of the model are: 퐽 = 0.362 [푘푔 · 푚2], 푚 = 4.37 [푘푔], 푙 = 0.238 [푚], 퐵 = 0.27 [푁 · 푚 · 푠/푟푎푑], 휆 = 41.208 [푁 · 푚/푟푎푑], 퐸 = 2.024 [푟푎푑−1], 휔 = 2.918
[푟푎푑], 휂 = 0.951 [푠], and 퐾푠 = 42500 [푁 · 푚/푠]. These parameters values are those obtained from the anthropometric characteristics measured from a patient by Ferrarin and Pedotti (2000). Simulation was conducted to evaluate RGFL to regulate the knee angle in different reference positions, as suggested in (Kirsch et al., 2017). The references are 푟(푡) = 60표, 0 ≤ 푡 < 5, 푟(푡) = 20표, 5 ≤ 푡 < 10, and 푟(푡) = 40표, 10 ≤ 푡 ≤ 15. The sampling time is 푇 = 0.001 [푠], which is short enough to approximate reasonably well the continuous dynamics of the lower limb model. We also assume that the model (3.33) has imprecise parameters and neglected dynamics. More precisely, we assume that the mass of shank-foot complex and the degenerative torque are in error of 7.5%, 15% and −5%, respectively, with respect to the nominal values, which means that 푚푢 = 1.075푚 and 푘 휋 (−퐸(푥1 + 2 )) 푘 푘 푘 푇푠푢 = 1.15휆푒 [푥1 − 휑] + 0.95휔푥2. Additionally, we consider that the state 푥3 is disturbed by an unmodeled signal 푑푘 whose value is uniformly distributed [−0.02, 0.02]. Disturbance 푑푘 induces a fatigue effect into the lower limb model. [︁ ]︁ The feedback gain of the linear closed-loop was set as 퐾 = 251.975 61.68 7.9 . The ePL parameters are: 휉 = 0.002, 휗 = 0.001, 휏 = 0.01, 휆 = 0.875, and 휎 = 0.02, chosen as suggested by (Lughofer, 2011, Cap. 4). Local linear models of the fuzzy functional rules of ePL are updated using the RLS algorithm with forgetting factor 휁 = 0.98 and gain
퐾푝 = 0.13. A fuzzy functional Takagi-Sugeno (TS) controller was also designed following (Gaino et al., 2017).
The optimization model (3.22) was solved with 휈 = 50 for 휏2 ∈ [0.05, 2.10]. The 휈 value was chosen as the maximal tracking error assumed for the closed-loop system. √︁ The volume of the estimate region of attraction is proportional to 1/ det(푃 ). Figure √︁ 3.11 shows the values of 휖0 and Vol(푃 ) = 1/ det(푃 ) as a function of 휏2. The maximal allowed bound ePL error is achieved at 휏2 = 1.50 indicating the optimal convergence rate to maximize the acceptable ePL errors (휖0 = 955). On the other hand, the volume of the estimated region of attraction reduces as 휏2 increases. Once the stability bounds are found, four simulations were performed. The results are shown in Figure 3.12: the nominal exact lower limb model with EFL control is depicted in continuous cyan line, the uncertain model with EFL control is shown by the continuous Chapter 3. Robust Granular Feedback Linearization 52
√︁ Figure 3.11 – Maximal square bound of ePL error 휖0 (left axis), and Vol(푃 ) = 1/ det(푃 ) (right axis) for given values of 휏2 (guaranteed exponential convergence of the tracking error, e). red line, the uncertain model with TS fuzzy control is shown by the dashed green line, and the uncertain model with RGFL control depicted by the dotted-dashed blue line. The dashed black line is the reference signal 푟(푡). As we can note, the maximum tracking error occurs at the initial step, within the bound 휈 = 50. Figure 3.12 gives a qualitative overview of the behavior of the controllers. Under ideal situations, that is, when the model used during design fits perfectly the lower limb of the patient, the EFL behaves as intended (continuous cyan line) and is successful. However, when the lower limb model used in design differs from the actual system, the behavior of the closed-loop depends on the control approach. We see that the EFL (contin- uous red line) and TS Fuzzy controller (dashed green line) show an offset error during the simulation period. Contrary to EFL and TS control, RGFL controller (dotted-dashed blue line) behaves closely to the ideal case. The price paid by RGFL to surpass EFL and TS controllers is a small increase in the torque to banish the offset error. The ePL algorithm developed six fuzzy rules, as the lower part of Figure 3.13 shows. It is interesting to notice the adaptation nature of RGFL by looking at the first 1.5 [푠] when the algorithm develops five fuzzy rules. The adaptation in such a period occurs because of the angular position changes quickly, and the ePL is learning from the lower limb states model, as the upper part of Figure 3.13 shows. At 2.0 [푠], the algorithm has learned enough to eliminate one rule and keep canceling the current nonlinear effects. Next, when the reference changes from 60표 to 20표, two new rules are created to counteract for the corresponding nonlinear changes. Overall, RGFL control needs at most six fuzzy rules to ensure performance for all ranges of knee joint angles. Chapter 3. Robust Granular Feedback Linearization 53
Figure 3.12 – Behavior of closed-loop system with: nominal model using EFL (continuous cyan line), actual system using EFL (continuous red line), TS Fuzzy con- troller (dashed green line), RGFL (dotted-dashed blue line), and reference (dashed black line).
Table 3.3 – Min and Max Values to normalize the ePL algorithm input.
푥1 푥2 푥3 푒1
푥max푖 휋/2 0.325 15 휋/4
푥min푖 0 −0.325 0 −휋/4
The illustrative video shows how the evolving participatory learning works, and how robust granular feedback linearization behaves. The video exhibits the knee position and the active fuzzy rules at each time step. We remark the following: 1) the input of the fuzzy rules z at each step 푘 is composed by the state vector and the tracking error, 4 and hence z ∈ R , but the video displays states 푧1 and 푧4 only. 2) The vector z ∈ [0,1] is normalized using:
푥푘 − 푥 푧푘 = 푖 min푖 푖 = 1, ··· , 4 (3.38) 푑푖 푥max푖 − 푥min푖 with the minimum and maximum values given in the Table 3.3. Because the tracking error can be either negative or positive, the normalized error is null for 푧4 = 0.5. 3) The zone of influence (spread) of the 푖-th fuzzy rule is constant and chosen by the designer when the value of 휎 is specified. Note that all rules may contribute to produce an output at each step, and that ePL only updates the most compatible rule, or equivalently, the most Chapter 3. Robust Granular Feedback Linearization 54
Figure 3.13 – Number of fuzzy rules built by the RGFL controller to control the angular position of the knee.
Table 3.4 – Performance indexes of the controllers. IAE ITAE RMSE IVU 퐸퐹 퐿푛 1.0485 4.4537 0.1698 0.1538 EFL 2.3959 16.080 0.1964 0.1531 TS 2.0326 12.799 0.1768 0.1871 RGFL 1.0350 4.8150 0.1604 0.1559
푘 compatible cluster at each step. The video shows the updates of the cluster centers v푠 as in (2.26). To quantify and to compare the performance of RGFL controller with EFL and TS Fuzzy controllers we measure the integral of absolute error – IAE, integral of time- weighted absolute error – ITAE, and root mean square error – RMSE, and integral of time-weighted variability of the signal control – IVU. Computation of values of IAE, ITAE, RMSE, and IVU follows (Oliveira et al., 2017). Table 3.4 summarizes the results. The performance of RGFL is noticeably superior to EFL and TS Fuzzy controllers, and its behavior is the closest to the ideal performance of EFL under the nominal system, denoted 퐸퐹 퐿푛 in Table 3.4.
3.3.4 Evaluation of RGFL Control with Evolving Takagi-Sugeno Modeling
This section evaluates the behavior and performance of the RGFL controller when ePL modeling is replaced the eTS modeling algorithm of Section 2.2.1. The eTS modeling is detailed in Algorithm 3.2. Several MODIFY and UPGRADE conditions were used to evaluate the eTS algo- rithm. These conditions were suggested in the literature as C1- (Angelov and Filev, 2004), C2- (Ramos and Dourado, 2003), and C3- (Angelov et al., 2004a), and are summarized Chapter 3. Robust Granular Feedback Linearization 55
푘 Algorithm 3.2 Compute of 푢^푐 using the eTS algorithm. 1: Input: z푘 ∈ [0,1]푛, 푘 = 1, ··· 푘 2: Output: 푢^푐 3: Choose the parameters 퐾푝 and 휎 4: Set the first input data as the first focal point 5: while 푘 ≤ ∞ do 6: z푘 ← Read new data 푘 7: Compute potential 푃z using (2.19) 8: for 푖 = 1 to 푐푘 do 푘 9: Compute potential 푃 * using (2.21) x푖 10: if MODIFY condition holds then *푘 푘 11: x푠 ← x 12: else if UPGRADE condition holds then *푘 푘 13: x푐푘+1 ← x 14: else 15: Ignore input data 16: end if 17: end for 18: for 푖 = 1 to 푐푘 do 푘 19: Compute activation degree 휇푖 using (2.22) 20: end for 21: Compute estimate 푤^푘 using (3.10) 푘 22: Compute control signal 푢^푐 using (3.6) 23: Update the counter: 푘 = 푘 + 1 푘 24: Return 푢^푐 25: end while in Table 3.5.
Table 3.5 – Modify and Upgrade conditions of eTS algorithm.
Source Scenario UPGRADE Condition MODIFY Condition * * * 푑푚푖푛 푃 C1 A 푃푧 > 0.5푃 푃푧 > 0.15푃 푎푛푑 + < 1 푟 푃푧 * 푑푚푖푛 푃 B 푃푧 > 푃푚 푃푧 > 푃푚 푎푛푑 푟 + 푃 < 1 C2 *푧 * * 푑푚푖푛 푃 C 푃푧 > 푃 푃푧 > 푃 푎푛푑 + < 1 푟 푃푧 * * 푑푚푖푛 D 푃푧 > 푃 푃푧 > 푃 푎푛푑 푟 < 0.5 * * * * * * 푑푚푖푛 C3 E 푃푧 > 푃 표푟 0.5푃 < 푃푧 < 0.675푃 (푃푧 > 푃 표푟 0.5푃 < 푃푧 < 0.675푃 ) 푎푛푑 푟 < 0.5 * * 푑푚푖푛 F 푃푧 > 푃 표푟 푃푧 < 푃* (푃푧 > 푃 표푟 푃푧 < 푃*) 푎푛푑 푟 < 0.5 * * 푑푚푖푛 푑푚푖푛 G 푃푧 > 푃 표푟 푃푧 < 푃* (푃푧 > 푃 푎푛푑 푟 < 0.5) 표푟 (푃푧 < 푃* 푎푛푑 푟 < 0.85)
RGFL with the eTS algorithm was evaluated using an inverted pendulum as con- sidered by many authors (Slotine and Li, 1991; Wang, 1994; Park et al., 2003) to access adaptive feedback linearization control approaches. The inverted pendulum is shown in Figure 3.14. Chapter 3. Robust Granular Feedback Linearization 56
˙ 푥2 = 휃
푥1 = 휃
푙
푢
Figure 3.14 – Inverted Pendulum.
The dynamics of the inverted pendulum is:
푥˙ 1 = 푥2 푚푙푥2 cos 푥 sin 푥 −cos 푥 푢 푔 sin 푥 − 2 1 1 1 (3.39) 1 푚푐+푚 푥˙ 2 = 2 푙(4/3 − 푚 cos 푥1 ) 푚푐+푚 ˙ where 푥1 = 휃 [푟푎푑] is the angle with the vertical axis, 푥2 = 휃 [푟푎푑/푠] is the angular speed, 2 푔 = 9.8푚/푠 is the gravity acceleration, 푚푐 [퐾푔] is the cart mass, 푚 [퐾푔] is the pole mass, 푙 [푚] is the pole half-length, and 푢 [푁] is control input. The inverted pendulum is an instance of (2.1), with the diffeomorphism (2.3) [︁ ]︁푇 푀(x) = 푥1 푥2 . The control law (2.2) in discrete form is:
푘 1 [︁ 푘 푘 푘 푘]︁ 푢푒 = 푘 푣 − 푓푛(x ) − 푔푛(x )푢푟 , (3.40) 푔푛(x ) with 2 푚푙 cos 푥푘 sin 푥푘(푥푘) 푔 sin 푥푘 − 1 1 2 푘 1 푚푐+푚 푓푛(x ) = , (︂ 푚 cos2 푥푘 )︂ 푙 4/3 − 1 푚푐+푚
푘 푘 cos 푥1 푔푛(x ) = , (︂ 푚 cos2 푥푘 )︂ 푙(푚 + 푚) 4/3 − 1 푐 푚푐+푚
(푛) 푘 푘 푟 − 푓푛(r ) 푢푟 = 푘 . 푔푛(r ) Simulations use the discrete form of the pendulum model:
푘+1 푘 푘 푥1 = 푥1 + 푇 푥2 (3.41) 푘+1 푘 [︁ 푘 푘 푘]︁ 푥2 = 푥2 + 푇 푓(x ) + 푔(x )푢 where 푇 is the sampling time. Functions 푓(x푘) and 푔(x푘) are considered imprecise because we assume that the parameters are 푚 = 푚푛(1+휍0) and 푙 = 푙푛(1+휍1), where 푚푛 and 푙푛 are the nominal values, and 휍푖 are uncertain deviations. The nominal parameters were chosen as suggested by Park et al. (2003), namely: 푚푐 = 1 푘푔, 푚푛 = 0.1 푘푔 and 푙푛 = 0.5 푚. Chapter 3. Robust Granular Feedback Linearization 57
휋 The reference signal to be tracked is 푟(푡) = 30 sin(푡). The state feedback gain is set as [︁ ]︁ K = 2 1 . Gaussian function consider spreads 휎 = 0.3, 0.4, or 0.5. Two scenarios were considered in the simulations experiments. The first scenario considers the ideal, precise modeling with no uncertainty. The second scenario assumes that parameters 푚 and 푙 have deviations 휍0 = −0.2 and 휍1 = −0.15, respectively. The results for 휎 = 0.3 are shown in Figure 3.15: EFL controller (blue dashed line), RGFL controller using eTS algorithm and condition A and C (red continuous line), with D and E (green dash-dotted line), B (grey dotted line), and with conditions F and G (black continuous line). The reference signal is shown the black dashed line.