semantics verification
play

Semantics & Verification Lecture 13 Gerd Behrmann Outline of - PowerPoint PPT Presentation

Semantics & Verification Lecture 13 Gerd Behrmann Outline of remaining lectures Lecture 9: Modelling real time system Lecture 10: More on Uppaal + mini projects Lecture 11: Mini projects Lecture 12: Verification of timed


  1. Semantics & Verification Lecture 13 Gerd Behrmann

  2. Outline of remaining lectures ● Lecture 9: Modelling real time system ● Lecture 10: More on Uppaal + mini projects ● Lecture 11: Mini projects ● Lecture 12: Verification of timed automata ● Lecture 13: Binary Decision Diagrams ● Lecture 14: Using BDDs for the purpose of verification ● Lecture 15: Round-up of course

  3. Reduced Ordered Binary Decision Diagrams [Bryant’86] ● Compact represetation of boolean functions allowing effective manipulation (satisfiability, validity,….) ● Compact representation of sets over finite universe allowing effective manipulations.

  4. Use of ROBDDs ● Comibatorial circuits ● Sequential circuits ● Automata ● Combinatorial problems ● Temporal logic model checking ● Program analysis ● …..

  5. Boolean Functions

  6. Truth Tables 2 n entries in table!

  7. Combinatorial Circuits Are these two circuits equivalent?

  8. Control Programs A Train Simulator, visualSTATE (VVS) 1421 machines 11102 transitions BUGS ? 2981 inputs 2667 outputs 3204 local states Declared state sp.: 10^476 “Ideal” presentation: 1 bit/state will clearly NOT work!

  9. “Good” Representations of Boolean Functions Always perfect representations are hopeless Normalforms – Disjunctive NF – Conjunctive NF THEOREM (Cook’s theorem) – If-then-else NF – ……. Satisfiability of Boolean expressions is NP-complete Compact representations are • compact and • efficient on real-life examples

  10. Binary Decision Trees Variable is set to 0 Variable is set to 1 Each path determines a partial (set of) truth assignments. Result of the boolean expression under the given assigment found in value of terminal.

  11. Binary Decision Diagrams allow NODES to be shared Equivalence ~ on nodes: n ~ m iff either both n and m are terminals and have the same value or both are non-terminals with var( n ) = var( m ) and 1. n’ ~ m’ when n - 0-> n’ , m- 0-> m’ , and 2. n’ ~ m’ when n - 1-> n’ , m- 1-> m’ Have you seen this somewhere before?

  12. Orderedness & Reducedness TESTS

  13. Orderedness & Reducedness x x x x y z x<y x<z

  14. Reduced Ordered Binary Decision Diagrams IBEN Edges to 0 implicit

  15. ROBDDs formally

  16. Ordering does matter! Variable ordering

  17. Canonicity of ROBDDs

  18. Canonicity of ROBDDs

  19. Array implementation b

  20. Makenode and Hashing

  21. BUILD Run time?

  22. Boolean operations on ROBDDs

  23. Boolean operations on ROBDDs

  24. APPLY example

  25. APPLY operation

  26. APPLY with dynamic programming

  27. Other operations

  28. Mia’s skema Mon Tue Wed Thu Fri Sat Sun 8-9 mat eng dan tys eng 9-10 mat tys dan geo tys 10-11 eng dan tys dan tys 11-12 dan dan bio mat gym 12-13 gym fys fys fys gym gym 13-14 bio geo 14-15 bio

  29. ROBDD encoding of transition system Encoding of states using binary 00 01 variables (here x1 and x2 ). Encoding of transition relation using source and target variables 10 11 (here x1, x2, y1 , and y2 ) Trans(x1,x2,y1,y2):= !x1 & !x2 & !y1 & y2 + !x1 & !x2 & y1 & y2 + x1 & !x2 & !y1 & y2 + x1 & !x2 & y1 & y2 + x1 & x2 & y1 & !y2;

  30. ROBDD representation (cont.) 00 01 10 11 Trans(x1,x2,y1,y2):= !x1 & !x2 & !y1 & y2 + !x1 & !x2 & y1 & y2 + x1 & !x2 & !y1 & y2 + x1 & !x2 & y1 & y2 + x1 & x2 & y1 & !y2;

  31. Reachable States Relational Product: May be constructed Reach( x ) := Init( x ); without building REPEAT intermediate (often large) Old( x ) := Reach( x ); &-BDD. New( y ) := Exists x. (Reach( x ) & Trans( x , y )); Reach( x ) := Old( x ) + New( x ) UNTIL Old( x ) = Reach( x ) Reach 0 Reach 1 Reach 2 00 01 10 11 Reach 1

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend