Upload
others
View
15
Download
0
Embed Size (px)
Citation preview
SF - M2 SAR - 2017/2018
Rappels LTL et CTLNathalie Sznajder
UniversitƩ Pierre et Marie Curie, LIP6
SF - M2 SAR - 2017/2018
Les mƩthodes formelles
ā¢ Preuve assistĆ©e par ordinateur
ā¢ Test
ā¢ Model-Checking
SF - M2 SAR - 2017/2018
Model-CheckingIntroduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
systĆØme
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
spƩcification
SF - M2 SAR - 2017/2018
Est-ce que le
Model-CheckingIntroduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
systĆØme
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
spƩcification
satisfait ?
SF - M2 SAR - 2017/2018
Est-ce que le
Model-Checking
Figure 1: essai
blablabla
1
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
systĆØme
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
spƩcification
satisfait ?
modĆØle
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
SF - M2 SAR - 2017/2018
Est-ce que le
Model-Checking
Figure 1: essai
blablabla
1
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
systĆØme
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
spƩcification
satisfait ?
modĆØle
Figure 1: essai
blablabla'
1
formule
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
SF - M2 SAR - 2017/2018
Est-ce que le
Model-Checking
Figure 1: essai
blablabla
1
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
systĆØme
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
spƩcification
satisfait ?
modĆØle
Figure 1: essai
blablabla'
1
formule
ā§ ?algorithme de Model Checking
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
Introduction
Principles of model checking
Does
system
satisfy
specification
?
model
'
formula
?|=model-checker
Nathalie Bertrand Model checking VTS ā M2RI ā 2011 3/86
SF - M2 SAR - 2017/2018
ā¢ Soit M= (Q,T, A, q0, AP, l).
ā¢ On supposera que T est totale, i.e., chaque Ć©tat a au moins un successeur.
ā¢ On peut complĆ©ter une structure de Kripke : on rajoute un Ć©tat puits successeur des Ć©tats dead-lock.
Structure de Kripke
SF - M2 SAR - 2017/2018
ExƩcutions et traces
ā¢ Soit M=(Q,T, A, q0, AP, l). Une exĆ©cution de M est une sĆ©quence infinie r=q0a0q1a1q2a2... telle que (qi,ai,qi+1)āT, pour tout iā„0.
ā¢ On peut omettre lāĆ©tiquetage des transitions : r=q0q1q2...
ā¢ Une trace dāexĆ©cution de M est lāĆ©tiquetage dāune exĆ©cution: l(r)=l(q0)l(q1)l(q2)...
SF - M2 SAR - 2017/2018
Arbre dāexĆ©cutions dāune structure de Kripke
s0
s1 s2
s3
Figure 1: essai
blablablaĻ
āt Ā·(
requete ā ātā² ā„ t Ā· (reponse))
Ļ
1
s0, 0
s1, 1 s2, 1
s3, 2 s3, 2
s1, 3 s3, 3 s1, 3 s3, 3
......
. . .. .. . . .. .
.
2
SF - M2 SAR - 2017/2018
Arbre dāexĆ©cutions dāune structure de Kripke
ā¢ Correspond au Ā«dĆ©pliageĀ» de la structure de Kripke
ā¢ Sa racine est lāĆ©tat initial de la structure de Kripke
ā¢ Au niveau i, les fils dāun noeud sont les Ć©tats successeurs au niveau i+1
ā¢ La relation de transition est totale : lāarbre est infini
VFSR - M2 SAR - 2013/2014
1.SpƩcifications
SF - M2 SAR - 2017/2018
PropriĆ©tĆ©s sur les systĆØmes de transition (I)
ā¢ Invariance : tous les Ć©tats du systĆØme vĆ©rifient une certaine propriĆ©tĆ©
ā¢ SĆ»retĆ© : quelque chose de mauvais nāarrive jamais
ā¢ AccessibilitĆ© : un Ć©tat donnĆ© est accessible depuis lāĆ©tat initial
SF - M2 SAR - 2017/2018
PropriĆ©tĆ©s sur les systĆØmes de transition (II)
ā¢ VivacitĆ© : Quelque chose de Ā«bonĀ» finira par arriver
ā¢ EquitĆ© : Quelque chose se produira infiniment souvent
SF - M2 SAR - 2017/2018
Logiques temporelles
ā¢ Permettent dāexprimer propriĆ©tĆ©s sur sĆ©quences dāobservations
ā¢ Utilisation de connecteurs temporels et de quantificateurs sur les chemins
SF - M2 SAR - 2017/2018
Logiques temporelles : pourquoi?
ā¢ On pourrait utiliser logique du premier ordre.
ā¢ Exemple : Ā«toute requĆŖte sera un jour satisfaiteĀ»
Figure 1: essai
blablabla'
8t Ā·ļæ½requete ! 9t0 ļæ½ t Ā· (reponse)
ļæ½
1
SF - M2 SAR - 2017/2018
Logiques temporelles : pourquoi?
ā¢ On pourrait utiliser logique du premier ordre.
ā¢ Exemple : Ā«toute requĆŖte sera un jour satisfaiteĀ»Difficile Ć Ć©crire
/comprendre
VĆ©rification peu efficace
Figure 1: essai
blablabla'
8t Ā·ļæ½requete ! 9t0 ļæ½ t Ā· (reponse)
ļæ½
1
SF - M2 SAR - 2017/2018
Logiques temporelles
ā¢ Pas de variable (instants implicites), mais modalitĆ©s.
ā¢ Temporel ā temporisĆ© : logiques temporelles ne quantifient pas Ć©coulement du temps.
SF - M2 SAR - 2017/2018
Logiques temporelles linƩaires ou arborescentes
ā¢ 2 approches :
ā¢ temps linĆ©aire : propriĆ©tĆ©s des sĆ©quences dāexĆ©cutions (futur dĆ©terminĆ©)
ā¢ temps arborescent : propriĆ©tĆ©s de lā arbre dāexĆ©cutions (tous les futurs possibles)
VFSR - M2 SAR - 2013/2014
2. La logique LTL
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
ā¢ ModĆØle des formules : une trace dāexĆ©cution infinie.
ā¢ t, i ā§ Ļ ssi la formule Ļ est vĆ©rifiĆ©e Ć la position i de la trace.
ā¢ DĆ©fini inductivement sur la formule
[Pnueli 77]
SF - M2 SAR - 2017/2018
ā¢ Rappel : une trace dāexĆ©cution ā£ exĆ©cution dans laquelle seul lāĆ©tiquetage des Ć©tats est visible
ā¢ ā cāest un mot (infini) sur lāalphabet 2AP.
ā¢ Soit t une trace, on note t(i) la Ā«lettreĀ» Ć la position iā„0, i.e. lāensemble des propositions atomiques vraies.
Logique temporelle linƩaire : LTL
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
p p,q q,rq p,rp :
p pp
...
t,i ā§ p ssi pāt(i)
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
XĻ : ...
XĻ
q,r p,q q,rp p,r ...Exemples : Xp
Xp p
q p q,rq,r p,r ...X(Xp)
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
XĻ : ...
XĻ
q,r p,q q,rp p,r ...Exemples : Xp
Xp p
q p q,rq,r p,r ...
p
X(Xp) p
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
XĻ : ...
XĻ
q,r p,q q,rp p,r ...Exemples : Xp
Xp p
q p q,rq,r p,r ...
Xp p
X(Xp) q,r p
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
XĻ : ...
XĻ
q,r p,q q,rp p,r ...Exemples : Xp
Xp p
q p q,rq,r p,r ...
X(Xp) Xp p
X(Xp) q,rq p
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
XĻ : ...
XĻ
t,i ā§ XĻ ssi t,i+1ā§Ļ
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
FĻ : ...
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
FĻ : ...
FĻ
FĻ
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
FĻ : ...
FĻ FĻ
FĻ
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
FĻ : ...
FĻ FĻ FĻ
FĻ
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
FĻ : ...
FĻ FĻ FĻ
FĻ
t,i ā§ FĻ ssi il existe jā„i tel que t,jā§Ļ
Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
GĻ : ...
Ļ Ļ Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
GĻ : ...
GĻ Ļ Ļ Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
GĻ : ...
GĻ
t,i ā§ GĻ ssi pour tout jā„i, t,jā§Ļ
Ļ Ļ Ļ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
GĻ : ...
GĻ
t,i ā§ GĻ ssi pour tout jā„i, t,jā§Ļ
Ļ Ļ ĻGĻ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
GĻ : ...
GĻ
t,i ā§ GĻ ssi pour tout jā„i, t,jā§Ļ
Ļ Ļ ĻGĻ GĻ
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
Ļ1UĻ2: ...
Ļ1 Ļ1 Ļ2Ļ1Ļ1
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
Ļ1UĻ2: ...
Ļ1 Ļ1 Ļ2
Ļ1UĻ2
Ļ1Ļ1
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
Ļ1UĻ2: ...
t,i ā§ Ļ1UĻ2 ssi il existe jā„i, t,j ā§Ļ2 et, pour tout iā¤k<j, t,k ā§ Ļ1
Ļ1 Ļ1 Ļ2
Ļ1UĻ2
Ļ1Ļ1
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
Ļ::= pāAP | Ā¬Ļ | ĻāØĻ|XĻ| FĻ| GĻ| ĻUĻ
t,i ā§ p ssi pāt(i)t,i ā§ Ā¬Ļ ssi t,i ā Ļt,i ā§ Ļ1āØĻ2 ssi t,i ā§ Ļ1 ou t,i ā§ Ļ2
t,i ā§ XĻ ssi t,i+1ā§Ļt,i ā§ FĻ ssi il existe jā„i tel que t,jā§Ļt,i ā§ GĻ ssi pour tout jā„i, t,jā§Ļt,i ā§ Ļ1UĻ2 ssi il existe jā„i, t,j ā§Ļ2 et, pour tout iā¤k<j, t,k ā§ Ļ1
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
Ļ::= pāAP | Ā¬Ļ | ĻāØĻ|XĻ| FĻ| GĻ| ĻUĻ
ā¤ā£pāØĀ¬p, pour pāAP quelconqueā„ā£Ā¬ā¤Ļ1ā§Ļ2 ā£Ā¬(Ā¬Ļ1āØĀ¬Ļ2)
Ļ1āĻ2 ā£ Ā¬Ļ1āØĻ2
SF - M2 SAR - 2017/2018
Logique temporelle linƩaire : LTL
En fait, FĻ et GĻ macros aussi : ā¢ FĻā£ā¤UĻā¢ GĻā£ Ā¬F(Ā¬Ļ)
Exercice : vƩrifier.
SF - M2 SAR - 2017/2018
ā¢ Autres macros utiles :
ā¢ (Weak until) Ļ1WĻ2 ā£ GĻ1 āØ Ļ1UĻ2
ā¢ (Release) Ļ1RĻ2 ā£ Ļ2 W (Ļ1ā§Ļ2) ā£ GĻ2 āØ Ļ2U (Ļ1ā§Ļ2)
Logique temporelle linƩaire : LTL
Ļ::= pāAP | Ā¬Ļ | ĻāØĻ|XĻ| ĻUĻ
SF - M2 SAR - 2017/2018
ā¢ AccessibilitĆ© : F (x=0)
ā¢ Invariance : G Ā¬(x=0)
ā¢ VivacitĆ© : G(request ā F response)
ā¢ EquitĆ© forte : GF enabled ā GF scheduled
ā¢ EquitĆ© faible : FG enabled ā GF scheduled
ā¢ RelĆ¢chement de contrainte : reset R alarm
LTL : Exemples
VFSR - M2 SAR - 2013/2014
3. La logique CTL
SF - M2 SAR - 2017/2018
Exprimer la possibilitĆ©ā¢ La propriĆ©tĆ© Ā«Ć chaque fois que paid est
vĆ©rifiĆ©, il est possible dāobtenir une biĆØreĀ» nāest pas exprimable en LTL!
Transition Systems 21
the likelihood with which a certain transition is selected. Similarly, when the set of initialstates consists of more than one state, the start state is selected nondeterministically.
The labeling function L relates a set L(s) ā 2AP of atomic propositions to any state s.1
L(s) intuitively stands for exactly those atomic propositions a ā AP which are satisfiedby state s. Given that Ī¦ is a propositional logic formula, then s satisfies the formula Ī¦ ifthe evaluation induced by L(s) makes the formula Ī¦ true; that is:
s |= Ī¦ iff L(s) |= Ī¦.
(Basic principles of propositional logic are explained in Appendix A.3, see page 915 ff.)
Example 2.2. Beverage Vending Machine
We consider an (somewhat foolish) example, which has been established as standard in thefield of process calculi. The transition system in Figure 2.1 models a preliminary designof a beverage vending machine. The machine can either deliver beer or soda. States arerepresented by ovals and transitions by labeled edges. State names are depicted inside theovals. Initial states are indicated by having an incoming arrow without source.
pay
selectsoda beer
insert coin
ĻĻ
get soda get beer
Figure 2.1: A transition system of a simple beverage vending machine.
The state space is S = { pay , select , soda , beer }. The set of initial states consists ofonly one state, i.e., I = { pay }. The (user) action insert coin denotes the insertion of acoin, while the (machine) actions get soda and get beer denote the delivery of soda andbeer, respectively. Transitions of which the action label is not of further interest here,e.g., as it denotes some internal activity of the beverage machine, are all denoted by thedistinguished action symbol Ļ . We have:
Act = { insert coin , get soda , get beer , Ļ }.
Some example transitions are:
pay insert coināāāāāāāāā select and beer get beerāāāāāāā pay .
1Recall that 2AP denotes the power set of AP.
{paid, soda}
{paid, beer}
{paid}
n2 w2 c2request2
release
pay
select selectā
soda beer
insert coin
insert coin
Ļ Ļ
get soda get beer
3
{paid, beer}
{paid} {paid}
{paid, soda}
Les deux systĆØmes vĆ©rifient les mĆŖmes propriĆ©tĆ©s LTL!!
SF - M2 SAR - 2017/2018
Computational Tree Logic : CTL
ā¢ ModĆØle des formules : Ć©tat de lāarbre dāexĆ©cutions infini.
ā¢ M,s ā§ Ļ ssi la formule Ļ est vĆ©rifiĆ©e Ć lāĆ©tat s de la structure de Kripke M.
ā¢ On note S(Ļ) lāensemble des Ć©tats s t.q. M,s ā§ Ļ
ā¢ Ajout de quantificateurs sur les chemins dans lāarbre : E et A.
ā¢ DĆ©fini inductivement sur la formule.
[Clarke, Emerson 81]
SF - M2 SAR - 2017/2018
CTL: syntaxe et sƩmantique
p
q,r p
r,s p,q q s
s ā§ p ssi pāl(s)
SF - M2 SAR - 2017/2018
CTL: syntaxe et sƩmantique
s ā§ EXĻ ssi il existe sā, successeur de s t.q. sā ā§Ļ
EXĻ
Ļ
SF - M2 SAR - 2017/2018
CTL: syntaxe et sƩmantique
s ā§ AXĻ ssi pour tout sā, successeur de s, sā ā§Ļ
AXĻ
ĻĻ
SF - M2 SAR - 2017/2018
CTL: syntaxe et sƩmantique
s ā§ EĻUĻā ssi il existe une exĆ©cution s0s1...sk telle que s0=s, sk ā§Ļā et pour tout 0ā¤i<k, si ā§Ļ.
EĻUĻā
Ļ
Ļ
Ļā
SF - M2 SAR - 2017/2018
CTL: syntaxe et sƩmantique
s ā§ AĻUĻā ssi pour toute exĆ©cution s0s1... telle que s0=s, ā k t.q. sk
ā§Ļā et pour tout 0ā¤i<k, si ā§Ļ.
AĻUĻā
Ļ
Ļ
Ļā
Ļā
Ļā
Ļā
Ļ
SF - M2 SAR - 2017/2018
CTL: syntaxe et sƩmantique
Ļ::= pāAP | Ā¬Ļ | ĻāØĻ|EXĻ| AXĻ| EĻUĻ | AĻUĻ
s ā§ p ssi pāl(s)s ā§ Ā¬Ļ ssi s ā Ļs ā§ Ļ1āØĻ2 ssi s ā§ Ļ1 ou s ā§ Ļ2
s ā§ EXĻ ssi il existe sā, successeur de s, t.q. sāā§Ļ s ā§ AXĻ ssi sā, pour tout sā, successeur de s, sāā§Ļs ā§ EĻ1UĻ2 ssi il existe une exĆ©cution s0s1...sk tel que s0=s, sk ā§Ļ2 et pour tout 0ā¤iā¤k, si ā§Ļ1.s ā§ AĻ1UĻ2 ssi pour toute exĆ©cution s0s1... telle que s0=s, il existe k t.q. sk ā§Ļ2 et pour tout 0ā¤iā¤k, si ā§Ļ1.
SF - M2 SAR - 2017/2018
CTL : macros
ā¢ EFĻ ā£ Eā¤UĻ
ā¢ AFĻā£Aā¤UĻ
ā¢ EGĻā£Ā¬AFĀ¬Ļ
ā¢ AGĻā£Ā¬EFĀ¬Ļ
SF - M2 SAR - 2017/2018
CTL : Equivalences de formules
ā¢ AXĻ=Ā¬EXĀ¬Ļ
ā¢ AĻUĻā=Ā¬EĀ¬(ĻUĻā)=Ā¬E(GĀ¬ĻāāØĀ¬ĻāU(Ā¬Ļā§Ā¬Ļā))=Ā¬EGĀ¬Ļāā§Ā¬E(Ā¬ĻāU(Ā¬Ļā§Ā¬Ļā))
SF - M2 SAR - 2017/2018
CTL : Lois dāexpansionā¢ AĻUĻā=ĻāāØ(Ļā§AX(AĻUĻā))
ā¢ AFĻ=ĻāØ(AXAFĻ)
ā¢ AGĻ=Ļā§AXAGĻ
ā¢ EĻUĻā=ĻāāØ(Ļā§EXE(ĻUĻā))
ā¢ EFĻ=ĻāØEXEFĻ
ā¢ EGĻ=Ļā§EXEGĻ
SF - M2 SAR - 2017/2018
CTL : lois distributives
ā¢ AG(Ļā§Ļā)=AGĻā§AGĻā
ā¢ EF(ĻāØĻā)=EFĻāØEFĻā
SF - M2 SAR - 2017/2018
Exemples
ā¢ AccessibilitĆ© : EF(x=0)
ā¢ Invariance : AGĀ¬(x=0)
ā¢ VivacitĆ© : AGAF(active)
SF - M2 SAR - 2017/2018
Exercice
61/71
CTL (Clarke & Emerson 81)
Example
1 2 3 4
5 6 7 8
q p, q q r
p, r p, r p, q
Compute
S(EX p) = {1, 2, 3, 5, 6}
S(AX p) = {3, 6}
S(EF p) = {1, 2, 3, 4, 5, 6, 7, 8}
S(AF p) = {2, 3, 5, 6, 7}
S(E q U r) =
S(A q U r) =
S(EXp)? S(AXp)?S(EFp)? S(AFp)?S(EqUr)?S(AqUr)?
SF - M2 SAR - 2017/2018
Exercice
Exercises 433
6.11 Exercises
Exercise 6.1. Consider the following transition system over AP = { b, g, r, y }:
4
{ r }
{ y }{ g }
{ b }
1 2 3
The following atomic propositions are used: r (red), y (yellow), g (green), and b (black). Themodel is intended to describe a traffic light that is able to blink yellow. You are requested toindicate for each of the following CTL formulae the set of states for which these formulae hold:
(a) āā¦ y (g) ā" Ā¬ g
(b) ā" y (h) ā(b U Ā¬ b)
(c) ā" āā¦ y (i) ā(b U Ā¬ b)
(d) āā¦ g (j) ā(Ā¬ b Uāā¦ b)
(e) āā¦ g (k) ā(g U ā(y U r))
(f) ā" g (l) ā(Ā¬ b U b)
Exercise 6.2. Consider the following CTL formulae and the transition system TS outlined onthe right:
Ī¦1 = ā(a U b) āØ āā (ā" b)
Ī¦2 = ā" ā(a U b)
Ī¦3 = (a ā§ b) ā ā" āā ā(b W a)
Ī¦4 = (ā" āā¦Ī¦3)
s0
ā s4
{ b }
s1
{ a }s2
{ a, b }s3
{ b }Determine the satisfaction sets Sat(Ī¦i) and decide whether TS |= Ī¦i (1 # i # 4).
Exercise 6.3. Which of the following assertions are correct? Provide a proof or a counterexample.
(a) If s |= ā" a, then s |= ā" a.
(b) If s |= ā" a, then s |= ā" a.
(c) If s |= āā¦ a āØ āā¦ b, then s |= āā¦ (a āØ b).
(d) If s |= āā¦ (a āØ b), then s |= āā¦ a āØ āā¦ b.
Ļ = A(aUb)āØEXEGb
Ļ=AG(A(aUb))
Mā§Ļ?
SF - M2 SAR - 2017/2018
Comparaison LTL/CTL
ā¢ La formule CTL AF(aā§EXa) nāest pas exprimable en LTL
ā¢ La formule LTL FG request āGF response nāest pas exprimable en CTL
ā¢ LTL et CTL incomparables!
ā¢ LTL et CTL inclus dans CTL*
SPECIF - M1 SAR - 2016/2017
Comparaison LTL/CTL
Soit Ļ une formule CTL et Ļ une formule LTL Alors Ļ est Ć©quivalent Ć Ļ si, pour toute
structure de Kripke M, M ā§ Ļ si et seulement si M ā§ Éø. On note Ļ ā£Éø.
SPECIF - M1 SAR - 2016/2017
Comparaison LTL/CTL
ā¢ CTL ne sait pas exprimer FGp:
ExpressivitƩ : LTL vs. CTL
Pouvoir expressif incomparable de LTL et CTLI impossibilitĆ© dāexprimer les propriĆ©tĆ©s existentielles en LTLI CTL ne sait pas exprimer F G p
q0
p ~p p
q1 q2
K:
K |= F G p K 6|= AF AG pI problĆØme similaire : Ć©quitĆ© forte
Choix de la logiqueI en fonction des besoins du problĆØme . . .I . . . et des outils qui conviennent
Logiques plus expressives : CTLā¤, Āµ-calcul
Stephan Merz (LORIA) Tutoriel Model Checking ETR 05 23 / 37
Ce nāest pas une preuveā¦
SPECIF - M1 SAR - 2016/2017
Comparaison LTL/CTL
ā¢ F(Ļ1āØĻ2) = FĻ1 āØ FĻ2
ā¢ EF(Ļ1āØĻ2) = EFĻ1 āØ EFĻ2
ā¢ MAIS : AF(Ļ1āØĻ2) ā AFĻ1 āØ AFĻ2
SPECIF - M1 SAR - 2016/2017
Comparaison LTL/CTL332 Computation Tree Logic
{ a } { b }
sā²ā² sā²
s
For each path that starts in state s we have that ā¦ (a āØ b) holds, so s |= āā¦ (a āØ b). Thisfollows directly from the fact that each path visits either state sā² or state sā²ā² eventually,and sā² |= a āØ b and the same applies to sā²ā². However, state s does not satisfy āā¦ a āØ āā¦ b.For instance, path s (sā²ā²)Ļ |= ā¦ a but s (sā²ā²)Ļ Ģø|= ā¦ b. Thus, s Ģø|= āā¦ b. By a similar reasoningapplied to path s (sā²)Ļ it follows that s Ģø|= āā¦ a. Thus, s Ģø|= āā¦ a āØ āā¦ b. Stated in words,not all computations that start in state s eventually reach an a-state nor do they alleventually reach a b-state.
6.2.4 Normal Forms for CTL
The duality law for āāĪ¦ shows that āā can be treated as a derived operator of āā .That is to say, the basic operators āā , āU, and āU would have been sufficient to define thesyntax of CTL. The following theorem demonstrates that we can even omit the universalpath quantifier and define all temporal modalities in CTL using the basic operators āā ,āU, and ā" .
Definition 6.13. Existential Normal Form (for CTL)
For a ā AP, the set of CTL state formulae in existential normal form (ENF, for short) isgiven by
Ī¦ ::= trueā£ā£ā£ a
ā£ā£ā£ Ī¦1 ā§Ī¦2
ā£ā£ā£ Ā¬Ī¦ā£ā£ā£ āāĪ¦
ā£ā£ā£ ā(Ī¦1 UĪ¦2)ā£ā£ā£ ā" Ī¦.
Theorem 6.14. Existential Normal Form for CTL
For each CTL formula there exists an equivalent CTL formula in ENF.
M,sā§ AF(aāØb) M,sā AF aāØ AF b