Top Banner
MODELING TIME IN COMPUTING Benjamin Gamble
33

Benjamin Gamble. What is Time? Can mean many different things to a computer Dynamic Equation Variable System State 2.

Jan 12, 2016

Download

Documents

Georgina Farmer
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

MODELING TIME IN COMPUTING

Benjamin Gamble

Page 2: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

2

What is Time?

Can mean many different things to a computer

DynamicEquationVariableSystem State

Page 3: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

3

Outline History Languages & Interpretations Dimensions of the Time Modeling Problem

Discrete vs. DenseFinite or Bounded Time ModelsLinear vs. BranchingDeterminism vs. NondeterminismTime Advancement ProblemConcurrency & Composition

Analysis & Verification Issues

Page 4: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

4

History of Time in Computing

First implemented in computer hardware

Then adapted for software and computational complexity

Parallel processing mandated a further investigation in timing issues

Modern day real time systems

Page 5: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

5

Outline History Languages & Interpretations Dimensions of the Time Modeling Problem

Discrete vs. DenseFinite or Bounded Time ModelsLinear vs. BranchingDeterminism vs. NondeterminismTime Advancement ProblemConcurrency & Composition

Analysis & Verification Issues

Page 6: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

6

Choosing the Right Language

Page 7: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

7

Two Main Classes of Languages

OperationalWell suited to describe the evolution

of a system starting at some initial state

Based on the key concept of state and transition

Modeled as evolving from a state to the next one when a certain event occurs

Page 8: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

8

Operational Example

A safeWhen the correct security code is

entered, the safe opensIf the safe remains open for 3 minutes,

it automatically closes

Page 9: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

9

Two Main Classes of Languages

DescriptiveBetter suited for describing the

properties that the system must satisfyLogic based formalismsAlgebra based formalisms

Page 10: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

10

Descriptive Example

A safeThe safe is open if and only if the

correct security code has been entered no more than 3 minutes ago

Page 11: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

11

Outline History Languages & Interpretations Dimensions of the Time Modeling Problem

Discrete vs. DenseFinite or Bounded Time ModelsLinear vs. BranchingDeterminism vs. NondeterminismTime Advancement ProblemConcurrency & Composition

Analysis & Verification Issues

Page 12: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

12

Discrete vs. Dense Time Domains Discrete time means that there is a set

of isolated points Dense time means that for every 2

points there is always a third point in between

Page 13: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

13

Continuous vs. Non-Continuous Time Models

Page 14: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

14

Continuous vs. Non-Continuous Time Models

Page 15: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

15

Finite or Bounded Time Models

Many system models assume that the behaviors may proceed indefinitely into the future and maybe even the past

This models time as an unbounded set Some system behaviors happen within a

time window This will require a bounded time model

Page 16: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

16

Bounded Time Model Example

Braking a carWe know that it requires, at most, a

few secondsTesting an anti-lock braking system

may include a time window of 0-60 seconds as a temporal domain

Page 17: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

17

Hybrid Systems

What is a hybrid system?Uses both discrete and dense time

modeling When this may be used:

Square wave formContinuous sampled at certain pointsDiscrete steps with continuous

variables

Page 18: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

18

Linear vs. Branching Time Models Linear – interpreted over linear

sequences of states

Page 19: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

19

Linear vs. Branching Time Models Branching – interpreted over trees of

states

Page 20: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

20

Determinism vs. Nondeterminism Deterministic

Whenever the future state of the system is uniquely determined by its current state and input values

Ex. A light switch○ Pressing the switch (input) while the light is in

state ‘off’ yields the unique possible state of light ‘on’

Page 21: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

21

Determinism vs. Nondeterminism Nondeterministic

Systems that can evolve to different future states from the same present state and the same input by making arbitrary ‘choices’

Ex. A resource arbiter○ Responds to 2 requests happening at the

same time by ‘choosing’ arbitrarily to whom to grant the resource first

Page 22: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

22

Implicit vs. Explicit Time Reference Explicit Time Reference

Using math such as calculus to specify system behavior and its properties

Implicit Time ReferenceRefers to a ‘current time’ and orders events

with respect to it

Page 23: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

23

Time Advancement Problem This problem arises when the model of a

timed system exhibits behaviors that do not progress past some instantEx. Pushing a button

○ Actual duration to push a button can be ignored and can be represented abstractly as a zero time event

○ If these types of events are allowed then there could possibly be an infinite number of such transitions in a zero time interval

Page 24: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

24

Solutions to the Time Advancement Problem Priori

The syntax or the semantics of the formal notation is restricted beforehand, in order to guarantee that the model of any system described with it will be exempt from time advancement problems

Page 25: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

25

Solutions to the Time Advancement Problem Posteriori

Deals with time advancement issues after the system specification has been built

It is then analyzed against a formal definition of time advancement in order to check that all of its actual behaviors do not incur into the time advancement problem

Page 26: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

26

Concurrency & Composition Composition also known as

modularization Problems arise when analyzing

synchronous subsystems A classification of dealing with the

composition of concurrent units can be spilt in two waysSynchronous vs. Asynchronous

Page 27: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

27

Synchronous vs. Asynchronous

SynchronousOccur at the same time or at instants of time

that are relatedNaturally paired with a discrete time domain

AsynchronousEach activity can progress at a speed

unrelated to othersThere is no need to know in which state

each unit is at every instant

Page 28: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

28

Outline History Languages & Interpretations Dimensions of the Time Modeling Problem

Discrete vs. DenseFinite or Bounded Time ModelsLinear vs. BranchingDeterminism vs. NondeterminismTime Advancement ProblemConcurrency & Composition

Analysis & Verification Issues

Page 29: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

29

Expressiveness

The possibility of characterizing extensive classes of properties

A language is more expressive if it can be finely tuned into a set of behaviors that satisfy certain properties

For each language there exists properties that can only be expressed by them

Page 30: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

30

Decidability & Complexity Decidability

There is a trade-off between expressiveness and decidability

Complexity is used for decidable models Used to determine the effort required by an

algorithm to decide whether a property holdsMeasured in the amount of memory or time

required as a function of the input

Page 31: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

31

Analysis & Verification Techniques Exhaustive Enumeration

AutomatedExploration of graphs

Syntactic TransformationsAddress the verification problem by logical

deductionsSpecification and requirements are in

descriptive form

Page 32: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

32

Outline History Languages & Interpretations Dimensions of the Time Modeling Problem

Discrete vs. DenseFinite or Bounded Time ModelsLinear vs. BranchingDeterminism vs. NondeterminismTime Advancement ProblemConcurrency & Composition

Analysis & Verification Issues

Page 33: Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.

33

Questions?