Leonardo Gobbi Lopez
PRACTICAL NONLINEAR MODEL PREDICTIVE CONTROL OF A 5 MW WIND TURBINE
Disserta¸c˜ao presented to the Programa de P´os-Gradua¸c˜ao em Engenharia de Automa¸c˜ao e Sistemas in partial ful-fillment of the requirements for the degree of Mestre em Engenharia de Automa¸c˜ao e Sistemas.
Orientador: Prof. Julio Elias Normey-Rico, Dr.
Florian´opolis 2018
Ficha de identificação da obra elaborada pelo autor,
através do Programa de Geração Automática da Biblioteca Universitária da UFSC.
Lopez, Leonardo Gobbi
Practical nonlinear model predictive control of a 5 MW wind turbine / Leonardo Gobbi Lopez ; orientador, Julio Elias Normey-Rico, 2018. 121 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, 2018.
Inclui referências.
1. Engenharia de Automação e Sistemas. 2. Controle Preditivo Baseado em Modelo. 3. Turbina eólica. I. Normey-Rico, Julio Elias. II.
Universidade Federal de Santa Catarina. Programa de Pós-Graduação em Engenharia de Automação e Sistemas. III. Título.
Leonardo Gobbi Lopez
PRACTICAL NONLINEAR MODEL PREDICTIVE CONTROL OF A 5 MW WIND TURBINE
Esta Disserta¸c˜ao foi julgada aprovada para a obten¸c˜ao do T´ıtulo de “Mestre em Engenharia de Automa¸c˜ao e Sistemas”, e aprovada em sua forma final pelo Programa de P´os-Gradua¸c˜ao em Engenharia de Automa¸c˜ao e Sistemas.
Florian´opolis, 28 de mar¸co 2018.
Prof. Daniel Ferreira Coutinho, Dr. Coordenador
Universidade Federal de Santa Catarina Banca Examinadora:
Prof. Julio Elias Normey-Rico, Dr. Orientador
Prof. Marcelo De Lellis Costa de Oliveira, Dr. Universidade Federal de Santa Catarina
Prof. Alexandre Trofino, Dr. Universidade Federal de Santa Catarina
Paulo Renato da Costa Mendes, Dr. Universidade Federal de Santa Catarina
This work is dedicated to my friends and family. That a search for a better world never ends.
ACKNOWLEDGEMENTS
This dissertation came as a result of my two years masters pro-gram in the Departamento de Automa¸c˜ao e Sistemas (DAS) at the Universidade Federal de Santa Catarina (UFSC). I would like to thank my advisor, Julio Elias Normey-Rico, for believing in me and my dis-sertation idea. Your help, knowledge and dedication is an example for me.
I would like to thank all my friends, in particular Vitor Zeni, for giving me the first push into joining the master’s program.
During my master’s program I lost one of my best friends, Arthur de Souza Allievi. That your way of facing life, friendship and jokes live forever through me and everybody that ever met you.
Thanks to my family, Maur´ıcio Lopez, Maria Aparecida Gobbi, Caio Lopez, Maria Paula, Samuel, Mel and Gato for understanding my needs during this period and always being there for me.
Two new people showed up in my life and gave me new meaning and happiness: my beautiful and loving girlfriend Tha´ıs Catapan and our crazy dog Doggo. The difference this new tiny family makes for my life is unmeasurable.
Science is not a body of knowledge nor a system of belief; it is just a term which describes humankind’s incremental acqui-sition of understanding through observa-tion. Science is awesome.
RESUMO EXPANDIDO
Introdu¸c˜ao
Um dos dispositivo usados para capturar energia do vento se chama turbina e´olica. Quando o vento bate em suas h´elices, gera uma for¸ca que a faz girar. Essa energia mecˆanica das p´as ´e transmitida ao gerador el´etrico que por sua vez a converte em energia el´etrica. O mercado de energia e´olica foi o que mais cresceu nos ´ultimos anos no mundo de ener-gias renov´aveis (REN21, 2016) entre 2014 e 2015. Na busca por aumen-tar a eficiˆencia desse dispositivo, v´arias t´ecnicas de controle vˆem sendo estudadas, entre elas controle preditivo baseado em modelo (MPC). Com isso, uma nova t´ecnica de controle preditivo chamada Controle Preditivo Pr´atico N˜ao-linear Baseado em Modelo (PNMPC) foi uti-lizada nessa disserta¸c˜ao para investigar as suas vantagens e desvanta-gens em turbinas e´olicas.
Objetivos
O objetivo da presente disserta¸c˜ao de mestrado ´e controlar uma turbina e´olica utilizando a t´ecnica do PNMPC somente com mudan¸cas l´ogicas ao sistema de controle da turbina, ou seja, sem modifica¸c˜oes f´ısicas da mesma.
Metodologia
O objetivo de controle em uma turbina ´e gerar o m´aximo de energia el´etrica com o m´ınimo de varia¸c˜ao e com o menor dano por fadiga da torre poss´ıvel. Para atingir tal objetivo o PNMPC necessita de um modelo matem´atico fenomenol´ogico interno na forma de uma equa¸c˜ao diferencial ordin´aria, um estimador de velocidade efetiva do vento e um observador de Luenberger, trˆes pontos detalhados e implementados ob-tendo bons resultados: o modelo fenomenol´ogico possui dinˆamicas bas-tante pr´oximas a da turbina estudada sendo modelada as dinˆamicas do eixo de rota¸c˜ao e da torre, o estimador de velocidade efetiva do vento obt´em, atrav´es de uma equa¸c˜ao de equil´ıbrio de torques, uma estima¸c˜ao realista do vento efetivo, o observador de Luenberger obt´em os valores de vari´aveis n˜ao mensur´aveis, como o deslocamento e velocidade de deslocamento da torre de maneira pr´oxima a realidade. A turbina a ser controlada foi desenvolvida pela NREL (National Renewable Energy Laboratory) e ´e de 5 MW em terra do tipo horizontal, upwind e com trˆes p´as. Devido a concorrˆencia forte do mercado e´olico essa turbina foi desenvolvida a partir do conhecimento de duas diferentes turbinas de 5 MW existentes, desenvolvendo uma com caracter´ısticas pr´oximas a
realidade. Para simular e implementar o controlador foi usado um soft-ware CAD (Computer Aided Engineering) da pr´opria NREL chamado FAST, que ´e um simulador de m´edia fidelidade para turbinas e´olicas, em conjunto com MATLAB / Simulink . O algoritmo do PNMPC usaR
ideias similares a MPC lineares como o Generalized Predictive Con-troller (GPC) e o Dynamic Matrix Controller (DMC) com a diferen¸ca presente no c´alculo online a cada tempo de amostragem usado pelo PNMPC. Tal c´alculo lineariza a cada tempo de amostragem o sistema no ponto de opera¸c˜ao atual. Todas as peculiaridades dos controladores e da turbina e´olica s˜ao descritas e detalhadas nesse trabalho.
Resultados e Discuss˜ao
O algoritmo do PNMPC foi comparado com o controlador padr˜ao (base) da ind´ustria (controle de torque ´otimo associado a um contro-lador proporcional-integrativo com anti-windup), com um DMC (para estudar a poss´ıvel vantagem de se linearizar a cada tempo de amostra-gem) e com varia¸c˜oes dentro do pr´oprio PNMPC. O controlador base foi melhor que o PNMPC em regi˜oes de velocidade baixa do vento, mas foi inferior em ventos mais r´apidos. O PNMPC manteve um seguimento de potˆencia el´etrica mais pr´oximo e com menos danos `a torre quando comparado com o controlador base. O DMC demonstrou dificuldades em todas as regi˜oes, principalmente ao se levar em conta os dano da torre, deixando claro que a lineariza¸c˜ao em tempo de amostragem do PNMPC ´e vantajosa.
Considera¸c˜oes Finais
O controlador PNMPC demonstrou ser uma op¸c˜ao vi´avel para o con-trole de turbinas e´olicas, principalmente em regi˜oes de alta velocidade do vento, j´a que, para regi˜oes de baixa velocidade, o controlador base utilizado atualmente obteve resultados melhores. Como trabalhos fu-turos deve-se buscar melhorar os resultados para velocidades baixas do vento e aumentar a fidelidade dos modelos dos atuadores.
Palavras-chave: Controle Preditivo Baseado em Modelo. MPC. Con-trole Preditivo Pr´atico N˜ao-linear Baseado em modelo. PNMPC. Tur-bina e´olica. FAST. Estimador de vento.
ABSTRACT
One of the devices that harvests energy from the wind is called wind turbine. It is a growing market for renewable energy, being the one that must grew in recent years (REN21, 2016). In search for better
ef-ficiency, control algorithms have been sought to obtain higher energy conversion from mechanical to electric and less fatigue to the wind tur-bine’s tower. Model Predictive Controllers (MPC) have shown benefits when implemented in a wind turbine, therefore a novel predictive tech-nique, called Practical Nonlinear Predictive Controller (PNMPC), is used in this work as a middle ground from linear and nonlinear pre-dictive controllers. The turbine controlled in this work is the NREL 5 MW onshore wind turbine using the FAST simulator with MATLAB / Simulink . The PNMPC algorithm uses similar ideas as in the Gen-R
eralized Predictive Controller (GPC) and Dynamic Matrix Controller (DMC), but uses an internal model linearization at each sampling time around the present operational point. To apply the PNMPC in the wind turbine a mathematical model, wind estimator and a Luenberger observer were implemented and showed good results. All peculiarities of the wind turbine are addressed as well as the controller details. The PNMPC’s performance is compared to a baseline controller and other PNMPC’s variations. The baseline controller outperformed the PN-MPC for low wind speeds, but its performance was inferior in high wind speeds scenarios. In high winds the PNMPC kept a tighter elec-tric power capture with less fatigue loads to the tower.
Keywords: Model Predictive Control. MPC. Practical Nonlinear Pre-dictive Control. PNMPC. Wind turbine. FAST. Wind estimator.
LIST OF FIGURES
Figure 1 (a)Vertical-Axis Turbine (b)Horizontal-Axis Turbine . . . 29
Figure 2 (a)Upwind (b)Downwind . . . 30
Figure 3 Upwind horizontal-axis wind turbine components . . . 31
Figure 4 FAST’s modules . . . 32
Figure 5 Blade and tower degrees of freedom . . . 33
Figure 6 Rotor dynamics . . . 35
Figure 7 Simplified rotor dynamics . . . 35
Figure 8 Power coefficient curve (Cp) . . . 37
Figure 9 Torque coefficient curve (Cq) . . . 37
Figure 10 Tower fore-aft bending . . . 38
Figure 11 Thrust coefficient curve . . . 39
Figure 12 Angle of attack . . . 40
Figure 13 Standard IEC turbulence categories . . . 41
Figure 14 TurbSim IEC class A with mean 18 m/s wind. . . 42
Figure 15 Real and effective wind speed . . . 43
Figure 16 Model comparison . . . 44
Figure 17 Model comparison with effective wind speed . . . 46
Figure 18 The real and effective wind used in the simulation . . . 47
Figure 19 Electric power in relation to wind speed . . . 48
Figure 20 Optimum torque controller regions . . . 50
Figure 21 Flowchart of the baseline control system . . . 51
Figure 22 Operation modes of the OT+PI . . . 52
Figure 23 MPC Strategy . . . 54
Figure 24 MPC structure . . . 55
Figure 25 Free and forced response . . . 56
Figure 26 Step response coefficients . . . 59
Figure 27 Block diagram of the prediction filter . . . 64
Figure 28 GP N M P C matrix in example . . . 67
Figure 29 GP N M P C matrix alternate implementation . . . 68
Figure 30 Control scheme A . . . 72
Figure 31 Control scheme B. . . 74
Figure 33 Real wind vs estimated effective wind . . . 78
Figure 34 Luenberger observer efficiency . . . 80
Figure 35 Wind step baseline controller . . . 82
Figure 36 GP N M P C coefficients . . . 84
Figure 37 Switching region . . . 86
Figure 38 Low wind comparison for control problem A . . . 95
Figure 39 Low wind comparison for control problem B . . . 97
Figure 40 PI dip below rated. . . 99
Figure 41 High wind class A comparison for control problem A . . 100
Figure 42 High wind class C comparison for control problem A . . 102
Figure 43 High wind class A comparison for control problem B . . 104
Figure 44 Switching wind comparison for control problem A. . . 107
Figure 45 Switching wind comparison for control problem B . . . 109
Figure 46 DEL comparison. . . 112
LIST OF TABLES
Table 1 NREL 5 MW wind turbine . . . 34
Table 2 Model comparison . . . 45
Table 3 Model comparison with effective wind speed . . . 46
Table 4 Full system natural frequencies . . . 49
Table 5 Possible wind speeds vector example . . . 76
Table 6 Possible values vector example . . . 77
Table 7 Luenberger observer efficiency . . . 81
Table 8 Computational time . . . 83
Table 9 Normalization factor. . . 84
Table 10 PNMPC’s general parameters. . . 87
Table 11 PNMPC’s weights . . . 88
Table 12 PNMPC’s weights . . . 89
Table 13 Wind turbine constraints . . . 89
Table 14 Low wind performance indicators for control problem A. 96 Table 15 Low wind performance indicators for control problem B . 98 Table 16 High wind class A performance indicators for control prob-lem A . . . 101
Table 17 High wind class C performance indicators for control prob-lem A . . . 103
Table 18 High wind class A performance indicators for control prob-lem B . . . 105
Table 19 High wind class C performance indicators for control prob-lem B . . . 106
Table 20 Switching wind performance indicators for control prob-lem A . . . 108
Table 21 Switching wind performance indicators for control prob-lem B . . . 110
Table 22 18 m/s wind class C seed 2 performance for control prob-lem B . . . 114
Table 23 18 m/s wind class C seed 2 performance for control prob-lem B . . . 114
Table 24 18 m/s wind class C seed 3 performance for control prob-lem B . . . 115
LIST OF ACRONYMS AND ABBREVIATIONS
MPC Model Predictive Control
PNMPC Practical Nonlinear Model Predictive Control LIDAR Light Detection and Ranging
FAST Fatigue, Aerodynamics, Structures, and Turbulence NREL National Renewable Energy Laboratory
CAE Computed Aided Engineering
OT Optimum Torque
PI Proportional and integral GPC Generalized Predictive Control NMPC Nonlinear Model Predictive Control
NARMAXNon-linear Auto-Regressive with Moving Average and Exogenous inputs
ODE Ordinary Differential Equation QP Quadratic Programming DEL Damage Equivalent Loads
LIST OF SYMBOLS Pe Electric power v Wind speed ωr Rotor speed J Moment of inertia Rm Rotor radius
Ng Gear box ratio
θ Pitch angle Tg Generator torque hH Hub height ρ Air density η Generator efficiency Ta Aerodynamic torque Cq Torque coefficient λ Tip-speed-ratio Cp Power coefficient Pw Wind power Pr Rotor power
xT Tower fore-aft bending
mT e Tower equivalent modal mass
cT Tower equivalent structural damping
kT Tower equivalent bending stiffness
f0 1st fore-aft natural frequency
ds Structural damping ratio
Fa Aerodynamic thrust
CT Thrust coefficient
τθ Pitch actuator time constant
τT Generator torque actuator time constant
y(t) Output variables at instant t u(t) Input variables at instant t w(t) Reference variables at instant t N1 Lower value of prediction horizon
N Number of points of prediction horizon (N = N2− N1)
Nu Control horizon
F Free response
G System’s dynamic matrix Fsc Uncorrected free response
η(k) Correction factor at instant k Qδ Tracking weight
Qλ Control weight
A System’s dynamic matrix B System’s input matrix C System’s output matrix
CONTENTS 1 INTRODUCTION . . . 25 1.1 OBJECTIVES . . . 26 1.1.1 General objectives . . . 26 1.1.2 Specific objectives . . . 27 1.2 SCIENTIFIC CONTRIBUTION . . . 27 1.3 WORK ORGANIZATION . . . 27 2 WIND TURBINE MODELING . . . 29 2.1 TYPES OF WIND TURBINES . . . 29 2.2 HORIZONTAL-AXIS WIND TURBINE COMPONENTS 30 2.3 AEROELASTIC MODEL . . . 31 2.4 REDUCED NONLINEAR MODEL . . . 35 2.5 WIND . . . 40 2.6 MODEL COMPARISON . . . 43 2.7 BASELINE CONTROLLER . . . 47 2.7.1 Rotor speed filter . . . 48 2.7.2 Optimum torque controller . . . 49 2.7.3 Gain-scheduled PI pitch controller . . . 50 2.7.4 Expected behavior . . . 51 2.8 FINAL COMMENTS . . . 52 3 THEORY OF METHODS . . . 53 3.1 MPC . . . 53 3.1.1 Free and forced response . . . 55 3.1.2 Objective function . . . 56 3.1.3 Constraints . . . 57 3.1.4 Obtaining the control law . . . 57 3.1.5 DMC . . . 58 3.1.6 PNMPC . . . 60 3.1.7 Numeric Prediction . . . 63 3.1.8 Prediction error . . . 63 3.1.9 Cost function . . . 65 3.1.10 Alternate implementation . . . 66 3.2 WIND ESTIMATOR . . . 68 3.3 LUENBERGER OBSERVER . . . 69 3.4 FINAL COMMENTS . . . 70 4 IMPLEMENTATION . . . 71 4.1 CONTROL PROBLEM . . . 71 4.1.1 Control problem A . . . 72
4.1.2 Control problem B . . . 73 4.2 WIND SPEED ESTIMATOR . . . 75 4.2.1 Estimation example . . . 76 4.2.2 Wind estimation filter . . . 77 4.2.3 Wind estimator efficiency . . . 78 4.3 LUENBERGER OBSERVER . . . 79 4.3.1 Luenberger observer efficiency . . . 80 4.4 PNMPC . . . 81 4.4.1 Sampling time . . . 81 4.4.2 Alternate implementation . . . 83 4.4.3 Controller design . . . 85 4.4.3.1 For control problem A . . . 87 4.4.3.2 For control problem B . . . 88 4.4.3.3 Constraints . . . 89 4.5 DMC DEFINITIONS . . . 90 4.6 FINAL COMMENTS . . . 91 5 RESULTS . . . 93 5.1 ANALYZED VARIABLES . . . 93 5.2 LOW WIND SPEEDS . . . 94 5.2.1 Control problem A . . . 94 5.2.2 Control problem B . . . 96 5.3 HIGH WIND SPEEDS . . . 99 5.3.1 Control problem A . . . 99 5.3.2 Control problem B . . . 103 5.4 SWITCHING REGION WIND SPEEDS . . . 106 5.4.1 Control problem A . . . 106 5.4.2 Control problem B . . . 108 5.5 CONCLUSIONS . . . 110 5.5.1 Internal model . . . 110 5.5.2 PNMPC and DMC . . . 111 5.5.3 Control problem A and B . . . 111 5.5.4 Control problem B: PNMPC and baseline . . . 112 5.5.5 Wind seed dependency . . . 113 6 CONCLUSION AND FUTURE WORK . . . 117 REFERENCES . . . 119
25
1 INTRODUCTION
The energy provided by the wind can be captured by a device called Wind Turbine. It is responsible for converting the wind speed into rotational speed of its blades causing the generator to produce electric energy. This system, although not very complex in its pur-pose, needs to be highly efficient to lower the cost of electric energy generation, showing that studying and developing control methods is relevant(RINGWOOD; SIMANI, 2015).
In a global context, the wind energy corresponds to the second highest source of renewable energy for electricity, only behind hydro-electric with 3.7% and 16.6% in 2015, respectively. The advantage in terms of projection comes to the fact that in the same year the world’s installed capacity has expanded 22%, being considered the en-ergy source that most grew between 2014 and 2015. This growth hap-pened mostly due to its undergoing cheapening because, among other factors, the efficiency increased in converting the wind speed into elec-tricity (REN21, 2016).
With regard to Brazil, the wind energy partition grew 32% (REN21,
2016) between 2014 and 2015. The Brazilian wind potential varies de-pending on the study, initially thought to be of 143 GW in 2001, allied with the constant technological innovations, may be as big as 500 GW (DEWI, 2015). Considering that in 2015 Brazil generated 8.7 GW, we
are very far from reaching all available potential in the territory. In 2017, Brazil’s wind energy broke two important records (TRIGUEIRO, 2017): it managed to supply power to 12% of the whole
country and its price per megawatt became cheaper than the last three hydroelectric power plants built.
Being clear the importance of wind energy, several efforts have been conducted in the development of new and better controllers. In particular model predictive control (MPC) strategies have been recently studied. Wind turbine is a multi-variable system that has nonlinear dy-namics and its operation is subject to constraints that demand the use of advanced control techniques to obtain an adequate performance. In this context, model predictive control shows itself as a viable option with growing prospects in search of higher efficiency with less wear by fatigue of the wind turbine. A linear MPC with a set of local mod-els and an extended kalman filter is compared to a baseline controller in (NOVAK; CHAPULA, 2014). In (LIO; ROSSITER; JONES, 2014) the
26
turbines. A Nonlinear MPC with fatigue mitigation was developed in (SCHLIPF; SCHLIPF; K ¨UHN, 2012) using a wind measurement system called LIDAR. Another linear MPC, but focused on load mitigation was developed in (ZIERATH et al., 2015).
The two main advantages of MPC are (ROSSITER, 2003):
• The MPC algorithm takes into account the system’s constraints;
• MPC enables a systematic design for multi-variable problems;
There are a few MPC techniques already applied in different works, but there is a relatively young technique that was not tested yet: Practical Nonlinear Model Predictive Control (PNMPC) (PLUCENIO,
2010).
PNMPC combines linear and nonlinear responses of the system to obtain a more accurate prediction with respect to linear MPC and less computationally heavy than nonlinear MPC. This technique would come as a middle ground between already studied linear and nonlinear MPCs, searching for a compromise between performance and compu-tational burden (YANG; PLUCENIO, 2016).
It calls for attention in some articles, for example in (SCHLIPF; SCHLIPF; K ¨UHN, 2012), the use of a more precise wind speed sensor that is mounted on top of the wind turbine: the LIDAR (Light Detection and Ranging). This approach got 4% in efficiency gain and 30% lower tower fatigue. Unfortunately, the sensor costs around £80.000 - £100.000 (BUSH, 2014).
1.1 OBJECTIVES
1.1.1 General objectives
The present dissertation, in light of the number of model predic-tive controllers being tested nowadays, aims to design a controller using the Practical Nonlinear Model Predictive Control (PNMPC) technique to control a 5 MW wind turbine. The objective is to propose only logi-cal changes to the control algorithm (no physilogi-cal modification), without using any wind measurement sensor. Moreover, it tries to show that this strategy can offer advantages over linear MPCs without the com-plexity of Nonlinear MPC solutions.
27
1.1.2 Specific objectives
To achieve the desired goal, the following specific objectives were established:
• To increase the wind turbine efficiency by utilizing an advanced control technique;
• To generate the maximum electric energy with minimum oscilla-tion as possible;
• To reduce the fatigue damage suffered by the tower; • To propose only logical changes to the wind turbine;
• To comprehend and become proficient in using a wind turbine model simulator called FAST (Fatigue, Aerodynamics, Structures, and Turbulence) (SINGH et al., 2014). FAST is called a “medium-fidelity model” as it is not perfect. However, it provides results which are very similar to those obtained from a real wind turbine, thus being used to better investigate control techniques;
1.2 SCIENTIFIC CONTRIBUTION
The present work had an article presented at the 9th Interna-tional Renewable Energy Congress (IREC) 2018 conference in Tunisia and published in the IEEExplore titled: “Practical Nonlinear Predic-tive Control of a 5 MW Wind Turbine”.
1.3 WORK ORGANIZATION
The rest of this dissertation is organized as follows. Chapter 2 presents the types of wind turbines and models used for simulations, detailing the wind dynamics and the controller used nowadays. Chap-ter 3 explains all the theory behind the implemented model predictive controller. Chapter 4 addresses the implementation used. Chapter 5 shows the results obtained by the PNMPC compared to the baseline controller and the linear MPC. To finish, Chapter 6 wraps the conclu-sions obtained and describes future work to be done.
29
2 WIND TURBINE MODELING
In this chapter the main types of wind turbine are described and the one used throughout the work is further detailed and modeled.
2.1 TYPES OF WIND TURBINES
Wind turbines can be divided in two basic types with regard to the rotational alignment: horizontal and vertical axis. Horizontal ones are more expensive and complex to implement than the vertical ones, but compensate in higher efficiency, being more frequently used in the world (MEYERS, 2013). Figure 1 contains both types.
Figure 1 – (a)Vertical-Axis Turbine (b)Horizontal-Axis Turbine
Source: (RESEARCH HUBS, 2015)
Horizontal-Axis wind turbines can be subdivided into how it aligns with the wind: Upwind and Downwind. The wind reaches pri-marily the rotor in upwind and in downwind the first point of contact is the nacelle. The upwind type is more common because it operates in a safer manner (MEYERS, 2013). The biggest technical difference between
both types is the fact that the downwind ones align passively, without the need for mechanical actuation, to the wind’s direction, while the upwind ones need an actuation through a yaw control algorithm (ori-entation control). It is possible to observe the difference between types in Figure 2.
31
Figure 3 – Upwind horizontal-axis wind turbine components
Source: (DARLING, 2016)
2.3 AEROELASTIC MODEL
The model being controlled is a 5 MW wind turbine developed by the National Renewable Energy Laboratory (NREL)(JONKMAN et al., 2009) and implemented in their simulator FAST(Fatigue, Aerody-namics, Structures, and Turbulence)(JONKMAN; JR., 2005) linked with MATLAB/Simulink .R
FAST is a CAE (Computed Aided Engineering) tool made as a junction of a few modules (AeroDyn, Hydrodyn, Servodyn) that corre-spond to different physical domains related to the wind turbine.
Each module focuses on a different physical dynamics in a wind turbine. FAST allows the designer several degrees of freedom to create and test horizontal-axis wind turbines: Onshore or offshore, two or three blades, small or big, on ice or land. To account for such freedom these modules were designed so the user could simply disable a module
32
of no interest to the work done or modify only one of them. The Figure 4 further clarifies FAST’s modular interface.
Figure 4 – FAST’s modules
Source: (JONKMAN; JONKMAN, 2016)
The module that computes the rotor, drive-train, nacelle and tower dynamics in FAST is called ElastoDyn. Within it one can turn on or off a few degrees of freedom depending on the objective or how close the simulation should be to a real wind turbine. Each degree of freedom and its explanation follows:
• First and second flapwise mode: Bending of the blades in the flapwise direction;
• First edgewise blade mode: Bending of the blades in the edgewise direction;
• Drive-train rotational-flexibility: Bending of the rotor shaft sub-ject to by loads from the wind and generator sides;
• Generator: the torque influence in rotor and generator speed; • Yaw: the orientation variable to align to the wind. If turned off
it maintains a fixed position;
• First and second fore-aft tower bending mode: Bending of the tower parallel to the wind direction;
33
• First and second side-to-side bending mode: Bending of the tower orthogonal to the wind direction;
Figure 5 illustrates the blade and tower degrees of freedom.
Figure 5 – Blade and tower degrees of freedom
Source: (SURYANARAYANAN; DIXIT, 2006)
For the whole work done, all degrees of freedom are on, but the Yaw actuation is off because a different and uncoupled controller would be required and it was considered of minor importance when compared to pitch and torque control. Therefore, the wind exciting the turbine is considered perfectly aligned.
There are two types of pitch control: collective and individual. The first one pitches all the blades together at the same time by the same amount, while the individual pitch approach controls each blade separately. This work focuses on the first one.
The 5 MW wind turbine developed by NREL (JONKMAN et al.,
2009) was an extensive work comparing information from mainly two big known 5 MW wind turbines in the market. Since these types of information are privileged the combination of everything they could acquire plus some extrapolations generated a series of parameters to be applied to the modules in FAST in order to get the closest possible approximation from a 5 MW turbine. These values are shown in Table 1 for an onshore, upwind, horizontal-axis wind turbine with 3 blades and collective pitch control.
34
Table 1 – NREL 5 MW wind turbine
Parameter Symbol Unit Value
Rated power Pe,rated MW 5
Cut-in wind speed vin m/s 3
Rated wind speed vrated m/s 11.4
Cut-out wind speed vout m/s 25
Rated rotor speed ωr,rated rad/s 1.2671
Maximum rotor speed ωr,max rad/s 1.64723
Generator inertia on high-speed shaft Jg kg.m2 534.116
Hub inertia on low-speed shaft JH kg.m2 115926
Blade inertia on low-speed shaft JB kg.m2 11776047
Rotor radius Rm m 63
Gear box ratio Ng - 97
Maximum pitch angle θmax degrees 90
Minimum pitch angle θmin degrees 0
Maximum pitch rate ∆θmax degrees/s 8
Minimum pitch rate ∆θmin degrees/s -8
Maximum generator torque Tg,max N.m 47402.97
Minimum generator torque Tg,min N.m 0
Maximum generator torque rate ∆Tg,max N.m/s 15000
Minimum generator torque rate ∆Tg,min N.m/s -15000
Hub Height hH m 90
Hub height air density ρ Kg/m3 1.225
Generator efficiency η % 94.4
Natural frequency of 1st tower fore-aft bending f0 Hz 0.32
Structural damping ratio ds - 0.01
36
J is the sum of moments of inertia as in (2.2), Ta is the aerodynamic
torque that is a function of the pitch angle (θ), wind speed (vrel) and
rotor speed (ωr) seen in (2.3) , Tg is the electric torque on to the
generator, and Ng is the gear box ratio.
J = JH+ 3JB+ JgNg2 (2.2)
where JH is the hub inertia, JB the blade inertia and Jg the generator
inertia.
The torque transmitted by the wind is given by Ta =
1 2ρπR
3
mCq(λ, θ)vrel2 (2.3)
where ρ is the air density, Rm is the rotor radius, Cq is the torque
coefficient, obtained from a table that is a function of the tip-speed-ratio (λ) in (2.4) and the pitch angle (θ), defined as
λ = Rmωr vrel
(2.4) The torque coefficient Cq can be derived from the power
coeffi-cient Cpas
Cq(λ, θ) =
Cp(λ, θ)
λ (2.5)
Cq and Cp vary between wind turbines and are experimentally
obtained by the manufacturer. For this dissertation the NREL 5 MW wind turbine was simulated using FAST to obtain these values for a wide range of tip-speed-ratios and pitch angles and then interpolated for higher sensitivity. Cpis used to calculate the fraction of wind power
(Pw), in (2.6), that is converted to rotor power (Pr), in (2.7). Cq, on
the other hand, translates the wind directly to torque as was seen in (2.3). The surface plot of Cq and Cpare shown, respectively, in Figures
8 and 9 Pw= 1 2ρπR 2 mv3rel (2.6) Pr= PwCp(λ, θ) (2.7)
38
Figure 10 – Tower fore-aft bending
Source: (SCHLIPF; SCHLIPF; K ¨UHN, 2012)
The tower fore-aft dynamics is modeled as a spring-mass-damper system not influenced by gravity (SCHLIPF; SCHLIPF; K ¨UHN, 2012) as
in (2.9).
mT ex¨T+ cT˙xT+ kTxT = Fa( ˙xT, ωr, θ, v0) (2.9)
where Fa is the aerodynamic thrust, mT e, cT and kT are, respectively,
the tower equivalent modal mass, structural damping and bending stiff-ness calculated as
mT e= 0.25mT + mN + mH+ 3mB (2.10)
cT = 4πmT edsf0 (2.11)
kT = mT e(2πf0)2 (2.12)
The aerodynamic thrust, in (2.13), requires another coefficient to be calculated: the thrust coefficient (CT), in Figure 11.
Fa=
1 2ρR
2
39
Figure 11 – Thrust coefficient curve
Source: Author
The thrust coefficient determines how much of the wind is being converted into an axial force in the rotor that bends the tower.
Since the reduced model only has the rotor speed dynamic, a simple gear box ratio multiplication gives the generator speed, thus, allowing the calculation of electric power (Pe) by taking into
consider-ation the generator efficiency (η), as
Pe= ωrTgNgη (2.14)
There is no actuator dynamics directly programmed withing FAST, but interfacing it with MATLAB/Simulink allows the imple-R
mentation of such dynamics. There are works focused on more realistic control of pitch and generator torque, taking into account more pre-cise models of the actuators. Nevertheless, this dissertation focuses on the reference sent to these subsystems and models them as simple first order approximations as in (2.15) and (2.16). According to ( RING-WOOD; SIMANI, 2015), these closed-loop dynamics approximations are sufficient for control purposes:
˙θ = −1 τθ θ + 1 τθ θr (2.15) ˙ Tg= − 1 τT Tg+ 1 τT Tgr (2.16)
40
where τθ and τT are the time constants for the pitch and torque. θr
and Tgrare the references provided to the actuators by the controller.
To further comprehend the pitch angle (θ), Figure 12 shows a cross section of the wind turbine’s blade to define the attack angle (α) and the resulting forces: lift (L) and drag (D). φ is the angle of relative wind. θi is the inclination of local blade chord to rotor plane, an angle
that depends on the pitch angle.
Figure 12 – Angle of attack
Source: (BURTON et al., 2011)
2.5 WIND
The main objective of the wind turbine is to extract power from the wind, therefore it is necessary to have a close to real wind data to excite the turbine model. To achieve this goal another program from NREL called TurbSim was used (JONKMAN; KILCHER, 2012). TurbSim receives as input a series of parameters depending on the desired wind to be created and it interfaces with FAST natively.
One can separate the wind into two main dynamics: mean wind speed and turbulence. The mean wind speed is generally taken as an-nual measurements from a certain region as the value changes based on geographical characteristics, time during the day and seasonal vari-ations. The turbulence is also affected in the same way as the mean wind speed but it is of much higher frequency. It is very common to model the wind as a mean wind speed, a constant parameter, added by a turbulence, a varying parameter.
41
Since, in this work, TurbSim is used, all that matters is to cor-rectly set it to create the right wind for the model analysis. For that, the existing IEC 61400 standard has the purpose of ensuring that wind turbines are appropriately engineered. In this set of requirements there is detailed information of turbulence in relation to mean wind speed depending on the region considered, whether in continental land, off-shore or near the coast. Figure 13 shows the standard deviation (σ1)
and turbulence intensity in relation to hub-height wind speed (vhub) for
classes A, B and C of turbulence, A being the highest, and for NTM (Normal Turbulence Model), ETM (Extreme Turbulence Model) and EWM (Extreme Wind Speed Model). Throughout this work the NTM classes A, B and C for continental land are used.
Figure 13 – Standard IEC turbulence categories
Source: (JONKMAN; KILCHER, 2012)
The wind has very slow variations with regards to its direction, on a magnitude of hours (HENRIKSEN, 2007), giving another reason for omitting yaw control as it is responsible for proper wind turbine align-ment. Therefore, Figure 14 shows the parallel to the nacelle component going from rotor to nacelle of the wind, generated by TurbSim for a demanded eighteen meters per second mean speed.
42
Figure 14 – TurbSim IEC class A with mean 18 m/s wind
Source: Author
With regard to wind turbines, the wind perfectly measured on the nacelle does not directly translate into usable wind, because the wind turbine works like a filter for the incoming wind, creating a dif-ferentiation between real wind and effective wind. The effective wind is the portion of it that is responsible for generating the turbine dy-namics, and, therefore, the wind that serves as input to the reduced model previously developed. Figure 15 shows an example on how dif-ferent these two winds are. More clarifications will follow throughout the work.
43
Figure 15 – Real and effective wind speed
Source: Author
The effective wind above was obtained with the use of a wind estimator that will be detailed later. Roughly it estimates the effective wind based on the real wind turbine dynamics taken as filtered outputs. So it was obtained by simulating FAST and estimating in real time.
2.6 MODEL COMPARISON
The reduced model must be validated as a reasonably good ap-proximation to the aeroelastic model in FAST. In the simulations the same inputs - pitch angle, wind speed and torque - are used in both models and took the rotor speed, fore-aft displacement and velocity as outputs. FAST provides the rotor speed and fore-aft displacement di-rectly while the velocity is taken by the derivative of the displacement. The reduced model and FAST response can be seen in Figure 16. The input values were chosen in a way that the simulation would be close to the operational regime of the 5 MW wind turbine.
45
Table 2 – Model comparison
Output NRMSE
Rotor speed 0.87
Fore-aft displacement 0.73 Fore-aft velocity 0.58
Source: Author
As stated previously, the use of effective wind instead of real wind can improve the values above. To confirm this fact the next simulation, in Figure 17, shows this change for the same inputs, but this time the wind exciting the reduced model is the effective one. One can see the improvement in numbers by comparing Tables 2 and 3.
46
Figure 17 – Model comparison with effective wind speed
Source: Author
Table 3 – Model comparison with effective wind speed
Output NRMSE
Rotor speed 0.99
Fore-aft displacement 0.79 Fore-aft velocity 0.57
Source: Author
The only number that did not improve was the mean fore-aft velocity value. This most likely happened because the effective wind
48
Figure 19 – Electric power in relation to wind speed
Source: (LIO; ROSSITER; JONES, 2014)
The baseline controller for wind turbines decouples the torque and pitch controllers based on the regions seen in Figure 19. For region I the torque and pitch angle must be kept zeroed until there is enough wind. In region II the pitch angle is kept as zero and the torque is responsible for keeping maximum power generation, this is called Op-timum Torque controller. When the wind is strong enough the turbine enters region III, where the torque is inversely proportional to the fil-tered generator speed and a gain scheduled based PI pitch controller with anti-windup aims to keep the rotor speed constant to maintain rated power. In Region IV the emergency breaks must be used to completely stop the turbine.
The measured and controlled variable in the baseline controller, is the generator speed (or rotor speed depending on the implemen-tation) filtered by a low-pass filter with corner frequency of 0.25 Hz (JONKMAN et al., 2009).
To better comprehend the controller each part will be explained separately.
2.7.1 Rotor speed filter
The measured rotor speed is filtered to mitigate high-frequency mode excitations, mainly the blade’s first edgewise natural frequency in Table 4, therefore a single pole low pass filter with corner frequency of 0.25 Hz was used to achieve high mitigation at 1.08 Hz. It is important to state the fact that this frequency was chosen based on the 5 MW wind
49
turbine studied here, as each specific turbine would require different filter corner frequencies.
Table 4 – Full system natural frequencies
Description Frequency in FAST (Hz)
1st Tower Fore-Aft 0.3240
1st Tower Side-to-Side 0.3120
1st Drive-train Torsion 0.6205
1st Blade Asymmetric Flapwise Yaw 0.6664 1st Blade Asymmetric Flapwise Pitch 0.6675 1st Blade Collective Flap 0.6993 1st Blade Asymmetric Edgewise Pitch 1.0793 1st Blade Asymmetric Edgewise Yaw 1.0898 2nd Blade Asymmetric Edgewise Yaw 1.9337 2nd Blade Asymmetric Edgewise Pitch 1.9223
2nd Blade Collective Flap 2.0205
2nd Tower Fore-Aft 2.9003
2nd Tower Side-to-Side 2.9361
Source: (JONKMAN et al., 2009)
2.7.2 Optimum torque controller
The optimum torque controller is a tabulated function of the filtered generator speed, for each speed there is a predefined generator torque input. It works in five control regions: I, I12, II, II12, and III. The first half region introduced is used to accelerate the rotor to start generating, the second one is a small region used to speed up the rotor speed to rated values. Figure 20 clarifies these regions.
50
Figure 20 – Optimum torque controller regions
Source: (JONKMAN et al., 2009)
The optimum curve, as seen in black in Figure 20, denotes the necessary torque value to be used with respect to the filtered generator speed that will obtain the maximum power extraction from the wind. This value is directly related to the power coefficient, as is the one that tracks the maximum value of the curve in Figure 8.
According to Betz’s limit, the maximum possible value of kinec-tic energy of the wind that can be used to spin the turbine is of 59.3% (BETZ, 1966), but that is unachievable as there are other losses not
taken into account. Therefore the power coefficient curve, for the NREL 5 MW wind turbine, has a maximum value of 0.482 at a tip-speed-ratio of 7.55 and zeroed pitch angle.
The optimum torque controller keeps the generator speed at val-ues that correspond to a tip-speed-ratio of 7.55, as calculated in (2.4), when in region II, whereas in region III the objective is to maintain the rated power output.
2.7.3 Gain-scheduled PI pitch controller
The collective pitch controller is a gain-scheduled proportion-integral controller on the speed error between the filtered generator speed and the rated speed.
51
at its rated value as it only actuates in region III. Since it is a highly nonlinear region a gain schedule is used to modify its dynamics for each generator speed exciting the system.
2.7.4 Expected behavior
To summarize, Figure 21 demonstrates the control design, while Figure 22 shows the expected behavior of inputs and outputs.
Figure 21 – Flowchart of the baseline control system
52
Figure 22 – Operation modes of the OT+PI
Source: (JONKMAN et al., 2009)
2.8 FINAL COMMENTS
In this chapter the main components and types of wind turbines were discussed to arrive into a common ground of the most efficient type: upwind horizontal-axis wind turbine with three blades.
After that definition, a standard turbine was characterized as the NREL 5 MW onshore wind turbine because there is a fair amount of works based upon it. This wind turbine was developed for use in a simulation environment called FAST, that was also explained in this section.
Since this work relies on models, a nonlinear wind turbine model was developed to account for the main dynamics and compared directly with the simulated NREL 5 MW in FAST, showing good results.
A few aspects of how the wind works and how it interacts with the turbine were clarified as well.
To finalize, the baseline controller was explained, as it will be the main tool for comparison used throughout this work.
The next chapter will detail all the necessary theory behind the controller implemented in the wind turbine.
53
3 THEORY OF METHODS
With the turbine model and baseline controller described, this chapter will provide the necessary theoretical background to under-stand the controller implemented in this dissertation.
3.1 MPC
Model predictive control (MPC) is used to name a family of control algorithms that uses a system model to predict the future state of a given process and minimizes an objective function. Therefore, the internal model of the system is of utmost importance to this class of controller.
The main linear MPC strategies known nowadays are the Dy-namical Matrix Control (DMC) and the Generalized Predictive Control (GPC), well detailed in (CAMACHO; BORDONS, 2007). These techniques
vary depending on the model used to predict the outputs of the system, and both can be used for single or multivariable problems.
MPC has some advantages when compared to other control tech-niques, such as (CAMACHO; BORDONS, 2007):
• The concept is very intuitive with relatively easy tuning; • It can be used for a great variety of processes;
• It is easy applicable to multivariable systems; • It intrinsically compensates for dead times;
• It compensates for measurable disturbances by naturally applying a feed forward control;
• It is an easy-to-implement control law; • It takes into account the system’s constraints; • It is very useful when futures references are known;
• It is an open methodology that allows for future extensions; Unfortunately there are two main drawbacks:
• The algorithm is more computationally heavy than a classical PID, being a factor to be taken into consideration;
54
• The performance is highly dependent on the internal model dis-crepancy to the real process;
MPC algorithms have been used with good success for a variety of processes and, with the evolution of components, the computational burden is decreasing.
On a more generalized approach, all MPCs have a common strat-egy: First, the future outputs of the system are determined for a pre-diction horizon (N ) at each instant t, resulting in the predicted outputs ˆ
y(t+k|t) for k = 1...N (reads as follows: the predicted variable value at instant t + k calculated in instant t). The variable output is dependent on the previous and known values up to instant t for inputs and out-puts and on the future control signals u(t + k|t) for k = 0...N − 1 that will be sent to the system. Secondly, the future set of control signals is calculated by optimizing a criterion that keeps the outputs as close as possible to the reference trajectory w(t + k). Thirdly, the control signal u(t|t) is sent to the process and at the next sampling instant y(t + 1) the whole calculation strategy restarts. Figure 23 illustrates the inputs and outputs dynamics explained above.
Figure 23 – MPC Strategy
Source: (CAMACHO; BORDONS, 2007)
To summarize, an internal model in the MPC strategy is used to predict the future of outputs based on previous values and future
55
control actions. These values are compared with the desired reference trajectory for the process, generating the future errors. The errors go through an optimizer that has a cost function (usually to minimize the error to reference) and the system’s constraints. The optimizer defines the future control input to the system. In the next sampling time the new output and input becomes the previous ones and the logic loops, as can be seen in Figure 24.
Figure 24 – MPC structure
Source: (CAMACHO; BORDONS, 2007)
The next sections explain key concepts from the MPC family of controllers.
3.1.1 Free and forced response
Free and forced response is a way to represent the control actions as a sum of two signals:
u(t) = uf(t) + uc(t) (3.1)
where uf(t) are the inputs prior to instant t and uc(t) are the future
main-56
tained constant and equal to its last value, while the signal uc(t) is
considered as zero in the past and equal to the next future control values(CAMACHO; BORDONS, 2007).
The free response yf(t) is the output prediction when the
ma-nipulated variable is uf(t). The forced response yc(t) is the output
prediction when the input is uc(t). As can be seen in Figure 25, for
a linear system, the free response is the evolution of the process with-out changes in the control variable while the forced response takes into consideration the future control movement.
Figure 25 – Free and forced response
Source: (CAMACHO; BORDONS, 2007)
3.1.2 Objective function
Generally the cost function of the MPC is one that minimizes the error of reference (w) tracking by the output (y) while taking into consideration the control effort (∆u) where ∆ = 1−z−1is the increment
operator. For such task the general expression of an objective function is as follows (CAMACHO; BORDONS, 2007):
J = N2 X j=N1 δ(j)[ˆy(t + j|t) − w(t + j)]2+ Nu X j=1 λ(j)[∆u(t + j − 1)]2 (3.2)
The first sum term in (3.2) minimizes the reference tracking er-ror from the minimum (N1) to the maximum (N2) prediction horizon
57
second term minimizes the control effort from the next sampling instant to the control horizon (Nu) weighted by λ. The control horizon defines
in how many manipulated variable actions one expects to achieve the minimum value for the cost function J.
3.1.3 Constraints
Every process is subject to constraints, whether in its manip-ulated variables or in its outputs. This adds more complexity to the cost function in the form of maximum and minimum values (CAMACHO; BORDONS, 2007):
umin ≤u(t) ≤ umax, ∀t
∆umin ≤∆u(t) ≤ ∆umax, ∀t
ymax≤y(t) ≤ ymin, ∀t
(3.3)
where the first line represents the maximum and minimum values for the control action, the second line stands for the maximum and min-imum control action variations and the last line states the maxmin-imum and minimum values for the output variable.
There are other forms of constraints, more complex than the ones in (3.3), but only these ones are used throughout this work.
3.1.4 Obtaining the control law
The final concept is obtaining the future control increments ∆u(t+ k|t). For that, three steps are summarized (YANG; PLUCENIO, 2016):
1. Obtain the prediction value ˆy(t + k|t) as a function of future control signals;
2. Substitute ˆy and w in the cost function J;
3. Minimize J taking into account the weights and constraints; The result is a sequence of Nu future control increments where
only the first one will be used. Only the first one because the algorithm recalculates the next input at each sample time (CAMACHO; BORDONS,
58
3.1.5 DMC
DMC stands for Dynamic Matrix Control and it is a MPC strat-egy typically used in the petrochemical industry, characterized by using a step response model of the system. It was developed in the late sev-enties by (CUTLER; RAMAKER, 1980).
The step response model is defined by (3.4).
y(t) =
∞
X
i=1
gi∆u(t − i) (3.4)
The prediction along the N horizon is calculated by adding the disturbance prediction ˆn(t + k|t), considered constant along the predic-tion horizon and defined by (3.5), with ymbeing the measured output
value (CAMACHO; BORDONS, 2007).
ˆ
n(t + k|t) = ˆn(t|t) = ym(t) − ˆy(t|t) (3.5)
Resulting in the output predicted value in:
ˆ y(t + k|t) = k X i=1 gi∆u(t + k − i) + ∞ X i=k+1 gi∆u(t + k − i) + ˆn(t + k|t) (3.6)
Equation (3.6) is separated in two sums: the left one has the past values while the right one the future values. By taking (3.5) into (3.6) it is possible to achieve (3.7). ˆ y(t + k|t) = k X i=1 gi∆u(t + k − i) + ym(t) + ∞ X i=1 (gk+1− gi)∆u(t − i) (3.7)
The last two parts of (3.7) form the free response of the system f (t + k): f (t + k) = ym(t) + ∞ X i=1 (gk+1− gi)∆u(t − i) (3.8)
If the system is stable the step response coefficients gi will tend
to a constant value after N samples, as seen in Figure 26 (YANG; PLUCE-NIO, 2016).
59
Figure 26 – Step response coefficients
Source: (CAMACHO; BORDONS, 2007)
Now that gk+1− gi ≈ 0 for i > N the free response can be
calculated as in (3.9) f (t + k) = ym(t) + N X i=1 (gk+1− gi)∆u(t − 1) (3.9)
Therefore, each sample time prediction from k = 1, . . . , N will have the form as in (3.10) for Nucontrol actions.
ˆ
y(t + 1|t) = g1∆u(t) + f (t + 1)
ˆ
y(t + 2|t) = g2∆u(t) + g1∆u(t + 1) + f (t + 2)
.. . ˆ y(t + N |t) = N X i=N −Nu+1 gi∆u(t + N − i) + f (t + N ) (3.10)
The system predictions can be written in matrix form as ˆ
60
where G is the system’s dynamic matrix, ∆u is the vector of future con-trols and f is the free response vector, all defined as (YANG; PLUCENIO, 2016). G = g1 0 . . . 0 g2 g1 . . . 0 .. . ... . .. ... gNu gNu−1 . . . g1 .. . ... . .. ... gN gN −1 . . . gN −Nu+1 ∆u = ∆u(k) ∆u(k + 1) .. . ∆u(k + Nu) f = f (t + 1) f (t + 2) .. . f (t + N ) (3.12)
To comprehend the DMC technique is critical to better under-stand the PNMPC variation in the next section.
3.1.6 PNMPC
Practical Nonlinear Predictive Control (PNMPC), developed in (PLUCENIO, 2010) and further detailed and tested in (YANG; PLUCENIO,
2016), is a predictive technique that is a middle ground between linear and Nonlinear MPC (NMPC).
As stated, predictive controllers need a good internal model to adequately compute the control law. Unfortunately, most processes are nonlinear and the usual route is to obtain the model by linearization around an operation point. This usual route is not always capable of dealing with strong nonlinearities or with a plant that often deviates from the linearization point. Gain scheduling techniques is a common way to address this issue by varying a parameter based on the present operation point to account for the system’s nonlinearities. Another method is to directly use a nonlinear model.
61
The NMPC is conceptually close to linear MPC as it minimizes the same cost function, but in a practical sense it gets complicated in the following aspects (CAMACHO; BORDONS, 2007):
• The use of nonlinear identification techniques;
• To obtain the control signal it is necessary to solve a non-convex optimization problem;
• Stability and control quality issues; • Computationally heavy;
Nevertheless, NMPC is a very promising and open field of re-search (GR ¨UNE, 2011).
To deal with nonlinear systems there are a few MPC techniques classified in three groups (YANG; PLUCENIO, 2016):
1. Techniques that use a generic nonlinear model and a nonlinear optimizer of general purpose;
2. Techniques that use specific nonlinear models with a specific op-timizer for the chosen model;
3. Techniques that use one or a series of linear models to represent the process with a linear optimizer;
Each of the above options has its advantages and drawbacks, usually related to performance and computational burden.
The PNMPC technique aligns with the third class, showing good performance in nonlinear processes and is of fairly simple implementa-tion.
PNMPC’s main characteristic is to consider, at every sample time, a linear approximation of a nonlinear prediction model to conse-quently use a quadratic optimization algorithm. The DMC’s internal model is obtained by the step response of a given process and the PNMPC does it at every sample time and, therefore, linearizes it for the present operational point. PNMPC can be seen as a type of gain scheduling MPC but computationally heavier.
The same way as the DMC, predictions along the prediction horizon are a function of the free response and of the future control actions, as in (3.11) (PLUCENIO, 2010).
The only variables that can alter the value of the future predic-tions are the future increments ∆u, therefore the system is linearized
62
with respect to it. It is assumed that the predictions ˆy depend on the past control ←u , present and past outputs ←− −y , and the future control increments ∆u:
ˆ
y = f (←−y , ←−u , ∆u), (3.13) and can be further rewritten as
ˆ
Y ≈ F + GP N M P C∆u (3.14)
where F = f (←−y , ←−u ) and GP N M P C = ∂∆u∂ ˆY . The representation in
(3.14) is a first order approximation of the Taylor series for ∆u = 0. GP N M P C, much like in DMC’s (3.12), is a matrix of step
re-sponse coefficients defined by the jacobian in (3.15) calculated at the input u point. GP N M P C= ∂ ˆY(k+1) ∂∆u(k) 0 0 0 ∂ ˆY(k+2) ∂∆u(k) ∂ ˆY(k+2) ∂∆u(k+1) 0 0 .. . ... . .. ... ∂ ˆY(k+N ) ∂∆u(k) ∂ ˆY(k+N ) ∂∆u(k+1) . . . ∂ ˆY(k+N ) ∂∆u(k+Nu−1) (3.15)
The triangular form of the GP N M P C matrix is because the
sys-tem is strictly casual: the output depends only on past and current in-puts and there is no direct feed between input and output. The matrix G in DMC and GP N M P C are the same for linear systems (PLUCENIO et al., 2007).
The main characteristic of the PNMPC is the numeric determi-nation of the GP N M P Cmatrix. There are various alternatives to create
a model of nonlinear processes, for example: artificial neural networks and NARMAX (Non-linear Auto-Regressive with Moving Average and Exogenous inputs) models (YANG; PLUCENIO, 2016). Normally the
ja-cobian matrix is a function of the mathematical model of the process, but in the PNMPC case it is conceived through numeric algorithms, solving an ODE (Ordinary Differential Equation) to obtain the pre-dicted outputs and calculating the jacobian at the input point for ex-ample, making the technique more practical.
63
3.1.7 Numeric Prediction
To obtain the predicted output ˆY it is necessary to numerically calculate F and GP N M P C using the previous controls and outputs
to-gether with the future control increments ∆u. To achieve such results, for a SISO system, one must (YANG; PLUCENIO, 2016):
1. obtain the predicted output vector ˆY0
N of size N ×1 by running the
algorithm that models the process with past outputs and inputs for null future increments ∆u = [0 . . . 0]T
2. make F = ˆY0 N;
3. obtain the predicted output vector ˆY1
N of size N ×1 by running the
algorithm that models the process with past outputs and inputs for a small future control increment ǫ using ∆u = [ǫ 0 . . . 0]T;
4. make the first column of the approximate partial derivative from output to input GP N M P C(:, 1) = ˆ Y1 N− ˆY 0 N ǫ ;
5. obtain the predicted output vector ˆY2
N of size N ×1 by running the
algorithm that models the process with past outputs and inputs for a small future control increment ǫ using ∆u = [0 ǫ . . . 0]T;
6. make the second column of the approximate partial derivative from output to input GP N M P C(:, 2) =
ˆ Y2 N− ˆY 0 N ǫ ;
7. proceed computing the GP N M P Ccolumns until it reaches the last
one ˆYNu
N with ∆u = [0 0 . . . ǫ]T generating GP N M P C(:, N u) = ˆ
YNNu− ˆY0 N
ǫ
With F and GP N M P C, the prediction vector ˆY of (3.14) can
be calculated. To obtain the control action, the same algorithm as in DMC is used. One difference between PNMPC and DMC is the fact that the free response is purely nonlinear (PLUCENIO, 2010).
3.1.8 Prediction error
The DMC has a logic to correct predictions that guarantees no error in steady state for linear systems. Unfortunately, for nonlinear systems that is not the case. The PNMPC uses an explicit correction mechanism.
64
To deal with prediction error, noise and disturbances, the PN-MPC algorithm adds to each prediction the filtered prediction error integral. The block diagram for this is in Figure 27.
Figure 27 – Block diagram of the prediction filter
Source: (PLUCENIO, 2010)
At each sampling time the error between the predicted output at instant k, ˆy(k|k − 1), and the real output y(k) is calculated as
e(k) = y(k) − ˆy(k|k − 1) (3.16) Changing to the z operator and defining Df(z) = 1 − fdz−1
makes the prediction error transfer function as in (3.17). e(z) = z 2− (1 + f d)z + fd z2− (1 + f d− ki)z + fd (y(k) − ˆysc(k)) (3.17)
where ˆysc(k) is the uncorrected predicted output and y(k) is the real
output.
By applying the final value theorem, the integrator 1 − z−1 in
the denominator guarantees zero error in steady state for a step input in (y(k) − ˆysc(k)).
For the filter design, one must simply define a in (3.18) that makes a fast enough response, but taking into consideration the noise amplification that can occur.
65
fd= a2
ki= 1 + a2− 2a
(3.18)
The correction factor η(k), calculated in the sample time k and used for the k + 1 until k + N prediction, is obtained as
η(z−1) = 1
1 − fdz−1
1 1 − z−1e(z
−1) (3.19)
A sample time implementation of the prediction filter is as fol-lows:
e(k) = y(k) − ˆy(k − 1|k)
η(k) = η(k − 1)(1 + fd) − fdη(k − 2) + e(k)ki
F = Fsc+ η(k)
(3.20)
The final line in (3.20) describes where the correction factor should be added in the uncorrected free response vector Fsc. It is
important to keep in mind these two types of free response, as both are used by the algorithm in different ways. The uncorrected one is used to compute the GP N M P C while the corrected one is used inside the cost
function described next.
3.1.9 Cost function
The typical cost function used by the PNMPC technique for a SISO system can be rewritten based on (3.2) as
J = N2 X j=N1 δ(j)[ˆy(k + j) − w(k + j)]2+ Nu X j=1 λ(j)[∆u(k + j − 1)]2, (3.21)
considering the sample period k, where δ and λ are weights for reference (w) tracking and control effort, respectively.
The problem to be solved consists of obtaining the control incre-ment vector in (3.22) that minimizes the cost function J, in equation (3.21), subject to constraints in inputs and outputs.
66
∆u = [∆u(k), ∆u(k + 1), . . . , ∆u(k + Nu− 1)] (3.22)
For constrained systems the controller must solve a Quadratic Programming (QP) problem, formulated as
minimize ∆u 1 2∆u TH∆u + bT∆u subject to Au ≤ c (3.23)
with H and b defined as
H = GTQ
δG + Qλ
b = GTQT
δ(F − w)
(3.24)
where Qδis a diagonal matrix containing the reference tracking weights,
w is the reference trajectory along the prediction horizon, and Qλis a
diagonal matrix containing the weights for control effort. To finalize, simply pass all values and constraints as a matrix to a QP solver and obtain the future increments vector ∆u.
In an unconstrained case the answer can be obtained explicitly as
∆u = (GTQδG + Qλ)
−1GTQT
δ(w − F ) (3.25)
3.1.10 Alternate implementation
In (YANG; PLUCENIO, 2016) the authors discussed a few
alter-nate implementations of the PNMPC, usually sacrificing performance to obtain faster running algorithms. Only one alternate implementa-tion is discussed here as it is the one used in all simulaimplementa-tions. It consists of only obtaining one column of the matrix GP N M P C.
The alternate technique considers the system as time invariant. To assume that, it is necessary to evaluate the process as to confirm zero or small time variance. As an example, a given process was be-ing controlled by a standard PNMPC and in a random iteration the GP N M P C matrix was analyzed. Figure 28 shows the matrix.
67
Figure 28 – GP N M P C matrix in example
Source: (YANG; PLUCENIO, 2016)
As can be seen in Figure 28, the values seen diagonally are very approximate. This denotes a smooth and small nonlinearity, allowing the use of the alternative technique.
Since the system is now assumed to be time invariant, only the first column of the jacobian matrix needs to be computed, copied and displaced to form an inferior triangular matrix as in Figure 29.
68
Figure 29 – GP N M P C matrix alternate implementation
Source: (YANG; PLUCENIO, 2016)
This alternate PNMPC technique is considerably more compu-tationally efficient and its drawback is strongly dependent on how time variant the system is.
3.2 WIND ESTIMATOR
The wind speed measurement is not typically available on MW-scale wind turbines, creating the necessity to estimate it. The logic be-hind this approach was used in (MATELJAK; PETROVI ´C; BAOTI ´C, 2011).
The principle relies in torque equilibrium equations. Torque is a rotational force defined as
τ = I ˙ω (3.26)
where I is the inertial moment of the body and ˙ω is its angular accel-eration.
69
in the low speed shaft:
1. the torque provided by the wind, Ta in (2.3);
2. the generator torque, Tg;
3. the difference from the torques above, J ˙ωr;
The three torques above were presented in Section 2.4 and form together the equation of rotor dynamics (2.1). Therefore, to obtain the wind estimation it is necessary to find the wind that balances the aforementioned equation. To better clarify, function fw in (3.27) has a
zero value if the effective wind vef f is equal to the estimated one ˆvef f.
fw(ˆvef f) = Ta− TgNG− J ˙ωr (3.27)
Unfortunately, the aerodynamic torque Ta is more complex to
estimate as it depends on the torque coefficient Cq, presented in Figure
9. The implementation of this technique will be further detailed in the next chapter.
3.3 LUENBERGER OBSERVER
Not all relevant information about a system can be measured, in control theory when there is a need to know an unmeasured value the use of observers are recommended. Observers use the available information of the system to estimate additional values.
Observers were designed by David G. Luenberger based on linear time invariant state-space systems of the form
˙x(t) = Ax(t) + Bu(t)
y(t) = Cx(t) + Du(t) (3.28)
where A is the dynamic matrix of the system, B the input matrix, C the output or sensor matrix and D the direct feedthrough matrix. x(t), y(t) and u(t) are the system states, outputs and inputs, respectively.
Luenberger defined observers in (LUENBERGER, 1979) as quoted:
The observer is itself a linear dynamic system. Its input values are the values of measured outputs from the original system, and its state vector generates missing information about the state of the original system. The observer can be
70
regarded as a dynamic device that, when connected to the available system outputs, generates the entire state.
A trivial observer would be a direct copy of the system in 3.28, but that would only work if the initial states of the system and the observer matched perfectly. As this is not the usual case, it is necessary to augment it by incorporating a term that depends on the difference between the real and the observed output. Considering the observer states as z(t) and the real states as x(t), we can obtain the structure of the observer, for some gain matrix L, as
˙z(t) = Az(t) + Bu(t) + L[y(t) − (Cz(t) + Bu(t))] (3.29) where L is the observer gain matrix and must be defined such that, for continuous systems, the eigenvalues of the matrix A − LC are in the left half plane, therefore, stable.
3.4 FINAL COMMENTS
In this chapter, all the theory behind the work done in this dis-sertation was explained as generically as possible, as the next chapter will focus purely on the wind turbine subject.
The MPCs strengths and drawbacks together with its character-istics were detailed to be able to explain DMC in such a way that it could clarify the connection between it and the PNMPC algorithm, as both use step responses of the system to predict outputs.
PNMPC is the technique implemented in this work and, there-fore, was further detailed.
Since the scope is wind turbines, a technique to estimate the wind and other turbine dynamics with an observer was clarified prior to directly define how to implement them.
The next chapter will show how each technique was implemented in a wind turbine.
71
4 IMPLEMENTATION
This chapter is dedicated to explain how the controller design and implementation took place. All the theory explained before was implemented for the NREL 5 MW wind turbine using MATLAB / Simulink environment integrated with FAST.R
4.1 CONTROL PROBLEM
In wind turbines four variables are considered as measurable: 1. Rotor angular velocity ωr;
2. Pitch angle θ; 3. Generator torque Tg;
4. Tower fore-aft acceleration ¨xT;
the manipulated variables are: 1. Pitch angle θ;
2. Generator torque Tg;
The wind speed (vrel) is considered as an unmeasurable
distur-bance.
The electric power (Pe) is taken as measured, but in reality it is
calculated as in (2.14).
For the sake of analysis, it was considered two distinct control problems with the objective of assessing two main points:
1. If the complexity of the internal model can increase the perfor-mance;
2. How the increase in control objectives affect the other variables; The two distinct control problems are called A and B, described next.