Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local...

83
Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Systems Ylva Jung Division of Fluid and Mechanical Engineering Systems Degree Project Department of Management and Engineering LIU-IEI-TEK-A--09/00707--SE

Transcript of Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local...

Page 1: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Local Sensitivity Analysis of Nonlinear

Models – Applied to Aircraft Vehicle

Systems

Ylva Jung

Division of Fluid and Mechanical Engineering Systems

Degree ProjectDepartment of Management and Engineering

LIU-IEI-TEK-A--09/00707--SE

Page 2: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 3: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Lokal känslighetsanalys av icke-linjära modeller –

tillämpat på grundflygplansystem

Examensarbete utfört i Fluid och mekanisk systemteknikvid Tekniska högskolan i Linköping

av

Ylva Jung

LIU-IEI-TEK-A--09/00707--SE

Handledare: Sören Steinkellner

SAAB AB

Petter Krus

IEI, Linköpings universitet

Examinator: Petter Krus

IEI, Linköpings universitet

Linköping, 23 October, 2009

Page 4: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 5: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Avdelning, Institution

Division, Department

Division of Fluid and Mechanical Engineering Sys-temsDepartment of Management and EngineeringLinköpings universitetSE-581 83 Linköping, Sweden

Datum

Date

2009-10-23

Språk

Language

� Svenska/Swedish

� Engelska/English

Rapporttyp

Report category

� Licentiatavhandling

� Examensarbete

� C-uppsats

� D-uppsats

� Övrig rapport

URL för elektronisk version

http://www.iei.liu.se/flumes?l=en

http://urn.kb.se/resolve?urn=urn:nbn:se:liu:diva-51212

ISBN

ISRN

LIU-IEI-TEK-A--09/00707--SE

Serietitel och serienummer

Title of series, numberingISSN

Titel

TitleLokal känslighetsanalys av icke-linjära modeller – tillämpat på grundflygplansys-tem

Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems

Författare

AuthorYlva Jung

Sammanfattning

Abstract

As modeling and simulation becomes a more important part of the modelingprocess, the demand on a known accuracy of the results of a simulation has grownmore important. Sensitivity analysis (SA) is the study of how the variation inthe output of a model can be apportioned to different sources of variation. Byperforming SA on a system, it can be determined which input/inputs influence acertain output the most. The sensitivity measures examined in this thesis are theEffective Influence Matrix, EIM, and the Main Sensitivity Index, MSI.

To examine the sensitivity measures, two tests have been made. One on a lab-oratory equipment including a hydraulic servo, and one on the conceptual landinggear model of the Gripen aircraft. The purpose of the landing gear experimentis to examine the influence of different frictions on the unfolding of the landinggear during emergency unfolding. It is also a way to test the sensitivity analysismethod on an industrial example and to evaluate the EIM and MSI methods.

The EIM and MSI have the advantage that no test data is necessary, whichmeans the robustness of a model can be examined early in the modeling process.They are also implementable in the different stages of the modeling and simulationprocess. With the SA methods in this thesis, documentation can be produced atall stages of the modeling process. To be able to draw correct conclusions, it isessential that the information that is entered into the analysis at the beginning iswell chosen, so some knowledge is required of the model developer in order to beable to define reasonable values to use.

Wishes from the model developers/users include: the method and model qual-ity measure should be easy to understand, easy to use and the results should beeasy to understand. The time spent on executing the analysis has also to be wellspent, both in the time preparing the analysis and in analyzing the results.

The sensitivity analysis examined in this thesis display a good compromisebetween usefulness and computational cost. It does not demand knowledge inprogramming, nor does it demand any deeper understanding of statistics, makingit available to both the model creators, model users and simulation result users.

Nyckelord

Keywords Local sensitivity analysis, Effective Influence Matrix, Main Sensitivity Index, Sen-sitivity measures, Uncertainties, Dymola, Hopsan, Vehicle systems

Page 6: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 7: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Abstract

As modeling and simulation becomes a more important part of the modelingprocess, the demand on a known accuracy of the results of a simulation has grownmore important. Sensitivity analysis (SA) is the study of how the variation inthe output of a model can be apportioned to different sources of variation. Byperforming SA on a system, it can be determined which input/inputs influence acertain output the most. The sensitivity measures examined in this thesis are theEffective Influence Matrix, EIM, and the Main Sensitivity Index, MSI.

To examine the sensitivity measures, two tests have been made. One on a lab-oratory equipment including a hydraulic servo, and one on the conceptual landinggear model of the Gripen aircraft. The purpose of the landing gear experimentis to examine the influence of different frictions on the unfolding of the landinggear during emergency unfolding. It is also a way to test the sensitivity analysismethod on an industrial example and to evaluate the EIM and MSI methods.

The EIM and MSI have the advantage that no test data is necessary, whichmeans the robustness of a model can be examined early in the modeling process.They are also implementable in the different stages of the modeling and simulationprocess. With the SA methods in this thesis, documentation can be produced atall stages of the modeling process. To be able to draw correct conclusions, it isessential that the information that is entered into the analysis at the beginning iswell chosen, so some knowledge is required of the model developer in order to beable to define reasonable values to use.

Wishes from the model developers/users include: the method and model qual-ity measure should be easy to understand, easy to use and the results should beeasy to understand. The time spent on executing the analysis has also to be wellspent, both in the time preparing the analysis and in analyzing the results.

The sensitivity analysis examined in this thesis display a good compromisebetween usefulness and computational cost. It does not demand knowledge inprogramming, nor does it demand any deeper understanding of statistics, makingit available to both the model creators, model users and simulation result users.

v

Page 8: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 9: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Acknowledgments

This is my master’s thesis for a degree of Master of Science in Applied Physicsand Electrical Engineering. It has been carried out at the section for Simulationand Thermal Analysis at Saab Aerosystems, Saab AB in Linköping, in cooperationwith the department of Management and Engineering (IEI) at the University ofLinköping.

Some thanks are needed. Thanks to everyone at TDGT and FluMeS/Machinedesign at IEI for making feel welcome. Special thanks to my supervisor SörenSteinkellner for giving me the chance to do this thesis, as well as all the help, theanswers given and for always taking the time. Thanks also to my examiner PetterKrus for valuable inputs and helping me with HOPSAN and Niclas Wiker for allthe help on the landing gear model and Dymola.

Last but not least Daniel, for listening to all my worries about the thesis andthe future, for believing in me, making me believe in me and for making me feelloved.

Ylva Jung, Linköping October 2009

vii

Page 10: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 11: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Contents

1 Introduction 3

1.1 Background . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31.1.1 Company background . . . . . . . . . . . . . . . . . . . . . 31.1.2 Problem background . . . . . . . . . . . . . . . . . . . . . . 4

1.2 Goal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41.3 Aims . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51.4 Method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51.5 Reader’s guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

2 Theory - Modeling and simulation 7

2.1 Some definitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72.2 The benefits of modeling and simulating . . . . . . . . . . . . . . . 92.3 Modeling methods for physical systems . . . . . . . . . . . . . . . . 10

2.3.1 Physical modeling . . . . . . . . . . . . . . . . . . . . . . . 102.3.2 System Identification . . . . . . . . . . . . . . . . . . . . . . 102.3.3 Mixing modeling methods . . . . . . . . . . . . . . . . . . . 10

2.4 Model properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112.4.1 Linearity . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112.4.2 Linearization . . . . . . . . . . . . . . . . . . . . . . . . . . 112.4.3 Robustness . . . . . . . . . . . . . . . . . . . . . . . . . . . 122.4.4 Level of model validity . . . . . . . . . . . . . . . . . . . . . 12

2.5 Modeling and simulations . . . . . . . . . . . . . . . . . . . . . . . 132.5.1 Modeling and simulation tools . . . . . . . . . . . . . . . . 13

2.6 Uncertainties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142.6.1 Parameter uncertainties . . . . . . . . . . . . . . . . . . . . 142.6.2 Model structure uncertainties . . . . . . . . . . . . . . . . . 14

2.7 Disturbances . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152.8 Automatic control engineering . . . . . . . . . . . . . . . . . . . . . 152.9 Models used at TDGT . . . . . . . . . . . . . . . . . . . . . . . . . 16

3 Theory - Sensitivity Analysis 19

3.1 Global and local methods . . . . . . . . . . . . . . . . . . . . . . . 193.2 Local sensitivity measurements . . . . . . . . . . . . . . . . . . . . 20

3.2.1 Effective Influence Matrix, EIM . . . . . . . . . . . . . . . . 22

ix

Page 12: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

x Contents

3.2.2 Main Sensitivity Index, MSI . . . . . . . . . . . . . . . . . . 23

4 Experiments 25

4.1 Hydraulic servo experiment . . . . . . . . . . . . . . . . . . . . . . 25

4.1.1 Laboratory equipment . . . . . . . . . . . . . . . . . . . . . 27

4.1.2 HOPSAN . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

4.1.3 Co-simulation with HOPSAN and Excel . . . . . . . . . . . 27

4.2 Landing gear experiment . . . . . . . . . . . . . . . . . . . . . . . . 29

4.2.1 The landing gear . . . . . . . . . . . . . . . . . . . . . . . . 29

4.2.2 Dymola . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

5 Results - Hydraulic servo experiment 35

5.1 Comparison between physical system andHOPSAN model . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

5.1.1 Differences between the model and reality . . . . . . . . . . 35

5.2 System parameters and characteristics . . . . . . . . . . . . . . . . 37

5.3 Step response . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38

5.3.1 Step response with new system characteristics and some newparameters . . . . . . . . . . . . . . . . . . . . . . . . . . . 39

5.4 Square wave . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40

5.5 Observations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43

6 Results - Landing gear experiment 45

6.1 System parameters and characteristics . . . . . . . . . . . . . . . . 45

6.2 Sensitivity measures . . . . . . . . . . . . . . . . . . . . . . . . . . 46

6.3 Is the assumption of linear systems reasonable? . . . . . . . . . . . 50

6.4 Usefulness in an industrial example . . . . . . . . . . . . . . . . . . 51

6.5 Observations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51

7 Summary and conclusions 53

7.1 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53

7.2 Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55

8 Future work 57

Bibliography 59

A Nomenclature 61

A.1 Definitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61

A.2 Abbreviations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62

B User’s guide 63

C Problems and improvements 65

Page 13: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Contents xi

D Code 67

D.1 How to shorten Dymola names . . . . . . . . . . . . . . . . . . . . 67D.2 New Dymola component . . . . . . . . . . . . . . . . . . . . . . . . 68D.3 Terminate function . . . . . . . . . . . . . . . . . . . . . . . . . . . 68

Page 14: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 15: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

List of Figures

2.1 The desired benefits of model-based design. . . . . . . . . . . . . . 92.2 Two models showing the principle of superposition. . . . . . . . . . 112.3 The second topmost layer of the environmental control system. . . 16

3.1 aij and bij describe the relation between ∆x and ∆y. . . . . . . . . 21

4.1 Laboratory equipment for the hydraulic servo experiment. . . . . . 254.2 Laboratory equipment for hydraulic servo experiment, with added

weights to increase the inertia of the system. . . . . . . . . . . . . 264.3 The graphical interface of the equipment in the hydraulic servo

experiment. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284.4 Laboratory equipment for hydraulic servo experiment modeled in

HOPSAN. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284.5 A drawing of the Gripen main landing gear. . . . . . . . . . . . . 304.6 The Gripen Demo during flight. . . . . . . . . . . . . . . . . . . . . 304.7 The main landing gear, modeled in Dymola. . . . . . . . . . . . . 314.8 A simplified flow chart on the communication between Excel and

Dymola. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 324.9 System parameters used in the landing gear sensitivity analysis. . 334.10 System characteristics investigated in the landing gear sensitivity

analysis. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33

5.1 A step response example to clarify the terms: overshoot, rise timeand steady state error. The overshoot marked in the figure shouldbe divided by yf to obtain a ersult in percents. . . . . . . . . . . . 36

5.2 Measurements from the step response of the hydraulic servo. . . . 365.3 Step response for the HOPSAN model, plotted the first 20 seconds

and the first second respectively. . . . . . . . . . . . . . . . . . . . 375.4 EIM of a step response. . . . . . . . . . . . . . . . . . . . . . . . . 385.5 MSI of a step response. . . . . . . . . . . . . . . . . . . . . . . . . 395.6 Laboratory equipment for the extended hydraulic servo experiment

modeled in HOPSAN. . . . . . . . . . . . . . . . . . . . . . . . . . 405.7 EIM of the step response in section 5.3.1. . . . . . . . . . . . . . . 415.8 MSI of the step response in section 5.3.1. . . . . . . . . . . . . . . 415.9 The behaviour of the hydraulic servo with a square wave as input. 415.10 The behaviour of the HOPSAN model with a square wave as input. 425.11 EIM of a square wave input. . . . . . . . . . . . . . . . . . . . . . . 425.12 MSI of a square wave input. . . . . . . . . . . . . . . . . . . . . . . 43

6.1 System parameters used in sensitivity analysis. . . . . . . . . . . . 466.2 System characteristics investigated in sensitivity analysis. . . . . . 466.3 EIM of the landing gear model with a deviation of 0.20. . . . . . . 476.4 MSI of the landing gear model with a deviation of 0.20. . . . . . . 486.5 The system parameters with the deviation changed to 0.10. . . . . 486.6 EIM of the landing gear model with a deviation of 0.10. . . . . . . 49

Page 16: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

2 Contents

6.7 MSI of the landing gear model with a deviation of 0.10. . . . . . . 496.8 The MSI matrix with tauzero = 15 and the variability +5. . . . . . 506.9 The MSI matrix with tauzero = 15 and the variability −5. . . . . . 50

A.1 Illustration of the terms accuracy and precision. . . . . . . . . . . . 61

B.1 The System parameters tab in the Excel interface. . . . . . . . . . 63B.2 The System characteristics tab in the Excel interface. . . . . . . . 64

List of Tables

5.1 Comparison between the control theoretic properties of the hy-draulic servo system. . . . . . . . . . . . . . . . . . . . . . . . . . 36

5.2 System characteristics investigated in sensitivity analysis. . . . . . 375.3 System parameters used in sensitivity analysis. . . . . . . . . . . . 385.4 Additional system characteristics investigated in sensitivity analysis. 395.5 Additional system parameters used in sensitivity analysis. . . . . . 40

6.1 System parameters used in sensitivity analysis, and the shortenednames used in the report. . . . . . . . . . . . . . . . . . . . . . . . 46

6.2 System characteristics used in sensitivity analysis, and the short-ened names used in the report. . . . . . . . . . . . . . . . . . . . . 47

A.1 Abbreviations used in the thesis. . . . . . . . . . . . . . . . . . . . 62

Page 17: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Chapter 1

Introduction

This first chapter gives a brief introduction to the company background and theproblem background in section 1.1, as well as the goals and aims of this thesisin sections 1.2 and 1.3 respectively. Section 1.4 presents the method used andsection 1.5 contains a reader’s guide.

1.1 Background

1.1.1 Company background

Saab is a Swedish high-technological company with focus on defense, aviation andcivil security, and in the beginning the company was manufacturing planes. “Sven-ska Aeroplan Aktiebolaget” (Swedish for “Swedish Aeroplane Limited”) (SAAB)was founded in 1937 in Trollhättan, has had the headquarters in Linköping formany years but is now based in Stockholm. In 1965 the name was changed toSaab AB.

The light bomber and reconnaissance aircraft B17 was the company’s firstaircraft, and with it Saab became the leading supplier to the Swedish Air Force.The J29 Tunnan fighter was introduced in the late 1940’s, followed by Lansen(1950’s), Draken (1960) and Viggen (1971). JAS 39 Gripen entered service in1993. During the 1980’s investments in civil aircrafts were made resulting in Saab340 and Saab 2000.

Besides military and commercial aircraft production, automobile manufactur-ing began in the late 1940’s and in the 1960’s Saab helped to create Sweden’scomputer, missile and space industries. In 1969 Saab and Scania merged to Saab-Scania, manufacturing automobiles, trucks and buses. Since 1990 the passengercar division is an independent company, Saab Automobile, and in 1995 Saab-Scania was demerged into two companies, with bus and truck constructor Scaniaseparated from Saab.

Saab has also, by acquisitions of the defense group Celsius in 2000, diversifiedinto defense industry with roots in companies like Bofors, Philips, Datasaab, Eric-sson, AGA and Satt Electronics. The product-range is focused on future defense

3

Page 18: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

4 Introduction

needs and safer society [18].This thesis is done at Saab Aerosystems in Linköping, at the section for Sim-

ulation and Thermal Analysis, TDGT. This group has 15 employees and worksprimarily with the Gripen’s Vehicle Systems, i.e. fuel system, auxiliary power unitand system, environmental control system, hydraulic system, landing gear andrescue system. The section also works with other Saab aircrafts and aircrafts fromother manufacturers as well as UAVs. The work consists of:

• analyses of vehicle systems including regulation of the hardware and soft-ware, e.g. simulations of new systems and calculations of the performanceof completed systems.

• development of calculation models and real time models in vehicle systems.

• CFD calculations of the internal currents and temperature fields of the air-craft interior and the vehicle systems.

• R&D within the field of vehicle systems.

Modeling and simulation within vehicle systems are used today for:

• total system specification and design, e.g. functionality on the ground andin the air.

• equipment specification and design.

• software specification and design.

• various simulators.

• test rig design.

1.1.2 Problem background

In order to minimize the time of development for a product as well as reducingthe necessity of extended testing of the physical product, the demand on a knownaccuracy (see definition A.1) of the results of a model simulation (i.e. how well theresult reflects the behaviour of a real system) has grown more important. Uncer-tainties in system parameters (e.g. weight, length, volume) entail uncertainties inthe result of a simulation. The accuracy of a simulation result is a function of theknowledge of the uncertainties in the system parameters, which can be estimatedwith or without access to test data. It is also based on the knowledge that thereare other sources of uncertainties, unknown to us.

1.2 Goal

The goal of the thesis is to evaluate different measures of accuracy of the resultsfor physical models so as to decide how useful they are in practice for the kind ofmodels developed at TDGT.

Page 19: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

1.3 Aims 5

1.3 Aims

Practical needs for TDGT on a measure of accuracy are:

• to be useful in simulations of both static and dynamic systems.

• to work at the early stages of conceptual design (uncertainties are roughguesses) as well as when test data is available.

• to serve as model documentation for the uncertainties of system parameters.

• to provide synergy effects e.g. possibility to point out which model compo-nent contribute the most to the inaccuracy in simulation results.

• to fit with already implemented system model components.

If the needs above are fulfilled by a measure of accuracy and the method isimplementable in a company development process, the development of new systemswill be easier and the quality of simulation models and results of calculation willimprove. In the long run this will lead to reduced costs in developing aircrafts.

1.4 Method

This thesis started out with a litterature review to deepen the knowledge aboutthe theories behind sensitivity analysis. The decision was made to proceed withthe local sensitivity analysis methods EIM (see section 3.2.1) and MSI ( 3.2.2). Toevaluate the possibility to implement these at TDGT, tests have been made; oneon a physical model of a hydraulic servo and one on a model developed and usedat TDGT, the conceptual model of a Gripen landing gear.

Page 20: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

6 Introduction

1.5 Reader’s guide

Chapter 1 Introduction to the thesis, background, goals and aims ofthe thesis.

Chapter 2 This chapter presents the theoretical background to model-ing and simulation. It describes the profits of modeling andsimulation, different types of modeling and problems thatwill emerge during the modeling process, such as uncertain-ties and disturbances. There is also a short presentation ofmodels used at TDGT.

Chapter 3 In this chapter, the theory behind Sensitivity Analysis (SA)is presented.

Chapter 4 Two experiments have been made to test the SA method,they are presented here.

Chapter 5 Results of the hydraulic servo experiment.Chapter 6 Results of the landing gear experiment.Chapter 7 Summary and conclusions.Chapter 8 Ideas and suggestions for future improvements are pre-

sented here.Bibliography

Appendix A Definitions and abbreviations used in the thesis.Appendix B User’s guide.Appendix C Some problems that have occurred during the work with

this thesis, and their causes are listed.Appendix D Code for some functions used in this thesis.

Page 21: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Chapter 2

Theory - Modeling and

simulation

Simulation grows more and more important in development processes today, andin order to get reliable results, sufficiently good models are needed.

This chapter introduces the theoretical background of modeling and simulation(M&S) as presented in this thesis. It starts with some definitions in section 2.1,and describes the profits of modeling and simulation in section 2.2. The physicalmodeling and system identification methods are introduced in section 2.3, somemodel properties in section 2.4 and the (M&S) tools Simulink and Dymola insection 2.5. Then the concepts of uncertainties and disturbances are described insections 2.6 and 2.7, followed by a short description on how models are used incontrol engineering in section 2.8. The chapter ends with a survey of the modelsused at TDGT in section 2.9.

Someone with knowledge about modeling and simulation probably need notread parts of this chapter and could concentrate on section 2.4.4 about the levelof model validity, section 2.6 about uncertainties and section 2.9 about the modelsused at TDGT.

2.1 Some definitions

Many definitions exist for the terms used in this thesis; the following definitionsall come from [5] if nothing else is stated.

System:

A system is a potential source of data.

Another way of describing a system is with an example.

The largest possible system of all is the universe. Whenever we de-cide to cut out a piece of the universe such that we can clearly say

7

Page 22: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

8 Theory - Modeling and simulation

what is inside that piece (belongs to that piece), and what is outside(does not belong to that piece), we define a new system. A system ischaracterized by the fact that we can say what belongs to it and whatdoes not, and by the fact that we can specify how it interacts with itsenvironment. System definitions can furthermore be hierarchical. Wecan take the piece from before, cut out a yet smaller part of it, and wehave a new system.

Inputs and outputs:

Closely linked to a system are inputs and outputs. Inputs are variables thatare generated by the environment and that influence the behaviour of the system.Outputs are variables that are determined by the system and that in turn influencethe behaviour of its environment.

Experiment:

An experiment is the process of extracting data from a system byexerting it through its outputs.

Model:

A model (M) for a system (S) and an experiment (E) is anything towhich E can be applied in order to answer questions about S.

A model is a delimitation of the aspects of the properties of a system that arerelevant for a specific aim. A model is always a simplification of the real system.Since a model is determined by the aim and the knowledge about the system, amodel can never be “true” or “correct”. It only has to be good enough for thedefined system/problem at hand. A model of a system can thus be valid for oneexperiment and invalid for another.

Simulation:

A simulation is an experiment performed on a model.

Or, as presented in [2]:

Simulation is the imitation of the operation of a real-world process orsystem over time. Simulation involves the generation of an artificialhistory of the system and the observation of that artificial history todraw inferences concerning the operating characteristics of the realsystem that is represented.

Page 23: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

2.2 The benefits of modeling and simulating 9

2.2 The benefits of modeling and simulating

So what are the benefits of simulation, and where does modeling come into thepicture?

There are many reasons to do a simulation. As is implied in the definitionabove, section 2.1, simulation is a way of gaining knowledge about a physical orabstract system without the real system. Situations where it would be expensiveto use the real system, or when this could cause danger or even death are areaswhere simulation is used. These typically include simulation of technology forperformance optimization, safety engineering, testing, training and education, e.g.in the domain of nuclear power. Another useful application of simulation is to testproducts that do not yet exist, i.e. in order to evaluate different designs withoutthe need to produce expensive prototypes. Simulations can also be used to “speedup” or “slow down” time, in cases where the time lapses are too fast (e.g. anexplosion) or too slow (e.g. the creation of a galaxy). In addition to time scalingthere is also the possibility of size scaling.

Another advantage of simulation over experiments with the real system is thatall inputs and outputs are available. Moreover the disturbances are also accessible,making it possible to determine in a more precise way the influence of differentelements.

Simulation is also a possible way of gaining knowledge and detecting problemsbefore they occur. With a simulation of a diving aircraft it is for example possibleto calculate the forces on the wings, thus determining the thickness needed. Thishelps making correct design decisions at an early stage and consequently reducecosts, see figure 2.1.

Figure 2.1. The desired benefits of model-based design (MBD), [20].

Page 24: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

10 Theory - Modeling and simulation

2.3 Modeling methods for physical systems

When starting the modeling process there are different ways to go, two types ofmodels are physical models, also called mathematical models, and models con-structed through System Identification. Regardless of which, the process is itera-tive and the modeler has to continue until the model is sufficiently good for thepurpose it was intended for.

Most models also go through the phases of verification and validation. Veri-fication is a determination of whether the computational implementation of theconceptual model is correct. Validation is the determination of whether the con-ceptual model can be substituted for the real system for the purposes of experi-mentation [2]. Or in two short questions. Verification: Did I build the thing right?Validation. Did I build the right thing?

Two of the more commonly used modeling methods for physical systems aredescribed below.

2.3.1 Physical modeling

Physical models, or mathematical models, are based on mathematical equationsdescribing the physical behaviour of the system being modeled. The relations be-tween the model variables and signals are expressed as mathematical connections,these are often differential equations.

One big advantage of physical modeling is that the underlying physical relationsstill are visible for the modeler, and the physical variables can be distinguished.

2.3.2 System Identification

System identification (SI) is a modeling method that results in a so called blackbox model, where only the relation between the inputs and outputs are described.With this method the model is not based on the fundamental physical relations.The description of the system modeled can be mathematical or in the form of agraph or a table. It can e.g. be a step response, an impulse response or a Bodeplot.

An advantage of system identification is that the final model can be less com-plex than when using for example physical modeling.

2.3.3 Mixing modeling methods

It is possible to mix the use of different modeling methods, where parts of themodel can be based on physical modeling and others on system identification.This is done to benefit from the advantages of the different methods.

Physical models are sometimes called white box models, and with SI beingblack box modeling, as a result there is something called grey-box model. Oneexample is models consisting of differential equations where several parametersoccurring in these equations are not known and have to be extracted from thesystem by data-based methods [13].

Page 25: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

2.4 Model properties 11

2.4 Model properties

2.4.1 Linearity

Linearity is one of the most important concepts in mathematical modeling. Modelsof devices or systems are said to be linear when their basic equations — whetheralgebraic, differential or integral — are such that the magnitude of their or responseproduced is directly proportional to the excitation or input that drives them [11].

A linear function f(x) is such that it satisfies both of the following properties:additivity and homogeneity. Additivity demands that f(x+ y) = f(x) + f(y) andhomogeneity that f(αx) = αf(x).

Or, as presented in [16] with an example.

x = f(x, u)y = h(x, u)

(2.1)

The model described by equation (2.1) is said to be linear if f(x, u) and h(x, u)are linear functions of the inner states, x, and the inputs, u:

f(x, u) = Ax+Buh(x, u) = Cx+Du

(2.2)

For a linear system excited by a complex set of inputs, it is possible to usethe principle of superposition. This is to say that the output of the system is thesame regardless whether the system is exposed to the input as it is, or if the inputis divided into smaller inputs, each exciting the system, and these are added, orsuperposed, see figure 2.2.

Figure 2.2. Two models showing the principle of superposition. If the state-spacemodel (which all four have the same coefficients) is linear, the left system and the rightare equal.

The models developed and worked with at TDGT are highly nonlinear.

2.4.2 Linearization

It can be purposeful to se how the solution of a nonlinear system behaves “closeto” a certain working point. If a solution to (2.1) is x0, u0, let y0 = h(x0, u0). Thissystem can be linearized around x0, u0 by observing small deviations ∆x(t) =

Page 26: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

12 Theory - Modeling and simulation

x(t)−x0, ∆u(t) = u(t)−u0 and ∆y(t) = y(t)− y0. Then the approximation (2.3)is valid.

ddt

∆x = A∆x+B∆u∆y = C∆x+D∆u

(2.3)

where A, B, C and D are Jacobians to f(x, u) and h(x, u) with respect to x and urespectively, evaluated in (x0, u0).

Linearization is a useful tool, but there are restrictions [16].

• Linearization can only be used to study local properties close to the chosenworking point. In many cases the behaviour around a stationary solution canbe interesting, in particular since it is often desired that the system shouldreside around such a point.

• It is often difficult to quantitatively estimate how good an approximationthe linearized solution is.

A question that arises in connection with linearization is: how big can thedeviations ∆x and ∆u be before even these deviations cannot be considered linear?Normally the deviations used in sensitivity analysis are rather small, but in thisthesis the deviations have been as big as 400% for the friction coefficients in thelanding gear model.

The questions and restrictions around linearization show that experience is ofimportance when performing a linearization.

2.4.3 Robustness

Another influential property of a model is robustness. A robust system is such thatits properties do not change more than expected if applied to a system slightlydifferent from the mathematical one. Sensitivity analysis is the primary tool forstudying the degree of robustness in a system [14].

Important to note is that because a system is robust with respect to certainparameters, this does not guarantee anything regarding the robustness of otherparameters of the system.

2.4.4 Level of model validity

In the definition of a model, in 2.1, it is stated that a model has to be “goodenough for the defined system or problem at hand”. To decide when a modelis good enough, tests and evaluations are carried out to be sure the confidencein the model is sufficient and the model can be considered valid. Since no rulesexist, engineers must use their experiences to determine if additional testing iswarranted, but in practice a model’s level of validity is often a consequence ofproject constraints such as time, money and human resources.

Even when the results obtained from tests and evaluations are reasonable andthe model seems to be correct, this might not be the case. If a model produces

Page 27: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

2.5 Modeling and simulations 13

an acceptable prediction, it could be because of: (a) reasonably correct input as-sumptions combined with a reasonably correct model structure; (b) compensatingerrors in the model input assumptions and a reasonably correct model structure;or (c) a combination of incorrect input assumptions combined with errors in themodel structure, all of which compensate for each other [7].

In the following example a system equation is assumed to be as in (2.4).

f(x) = −u(x)u(x) = −x

(2.4)

The true system is described in equation (2.5).

f(x) = u(x)u(x) = x

(2.5)

This model is an example of the third case above, (c), where a combination ofincorrect input assumptions combined with errors in the model structure, all ofwhich compensate for each other. As long as the input has the wrong sign themodeler will not realize this model error, and the two errors cancel each other out.This short example shows that even when the simulation results seem to provethat the model is “good enough”, this might not be the case.

2.5 Modeling and simulations

2.5.1 Modeling and simulation tools

There are different types of simulation tools, two examples are Dymola [10] andthe more commonly used Simulink [17].

Simulink is a signal-flow tool where the flow of information between componentsis causal (definition A.2). The different components are predefined as to what isinput or output, with the signal relating them flowing in a specified direction.The equations are given on the form of ordinary differential equations (ODE), see(2.6). Simulink has a good support for data-flow and control-system modeling andis commonly used in software-intensive systems with discrete blocks [20].

{

x = f(u, x)y = g(u, x)

(2.6)

Dymola on the other hand is a power-port tool where the information is trans-ferred between components through power ports, connections that are non-causal,(see definition A.2). Dymola has a good support for physical modeling and thetool is suitable for continuous systems. The tool is based on differential-algebraicequations, DAEs, see (2.7).

0 = f(u, x, x, y) (2.7)

Page 28: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

14 Theory - Modeling and simulation

2.6 Uncertainties

2.6.1 Parameter uncertainties

When modeling a system there will most of the times be uncertainties that haveto be addressed.

There are known knowns. There are things we know that we know.There are known unknowns. That is to say, there are things that wenow know we don’t know. But there are also unknown unknowns.There are things we do not know we don’t know.

Former U.S. Secretary of Defense, Donald Rumsfeld

February 12, 2002

Uncertainties can be distinguished as being either aleatory or epistemic.

Aleatory uncertainty: An aleatory uncertainty arises because of natural, un-predictable variations in the performance of the system under study. Aleatoryuncertainties are also referred to as variability, irreducible uncertainties, inherentand stochastic uncertainties. The knowledge of experts cannot be expected toreduce aleatory uncertainty although their knowledge may be useful in quantify-ing the uncertainty. Thus, this type of uncertainty is sometimes referred to asirreducible uncertainty or external uncertainty [8].

Epistemic uncertainty: Epistemic uncertainty, or reducible and subjective un-certainties as it is also called, is due to a lack of knowledge about the behaviourof the system that is conceptually resolvable. The epistemic uncertainty can, inprinciple, be eliminated with sufficient study and, therefore, expert judgementsmay be useful in its reduction.

From a psychological point of view, epistemic (or internal) uncertainty reflectsthe possibility of errors in our general knowledge. For example, one believes thatthe population of city A is less than the population of the city B, but one is notsure of that [8].

Early in the concept phase, there are more epistemic uncertainties than aleatoryuncertainties. During the refinement of the model, most epistemic uncertaintiesdecrease and some epistemic parameters transform into aleatory uncertainties [21].

2.6.2 Model structure uncertainties

Epistemic uncertainties can also be connected to the model structure, that thesystem and its equations are not modeled with sufficient detail. While parameteruncertainty is linked to the physical parameters themselves, model structure un-certainty refers to lack of knowledge about the relationships between parametersand the underlying phenomenologies [3].

Page 29: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

2.7 Disturbances 15

Activity index

The effects of model structure uncertainties can be covered by comparison withtest data. Another approach, not discussed in this thesis, is to use the so-calledactivity index, where the energy levels in a system are monitored, and parts withlow activity are candidates for simplification and parts with high activity mayneed further elaboration [1].

2.7 Disturbances

A disturbing signal or disturbance is an external signal which we cannot chooseor influence. Even though we cannot influence the disturbances, they often haveimpact on the system and therefore it is essential to have knowledge about theirtypical qualities [16]. The problem with disturbances will not be further investi-gated in this thesis but is assumed dealt with in the modeling process and is apart of the model uncertainties.

Known sources of disturbance - Measurable disturbances

The disturbance is often a well known physical quantity, and is measurable. Inthis case the disturbances can be modeled, and in many cases treated as an input,if it has been properly modeled.

Known sources of disturbance - Non measurable disturbances

Sometimes, even though the origin of a disturbance is known, it is not measurable.Take the case of a plane. Its motions are determined by the power of the

engine, the force of gravity and by the forces exerted on the airplane from theair surrounding it. Some of these are known or measurable and can be treated asin the previous paragraph; others are known but not measurable and have to betreated as such.

Unknown sources of disturbances

A third case is when there are disturbances but where the possibility, time orenergy is lacking to find out their physical causes. These effects can then be col-lected to one aggregated contribution which typically is added to the undisturbedoutput.

2.8 Automatic control engineering

When talking about a system or a system model in automatic control it is usuallywell defined what the inputs, outputs and the controlled quantity are. That is notalways the case for the models discussed in this thesis. The signal can in differentcontexts be input and output and it is therefore difficult to use the same definitionsthat are used in automatic control.

Page 30: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

16 Theory - Modeling and simulation

Still there are similarities. Perturbations causing disturbances have to be dealtwith as well as uncertainties and discrepancies between the model and the reality.

2.9 Models used at TDGT

The models developed and used at TDGT today are complex, heterogeneous air-craft models including both equipment and the software controlling and monitoringthe physical system. The systems include physical models (pumps, valves, gears,turbines, etc, i.e. fluids that moves) and software models (models of the code thatcontrols the system) and also a mixture of continuous and discrete parts. Whenworking with aircraft systems, in addition to the usual problems occuring duringthe modeling process, challenges such as the effects of g-forces and two-phasedflow, i.e. mixing fuel with air, in fuel systems occur.

As an example of the complexity of the models in use, the fuel system modelhas 300 components with 226 state variables and more than 100 input and outputsensors. The environmental control system is probably the most complex modelwith more than 100 component subroutines and five major feedbacks which hasbeen in daily use for ten years. This model was the first for which Saab useda modern tool instead of the ordinary FORTRAN environment used earlier, andwas modeled in the modeling tool Easy5. A migration from Easy5 to Dymola isin progress at TDGT and a part of the environmental control system modeled inDymola can be seen in figure 2.3.

Figure 2.3. The second topmost layer of the environmental control system, with sub-systems such as the motor and the cabin. The modeling tool used is Dymola.

Page 31: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

2.9 Models used at TDGT 17

All components in the systems have been physically modeled, such as valves,pipes, tanks, sensors, heat exchangers, ram air channels, water separators, cabin,on-board oxygen generating system compressors, turbines, etc.

The system context such as flight conditions (speed, altitude, humidity, tem-perature, etc.) are inputs to the model, as are the interfaces to other systemswhere energy is transferred into the system. Dynamic models based on physicaldifferential equations have generally been used. Black-box models have been usedfor some equipments of minor interest such as sensors. Tables are only used forhighly nonlinear equipment such as compressors and turbines [12].

Page 32: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 33: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Chapter 3

Theory - Sensitivity Analysis

Sensitivity analysis (SA) is the study of how the variation in the output of amodel (numerical or otherwise) can be apportioned, qualitatively or quantitatively,to different sources of variation, and of how the given model depends upon theinformation fed into it [19].

Since a model is always a simplification of the real system, the reliability of themodel must be determined, and one way of doing so is using SA. By performingSA on a system, it can be determined which inputs influence a given output themost. The most important contributions to the uncertainty in a model can thusbe determined, and this information can then be used as a guideline to determinethe areas that need higher attention.

The Sensitivity analysis theory is presented in this chapter, starting with adescription of global and local methods in section 3.1, followed by an account ofthe sensitivity measures Effective Influence Matrix, EIM, and Main SensitivityIndex, MSI, in section 3.2.

3.1 Global and local methods

There are different methods of performing sensitivity analysis. Local sensitivitystands for the local variability of the output by varying input variables one at atime near a given working point, which involves partial derivatives. The globalsensitivity, however, stands for the global variability of the output over the entirerange of the input variables and hence provides an overall view on the influence ofinputs on the output. Using this variance-based SA the analysis of variance canbe decomposed into increasing order terms, i.e. first-order terms (main effects)depending on a single variable, higher-order terms (interaction effects) dependingon two or more variables [6].

Assuming that each parameter is computed in its nominal point and only onemore point, the number of simulation runs needed when using a local method isk + 1 for a system with k inputs, and 2k + 1 if a central difference approach isused [21]. With a global method this number is 2k − 1 [19]. In other words alocal method grows linearly with an increasing number of inputs, while a global

19

Page 34: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

20 Theory - Sensitivity Analysis

method grows exponentially. Thus, though global methods might work very wellon small problems, the increase in required experiments soon becomes untenablewith a growing number of inputs.

Furthermore, even a small model might not be a suitable candidate to globalSA. If a model is stiff, has time constant of different magnitudes, simulation is oftenslow. Not only the number of simulations demanded but also the time needed tosimulate influence the time it takes to perform a sensitivity analysis. Therefore amodel which has few inputs but takes a long time to simulate is unfit to performglobal sensitivity analysis on.

Seeing that the models used at TDGT are big and complex, the number ofsimulations needed for a global sensitivity analysis would be too big to be prac-tical. Consequently local sensitivity analysis methods have been chosen to beinvestigated in this thesis.

3.2 Local sensitivity measurements

To increase the understanding and the background of the sensitivity measuresused in this thesis, a description of the notation is presented. The sensitivitymeasurements presented in this chapter are presented more thoroughly in [14].

Since different parameters, and at times also their sensitivities, might havevalues of different orders of magnitude it may be difficult to get a good overviewof a system and how sensitive the variables actually are. In the landing gearexperiment, the system characteristics vary between 1.5 · 10−6 and 1.9 · 107, adifference in magnitudes of 1013. Normalized variables are also used in orderto facilitate comparison between different units as well as making it possible touse addition, e.g. when wanting to aggregate variables into one single variable.Thus, in order to make it easier to get an overview of the sensitivities, normaliseddimensionless sensitivities are introduced.

Sometimes in SA, the range of variation is taken as identical for all the variables,often a few percent of the nominal value [19]. The approach in this thesis is not tohave the same relative deviation for all the parameters, but to be able to choosethese freely.

The uncertainties of system characteristics, y, can be expressed as a function oftwo vectors, xd and xu, design parameters and uncertainty parameters respectively,see equation (3.1). An example of a design parameter could be the choice of fluidin a system whereas an uncertainty parameter could be the viscosity fo that fluid,which is a function of the temperature (among other things).

y = f(xd, xu) (3.1)

f is a nonlinear function but if it can be linearized around a nominal point, thiswill result in the equation (3.2). For some reflections on the correctness of theassumption of linearity, see section 6.3.

y0 + ∆y = f(xd0, xu0) +A∆xd +B∆xu (3.2)

Page 35: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

3.2 Local sensitivity measurements 21

hence∆y = A∆xd +B∆xu (3.3)

A and B are Jacobians with elements:

aij =δfi(xd, xu)

δxd,j=δyiδxd,j

(3.4)

bij =δfi(xd, xu)

δxu,j=δyiδxu,j

(3.5)

where the aij element in the A-matrix describes the sensitivity on the i:th systemcharacteristic by the j:th desing parameter index. The bij element in the B-matrixdescribes the sensitivity on the i:th system characteristic by the j:th uncertaintyparameter index. With a high value of aij , a change in the j:th parameter willresult in a relatively bigger change in the i:th system characteristic than with asmaller value of aij , see figure 3.1.

0 2 4 6 8 100

2

4

6

8

10

12

14

16

18

20

x + ∆x

y +

∆y

Figure 3.1. aij and bij describe the relation between ∆x and ∆y. The values in thegraph are examples with a normal distribution. In this case the aij or bij is linear andequals 2. With a nominal x-value of x = 5 and a deviation of ∆x = 0.5 this would leadto a ∆y = 1.

The normalized sensitivities become:

b0,ij =xujyi

δyiδxuj

(3.6)

Page 36: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

22 Theory - Sensitivity Analysis

In this way, a non-dimensional value is obtained that indicates by how manypercent a certain system characteristic changes when a system parameter is changedby one per cent. By studying the effect of these uncertainties valuable informationabout parts in the design can be found, and a sensitivity matrix can be estab-lished. With this matrix it is easy to see which areas need higher attention toreduce uncertainty.

In this thesis two sensitivity measures have been investigated, and these arepresented below.

3.2.1 Effective Influence Matrix, EIM

Valuable information can be collected by looking at the actual uncertainties in pa-rameters. On condition that the uncertainties are small compared to the nominalvalues, the variance in the system characteristics can be calculated as:

Vy,i =

n∑

j=1

b2ijVx,j (3.7)

Here Vx,j is the variance in the parameters and Vy,i is the variance in the systemcharacteristics. The standard deviation can then be calculated as:

σy,i =√

Vy,i =

n∑

j=1

b2ijVx,j =

n∑

j=1

b2ijσ2x,j (3.8)

and the normalized (non-dimensional) standard deviation becomes:

σ0,y,i =σy,iyi

=1

yi

n∑

j=1

b2ijσ2x,j =

1

yi

n∑

j=1

( yixjb0,ij

)2(xjσ0,x,j)2

=

n∑

j=1

b20,ijσ20,x,j (3.9)

The influence from removing an uncertainty altogether can then be calculated.The difference in variance in system characteristics by removing one uncertaintyVx,j is:

∆Vy,ij = Vy,i − V∗

y,ij (3.10)

Here V ∗y,ij is the variance for the system characteristic, but with the variance ofthe j:th parameter set to zero:

V ∗y,ij = Vy,i,Vx,j=0 (3.11)

For a linear system or a nonlinear system with small variations, this becomes:

∆Vy,ij = b2ijVx,j (3.12)

Page 37: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

3.2 Local sensitivity measurements 23

The change in deviation can then be expressed by:

∆σy,ij = σy,i −√

Vy,i − b2ijVx,j = σy,i −√

σ2y,i − b

2ijVx,j

= σy,i

(

1−

1− b2ijσ2x,j

σ2y,i

)

(3.13)

or in non-dimensional form:

∆σ0,y,ij = σ0,y,i

(

1−

1− b20,ijσ2

0,x,j

σ20,y,i

)

(3.14)

The EIM states how much smaller the deviation will become if the couplingbetween this system parameter and this certain system characteristic was perfect.If a variation in the j:th parameter has a big impact on the i:th characteristicvariation, this will lead to a bigger ∆σ0,y,ij than if the j:th parameter has a smallimpact. Due to the non-linear form of (3.13) there are often very few significantelements in the Effective Influence Matrix; a large deviation in one parameterquickly shadows the influence of other parameters.

3.2.2 Main Sensitivity Index, MSI

The Main sensitivity index SMSI,i,j , is a measure of influence for uncertainties,defined as the ratio between the contribution to the total variance in a systemcharacteristic i by an uncertain parameter index j, Vy,i − V

y,ij , and that totalvariance in a system characteristic index i, Vy,i.

SMSI,i,j =Vy,i − V

y,ij

Vy,i= 1−

V ∗y,ijVy,i

(3.15)

Under the assumption of small uncertainties the behaviour is linear and canbe written as:

SMSI,i,j =b2ijVx,j

Vy,i=b2ijσ

2x,j

σ2y,i

(3.16)

The results can be easily read in a MSI matrix, as the portion of influence agiven parameter has on the system parameters. In the MSI matrix the values arenormalized so the row sum is always one [14].

The MSI only provides the first-order interaction effects, but there is also asensitivity index closely linked to the MSI, the Total Sensitivity Index, TSI. TheTSI include terms of higher orders, rapidly increasing the number of simulationruns needed.

Page 38: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 39: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Chapter 4

Experiments

In order to examine the sensitivity measures described, two tests have been made.One on a laboratory equipment including a hydraulic servo, described in sec-tion 4.1, and one on a conceptual landing gear model of the Gripen aircraft (fromnow referred to as the landing gear), described in section 4.2.

4.1 Hydraulic servo experiment

The laboratory equipment in the hydraulic servo experiment consists of an I-beamthat can seesaw around its center. The position of the beam is controlled by ahydraulic servo, see figure 4.1 for a sketch and figure 4.2 for a picture. Weightscan be added to the ends of the beam to increase the inertia.

This model could represent the movements of beams and other equipmentsin a mechanical system. A hydraulic servo is a part of the landing gear beinginvestigated later in this thesis. The aim of this experiment is to test the localsensitivity analysis method on a quite small and well defined problem. The systemis easily handled and small enough to get the general view of.

Figure 4.1. Laboratory equipment for the hydraulic servo experiment, [9].

25

Page 40: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

26 Experiments

Figure 4.2. Laboratory equipment for hydraulic servo experiment, with added weightsto increase the inertia of the system.

Page 41: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

4.1 Hydraulic servo experiment 27

4.1.1 Laboratory equipment

The functioning of the laboratory equpiment is described below, with the numbersreferring to figure 4.1.

1. PC With dSPACE and a graphical user interface (control desk) to monitorand change the controlling parameters.

2. dSPACE measurement and control system.

3. Servo valve MOOG D661 (140 l/min), two stage flapper valve with mechan-ical feedback. Electrical feedback of the valve spool position.

4. Pressure sensor for measuring the cylinder pressures, p1 and p2 and thesystem pressure ps.

5. Symmetric servo cylinder. The cylinder has a built-in position sensor (po-tentiometer sensor).

6. Pressure relief valve to set the system pressure ps.

A pump and tubes couples oil to the system, and a pressure relief valve (6in figure 4.1) sets the system pressure ps. The tubes are connected to the servovalve (3) which in turn is connected to the hydraulic cylinder (5), determining theposition xp of the beam. The valve is a 4-way servo valve and is controlled with avoltage signal from the controller. p1, p2 (4), ps and xp (the built-in potentiometerin 5) are measured and sent to a computer via a dSPACE measurement and controlsystem (2), and a valve signal is computed and sent to the servo valve. A PI (pro-portional - integral) controller is implemented in Matlab/Simulink in a connectedcomputer (1) and communicates with the hydraulic system via dSPACE.

The graphical interface with the slides to adjust the P- and I-element param-eters as well as the choice of wave form (with amplitude and frequency settings)and the resulting outputs from the system is presented in figure 4.3.

4.1.2 HOPSAN

HOPSAN, created at Linköping University in 1977, is a simulation tool for hy-draulic power systems but has also been adopted for other domains such as elec-tric power, flight dynamics and vehicle dynamics. The existence of a library ofcomponent models of for example valves, machines and lines makes it possible tostudy complex load dynamics and wave propagation in long lines [15].

The laboratory experiment used in experiment one can be seen modeled infigure 4.4.

4.1.3 Co-simulation with HOPSAN and Excel

HOPSAN can not only simulate systems on its own but can also communicate withother tools during simulation. The program can collaborate with Matlab/Simulink,

Page 42: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

28 Experiments

Figure 4.3. The graphical interface of the equipment in the hydraulic servo experiment.

Figure 4.4. Laboratory equipment for hydraulic servo experiment modeled in HOPSAN.

Page 43: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

4.2 Landing gear experiment 29

Excel and Visual Basic in different ways, and in this thesis the possibility to co-simulate with Excel has been made use of. Through Excel most Windows programscan communicate with HOPSAN, for further information read the user’s guide [15].

Using co-simulation it is possible to list the variables in the HOPSAN model inExcel and use Excel to change the variables in HOPSAN. This has been employedwhen calculating the sensitivity measures defined in section 3.2. By co-simulationthe variables used in HOPSAN can be used by Excel, and Excel can add the prede-fined ∆x to each system parameter and calculate the EIM:s and MSI:s connected.

4.2 Landing gear experiment

The Gripen has three landing gears; two main landing gears, one attached to eachwing, as well as a nose gear. The main landing gear examined in this thesis,consists of a main leg, the integrated wheel fork and plunger tube, to which thewheel is attached, a fold stay including a lock mechanism and a hydraulic circuitextending the landing gear, see figure 4.5. Figure 4.6 shows a picture of the Gripenaircraft during flight.

4.2.1 The landing gear

The landing gear has been simulated in the case of a normal unfolding with thehelp of the hydraulic cylinder as well as an emergency unfolding. In the extensioncase, an hydraulic cylinder together with the air loads will help the landing gearunfold. In the case of an emergency unfolding, a catch will unlock a cover and thelanding gear will fall down, and gravitational forces and the air load will unfoldit, that is to say the hydraulic system will not be in use.

This experiment is to examine the influence of different frictions on the un-folding of the landing gear - mainly to examine whether or not it will extend fullyand reach the end position when in emergency state, or if it will be suspended halfway. The time to reach full extension has also been investigated, as well as thepressure in the two tanks in the hydraulic cylinder and the flow of hydraulic oil toand from the landing gear.

In this experiment no physical testing will be performed, only simulations.

4.2.2 Dymola

The landing gear is modeled in Dymola. Dymola is a component based tool formodeling and simulation and is developed by Dynasim AB, a company based inLund. The ideas behind Dymola were originally developed by Hilding Elmqvistas a part of his Ph.D. thesis, which he attained at the Department of AutomaticControl, Lund Institute of Technology in 1978. Dymola uses the generic modelinglanguage Modelica, which is an object-oriented, declarative modeling language.Modelica is component-oriented and is used primarily for complex systems such asmechanical, electrical, hydraulic, thermal, control and electric power components,and is also capable of handling systems with two or more of these types.

The main landing gear modeled in Dymola is shown in figure 4.7.

Page 44: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

30 Experiments

Figure 4.5. A drawing of the Gripen main landing gear.

Figure 4.6. The Gripen Demo during flight.

Page 45: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

4.2 Landing gear experiment 31

Figure 4.7. The main landing gear, modeled in Dymola.

Page 46: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

32 Experiments

Initial value problem

Many simulation programs need a period of time to initialize and find the rightstationary states, and therefore you cannot order an event until a certain periodof time into the simulation, in order to let the system stabilize to a stationarypoint. This is not needed when using Dymola as it starts by solving an initialvalue problem. Still this requires correct initial values if initial oscillations are tobe avoided. One way to do this is to run a simulation for an appropriate time,save these final values obtained and use these as initial values.

Communication between Excel and Dymola

With the sensitivity analysis code written in Visual Basic for Application (VBA)in Excel and the model being modeled in Dymola, these programs need a means forcommunication. This is done using Dynamic Data Exchange (DDE), a technologyfor communication between different applications.

The user fills in the system parameter values and their deviations in Excel, andthe simulations will be executed as a batch. Excel/VBA will set the parametersand send these to Dymola, which executes the simulations and returns the valuesof the predefined system characteristics, and the local sensitivity analysis result iscalculated and presented in Excel. A simplified flow chart on the communicationbetween Excel and Dymola can be found in figure 4.8.

Figure 4.8. A simplified flow chart on the communication between Excel and Dymola.

Page 47: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

4.2 Landing gear experiment 33

The maximum length of a DDE command is 255 characters, which is a rathersmall number when the information demanded by Dymola includes model name,start values and final values. The modeler might also want to state the simulationtime and method, quickly resulting in more than 255 characters. To avoid theproblem of a commando string being too long, the system characteristics usedin the simulations in this thesis have been renamed in Dymola. This was donedirectly in the Dymola model, but when applying the method on bigger modelsand the analysis being used in everyday life it is not a tenable way to do it. Asuggestion on how to solve this problem is to write a part of the code in a Dymolascript, but this entails other problems, see further in Appendix C.

The Excel interface where the system parameters are filled in is shown infigure 4.9 and the system characteristics in figure 4.10. For a user’s guide on howto set the different values, see Appendix B.

Figure 4.9. System parameters used in the landing gear sensitivity analysis.

Figure 4.10. System characteristics investigated in the landing gear sensitivity analysis.

Page 48: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 49: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Chapter 5

Results - Hydraulic servo

experiment

This chapter starts with a comparison between the physical model and the HOP-SAN model used for simulation, in section 5.1. The system parameters and char-acteristics used in the sensitivity analysis are presented in section 5.2, followedby the results for a step input and a square wave input in sections 5.3 and 5.4respectively. Section 5.5 presents some observations made in this experiment.

5.1 Comparison between physical system and

HOPSAN model

One way to compare is to utilize the properties of control theory. Four propertieshave been looked closer at. These are overshoot, rise time, steady-state error andthe time constant. The overshoot is defined asM = (ymax−yf )/yf where yf is thesteady-state value and ymax is the maximum value of the signal. The overshoot isoften given in percents. The rise time, Tr is the time it takes for the signal to gofrom 0.1yf to 0.9yf . The steady-state error is defined as the difference betweenthe steady-state value and the reference signal. These can be seen in figure 5.1.A time constant is used to see in which time scale the output approaches thesteady-state value yf .

The results of these tests are shown in table 5.1. More detailed pictures of astep response for the physical system as well as the one modeled in HOPSAN areshown in figures 5.2 and 5.3 respectively.

5.1.1 Differences between the model and reality

The hydraulic system has been at least partially calibrated, but it was unknownwhen and how this was done. Since the purpose of this thesis is not to perfecta model for the experiment equipment described, the model has been adapted to

35

Page 50: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

36 Results - Hydraulic servo experiment

0 1 2 3 4 5 6 7 8 9 100

0.1

0.2

0.3

0.4

0.5

0.6

0.7

Time [s]

steady−stateerror

overshoot

yf

0.1 yf

0.9 yf

Tr

Figure 5.1. A step response example to clarify the terms: overshoot, rise time andsteady state error. The overshoot marked in the figure should be divided by yf to obtaina ersult in percents.

Table 5.1. Comparison between the control theoretic properties of the hydraulic servosystem.

Real system HOPSAN model

Time constant τ [s] 0.11 0.12Rise time [s] 0.12 0.14Steady-state error - 0Overshoot [%] 2.5 4.0

0 2 4 6 8 10−2.5

−2

−1.5

−1

−0.5

0

0.5

1

1.5

2

2.5

"Mod

el R

oot"

/"X

p filt"/

"Out

1"

"Mod

el R

oot"

/"X

pref

"

xpos

xpos,ref

Figure 5.2. Measurements from the step response of the hydraulic servo.

Page 51: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

5.2 System parameters and characteristics 37

Figure 5.3. Step response for the HOPSAN model, plotted the first 20 seconds and thefirst second respectively.

accord with the reality. This was done by changing the system gain, resulting ina system model that corresponds sufficiently with the real system.

5.2 System parameters and characteristics

The system characteristics chosen to investigate are: the spool position and thepressure levels in the piston, see table 5.2. The Relative model uncertainty, column5, is an estimation of the model structure uncertainty, given in percent. This isto be able to compare the influence of uncertainties in the parameters with theoverall uncertainty in the model structure; is it really worth refining the model ifthe uncertainties in e.g. the weight of the plane is much bigger than the modelstructure uncertainty?

Table 5.2. System characteristics investigated in sensitivity analysis.

System characteristics Name Value Unit Rel. model unc.Pressure node A P_SERVAL_1_NA 3104729 Pa 0.005Pressure node B P_SERVAL_1_NB 2977669 Pa 0.005Spool position XS_XSENSE_1 0.141110 m 0.01Spool position X_MLOADC_1_NX2 0.141110 m 0.005

Once the system characteristics to investigate are decided, the parameters thatwill or might influence these are elected. These can e.g. be known or be suspectedto have an influence on the system characteristics, or could be chosen to securethey do not affect the same. The system parameters chosen are: oil density andflow coefficient Cv or Cq in the valve, the bulk modulus of the oil and the pistonareas a1 and a2, the load mass of the bulk and the system gain, see table 5.3. Thevariability, or the deviation, is an estimate of the variations in the parameters.

Page 52: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

38 Results - Hydraulic servo experiment

Table 5.3. System parameters used in sensitivity analysis.

System group Name Value Variability UnitOil density RHO_SERVAL_1 870 100 kg/m3Flow coefficient CQ 0.67 0.1Bulk modulus of oil BETAE_PISTON_1 8.00E+08 4.00E+07 PaPiston area A1 7.60E-04 1.00E-04 m2Piston area A2 7.60E-04 1.00E-04 m2Mass ML_MLOADC_1 387 100 kgGain: Multiplier K_GAIN_1 0.02 0.002Amplitude input ystep_Pulsetraininput_1 0.08 0.02

5.3 Step response

The Effective Influence Matrix, see 3.2.1, performed on the HOPSAN modelresults in a matrix with rather small elements, as can be seen in figure 5.4.

Figure 5.4. EIM of a step response.

When starting out the process of deciding whether to go forward with the modelas it is or if it has to be worked with more it is useful to look at the normalizeddeviations of the system characteristics. In this case they are between one and tenpercent. If these are bigger than a threshold value, further investigation might beneeded.

Since the values in the EIM and the MSI matrix are based on the same in-formation, these are different ways of presenting the same information. The EIMstates how much smaller the deviation will become if the coupling between thissystem parameter and this certain system characteristic was perfect. With thevalues being rather small, it might not be economically defensible to continue therefinement of the model.

The Main Sensitivity Index matrix (see 3.2.2) can be seen in figure 5.5. Ata first glance it might look as if the piston areas A1 and A2 have a big impacton the pressures P_SERV AL_1_NA and P_SERV AL_1_NB, with elementvalues between 42 and 57 percent, but with a closer look it will be shown thatthese connections are not as bad as it could seem. Since the sum of the elements

Page 53: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

5.3 Step response 39

in each row is always one in the MSI matrix, these are only the internal relationsof the system parameters. If, as in this case, A1 and A2 are the only parametersinfluencing the pressures A and B, these elements will have rather high values. Itmight mean that these connections should be further investigated, or just that thissystem characteristic is affected by these parameters and these parameters only.

To decide which case it is, one has to look at the normalized deviations, oncondition that the deviations chosen are big enough. If the normalized deviationsare big enough, the model might be in need of more work if this deviation seemsbigger than expected, otherwise it is probably okay.

Figure 5.5. MSI of a step response.

One of the benefits with the MSI matrix is its lucidity. It is easy to see whichparameters that have the biggest influence on each system characteristic, and withthe percentage presentation it is not necessary to have a deeper understanding ofthe system being analyzed. At the same time, this is also a drawback, since bythe conversion into percentages some of the connection to the real system and theunderstanding of the same is lost.

5.3.1 Step response with new system characteristics and

some new parameters

Another sensitivity analysis has been performed on the model with a step input.In this experiment, the characteristics chosen to analyse are: the integral of thesquare of the fault,

∫ tend

t=0 (y − yref )2 dt, and the integral of the absolute value of

the fault,∫ tend

t=0 |(y − yref )| dt, see table 5.4.Two system parameters are added as well, the viscous friction coefficient Bp

and the coulomb friction force Fc, as can be seen in table 5.5.The updated HOPSAN model is shown in figure 5.6.

Table 5.4. Additional system characteristics investigated in sensitivity analysis.

System characteristics Name Value Unit Rel. model unc.Integrated (absolute(fault)) y_I1Filter_1 0.024 Pa 0.01Integrated ((fault)ˆ2) y_I1Filter_3 9.5E-4 Pa 0.01

Page 54: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

40 Results - Hydraulic servo experiment

Table 5.5. Additional system parameters used in sensitivity analysis.

System group Name Value Variability UnitViscous friction coefficient BP 20 20 Ns/mCoulomb friction force FC_MLOADC_1 100 20 N

Figure 5.6. Laboratory equipment for the extended hydraulic servo experiment modeledin HOPSAN.

The viscous friction coefficient Bp and the coulomb friction force Fc were sus-pected to have an impact on the system, but as can be seen in the figure 5.7 andthe figure 5.8 this was not the case.

The two system characteristics investigated,∫ tend

t=0 (y−yref )2 dt and

∫ tend

t=0 |(y−yref )| dt, are two rather common measurements of how good a model is. The EIMand MSI results of these can be seen in figures 5.7 and 5.8.

Other characteristics to investigate to make the comparison between the modeland the real system (in those cases where such a comparison is possible) could bethe overshoot or the maximum value. A maximum function finding the maximumvalue of a signal or vector are accessible in many modeling and simulation tools,such as Matlab/Simulink.

5.4 Square wave

With the input to the systems being a square wave, the output can be seen infigures 5.9 and 5.10.

The choice of inputs affects the EIM and MSI matrices, as can be seen in whencomparing the figures 5.4 with 5.11 and 5.5 with 5.12 for the EIM and MSI

Page 55: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

5.4 Square wave 41

Figure 5.7. EIM of the step response in section 5.3.1.

Figure 5.8. MSI of the step response in section 5.3.1.

0 2 4 6 8 10 12−2.5

−2

−1.5

−1

−0.5

0

0.5

1

1.5

2

2.5

"Mod

el R

oot"

/"X

p filt"/

"Out

1"

"Mod

el R

oot"

/"X

pref

"

xpos

xpos, ref

Figure 5.9. The behaviour of the hydraulic servo with a square wave as input.

Page 56: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

42 Results - Hydraulic servo experiment

Figure 5.10. The behaviour of the HOPSAN model with a square wave as input.

respectively. When choosing the input signal, it is essential to consider not onlythe type of input (e.g. a step, sine curve or square wave) but also other factors suchas simulation time. Since the values evaluated are the final values, the choice ofsimulation time is significant. Depending on which characteristics one is interestedin, the choices might be different. For a system reaching a stationary state in whichthe interest lies, it is essential to chose a simulation time that is long enough toreach that state.

In this case of a square wave input the final time can e.g. be chosen directlybefore or after a switch in input, or in between, this depends on which character-istics that are interesting. To investigate the overshoot, the simulation time wouldhave to end at an appropriate time after the switch.

To perform SA on a high frequency system is difficult, since the calculationsonly depend on the final values.

Figure 5.11. EIM of a square wave input.

Page 57: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

5.5 Observations 43

Figure 5.12. MSI of a square wave input.

5.5 Observations

Some conclusions can be drawn from this experiment. The sensitivity measure-ments EIM and MSI seem to give reasonable sensititvity matrices for the stepresponse experiment. This model har a transient behaviour but reaches a station-ary state at which the SA has been performed. The experiment with a squarewave input does not reach any stationary state, making the choice of simulationtime difficult. Depending on this choice the EIM and MSI matrices will be verydifferent, since only the final value of the simulation is considered.

A question that emerged was how one can know if the parameters tested are theonly ones affecting the system characteristics. The answer is you can’t. The choiceof system parameters upon which to base the SA have to be based on knowledge,or some intuition, about the system and how the parameters and characteristicsare connected or related.

Page 58: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 59: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Chapter 6

Results - Landing gear

experiment

The system parameters and characteristics used in the sensitivity analysis arepresented in section 6.1. In section 6.2 the results of a sensitivity analysis arepresented, for two different values in the system parameters. Some thoughts onthe assumption of linearity can be found in section 6.3 and some thoughts on theusefulness of the method in section 6.4. Section 6.5 presents some observationsmade in this experiment.

6.1 System parameters and characteristics

The goal of the simulation is to see how different frictions, mainly in the foldstay, affect the unfolding of the landing gear. The system parameters are chosenas the friction coefficients in the upper, center and lower folding stay joints, asstated in figure 6.1. Only three parameters have been chosen to investigate, scincethis is only a first evaluation, and more parameters result in longer analysis time.Table 6.1 presents the shortened names used in this report.

The friction coefficients µ used in the model are defined as

F (N) = µN (6.1)

where F (N) is the friction force, µ is the friction coefficient and N is the normalforce.

The system characteristics chosen are the final angle of the fold stay centerjoint, the time to extension, the pressures in the two hydraulic cylinder tanksand the flow of hydraulic oil to and from the landing gear. In the case of anemergency unfolding the hydraulic flow will not influence the external hydraulicsystem, but when the hydraulic cylinder is used to retract the landing gear, itwill affect the external system and is therefore an interesting characteristic. Sincethe two volumes in the hydraulic cylinder are connected but with a leakage in the

45

Page 60: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

46 Results - Landing gear experiment

Figure 6.1. System parameters used in sensitivity analysis.

Table 6.1. System parameters used in sensitivity analysis, and the shortened namesused in the report.

System parameter NamefoldStayUpperJoint.mue µupperfoldStayCenterJoint.mue µcenterfoldStayCenterJoint.mue µlower

emergency unfolding case, and the piston will compress the oil in tank B and thereverse in tank A, there will be zero pressure in tank A at the end of all simulations.

See the Excel interface in figure 6.2 and the shortened names for the charac-teristics used in this report in table 6.1.

Figure 6.2. System characteristics investigated in sensitivity analysis.

The EIM matrix contains elements of different magnitudes (from values close tozero to values of more than a hundred). Two different cases can be distinguished:where the three µ:s, µupper, µcenter and µlower all have contributions (p_b andflow_2 ) and where µcenter influences the most (revoluteAngle, extensionTime andflow_1 ), see figure 6.3. The p_a is not affected by any of the system parametersabove and the model uncertainty contributes only marginally.

6.2 Sensitivity measures

To tune the shaping of the landing gear, a sensitivity analysis is performed on anemergency unfolding. This is to be able to see which frictions contribute the mostto possible problems in unfolding.

Page 61: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

6.2 Sensitivity measures 47

Table 6.2. System characteristics used in sensitivity analysis, and the shortened namesused in the report.

System characteristic NamefoldStayCenterJoint.revolute.angle revoluteAngletimeToExtend.y extensionTimeactuator.linActuator.p_a p_aactuator.linActuator.p_b p_bactuator.CB1.m_flow flow_1actuator.CB2.m_flow flow_2

The EIM matrix contains elements of different magnitudes (from values close tozero to values of more than a hundred). Two different cases can be distinguished:where the three µ:s, µupper, µcenter and µlower all have contributions (p_b andflow_2 ) and where µcenter influence the most (revoluteAngle, extensionTime andflow_1 ), see figure 6.3. The p_a is not affected by any of the system parametersabove and the model uncertainty contributes only marginally.

Figure 6.3. EIM of the landing gear model with a deviation of 0.20.

In the MSI matrix almost the same conclusions can be drawn: the character-istics for which the three friction coefficients µupper, µcenter and µlower all havecontributions (p_b) and for which µcenter influence the most (revoluteAngle, ex-

tensionTime and flow_1 ), see figure 6.4. In the MSI, the flow_2 belongs to thisthe second group of system characteristics.

As stated in section 3.2.2 the row sum of MSI always equals one, which is notthe case for the p_a. This is because the value of p_a equals zero at the finaltime step for each of the simulations, regardless of the values of µupper, µcenterand µlower.

With a smaller deviation of 0.10 added to µupper, µcenter and µlower, as shownin picture 6.5, the model uncertainty becomes more influential than with the biggerdeviation of 0.20 above.

Page 62: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

48 Results - Landing gear experiment

Figure 6.4. MSI of the landing gear model with a deviation of 0.20.

Figure 6.5. The system parameters with the deviation changed to 0.10.

Page 63: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

6.2 Sensitivity measures 49

Beside the higher model uncertainty influence in the EIM matrix, there areother differences. The revoluteAngle, flow_1 and flow_2 are each affected by allthree frictions as well as the model uncertainty. The p_a still equals zero in allsimulations. The extension time extensionTime is influenced only by the modeluncertainty whereas the µcenter has the main influence on p_b. The EffectiveInfluence Matrix is shown in figure 6.6.

Figure 6.6. EIM of the landing gear model with a deviation of 0.10.

In the MSI matrix the dispersion compared to the analysis of when the devia-tion is 0.20 (figure 6.4) is bigger, see figure 6.7. For three of the characteristics themodel uncertainty has an 80 percent or bigger influence; extensionTime (98 %),flow_1 (also 98 %) and flow_2 (80 %, the remaining 20 % come from µcenter).The p_a still equals zero in all simulations, resulting in a row with all zeros. Thep_b is primarily affected by µcenter, while µupper and µcenter have the biggestinfluence on the angle revoluteAngle, with a smaller contribution from µlower.

Figure 6.7. MSI of the landing gear model with a deviation of 0.10.

Page 64: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

50 Results - Landing gear experiment

6.3 Is the assumption of linear systems reason-

able?

Under the assumption of linearity around the nominal point at which we areworking, the results should be the same for a positive and a negative deviation.To examine if this is the case for the landing gear, an experiment where thedeviation of the tau_zero in the Center Joint was exchanged for a negative value(−5 was used instead of +5) is executed. As can be seen in the figures 6.8 and 6.9,the assumption is not fully correct, but the parameter can be considered linear.Since it is not possible to check if the assumption of linearity is reasonable, someexpertise is crucial to be able to settle the linearity of the parameters.

The same can be said about the size of the linear deviation: how big can thedeviation be without its getting outside the linear zone?

It is thus important to be acquainted enough with the system and/or the modelto be able to conclude whether or not it can be considered linear for these pusposes.

Figure 6.8. The MSI matrix with tauzero = 15 and the variability +5.

Figure 6.9. The MSI matrix with tauzero = 15 and the variability −5.

Page 65: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

6.4 Usefulness in an industrial example 51

6.4 Usefulness in an industrial example

The sensitivity analysis increases the knowledge of the model/system behaviourand results in a comprehension of the simulation model result quality. To usethe sensitivity analysis methods involving EIM and MSI, no test data is necessarywhich means the robustness of a model can be examined early in the modelingprocess. It is also implementable in the different stages of the M&S process, whichis an important part of the usefulness of the method.

The modeling and simulation process with its methods is an enforced way ofobtaining a structured, systematic documentation of the system parameter’s un-certainties and the model’s fidelity [21]. Today the modelers have to use theirexpertise to judge whether or not a model is finished, and there’s often no docu-mentation to support the decision for when the model is finished. With the sensi-tivity analysis methods in this thesis documentation can be produced at all stagesof the modeling process, and the improvements in the model are documented.If different measures are used throughout the modeling process, comparisons aredifficult and the demand on more knowledge about the model and the differentmethods increases.

Some desires of the method and model quality measures are that they shouldbe easy to understand, easy to use and the results should be easy to understand.The time spent on executing the analysis also has to be well spent; both in thetime preparing the analysis and in analyzing the results.

Of course, to be able to draw the correct conclusions, it is essential that theinformation that is entered into the analysis at the beginning, i.e. nominal pointand deviation of the system parameters and the model uncertainties, is well chosen.

The sensitivity analysis examined in this thesis display a good compromisebetween usefulness and computational cost. It does not demand knowledge inprogramming, nor does it demand any deeper understanding of statistics, makingit available to both the model creators and the model users.

6.5 Observations

The results from these tests seem reasonable, but some observations have beenmade which could have led to better ones.

Final values close to zero causes problems in the normalization; with the finalvalue being the denominator this leads to a division with zero. The revoluteAngle

has the final value 5.0 · 10−5rad in the simulation with the nominal values (µ =0.05), final value 6.0 · 10−5rad with µ = 0.05 + 0.10 = 0.15 and final value 0.03radwith µ = 0.05 + 0.20 = 0.25. This leads to matrix elements which might be hardto evaluate, the normalized deviation is 150 times smaller with the µ = 0.15 thanwith µ = 0.25; is this correct or is it due to the normalization?

Discrete characteristics should also be avoided. In this thesis the angle revo-

luteAngle is continuous, but the real interest lies in whether the landing gear isfully extended and the lock mechanism is locked or not. This is hard to determinefrom the EIM and MSI results.

Page 66: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 67: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Chapter 7

Summary and conclusions

This chapter concludes the thesis with a short summary, section 7.1, and someconclusions, in section 7.2.

7.1 Summary

In order to minimize the time of development for a product as well as reducingthe necessity of extended testing on the physical product, the demand on a knownaccuracy of the results of a model simulation (i.e. how well the result reflectsthe behaviour of a real system) has grown more important. The accuracy of asimulation result is a function of the knowledge of the uncertainties in the systemparameters, which can be estimated with or without access to test data. It is alsobased on the knowledge that there are other sources of uncertainties, unknown tous.

One way of investigating how the model depends upon information fed into itis through sensitivity analysis. Sensitivity analysis (SA) is the study of how thevariation in the output of a model (numerical or otherwise) can be apportioned,qualitatively or quantitatively, to different sources of variation. By performing SAon a system, it can be determined which inputs influence a certain output themost. This information can then be used as a guideline to determine the areasthat need higher attention. One big advantage with SA methods is that no testdata is needed, making it possible to implement early in the modeling process.The sensitivity analysis increases the knowledge of the model/system behaviourand results in a comprehension of the simulation model result quality.

Demands on a SA method to be used are among other things that the methodand model quality measure should be easy to understand, easy to use and theresults should be easy to understand. The time spent on executing the analysisalso has to be well spent; both in the time preparing the anaylsis and in analyzingthe results. If the time to perform the sensitivity analysis is too long in relationto the results obtained, the analysis will never be performed.

The sensitivity measures used in this thesis are the Effective Influence Ma-trix, EIM, and the Main Sensitivity Index, MSI. Both EIM and MSI present how

53

Page 68: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

54 Summary and conclusions

variations in the system parameters influence the variations in the system charac-teristics.

The EIM states how much smaller the deviation will become if the couplingbetween this system parameter and this certain system characteristic was perfect.Due to the non-linear form of the EIM there are often very few significant ele-ments; a large deviation in one parameter quickly shadows the influence of otherparameters.

In the MSI matrix, the values are normalized so the row sum is always one. Abenefit with the MSI matrix is its lucidity. It is easy to see which parameters thathave the biggest influence on each system characteristic, and with the percentagepresentation it is not necessary to have a deeper understanding of the system beinganalyzed. It is not necessary to have a deeper understanding of the system beinganalyzed to understand the division into percentages. At the same time, this isalso a drawback, since by the conversion into percentages some of the connectionto the real system and the understanding of the same is lost.

To examine the sensitivity measures described, two tests have been made. Oneon a laboratory equipment including a hydraulic servo, and one on the landinggear model of the Gripen aircraft. The hydraulic servo model could represent themovements of beams and other equipments in a mechanical system. The aim ofthis experiment is to test the local sensitivity analysis method on a quite smalland well defined problem. The system is easily handled and small enough to getthe general view of. The purpose of the landing gear experiment is to examinethe influence of different frictions on the unfolding of the landing gear - mainly toexamine whether or not it will extend fully and reach the end position when inemergency state, or if it will be suspended half way. It is also a way to test thesensitivity analysis method on an industrial example, and to evaluate the method.

Not only the parameter uncertainties are possible to examine, but also theuncertainties in model structure. With the means to state the model uncertaintyit is also possible to compare the influence of uncertainties in the parameters withthe overall uncertainty in the model structure; is it really worth refining the modelif the uncertainties in e.g. the weight of the plane is much bigger than the modelstructure uncertainty?

Some knowledge is required of the model developer in order to be able to definereasonable values to use. To be able to draw correct conclusions, it is essential thatthe information that is entered into the analysis at the beginning, i.e. nominalpoint and deviation of the system parameters and the model uncertainties, is wellchosen.

Page 69: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

7.2 Conclusions 55

7.2 Conclusions

The EIM and MSI matrices have proved to have some utility on the experimentsperformed in this thesis. The results obatained have been reasonable compared tothe time executing the sensitivity analysis. The two sensitivity measures comple-ment each other and people with different background could have more use of oneor the other. If I were to choose only one I would choose the EIM since it providesa more exact and delailed picture while the MSI gives more of an overview.

Sensitivity analysis is not an exact science, but gives an indication to the areaswhich contain the most uncertainties, and where more work might be needed.

One problem is how to know if the parameters tested are the only ones affectingthe system characteristics. With global sensitivity analysis the parameters aretested, their influence alone as well as in combination with all others. Whenchoosing a local SA method the gain in time to perform the analysis is paid withthe loss of information. Some knowledge about the system and how the parametersand characteristics are connected or related is needed. Another problem is thatthe systems upon which to perform the SA should preferarbly not be transient,and in the choice of system characteristics discrete ones should be avoided.

But overall the methods evaluated have been promising and with some morework to adapt the programs to the models used at TDGT, they could be used inthe modeling process.

Page 70: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 71: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Chapter 8

Future work

One way to further use local sensitivity analysis methods is to couple it withprobabilistic design. Probabilistic design is when the system designer considersthe parameters not as a value or a number, but as a probability distribution.This can be seen as if the probabilistic design predicts the flow of variability (ordistributions) through a system [24].

To see how a reduced global sensitivity analysis could be used, for example tovary two paramters at a time, could improve the usefulness of the EIM and MSImethods.

Another possibility is to see how SA could be adapted to the frequency domain.This could be used when a system has a transient behaviour making it not suitablefor the EIM and MSI applied to the time domain in this thesis. In these cases itwould be interesting to investigate the possibility to perform a sensitivity analysison frequency domain properties such as band width and phase margin.

57

Page 72: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare
Page 73: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Bibliography

[1] M. Alirand and A. Jansson. A first idea of continuity in model simplificationfor hydraulic circuit - an automatic gearbox real-time application. The 9thScandinavia International Conference on Fluid Power, SICFP’05, LinköpingSweden., 2005.

[2] Jerry Banks, editor. Handbook of Simulation: Principles, Methodology, Ad-vances, Applications, and Practice. John Wiley & Sons, New York, 1998.ISBN 0-471-13403-1.

[3] P. T. Biltgen. Uncertainty quantification for capability-based systems-of-systems design. 26th International Congress of the Aeronautical Sciences,Anchorage USA, ICAS2008-1.3.3, 2008.

[4] Peter C. Breedveld. Port-based modeling of mechatronic systems. Mathe-matics and Computers in Simulation, 66, 2004.

[5] François Cellier. Continuous System Modeling. Springer-Verlag New York,Inc., 1991. ISBN 0-387-97502-0.

[6] Wei Chen, Ruichen Jin, and Agus Sudjianto. Analytical metamodel-basedglobal sensitivity analysis and uncertainty propagation for robust design. SAEtransactions, 113(5), 2004.

[7] Alison C. Cullen and H. Christopher Frey. Probabilistic Techniques in Expo-sure Assessment. Plenum Press, New York, 1999. ISBN 0-306-45956-6.

[8] A.R. Daneshkhah. Uncertainty in Probabilistic Risk Assessment: A Re-view. http://www.shef.ac.uk/content/1/c6/03/09/33/risk.pdf, August 92004. 2009-06-10.

[9] Linköping University Division of Fluid Power Technology. Lab. 3 in the courseTMHP51 Hydraulic servo systems — Linear position servo with stabilis-ing feedback. http://www.iei.liu.se/content/1/c6/10/28/03/lab/LabEx%203-4_tmhp51.pdf. 2009-06-08.

[10] Dynasim. Dymola. http://www.dynasim.se/.

[11] Paul A. Fishwick, editor. Handbook of Dynamic System Modeling. Chapman& Hall / CRC, Boca Raton, 2007. ISBN 1-58488-565-3.

59

Page 74: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

60 Bibliography

[12] Hampus Gavel, Sören Steinkellner, Henric Andersson, and Petter Krus. Mod-eling and simulation of saab gripen’s vehicle systems. American Institute ofAeronautics and Astronautics (AIAA), Modeling and Simulation TechnologiesConference, Chicago USA, August 2009. AIAA 2009-6134-93.

[13] Jan Hauth. Grey-Box Modelling for Nonlinear Systems. http://kluedo.ub.uni-kl.de/volltexte/2008/2287/pdf/diss.pdf, December 2008. 2009-07-06.

[14] Petter Krus. Engineering Design Analysis and Synthesis.http://sites.google.com/site/petterkrus/Home/research-interest/model-based-qfd as DesignAnalysisandSynthesis08.pdf, November 4 2008. 2009-02-24.

[15] Jonas Larsson. User’s guide to Hopsan - An integrated simulation en-vironment. Department of Mechanical Engineering, Linköping University,http://www.iei.liu.se/flumes/hopsan?l=en, 2002. 2009-04-21.

[16] Lennart Ljung and Torkel Glad. Modellbygge och simulering. Studentlitter-atur, 1991. ISBN 91-44-02443-6.

[17] Mathworks. Matlab/Simulink. http://www.mathworks.com/.

[18] Saab. A history of high technology.http://www.saabgroup.com/en/AboutSaab/History/history.htm. 2009-07-06.

[19] A. Saltelli, K. Chan, and E. M. Scott, editors. Sensitivity Analysis. JohnWiley & Sons, Chichester, 2000. ISBN 0-471-99892-3.

[20] Sören Steinkellner and Henric Andersson. Hosted simulation. TechnologyTransfer, 4, 2008.

[21] Sören Steinkellner and Petter Krus. Balancing uncertainties in aircraft systemsimulation models. CEAS, Council of European Aerospace Societies, 2ndEuropean Air & Space Conference, Manchester U.K., October 2009.

[22] Wikipedia. Accuracy and Precision. http://en.wikipedia.org/wiki/Accuracy_and_precision. 2009-03-06.

[23] Wikipedia. Causal system. http://en.wikipedia.org/wiki/Causal_system.2009-09-01.

[24] Wikipedia. Probabilistic design. http://en.wikipedia.org/wiki/Probabilistic_design. 2009-08-31.

Page 75: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Appendix A

Nomenclature

Definitions and abbreviations used in the thesis are assembled in this chapter.

A.1 Definitions

Definition A.1 Accuracy and precision

Accuracy: Accuracy is the degree of closeness of a measured or calculated quan-tity to its actual (true) value and indicates proximity to the true value, see an illus-traion in figure A.1. In statistics the related term is bias (non-random or directedeffects caused by a factor or factors unrelated by the independent variable) [22].

Precision: Precision is closely related to accuracy. It is also called reproducibil-ity or repeatability, the degree to which further measurements or calculations showthe same or similar results, figure A.1. In statistics the related term is standarddeviation (random variability) [22].

Figure A.1. Illustration of the terms accuracy and precision, [22].

61

Page 76: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

62 Nomenclature

Definition A.2 Causality

Causal modeling: Causality in modeling describes the computational direction.When writing the equations in a program, some demand an explicit declarationof the variables whereas others accept implicit declarations. This causality, bondcausality, also gives the modeler a representation of the physical and computationalstructure of the model [4].

Causal system: A causal system is a system where the outputs and internalstates depend only on present and previous input values [23].

Non-causal and anticausal system: A non-causal or acausal system is a sys-tem where the outputs and internal states depend not only on present and previousinput values but have some dependence on future input values. A system that de-pends solely on future input values is an anticausal system [23].

A.2 Abbreviations

Table A.1. Abbreviations used in the thesis.

DAE Differential-Algebraic EquationsDDE Dynamic Data ExchangeEIM Effective Influence MatrixGUI Graphical User InterfaceM&S Modeling and simulationMSI Main Sensitivity IndexODE Ordinary Differential EquationsR&D Research and DevelopmentSA Sensitivity AnalysisSI System IdentificationTDGT Section for Simulation and Thermal Analysis at SAAB AerosystemsTSI Total Sensitivity IndexVBA Visual Basic for Application

Page 77: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Appendix B

User’s guide

This chapter presents a short guide to the Excel interface. Figure B.1 shows theSystem parameters tab and figure B.2 shows the System characteristics tab.

Figure B.1. The System parameters tab in the Excel interface.

63

Page 78: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

64 User’s guide

Figure B.2. The System characteristics tab in the Excel interface.

Page 79: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Appendix C

Problems and improvements

Some problems that have occurred during the work with this thesis and theircauses, as well as a suggestion for improvement, are presented in this chapter.

Problem

The DDE code string is too long (it may contain no more than 255 characters).

Cause

Shorten the names of the system characteristics. A fast way to do this is to usethe code as in D.1.

A probably better method would be to write a Dymola script, containing thecode ordering a simulation. This has been tried but did not work out as the modelwas translated, restoring all parameters to the start values and the parameters setin Excel “lose” their values. Having to translate the model before each simulationalso slows down the process. If put in a script there would not be a maximumnumber of characters and it would be possible to use the full names of the systemcharacteristics, but this idea has not been effected.

Problem

The row elements in the MSI matrix do not sum up to one.

Cause

The VBA code uses a constant div_to_zero of 1 · 10−15 to avoid division by zero.If the values are of a similar magnitude this might cause problems.

65

Page 80: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

66 Problems and improvements

Problem

The simulation is not completed.

Cause

The initial values might not be accepted by Dymola. This might occur when theset of values does not converge in Dymola.

Improvement

One improvement that needs to be made is to make the GUI (Graphical UserInterface) more user-friendly. The programs that have been used in this thesis willneed some extra work to become more accessible in the modeling process. Todayit is necessary to make changes in the VBA code to execute a sensitivity analysis.To make the method more easy to use it would be a good idea to move all usercommunication to Excel.

Page 81: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

Appendix D

Code

The code used to shorten the Dymola names is presented in section D.1, a newcomponent is describes in section D.2 and the code for the terminate function usedin Dymola in section D.3.

D.1 How to shorten Dymola names

In order to fit in the DDE code in no more than 255 characters, it might bedesirable to shorten some Dymola names. The code example below will result ina DDE code 88 characters shorter than the original.

// Shortened variable names

Real angleExt;

Real tExt;

Real lin_p_a;

Real lin_p_b;

Real CB1_m_flow;

Real CB2_m_flow;

// Original model code.

equation

angleExt = foldStayCenterJoint.revolute.angle;

tExt = timeToExtend.y;

lin_p_a = actuator.linActuator.p_a;

lin_p_b = actuator.linActuator.p_b;

CB1_m_flow = actuator.CB1.m_flow;

CB2_m_flow = actuator.CB2.m_flow;

67

Page 82: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

68 Code

D.2 New Dymola component

This new component, TimeToExtend, takes the angle in the fold stay center jointas input. When this angle reaches a value of 0.5◦ or less, the output is set to thetime. So if the angle 0.5◦ is reached, the output y will tell at which time thishappened, and if the angle is not reached the output will equal zero.

model TimeToExtend "Time in defolding state to reach full extension"

parameter Real extendAngle=0.5/180*Modelica.Constants.pi;

Boolean mode(start=false);

Modelica.Blocks.Interfaces.RealInput u

Modelica.Blocks.Interfaces.RealOutput y(start=0)

equation

mode = (u < extendAngle);

when edge(mode) then

y = time;

end when;

end TimeToExtend;

D.3 Terminate function

A terminate function has been constructed to be put to use when the landing gearis fully extended, since the simulation progress at angle≈ 0◦ is slow due to stiffness.The function will terminate the simulation 0.3 seconds after the passing of Lockmechanism angle = 0.5◦, using the output from the TimeToExtend componentdesribed above. It overrules the simulation time given in the “Simulation Setup”window.

// Terminate function, see bottom of code.

Real timePlus(start=300); // Help variable

// Original model code.

//

algorithm

when

(timeToExtend.y > 0) then

timePlus :=time + 0.30;

Page 83: Local Sensitivity Analysis of Nonlinear Models – Applied ...275512/FULLTEXT01.pdf · Local Sensitivity Analysis of Nonlinear Models – Applied to Aircraft Vehicle Sys-tems Författare

D.3 Terminate function 69

end when;

if (time > timePlus) then

terminate("Fully extended");

end if;