Книжная полка Сохранить
Размер шрифта:
А
А
А
|  Шрифт:
Arial
Times
|  Интервал:
Стандартный
Средний
Большой
|  Цвет сайта:
Ц
Ц
Ц
Ц
Ц

Fundamentals of event-continuous system simulation theory

Покупка
Основная коллекция
Артикул: 778806.01.01
Effective computer analysis of event-continuous and hybrid systems is addressed. A multipurpose software architecture employing control of the integration step size with regard to the error, stability, and unilateral events is proposed. The problem of synchronization of continuous and discrete processes is dealt with. All new theoretical concepts are tested on heterogeneous applications to biological systems, large electric power systems, mechanical engineering and chemical kinetics problems.
Шорников, Ю. В. Shornikov, Yu. V. Fundamentals of Event-Continuous System Simulation Theory : textbook / Yu. V. Shornikov, D. N. Dostovalov. - Novosibirsk : NSTU Publisher, 2018. - 175 p. - ISBN 978-5-7782-3773-5. - Текст : электронный. - URL: https://znanium.com/catalog/product/1869241 (дата обращения: 28.03.2024). – Режим доступа: по подписке.
Фрагмент текстового слоя документа размещен для индексирующих роботов. Для полноценной работы с документом, пожалуйста, перейдите в ридер.

Co-funded by the Erasmus+ Programme of the European Union





                ж InMotion






FUNDAMENTALS
OF EVENT-CONTINUOUS SYSTEM SIMULATION THEORY

YU. V. SHORNIKOV, D. N. DOSTOVALOV







NOVOSIBIRSK

2018

UDC 004.94(075.8) S 55

Reviewers:


Professor V. V. Aksenov, D.Sc. (Phys. & Math.),


Professor A. A. Voevoda, D.Sc. (Tech.)

Co-funded by the Erasmus+ Programme of the European Union

Ш inMotion

        This publication was conducted within InMotion project (Innovative teaching and learning strategies in open modelling and simulation environment for student-centered engineering education (573751-EPP-1-2016-1-DE-EPPKA2-CBHE-JP).



         This project has been funded with support from the European Commission. This publication reflects the views only of the authors, and the Commission cannot be held responsible for any use which may be made of the information contained therein.



        Shornikov Yu. V.


S 55           Fundamentals of Event-Continuous System Simulation Theory :
         Textbook / Yu. V. Shornikov, D. N. Dostovalov. - Novosibirsk : NSTU Publisher, 2018. - 175 p.

               ISBN 978-5-7782-3773-5

               Effective computer analysis of event-continuous and hybrid systems is addressed. A multipurpose software architecture employing control of the integration step size with regard to the error, stability, and unilateral events is proposed. The problem of synchronization of continuous and discrete processes is dealt with. All new theoretical concepts are tested on heterogeneous applications to biological systems, large electric power systems, mechanical engineering and chemical kinetics problems.



UDC 004.94(075.8)
ISBN 978-5-7782-3773-5               © Shornikov Yu.V., Dostovalov D.N.,        2018
© Novosibirsk State Technical University, 2018

            Contents




    Preface                                                                 7

    1  Event-Continuous Systems                                            9
       1.1 Discrete-Continuous  Models ................................... 9
       1.2 Continuous Models   .......................................... 15
           1.2.1  Solution Dependence on the Initial Conditions ......... 17
           1.2.2  Lyapunov Stability .................................... 17
           1.2.3  Caratheodory’s Conditions ............................. 18
       1.3 Discrete Models and  Zeno Behavior ........................... 21
           1.3.1  Zeno Phenomenon ....................................... 22
           1.3.2  Harel Statecharts ..................................... 25
       1.4 Modes and Events ............................................. 25
       1.5 Local and Global Behavior .................................... 28
       1.6 Discontinuity Classification ................................. 29
           1.6.1  Change of Initial Conditions .......................... 29
           1.6.2  Change of the Values of Right-Hand Side Parameters . . . 30
           1.6.3  Changing the Right-Hand Side Form without Changing the Set of Continuous State Variables ............................ 32
           1.6.4  Changing a Hybrid System Mode Right-Hand Side along with Changing the Set of Continuous State Variables . . .       33

    2  Mathematical Foundations of HS Mode Numerical Analysis 37
       2.1 Choosing a Numerical Scheme .................................. 37
       2.2 Convergence .................................................. 40
       2.3 Stability .................................................... 40
       2.4 Runge-Kutta Methods .......................................... 42
       2.5 Stiffness .................................................... 43
       2.6 Accuracy (Error) Control ..................................... 44
       2.7 Stability Control ............................................ 45
       2.8 Step Size Control ............................................ 47
           2.8.1  Step Size Control with Respect to the Error ........... 47
           2.8.2  Step Size Control with Respect to the Stability ....... 47

            2.8.3 Step Size Control with Respect to the Error and Stability . 48
       2.9  Method of Order Two .......................................... 48
       2.10 Adams’ Method ................................................ 50

    3  Correct Detection of Discrete Events                                   53
       3.1  Hybrid System’s Singular Regions ............................. 53
       3.2  Problem of Correct Discrete Event Detection .................. 54
       3.3  Linearization and the Relaxation Method in Event Localization .   56
            3.3.1 Event Function Linearization ........................... 57
            3.3.2 Relaxation Method in Event Detection ................... 58
       3.4  Ensuring Asymptotic Approaching the Event Surface for Explicit Schemes ........................................................... 59
            3.4.1 Detection Algorithm with a One-Step Method of Order Two 60
            3.4.2 Adams’ Method in Event Detection ....................... 62
            3.4.3 L-Stable  Method in Event Detection..................... 66
       3.5  Hybrid Systems with Nontrivial Event Functions ............... 71

    4  Software                                                            75
       4.1  Architecture of the Modeling and Simulation Environment ...... 75
       4.2  Visual Computer Models ....................................... 78
            4.2.1 User-Defined (Macro)  Blocks ........................... 79
            4.2.2 Data Import ............................................ 82
       4.3  Textual Models ............................................... 84
            4.3.1 Specification of Discrete Behavior ..................... 84
            4.3.2 Specification of Continuous Behavior ................... 88
            4.3.3 Macros in Textual Description .......................... 90
       4.4  Block-Textual Models ......................................... 93
       4.5  Computer Model Analysis ...................................... 96
            4.5.1 Textual Model Analysis ................................. 96
            4.5.2 Visual Computer Model Analysis ......................... 99
       4.6  Graphical Interpretation of Simulation Results .............. 102

    5  Software   Unification                                             105
       5.1  Topicality and Problem Statements ........................... 105
            5.1.1 Chemical Kinetics ..................................... 105
            5.1.2 Models with Distributed  Properties ................... 106
       5.2  Construction of Chemical Kinetics Differential Equations .... 107
            5.2.1 Syntax ................................................ 109
            5.2.2 Semantics ............................................. 110
       5.3  Supported Types of Partial Differential Equations ........... 111
            5.3.1 Textual Language   LISMA_PDE .......................... 112

                5.3.2 Modeling and Simulation of an HS with Distributed Properties ................................................... 114

        6   Modeling and Simulation Examples                                117
           6.1  Model of Two Tanks with Sluggish Valves .................. 117
           6.2  Interactive Simulation ................................... 120
           6.3  Production-Distribution System Model.......................122
           6.4  Transient Heat Conduction Model     ...................... 129
           6.5  Ring Modulator ........................................... 131
           6.6  Biosystems ............................................... 136
                6.6.1 Modeling and Simulation of Diffusion ............... 136
                6.6.2 Computer Modeling and Simulation of the Biliary System 138
           6.7  Power Engineering ........................................ 144

        Bibliography                                                       153

        A Visual Modeling Languages of the ISMA Environments                161

        B   Shortened Version  of the LISMA_PDE Grammar                    165

        C   List of Handled Semantic       Errors                          169

        D Symbolic Computer Model of the Production-Distribution System                                                             171


            Preface




Physical systems interacting with software applications (so-called event-continuous systems) can be effectively modeled as heterogeneous systems including subsystems with continuous time and subsystems interacting with discrete events. Initially, the terminology of discrete-continuous systems based on concrete mathematical concepts was developed, although it was limited in the dimensions of the analyzed systems due to using the analogue approach. Usually, the continuous components of a system are modeled as differential equations, whereas its discrete events are modeled with the aid of a finite automaton. The most important theoretical and practical contribution to the field of event-continuous systems is the development of systems theory, control theory, computer-aided analysis software, et cetera. In order to ease the usage of different analytical approaches, numerous software applications (Charon, HyVisual, HyTech, etc.) and tools for effective numerical analysis and data processing were developed. The important features of the new software tools are surveyed in works of J.M. Esposito. Professor Esposito, in particular, suggested new paradigms such as event functions. It led to the creation of new approaches to numerical analysis of discrete-continuous phenomena. A new methodology of studying event-continuous systems was developed.
   At the same time, there appeared the need of development of a new event-driven multipurpose software architecture dealing with situations when a few events might occur simultaneously, which would normally lead to a nontrivial modeling problem. The new methodology allowed solving high-dimensional problems, but now there is the problem of stiff modes. And here, by the way, Professor E.A. Novikov obtained major scientific results, considering completely different fundamental problems. And whereas, in works of Dr. Esposito, when simulating event-continuous systems, the integration step size is controlled only by the error tolerance conditions and the requirement to detect unilateral events, we add the stability conditions, taking into account the stiffness, and consider the dynamical behaviors of the event functions, which speeds the event detection algorithm up.
   It should be noted that event-driven systems are of more and more use in different totally not related areas. The examples are the heterogeneous modeling and simulation of living systems, large electrical power systems, mechanical engineering, chemical kinetics systems, chemical industry, and many other applications.

7

PREFACE





   The book is written in such a manner that it can be easily understood. It includes the necessary theoretical concepts and practical examples, and can help one to study complex event-continuous phenomena.

            Chapter 1


            Event-Continuous Systems



The terminology of hybrid systems (HS) in the modern literature is mostly given at a denotative level and is quite contradictory in different sources. The strict mathematical definitions of new HS paradigms are introduced below. The introduced definitions are illustrated in detail by numerous simple and understandable examples of typical hybrid systems. For certainty, we will distinguish event-continuous models or hybrid systems (HS) from traditional discrete-continuous systems by using new paradigms and the corresponding new numerical analysis techniques.

        1.1 Discrete-Continuous Models

We cite examples of discrete-continuous systems (DCS), which, in contrast to event-continuous systems, will be figuratively classified as DCSs due to the difference of the analysis techniques. Mathematical models of DCSs are introduced in [1, 2, 3, 4, 5] and were analyzed in the ISMA environment [6].

Example 1.1  Biliary System
     A system of differential equations modeling the bile secretion dynamics in living creatures and, particularly, in a normal human biliary system is written as



                        x⁰₁ = c - F1 (x1) + F2 (x2), x⁰₂ = -F2 (x2) x1 (0) = x10, x2(0) = x20,


(1.1)

     where c [smC = const is the rate of bile producing by the liver, x1[ml] is the volume of the bile in the bile duct, x₂ [ml] is the volume of the bile in the


9

CHAPTER 1. EVENT-CONTINUOUS SYSTEMS

     gallbladder. The nonlinear functions F1 , F2 are defined in the form

                  {F ?                    f          F ?
k1X1,X1 < —¹ ,         I k2X2,X2 < .2 ,
                             Fk¹? F2(x2) =           Fk²?    (1.2)
F1?,X1 > T1-;        I F2?,X2 > ,2.
                             k₁                      k₂

where k1 , k2 are the constant normalizing coefficients of bile deposition rate, F₁? , F₂? are the maximum rates of bile going out of the gallbladder and the bile duct respectively.
The model of the bile dynamics in the biliary system is a discrete-continuous one. Let us consider the linear segments without saturation, when x1 < x?₁ = F₁?/k₁, x₂ < x?₂ = F₂?/k₂. Then, the initial model can be rewritten as



            x⁰₁ = c₁ - k₁x₁ + k₂x₂, x⁰₂ = -k₂x₂,

x1 (0) = x10, x2(0) = x20,


(1.3)

where c₁ = const is the rate of bile secretion on the linear segment. The roots of the system are found from its characteristic equation

-ki - Ai

-k₂ - A₂

(1.4)

0

We have A₁ = -k₁ and A₂ = -k₂. Considering that k₁ > 0 and k₂ > 0 by definition, the system of equations has negative real roots. In this case, the solution is asymptotically stable with the asymptote x1 = c1/k1. The phase portrait in the phase plane x2(x1) has a stable node at the point (c1/k1, 0). For the parameters’ values [7] c1 = 20, x₁? = 7, F₁? = 35, x?₂ = 10, F₂? = 100, a part of the phase portrait is shown in Fig. 1.1.
These explorations have shown that the biliary system is stable even in the critical mode when the bile ducts are overfilled with bile. And it is consistent with the principle of homeostasis in an organism, following which the biliary system tends to return to the equilibrium state even in case of violation of the normal physiological activity.
If we accept the hypothesis that the rates of bile outflow and inflow with respect to the gall bladder and the the bile duct follow Torricelli’s law, then we have
xi = Ci - ai^x? + a2^X2, x'₂ = ¹¹2^X2,                  (1.5)


where

ai =

a2 =

(1.6)

1.1. DISCRETE-CONTINUOUS MODELS

11

Figure 1.1: Phase portrait of the production of bile

      In this case, the phase portrait has a stable node as illustrated in Fig. 1.2. The fixed point’s coordinates are easy to be determined from the equations

0 — ci — aiVx + a2^x2, 0 — —a2^x2

(1.7)

       We therefore get x⁰₂ — 0 and x⁰ᵢ — (ci/ai)² or, taking into account (1.6), we have x⁰ᵢ — (cᵢ/kᵢ)²(xᵢ?)⁻ⁱ. Let us compare the mode, where the piecewise linear approximation of the bile outcome with x⁰ᵢ — cᵢ /kᵢ is used, with the mode where the mentioned parabolic approximation is used. By substituting the parameters with their values, we find that


0
i—



x

(1.8)



      The increased amount of the bile in the bile duct loads the biliary system to a greater extent. The analysis shows that the mode with the parabolic law of the bile outflow is less critical, because there is less bile left in the bile duct in the steady state than that in the mode with the piecewise linear approximation.                                                      □


Example 1.2   Clockwork
     A model of a clock with different types of the instantaneous impact of the escapement can be represented as



d2x
d2 + x—

+f0.dx < o. dt

fo-dx > o, dt

—

(1.9)

CHAPTER 1. EVENT-CONTINUOUS SYSTEMS

Figure 1.2: Phase portrait with a stable node

     where f₀ is the constant friction per unit mass. The impact follows either the assumption that the momentum is conserved v₁ - v₀ = const or the

     assumption that after the impact the kinetic energy of the system changes


by the same value

22
mv₁² mv₀²
_  2 const,


(1.10)

      where v1 and v0 are the speeds before and after the impact.
      The authors of the considered example have analytically studied models with switching discrete-continuous system modes and have established the possibility of the existence of self-oscillations in the system.       □


Example 1.3   Autopilot
     The next example is a model of an autopilot with a contactor servomechanism which is described by the equations


ddt2 = M _h ' + q, a = p + a, 'ф(а) = sign(a),


(1.11)

      where q, M, h and a are constants. This system with the so-called multi step control is a hybrid system with two local behaviors: c₁, if g(a) = a < 0, and c₂ if g(a) = a > 0. By varying the parameter a, the autopilot control

1.1. DISCRETE-CONTINUOUS MODELS

13

      can be improved. As the phase portrait shows (Fig. 1.3, a), increasing a leads to a transient process ending quicker than in the case of no derivative control when a = 0. However, the further increase of a causes the behavior to become Zeno (Fig. 1.3, b).


Figure 1.3: Improvement of the autopilot control by increasing the a coefficient

     This effect can be avoided by replacing the discontinuous function ^(a) = sign(a) with the smooth function

X(a) = 2arctg(KCT • a)/n.                (1.12)


     The HS behavior therefore degenerates into the behavior of an ordinary dynamical system:

^ = x, X = -Mx — 2arctg(Kₐ • a)/n, a = y + ax. (1.13)

     The simulation results are shown in Fig. 1.4.
     The results of the research show that using the function X(a) = sign(a) causes Zeno behavior, whereas using the function X(a) = 2arctg(Kₐ • a)/n