A Worked MRTPN Example (or: The Pholly of Physicists…) (June 2005)

Slides:



Advertisements
Similar presentations
Bison Management Suppose you take over the management of a certain Bison population. The population dynamics are similar to those of the population we.
Advertisements

Bit-State Space Exploration It’s a variation on reachability analysis The reachability analysis: –Keeps track of the already explored states –Performs.
Chapter 7: Matrix Algebra 1.(7.1) Matrix Arithmetic a)Matrix-Vector Multiplication b)Matrix-Matrix Multiplication 2.(7.2) Applications 1.(7.1) Matrix Arithmetic.
AS Bioscope TM Multiple sampling of your bacteria using an innovative portable respirometer. Bioscope is a portable real-time respirometer that provides.
Unit 8 - Lesson 1 Angles in Triangles
Advanced Pipelining Optimally Scheduling Code Optimally Programming Code Scheduling for Superscalars (6.9) Exceptions (5.6, 6.8)
PROTOCOL VERIFICATION & PROTOCOL VALIDATION. Protocol Verification Communication Protocols should be checked for correctness, robustness and performance,
Intro to Computer Org. Pipelining, Part 2 – Data hazards + Stalls.
Computer Organization and Architecture
Chapter 12 CPU Structure and Function. CPU Sequence Fetch instructions Interpret instructions Fetch data Process data Write data.
Section 2.3 Gauss-Jordan Method for General Systems of Equations
Approximation Algorithms: Combinatorial Approaches Lecture 13: March 2.
Concurrent & Distributed Systems Lecture 5: Semaphores and Synchronisation Concurrent processes which don’t interact in some way don’t form an interesting.
1 Lecture 7: Out-of-Order Processors Today: out-of-order pipeline, memory disambiguation, basic branch prediction (Sections 3.4, 3.5, 3.7)
CS 536 Spring Global Optimizations Lecture 23.
A.Chekhtman1 GLAST LAT ProjectInstrument Analysis meeting, June, 24, 2005 CAL retriggering study with SLAC data. Alexandre Chekhtman NRL/GMU Gamma-ray.
Prof. Fateman CS 164 Lecture 221 Global Optimization Lecture 22.
Virtual Memory and Paging J. Nelson Amaral. Large Data Sets Size of address space: – 32-bit machines: 2 32 = 4 GB – 64-bit machines: 2 64 = a huge number.
Copyright © Cengage Learning. All rights reserved.
Prof. Bodik CS 164 Lecture 16, Fall Global Optimization Lecture 16.
Please open your laptops, log in to the MyMathLab course web site, and open Quiz 3.1 IMPORTANT NOTE: If you have time left on your quiz clock after you.
Binary Arithmetic Math For Computers.
CH12 CPU Structure and Function
8/24/2015 V. J. Motto 1 Chapter 2: Review – Quadratic Function V. J. Motto M110 Modeling with Elementary Functions.
Virtual Memory.
1 Timing System Timing System Applications. 2 Timing System components Counting mechanisms Input capture mechanisms Output capture mechanisms.
1 HEAPS & PRIORITY QUEUES Array and Tree implementations.
Analysis CS 367 – Introduction to Data Structures.
Algorithm Analysis. Algorithm An algorithm is a clearly specified set of instructions which, when followed, solves a problem. recipes directions for putting.
Dynamic Range And Granularity. Dynamic range is important. It is defined as the difference between light and dark areas of an image. All digital images.
41: Trig Equations © Christine Crisp “Teach A Level Maths” Vol. 1: AS Core Modules.
Theorems About Roots of Polynomial Equations
® IBM Software Group © 2006 IBM Corporation JSF Progress Bar This Learning Module shows how to integrate EGL/JSF functionality into a run-time progress.
Graph Colouring L09: Oct 10. This Lecture Graph coloring is another important problem in graph theory. It also has many applications, including the famous.
Possible Improvements For Modular Relative Time Petri Nets (or: rooting for the underdog)
1 Chapter 9. To familiarize you with  Simple PERFORM  How PERFORM statements are used for iteration  Options available with PERFORM 2.
Start Up Day 25 Factor each Polynomial:
Algorithm Analysis Chapter 5. Algorithm An algorithm is a clearly specified set of instructions which, when followed, solves a problem. –recipes –directions.
Describing Distributions with Numbers Chapter 2. What we will do We are continuing our exploration of data. In the last chapter we graphically depicted.
Date: 2.4 Real Zeros of Polynomial Functions
1 Project designed and created by M. Shajith Kumar.
IT3002 Computer Architecture
Single Pick Probability AND vs. OR Sequential Probability With Replacement Conditional Disjoint vs. Non Disjoint Unit 4 – Probability – Part 1.
1 What happens to the location estimator if we minimize with a power other that 2? Robert J. Blodgett Statistic Seminar - March 13, 2008.
Warm Up for Lesson 3.6 Identify the vertex of each parabola: (1). y = -(x + 3) 2 – 5 (2). y = 2x (3). y = 3(x – 1) (4). y = -5(x + 4) 2 (5).
Bringing Together Paradox, Counting, and Computation To Make Randomness! CS Lecture 21 
Visual Basic A Quick Tutorial VB Review for ACS 367.
Lecture 4 Page 1 CS 111 Online Modularity and Memory Clearly, programs must have access to memory We need abstractions that give them the required access.
Copyright © 2013, 2009, 2005 Pearson Education, Inc. 1 3 Polynomial and Rational Functions Copyright © 2013, 2009, 2005 Pearson Education, Inc.
POLYNOMIALS By Zach Ray. ADDING AND SUBTRACTING POLYNOMIALS Step 1 Arrange the Polynomial in standard form Standard form of a polynomial just means that.
Copyright © Cengage Learning. All rights reserved. Graphs; Equations of Lines; Functions; Variation 3.
TEN MONEY SAVING TIPS FOR TEENAGERS BY PHILLIP QUINTANA.
Sec Preparing for New Fiscal Years.  In order to meet the financial reporting demands of each new financial year, certain ledger accounts in any.
Lecture 5 Page 1 CS 111 Summer 2013 Bounded Buffers A higher level abstraction than shared domains or simple messages But not quite as high level as RPC.
Theory of Computational Complexity Yusuke FURUKAWA Iwama Ito lab M1.
Convert from degree measure to radians: 1. 54° ° Convert from radian measure to degree measure: 3. 16π/ π/5.
Trees.
Please CLOSE YOUR LAPTOPS, and turn off and put away your cell phones, and get out your note- taking materials.
3.3 Dividing Polynomials.
CLOSE Please YOUR LAPTOPS, and get out your note-taking materials.
Exploring the Backblaze Hard Drive Data Big, Missing, Problematic Data
Modularity and Memory Clearly, programs must have access to memory
Multi-Way Search Trees
Warm-Up March 10th Find the perimeter and area of the rectangle below.
Iteration: Beyond the Basic PERFORM
CS 704 Advanced Computer Architecture
Warm-up: Determine whether the graph of y is a function of x:
Warm Up Find the perimeter and area of the rectangle below. 4x - 3
“Teach A Level Maths” Vol. 1: AS Core Modules
Maximum Flow Problems in 2005.
Presentation transcript:

A Worked MRTPN Example (or: The Pholly of Physicists…) (June 2005)

The Problem Brand new sensor measures inspirons. But, the PC-card only has one register! If we miss 3 readings in a row the results will be useless!  Samples are timed, so double-reading is ok.

The Solution Model the system with ‘outer bounds’ values. Check for triple miss. Three components: –sensor –single register –software monitor sensor monitor register write read

Sensor Takes a few moments to warm up if it’s cold. Takes a few moments to take a measurement. Then transfers the reading to the PC card off ready analysing activate writesample [1,3] [2,4][0,1]

Register Very simple, powers up quickly. Very rapid read & writes. off ready activate readwrite 1 [0,1]

Monitor Software to accumulate the results in a file. Reading and writing take a few moments for the O/S calls to execute. off ready buffering activate storeread [2,4] [1,2] [2,3]

Modular Algorithm Initial state = {(s0 γ, 0)} Aγ For each state M: –find the locally reachable states, M’ lreach(M, δ ) = { (M’, λ ) } <= (future state, leftover delay) –find global events that can then be fired, tf (M →* M’) Λ (M’ [ λ, tf > M’’) => M’’ is a new state! –continue until time is exhausted for M lather, rinse, repeat!

Let’s go… Initial state: {(s0,0),(r0,0),(m0,0)} Need to calculate the lreach sets for those… For convenience: –local pairs (s,d) –global pairs [s,d] –omega pair [[s,d]] (s0,0), (r0,0), (m0,0) ???

lreach(s0) 0 => (s0,0), (s1,0), (s2,0), (s3,0) 1 => (s1,1), (s2,1), (s3,1), (s4,0), (s5,0), (s6,0) 2 => (s2,2), (s3,2), (s4,1), (s5,1), (s6,1), (s4,0), (s5,0), (s6,0) 3 => (s3,3), [s4,2], (s5,2), (s6,2), (s4,1), (s5,1), (s6,1), (s4,0), (s5,0), (s4,0) 4=> [[s4,3]], [s5,3], (s6,3), [s4,2], (s5,2), (s6,2), (s4,1), (s5,1), (s6,1) s1 s0 s2s3 0,act sample ,write3,write4,write5,write 3,write4,write s4 s5 s6

lreach(s0) – cont’d 4=> [[s4,3]], [s5,3], (s6,3), [s4,2], (s5,2), (s6,2), (s4,1), (s5,1), (s6,1) 5 => [[s4,3]], [[s5,4]], [s6,4],[s5,3], (s6,3), [s4,2], (s5,2), (s6,2) 6 => [[s4,3]], [[s5,4]], [[s6,5]], [s6,4], [s5,3], (s6,3) 7 => [[s4,3]], [[s5,4]], [[s6,5]], [s6,4] 8 => [[s4,3]], [[s5,4]], [[s6,5]] Saturated! Hence Ω(s0) = 8 s1 s0 s2s3 0,act sample ,write3,write4,write5,write 3,write4,write s4 s5 s6

lreach(m0) 0 => (m0,0), (m1,0), (m2,0), (m3,0) 1 => (m1,1), (m2,1), (m3,1) 2 => (m1,2), (m2,2), (m3,2) 3 => [m1,3], (m2,3), (m3,3) 4 => [[m1,4]], [m2,4], (m3,4) 5 => [[m1,4]], [[m2,5]], [m3,5] 6 => [[m1,4]], [[m2,5]], [[m3,6]] Saturated! Hence Ω(m0) = 6 m1 m0 m2 m3 0,act 3,read4,read5,read6,read 4,read5,read

lreach(r0) 0 => (r0,0), (r1,0) 1 => [r1,1] 2 => [[r1,2]] Saturated! Hence Ω(r0) = 2 r0 r1 0,act 2,read 1,read 1,write 2,write

Back to the big picture Next set of states found by taking pair- wise matches from the modules lreach sets. Notice there is no (7,write) or (8,write)? –(6, read) is a globally certain event –stragglers will have to wait for the next state (s0,0), (r0,0), (m0,0) (s7,0), (r2,0), (m0,3) (s7,0), (r2,0), (m0,4) (s7,0), (r2,0), (m0,5) (s7,0), (r2,0), (m0,6) (s0,3), (r2,0), (m4,0) (s0,4), (r2,0), (m4,0) (s0,5), (r2,0), (m4,0) (s0,6), (r2,0), (m4,0) 4,write 3,write 5,write 6,write 3,read 4,read 5,read 6,read sg0 sg1 sg2 sg3 sg4 sg8 sg7 sg6 sg5

New States – s7 New state found. lreach(s7): 0 => (s7,0), (s4,0), (s5,0), (s6,0) 1 => (s4,1), (s5,1), (s6,1) 2 => [s4,2], (s5,2), (s6,2) 3 => [[s4,3]], [s5,3], (s6,3) 4 => [[s4,3]], [[s5,4]], [s6,4] 5 => [[s4,3]], [[s5,4]], [[s6,5]] Saturated! Hence Ω(s7) = 5 2,write 3,write 4,write 5,write 3,write4,write s4 s5 s6 0,sample s7

New States – m4 New state found. lreach(m4): 0 => (m4,0) 1 => (m4,1) 2 => (m4,2), (m5,0) 3 => (m4,3), [m5,1], (m5,0) 4 => [[m5,2]], [m5,1] 5 => [[m5,2]] Saturated! Hence Ω(m4) = 5 m1 m2 m3 4,read 5,read 4,read5,read 3,read 6,read 2,read1,read 3,store2,store m4 m5

New States – r2 New state found. lreach(r2): 0 => [r2,0] 1 => [[r2,1]] Saturated! Hence Ω(r2) = 1 r1 2,read 1,read1,write 2,write r2 1,read 0,read 0,write 1,write

Back to the big picture – cont’d The local state spaces are all saturated, so now we just need to keep exploring… (s0,3), (r2,0), (m4,0) (s7,0), (r2,0), (m4,0) (s7,0), (r2,0), (m4,1) (s7,0), (r2,0), (m4,2) (s7,0), (r2,0), (m4,3) (s0,6), (r2,0), (m4,0) (s0,7), (r2,0), (m4,0) (s7,0), (r2,0), (m4,4) 1,write 0,write 2,write 3,write 3,read 4,read 4,write sg1 sg4 sg9 sg15 sg14 sg13 sg12 sg11 (s0,8), (r2,0), (m4,0) 5,read sg10 (s7,0), (r2,0), (m4,5) 5,write sg16

Back to the big picture – cont’d The exploration continues… (s7,0), (r2,0), (m0,3) (s7,0), (r2,0), (m0,5) (s7,0), (r2,0), (m0,6) (s7,0), (r2,0), (m4,0) (s7,1), (r2,0), (m4,0) (s7,2), (r2,0), (m4,0) (s7,3), (r2,0), (m4,0) 3,write 2,write 0,read 1,read 2,read 3,read sg7 sg8 sg5 sg11 sg17 sg18 sg19

Back to the big picture – cont’d And a bit more… (s7,0), (r2,0), (m4,0) (s7,0), (r2,0), (m4,2) (s7,0), (r2,0), (m4,3) (s7,0), (r2,0), (m4,4) (s7,0), (r2,0), (m4,5) (s7,3), (r2,0), (m4,0) (s7,4), (r2,0), (m4,0) (s7,5), (r2,0), (m4,0) 3,write 2,write 4,write 5,write 3,read 4,read 5,read sg11 sg13 sg15 sg14 sg16 sg19 sg20 sg21

Back to the big picture – cont’d And some congruent activity… (s7,2), (r2,0), (m4,0) (s7,0), (r2,0), (m4,0) (s7,0), (r2,0), (m4,1) (s7,0), (r2,0), (m4,2) (s7,0), (r2,0), (m4,3) (s7,5), (r2,0), (m4,0) 1,write 0,write 2,write 3,write 3,read sg18 sg11 sg13 sg12 sg14 sg21

Ω Limits We will only find events in these ranges: –write Є (s0, [3,8]) U (s7, [2,5]) –read Є (m0, [3,6]) U (m4, [3,5]) –both of these dominate the register ranges. In practise a ‘real’ tool would probably throw out most of the lreach data once the event ranges for each entry state have been calculated.

Guestimating |SG|… From the previous ranges we know that s7 and m4 can only go up to 5s before they will definitely ‘go off’. –so there are less than ~12 ‘core’ states because at least two modules will always be 0 –plus we need to clear the initialisation delays out at the start, less than ~14 states –Should be less than ~26 states in the synch graph, which is well below 7 x 6 x 3.

Guestimating |SG|… - cont’d

And the triple-write property? Can happen for really bad cases: –[…, sg21, (0,write), sg11, (2,write), sg13, (2,write), sg15, …] This is because the read cycle is between [3,5] and the write cycle is between [2,5]. So if the sensor is having a good day, and the monitor a bad one, we can miss out. But this is not necessarily ‘obvious’ from eye- balling the model, as one’s first thought might be that since > 5 we should be safe…

What can we do? Need to bring the two interval ends closer. –get the reading cycle down to 3s; or –add a choke to the writing cycle for an extra 1s Unless both ranges are constant, we can always fire the first event for “free” (zero time), so the rate test is simply: –min(acycle) * (n – 1) > max(bcycle)

What next?