ctl - colorado state universityfrance/cs614/slides/ctl-b.pdfoverview review ctl model checking ctl...

40
CTL Chapter 6 – Part 2

Upload: others

Post on 21-Jan-2021

7 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

CTL

Chapter 6 – Part 2

Page 2: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Overview● Review CTL Model Checking● CTL model Checking algorithms for

● ∃(ɸ U )

● ∃□ɸ● Counter Examples and witnesses

● Symbolic Model Checking (Thursday)

● Binary Decision Trees● Encoding Transition Systems by Switching functions● Symbolic Computation● Ordered Binary Decision Diagrams

Page 3: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 4: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Example parse tree for CTL

Page 5: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 6: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 7: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

∃◊((p=r)(p q)) = ∃(true U ((p=r) (p q)) )

Trace Algorithm on Whiteboard...

Page 8: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 9: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 10: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Compute ∃□q

Trace Algorithm on Whiteboard...

Page 11: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 12: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 13: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Counter Examples and Witnesses

● Counter Examples● Indicate the refutation of universally quantified path

formulae

● Witness● Indicate the satisfaction of existentially quantified

path formulae

Page 14: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 15: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 16: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 17: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 18: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 19: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 20: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 21: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 22: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 23: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 24: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 25: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic
Page 26: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Symbolic Model Checking

Page 27: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Symbolic Model Checking

Page 28: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Symbolic Model Checking

Page 29: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Symbolic Model Checking

●Encoding states and Transitions

Page 30: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Symbolic Model Checking, ∃(ɸ U )

●Algorithm

●Correction

●Main operation in loop

Page 31: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Symbolic Model Checking, ∃(ɸ U )

∃◊((a=c)(a b)) = ∃(true U ((a=c) (a b)) )

Trace Algorithm with BDDs on Whiteboard...

We need:

●Sat(a),

●Sat(b),

●Sat(c),

●Transitions (s,s')

Page 32: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Symbolic Model Checking, ∃□ɸ

●Algorithm

●Correction

●Main operation in loop

Page 33: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Symbolic Model Checking, ∃□ɸ

∃□ɸ

Trace Algorithm with BDDs on Whiteboard...

We need:

●Sat(b),

●Transitions (s,s')

Page 34: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Symbolic Model Checking - ∃□q

Page 35: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

BDT Cons...

● May not have a data structure which is efficient for all computations

● Data structures which yield compact representations for many computations that appear in practical applications

● OBDDs - data structure that has been proven to be very successful for model checking purposes

● particularly in the area of hardware verification

● Besides yielding compact representation for many “realistic” transition systems, they enjoy the property that the Boolean connectives can be realized in time linear in the size of the input OBDDs

● with appropriate implementation techniques, equivalence checking can even be performed in constant time.

Page 36: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

BDT to OBDD ● yield a data structure for computations that relies on a

compactification of binary decision trees.

● skip redundant fragments of a binary decision tree.

● This means collapsing constant subtrees (i.e., subtrees where all terminal nodes have the same value) into a single node

● identifying nodes with isomorphic subtrees

● we obtain a directed acyclic graph of outdegree 2

– the inner nodes are labeled by variables and their outgoing edges stand for the possible evaluations of the corresponding variable.

– The terminal nodes are labeled by the function value.

Page 37: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

BDD to OBDD

●Consider BDD

●Correction: line from z3 to 0 should be a dashed line

●To ODBBs

Page 38: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

BDD to OBDD

Page 39: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

Variable Ordering

Page 40: CTL - Colorado State Universityfrance/CS614/Slides/CTL-b.pdfOverview Review CTL Model Checking CTL model Checking algorithms for ∃(ɸ U ) ∃ ɸ Counter Examples and witnesses Symbolic

OBDD formal definition