Second Lecture: Basics of model-checking for finite and timed systems

Size: px
Start display at page:

Download "Second Lecture: Basics of model-checking for finite and timed systems"

Transcription

1 Second Lecture: Bsics of model-checking for finite nd timed systems Jen-Frnçois Rskin Université Lire de Bruxelles Belgium Artist2 Asin Summer School - Shnghi - July 28

2 Pln of the tlk Lelled trnsition systems Properties of leled trnsition systems: Rechility - Sfety - Büchi properties Pre-Post opertors Prtil orders - Fixed points Symolic model-checking Appliction to TA: region equivlence, region utomt, zones

3 Pln of the tlk Lelled trnsition systems Properties of leled trnsition systems: Rechility - Sfety - Büchi properties Pre-Post opertors Prtil orders - Fixed points Symolic model-checking Appliction to TA: region equivlence, region utomt, zones

4 Leled trnsition systems A leled trnsition system, LTS for short, is tuple (S,S,Σ,T,C,λ) where: S is (finite or infinite) set of sttes S S is the suset of initil sttes Σ is n event or ction set (finite or infinite) C is (finite or infinite) set of colors λ : S C is leling function tht lels ech stte with color.

5 A lelled trnsition system: c d c d c c

6 Pln of the tlk Lelled trnsition systems Properties of leled trnsition systems: Rechility - Sfety - Büchi properties Pre-Post opertors Prtil orders - Fixed points Symolic model-checking Appliction to TA: region equivlence, region utomt, zones

7 Rechility Rechility verifiction prolem Instnce: LTS (S,S,Σ,T,C,λ), set Gol S. Question: is there n execution of the LTS tht strts in S nd reches Gol? More formlly, is there sequence sσs1σ1s2σ2...σn-1sn such tht (1) s S, (2) i i<n T(si,σi,si+1), nd (3) sn Gol? The set of rechle sttes of LTS (S,S,Σ,T,C,λ) is the set of sttes s S such tht there is sequence sσs1σ1s2σ2...σn-1sn nd (1) s S, (2) i i<n T(si,σi,si+1), (3) sn=s. Let Rech(S) denote the set of rechle sttes. Clerly, there is pth tht strts in S nd reches G iff Rech(S) Gol.

8 S Rechility

9 Rechility Gol S

10 Rechility Gol Rech(S) S

11 Rechility Gol Rech(S) Negtive instnce S

12 Rechility Gol Rech(S) S

13 Rechility Gol Rech(S) S Positive instnce

14 Sfety Sfety verifiction prolem Instnce: LTS (S,S,Σ,T,C,λ), set of sttes Sfe S. Question: re ll pths tht strts in S stying within Sfe. More formlly, for ll sequences sσs1σ1s2σ2...σn-1sn such tht (1) s S, (2) i i<n T(si,σi,si+1), is it the cse tht (3) i i n si Sfe? Clerly ll pths tht strt in S re stying within Sfe iff Rech(S) (S\Sfe)=. So, the sfety nd rechility prolems re dul prolems.

15 S Sfety

16 Sfety Sfe Bd S

17 Sfety Sfe Bd Rech(S) S

18 Sfety Sfe Bd Rech(S) S Positive instnce

19 Sfety Sfe Bd Rech(S) S

20 Sfety Sfe Bd Rech(S) Negtive instnce S

21 Büchi condition Büchi verifiction prolem Instnce: LTS (S,S,Σ,T,C,λ), set Gol S. Question: is there one execution of the LTS tht strts in S nd psses infinitely often y the set Gol S? More formlly, is there n execution sσs1σ1s2σ2...σn-1sn... such tht (1) s S, (2) i i T(si,σi,si+1), (3) i j i such tht sj Gol?

22 Büchi condition Gol Init

23 Pln of the tlk Lelled trnsition systems Properties of leled trnsition systems: Rechility - Sfety - Büchi properties Pre-Post opertors Prtil orders - Fixed points Symolic model-checking Appliction to TA: region equivlence, region utomt, zones

24 Post, Pre nd Apre opertors We will design verifiction lgorithms for the rechility, sfety nd Büchi properties. Our lgorithms will mnipulte sets of sttes. Besides set opertions, we will need to compute the set of sttes tht re successors (Post), or predecessors (Pre nd Apre) of set of sttes.

25 The Post : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of successors of X y σ Post(X,σ)={ y X x X T(x,σ,y) }

26 The Post : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of successors of X y σ Post(X,σ)={ y X x X T(x,σ,y) } c c c

27 The Post : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of successors of X y σ Post(X,σ)={ y X x X T(x,σ,y) } Post(X,)= c c c

28 The Post : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of successors of X y σ Post(X,σ)={ y X x X T(x,σ,y) } Post(X,)= c c c

29 The Post : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of successors of X y σ Post(X,σ)={ y X x X T(x,σ,y) } Post(X,)=Y c c c

30 The Pre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of predecessors of X y σ Pre(X,σ)={ y S x X T(y,σ,x) }

31 The Pre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of predecessors of X y σ Pre(X,σ)={ y S x X T(y,σ,x) } c c c

32 The Pre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of predecessors of X y σ Pre(X,σ)={ y S x X T(y,σ,x) } Pre(X,)= c c c

33 The Pre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of predecessors of X y σ Pre(X,σ)={ y S x X T(y,σ,x) } Pre(X,)= c c c

34 The Pre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of predecessors of X y σ Pre(X,σ)={ y S x X T(y,σ,x) } Pre(X,)=Y c c c

35 The Apre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of sttes tht hve ll their successors y σ in X Apre(X,σ)={ x S y S T(x,σ,y) y X }

36 The Apre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of sttes tht hve ll their successors y σ in X Apre(X,σ)={ x S y S T(x,σ,y) y X } c c c

37 The Apre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of sttes tht hve ll their successors y σ in X Apre(X,σ)={ x S y S T(x,σ,y) y X } Apre(X,) c c c

38 The Apre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of sttes tht hve ll their successors y σ in X Apre(X,σ)={ x S y S T(x,σ,y) y X } Apre(X,) c c c

39 The Apre : 2 S Σ 2 S tkes (1) set of sttes X (2) n ction σ nd returns the set of sttes tht hve ll their successors y σ in X Apre(X,σ)={ x S y S T(x,σ,y) y X } Apre(X,)=Y c c c

40 PRE-POST-APRE From the Pre : 2 S Σ 2 S, the Post : 2 S Σ 2 S, nd the Apre : 2 S Σ 2 S, we cn define their generliztions over the entire lphet of ctions: The POST : 2 S 2 S tkes set of sttes X nd returns the set of sttes Y tht re rechle in one step from X, i.e. : POST(X)={ y S x X σ Σ T(x,σ,y) } The PRE : 2 S 2 S tkes set of sttes X nd returns the set of sttes Y tht cn rech X in one step, i.e. : PRE(X)={ y S x X σ Σ T(y,σ,x) } The APRE: 2 S 2 S tkes set of sttes X nd returns the set of sttes Y tht hve ll their one step successors in X, i.e. : APRE(X)={ y S x S σ Σ T(y,σ,x) x X } Exercise : proof tht APRE(X)=S\PRE(S\X).

41 POST(X)= c c c

42 POST(X)= c c c

43 POST(X)=Y c c c

44 PRE(X)= c c c

45 PRE(X)= c c c

46 PRE(X)=Y c c c

47 APRE(X)= c c c

48 APRE(X)= c c c

49 APRE(X)=Y c c c

50 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes? c d c d c c

51 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes?... By iterting the POST opertor! c d c d c c

52 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes?... By iterting the POST opertor! step c d c d c c

53 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes?... By iterting the POST opertor! or1 step c d c d c c

54 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes?... By iterting the POST opertor!,1, 2 steps c d c d c c

55 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes?... By iterting the POST opertor!,1, 2, 3 steps c d c d c c

56 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes?... By iterting the POST opertor!,1, 2, 3, 4 steps c d c d c c

57 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes?... By iterting the POST opertor!,1, 2, 3, 4, 5 steps c d c d c c

58 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes?... By iterting the POST opertor!,1, 2, 3, 4, 5, 6 steps c d c d c c

59 How cn we use the POST opertor to solve the following rechility question: Cn we rech the lue sttes from initil sttes?... By iterting the POST opertor!,1, 2, 3, 4, 5, 6, steps - we hve reched fixed point c d c d c c

60 Pln of the tlk Lelled trnsition systems Properties of leled trnsition systems: Rechility - Sfety - Büchi properties Pre-Post opertors Prtil orders - Fixed points Symolic model-checking Appliction to TA: region equivlence, region utomt, zones

61 Prtil orders Let S e set. A prtil order over S is reltion S S such tht the following properties hold: (i) reflexivity: s S: s s, (ii) trnsitivity: s1,s2,s3 S: s1 s2 s2 s3 s1 s3, (iii) ntisymmetry: s1,s2 S: s1 s2 s2 s1 s1=s2. A pir (S, ) such tht is prtil order over S is clled prtilly ordered set. Let T e set, we note P(T) for the set of susets of T. Exmple: if T={t1,t2,t3} then P(T)={{},{t1},{t2},{t3},{t1,t2},{t2,t3},{t1,t3},{t1,t2,t3}}. Clerly, for ny set T, (P(T), ) is prtilly ordered set.

62 Grphicl representtion of P(T) (P(T), ) is prtilly ordered set: is reflexive: {} {}, {t1} {t1},..., {t1,t2} {t1,t2},... is trnsitive: {t1} {t1,t2} {t1,t2} {t1,t2,t3} {t1} {t1,t2,t3} nd clerly, is ntisymmetric.

63 Lower nd upper ounds Let (S, ) e prtilly ordered set. Let s S nd S S, s is lower-ound of S iff s S s s. s is upper-ound of S iff s S s s. Let s e lower-ound for S, we sy tht s is the gretest loweround (gl) for S iff for ll lower-ound s for S, we hve s s. We note gl(s ) the gl of S it it exists. Let s e upper-ound for S, we sy tht s is the lest upper-ound (lu) for S iff for ll upper-ound s for S, we hve s s. We note lu(s ) the lu of S it it exists.

64 r1= r2= R= r3= r1 nd r2 re upper ounds of R. r2 is the lest upper ound of R. r3 is the only lower-ound of R nd so it is the gretest lower ound of R.

65 R= The lu of set of sets Ri is equl to i Ri ex: lu R = {t1,t2,t3} The gl of set of sets Ri is equl to i Ri ex: gl R = {t3}

66 A set of elements S S is chin iff s,s S s s s s i.e. ll pirs of elements re ordered y (incresing sequence of elements). R={{},{t1},{t1,t2}} is chin in P(T). R ={{},{t1,t3}} is chin in P(T). R = {{},{t1,t3},{t2,t3}} is not chin in P(T).

67 A prtilly ordered set (S, ) is complete prtil order if every chin in S hs lu in S. A complete prtil order (S, ) is complete lttice if every suset S of S hs lu in (S, ). Note tht gl S = lu{s S s S: s s }, so every suset S in complete lttice hs lso gl. Exmple: (P(T), ) is complete lttice. Indeed, rememer tht the lu of set of sets Ri is equl to i Ri nd the gl of set of sets Ri is equl to i Ri.

68 The mximl element of P(T), i.e. the lest upper-ound of P(T), noted Mx(P(T)). The miniml element of P(T), i.e. the gretest lower-ound of P(T), noted Min(P(T)). Min nd Mx elements in complete lttice

69 Let (S, ) e prtilly ordered set. A function f:s S is monotone (order preserving) iff s,s S s s f(s) f(s ). Let (S, ) e complete prtilly ordered set. A function f:s S is continuous iff f is monotone nd for ll non-empty chin S in S: f(lu(s ))=lu(f(s )). Remrk. In ny finite complete prtilly ordered set S, if f is monotone then f is continuous. s S is fixed point of f:s S if f(s)=s. The set of fixed points of f is noted Fx(f). Theorem (Trski) Any monotone function on complete lttice hs : (i) lest fixed point, lfp(f), equl to gl(fx(f)) (ii) gretest fixed point, gfp(f), equl to lu(fx(f))

70 Let us consider f s depicted y red rrows Clerly, f is monotone (nd so continuous). Fx(f)={{t1,t3},{t1,t2,t3}}. lfp(f)={t1,t3}=gl(fx(f)). gfp(f)={t1,t2,t3}=lu(fx(f)).

71 S lu(fx(f)) =gfp(f) Fx(f) gl(fx(f)) =lfp(f)

72 Let f i e defined inductively s - for i=: f =f - for ll i>: f i =f(f i-1 ). Theorem (Kleene-Trski) Let (S, ) e complete lttice, let f:s S e continuous: lfp(f)=gl { f i (Min(S)) i } nd gfp(f)=lu { f i (Mx(S)) i }. This gives us n itertive schem to compute the lfp(f) (gfp(f)) of continuous function f: iterte the function from the Min (Mx) of the set until stiliztion.

73 S Mx(S) lu(fx(f)) =gfp(f)... Fx(f)... gl(fx(f)) =lfp(f) Min(S)

74 Computtion of lfp(f) f ({})={t1,t2} f 1 ({})=f({t1,t2})={t1,t2}=lfp(f)

75 Computtion of gfp(f) R=f ({t1,t2,t3})={t1,t2,t3}=gfp(f)

76 Pln of the tlk Lelled trnsition systems Properties of leled trnsition systems: Rechility - Sfety - Büchi properties Pre-Post opertors Prtil orders - Fixed points Symolic model-checking Appliction to TA: region equivlence, region utomt, zones

77 Symolic model-checking The rechility, sfety, nd Büchi ojectives cn e solved using fixed point equtions. Solving those equtions will e done y itertion of functions uilt from the Pre, Apre or Post opertors on sets of sttes. Those lgorithms re clled symolic ecuse they mnipulte sets of sttes directly insted of mnipulting individul sttes s it is done in soclled explicit model-checking lgorithms.

78 Fixed points for rechility Let us consider n instnce of the rechility prolem given y the LTS L=(S,S,Σ,T,C,λ), nd set of sttes Gol S; Gol is rechle in the LTS iff lfp (λx. S POST(X)) Gol this is forwrd lgorithm iff lfp (λx. Gol PRE(X)) S this is ckwrd lgorithm

79 Rechility - Forwrd lgorithm lfp (λx. S POST(X)) Gol c d c d c c

80 Itertive evlution of lfp (λx. S POST(X)) c d c d c c

81 Itertive evlution of lfp (λx. S POST(X)) c d c d c c

82 Itertive evlution of lfp (λx. S POST(X)) c d c d c c

83 Itertive evlution of lfp (λx. S POST(X)) c d c d c c

84 Itertive evlution of lfp (λx. S POST(X)) c d c d c c

85 Itertive evlution of lfp (λx. S POST(X)) c d c d c c

86 Itertive evlution of lfp (λx. S POST(X)) c d c d c c

87 Itertive evlution of lfp (λx. S POST(X)) Fixed point! c d c d c c

88 Itertive evlution of lfp (λx. S POST(X)) Fixed point! It intersects Gol! Positive instnce. c d c d c c

89 Rechility - Bckwrd lgorithm lfp (λx. Gol PRE(X)) S c d c d c c

90 Itertive evlution of lfp (λx. Gol PRE(X)) S c d c d c c

91 Itertive evlution of lfp (λx. Gol PRE(X)) S c d c d c c

92 Itertive evlution of lfp (λx. Gol PRE(X)) S c d c d c c

93 Itertive evlution of lfp (λx. Gol PRE(X)) S c d c d c c

94 Itertive evlution of lfp (λx. Gol PRE(X)) S c d c d c c

95 c d c d c c

96 Itertive evlution of lfp (λx. Gol PRE(X)) S c d c d c c

97 Itertive evlution of lfp (λx. Gol PRE(X)) S Fixed point! It intersects S! Positive instnce. c d c d c c

98 Sfety - Bckwrd lgorithm S gfp (λx. Sfe APRE(X)) c d c d c c

99 Itertive evlution of gfp (λx. Sfe APRE(X)) c d c d c c

100 Itertive evlution of gfp (λx. Sfe APRE(X)) c d c d c c

101 Itertive evlution of gfp (λx. Sfe APRE(X)) c d c d c c

102 Itertive evlution of gfp (λx. Sfe APRE(X)) Fixed point! Negtive instnce s S gfp (λx. Sfe APRE(X)). c d c d c c

103 Fixed points for Büchi ojectives Let consider n instnce of the Büchi verifiction prolem given y the LTS L=(S,S,Σ,T,C,λ), set of sttes Gol S; Gol is rechle infinitely often from n initil sttes in L iff gfp(λy. lfp(λx. PRE(X) ( Gol PRE(Y)))) S this is ckwrd lgorithm

104 Fixed points for Büchi ojectives

105 Fixed points for Büchi ojectives 1 2 We wnt to check if {3} cn e reched infinitely often from the initil stte

106 Fixed points for Büchi ojectives 1 2 We wnt to check if {3} cn e reched infinitely often from the initil stte. For tht we evlute the fixed point expression gfp(λy. lfp(λx. PRE(X) ( Gol PRE(Y)))) 4 3 5

107 Fixed points for Büchi ojectives 1 2 We wnt to check if {3} cn e reched infinitely often from the initil stte. For tht we evlute the fixed point expression gfp(λy. lfp(λx. PRE(X) ( Gol PRE(Y)))) 4 3 Y={1,2,3,4,5} 5

108 Fixed points for Büchi ojectives 1 2 We wnt to check if {3} cn e reched infinitely often from the initil stte. For tht we evlute the fixed point expression gfp(λy. lfp(λx. PRE(X) ( Gol PRE(Y)))) 4 3 Y={1,2,3,4,5} lfp(λx. PRE(X) ( Gol PRE(Y))) = lfp(λx. PRE(X) ( Gol )) ={1,2,3}=Y1 5

109 Fixed points for Büchi ojectives 1 2 We wnt to check if {3} cn e reched infinitely often from the initil stte. For tht we evlute the fixed point expression gfp(λy. lfp(λx. PRE(X) ( Gol PRE(Y)))) 4 3 Y={1,2,3,4,5} lfp(λx. PRE(X) ( Gol PRE(Y))) = lfp(λx. PRE(X) ( Gol )) ={1,2,3}=Y1 5 Y1={1,2,3}

110 Fixed points for Büchi ojectives 1 2 We wnt to check if {3} cn e reched infinitely often from the initil stte. For tht we evlute the fixed point expression gfp(λy. lfp(λx. PRE(X) ( Gol PRE(Y)))) 4 3 Y={1,2,3,4,5} lfp(λx. PRE(X) ( Gol PRE(Y))) = lfp(λx. PRE(X) ( Gol )) ={1,2,3}=Y1 5 Y1={1,2,3} lfp(λx. PRE(X) ( Gol PRE(Y1))) = lfp(λx. PRE(X) ( Gol {1,2,3} )) ={1,2,3}=Y2=Y1

111 Fixed points for Büchi ojectives 1 2 We wnt to check if {3} cn e reched infinitely often from the initil stte. For tht we evlute the fixed point expression gfp(λy. lfp(λx. PRE(X) ( Gol PRE(Y)))) 4 3 Y={1,2,3,4,5} lfp(λx. PRE(X) ( Gol PRE(Y))) = lfp(λx. PRE(X) ( Gol )) ={1,2,3}=Y1 5 Y1={1,2,3} lfp(λx. PRE(X) ( Gol PRE(Y1))) = lfp(λx. PRE(X) ( Gol {1,2,3} )) ={1,2,3}=Y2=Y1 Fixed point!

112 Fixed points for Büchi ojectives 1 2 We wnt to check if {3} cn e reched infinitely often from the initil stte. For tht we evlute the fixed point expression gfp(λy. lfp(λx. PRE(X) ( Gol PRE(Y)))) 4 3 Y={1,2,3,4,5} lfp(λx. PRE(X) ( Gol PRE(Y))) = lfp(λx. PRE(X) ( Gol )) ={1,2,3}=Y1 5 Y1={1,2,3} lfp(λx. PRE(X) ( Gol PRE(Y1))) = lfp(λx. PRE(X) ( Gol {1,2,3} )) ={1,2,3}=Y2=Y1 Fixed point! As S Y2, the Büchi property is verified y the LTS L

113 Trce pre-orders, Trce equivlence, Simultions, Bisimultions nd quotients

114 Trces of LTS Let (S,S,Σ,T,C,λ) e LTS. Let sσs1σ1s2σ2...σn-1sn... e such tht (1) s S, (2) i i T(si,σi,si+1), the sequence λ(s)σ λ(s1)σ1λ(s2)σ2...σn-1λ(sn)... is clled trce of the LTS. Note tht two different pths in the LTS my generte the sme trce. The color of stte is ment to model the importnt properties of tht stte. So the notion of trce llows us to concentrte on the importnt properties of the system.

115 Trces of LTS We note Trces(L) the set of trces generted y the LTS L. Two LTS L1 nd L2 re trce equivlent if Trces(L1)=Trces(L2) Trce equivlence nd verifiction. If we hve two LTS L1 nd L2 such tht Trces(L1)=Trces(L2), nd L2 is (much) smller thn L1, it my e very dvntgeous to do verifiction on L2 insted on L1. As we will see L1 my e infinite while L2 is finite. We will illustrte tht with TA. Unfortuntely, minimizing system using the notion of trce equivlence is costly computtionlly. We will introduce now stronger notions of equivlence thn re esier to compute.

116 Simultion reltions

117 Simultion reltions Given LTS (S,S,Σ,T,C,λ), simultion reltion is reltion R S S such tht for ll (s1,s2) R : (1) s1 S iff s2 S (2) λ(s1)=λ(s2) (3) σ Σ s3 S: T(s1,σ,s3) s4 S T(s2,σ,s4) (s3,s4) R

118 Simultion reltions Given LTS (S,S,Σ,T,C,λ), simultion reltion is reltion R S S such tht for ll (s1,s2) R : (1) s1 S iff s2 S (2) λ(s1)=λ(s2) (3) σ Σ s3 S: T(s1,σ,s3) s4 S T(s2,σ,s4) (s3,s4) R When (s1,s2) R, we sy tht s1 is simulted y s2.

119 Simultion reltions

120 Simultion reltions Who cn simulte who?

121 Simultion reltions This is simultion reltion

122 Simultion reltions Is this the lrgest one?

123 Simultion reltions Is this the lrgest one? NO.

124 Simultion reltions nd isimultions

125 Simultion reltions nd isimultions Given LTS (S,S,Σ,T,C,λ), there exists unique lrgest simultion reltion R S S;

126 Simultion reltions nd isimultions Given LTS (S,S,Σ,T,C,λ), there exists unique lrgest simultion reltion R S S; A reltion R S S is symmetric iff for ll s1,s2 such tht R(s1,s2) we hve lso R(s2,s1);

127 Simultion reltions nd isimultions Given LTS (S,S,Σ,T,C,λ), there exists unique lrgest simultion reltion R S S; A reltion R S S is symmetric iff for ll s1,s2 such tht R(s1,s2) we hve lso R(s2,s1); A simultion reltion R which is symmetric is clled isimultion.

128 Simultion reltions nd isimultions Given LTS (S,S,Σ,T,C,λ), there exists unique lrgest simultion reltion R S S; A reltion R S S is symmetric iff for ll s1,s2 such tht R(s1,s2) we hve lso R(s2,s1); A simultion reltion R which is symmetric is clled isimultion. Given isimultion reltion R nd two sttes s1,s2 such tht R(s1,s2) (note tht we hve lso R(s2,s1) y definition), we sy tht s1 nd s2 re isimilr, this is noted s1 R s2 (or s1 s2 if R is cler from the context). The reltion R is n equivlence reltion.

129 Bisimultion

130 Bisimultion This is isimultion

131 Quotient of LTS using isimultion Let L=(S,S,Σ,T,C,λ) e LTS, R S S e isimultion reltion over the stte spce of L, nd let R e the ssocited equivlence reltion. The quotient y R of L is the LTS L =(S,S,Σ,T,C,λ ): S re the equivlence clsses for R ; S re the equivlence clsses s for R such tht for ll s s, s S ; T is such tht T (s1,σ,s2) iff s1 s1, s2 s2:t(s1,σ,s2) ; λ is such tht λ (s)=λ(s) for ny s s. Theorem: Let L e LTS nd R isimultion over the stte spce of L, let L e the quotient of L y R, then Trces(L)=Trces(L ).

132 Quotient of LTS using isimultion The LTS

133 Quotient of LTS using isimultion The LTS

134 Quotient of LTS using isimultion The LTS The quotient y

135 Quotient of LTS using isimultion The LTS The quotient y

136 Quotient of LTS using isimultion The LTS The quotient y

137 Quotient of LTS using isimultion The LTS The quotient y

138 Bisimultion is not complete for trce equivlence Clerly, the two initil sttes re trce equivlent ut they re not isimilr. The LTS

139 Pln of the tlk Lelled trnsition systems Properties of leled trnsition systems: Rechility - Sfety - Büchi properties Pre-Post opertors Prtil orders - Fixed points Symolic model-checking Appliction to TA: region equivlence, region utomt, zones

140 Algorithmic verifiction of timed utomt We will show now how to pply the concepts tht we hve introduced so fr to otin lgorithms to verify properties of timed utomt; We will show how to use the pre-post opertors to uild fixed points lgorithms; We will show tht those lgorithms re terminting y showing tht they operte over finite stte time-strct isimultion quotients.

141 A timed utomton Question: Cn L3 e reched?

142 A timed utomton Question: Cn L3 e reched? This question cn e reduced to rechility verifiction prolem over the leled trnsition system of the TA.

143 Leled trnsition system of TA The LTS=(S,S,Σ,T,C,λ) of TA A=(Q,Q,Σ,P,Cl,E,L,F,Inv), is s follows: - S is the set of pirs (q,v) where q Q is loction of A nd v : Cl R such tht v Inv(q); - S={(q,<,,...,>) q Q }; - T S x (Σ R ) x S defined y two types of trnsitions: Discrete trnsitions: (q1,v1) (q2,v2) T iff there exists (q1,,φ,δ,q2) E, v1 Φ, nd v2:=v1[δ:=]. Continuous trnsitions: (q1,v1) δ(q2,v2) T iff q1=q2, δ R, v2=v1+δ, nd δ, δ δ, v1+δ Inv(q1). - C=2 P, λ((q,v))=l(q), for ny (q,v) Q. Clerly, this trnsition system hs (continuous) infinite numer of sttes. How do we hndle it?

144 Time strct-leled trnsition system The LTS=(S,S,Σ,T,C,λ) of TA A=(Q,Q,Σ,P,Cl,E,L,F,Inv), is s follows: - S is the set of pirs (q,v) where q Q is loction of A nd v : Cl R such tht v Inv(q); - S={(q,<,,...,>) q Q }; - T S x (Σ {Dely}) x S defined y two types of trnsitions: Discrete trnsitions: (q1,v1) (q2,v2) T iff there exists (q1,,φ,δ,q2) E, v1 Φ, nd v2:=v1[δ:=]. Continuous trnsitions: (q1,v1) Dely(q2,v2) T iff q1=q2, δ R, v2=v1+δ, nd δ, δ δ, v1+δ Inv(q1). - C=2 P, λ((q,v))=l(q), for ny (q,v) Q. Clerly, this trnsition system hs (continuous) infinite numer of sttes. How do we hndle it?

145 Continuous stte spce y x

146 Continuous stte spce y 3 2 Are there vlutions of clocks tht ehves in similr wy? x

147 Continuous stte spce y 3 First, let us note tht clocks re compred to constnts (tht re nturl numers) x

148 Continuous stte spce y 3 First, let us note tht clocks re compred to constnts (tht re nturl numers). Mx. vlue over which y is compred x Mx. vlue over which x is compred

149 Continuous stte spce y 3 It is importnt to know if x or y rech the next nturl numer first. Mx. vlue over which y is compred x Mx. vlue over which x is compred

150 Continuous stte spce y This prtition is fine enough 3 Mx. vlue over which y is compred x Mx. vlue over which x is compred

151 Continuous stte spce y This prtition is fine enough Mx. vlue over which y is compred ech tringle is region x Mx. vlue over which x is compred

152 Continuous stte spce y This prtition is fine enough Mx. vlue over which y is compred ech segment is region x Mx. vlue over which x is compred

153 Continuous stte spce y This prtition is fine enough Mx. vlue over which y is compred ech segment is region x Mx. vlue over which x is compred

154 Continuous stte spce y This prtition is fine enough Mx. vlue over which y is compred ech segment is region x Mx. vlue over which x is compred

155 Continuous stte spce y This prtition is fine enough Mx. vlue over which y is compred ech of those points is region x Mx. vlue over which x is compred

156 Continuous stte spce y This prtition is fine enough Mx. vlue over which y is compred Time pssing x Mx. vlue over which x is compred

157 Continuous stte spce y This prtition is fine enough Mx. vlue over which y is compred Time pssing x Mx. vlue over which x is compred

158 Continuous stte spce y This prtition is fine enough Mx. vlue over which y is compred Reseting of y x Mx. vlue over which x is compred

159 Continuous stte spce y This prtition is fine enough Mx. vlue over which y is compred Reseting of y x Mx. vlue over which x is compred

160 Continuous stte spce This prtition is fine enough 2 discrete trnsition from L1 to L x 1 2 x L1 L2

161 Continuous stte spce This prtition is fine enough 2 discrete trnsition from L1 to L x 1 2 x L1 L2

162 Continuous stte spce This prtition is fine enough 2 discrete trnsition from L1 to L2 with reset of y x 1 2 x L1 L2

163 Continuous stte spce This prtition is fine enough 2 discrete trnsition from L1 to L2 with reset of y x 1 2 x L1 L2

164 Region equivlence: forml definition For ech vrile x Cl, let cx e the lrgest constnt with which x is compred in the TA. Two vlutions v1,v2:cl R re region equivlent, noted v1 v2 iff sme integer prts: for ll x Cl, int(v1(x))=int(v2(x)), or v1(x)>cx nd v2(x)>cx. sme frctionl ordering: for ll x,y Cl with v1(x) cx nd v1(y) cy, frc(v1(x)) frc(v1(y)) iff frc(v2(x)) frc(v2(y)) sme null frctionl prts: for ll x,y Cl with v1(x) cx nd v1(y) cy, frc(v1(x))= iff frc(v2(x))= Theorem: Region is set of vlutions tht re time strct isimilr.

165 Region equivlence quotient of the time-strct LTS The following theorem is the foundtion for the utomtic verifiction of timed utomt. Theorem. Let A e timed utomton, let L e its time-strct leled trnsition system, let L e its quotient y the region equivlence, then L is finite nd L is trce equivlent to L.

166 Post opertions in the time strct LTS To construct region sed isimultion quotient of the timestrct LTS of TA (or to compute on it), we must e le to compute the trnsition reltion etween regions. We consider the two types of trnsitions tht we find in the time-strct LTS of TA: Discrete trnsitions tht re ssocited to trnsition edges in the timed utomton. Let (q1,,φ,δ,q2) E: (1) Note tht given region r nd gurd Φ, ll vlutions v1,v2 r is such tht v1 Φ iff v2 Φ. (2) The effect of resetting clock on region r gives region r. Dely trnsitions. Given region r, we cn compute the set of regions r tht contins v+t for some v r nd some t R.

167 Continuous stte spce y The trnsitions of the time-strct trnsition system cn e rephrsed on the regions 3 Mx. vlue over which y is compred x Mx. vlue over which x is compred

168 Continuous stte spce y The trnsitions of the time-strct trnsition system cn e rephrsed on the regions Mx. vlue over which y is compred Reseting of y x Mx. vlue over which x is compred

169 Continuous stte spce y The trnsitions of the time-strct trnsition system cn e rephrsed on the regions Mx. vlue over which y is compred Reseting of y x Mx. vlue over which x is compred

170 Continuous stte spce y The trnsitions of the time-strct trnsition system cn e rephrsed on the regions Mx. vlue over which y is compred Time pssing x Mx. vlue over which x is compred

171 Continuous stte spce y The trnsitions of the time-strct trnsition system cn e rephrsed on the regions Mx. vlue over which y is compred Time pssing x Mx. vlue over which x is compred

172 TA nd the ckwrd pproch The region isimultion is stle lso for the opertions tht explore the stte spce in ckwrd fshion (Pre, Apre)... nd so, we cn lso use ckwrd lgorithms to verify TA.

173 On the use of the region equivlence to verify rechility properties of TA Forwrd rechility nlysis on simple exmple

174 Question: Cn L3 e reched? L L1 L2 y 2 1 y 2 1 y x 1 2 x 1 2 x

175 Question: Cn L3 e reched? L L1 L2 y 2 1 y 2 1 y x 1 2 x 1 2 x

176 Question: Cn L3 e reched? L L1 L2 y 2 1 y 2 1 y x 1 2 x 1 2 x

177 Question: Cn L3 e reched? L L1 L2 y 2 1 y 2 1 y x 1 2 x 1 2 x

178 Question: Cn L3 e reched? L L1 L2 y 2 1 y 2 1 y x 1 2 x 1 2 x

179 Question: Cn L3 e reched? L L1 L2 y 2 1 y 2 1 y x 1 2 x 1 2 x

180 Question: Cn L3 e reched? L L1 L2 y 2 1 y 2 1 y x 1 2 x 1 2 x

181 Question: Cn L3 e reched? L L1 L2 y y y x 1 2 x 1 2 x

182 Question: Cn L3 e reched? L L1 L2 y y y x 1 2 x 1 2 x Tking the trnsition from L1 to L2 does not dd ny new sttes, so we hve reched fixed point.

183 Zones The region equivlence gives rise to finite quotient nd gurnties tht our fixed point lgorithms re terminting. Nevertheless, the numer of region is exponentil in the numer of clocks s well s in the inry encoding of constnts. To mitigte this stte explosion phenomenon, we cn use efficient dt-structure to represent convex unions of regions. Zones re such dt-structure. Note tht the rechility prolem for timed utomt is complete for PSpce, so it is elieved tht the stte explosion is unvoidle in the worst cse.

184 Zones y x x 1 x 3 y 3 y 1 x-y -2 y-x 1

185 Zones Let C e finite set of clocks, zone is defined y set of constrints of the form: (1) x-y c where x,y C nd c Z. (2) x c where x C nd c Z. nd {,<,=,>, }. Zones re closed under the reseting opertion, the forwrd nd ckwrd time pssing opertions, nd intersection. Unfortuntely, zones re not closed under union nor complementtion. So implementtions need to mintin lists of zones. Zones cn e cnoniclly represented y DBM (=Difference Bound Mtrices).

186 Zones y x x 1 x 3 y 3 y 1 x-y -2 y-x 1

187 Zones y x Reseting of y: x 1 x 3 y=

188 Zones y x Conjunction with the gurd: x 2 y 3

189 Zones y x Conjunction with the gurd: x 2 y 3

190 Zones y x Conjunction with the gurd: x 2 y 3

191 Zones y x Conjunction with the gurd: x 2 y 3

192 Zones y x x 1 x 2 y 1 y 3 x-y -1

193 Decidility results for TA

194 Decidility results As direct consequence of our previous developments, we hve tht: The rechility verifiction prolem for TA w.r.t. set Gol which is defined s union of regions is decidle. The sfety verifiction prolem for TA w.r.t. set Sfe which is defined s union of regions is decidle. The Büchi verifiction prolem for TA w.r.t. set Gol which is defined s union of regions is decidle.

195 Decidility results As the rechility verifiction prolem for TA is decidle then the timed lnguge emptiness prolem (finite word cse) is decidle for TA. As the Büchi verifiction prolem for TA is decidle then the timed lnguge emptiness prolem (infinite word cse) is decidle for TA. Hint to estlish the result: construct set Gol tht ensures non-zenoness nd the Büchi cceptnce condition of the TA. Show tht this set is finite union of regions. As n intermediry step you will need generlized Büchi condition.

196 Undecidility results for TA

197 Undecidility results for TA The timed universlity prolem, i.e. does TA ccepts ll possile timed words on lphet, is undecidle. The lnguge inclusion prolem etween timed utomt is undecidle. (direct consequence of the previous undecidility result).

Minimal DFA. minimal DFA for L starting from any other

Minimal DFA. minimal DFA for L starting from any other Miniml DFA Among the mny DFAs ccepting the sme regulr lnguge L, there is exctly one (up to renming of sttes) which hs the smllest possile numer of sttes. Moreover, it is possile to otin tht miniml DFA

More information

Coalgebra, Lecture 15: Equations for Deterministic Automata

Coalgebra, Lecture 15: Equations for Deterministic Automata Colger, Lecture 15: Equtions for Deterministic Automt Julin Slmnc (nd Jurrin Rot) Decemer 19, 2016 In this lecture, we will study the concept of equtions for deterministic utomt. The notes re self contined

More information

Convert the NFA into DFA

Convert the NFA into DFA Convert the NF into F For ech NF we cn find F ccepting the sme lnguge. The numer of sttes of the F could e exponentil in the numer of sttes of the NF, ut in prctice this worst cse occurs rrely. lgorithm:

More information

Exercises with (Some) Solutions

Exercises with (Some) Solutions Exercises with (Some) Solutions Techer: Luc Tesei Mster of Science in Computer Science - University of Cmerino Contents 1 Strong Bisimultion nd HML 2 2 Wek Bisimultion 31 3 Complete Lttices nd Fix Points

More information

1 Nondeterministic Finite Automata

1 Nondeterministic Finite Automata 1 Nondeterministic Finite Automt Suppose in life, whenever you hd choice, you could try oth possiilities nd live your life. At the end, you would go ck nd choose the one tht worked out the est. Then you

More information

Designing finite automata II

Designing finite automata II Designing finite utomt II Prolem: Design DFA A such tht L(A) consists of ll strings of nd which re of length 3n, for n = 0, 1, 2, (1) Determine wht to rememer out the input string Assign stte to ech of

More information

CS415 Compilers. Lexical Analysis and. These slides are based on slides copyrighted by Keith Cooper, Ken Kennedy & Linda Torczon at Rice University

CS415 Compilers. Lexical Analysis and. These slides are based on slides copyrighted by Keith Cooper, Ken Kennedy & Linda Torczon at Rice University CS415 Compilers Lexicl Anlysis nd These slides re sed on slides copyrighted y Keith Cooper, Ken Kennedy & Lind Torczon t Rice University First Progrmming Project Instruction Scheduling Project hs een posted

More information

Formal Languages and Automata

Formal Languages and Automata Moile Computing nd Softwre Engineering p. 1/5 Forml Lnguges nd Automt Chpter 2 Finite Automt Chun-Ming Liu cmliu@csie.ntut.edu.tw Deprtment of Computer Science nd Informtion Engineering Ntionl Tipei University

More information

AUTOMATA AND LANGUAGES. Definition 1.5: Finite Automaton

AUTOMATA AND LANGUAGES. Definition 1.5: Finite Automaton 25. Finite Automt AUTOMATA AND LANGUAGES A system of computtion tht only hs finite numer of possile sttes cn e modeled using finite utomton A finite utomton is often illustrted s stte digrm d d d. d q

More information

CMSC 330: Organization of Programming Languages

CMSC 330: Organization of Programming Languages CMSC 330: Orgniztion of Progrmming Lnguges Finite Automt 2 CMSC 330 1 Types of Finite Automt Deterministic Finite Automt (DFA) Exctly one sequence of steps for ech string All exmples so fr Nondeterministic

More information

Lecture 09: Myhill-Nerode Theorem

Lecture 09: Myhill-Nerode Theorem CS 373: Theory of Computtion Mdhusudn Prthsrthy Lecture 09: Myhill-Nerode Theorem 16 Ferury 2010 In this lecture, we will see tht every lnguge hs unique miniml DFA We will see this fct from two perspectives

More information

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. Comparing DFAs and NFAs (cont.) Finite Automata 2

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. Comparing DFAs and NFAs (cont.) Finite Automata 2 CMSC 330: Orgniztion of Progrmming Lnguges Finite Automt 2 Types of Finite Automt Deterministic Finite Automt () Exctly one sequence of steps for ech string All exmples so fr Nondeterministic Finite Automt

More information

CHAPTER 1 Regular Languages. Contents

CHAPTER 1 Regular Languages. Contents Finite Automt (FA or DFA) CHAPTE 1 egulr Lnguges Contents definitions, exmples, designing, regulr opertions Non-deterministic Finite Automt (NFA) definitions, euivlence of NFAs nd DFAs, closure under regulr

More information

Automata Theory 101. Introduction. Outline. Introduction Finite Automata Regular Expressions ω-automata. Ralf Huuck.

Automata Theory 101. Introduction. Outline. Introduction Finite Automata Regular Expressions ω-automata. Ralf Huuck. Outline Automt Theory 101 Rlf Huuck Introduction Finite Automt Regulr Expressions ω-automt Session 1 2006 Rlf Huuck 1 Session 1 2006 Rlf Huuck 2 Acknowledgement Some slides re sed on Wolfgng Thoms excellent

More information

Lecture 08: Feb. 08, 2019

Lecture 08: Feb. 08, 2019 4CS4-6:Theory of Computtion(Closure on Reg. Lngs., regex to NDFA, DFA to regex) Prof. K.R. Chowdhry Lecture 08: Fe. 08, 2019 : Professor of CS Disclimer: These notes hve not een sujected to the usul scrutiny

More information

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. NFA for (a b)*abb.

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. NFA for (a b)*abb. CMSC 330: Orgniztion of Progrmming Lnguges Finite Automt 2 Types of Finite Automt Deterministic Finite Automt () Exctly one sequence of steps for ech string All exmples so fr Nondeterministic Finite Automt

More information

Lecture 9: LTL and Büchi Automata

Lecture 9: LTL and Büchi Automata Lecture 9: LTL nd Büchi Automt 1 LTL Property Ptterns Quite often the requirements of system follow some simple ptterns. Sometimes we wnt to specify tht property should only hold in certin context, clled

More information

CMPSCI 250: Introduction to Computation. Lecture #31: What DFA s Can and Can t Do David Mix Barrington 9 April 2014

CMPSCI 250: Introduction to Computation. Lecture #31: What DFA s Can and Can t Do David Mix Barrington 9 April 2014 CMPSCI 250: Introduction to Computtion Lecture #31: Wht DFA s Cn nd Cn t Do Dvid Mix Brrington 9 April 2014 Wht DFA s Cn nd Cn t Do Deterministic Finite Automt Forml Definition of DFA s Exmples of DFA

More information

Theory of Computation Regular Languages. (NTU EE) Regular Languages Fall / 38

Theory of Computation Regular Languages. (NTU EE) Regular Languages Fall / 38 Theory of Computtion Regulr Lnguges (NTU EE) Regulr Lnguges Fll 2017 1 / 38 Schemtic of Finite Automt control 0 0 1 0 1 1 1 0 Figure: Schemtic of Finite Automt A finite utomton hs finite set of control

More information

Nondeterminism and Nodeterministic Automata

Nondeterminism and Nodeterministic Automata Nondeterminism nd Nodeterministic Automt 61 Nondeterminism nd Nondeterministic Automt The computtionl mchine models tht we lerned in the clss re deterministic in the sense tht the next move is uniquely

More information

Finite Automata Theory and Formal Languages TMV027/DIT321 LP4 2018

Finite Automata Theory and Formal Languages TMV027/DIT321 LP4 2018 Finite Automt Theory nd Forml Lnguges TMV027/DIT321 LP4 2018 Lecture 10 An Bove April 23rd 2018 Recp: Regulr Lnguges We cn convert between FA nd RE; Hence both FA nd RE ccept/generte regulr lnguges; More

More information

CM10196 Topic 4: Functions and Relations

CM10196 Topic 4: Functions and Relations CM096 Topic 4: Functions nd Reltions Guy McCusker W. Functions nd reltions Perhps the most widely used notion in ll of mthemtics is tht of function. Informlly, function is n opertion which tkes n input

More information

Theory of Computation Regular Languages

Theory of Computation Regular Languages Theory of Computtion Regulr Lnguges Bow-Yw Wng Acdemi Sinic Spring 2012 Bow-Yw Wng (Acdemi Sinic) Regulr Lnguges Spring 2012 1 / 38 Schemtic of Finite Automt control 0 0 1 0 1 1 1 0 Figure: Schemtic of

More information

A Symbolic Approach to Control via Approximate Bisimulations

A Symbolic Approach to Control via Approximate Bisimulations A Symolic Approch to Control vi Approximte Bisimultions Antoine Girrd Lortoire Jen Kuntzmnn, Université Joseph Fourier Grenole, Frnce Interntionl Symposium on Innovtive Mthemticl Modelling Tokyo, Jpn,

More information

Chapter 2 Finite Automata

Chapter 2 Finite Automata Chpter 2 Finite Automt 28 2.1 Introduction Finite utomt: first model of the notion of effective procedure. (They lso hve mny other pplictions). The concept of finite utomton cn e derived y exmining wht

More information

Exercises Chapter 1. Exercise 1.1. Let Σ be an alphabet. Prove wv = w + v for all strings w and v.

Exercises Chapter 1. Exercise 1.1. Let Σ be an alphabet. Prove wv = w + v for all strings w and v. 1 Exercises Chpter 1 Exercise 1.1. Let Σ e n lphet. Prove wv = w + v for ll strings w nd v. Prove # (wv) = # (w)+# (v) for every symol Σ nd every string w,v Σ. Exercise 1.2. Let w 1,w 2,...,w k e k strings,

More information

CS 267: Automated Verification. Lecture 8: Automata Theoretic Model Checking. Instructor: Tevfik Bultan

CS 267: Automated Verification. Lecture 8: Automata Theoretic Model Checking. Instructor: Tevfik Bultan CS 267: Automted Verifiction Lecture 8: Automt Theoretic Model Checking Instructor: Tevfik Bultn LTL Properties Büchi utomt [Vrdi nd Wolper LICS 86] Büchi utomt: Finite stte utomt tht ccept infinite strings

More information

Hybrid Control and Switched Systems. Lecture #2 How to describe a hybrid system? Formal models for hybrid system

Hybrid Control and Switched Systems. Lecture #2 How to describe a hybrid system? Formal models for hybrid system Hyrid Control nd Switched Systems Lecture #2 How to descrie hyrid system? Forml models for hyrid system João P. Hespnh University of Cliforni t Snt Brr Summry. Forml models for hyrid systems: Finite utomt

More information

CISC 4090 Theory of Computation

CISC 4090 Theory of Computation 9/6/28 Stereotypicl computer CISC 49 Theory of Computtion Finite stte mchines & Regulr lnguges Professor Dniel Leeds dleeds@fordhm.edu JMH 332 Centrl processing unit (CPU) performs ll the instructions

More information

1. For each of the following theorems, give a two or three sentence sketch of how the proof goes or why it is not true.

1. For each of the following theorems, give a two or three sentence sketch of how the proof goes or why it is not true. York University CSE 2 Unit 3. DFA Clsses Converting etween DFA, NFA, Regulr Expressions, nd Extended Regulr Expressions Instructor: Jeff Edmonds Don t chet y looking t these nswers premturely.. For ech

More information

Assignment 1 Automata, Languages, and Computability. 1 Finite State Automata and Regular Languages

Assignment 1 Automata, Languages, and Computability. 1 Finite State Automata and Regular Languages Deprtment of Computer Science, Austrlin Ntionl University COMP2600 Forml Methods for Softwre Engineering Semester 2, 206 Assignment Automt, Lnguges, nd Computility Smple Solutions Finite Stte Automt nd

More information

Finite-State Automata: Recap

Finite-State Automata: Recap Finite-Stte Automt: Recp Deepk D Souz Deprtment of Computer Science nd Automtion Indin Institute of Science, Bnglore. 09 August 2016 Outline 1 Introduction 2 Forml Definitions nd Nottion 3 Closure under

More information

Speech Recognition Lecture 2: Finite Automata and Finite-State Transducers

Speech Recognition Lecture 2: Finite Automata and Finite-State Transducers Speech Recognition Lecture 2: Finite Automt nd Finite-Stte Trnsducers Eugene Weinstein Google, NYU Cournt Institute eugenew@cs.nyu.edu Slide Credit: Mehryr Mohri Preliminries Finite lphet, empty string.

More information

Chapter Five: Nondeterministic Finite Automata. Formal Language, chapter 5, slide 1

Chapter Five: Nondeterministic Finite Automata. Formal Language, chapter 5, slide 1 Chpter Five: Nondeterministic Finite Automt Forml Lnguge, chpter 5, slide 1 1 A DFA hs exctly one trnsition from every stte on every symol in the lphet. By relxing this requirement we get relted ut more

More information

1. For each of the following theorems, give a two or three sentence sketch of how the proof goes or why it is not true.

1. For each of the following theorems, give a two or three sentence sketch of how the proof goes or why it is not true. York University CSE 2 Unit 3. DFA Clsses Converting etween DFA, NFA, Regulr Expressions, nd Extended Regulr Expressions Instructor: Jeff Edmonds Don t chet y looking t these nswers premturely.. For ech

More information

Speech Recognition Lecture 2: Finite Automata and Finite-State Transducers. Mehryar Mohri Courant Institute and Google Research

Speech Recognition Lecture 2: Finite Automata and Finite-State Transducers. Mehryar Mohri Courant Institute and Google Research Speech Recognition Lecture 2: Finite Automt nd Finite-Stte Trnsducers Mehryr Mohri Cournt Institute nd Google Reserch mohri@cims.nyu.com Preliminries Finite lphet Σ, empty string. Set of ll strings over

More information

Finite Automata-cont d

Finite Automata-cont d Automt Theory nd Forml Lnguges Professor Leslie Lnder Lecture # 6 Finite Automt-cont d The Pumping Lemm WEB SITE: http://ingwe.inghmton.edu/ ~lnder/cs573.html Septemer 18, 2000 Exmple 1 Consider L = {ww

More information

Deterministic Finite Automata

Deterministic Finite Automata Finite Automt Deterministic Finite Automt H. Geuvers nd J. Rot Institute for Computing nd Informtion Sciences Version: fll 2016 J. Rot Version: fll 2016 Tlen en Automten 1 / 21 Outline Finite Automt Finite

More information

Software Engineering using Formal Methods

Software Engineering using Formal Methods Softwre Engineering using Forml Methods Propositionl nd (Liner) Temporl Logic Wolfgng Ahrendt 13th Septemer 2016 SEFM: Liner Temporl Logic /GU 160913 1 / 60 Recpitultion: FormlistionFormlistion: Syntx,

More information

Lexical Analysis Finite Automate

Lexical Analysis Finite Automate Lexicl Anlysis Finite Automte CMPSC 470 Lecture 04 Topics: Deterministic Finite Automt (DFA) Nondeterministic Finite Automt (NFA) Regulr Expression NFA DFA A. Finite Automt (FA) FA re grph, like trnsition

More information

Harvard University Computer Science 121 Midterm October 23, 2012

Harvard University Computer Science 121 Midterm October 23, 2012 Hrvrd University Computer Science 121 Midterm Octoer 23, 2012 This is closed-ook exmintion. You my use ny result from lecture, Sipser, prolem sets, or section, s long s you quote it clerly. The lphet is

More information

SWEN 224 Formal Foundations of Programming WITH ANSWERS

SWEN 224 Formal Foundations of Programming WITH ANSWERS T E W H A R E W Ā N A N G A O T E Ū P O K O O T E I K A A M Ā U I VUW V I C T O R I A UNIVERSITY OF WELLINGTON Time Allowed: 3 Hours EXAMINATIONS 2011 END-OF-YEAR SWEN 224 Forml Foundtions of Progrmming

More information

Regular expressions, Finite Automata, transition graphs are all the same!!

Regular expressions, Finite Automata, transition graphs are all the same!! CSI 3104 /Winter 2011: Introduction to Forml Lnguges Chpter 7: Kleene s Theorem Chpter 7: Kleene s Theorem Regulr expressions, Finite Automt, trnsition grphs re ll the sme!! Dr. Neji Zgui CSI3104-W11 1

More information

Compiler Design. Fall Lexical Analysis. Sample Exercises and Solutions. Prof. Pedro C. Diniz

Compiler Design. Fall Lexical Analysis. Sample Exercises and Solutions. Prof. Pedro C. Diniz University of Southern Cliforni Computer Science Deprtment Compiler Design Fll Lexicl Anlysis Smple Exercises nd Solutions Prof. Pedro C. Diniz USC / Informtion Sciences Institute 4676 Admirlty Wy, Suite

More information

CS103B Handout 18 Winter 2007 February 28, 2007 Finite Automata

CS103B Handout 18 Winter 2007 February 28, 2007 Finite Automata CS103B ndout 18 Winter 2007 Ferury 28, 2007 Finite Automt Initil text y Mggie Johnson. Introduction Severl childrens gmes fit the following description: Pieces re set up on plying ord; dice re thrown or

More information

NFA DFA Example 3 CMSC 330: Organization of Programming Languages. Equivalence of DFAs and NFAs. Equivalence of DFAs and NFAs (cont.

NFA DFA Example 3 CMSC 330: Organization of Programming Languages. Equivalence of DFAs and NFAs. Equivalence of DFAs and NFAs (cont. NFA DFA Exmple 3 CMSC 330: Orgniztion of Progrmming Lnguges NFA {B,D,E {A,E {C,D {E Finite Automt, con't. R = { {A,E, {B,D,E, {C,D, {E 2 Equivlence of DFAs nd NFAs Any string from {A to either {D or {CD

More information

Safety Controller Synthesis for Switched Systems using Multiscale Symbolic Models

Safety Controller Synthesis for Switched Systems using Multiscale Symbolic Models Sfety Controller Synthesis for Switched Systems using Multiscle Symolic Models Antoine Girrd Lortoire des Signux et Systèmes Gif sur Yvette, Frnce Workshop on switching dynmics & verifiction Pris, Jnury

More information

Foundations for Timed Systems

Foundations for Timed Systems Foundtions for Timed Systems Ptrici Bouyer LSV CNRS UMR 8643 & ENS de Cchn 6, venue du Président Wilson 9423 Cchn Frnce emil: bouyer@lsv.ens-cchn.fr Introduction Explicit timing constrints re nturlly present

More information

Homework 3 Solutions

Homework 3 Solutions CS 341: Foundtions of Computer Science II Prof. Mrvin Nkym Homework 3 Solutions 1. Give NFAs with the specified numer of sttes recognizing ech of the following lnguges. In ll cses, the lphet is Σ = {,1}.

More information

(e) if x = y + z and a divides any two of the integers x, y, or z, then a divides the remaining integer

(e) if x = y + z and a divides any two of the integers x, y, or z, then a divides the remaining integer Divisibility In this note we introduce the notion of divisibility for two integers nd b then we discuss the division lgorithm. First we give forml definition nd note some properties of the division opertion.

More information

Java II Finite Automata I

Java II Finite Automata I Jv II Finite Automt I Bernd Kiefer Bernd.Kiefer@dfki.de Deutsches Forschungszentrum für künstliche Intelligenz Finite Automt I p.1/13 Processing Regulr Expressions We lredy lerned out Jv s regulr expression

More information

Non-deterministic Finite Automata

Non-deterministic Finite Automata Non-deterministic Finite Automt Eliminting non-determinism Rdoud University Nijmegen Non-deterministic Finite Automt H. Geuvers nd T. vn Lrhoven Institute for Computing nd Informtion Sciences Intelligent

More information

NFAs continued, Closure Properties of Regular Languages

NFAs continued, Closure Properties of Regular Languages Algorithms & Models of Computtion CS/ECE 374, Fll 2017 NFAs continued, Closure Properties of Regulr Lnguges Lecture 5 Tuesdy, Septemer 12, 2017 Sriel Hr-Peled (UIUC) CS374 1 Fll 2017 1 / 31 Regulr Lnguges,

More information

CS 311 Homework 3 due 16:30, Thursday, 14 th October 2010

CS 311 Homework 3 due 16:30, Thursday, 14 th October 2010 CS 311 Homework 3 due 16:30, Thursdy, 14 th Octoer 2010 Homework must e sumitted on pper, in clss. Question 1. [15 pts.; 5 pts. ech] Drw stte digrms for NFAs recognizing the following lnguges:. L = {w

More information

First Midterm Examination

First Midterm Examination Çnky University Deprtment of Computer Engineering 203-204 Fll Semester First Midterm Exmintion ) Design DFA for ll strings over the lphet Σ = {,, c} in which there is no, no nd no cc. 2) Wht lnguge does

More information

The University of Nottingham SCHOOL OF COMPUTER SCIENCE A LEVEL 2 MODULE, SPRING SEMESTER LANGUAGES AND COMPUTATION ANSWERS

The University of Nottingham SCHOOL OF COMPUTER SCIENCE A LEVEL 2 MODULE, SPRING SEMESTER LANGUAGES AND COMPUTATION ANSWERS The University of Nottinghm SCHOOL OF COMPUTER SCIENCE LEVEL 2 MODULE, SPRING SEMESTER 2016 2017 LNGUGES ND COMPUTTION NSWERS Time llowed TWO hours Cndidtes my complete the front cover of their nswer ook

More information

ɛ-closure, Kleene s Theorem,

ɛ-closure, Kleene s Theorem, DEGefW5wiGH2XgYMEzUKjEmtCDUsRQ4d 1 A nice pper relevnt to this course is titled The Glory of the Pst 2 NICTA Resercher, Adjunct t the Austrlin Ntionl University nd Griffith University ɛ-closure, Kleene

More information

CS 301. Lecture 04 Regular Expressions. Stephen Checkoway. January 29, 2018

CS 301. Lecture 04 Regular Expressions. Stephen Checkoway. January 29, 2018 CS 301 Lecture 04 Regulr Expressions Stephen Checkowy Jnury 29, 2018 1 / 35 Review from lst time NFA N = (Q, Σ, δ, q 0, F ) where δ Q Σ P (Q) mps stte nd n lphet symol (or ) to set of sttes We run n NFA

More information

Regular Expressions (RE) Regular Expressions (RE) Regular Expressions (RE) Regular Expressions (RE) Kleene-*

Regular Expressions (RE) Regular Expressions (RE) Regular Expressions (RE) Regular Expressions (RE) Kleene-* Regulr Expressions (RE) Regulr Expressions (RE) Empty set F A RE denotes the empty set Opertion Nottion Lnguge UNIX Empty string A RE denotes the set {} Alterntion R +r L(r ) L(r ) r r Symol Alterntion

More information

Symbolic enumeration methods for unlabelled structures

Symbolic enumeration methods for unlabelled structures Go & Šjn, Comintoril Enumertion Notes 4 Symolic enumertion methods for unlelled structures Definition A comintoril clss is finite or denumerle set on which size function is defined, stisfying the following

More information

Finite Automata. Informatics 2A: Lecture 3. John Longley. 22 September School of Informatics University of Edinburgh

Finite Automata. Informatics 2A: Lecture 3. John Longley. 22 September School of Informatics University of Edinburgh Lnguges nd Automt Finite Automt Informtics 2A: Lecture 3 John Longley School of Informtics University of Edinburgh jrl@inf.ed.c.uk 22 September 2017 1 / 30 Lnguges nd Automt 1 Lnguges nd Automt Wht is

More information

GNFA GNFA GNFA GNFA GNFA

GNFA GNFA GNFA GNFA GNFA DFA RE NFA DFA -NFA REX GNFA Definition GNFA A generlize noneterministic finite utomton (GNFA) is grph whose eges re lele y regulr expressions, with unique strt stte with in-egree, n unique finl stte with

More information

12.1 Nondeterminism Nondeterministic Finite Automata. a a b ε. CS125 Lecture 12 Fall 2016

12.1 Nondeterminism Nondeterministic Finite Automata. a a b ε. CS125 Lecture 12 Fall 2016 CS125 Lecture 12 Fll 2016 12.1 Nondeterminism The ide of nondeterministic computtions is to llow our lgorithms to mke guesses, nd only require tht they ccept when the guesses re correct. For exmple, simple

More information

More general families of infinite graphs

More general families of infinite graphs More generl fmilies of infinite grphs Antoine Meyer Forml Methods Updte 2006 IIT Guwhti Prefix-recognizle grphs Theorem Let G e grph, the following sttements re equivlent: G is defined y reltions of the

More information

Intermediate Math Circles Wednesday, November 14, 2018 Finite Automata II. Nickolas Rollick a b b. a b 4

Intermediate Math Circles Wednesday, November 14, 2018 Finite Automata II. Nickolas Rollick a b b. a b 4 Intermedite Mth Circles Wednesdy, Novemer 14, 2018 Finite Automt II Nickols Rollick nrollick@uwterloo.c Regulr Lnguges Lst time, we were introduced to the ide of DFA (deterministic finite utomton), one

More information

Formal languages, automata, and theory of computation

Formal languages, automata, and theory of computation Mälrdlen University TEN1 DVA337 2015 School of Innovtion, Design nd Engineering Forml lnguges, utomt, nd theory of computtion Thursdy, Novemer 5, 14:10-18:30 Techer: Dniel Hedin, phone 021-107052 The exm

More information

NFAs continued, Closure Properties of Regular Languages

NFAs continued, Closure Properties of Regular Languages lgorithms & Models of omputtion S/EE 374, Spring 209 NFs continued, losure Properties of Regulr Lnguges Lecture 5 Tuesdy, Jnury 29, 209 Regulr Lnguges, DFs, NFs Lnguges ccepted y DFs, NFs, nd regulr expressions

More information

CSCI 340: Computational Models. Kleene s Theorem. Department of Computer Science

CSCI 340: Computational Models. Kleene s Theorem. Department of Computer Science CSCI 340: Computtionl Models Kleene s Theorem Chpter 7 Deprtment of Computer Science Unifiction In 1954, Kleene presented (nd proved) theorem which (in our version) sttes tht if lnguge cn e defined y ny

More information

80 CHAPTER 2. DFA S, NFA S, REGULAR LANGUAGES. 2.6 Finite State Automata With Output: Transducers

80 CHAPTER 2. DFA S, NFA S, REGULAR LANGUAGES. 2.6 Finite State Automata With Output: Transducers 80 CHAPTER 2. DFA S, NFA S, REGULAR LANGUAGES 2.6 Finite Stte Automt With Output: Trnsducers So fr, we hve only considered utomt tht recognize lnguges, i.e., utomt tht do not produce ny output on ny input

More information

More on automata. Michael George. March 24 April 7, 2014

More on automata. Michael George. March 24 April 7, 2014 More on utomt Michel George Mrch 24 April 7, 2014 1 Automt constructions Now tht we hve forml model of mchine, it is useful to mke some generl constructions. 1.1 DFA Union / Product construction Suppose

More information

Grammar. Languages. Content 5/10/16. Automata and Languages. Regular Languages. Regular Languages

Grammar. Languages. Content 5/10/16. Automata and Languages. Regular Languages. Regular Languages 5//6 Grmmr Automt nd Lnguges Regulr Grmmr Context-free Grmmr Context-sensitive Grmmr Prof. Mohmed Hmd Softwre Engineering L. The University of Aizu Jpn Regulr Lnguges Context Free Lnguges Context Sensitive

More information

Homework 4. 0 ε 0. (00) ε 0 ε 0 (00) (11) CS 341: Foundations of Computer Science II Prof. Marvin Nakayama

Homework 4. 0 ε 0. (00) ε 0 ε 0 (00) (11) CS 341: Foundations of Computer Science II Prof. Marvin Nakayama CS 341: Foundtions of Computer Science II Prof. Mrvin Nkym Homework 4 1. UsetheproceduredescriedinLemm1.55toconverttheregulrexpression(((00) (11)) 01) into n NFA. Answer: 0 0 1 1 00 0 0 11 1 1 01 0 1 (00)

More information

Probabilistic Model Checking Michaelmas Term Dr. Dave Parker. Department of Computer Science University of Oxford

Probabilistic Model Checking Michaelmas Term Dr. Dave Parker. Department of Computer Science University of Oxford Probbilistic Model Checking Michelms Term 2011 Dr. Dve Prker Deprtment of Computer Science University of Oxford Long-run properties Lst lecture: regulr sfety properties e.g. messge filure never occurs

More information

Strong Bisimulation. Overview. References. Actions Labeled transition system Transition semantics Simulation Bisimulation

Strong Bisimulation. Overview. References. Actions Labeled transition system Transition semantics Simulation Bisimulation Strong Bisimultion Overview Actions Lbeled trnsition system Trnsition semntics Simultion Bisimultion References Robin Milner, Communiction nd Concurrency Robin Milner, Communicting nd Mobil Systems 32

More information

CS 373, Spring Solutions to Mock midterm 1 (Based on first midterm in CS 273, Fall 2008.)

CS 373, Spring Solutions to Mock midterm 1 (Based on first midterm in CS 273, Fall 2008.) CS 373, Spring 29. Solutions to Mock midterm (sed on first midterm in CS 273, Fll 28.) Prolem : Short nswer (8 points) The nswers to these prolems should e short nd not complicted. () If n NF M ccepts

More information

3 Regular expressions

3 Regular expressions 3 Regulr expressions Given n lphet Σ lnguge is set of words L Σ. So fr we were le to descrie lnguges either y using set theory (i.e. enumertion or comprehension) or y n utomton. In this section we shll

More information

NFAs and Regular Expressions. NFA-ε, continued. Recall. Last class: Today: Fun:

NFAs and Regular Expressions. NFA-ε, continued. Recall. Last class: Today: Fun: CMPU 240 Lnguge Theory nd Computtion Spring 2019 NFAs nd Regulr Expressions Lst clss: Introduced nondeterministic finite utomt with -trnsitions Tody: Prove n NFA- is no more powerful thn n NFA Introduce

More information

Safety Controller Synthesis for Switched Systems using Multiscale Symbolic Models

Safety Controller Synthesis for Switched Systems using Multiscale Symbolic Models Sfety Controller Synthesis for Switched Systems using Multiscle Symolic Models Antoine Girrd Lortoire des Signux et Systèmes Gif sur Yvette, Frnce Séminire du LAAS Toulouse, 29 Juin, 2016 A. Girrd (L2S-CNRS)

More information

State Minimization for DFAs

State Minimization for DFAs Stte Minimiztion for DFAs Red K & S 2.7 Do Homework 10. Consider: Stte Minimiztion 4 5 Is this miniml mchine? Step (1): Get rid of unrechle sttes. Stte Minimiztion 6, Stte is unrechle. Step (2): Get rid

More information

The Regulated and Riemann Integrals

The Regulated and Riemann Integrals Chpter 1 The Regulted nd Riemnn Integrls 1.1 Introduction We will consider severl different pproches to defining the definite integrl f(x) dx of function f(x). These definitions will ll ssign the sme vlue

More information

Tutorial Automata and formal Languages

Tutorial Automata and formal Languages Tutoril Automt nd forml Lnguges Notes for to the tutoril in the summer term 2017 Sestin Küpper, Christine Mik 8. August 2017 1 Introduction: Nottions nd sic Definitions At the eginning of the tutoril we

More information

Converting Regular Expressions to Discrete Finite Automata: A Tutorial

Converting Regular Expressions to Discrete Finite Automata: A Tutorial Converting Regulr Expressions to Discrete Finite Automt: A Tutoril Dvid Christinsen 2013-01-03 This is tutoril on how to convert regulr expressions to nondeterministic finite utomt (NFA) nd how to convert

More information

Farey Fractions. Rickard Fernström. U.U.D.M. Project Report 2017:24. Department of Mathematics Uppsala University

Farey Fractions. Rickard Fernström. U.U.D.M. Project Report 2017:24. Department of Mathematics Uppsala University U.U.D.M. Project Report 07:4 Frey Frctions Rickrd Fernström Exmensrete i mtemtik, 5 hp Hledre: Andres Strömergsson Exmintor: Jörgen Östensson Juni 07 Deprtment of Mthemtics Uppsl University Frey Frctions

More information

On Determinisation of History-Deterministic Automata.

On Determinisation of History-Deterministic Automata. On Deterministion of History-Deterministic Automt. Denis Kupererg Mich l Skrzypczk University of Wrsw YR-ICALP 2014 Copenhgen Introduction Deterministic utomt re centrl tool in utomt theory: Polynomil

More information

Table of contents: Lecture N Summary... 3 What does automata mean?... 3 Introduction to languages... 3 Alphabets... 3 Strings...

Table of contents: Lecture N Summary... 3 What does automata mean?... 3 Introduction to languages... 3 Alphabets... 3 Strings... Tle of contents: Lecture N0.... 3 ummry... 3 Wht does utomt men?... 3 Introduction to lnguges... 3 Alphets... 3 trings... 3 Defining Lnguges... 4 Lecture N0. 2... 7 ummry... 7 Kleene tr Closure... 7 Recursive

More information

Summer School Verification Technology, Systems & Applications

Summer School Verification Technology, Systems & Applications VTSA 2011 Summer School Verifiction Technology, Systems & Applictions 4th edition since 2008: Liège (Belgium), Sep. 19 23, 2011 free prticiption, limited number of prticipnts ppliction dedline: July 22,

More information

FABER Formal Languages, Automata and Models of Computation

FABER Formal Languages, Automata and Models of Computation DVA337 FABER Forml Lnguges, Automt nd Models of Computtion Lecture 5 chool of Innovtion, Design nd Engineering Mälrdlen University 2015 1 Recp of lecture 4 y definition suset construction DFA NFA stte

More information

378 Relations Solutions for Chapter 16. Section 16.1 Exercises. 3. Let A = {0,1,2,3,4,5}. Write out the relation R that expresses on A.

378 Relations Solutions for Chapter 16. Section 16.1 Exercises. 3. Let A = {0,1,2,3,4,5}. Write out the relation R that expresses on A. 378 Reltions 16.7 Solutions for Chpter 16 Section 16.1 Exercises 1. Let A = {0,1,2,3,4,5}. Write out the reltion R tht expresses > on A. Then illustrte it with digrm. 2 1 R = { (5,4),(5,3),(5,2),(5,1),(5,0),(4,3),(4,2),(4,1),

More information

Formal Language and Automata Theory (CS21004)

Formal Language and Automata Theory (CS21004) Forml Lnguge nd Automt Forml Lnguge nd Automt Theory (CS21004) Khrgpur Khrgpur Khrgpur Forml Lnguge nd Automt Tle of Contents Forml Lnguge nd Automt Khrgpur 1 2 3 Khrgpur Forml Lnguge nd Automt Forml Lnguge

More information

Intuitionistic Fuzzy Lattices and Intuitionistic Fuzzy Boolean Algebras

Intuitionistic Fuzzy Lattices and Intuitionistic Fuzzy Boolean Algebras Intuitionistic Fuzzy Lttices nd Intuitionistic Fuzzy oolen Algebrs.K. Tripthy #1, M.K. Stpthy *2 nd P.K.Choudhury ##3 # School of Computing Science nd Engineering VIT University Vellore-632014, TN, Indi

More information

Random subgroups of a free group

Random subgroups of a free group Rndom sugroups of free group Frédérique Bssino LIPN - Lortoire d Informtique de Pris Nord, Université Pris 13 - CNRS Joint work with Armndo Mrtino, Cyril Nicud, Enric Ventur et Pscl Weil LIX My, 2015 Introduction

More information

From LTL to Symbolically Represented Deterministic Automata

From LTL to Symbolically Represented Deterministic Automata Motivtion nd Prolem Setting Determinizing Non-Confluent Automt Det. vi Automt Hierrchy From LTL to Symoliclly Represented Deterministic Automt Andres Morgenstern Klus Schneider Sven Lmerti Mnuel Gesell

More information

Thoery of Automata CS402

Thoery of Automata CS402 Thoery of Automt C402 Theory of Automt Tle of contents: Lecture N0. 1... 4 ummry... 4 Wht does utomt men?... 4 Introduction to lnguges... 4 Alphets... 4 trings... 4 Defining Lnguges... 5 Lecture N0. 2...

More information

Fundamentals of Computer Science

Fundamentals of Computer Science Fundmentls of Computer Science Chpter 3: NFA nd DFA equivlence Regulr expressions Henrik Björklund Umeå University Jnury 23, 2014 NFA nd DFA equivlence As we shll see, it turns out tht NFA nd DFA re equivlent,

More information

The size of subsequence automaton

The size of subsequence automaton Theoreticl Computer Science 4 (005) 79 84 www.elsevier.com/locte/tcs Note The size of susequence utomton Zdeněk Troníček,, Ayumi Shinohr,c Deprtment of Computer Science nd Engineering, FEE CTU in Prgue,

More information

Anatomy of a Deterministic Finite Automaton. Deterministic Finite Automata. A machine so simple that you can understand it in less than one minute

Anatomy of a Deterministic Finite Automaton. Deterministic Finite Automata. A machine so simple that you can understand it in less than one minute Victor Admchik Dnny Sletor Gret Theoreticl Ides In Computer Science CS 5-25 Spring 2 Lecture 2 Mr 3, 2 Crnegie Mellon University Deterministic Finite Automt Finite Automt A mchine so simple tht you cn

More information

CHAPTER 1 Regular Languages. Contents. definitions, examples, designing, regular operations. Non-deterministic Finite Automata (NFA)

CHAPTER 1 Regular Languages. Contents. definitions, examples, designing, regular operations. Non-deterministic Finite Automata (NFA) Finite Automt (FA or DFA) CHAPTER Regulr Lnguges Contents definitions, exmples, designing, regulr opertions Non-deterministic Finite Automt (NFA) definitions, equivlence of NFAs DFAs, closure under regulr

More information

NON-DETERMINISTIC FSA

NON-DETERMINISTIC FSA Tw o types of non-determinism: NON-DETERMINISTIC FS () Multiple strt-sttes; strt-sttes S Q. The lnguge L(M) ={x:x tkes M from some strt-stte to some finl-stte nd ll of x is proessed}. The string x = is

More information

DFA minimisation using the Myhill-Nerode theorem

DFA minimisation using the Myhill-Nerode theorem DFA minimistion using the Myhill-Nerode theorem Johnn Högerg Lrs Lrsson Astrct The Myhill-Nerode theorem is n importnt chrcteristion of regulr lnguges, nd it lso hs mny prcticl implictions. In this chpter,

More information

First Midterm Examination

First Midterm Examination 24-25 Fll Semester First Midterm Exmintion ) Give the stte digrm of DFA tht recognizes the lnguge A over lphet Σ = {, } where A = {w w contins or } 2) The following DFA recognizes the lnguge B over lphet

More information