• Nenhum resultado encontrado

Satisficing infinite-horizon model predictive control

N/A
N/A
Protected

Academic year: 2021

Share "Satisficing infinite-horizon model predictive control"

Copied!
98
0
0

Texto

(1)

SATISFICING INFINITE-HORIZON MODEL PREDICTIVE CONTROL

Dissertation presented to the Grad-uate Program in Automation and Systems Engineering in partial ful-fillment of the requirements for the degree of Master in Automation and Systems Engineering.

Advisor: Prof. Eduardo Camponogara, Dr. Co-advisor: Marcelo Lopes de Lima, Dr.

Florian´opolis 2019

(2)

Benetti, Bruno Eduardo

Satisficing Infinite-Horzion Model Predictive Control / Bruno Eduardo Benetti ; orientador, Eduardo Camponogara Camponogara, coorientador, Marcelo Lopes de Lima Lima, 2019.

98 p.

Dissertação (mestrado) - Universidade Federal de Santa Catarina, Centro Tecnológico, Programa de Pós Graduação em Engenharia de Automação e Sistemas, Florianópolis, 2019.

Inclui referências.

1. Engenharia de Automação e Sistemas. 2. MPC. 3. Satisficing MPC. 4. Infinite Horizon MPC. I.

Camponogara, Eduardo Camponogara. II. Lima, Marcelo Lopes de Lima. III. Universidade Federal de Santa Catarina. Programa de Pós-Graduação em Engenharia de Automação e Sistemas. IV. Título.

(3)
(4)

SATISFICING INFINITE-HORIZON MODEL PREDICTIVE CONTROL This Dissertation is recommended in partial fulfillment of the require-ments for the degree of “Master in Automation and Systems Engineer-ing”, which has been approved in its present form by the Graduate Program in Automation and Systems Engineering.

Florian´opolis, March 13th 2019.

Prof. Werner Kraus Junior, Dr. Graduate Program Coordinator Universidade Federal de Santa Catarina Dissertation Committee:

Prof. Eduardo Camponogara, Dr. Advisor

Universidade Federal de Santa Catarina

Hector Silveira, Dr.

Universidade Federal de Santa Catarina

Gustavo de Andrade, Dr. Universidade Federal de Santa Catarina

Paulo Mendes, Dr.

(5)

Primeiramente, gostaria de agradecer `a minha fam´ılia pelo suporte nos 3 anos de desenvolvimento deste trabalho. Entre idas e vindas, problemas que se postaram no meio do caminho e pensamentos de desistˆencia, eles nunca hesitaram em sacrificar o tempo deles para que eu tivesse o tempo necess´ario para finalizar este ciclo. Tempo ´e o recurso mais precioso que temos em nossa vida.

Em segundo lugar, gostaria de agradecer ao meu orientador Prof. Eduardo Camponogara, que trabalhando juntos desde 2011 ´e prati-camente parte da fam´ılia. Muito obrigado professor por acreditar na minha capacidade e nunca duvidar que seria poss´ıvel desenvolvermos um bom trabalho apesar das dificuldades. Confian¸ca ´e o melhor pre-sente que se pode dar. Tamb´em gostaria de agradecer ao meu coorien-tador Marcelo Lopes de Lima e aos integrantes do Grupo de Otimiza¸c˜ao e Sistemas (Camponog’s Army) pelas longas conversas que tivemos ao longo desses anos e que renovaram minha motiva¸c˜ao e f´e nos trabalhos acadˆemicos. Saber que vocˆe n˜ao ´e o ´unico a enfrentar este problema torna mais f´acil acreditar que ele tem solu¸c˜ao.

Por ´ultimo gostaria de agradecer a todas as pessoas que me fiz-eram evoluir nesse per´ıodo tanto profissionalmente, academicamente e principalmente pessoalmente. Entre amigos, colegas, professores e in´umeros outros que me fizeram questionar o que eu realmente queria como ideal de vida. N´os somos o produto de uma evolu¸c˜ao constante que acontece em cada intera¸c˜ao que temos durante a vida, o Bruno de hoje ´e muito melhor gra¸cas a vocˆes. N˜ao menos, gostaria de agradecer `a Petrobr´as e ao CNPq por terem financiado grande parte deste trabalho.

(6)
(7)

Introdu¸c˜ao

O controle preditivo baseado em modelo (MPC) ´e uma das pou-cas t´ecnicas de controle avan¸cado que teve um impacto significativo no controle de processos industriais. Em termos simples, o MPC converte um problema de otimiza¸c˜ao dinˆamica em uma sequˆencia de problemas de otimiza¸c˜ao est´atica, de tal forma que se torna poss´ıvel usar algorit-mos de otimiza¸c˜ao convexa padr˜ao. Esses problemas s˜ao resolvidos em tempo real para garantir que o controle seja calculado a cada passo de amostragem.

A estrat´egia de controle do MPC ´e baseada na solu¸c˜ao de um problema de otimiza¸c˜ao em tempo real para calcular o sinal de controle. Ele leva em conta o estado atual do sistema, poss´ıveis perturba¸c˜oes que podem afetar o processo e restri¸c˜oes que garantem a integridade do sistema.

Sistemas geograficamente distribu´ıdos s˜ao formados a partir da interconex˜ao de v´arios subsistemas dinˆamicos acoplados. H´a muitos exemplos desses sistemas, como usinas de energia, redes de controle de tr´afego urbano, plantas petroqu´ımicas e qu´ımicas. Esse tipo de sistema ´e composto de diversos subsistemas que podem influenciar uns aos outros. Por exemplo, o fluxo de massa que sai de um reator qu´ımico ´e o fluxo de entrada para um tanque. Esse acoplamento pode ser modelado como equa¸c˜oes dinˆamicas ou mesmo restri¸c˜oes alg´ebricas, como conserva¸c˜ao de massa ou energia.

Para esses sistemas, geralmente h´a duas op¸c˜oes de controle: im-plantar v´arios controladores PID SISO ignorando os acoplamentos de subsistemas ou usar uma t´ecnica de controle avan¸cada que possa levar em conta esses aspectos. Neste ´ultimo, a t´ecnica de controle avan¸cado mais utilizada ´e o MPC. Ao usar controladores SISO, todos os efeitos que um sistema pode causar em outros s˜ao considerados perturba¸c˜oes. Geralmente, os controladores PID s˜ao capazes de rejeitar esse tipo de perturba¸c˜ao, no entanto, o benef´ıcio que o MPC pode trazer ´e aproveitar o acoplamento e us´a-lo para melhorar seu desempenho.

Apesar de todos esses aspectos, existem alguns problemas relacio-nados `as limita¸c˜oes do MPC no ambiente industrial. Um dos problemas ´e o processo de ajuste: tipicamente, os engenheiros de processo definem pesos para cada objetivo, um para cada subsistema, que s˜ao combina-dos em uma fun¸c˜ao objetivo global a ser minimizada pelo controlador. Tal abordagem ´e conhecida como sintonia categ´orica porque, uma vez definidos, os pesos ser˜ao sempre os mesmos. Isso pode causar algumas

(8)

Em particular, Lima [16] propˆos uma abordagem de controle preditivo de satisfa¸c˜ao distribu´ıda que fornece uma sintoniza¸c˜ao au-tom´atica, conhecida como sintonia situacional. Essa nova abordagem n˜ao usa pesos para compensar os objetivos locais, mas estabelece uma regi˜ao satisfat´oria para cada subsistema, de modo que o controlador deve procurar uma solu¸c˜ao que seja satisfat´oria para todos os subsiste-mas. Em particular, o centro anal´ıtico da interse¸c˜ao de todas as regi˜oes satisfat´orias ´e uma solu¸c˜ao para o problema que tem uma propriedade desej´avel. Nomeadamente, os multiplicadores de Lagrange associados a esta solu¸c˜ao definem pesos para os subproblemas locais dependen-tes do estado e que conduzem a uma estrat´egia para a sintoniza¸c˜ao autom´atica.

Por outro lado, a abordagem de controle satisfat´orio requer o uso de algoritmos complexos de ponto-interior, que podem ser compu-tacionalmente onerosos e potencialmente sens´ıveis aos parˆametros de entrada. Para este fim, esta disserta¸c˜ao prop˜oe uma abordagem pr´atica para o controle satisfat´orio que se baseia em algoritmos de otimiza¸c˜ao robustos. Al´em disso, pretende-se explorar profundamente a estabili-dade do MPC satisfat´orio, a fim de garantir sua aplicabilidade em am-bientes industriais pr´aticos. Para conseguir isso, o Modelo de Predi¸c˜ao Orientado `a Predi¸c˜ao de Sa´ıda (OPOM) ser´a integrado `a abordagem, resultando em uma estrutura MPC satisfat´oria de horizonte infinito que garantir´a estabilidade com uma nova fun¸c˜ao objetivo.

Objetivos

O objetivo principal da disserta¸c˜ao ´e contribuir para o desen-volvimento do Controle Preditivo baseado em Modelo Satisfat´orio de Horizonte Infinito como uma op¸c˜ao no controle de processos industri-ais.

Metodologia

Para realizar o desenvolvimento deste novo controlador ´e ne-cess´ario, primeiramente, conhecer as bases te´oricas por tr´as das al-ternativas escolhidas: teoria de sistemas lineares, otimiza¸c˜ao e MPC neste caso. Para tanto o trabalho provˆe a fundamenta¸c˜ao necess´aria nestas ´areas para o entendimento posterior do leitor. Constru´ıdas as bases, passa-se para a elabora¸c˜ao de uma estrat´egia de controle pre-ditivo com horizonte infinito, atrav´es da sua implementa¸c˜ao em

(9)

soft-de um algoritmo para realizar a convers˜ao de um sistema que esteja como fun¸c˜ao de transferˆencia para o modelo OPOM. De posse dos resultados de simula¸c˜oes, j´a ´e poss´ıvel comparar a performance de diversas sintonias diferentes do mesmo controlador. Parte-se ent˜ao para a implementa¸c˜ao de uma sintonia satisfat´oria autom´atica para a finaliza¸c˜ao do controlador. Obtidos os resultados finais ´e realizada uma avalia¸c˜ao dos mesmos.

Resultados e Discuss˜ao

Os resultados apresentados mostram que a escolha pelo SIHMPC frente a modelos tradicionais de MPC traz diversos benef´ıcios para o projetista. Primeiramente existe a suposta garantia de estabilidade provida pelo horizonte infinito de predi¸c˜ao, al´em da simplifica¸c˜ao das restri¸c˜oes de estabilidade que podem ser impostas pelo processo. Em se-gundo lugar, o uso de sintonia satisfat´oria livra o operador/projetista de v´arias horas de sintonia do sistema, bastando fornecer ao sistema dados reais das limita¸c˜oes do processo. Al´em do mais, o uso da modelagem OPOM ao sistema provou ser ´util tamb´em do ponto de vista de an´alise do sistema em tempo real, fornecendo vari´aveis de monitoramento do regime transit´orio do processo, assim como prevˆe os alvos de regime permanente antes do tempo normal.

Considera¸c˜oes Finais

A elabora¸c˜ao do controlador SIHMPC ´e um passo na dire¸c˜ao de alternativas vi´aveis para uso na pr´atica de t´ecnicas de controle avan¸cado. O intuito ´e com o rompimento das barreiras que existem en-tre a academia e a ind´ustria na gera¸c˜ao de tecnologia, implementando fundamentos te´oricos atuais para atualizar um processo de controle MPC cl´assico. Os trabalhos futuros buscar˜ao simplificar o emprego do controle SIHMPC em um ambiente pr´atico e real, como uma solu¸c˜ao para os problemas encontrados.

Palavras-chave: Model Predictive Control. Inifinite-Horizon Con-trol. Satisficing MPC.

(10)
(11)

This work aims to give an alternative formulation for Model Pre-dictive Controllers that simplifies the implementation of stability con-ditions and accommodates conflicting objectives. Stability guarantees are ensured by means of an infinite prediction horizon, which takes into account the whole system dynamics until the end of time. Fur-ther, the Output Prediction Oriented Model (OPOM) is proposed as a suitable prediction model for the infinite horizon MPC (IHMPC), deliv-ering a system representation with a clear physical meaning that eases the implementation of stability guarantees. Besides, the controller is augmented with a Satisficing tuning strategy that bring about dynam-ical weights for the system objectives, relieving the operator from the burden of choosing one out of many Pareto-optimal solutions. The in-herited convergence of IHMPC and the satisficing theory give rise to the Satisficing Infinite Horizon Model Predictive Controller, or SIHMPC, which is presented hereafter from its development to simulations.

Keywords: Model Predictive Control. Inifinite-Horizon Control. Sat-isficing Theory. OPOM.

(12)
(13)

1 Introduction 15

1.1 Dissertation Goals . . . 17

1.1.1 Specifc Goals . . . 17

1.2 Dissertation Structure . . . 17

2 Background on Control and Optimization 19 2.1 Dynamic Systems Modeling and Control . . . 19

2.1.1 Output of a system . . . 20

2.1.2 Impulse response . . . 23

2.1.3 Dirac impulse . . . 25

2.1.4 Using the impulse response . . . 27

2.1.5 Transfer Function Models . . . 28

2.1.6 Step Response . . . 30 2.2 Introduction to Optmization . . . 31 2.2.1 Unconstrained Optimization . . . 32 2.2.1.1 Algorithms . . . 32 2.2.2 Constrained optimization . . . 34 2.2.2.1 Algorithms . . . 35

2.2.3 Sequential Quadratic Programming (SQP) . . 38

2.2.3.1 Local Method . . . 38

2.2.3.2 Global Methods . . . 39

2.3 Model Predictive Control . . . 41

2.3.1 MPC strategy . . . 41 2.3.2 MPC elements . . . 42 2.3.2.1 Prediction model . . . 42 2.3.2.2 Disturbance model . . . 43 2.3.2.3 Objective function . . . 43 2.3.2.4 Constraints . . . 43

2.3.2.5 Solving the optimization problem . . 43

2.4 Summary . . . 44

3 Infinite Horizon MPC Strategies 45 3.1 Limitations of Standard MPC . . . 45

3.1.1 Chapter contents . . . 47

3.2 OPOM . . . 48

3.2.1 Example . . . 50

3.2.2 OPOM Extra Cases . . . 52

3.2.3 OPOM Simulation . . . 52

3.3 A simple MPC using OPOM . . . 53

(14)

3.4 Infinite-Horizon MPC . . . 59

3.4.1 Transforming the infinite horizon into a finite one . . . 61

3.4.2 IHMPC with OPOM . . . 64

3.4.3 OPOM IHMPC Simulations . . . 65

3.5 Satisficing MPC . . . 69 3.6 Summary . . . 78 4 Satisficing Infinite-Horizon MPC 81 4.1 Control Strategy . . . 81 4.1.1 Prediction Model . . . 81 4.1.2 Infinite Horizon . . . 82 4.1.2.1 Slack Variables . . . 83 4.1.3 Satisficing tuning . . . 84 4.2 Illustrative Examples . . . 85 4.2.1 SISO System . . . 85 4.2.2 MIMO System . . . 87

4.2.3 Maximum Cost Negotiation . . . 91

4.3 Summary . . . 93

5 Conclusion 95

(15)

Your work is going to fill a large part of your life, and the only way to be truly satisfied is to do what you believe is great work. And the only way to do great work is to love what you do.

Steve Jobs

Model predictive control (MPC) is one of the few advanced control techniques that has had a significant impact on industrial process control. In simple terms, MPC converts a dynamic optimiza-tion problem into a sequence of static optimizaoptimiza-tion problems, in such a way that it becomes possible to use standard convex opti-mization algorithms. These problems are solved online to ensure that the control will be calculated at each sample time.

The MPC control strategy is based on solving a real-time op-timization problem in order to calculate the control signal. It takes into account the systems current state, possible disturbances that may affect the process, and constraints that ensure the system in-tegrity [1].

Geographically distributed systems are made from the inter-conection of various coupled dynamical subsystems as ilustrated in Figure 1.1, where the arrows conecting the subsystems represent the coupling among them. There are many examples of these sys-tems such as power plants, urban traffic control networks, petro-chemical and petro-chemical plants.

System 1 System 2 System 3 System 4 Input Output

Figure 1.1: Diagram of a geographically distributed system.

(16)

This kind of system is made of many subsytems that will influ-ence one another. For example the mass flow that exits a chemical reactor is the input flow to a tank. This coupling can be modeled as dynamical equations or even algebraic constraints like mass or energy conservation.

For those systems, there are usually two options for control: deploy many SISO1 PID controllers ignoring the subsystems cou-plings or use an advanced control technique that can take into ac-count these aspects. In the latter, the most used advanced control technique is MPC. When using SISO controllers, all the effects that one system can cause to each other are considered as disturbances. Usually, PID controllers are able to reject this kind of disturbance, however, the benefit that MPC can bring about is to take advantage of the coupling and use it to enhance its performance.

Despite all these aspects, there are some problems related to the limitations of MPC in the industrial environment. One of the problems is the procedure of tuning: tipically process engineers de-fine weights to each goal, one for each subsystem, that are com-bined into a global objective function to be minimized by the con-troller. Such an approach is known as categoric tuning because, once defined, the weights will be used there after. This can cause some difficulties and may compromise the task of searching for adequate weights that are suited for all the operational conditions.

In [2] Lima proposed a distributed satisficing predictive con-trol approach that delivers an automatic tuning, known as situta-tional tuning. This novel approach does not use weights to trade off local goals, but rather it estabilishes a satisficing region to each subsystem so that the controller should search for a solution that is satisfactory for all the subsystems. In particular, the analytical cen-ter of the incen-tersection of all satisfactory regions is a solution to the problem that has a desirable property [3]. Namely, the Lagrangian multipliers associated to this solution define weights for the local subproblems that are state dependent and which lead to a strategy for automatic tuning.

On the other hand, the satisficing control approach requires the use of complex interior-point algorithms that can be computa-tionally expensive and potentially sensitive to input parameters. To this end, this dissertation proposes a practical approach for satisfic-ing that relies on robust optimization algorithms. Besides that, it is intended to explore deeply the stability of satisficing MPC in order

(17)

to guarantee its aplicability in pratical industrial settings. To achieve this, the Output Prediction Oriented Model (OPOM) [4] will be inte-grated into the baseline approach, resulting into an infinite-horizon satisficing MPC framework that will ensure stability with a new ob-jective function.

1.1 DISSERTATION GOALS

The main goal of the dissertation is to contribute to the devel-opment of the Satisficing Infinite-Horizon Model Predictive Control as an option in industrial process control.

1.1.1 Specifc Goals

\bullet Present the theoretical development of the Satisficing infinite-horizon model predictive control.

\bullet Present how to integrate these approaches into a three-in-one MPC solution.

1.2 DISSERTATION STRUCTURE

This dissertation is structured in the following way: chapter 2 gives the necessary background on control theory and optimiza-tion; chapter 3 gives the background on the Output Prection Ori-ented Model as a prediction model, infinite-horizon MPC and sat-isficing MPC; chapter 4 defines the satsat-isficing infinite-horizon MPC and gives an illustrative example; chapter 5 makes a conclusion to the work.

(18)
(19)

God used beautiful mathematics in creating the world. Paul Dirac

This chapter presents the necessary background on control theory and convex optimization in order to understand the work developed in this dissertation. It is assumed that the reader has deep knowledge of calculus and linear algebra.

The chapter also reviews the basics of standard MPC control. The focus of the optimization review is on quadratic programming and the methods for convex optimization.

A reader with background on linear signal and systems theroy, optimization and model predictive control may skip this chapter. 2.1 DYNAMIC SYSTEMS MODELING AND CONTROL

Dynamic systems are systems that have inputs and outputs, and their outputs depend on the inputs and also on the internal state of the system. Some simple examples are electric circuits and spring mass systems.

Control engineering is based on modeling reality as dynamic systems, so that a mathmatical model is obtained, which makes pos-sible the control of the system.

Usually, a dynamic system is modeled by a differential equa-tion that describes the relaequa-tion between its inputs and outputs. The control science bases itself in finding functions such that when given as an input to the system will generate a desired output. The input and output function of a system are generally called signals.

There are many important characteristics about dynamic sys-tems, for example linearity, time invariance and causality. A system is said to be linear if it satisfies two conditions, homogeneity and adictivity, explained as follows:

\bullet Adictivity: given the same initial conditions, for every two dif-ferent inputs I1and I2that produce outputs O1 and O2, when combined I1+ I2 will result in an output O1+ O2.

\bullet Homogeneity: given the same initial conditions, it needs to be invariant to a scalar gain, in other words, if you input \alpha I1the output is \alpha O1, where \alpha is a real number.

A system is said to be time invariant if its output is only de-pendent on its internal state and input, indede-pendently of when they

(20)

are applied. A causal system (also known as a physical or nonantic-ipative system) is a system where the output depends on past and current inputs but not on future inputs.

Many tools have been developed since the begining of this science in order to make systematic the process of calculating these input functions. These tools are used to many objectives such as finding a model to a system and calculating a control law for it. The aplicability of a tool may vary depending on the system, some require linearity, for example, while others can be used to non-linear systems.

2.1.1 Output of a system

This subsection focuses on how one can calculate the output of a linear time-invariant causal system.

For linear systems, the output can be divided into the sum of the zero input response and the zero state response. The zero input response is the output produced by the system with no input, which is the response to the internal state of the system. The zero state response, on the other hand, is the output produced by the system considering only the input, consequently ignoring the internal state of the system.

Consider the following differential equation that represents a generic linear system:

dy(t)

dt + y(t) + 10 = u(t) (2.1)

y(0) = 2

where y(t) is considered the output of the system and u(t) is the input. One can solve this differential equation in order to calculate the output for a given input. In this case the zero input response is the solution of equation (2.2), while the zero state response is the solution of equation (2.3). It is important to realize that the solution of (2.3) depends totally on u(t), while the solution of (2.2) depends only of y(0).

dy(t)

dt + y(t) + 10 = 0 (2.2)

(21)

dy(t)

dt + y(t) + 10 = u(t) (2.3)

y(0) = 0

The only problem of this method is that, usually, it is cumber-some to solve the diferential equations. To give an example let us solve the problem above for u(t) = 8 \forall t \geq 0.

Zero input response

u(t) = 0 (2.4)

dyzi(t)

dt = - yzi(t) - 10 (2.5) Assuming a guess in the form of

yzi(t) = ceat - b (2.6) hence dyzi(t) dt = ace at (2.7) aceat= - ceat+ b - 10 (2.8) if we consider b = 10 aceat= - ceat (2.9) ac = - c (2.10) a = - 1 (2.11)

Therefore, the zero input response takes the form of

yzi(t) = ce - t - 10 (2.12) Using the given initial condition

yzi(0) = 2 (2.13)

2 = ce - 0 - 10 (2.14)

c = 12 (2.15)

so the final form of the zero input response is

(22)

Zero state response

u(t) = 8 (2.17)

dyzs(t)

dt = - yzs(t) - 10 + u(t) (2.18)

= - yzs(t) - 2 (2.19)

It is reasonable to guess that the zero state response takes the form of yzs(t) = ce - at - b (2.20) hence dyzs(t) dt = - ace - at (2.21) - ace - at = - ce - at+ b - 2 (2.22) Assuming b = 2 - ace - at= - ce - at (2.23) a = 1 (2.24)

using the given initial condition

yzs(t) = ce - t - 2 (2.25)

yzs(0) = 0 (2.26)

0 = ce - 0 - 2 (2.27)

c = 2 (2.28)

The final form of the zero state response is

yzs(t) = 2e - t - 2 (2.29) Output of the system As stated before, the output of the system is the sum of the zero output response and the zero state response. So the output of the system for u(t) = 8 \forall t \geq 0, is

y(t) = yzs(t) + yzi(t) (2.30)

y(t) = 14e - t - 12 (2.31)

This method is great once one has the input and the initial conditions, however one can search for a method that simplifies

(23)

the job. Imagine that you want to be ready to calculate the output for ANY given initial condition and ANY input signal. What one can do to make this situation easier? When working with linear systems, the linearity property allows us to use a particular signal \delta (t)that can describe any other possible signal u(t), such that once the output for this special signal is known, then the output for the given signal u(t) is readily calculated.

Indeed, there exists a generic function \delta (t) such that a lin-ear combination of multiple instances of it can generate any possi-ble function u(t), therefore the output of a system to u(t) is calcu-lated through a linear combination of the sytem output to \delta (t). This generic function \delta (t) is the dirac impulse.

2.1.2 Impulse response

Using the simplified impulse matching method explained in [5], one can calculate the impulse response of a given system:

Using D as the diferential operator, one can rewrite the dif-ferential equation that models the system in the following way

Q(D)y(t) = P (D)u(t) (2.32)

where y(t) is the output of the system and u(t) is the input. As the system is causal, the most general case is when the order of Q(D) \geq P (D) = N.

The use of a diferential operator basically turns a differential equation into an algebraic one for which the solution is easier.

As one wants to calculate the response to a typical signal to any initial condition, we are calculating the zero state response to the input of a \delta (t), that here is called h(t).

Before deriving the general expression for the unit impulse response h(t), it is illuminating to understand qualitatively the na-ture of h(t). The impulse response h(t) is the system response to an impulse input \delta (t) applied at t = 0 with all the initial conditions zero. An impulse input \delta (t) is like a lightning bolt, which strikes instantaneously and then vanishes. But in its wake, in that single moment, objects that have been struck are rearranged.

Similarly, an impulse input \delta (t) appears momentarily at t = 0, and then it is gone forever. But in that moment it generates en-ergy storages; that is, it creates nonzero initial conditions instan-taneously within the system at t = 0. Although the impulse input \delta (t)vanishes for t > 0 so that the system has no input after the im-pulse has been applied, the system will still have a response

(24)

gener-ated by these newly cregener-ated initial conditions. The impulse response h(t), therefore, must consist of the system’s characteristic modes for t \geq 0.

As a result

h(t) =characteristic mode terms (2.33) This response is valid for t > 0. But what happens at t = 0? At a single moment t = 0, there can at most be an impulse, so the form of the complete response h(t) is

h(t) = A0\delta (t) +characteristic mode terms (2.34) because h(t) is the unit impulse response, setting u(t) = \delta (t) and y(t) = h(t)in (2.32) yields

Q(D)h(t) = P (D)\delta (t) (2.35)

(a0DN + a1DN - 1+ .. + aN - 1D + aN)h(t) =

(b0DN + b1DN - 1+ .. + bN - 1D + bN)\delta (t) (2.36) In this equation we substitute h(t) from (2.34) and compare the coefficients of similar impulsive terms on both sides. The highest order of the derivative of the impulse on both sides is N , with its coefficient value as a0on the left-hand side and b0on the right-hand side. The two values must be matched. Therefore, a0 = b0and

h(t) = b0\delta (t) +characteristic modes (2.37) As seen, the impulse application can be treated as a zero in-put but modificating the highest order initial condition to 1, while all the others are zero. So first, by the impulse matching method, one calculates yn(t) which is the charcteristic modes response of the system. The impulse response h(t) can be calculated using the following equation

h(t) = b0\delta (t) + [P (D)yn(t)]u(t) (2.38) where yn(t)is a linear combination of the characteristic modes of the system subject to zero initial conditions but the highest order which is unitary. This condition represents the impulse as the light-ning that strikes the system.

(25)

To show better how the method works, let us calculate an example d2y(t) dt2 + 3 dy(t) dt + 2y(t) = du(t) dt (2.39) (D2+ 3D + 2)y(t) = Du(t) (2.40) The impulse matching method implies

\.

y(0) = 1and y(0) = 0 (2.41)

Finding the characteristic polynomial

(\lambda 2+ 3\lambda + 2) = (\lambda + 1)(\lambda + 2) (2.42) The characteristic roots of the system are \lambda = - 1 and \lambda = - 2, therefore the impulse response takes the form of

y(t) = c1e - t+ c2e - 2t (2.43) and its diferential

\.

y(t) = - c1e - t - 2c2e - 2t (2.44) using the initial conditions, we have

0 = c1+ c2 (2.45)

1 = - c1 - 2c2 (2.46)

so

c1= 1and c2= - 1 (2.47)

and the final form of the impulse response is

h(t) = P (D)y(t) = Dy(t) = - e - t+ 2e - 2t (2.48) 2.1.3 Dirac impulse

An impulse is a function that takes on value 0 everywhere but at 0 and whose integral from - \infty to \infty is equal to 1.

\delta (t) = \biggl\{ \infty , if t = 0 0, otherwise , with \int \infty - \infty \delta (t)dt = 1 (2.49)

(26)

This function can be defined through the limit of the follow-ing function: f (t) = \biggl\{ 1 s, if \| t\| \leq s 2 0, otherwise (2.50)

Figure 2.1: Dirac impulse development. If we take the limit when s goes to 0 \mathrm{l}\mathrm{i}\mathrm{m}

s\rightarrow 0f (t), f (t) will be-come the Dirac impulse \delta (t) as seen in Figure 2.1. To every value of s the integral remains equal to 1 and when s goes to 0 the value of the function is 0 everywhere but at 0. It is wise to point out here that \delta (t) is not a proper function in the usual sense, but rather a generalized function.

Another important property of the impulse function is that for any function u(t)

u(t)\delta (t) = u(0)\delta (t) (2.51) and \int \infty - \infty u(t)\delta (t)dt = u(0) \int \infty - \infty \delta (t)dt = u(0) (2.52) Hence, the impulse function can be used to theoretically sam-ple signals.

(27)

It is trivial to show that a linear infinite sum of impulses, what is called a train of impulses, can build any function. Therefore, if we calculate the impulse response for a linear system, it can be used to calculate any possible output of it. It is wise to point out here that the train of impulses, like the diract function, is not a proper function in the usual sense, but rather a generalized function 2.1.4 Using the impulse response

So, now that one has the impulse response, how does one use the information in order to obtain the response to a generic signal u(t)?

First let us show how u(t) can be written using impulses: De-fine p(t) as a pulse starting at zero and ending at \Delta \tau with unitary height as showed in Figure 2.2.

t Δτ

1

0

Figure 2.2: Unitary pulse.

It is not dificult to see that one can use the pulse to build a discrete aproximation of u(t)

u(t) \approx \infty \sum n=0

u(n\Delta \tau )p(t - n\Delta \tau ) (2.53)

With an algebraic manipulation, one can see that this description leads to the Dirac impulse. First, it is trivial that the limit of the approximation (2.53) will be the function u(t)

u(t) = \mathrm{l}\mathrm{i}\mathrm{m} \Delta \tau \rightarrow 0

\sum n

(28)

If we multiply and divide by \Delta \tau u(t) = \mathrm{l}\mathrm{i}\mathrm{m}

\Delta \tau \rightarrow 0 \sum

n

u(n\Delta \tau )p(t - n\Delta \tau )

\Delta \tau \Delta \tau (2.55) As seen before, this can be written as

u(t) = \mathrm{l}\mathrm{i}\mathrm{m} \Delta \tau \rightarrow 0

\sum n

u(n\Delta \tau )\delta (t - n\Delta \tau )\Delta \tau (2.56) Now that one has the description of u(t) as a function of the Dirac impulse, one can calculate the output based on the system linearity.

Input \Rightarrow Output \delta (t) \Rightarrow h(t) using a time delay \delta (t - n\Delta \tau ) \Rightarrow h(t - n\Delta \tau ) multiplying both sides by a scalar u(t) [u(n\Delta \tau )\Delta \tau ]\delta (t - n\Delta \tau ) \Rightarrow [u(n\Delta \tau )\Delta \tau ]h(t - n\Delta \tau )

taking the limits to make it continuous \mathrm{l}\mathrm{i}\mathrm{m}

\Delta \tau \rightarrow 0 \sum

n

u(n\Delta \tau )\delta (t - n\Delta \tau )\Delta \tau \Rightarrow \mathrm{l}\mathrm{i}\mathrm{m} \Delta \tau \rightarrow 0

\sum n

u(n\Delta \tau )h(t - n\Delta \tau )\Delta \tau

Therefore, the output to a generic signal u(t), as a function of its impulsive response, is

\mathrm{l}\mathrm{i}\mathrm{m} \Delta \tau \rightarrow 0

\sum n

u(n\Delta \tau )h(t - n\Delta \tau )\Delta \tau = \int \infty

- \infty

u(\tau )h(t - \tau )d\tau (2.57)

This integral is known as the convolution integral, which is really troublesome to calculate.

2.1.5 Transfer Function Models

Transfer Function Models is one of the tools used to describe signals and linear systems, which is based on the Laplace transform. The great benefit of the transfer function is to take a differential op-erator and transform it into an algebraic equation. Another benefit is to transform the convolution operation (2.57) into a simple multi-plication. It is assumed that the reader already has knowledge about

(29)

the Laplace transform, otherwise a great reference is the chapter 4 of [5].

Take the same system used in the example of impulse re-sponse: d2y(t) dt2 + 3 dy(t) dt + 2y(t) = du(t) dt (2.58)

One can solve this differential equation using the Laplace transform, considering state zero:

(s2+ 3s + 2)Y (s) = sU (s) (2.59) where Y (s) is the Laplace transform of y(t) and U (s) is the Laplace transform of u(t).

If one wants to know the solution to a constant output start-ing at zero u(t) = 1, for example, the followstart-ing procedure is used:

\bullet Calculate the Laplace transform of u(t) L \{ u(t)\} = U(s) = 1

s (2.60)

\bullet Solve the algebraic equation resulting

(s2+ 3s + 2)Y (s) = sU (s) (2.61)

Y (s) = s

s2+ 3s + 2U (s) (2.62)

Y (s) = s

s3+ 3s2+ 2s (2.63) \bullet Apply the inverse Laplace transform to Y (s)

L - 1\{ Y (s)\} =L - 1\{ s

s3+ 3s2+ 2s\} (2.64) = e - t - e - 2t (2.65) Note that there is an important step which is independent of the input

Y (s) = s

(30)

One can rewrite this equation in the following way Y (s) U (s) = s s2+ 3s + 2 (2.67) H(s) = s s2+ 3s + 2 (2.68)

H(s)is called the transfer function of the system.

An important fact is that the Laplace transform of the Dirac impulse \delta (t) is equal to 1, so the transfer function of a system is, in fact, the Laplace transform of its impulse response.

Transfer function is the most common tool used in SISO lin-ear systems theory to calculate outputs and properties of a system. This is due to the easy process of output calculation, which enables one to assess properties such as stability and how fast is the system dynamics.

For MIMO systems, it is used a matrix of transfer functions, coupling the inputs and outputs by independent transfer functions, e.g. H(s) = \biggl[ 1 s+1 3 s2+3s+2 2 1s \biggr] (2.69) 2.1.6 Step Response

Step is the constant signal starting at zero represented in Fig-ure 2.3. Its Laplace transform is U (s) = 1

s.

t 1

0

(31)

The step response of a system can be used to model it, once that from it one can generate any other response that system can provide. Besides that, the step response has some properties that can be measured and used to translate it a specific transfer function. The step response then is analogous to a transfer function as an identity to the system.

Let us consider the following system represented by its trans-fer function G(s)

G(s) = 3

s(s + 5) (2.70)

Its step response is 3t 5 + 3e - 5t 25 - 3 25 (2.71)

One can see a clear separation of this response in 3 basic terms, one that is constant, one that multiplies time and another that is a negative exponential. When time goes to infinity, the ex-ponential goes to zero. Let us call the three terms in the following way:

\bullet Integration part: the term multiplying time; \bullet Dynamic or Transient State part: the exponentials; \bullet Steady State part: the constant.

These three parts can be obtained by the partial fractions ex-pansion of G(s)U (s) given by:

3 s3+ 5s2 = 3 5s2 + 3 25(s + 5) - 3 25s (2.72) 2.2 INTRODUCTION TO OPTMIZATION

This section offers a brief introduction to mathematical opti-mization focusing on problem classes that are relevant to the dis-sertation. Continuous optimization is an area of mathematics that searches to solve problems of maximization or minimization of con-tinuous functions. The problem usually presents itself in the follow-ing way:

\mathrm{m}\mathrm{i}\mathrm{n}

(32)

The solution we search in these problems is an x\ast such that f (x\ast ) \leq f (x), for all x. What distinguishes continuous optimization from other areas of optimization is that the function variables are contin-uous and usually a vector of real numbers, instead of binary, integer or whatever other nature of variables. In other words, continuous optimization is the problem where f (x) : \Re n \rightarrow \Re is a real and continuous function, and x \in \Re n.

It is important to notice that there is no loss of generality in assuming that the problem is always of minimization because

\mathrm{a}\mathrm{r}\mathrm{g} \mathrm{m}\mathrm{i}\mathrm{n} x f (x) = \mathrm{a}\mathrm{r}\mathrm{g} \mathrm{m}\mathrm{a}\mathrm{x} x - f (x) (2.74) 2.2.1 Unconstrained Optimization

As we are working with continuous functions, some results from analysis can be used to know when a point is a function mini-mum. A necessary condition is that

\nabla f (x\ast ) = 0 (2.75) where \nabla f (x) denotes the gradient of the function. Although this is a necessary condition, it is not sufficient since there exists inflexion points. To complement this result one can use the necessary and sufficient condition that follows:

\nabla f (x\ast ) = 0, \nabla 2f (x\ast ) \succ 0 (2.76) Despite some of these problems having analytical solutions, in practice, some algorithms are used to solve optimization prob-lems. These algorithms based themselves in finding a sequence of variables, known as iterates, that converge to the minimum x\ast which should satisfy (2.76).

2.2.1.1 Algorithms

For problems without constraints on x the algorithms based themselves in finding directions where the function f (x) decreases and iterates in these directions until it converged near enough to the minimum. In a mathematical description, one can define this algorithms as

xk+1= xk+ tk\Delta xk (2.77) where k denotes the iterates, tk denotes the step of iteration and \Delta xkdenotes the direction. This iteration will always result in

(33)

Steepest descent algorithm The steepest descent algorithm bases itself in the fact that the gradient will always point to the greatest ascent direction from a point, so its negative would point to the steepest descent direction. The improvements in this algorithm are in the way it follows the gradient, meaning how big a step it will take at iteration and how often it will update its direction. A basic algorithm is presented as follows

Algorithm 1. Steepest descent algorithm

1: procedure ST E E P E S T D E S C E N T

2: while not converged do

3: Define a direction \Delta xk

4: Define a step in the direction tk

5: Update the variable xk+1= xk+ tk\Delta xk

6: end while

7: end procedure

end

The definition of tk is usually done by a linear search with backtracking, following the steps:

Algorithm 2. Linear Search with backtracking

1: procedure LI N E A R SE A R C H

2: t = 1

3: while f (x + t\Delta x) > f (x) + \alpha t\nabla f (x)T\Delta xdo

4: t = \beta t

5: end while

6: end procedure

end

where \alpha \in [0, 0.5] and \beta \in (0, 1). The definition of \Delta xk is a little more user oriented, but usually is used the negative of the gradient of function f (x) as this would be the greatest advance the-oretically, hence \Delta xk= - \nabla f (xk).

Newton’s Method The Newton’s method is a descent algorithm, assuming that \nabla 2f (x)is positive definite, in the sense that it uses a special direction \Delta xnt

\Delta xnt = - \nabla 2f (x) - 1\Delta x (2.79) Besides that, this method has a way to know how close the algo-rithm is to convergence by the Newton’s decrement

(34)

If the factor\lambda 2

2 is small enough, \lambda 2

2 \leq \varepsilon for some \varepsilon > 0, it converged. Algorithm 3. Newton’s algorithm

1: procedure NE W T O N’S A L G O R I T H M

2: while \lambda 2

2 > \varepsilon do

3: Calculate \Delta xnt = - \nabla 2f (x) - 1\Delta x

4: Calculate the stop criteria \lambda 2= \nabla f (x)T\nabla 2f (x) - 1\nabla f (x) 5: Define a step t in the direction \Delta xnt

6: Update the variable xk+1= xk+ t\Delta xnt

7: end while

8: end procedure

end

The step t is usually defined by using the linear search with backtracking as shown before.

2.2.2 Constrained optimization

One says that an optimization problem is constrained when it is formulated in this way:

minimize

x f0(x)

subject to fi(x) \leq bi, i = 1, . . . , m, fi(x) = bi, i = m + 1, . . . , n.

The constraints act on x, restricting its possible values and making it harder to solve the problem. However, there are some necessary and sufficient conditions based on the gradients \nabla fi, i = 0, . . . , n, but this depends on an additional condition called a constraint qualification.

A central role in characterizing solutions of constrained opti-mization problems is played by the Lagrangian function, defined as follows: \scrL (x, \lambda , \mu ) = f0(x) - m \sum i=1 \lambda ifi(x) - n \sum i=m+1 \mu ifi(x) (2.81)

This is a linear combination of objective and constraints, where the weights \lambda i and \mu i are known as Lagrange multipliers. At a local solution for the optimization problem, the following con-ditions will hold for some values of \lambda i\ast and \mu i\ast :

(35)

\nabla x\scrL (x\ast , \lambda \ast , \mu \ast ) = 0 (2.82) fi(x\ast ) \leq bi, i = 1, . . . , m (2.83) fi(x\ast ) = bi, i = m + 1, . . . , n (2.84) \lambda \ast i \geq 0, i = 1, . . . , m (2.85) \lambda \ast ifi(x\ast ) = 0; i = 1, . . . , m (2.86) The conditions explicited in (2.82) are known as Karush-Kuhn-Tucker conditions, or KKT conditions for short, named after those who discovered the conditions.

2.2.2.1 Algorithms

Penalty methods The penalty methods use the KKT conditions as relaxed constraints added to the optimization problem. This way the unconstrained algorithms will satisfy the necessary and suffi-cient conditions while minimizing the original objective function.

One fundamental approach to constrained optimization is to replace the original problem by a penalty function that consists of:

\bullet The original objective of the constrained optimization prob-lem.

\bullet One additional term for each constraint, which is positive when the current point x violates that constraint and zero oth-erwise.

Most approaches define a sequence of such penalty func-tions, in which the penalty terms for the constraint violations are multiplied by some positive coefficient. By making this coefficient larger and larger, we penalize constraint violations more and more severely, thereby forcing the minimizer of the penalty function closer and closer to the feasible region for the constrained problem. The simplest penalty function of this type is the quadratic penalty function, in which the penalty terms are the squares of the con-straint violations. One can define a penalty function Q such as

Q(x, \mu ) = f (x) + 1 2\mu m \sum i=1 \mathrm{m}\mathrm{a}\mathrm{x}\{ fi(x) - bi, 0\} 2+ 1 2\mu n \sum i=m+1 (fi(x) - bi)2 (2.87)

(36)

A general framework for algorithms based on the penalty function can be specified as follows.

Algorithm 4. Quadratic penalty algorithm

Input: Tolerance, initial guess, initial \mu 0

1: procedure QU A D R AT I C P E N A L T Y A L G O R I T H M

2: while \| Q(xk, \mu k)\| \geq tolerancedo

3: update \mu k+1= 0.1 \ast \mu k 4: solve the updated problem

5: update the initial guess with the solution of problem k

6: end while

7: end procedure

end

One can question why solve sequentially many problems in-stead of only solving the original one. The answer lies on the initial point factor, as one does not know where the optimum lies at the begining, it is usual to guess an initial solution so the algorithm can begin its work. The algorithm will be faster the closer the initial guess is to the optimum, this way the solution of chain of problems to the initial guess of the next and the algorithms do not take long time to find a solution.

The parameter \mu k can be chosen to solve a greater number of easier problems or a lower number of harder problems, so long as \mu k+1\leq \mu kwhen to go for the harder path (real problem) or the easier path (slower penalty) is a user oriented decision.

Barrier function method Another approach in the same way of quadratic penalties is the barrier method. Barrier methods use bar-rier functions to penalize infeasibility. The barbar-rier function of an inequality-constrained problem is described as follows:

F0= \{ x \in \Re n| fi(x) \geq 0, i = 1, . . . , m\} (2.88) The barrier function has the following properties:

\bullet It is infinite everywhere except inside F0; \bullet It is smooth inside F0;

\bullet Its values approach to infinite as x approaches the boundary of F0.

(37)

The most used barrier function is the logarithm barrier - m \sum i=1 \mathrm{l}\mathrm{o}\mathrm{g}(fi(x)) (2.89) where \mathrm{l}\mathrm{o}\mathrm{g}(\cdot \cdot \cdot ) is the natural logarithm function. The subproblem to be used in the iterative algorithms is

P (x, \mu ) = f (x) - \mu m \sum i=1

\mathrm{l}\mathrm{o}\mathrm{g}(fi(x)) (2.90) As the minima should remain inside the feasible region, the barrier ensures that the solutions will be pushed towards it. The generic algorithm to solve a log-barrier function is very similar to the quadratic penalty function shown for the quadratic-penalty method.

Augmented Lagrangian The Augmented Lagrangian algorithm is a penalty method that is similar to the quadratic penalties. Its dif-ference is that it explicitly uses Lagrange multipliers to build the penalty. This way it is more appropriate for ill conditioned prob-lems and generates better subprobprob-lems than either the quadratic penalty or the logarithmic barrier method. A suitable problem to the method is

minimize

x f (x)

subject to di(x) = 0, i = 1, . . . , q

The augmented Lagrangian function is described in the fol-lowing way: \scrL A(x, \lambda , \mu ) = f (x) - q \sum i=1 \lambda idi(x) + 1 2\mu q \sum i=1 d2i(x) (2.91)

This method works in two ways. First, as a penalty method it has to decrease \mu between the subproblem solutions. On the other hand the Lagrangian multiplier estimates \lambda i should converge to their true values, which comes from applying the KKT conditions to the augmented Lagrangian equation:

\lambda k+1i = \lambda ki - di(xk) \mu k

(38)

In the presence of inequalities, one can add slack variables to transform the problem into equations only.

Algorithm 5. Augmented Lagrangian Method

Input: \varepsilon , x0, \mu 0, \lambda 0

1: procedure AU G M E N T E D LA G R A N G I A N

2: while xk+1 - xk\geq \varepsilon do

3: update \lambda k+1i = \lambda ki - di(xk)

\mu k , i = 1, . . . , q

4: update \mu k+1= 0.1 \ast \mu k

5: solve the updated problem to get xmin

6: update the initial guess with the solution of problem xk= xmin

7: end while

8: end procedure

end

2.2.3 Sequential Quadratic Programming (SQP)

SQP or Sequential Quadratic Programming is a practical method that can be used for a large variety of problems. It works by producing an iterative series of quadratic subproblem approxima-tions that converge to the optimal solution. Consider the following general problem: P : Minimize f (x) x \in \BbbR n Subject to: cj(x) = 0, j = 0, . . . , q cj(x) \geq 0, j = q + 1, . . . , m (2.93)

where f : \BbbR n \rightarrow \BbbR and c

j : \BbbR n \rightarrow \BbbR are smooth functions. One can divide the SQP in two methods, whether your interest is a local solution or a global solution,

2.2.3.1 Local Method

Given an initial guess (x0, \lambda 0)for the solution and Lagrangian multiplier, SQP generates a sequence \{ (xk, \lambda k)\} k=0,1,... of iterates, in order to do so the method solves a quadratic approximation of P:

Pk: Minimize mk(pk) = 12pTkWkpk+ \nabla fkTpk pk

Subject to: \nabla cj(x)Tpk+ cj(xk) = 0, j \in \scrE \nabla cj(x)Tpk+ cj(xk) \geq 0, j \in \scrI

(39)

where Wk is the Hessian of the Lagrangian function at the current iterate. More precisely, \scrL (x, \lambda ) = f (x) - \sum

j\in \scrE \cup \scrI \lambda jcj(x)is the La-grangian, W (x, \lambda ) = \nabla 2

xx\scrL (x, \lambda ) is the Lagrangian’s Hessian, and Wk= W (xk, \lambda k)is the Hessian matrix evaluated at the current iter-ate.

For each k = 0, 1, . . ., the local SQP method begins by eval-uating fk = f (xk), \nabla fk = \nabla f (xk), Wk = W (xk, \lambda k), cj(xk) and \nabla cj(xk) for all j \in \scrI \cup \scrE . It then solves Pk to yield steps pk and \mu k for the current solution and Lagrangian multiplier, respectively, obtaining the next iterate (xk+1, \lambda k+1) = (xk+ pk, \lambda k+ \mu k).

If a convergence criterion is satisfied, such as the minimum step \| (pk, \mu k)\| < \varepsilon , the algorithm terminates, or else it continues iterating from (xk+1, \lambda k+1). Near the optimum the SQP method be-comes equivalent to Newton’s method applied to the first-order con-ditions, \nabla \scrL (x, \lambda ) = 0, which consists in solving a system of linear equations: \biggl[ Wk - ATk Ak 0 \biggr] \biggl[ pk \mu k \biggr] = \biggl[ - \nabla f (xk) + ATk\lambda k - c(xk) \biggr] (2.95) where c = [cj : j \in \scrE ] is the constraint vector function and Ak = \nabla c(xk) is the Jacobian matrix of the constraints evaluated at the current iterate. Assuming that (xk, \lambda k) is sufficiently close to a locally optimal pair (x\ast , \lambda \ast )and Wk is positive definite in the null space of Ak, then Pkis a convex quadratic problem that has a unique solution-Lagrangian multiplier (pk, \mu k). This pair is precisely the solution to the linear system (2.95). Thus, at least locally, the SQP method defines not only a good step from xkto a local solution x\ast , but also a good step from \lambda k towards the optimal Lagrangian multiplier \lambda \ast .

2.2.3.2 Global Methods

For SQP to be practical, convergence should be ensured for nonconvex problems and from remote starting points. The globally convergent version of SQP behaves much like trust-region methods. A merit function \phi is typically used to control the length of steps in line search methods or to determine how the size of a trust-region should be adjusted in trust-region methods. In essence, a merit func-tion combines constraint infeasibility and the objective value of an iterate so that a descent direction for this function means progress

(40)

towards a local solution. For equality-constrained problems, two merit functions are the l1merit function

\phi 1(x; \mu ) = f (x) + 1

\mu \| c(x)\| 1 (2.96) where \mu > 0, and Fletcher’s augmented Lagrangian merit function, which is defined by

\phi F(x; \mu ) = f (x) + \theta (x)Tc(x) + 1 2\mu \| c(x)\|

2

2 (2.97)

where \theta (x) = [\nabla c(x)\nabla c(x)T] - 1\nabla c(x)\nabla f (x).

The SQP method can be implemented in a number of ways. A practical implementation of SQP uses line search and quasi-Newton approximations of the Hessian matrix. Below we describe the steps of a general SQP algorithm for solving the nonlinearly constrained problem P .

SQP Algorithm

\bullet Choose parameters\eta \in (0, 1/2)and\tau \in (0, 1) \bullet Choose a starting iterate(x0, \lambda 0)

\bullet LetB0\in \BbbR n\times nbe a symmetric positive definite matrix (initial Hessian)

\bullet k = 0

\bullet Computefk= f (xk),\nabla fk= \nabla f (xk),ck= c(xk), andAk= \nabla c(xk) \bullet Fork = 0, 1, . . . , maxk

- If the KKT conditions are satisfied stop

- SolvePkto obtain a search directionpk

- Find step\mu kthat renderspka descent direction for\phi atxk - \alpha k\leftarrow 1

- While\phi (xk+ \alpha kpk; \mu k) > \phi (xk; \mu k) + \eta \alpha kD\phi (xk; pk)do

\alpha k\leftarrow \tau \prime

\alpha kfor\tau \prime \in (0, \tau )

end-while

- xk+1= xk+ \alpha kpk

- Evaluatefk+1,\nabla fk+1,ck+1,Ak+1 - Obtain\lambda k+1by solving the linear system

[Ak+1ATk+1]\lambda k+1= - Ak+1\nabla fk+1 - Calculatesk= \alpha kpkand

yk= \nabla x\scrL (xk+1, \lambda k+1) - \nabla x\scrL (xk, \lambda k) - ObtainBk+1using a quasi-Newton formula end-for

The operator D\phi (x, p) corresponds to the directional deriva-tive of function \phi in the direction given by p.

(41)

2.3 MODEL PREDICTIVE CONTROL

The term model predictive control (MPC) does not designate a specific control strategy but a very ample range of control methods that make explicit use of a model of the process to obtain the control signal by minimizing an objective function. The key ideas of the predictive control family are [1]:

\bullet Explicit use of a model to predict the process output at future time instants (horizon).

\bullet Calculation of a control sequence minimizing an objective function.

\bullet Receding strategy, so that at each instant the horizon is dis-placed towards the future, which involves the application of the first control signal of the sequence calculated at each step. 2.3.1 MPC strategy

The methodology of all the controllers belonging to the MPC family is characterised by the following strategy illustrated in Figure 2.4:

1. The future outputs for a defined horizon N , called the predic-tion horizon, are predicted at each instant t using the process model. These predicted outputs \^y(t + k| t) for k = 1, . . . , N depend on the known values up to instant t (past inputs and outputs) and on the future control signals u(t + k| t) k = 0, . . . , N - 1, to be calculated.

2. The set of future control signals is calculated by optimizing a determined criterion in order to keep the process as close as possible to the reference trajectory w(t + k) (which can be the set-point itself or a close approximation of it). This criterion usually takes the form of a quadratic function of the errors between the predicted output signal and the predicted refer-ence trajectory. The control effort is included in the objective function in most cases. An explicit solution can be obtained if the criterion is quadratic, the model is linear and there are no constraints, otherwise an iterative optimization method has to be used. Some assumptions about the structure of the future control law are also made in some cases, such as that it will be constant from a given instant.

(42)

3. The control signal u(t| t) is sent to the process, whilst the next control signals calculated are neglected, because at the next sampling instant y(t + 1) will already be known, and step 1 will be repeated with this new value and all the sequences will be brought up to date. Thus the control signal u(t + 1| t + 1) is calculated (which in principle will be different to u(t + 1| t) because of the new information available) using the receding horizon concept.

Figure 2.4: MPC idea.

2.3.2 MPC elements

All the MPC algorithms possess common elements and differ-ent options can be chosen for each one of these elemdiffer-ents, which gives rise to different algorithms. These elements are:

\bullet the prediction model, \bullet the objective function, and

\bullet the procedure to obtain the control law. 2.3.2.1 Prediction model

The process model plays a decisive role in the controller be-cause it is necessary to calculate the predicted output at future in-stants \^y(t + k\| t). The model can be divided into two parts: The

(43)

actual process model and the disturbance model. Both parts are needed for the prediction.

Process model Practically every possible form of modelling a pro-cess appears in a given MPC formulation, the following being the most commonly used:

\bullet Impulse response, \bullet Step response, \bullet Transfer function.

In this dissertation the step response and transfer function will be the main focus.

2.3.2.2 Disturbance model

A disturbance model is used when a process disturbance is known or measured, this way the controller can reject it beforehand. Normally it is used a minor process model, like the ones already cited, that models the system output using the disturbance as input. 2.3.2.3 Objective function

The objective function summarizes the controller goals guid-ing the optimization process as a weighted sum of subgoals so one can prioritize one goal of the controller over another.

2.3.2.4 Constraints

Generally, they represent physical constraints. These con-straints are typically imposed on control variations \Delta u, control boundaries umax and umin, saturation and operation limits for which the model is valid and safe.

2.3.2.5 Solving the optimization problem

As the MPC optimization problem is a quadratic program, it is solved with the interior-point method or Newton’s method for example.

(44)

2.4 SUMMARY

Chapter 2 presented the bases of linear control theory, op-timization and model predictive control. The concepts of step re-sponse, minimization of functions and the components of a MPC controller will be well used in the next chapters. Though briefly ex-plained, the optimization algorithms presented here will mold the simulation algorithms used later in this work.

(45)

A goal without a plan is just a wish.

Antoine de Saint-Exupery

3.1 LIMITATIONS OF STANDARD MPC

In [6] is stated some problems egineers face when using MPC in industrial projects. The criticism span over the following aspects:

\bullet MPC Justification \bullet MPC Stability

\bullet MPC Physical Meaning \bullet MPC Robustness \bullet MPC Tuning

MPC Justification Prior to apply an MPC strategy, it must be very clear the motivation for this, based on the control objectives to be achieved and the understanding of the process system at hand. In many cases, a well tuned regulatory control is enough to handle the control objectives. However, frequently, the MPC can take ad-vantages of its predictive and multivariable nature to enhance the performance of coupled and constrained systems.

MPC Stability MPC is a technique that is best suited for intercon-nected systems such that found in oil industry and energy genera-tion plants. In these cases, safety is a priority, so a controller with stability guarantees is needed. The problem is that the techniques for ensuring stability of MPC are rather theoretical and are harder to be ensured in practical uses where many disturbances can occur. The controller must remain feasible even if an actuator or sensor fails, and should keep the system inside its safety boundaries in the long run.

MPC Physical Meaning In PIDs and other classical control tech-niques, like on/off control and even open loop, the process engi-neers that make the system surveillance have in its control and state signals something they can correlate to reality. For systems with a

(46)

large number of variables (mainly inputs, outputs and constraints) the techniques tend to create and apply transformations to the state variables. At this point, the system works great but the physical link is lost. Some reports show that the operators often turn-off the con-troller once they do not feel safe with the system measures and they cannot predict what the controller will do face a disturbance. MPC Robustness Citing Hugo in [6]:

The promise of MPC controllers is that they would re-lieve the operators of many of their functions – indeed there were worries at one point that the operator skill set would ossify as more and more of the plant control would be performed by the MPC controller. These fears proved to be unfounded as MPCs often requires more operator intervention and have added to the operator workload. There are two reasons for this:

\bullet The unpredictability of the model predictive con-troller, especially coupled with an LP, requires the operator to ensure that the controller is behaving as desired. In fact, the Abnormal Situation Manage-ment Consortium has found that MPC controllers can contribute to escalation of upsets

\bullet The controller can behave poorly in the face of model mismatch and large plant disturbances.

MPC Control Tuning Since many of the MPCs result in a Pareto-optimal controller, it is hard to compare and analyze how better one tuning will be when compared to others. On another perspective, allied with the physicial meaning problems, it is hard to translate physical objectives and priorities into weights for an objective func-tion. A solution that automaticaly translates these priorities into the mathmatical weights for the optimization problem would greatly improve this aspect.

Citing Hugo in [6]:

On the surface, MPC controllers appear complete: opti-mality in both economic and regulatory control, ability to handle all plant inputs and outputs, and a centralized structure for coordination. But there is no guarantee that the (somewhat arbitrary) mathematical optimizations of

(47)

MPC translate well into engineering objectives, nor that the rigid structure of MPC controllers matches the engi-neering design problem at hand. No single set of MPC controller weights and constraints could provide the de-sired performance for the many competing goals and spe-cial cases of the plant.

For each of the problems raised above a novel advanced MPC strategy is proposed here as a direction to minimize them in a prac-tical way.

3.1.1 Chapter contents

In order to tackle some of the issues presented in [6] we will develop an alternative for these main elements of MPC presented in section 2.3.2, namely the objective function, the prediction model and the process to obtain a solution, and we will ad the tuning strategy as a main MPC element as explained below:

\bullet The first element is the prediciton model, for which it will be presented the OPOM (Output Prediction Oriented Model). OPOM is a prediction model based on the systems step re-sponse whose physical meaning is friendly to understand and eases the stability requirements, dividing the systems into three dynamics: steady state, exponetial or transient state and integration states.

\bullet The second element is the objective function which will be updated to an infinite horizon composition to ensure the con-troller stability. This method dates back to the 90’s with a the-oretical appeal, which can be powered by a new prediction model (OPOM) to be used in industrial applications with ease. \bullet The third element here will be the tuning strategy. As ex-plained before, a static tuning that yields a satisfactory op-eration for various conditions is hard to obtain, if not impos-sible. As an alternative, a situational tuning called satisficing will be presented in order to automate the choice of weights based in physicial process constraints. Following a satisficing methodology the operator does not have to worry about an abstract/empirical choice to tune the controller.

\bullet The last element is the optimization solution for the new opti-mization problem. As explained in Chapter 2 there are many

(48)

methods suited to be considered in this dissertation specially because the problems are convex or quadratic.

3.2 OPOM

The Output prediction oriented model presented in [7] is a prediction model based on the step response of a system. Let us take for example the linear system G(s) = k

(\tau s+1)s, whose step response is

S(s) = G(s)U (s) = G(s)1

s (3.1)

that results in:

S(t) = k\tau - k\tau e - \tau t + kt (3.2)

Observe that this response can be divided into three modes: 1. A steady state part which is constant: k\tau ;

2. A dynamical part which is driven to zero as time goes to infin-ity: - k\tau e - t

\tau ;

3. An integral part that grows with time: kt.

Considering these modes, it is possible to rewrite S(t) in the follow-ing form:

S(t) = d0+ dde - t\tau + dit (3.3)

where d0,ddand di are constants.

In the following, it will be derived a state space model where this modes are explicitated.

Let us define [y]k(t)as the output of the system for all time t, after instant k, with no input applied and [y\prime ]

k(t)as the output of the system for all time t, after a step applied at instant k.

Let us divide the output y(t) of a generic linear system into the sum of three state variable analagous to the equation (3.3):

[y]k(t) = [xs]k+ [xd]ke -

t \tau + [xi]

kt (3.4)

Suppose that all the controls are applied in the form of con-stant steps. According with the form of the step response already presented in Chapter 2, it is straight-forward to obtain the output signal after applying a control signal

(49)

This way we can predict [y]k+1(t)as [y]k+1(t) = [xs]k+ [xd]ke - t+\Delta t \tau + [xi] k(t + \Delta t)+ \{ d0+ dde - t+\Delta t

\tau + di(t + \Delta t)\} \Delta u

k (3.6) If we consider [x]k+1, we can write

[y]k+1(t) = [xs]k+1+ [xd]k+1e -

t \tau + [xi]

k+1t (3.7) where

[xs]k+1= [xs]k+ \Delta t[xi]k+ (d0+ \Delta tdi)\Delta uk (3.8) [xd]k+1= e - \Delta t t [xd] k+ dde - \Delta t t \Delta u k (3.9) [xi]k+1= [xi]k+ di\Delta uk (3.10) Observe that, although the inputs are steps applied at discrete times k, the output is continuous in t. This prediction can be mod-eled by a state-space model formulation

[x]k+1= A[x]k+ B\Delta uk (3.11) [y]k(t) = C[x]k (3.12) where [x]k= \left[ xs xd xi \right] k (3.13) A = \left[ 1 0 \Delta t 0 e - \Delta t\tau 0 0 0 1 \right] (3.14) B = \left[ d0+ di\Delta t dde - \Delta t \tau di \right] (3.15) C =\bigl[ 1 e - t \tau t\bigr] (3.16)

(50)

Discrete Output In many uses, there is no benefit in having a continuous output prediction as the controller itself is discrete in its nature. It is very easy to jump from the continuous output to a discrete one just changing the output matrix C to:

C = [1, 1, 0] (3.17)

In summary OPOM is a prediction model that describes math-matically the evolution of any system in terms of a sum of three parts: a constant part xs, a linear growing part xiand a sum of non zero exponentials xdwith the input discretized by steps (zero order hold). To see how one can use this in practice, some points need to be understood.

Initial Conditions Representation One can describe any initial point in terms of a sum of the states, however this relation is not in-jective. So we give some examples to help understand how the rep-resentation works. If one considers the system in a constant steady state, both x0

dand x0i are zero and the constant value goes to x0s(“s” comes from Steady State). But depending on how much informa-tion you have about the system’s past (more than a point), you can describe better this initial condition. It is even possible to design a state observer to track the initial conditions.

For example, looking at Equation (3.12), the system which has the initial condition (1, 0, 0) is a constant state that stays forever at 1 (with no further disturbances or controls applied), while the initial condition (0, 0, 1) gives you a system that is a ramp starting at zero, and (1, 0, 1) is a ramp starting at 1 with its output represented by y(t) = 1 + t. If one knows beforehand the system nominal poles, it is also easy to follow any dynamic.

3.2.1 Example

First, let us consider a simple system: G(s) = 1

s + 1 (3.18)

Its step response is easy to calculate

y(t) = 1 - e - t (3.19)

(51)

\bullet ds= 1 \bullet dd= - 1 \bullet di = 0

The resulting OPOM state space representation will be \left[ xs xd xi \right] k+1 = \left[ 1 0 \Delta t 0 e - \Delta t 0 0 0 1 \right] \left[ xs xd xi \right] k + \left[ 1 + 0\Delta t - e - \Delta t 0 \right] \Delta u (3.20)

and its predicted output is

[y(t)]k= [xs]k+ e - t[xd]k+ t[xi]k (3.21) So for a zero initial condition (steady state in the origin)

[y(t)]k= 0 + e - t\ast 0 + t \ast 0 = 0 (3.22) And for a non-zero steady initial condition (1, 0, 0)

[y(t)]k= 1 + e - t\ast 0 + t \ast 0 = 1 (3.23) which satisfies the system zero-input response.

Now, if one applies a step, which for this representation means \Delta u0 = 1 and for a sample time \Delta t of 0.1, the following OPOM state-space model is obtained

\left[ xs xd xi \right] k+1 = \left[ 1 0 0.1 0 e - 0.1 0 0 0 1 \right] \left[ xs xd xi \right] k + \left[ 1 + 0 \ast 0.1 - e - 0.1 0 \right] 1 (3.24) which gives us [xs]k+1= [xs]k+ 0, 1 \ast [xi]k+ 1 = 1 (3.25) [xd]k+1= e - 0.1\ast [xd]k - e - 0.1= - e - 0.1 (3.26) [xi]k+1= [xi]k+ 0 = 0 (3.27) So, for k = 1, (xs, xd, xi) = (1, - e - 0.1, 0)we have

Referências

Documentos relacionados

The non-linear MIMO predictive controller developed in this work used FLNs as internal models and was applied to control the extractive alcoholic fermentation process.. By solving

Guilford (1956) a partir do modelo da estrutura do intelecto deu o grande passo em frente no estudo da criatividade, afirmando que esta se compunha de vários fatores, não se tratando

Vários decretos e despachos da educação especial foram surgindo ao longo dos tempos, mas é com o decreto-lei 319/81 de 23 de Agosto que se dá a abertura da escola

No que diz respeito ao conteúdo, será dada ênfase no emprego de aplicativos (apps) envolvendo as práticas musicais, mas também serão contemplados o ambiente virtual de aprendizagem

A Educação Física (EF) no 1.º Ciclo de Ensino Básico (CEB) em Portugal, apesar de integrar o cur‑ rículo obrigatório, enfrenta muitas dificuldades para se afirmar como área

We thank the students of the Mineralogy II class (period 2017-II, 2018-II), to those responsible for the Laboratory of Petrographic Microscopy of the Department of

5 A liberdade religiosa vai muito além do direito de ter, não ter ou deixar de ter uma religião, ao contrário, como direito complexo garante aos seus titulares uma série de

Em Portugal, o Rio Tejo desenvolveu seis níveis terraços fluviais desde a superfície culminante do enchimento sedimentar da Bacia Cenozóica do Baixo Tejo até ao