Büchi Automata and Linear Temporal Logic Joshua D. Guttman Worcester Polytechnic Institute 18 February 2010 Guttman ( WPI ) Büchi & LTL 18 Feb 10 1 / 10
Büchi Automata Definition A Büchi automaton is a (non-deterministic) finite automaton. Guttman ( WPI ) Büchi & LTL 18 Feb 10 2 / 10
Büchi Automata Definition A Büchi automaton is a (non-deterministic) finite automaton. A = Q, Σ, δ, Q s, F where: Q is a finite set called the states Σ is a finite set called the alphabet δ Q Σ Q, is called the transition relation Q s Q is called the set of initial states F Q is called the set of accepting states Guttman ( WPI ) Büchi & LTL 18 Feb 10 2 / 10
Büchi Automata: Runs, acceptance, language Let W be an infinite sequence w 0, w 1,... with w i Σ A run R of A for W : an infinite sequence r 0, r 1,... with r i Q where 1 r 0 Q s 2 (r i, w i, r i+1 ) δ Guttman ( WPI ) Büchi & LTL 18 Feb 10 3 / 10
Büchi Automata: Runs, acceptance, language Let W be an infinite sequence w 0, w 1,... with w i Σ A run R of A for W : an infinite sequence r 0, r 1,... with r i Q where 1 r 0 Q s 2 (r i, w i, r i+1 ) δ A accepts W iff there is some run R for W where: {i : r i F } is infinite Guttman ( WPI ) Büchi & LTL 18 Feb 10 3 / 10
Büchi Automata: Runs, acceptance, language Let W be an infinite sequence w 0, w 1,... with w i Σ A run R of A for W : an infinite sequence r 0, r 1,... with r i Q where 1 r 0 Q s 2 (r i, w i, r i+1 ) δ A accepts W iff there is some run R for W where: {i : r i F } is infinite The language accepted by A, written lang(a), is {W : A accepts W } Guttman ( WPI ) Büchi & LTL 18 Feb 10 3 / 10
Some Büchi Automata, 1 Σ = {a, b} b 1 F = {2} a b a 2 Guttman ( WPI ) Büchi & LTL 18 Feb 10 4 / 10
Some Büchi Automata, 1 Σ = {a, b} b 1 F = {2} a b a 2 Accepts W iff W has infinitely many as Guttman ( WPI ) Büchi & LTL 18 Feb 10 4 / 10
Some Büchi Automata, 2 Σ = {a, b} F = {2} 1 b 2 a 3 Guttman ( WPI ) Büchi & LTL 18 Feb 10 5 / 10
Some Büchi Automata, 2 Σ = {a, b} F = {2} 1 b 2 a 3 Accepts W iff W has finitely many as Can transition to state 2 after last a received Guttman ( WPI ) Büchi & LTL 18 Feb 10 5 / 10
Testing Non-Emptiness F = {2} 1 b 2 a 3 Guttman ( WPI ) Büchi & LTL 18 Feb 10 6 / 10
Testing Non-Emptiness F = {2} 1 b 2 a 3 There exists a W lang(a) if there is a q with 1 a path from a start state to q 2 a cycle q + q Guttman ( WPI ) Büchi & LTL 18 Feb 10 6 / 10
Closure Conditions on Languages Suppose given Büchi automata A 1, A 2 there exist Büchi automata with languages: lang(a 1 ) lang(a 2 ) lang(a 1 ) lang(a 2 ) Σ ω \ lang(a 1 ) Guttman ( WPI ) Büchi & LTL 18 Feb 10 7 / 10
Büchi Automata Representing LTL formula ϕ ϕ contains atomic formulas L Σ: Input letters are prop. logic models M L Q: Each subformula of ϕ is a state, plus,,... δ(ψ, M): depends on form of ψ:, if ψ in prop. logic and M = ψ, if ψ in prop. logic and M = ψ Guttman ( WPI ) Büchi & LTL 18 Feb 10 8 / 10
Büchi Automata Representing LTL formula ϕ ϕ contains atomic formulas L Σ: Input letters are prop. logic models M L Q: Each subformula of ϕ is a state, plus,,... δ(ψ, M): depends on form of ψ:, if ψ in prop. logic and M = ψ, if ψ in prop. logic and M = ψ χ, if ψ is X (χ) and, Guttman ( WPI ) Büchi & LTL 18 Feb 10 8 / 10
Büchi Automata Representing LTL formula ϕ ϕ contains atomic formulas L Σ: Input letters are prop. logic models M L Q: Each subformula of ϕ is a state, plus,,... δ(ψ, M): depends on form of ψ:, if ψ in prop. logic and M = ψ, if ψ in prop. logic and M = ψ χ, if ψ is X (χ) and, if ψ is αuβ, δ(β, M) (δ(α, M) (αuβ)) Guttman ( WPI ) Büchi & LTL 18 Feb 10 8 / 10
Büchi Automata Representing LTL formula ϕ ϕ contains atomic formulas L Σ: Input letters are prop. logic models M L Q: Each subformula of ϕ is a state, plus,,... δ(ψ, M): depends on form of ψ:, if ψ in prop. logic and M = ψ, if ψ in prop. logic and M = ψ χ, if ψ is X (χ) and, if ψ is αuβ, δ(β, M) (δ(α, M) (αuβ)) F : {ψ Q : ψ = (αuβ)} Guttman ( WPI ) Büchi & LTL 18 Feb 10 8 / 10
Model Checking, 1: What? Suppose we are given: A Kripke structure K Represents a system An LTL formula ϕ Represents a specification correctness condition Guttman ( WPI ) Büchi & LTL 18 Feb 10 9 / 10
Model Checking, 1: What? Suppose we are given: A Kripke structure K Represents a system An LTL formula ϕ Represents a specification correctness condition Does every execution of K satisfy ϕ? Guttman ( WPI ) Büchi & LTL 18 Feb 10 9 / 10
Model Checking, 1: What? Suppose we are given: A Kripke structure K Represents a system An LTL formula ϕ Represents a specification correctness condition Does every execution of K satisfy ϕ? For every π over graph K, does π = ϕ hold? Guttman ( WPI ) Büchi & LTL 18 Feb 10 9 / 10
Model Checking, 2: How? Let α be an LTL formula over atoms L Let K = (S, I, T, L) be a finite Kripke structure with L(s) L α determines an automaton A Guttman ( WPI ) Büchi & LTL 18 Feb 10 10 / 10
Model Checking, 2: How? Let α be an LTL formula over atoms L Let K = (S, I, T, L) be a finite Kripke structure with L(s) L α determines an automaton A K determines a Büchi automaton B = S, Σ, δ, I, S where S = S {fail} Σ = 2 L, and δ(s, M) = {s T (s): L(s) = M} {fail: s = fail or L(s) M} Guttman ( WPI ) Büchi & LTL 18 Feb 10 10 / 10
Model Checking, 2: How? Let α be an LTL formula over atoms L Let K = (S, I, T, L) be a finite Kripke structure with L(s) L α determines an automaton A K determines a Büchi automaton B = S, Σ, δ, I, S where S = S {fail} Σ = 2 L, and? = lang(a) lang(b) δ(s, M) = {s T (s): L(s) = M} {fail: s = fail or L(s) M} Guttman ( WPI ) Büchi & LTL 18 Feb 10 10 / 10