2Today’s LectureIntroductory Lecture (01/10): Modeling of Systems and its applicationsExamples of Discrete Event, Continuous, and Hybrid SystemsTopic 1(2-3 weeks): Discrete Event Modeling of Systems (ref: S. Lafortune, et al. – Automata based models, Petri Net based models(?))
3Lecture 1: (Home Work)Additional reading material: F.E. Cellier, H. Elmqvist, and M. Otter, “Modeling from Physical Principles,” (pdf file URL:Problems:1. The height of water in a reservoir fluctuates with time. If you had to construct a dynamic system model to help water resource planners predict variations in the height, what input quantities would you consider? How many state variables would you need in your model?2. Suppose you were a heating engineer and you wished to consider your house as a dynamic system. Without a heater the average temperature of the house would clearly vary over a 24 hour period. What might you consider as state variables for a simple dynamic model? How would you expand your model to predict the temperatures in several rooms in your house? How does the installation of a thermostat controlled heater change your model?
4Systems Viewpoint to Modeling Model to study operation of complete system as opposed to operation of the individual partsMethod of model building: compositionalityMethod of analysis: isolate into partsUnified approach to modeling, rather than being domain-specificEnergy-based modeling of physical systemsDiscrete-event models of systems – change in system directly linked to the occurrence of eventsCombine modeling paradigms – Hybrid Systems approach to modeling
5Modeling of Dynamic Systems State-Determined Systems -- our goal is to start with physical component descriptions of systems understanding of component behavior to create mathematical models of the system.Mathematical model of state-determined system – defined by set of ordinary differential equations on the so-called state variables. Algebraic relations define values of other system variables to state variables.Dynamic behavior of state-determined system defined by (i) values of state variables at some initial time, and (ii) future time history of input quantities to system.In other words, our system models – satisfy the Markov property
6Uses of Dynamic ModelsAnalysis for prediction, explanation, understanding, and control. Two types: (a) analytic methods, and (ii) simulation-based methods. Given S, X at present, and U for the future, predict future X and Y.Identification. Given U and Y find S and X consistent with U and Y. (under normal and faulty conditions)Synthesis. Given U and a desired Y, find S such that S acting on U produces Y.Dynamic System, SState Variables, XOutput VariablesYInput VariablesU
9Example: Discrete-State Modeling of Systems Warehouse SystemsArriving Productsu1(t)Departing Productsu2(t)x(t)x(t) :arrival; u1(t) = 1; u2(t) = 0x(t+) = x(t) :departure; u1(t) = 0; u2(t) = 1; x(t) > 0x(t) :otherwiseQuestion: Is this similar to a tank system?What is the difference?
10What is A Hybrid System?Dynamic systems that require more than one modeling language to characterize their dynamicsProvide a mathematical framework for analyzing systems with interacting discrete and continuous dynamicsCapture the coupling between digital computations and analog physical plant and environmentContinuous Dynamics: mechanical, fluid, thermal systems, linear circuits, chemical reactionsDiscrete dynamics: collisions, switches in circuits, valves and pumps
11Hybrid Models of Physical Systems Why Hybrid Models?Proliferation of Embedded SystemsSimplify Behavior analysis of complex non linear systemsMotivation(s):Monitoring & DiagnosisDesign, Controlsignal domainD/Aenergy domaincontrolalgorithmplantactuatorssensorsphysical systemembedded controller+-TsampleA/D
12Supervisory Controller DecisionMakerEnvironmentSwitchingSignalu1Controller 1u2Controller 2uyPlant•umController m
13Example: Bouncing Ball ball position – x1 ball velocity – x2 acceleration – gcoefficient of restitution – c [0,1]x1 > 0 continuous flow governed by differential equationwhen transition condition satisfied discrete jump occursBehavior is zeno, i.e., infinite number of bounces occur in finitetime interval
14Example: ThermostatThermostat (controller) turns on radiator between 68 & 70 degrees andturns off the radiator between 80 and 82 degrees.Result: non deterministic system – for a given initial conditionthere are a whole family of different executions.
15Discrete Event Systems (Chapter 2: Cassandras and Lafortune: Languages and Automata) What is a discrete event system?State space of system discreteState transitions are only observed at discrete points in time, i.e., state transitions are associated with eventsFor multimedia overview of discrete event systems look up:Continuous time systems versus Discrete time systems
16Levels of Abstraction in a Discrete Event System
17Informal Definition of Event Specific actione.g., turn switch on/offSpontaneous occurrence dictated by nature of environmente.g., power supply goes offCertain conditions being met within systemheight of liquid in tank, h h0 flow through pipeh0
18Time-driven versus Event-Driven Systems Time-driven: Synchronous – at every clock tick event occurs which advances system behaviorEvent-driven: Asynchronous or concurrent – at various time instances not necessarily known in advance and not necessarily coinciding with clock ticks event e announces its occurrence
19Major System Classifications Time-DrivenContinuous-StateEvent-DrivenSystemsDynamicLinearTime-varyingStaticTime-invariantNonlinearDiscrete-StatestationaryDESsampledStochasticDeterministicDiscrete-TimeContinuous-Time
20State Evolution in DES Sequence of states visited Associated events cause the state transitionsFormal ways for describing DES behavior, i.e., what is a language for describing DES behavior?AutomataPetri Nets
21Languages for DES behavior Simplest: a timed language where timing information has been deleteduntimed modeling formalism defined by event sequence: e1 e2 …… enTimed Language: set of all timed sequences of events that the DES can generate/execute(e1,t1) (e2,t2) …… (en,tn)Stochastic Timed Language: a timed langauge with a probability distribution function defined over it
22Discrete Event Modeling Formalisms State-based: define a state space and specify a state-transition structure:(out_state, event, in_state) triplese.g., Automata and Petri NetsTrace-based: based on (recursive) algebraic expressionse.g., Communicating Sequential Processes (CSPs)We will study modeling, analysis, and supervisory control with untimed and timed automata
23Automaton Model for two philosophers Notion of parallel composition
24Recursive Equation Model: Two philosopher problem