BRICS R S-99-32 Aceto & L ar oussinie: Is y o ur Model C heck er on T ime?
BRICS
Basic Research in Computer Science
Is your Model Checker on Time?
On the Complexity of Model Checking for Timed Modal Logics
Luca Aceto
Franc¸ois Laroussinie
BRICS Report Series RS-99-32
ISSN 0909-0878 October 1999
Copyright c 1999, Luca Aceto & Franc¸ois Laroussinie.
BRICS, Department of Computer Science University of Aarhus. All rights reserved.
Reproduction of all or part of this work is permitted for educational or research use on condition that this copyright notice is included in any copy.
See back inner page for a list of recent BRICS Report Series publications.
Copies may be obtained by contacting:
BRICS
Department of Computer Science University of Aarhus
Ny Munkegade, building 540 DK–8000 Aarhus C
Denmark
Telephone: +45 8942 3360 Telefax: +45 8942 3255 Internet: BRICS@brics.dk
BRICS publications are in general accessible through the World Wide Web and anonymous FTP through these URLs:
http://www.brics.dk ftp://ftp.brics.dk
This document in subdirectory RS/99/32/
OntheComplexity ofModelCheckingforTimedModalLogics
LucaAceto
1
andFrançoisLaroussinie
2
1
BRICS
? ? ?
,DepartmentofComputerScience,AalborgUniversity,
FredrikBajersVej7-E,DK-9220AalborgØ,Denmark.
Email:luca@cs.auc.dk, Fax:+4598159889
2
LaboratoireSpécication etVérication,CNRSUMR8643,
ENSdeCachan,61av.duPr.Wilson,94235 Cachan,France.
Email:fl@lsv.ens-cachan.fr,Fax:+33147402464
Abstract. Thispaperstudiesthestructuralcomplexityofmodelcheck-
ingfor(variationson)thespecicationformalismsusedinthetoolsCMC
andUppaal, and fragmentsof atimedalternation-free
µ
-calculus.Foreachofthelogicswestudy,wecharacterizethecomputationalcomplexity
ofmodelchecking,as wellas itsspecication and programcomplexity,
usingtimedautomataasoursystemmodel.
1 Introduction
Theextensionofthemodelcheckingparadigmtothespecicationandverica-
tionofreal-timesystemshasbeenthoroughlystudiedinthelastfewyears.This
extensiveresearcheorthasled to thedevelopmentof specicationlogics that
extend standard untimed formalisms with the quantitative analysis of timing
constraints(see,e.g.,[4,15,18]),andtoimportanttheoreticalresultssettingthe
limitsof decidabilityformodelchecking.This theoryis now embodied in veri-
cation toolslikeHyTech [23],Kronos[24] and Uppaal[20],which havebeen
successfullyappliedto thevericationofrealsizedsystems.
The successful application of the aforementioned verication tools to the
analysis of realistic systems indicates that automatic verication of real-time,
embedded software may be feasiblein practice.However, despitemanyimpor-
tant theoreticalresultspresentedin op.cit.,theliteratureis lackingacompre-
hensive analysis of the structural complexity of model checking for real-time
logics.Intheuntimedcase, modelcheckingalgorithmswith apolynomialtime
complexity,andoftensmallspacerequirements,havebeendevelopedforseveral
branchingtimetemporallogics[8,9].Inthetimedcase,mostofthemodelcheck-
ing problems considered in theliterature are PSPACE-hard [3,10,15]. Clearly
thequantitativeanalysisoftimingconstraintsincreasesthecomplexityofmodel
checking,butitisinterestingtoanalyzepreciselyinwhichcasesthiscomplexity
blow-upoccurs.Intheuntimedcase,severalpapers(see,e.g.,[13,22,11])study
indetailtheeectofthetemporaloperators,thenumberofatomicpropositions
? ? ?
BasicResearchinComputerScience.
a better understanding of the complexity issue. Here,among other things, we
addressthe samekind of problem for thetimed case:what happensif time is
insertedeither onlyin themodel oronlyin theformula?Andwhat happensif
weuselessexpressivelogicswithrestrictedoperators?
Weconsiderseveraltimedmodallogics:L
ν
hasbeenintroducedin[18],andisthespecicationlanguageusedinthetoolCMC[17];
L s
isafragmentofLν
whichhasbeenproposedin[19]inordertoimprovetheeciencyofmodelcheckingin
practice;SBLL[2] and
L ∀ S
[1] havebeenintroducedfor theirpropertiesw.r.t.thetestingtimedautomatonmethodthat iscurrentlyusedinvericationtools
likeUppaaltocheckforpropertiesotherthanplainreachabilityones.
Foreachofthesepropertylanguages,westudythecomputationalcomplexity
ofmodelchecking,usingtimedautomata[5]asoursystemmodel.Asarguedby
LichtensteinandPnueli[21],thecomplexityofthemodelcheckingproblemcan
bemeasuredinthreedierentways.First,onecanxthespecicationandmea-
surethecomplexityasafunction of thesize oftheprogrambeingveried(the
programcomplexitymeasure). Secondly, onecanxthe programand measure
the complexity as afunction of the size of the specication (the specication
complexity measure). Finally, the combined complexity of the model checking
problemismeasuredasafunctionofthesizeofboththeprogramandthespec-
ication.Inthispaperweoercomplexityresultsforthesethreedierentviews
ofthemodelcheckingproblemforthelogicsweconsider.Insodoing,wegivean
a posteriori justication, couched in complexity-theoretic arguments, for some
of the folkbeliefs in the areaof model checkingfor real-time systems,and for
someofthechoicesmadebydevelopersofreal-timevericationtools.
Outline of the Main Results. We beginby analyzing the complexity of model
checking for L
µ,ν
, a timed alternation-free modalµ
-calculus (AFMC). In theuntimed setting, such afragment of the modal
µ
-calculus plays an importantroleasaspecicationformalismbecauseitisfairlyexpressiveanditsrestricted
syntaxmakesthesymbolicevaluationofexpressionsverysimple(moreprecisely,
linearbothinthesizeofthemodelandthespecication).Inthereal-timesetting,
weshowthatthecomplexityofmodelcheckingforthetimedAFMC,andforits
sublogicL
ν
,isEXPTIME-complete,asareboththeprogramcomplexityandthe specicationcomplexity.(Perhapssurprisingly,themodelcheckingproblemforL
ν
andafortioriforthetimedAFMCis EXPTIME-complete evenifwexthemodeltobetheinactiveprocesswithoutclocks,
nil
.)Wealsoprovethatthemodel checking problemfor L
ν
withoutgreatestxpointsessentially, atimed versionofHennessy-Milnerlogic[14]isPSPACE-complete.It isinstructiveto compare the aboveresultswith similar ones for theun-
timed alternation-free
µ
-calculus.Aspreviouslymentioned,forsuchaprogramlogic,wehavealgorithmsformodelcheckingthatrunintimelinearbothinthe
size of the program and of the specication. Moreover,boththe program and
the specication complexities are P-complete [6,12]. Note, however, that the
program complexity ofthe alternation-free
µ
-calculusfor concurrent programsis EXPTIME-complete [6],and this matchesexactlythecomplexity resultswe
L
µ,ν ,
Lν
EXPTIME-complete EXPTIME-completeEXPTIME-completeL s , SBLL, L ∀ S
PSPACE-complete PSPACE-complete PSPACE-complete L− ν
PSPACE-complete P PSPACE-completeL − s
coNP-complete P coNP-completeSBLL − , L − ∀ S
PSPACE-complete PSPACE-complete coNP-completeTable1:OverviewoftheResults
oerfor L
µ,ν
modelchecking.It isalso interestingtonote that thecomplexity of CTL model checkingand reachabilityfor concurrentprograms is PSPACE-complete [6], matching the complexity of model checking for TCTL[4] and of
reachability in timed automata, respectively. These results seem to provide a
mathematical groundingto thefolk belief that clocks actlikeconcurrentpro-
grams,andthatincreasingthenumberofclockscorrespondstoaddingparallel
components.
Wethen proceedtodevelopathoroughanalysisof thecomplexityofmodel
checkingforall theother timed modal property languagesthat wehavefound
in the literature. In each case, we oer results pinpointing the program, the
specicationaswellasthecombinedcomplexityofmodelcheckingfortheprop-
erty languageswith and withoutxpoints.An overviewof theresults wehave
obtainedis presentedin Table1, where
L −
denotes thexpointfree fragmentof
L
. Here wejust wish to point outthat the model checkingproblem for thepropertylanguage
L s
isPSPACE-complete,nomatterwhetherthecomplexityis measuredwithrespecttothesizeoftheprogram,ofthespecicationorofboth.Inlight ofthe aforementionedresults,and assumingthat PSPACE is dierent
fromEXPTIME, themodelcheckingproblemfor
L s
hasalowercomputational complexitythanthat forLν
.Ourresultsthusoeracomplexity-theoreticjusti- cation fortheclaims in [19].Thesourceof thelowercomplexityderivesfromtheobservationthatthemodelcheckingproblemfor
L s
,unlikethatforLν
,canbe reducedin polynomial time to reachabilitycheckingin timed automataa
problemwhosePSPACE-completenesswasshownin [5].
2 Basic denitions
We begin bybriey reviewinga variationonthe timed automatonmodel pro-
posedbyAlurandDill[5]andthepropertylanguagesthatwillbeusedin this
study.
TimedAutomata. Let Act be anite set ofactions,and let
N
andR ≥ 0
denotethesetsofnaturalandnon-negativerealnumbers,respectively.Wewrite
D
forthesetofdelayactions
{ (d) | d ∈ R ≥ 0 }
.Let
C
beasetofclocks.WeuseB (C)
todenotethesetofbooleanexpressions overatomic formulaeof theformx ∼ p
andx − y ∼ p
, withx, y ∈ C
,p ∈ N
,and
∼∈ {<, >, =}
. Moreover we writeB k (C)
for the restriction ofB(C)
toexpressions where the integer constants belong to
{0, . . . , k}
. Expressions inB(C)
areinterpretedoverthecollectionoftimeassignments.Atimeassignment,orvaluation,
v
forC
isafunctionfromC
toR ≥ 0
.WewriteR C ≥ 0
forthecollectionofvaluationsfor
C
.Giveng ∈ B (C)
andatimeassignmentv
,thebooleanvalueg(v)
describes whetherg
is satisedbyv
or not.Foreverytime assignmentv
and
d ∈ R ≥ 0
,weusev + d
todenotethetimeassignmentwhichmapseachclockx ∈ C
tothevaluev(x) +d
.ForeveryC 0 ⊆ C
,[C 0 → 0]v
denotestheassignmentfor
C
whichmaps eachclockinC 0
to thevalue0
andagreeswithv
overC\C 0
.Denition1. A timed automaton(TA) isa quintuple
A = h
Act, N, n 0 , C, Ei
where
N
isanitesetofnodes,n 0
istheinitialnode,C
isanitesetofclocks,and
E ⊆ N×B(C)×
Act×2 C ×N
isasetofedges.Thetuplee = hn, g, a, r, n 0 i ∈ E
stands for an edge from node
n
to noden 0
with actiona
, wherer
denotes thesetof clocks tobereset to
0
andg
isthe enabling condition(orguard). WeuseMCst
(A)
todenotethe largestintegerconstantoccurring inthe guardsofA
.A state(or conguration)of atimed automaton
A
is apair(n, v)
wheren
isanodeof
A
andv
isatimeassignmentforC
.TheinitialstateofA
is(n 0 , [C → 0])
where
n 0
istheinitialnode ofA
, and[C → 0]
isthetimeassignmentmappingallclocksin
C
to0
.TheoperationalsemanticsofatimedautomatonA
isgivenbytheTimed LabelledTransitionSystem(TLTS)
T A = hS A ,
Act∪ D, s 0 , −→i
,where
S A
is the set of statesofA
,s 0
is theinitial stateofA
, and−→
is thetransitionrelationdened asfollows:
(n, v) −→ a (n 0 , v 0 )
i∃hn, g, a, r, n 0 i ∈ E. g(v) = tt ∧ v 0 = [r → 0]v (n, v) −→ (d) (n 0 , v 0 )
in = n 0
andv 0 = v + d
Remark 1. NotethatwecouldconsiderextendedTAswhereweassignaninvari-
ant(i.e.adownwardclosedclockconstraint)toeachnodetoavoidexcessivetime
delays.AlltheresultspresentedherewillstillholdforextendedTAs.Notethat,
givenacomplexityclass
C
,havingaC
-hardnessresultfor(simple)TAsimpliesthe samefor extended TAs, while havinga
C
membership resultfor extendedTAsimpliesthesameforTAs.
Thespecication languages. WenowdeneL
µ,ν
atimedalternation-freemodalµ
-calculus.Denition2. Let
K
beanitesetofclocks,Idasetofidentiers.ThesetLµ,ν
of formulaeover
K
andId isgeneratedbythe followinggrammar:L
µ,ν 3 ψ , ϕ ::= g | ϕ ∧ ψ | ϕ ∨ ψ | hai ϕ | [a] ϕ | ∃∃ϕ | ∀∀ϕ
| K 0
inϕ |
max(X, ϕ) |
min(X, ϕ) | X
where
a ∈
Act,g ∈ B(K)
,K 0 ⊆ K
andX ∈
Id. Moreover, each occurrenceof an identier
X
ina formula has tobe boundby a min(X, ϕ)
(or max(X, ϕ)
)operator, and it cannot occur in a
ϕ
-subformula of the form max(X 0 , ψ )
(resp.min
(X 0 , ψ )
).(This restriction correspondstothe alternation-free property.)New operators like
tt
,ff
,g ⇒ ψ
(read `g
impliesψ
') can be easily dened.LetMCst
(ϕ)
bethelargestintegerconstantoccurringintheclockconstraintsinϕ
. Given aTAA
, weinterpretformulaein Lµ,ν
w.r.t.extended congurations(n, v, u) | = [a] ϕ
i∀ (n 0 , v 0 ). (n, v) −→ a (n 0 , v 0 ) ⇒ (n 0 , v 0 , u) | = ϕ (n, v, u) | = ∀∀ ϕ
i∀ d ∈ R ≥ 0 , (n, v + d, u + d) | = ϕ
(n, v, u) | = g
ig(u) = tt
(n, v, u) | = K 0
inϕ
i(n, v, [K 0 → 0]u) | = ϕ
(n, v, u) | =
max(X, ϕ)
i(n, v, u)
belongstothelargestsolutionofX = ϕ
Table2:SemanticsofL
µ,ν
.(n, v, u)
, where(n, v)
is acongurationofA
andu
isatime assignmentforK
.Whereastheclassicalmodaloperators
hai
and[a]
dealwithactiontransitions, theoperator∃∃
(resp.∀∀
)denotesexistential(resp.universal)quanticationover delay transitions. The clocks inK
are so-called formula clocks; they increasesynchronouslywiththe automataclocks, andthey areused asstopwatchesfor
measuringthetimeelapsingbetweenstatesofthesystem.Theformula
K 0
inϕ
initializestheset offormulaclocks
K 0
to0
inϕ
.Theconstraintsg
areused tocomparethevalueofformulaclocksin thecurrentextendedcongurationwith
an integer value. Finally, an extended conguration satises max
(Z, ϕ)
(resp.(
min(Z, ϕ)
) if it belongs to the largest (resp. least) solution of the equationZ = ϕ
overthecompletelatticeofsetsofextendedcongurations.Theexistence of these solutions is guaranteed by standardxpoint theory. The semanticsofL
µ,ν
is sketched in Table2.(The operatorshai
and∃∃
are dualsof[a]
and∀∀
;the semanticsof boolean operators is omitted.) The full formal details of the
semanticsarestandard[16].
As anexample of aproperty that can be expressed in L
µ,ν
using xpointsandclockconstraints,consider theformula
max
X,
[b]{x}
in∃∃(hci tt ∧ x ≤ 3)
∧ [a]X ∧ ∀∀X .
This formula expresses the fact that, in everystate that is reachable by per-
forming
a
-actionsanddelays,everyoccurrenceofab
-actioncanbefollowedbya
c
-actionwithin3
timeunits.Fragments of L
µ,ν
. The logic Lν
[18] is the fragment of Lµ,ν
in which onlygreatest xpointsare allowed.The logic
L s [19]
isthe fragment of Lν
withouttheexistentialmodalities
hai
and∃∃
, andwhereonlyarestricteddisjunctionof theformg ∨ ϕ
(withg ∈ B(K)
)isallowed.Thepropertylanguages
SBLL
andL ∀ S
extendL s
, anduseaslightlydierentkindofTAswhere(1)
U
isasubsetofActs.t.anyedgelabeledwitha ∈ U
hastheguard
tt
and(2)Actcontainsthelabelτ
usedfortheinternalactionofautomata.Moreovertheyare basedondierent semantics(denoted by
`
)compared withL
ν
andL s
: a formulaϕ
holds for(n, v, u)
only ifϕ
holds for every(n 0 , v 0 , u)
with
(n 0 , v 0 )
reachablefrom(n, v)
in zero or moreτ
-transitions. Forexample,(n, v, u) ` [a]ϕ
iforevery(n, v) −→ τ ∗ (n 0 , v 0 )
wehavethat(n 0 , v 0 ) −→ a (n 00 , v 00 )
implies
(n 00 , v 00 , u) ` ϕ
.Moreover(n, v, u) ` ∀∀ϕ
iforevery(n 0 , v 0 )
reachedfrom(n, v)
byusingτ
-transitionsanddelaytransitions(oftotaldurationd
),wehave(n 0 , v 0 , u + d) ` ϕ
.SBLL
extendsL s
by allowing the useofhai tt
subformulae witha ∈ U
.L ∀ S
extends
SBLL
with new operators∀∀ S
withS ⊆ U
. A formula∀∀ S ϕ
holds for(n, v, u)
iϕ
holds forany(n 0 , v 0 , u + d)
s.t.(n 0 , v 0 )
is reachablefrom(n, v)
byusingonly
τ
-transitionsanddelaytransitions(withtotaldurationd
),butdelaytransitionsoccuronlyin statesin whichnoneoftheactionsin
S
areenabled.These two languagescanbe translated into L
ν
in the following sense: for anyϕ ∈ L ∀ S
, there exists an Lν
formulaϕ
s.t.A ` ϕ
iA | = ϕ
. Forexample, wehave that
[a]ψ =
max(X, [a]ψ ∧ [τ]X )
. An important property [2,1] ofSBLL
and
L ∀ S
is thattheirmodel checkingproblem canbereducedtoareachability problem:foranyformulaϕ
oftheselanguages,wecanbuildatestingautomatonT ϕ
s.t.A ` ϕ
i a reject node is not reachable in the parallel composition(A|T ϕ )
. Moreover it has beenshown thatL ∀ S
is expressiveenough to encodeanyreachabilityproperty[1].
Verication oftimedsystems. Automaticvericationoftimedsystemsispossi-
bledespitetheuncountablyinnitenumberofcongurationsassociatedwitha
timedautomaton.Thedecisionprocedurefor
A | = ϕ
isbasedonthewellknownregion technique [4]. Given
A
andϕ
, it is possibleto partition the innite setoftimeassignmentsover
C + = C ∪ K
into anitenumberofregionsin suchawaythattwoextendedcongurations
(n, u)
and(n, v)
,whereu, v ∈ R C ≥ + 0
areinthesameregion,satisfythesameformulae.Formallytheregionscanbedened
as the equivalence classes induced by the equivalence relation over valuations
dened thus: given
u, v ∈ R C ≥ + 0
,u
andv
are in the sameregioni theysatisfythesameclockconstraintsin
B M (C + )
,whereM = max(
MCst(A),
MCst(ϕ))
.Wewrite
[u]
fortheregionwhichcontainsthetimeassignmentu
,anduseR Cl k
to denotethe(nite)set ofallregionsforaset
Cl
of clocksandthemaximumconstant
k
.Givenaregion[u]
inR Cl k
andC 0 ⊆ Cl
,wedenetheresetoperatorthus:
[C 0 → 0][u] = [[C 0 → 0]u]
.Moreover,givenaregionγ
,itssuccessorregion,denotedby
succ(γ)
,istheregionγ 0
s.t.foranyu ∈ γ
there existsδ ∈ R ≥ 0
with[u+δ] = γ 0
,and[u+δ 0 ] ∈ {γ, γ 0 }
,foreveryδ 0 < δ
.Theregionsucc(γ)
isdierentfrom
γ
iγ(x ≤ k) = tt
forsomeclockx
.Now, given a timed automaton
A = h
Act, N, n 0 , C, Ei
, a setK
of formulaclocks and an integer constant
M
withM ≥
MCst(A)
, we can dene a sym-bolicsemantics[18]overthenitetransitionsystem
(S, →)
,calledregiongraph,dened thus:
S = N × R C M ∪ K
and→= ( S
a
−→)∪ a −→ succ
. The symbolic se-mantics is closely related to the standard one: for every L
µ,ν
formula whoseclock constraints donotuse constantsgreater than
M
, andu ∈ γ
,(n, γ) | = ϕ
i
(n, u) | = ϕ
. Therefore each instance of the timed model checking problemcan be reduced to an untimed model checking query over the region graph.
Note that the size of
R C M +
is inO(|C + |! · M | C + | )
. Moreover for any regionγ
,|{γ 0 |γ 0 = succ i (γ), i ∈ N}| ≤ 2 · |C + | · (M + 1)
.Thereachabilityproblem,whichisafundamentalquestioninsystemverication,
isknowtobePSPACE-complete [3,10]. Moreoverthemodelcheckingproblem
forTCTL(atimedextensionofCTL)isPSPACE-complete[4].
We shall use the abbreviations
A +t | =
?Ψ +t
,A | =
?Ψ +t
andA +t | =
?Ψ
todenote,respectively,themodelcheckingproblemswhereclocksareallowedboth
andwhereclocksareallowedonlyinautomata.
3 Complexity results for model checking
Wenowconsiderthe complexityofmodelchecking(MC)forthepropertylan-
guagesintroducedpreviously.Theseresultsrequiretodenewhatarethesizeof
atimedautomaton
A = h
Act, N, n 0 , C, Ei
andaformulaϕ ∈
Lµ,ν
. Thesize|ϕ|
ofaformulaisitslength.Wedene
|A|
as|N| + |C| + |E| +
MCst(A) + Σ e ∈ E |g e |
,andassumeabinaryencodingfortheelementsofthesets
N
andC
.Consider-ingconstantsrepresentedinunaryorbinarydoesnotchangeourresultsexcept
whenitisexplicitlymentioned.
Theorem 1. The complexity of L
µ,ν
and Lν
model checking is EXPTIME-complete. Moreover, we have that the specication andprogram complexities of
L
µ,ν
andLν
model checking arealsoEXPTIME-complete.Proof. EXPTIME membership:Wehaveseenthat
A | = ϕ
iA ˜ | = ϕ
whereA ˜
isan untimedautomaton (the region graph) whose sizeis exponentialin| A |
andoverwhich
ϕ
isinterpretedasanuntimed formula.IfwemodifyslightlyA ˜
by adding the transitiveclosure of
succ −→
, the size of the resultingautomaton isstillexponentialin
|A|
,and∃∃
and∀∀
becomeonestep modalities.Thenϕ
isasimple(untimed) alternation-free
µ
-calculus formulafor which model checkingis linearin
| A| ˜
and|ϕ|
[9].This givestheEXPTIME membershipfor Lµ,ν
andL
ν
.EXPTIME-hardness: Deciding whether a given linear bounded alternating
Turing machine (LBATM)
M
accepts a given input stringw
is EXPTIME-complete[7],anditcanbereducedinpolynomialtimetoaMCproblem
A M | = Φ
with
Φ ∈
Lν
.The mainideais that wecanbuildaTAA M
overactionss
andaccept s.t. any
s
-transition ofA M
corresponds to a step ofM
due to thetapeboundness(see[3,10]).Byfollowingthesameapproachproposedin [6]for
untimedconcurrentsystems,thealternatingbehaviour 1
of
M
canbehandledbyanL
ν
formulaoftheform:Φ =
max(X, [
accept]ff ∧ ∀∀ [s] ∃∃ h s i X )
.IntuitivelyΦ
holdsfor
A M
ifthecurrentorstateisnotanacceptingstateandafteranystep(leading toanand state),there existsatransition leadingto anon-accepting
or stateand soon.We have
A M | = Φ
i theLBATMM
doesnot acceptw
.ThisgivestheEXPTIME-hardnessforL
ν
andLµ,ν
.Specicationcomplexity:Infacttheacceptanceof
w
byaLBATMM
canbereducedinpolynomialtimetoaproblemoftheform
nil | = Ψ M ,w
whereΨ M ,w
isanL
ν
formula.Thisencodingisbasedontheuseofformulaclockstorepresentthecongurationsof
M
.ThisgivestheEXPTIME-hardness.Program complexity:Thisis duetotheproofofEXPTIME-hardnessforL
ν
model checkingwhere theformula
Φ =
max(X, [
accept]ff ∧ ∀∀ [s] ∃∃ hsi X )
doesnotdepend ontheLBATM
M
. 21
Weassumew.l.o.g.thatwehaveastrictalternationofor andandstatesin
M
,andthattheinitialandnalstatesareorstates.
sat t = 1 a 1 x 1 := 0 t = 2 a 2 x 2 := 0 t = n a n x n := 0
r n r 1
r 0
t = 1 a 1 t = 2 a 2 t = n a n
t = n ∧ ϕ ˜ end
Fig.1:Theautomaton
A (ϕ)
withϕ ˜ = ϕ[p i ← x i = n − i; ¯ p i ← x i = n]
.Remark 2. In[15],atimed
µ
-calculusT µ
hasbeenproposed,andMCforT µ
wasshownto be PSPACE-hard.
T µ
is moreexpressivethan Lµ,ν
because itallowsforxpointalternationsanditusesapowerfulbinaryoperator
.
(insteadofourmodalities
hai
and∃∃
). Infact theproof of Theorem 1canbeadapted2 toT µ
andthisyieldsanimprovedlowerboundonthecomplexityof
T µ
MC.Moreover,using techniquesfrom [6], wecan provethat theMC problem for
T µ
(andtheextension of L
µ,ν
with alternations) is in EXPTIME, and is thus EXPTIME- complete.Tothebest ofourknowledgethisistherstprecise characterizationofthecomplexityofMCforthislogic.
Theorem2. The model checking problem for L
− ν
isPSPACE-complete. More- overthe specication complexityof L− ν
MC isPSPACE-complete. The program complexity of L− ν
MCis in P,if the integer constants inthe automata are rep-resentedinunary.
Proof. PSPACEmembership:Anondeterministicmodelcheckingalgorithm
in PSPACE canbeeasily dened by consideringthe parts ofthe regiongraph
associatedto
A | = ϕ
onlywhentheyarerequired.ThedierencewithLν
isthatwedonotneedto computearbitrarysetsofcongurationsforxpoints.
PSPACE-hardness: Let
Φ = Q 1 p 1 . . . Q n p n .ϕ
be an instance of the QBF(Quantied Boolean Formulae) problem, where each
Q i ∈ {∃, ∀}
andϕ
is apropositional formula over the
p i
's. We reduce the validity ofΦ
to a modelcheckingproblem. ConsidertheTA
A (ϕ)
inFigure1andtheL−
ν
formulaΦ ˜ = ∃∃(ha 1 i tt ∧ O 1 (∃∃(ha 2 i tt ∧ O 2 . . . ∃∃(ha n i tt ∧ O n hsati tt))))
where
O i
isha i i
(resp.[a i ]
)ifQ i
is∃
(resp.∀
).ClearlyA (ϕ) | = ˜ Φ
iΦ
isvalid.Specication complexity: In fact any QBF instance can be encoded as a
problemoftheform
nil | = Φ
,withΦ ∈
L− ν
,byusingformulaclocks.ThisentailsthePSPACE-hardnessofspecicationcomplexity.
Program complexity: Let
ϕ
be agiven L− ν
formula. We candene a poly-nomial(in
| A |
) algorithmbybuildingthe pertinentpartof theregiongraphinan on the y manner. The keypointsare that (1) deciding if
ϕ
holds for aTA
A
needstoconsider onlysequenceswithat most| ϕ |
actiontransitions and (2) betweentwo action transitions the number of possible delay transitions isbounded by
2(|C A | + |K|)(max(
MCst(A),
MCst(ϕ)) + 1)
which is polynomialin|A|
ifMCst(A)
isgivenin unary.ThetimecomplexityofsuchanalgorithmisinO(|A| 2 | ϕ | )
and,asϕ
isxed,theprogramcomplexityisinP. 22
Forex.byconsideringaformulalike:
µX.
accept∨ [tt. (p o ∧¬(tt .(p e ∧¬X )))]
wherep e
(resp.p o
)markseven(resp.odd)states.lemsoftheform
nil | = ϕ
(whereϕ
isaformulainanyofthelogicsconsideredsofar)arejust ashardastheMCproblemsforarbitraryTA. Thustheworst-case
complexityofMCforthesereal-timelogicsmaybeseenasderivingsolelyfrom
theuseofclocksinformulae.Thispatternwill remaintrueforalltheproperty
languageswestudy inwhatfollows,except
SBLL −
andL − ∀ S
.Thepropertylanguage
L s
hasbeenintroducedin [19] asasub-languageof Lν
that allowsformoreecientmodel checkingalgorithms.Tothebest ofour knowledge, however, such an intention has not been supported yet by precisecomplexitytheoreticconsiderations.Thesewenowproceedto present.
Theorem3. The complexity of
L s
MC is PSPACE-complete. Moreover, the specication andprogramcomplexitiesofL s
MCarealso PSPACE-complete.Proof. PSPACEmembership:Forevery
L s
formulaϕ
,itispossibletobuildaTA
T ϕ
suchthat,foranyTAA
,A | = ϕ
iarejectnodeofT ϕ
isnotreachablein theparallelcomposition
(A|T ϕ )
[2].ThesizeofT ϕ
islinearin that ofϕ
and(A|T ϕ )
can be seenasa newTAA ¯
corresponding to theproductA ×T ϕ
. Thereductionof
A | = ϕ
to areachabilityproblemforA ¯
isdonein polynomialtime,andthusgivesthePSPACE membership.
PSPACE-hardness:A reachabilityquestionfor node
n
in aTAA
canbere-duced to checking that
A 6| =
max(X, [
in_n]ff ∧ [a]X ∧ ∀∀ X )
if wesuppose thateveryedgein
A
haslabela
,exceptforanewtransitionh n, tt,
in_n, ∅ , n i
.Specication complexity: It is possible to reduce reachability in a linear
bounded nondeterministic Turing machine
M
with inputw
to a problem oftheform
nil | = Φ M ,w
bymeansofthesamekindofencodingusedforLν
.Programcomplexity:ItisPSPACE-completebecausetheformulaexpressing
thereachabilityproblemdoesnotdependontheinputautomaton. 2
Theorem4. The model checking problem for
L − s
is coNP-complete, as is the specication complexity of model checking. The program complexity ofL − s
isinP,if the constantsin theinputautomataarerepresentedinunary.
Thepropertylanguages
SBLL
andL ∀ S
havethesamecomplexity:Theorem5. The complexity of
SBLL
andL ∀ S
model checking is PSPACE-complete. Moreover we have that the specication and program complexities of
SBLL
andL ∀ S
MCare alsoPSPACE-complete.Forthepropertylanguages
SBLL −
andL − ∀ S
,weobtainthefollowingresult:Theorem6. TheMCproblemfor
SBLL −
andL − ∀ S
isPSPACE-complete. The specicationcomplexityofMCforSBLL −
andL − ∀ S
iscoNP-hard,andiscoNP-completeifconstantsintheformulaearerepresentedinunary.Finally, the pro-
gramcomplexityof MCfor
SBLL −
andL ∀ S
isPSPACE-complete.There isanimplicitrecursion(over
τ
anddelaytransitions)whichishiddenin thesemanticsoftheSBLL −
operator∀∀
,andthisrecursionissucienttomakeSBLL −
andL − ∀ S
modelcheckingPSPACE-hard.L
− ν
L ∀S
SBLL
L − s
L − ∀S
SBLL −
PSPACE EXPTIME
coNP
L s
L
µ,ν
L
ν
L → L 0
standsfor"
L
ismoreexpressivethanL 0
"Fig.2:Expressivenessvscomplexityofmodelchecking
Concluding remarks. The relationships between the relative expressive power
ofthepropertylanguagesthatwehaveconsidered,andthecomplexityoftheir
model checking problems is summarized in Figure 2. (There
L −→ L 0
meansthat anymodel checkingproblem
A | = ϕ
withϕ ∈ L 0
canbereducedin lineartimeto averication
A ˜ | = ˜ ϕ
withϕ ˜ ∈ L
.)Note that, for every specication language we consider, the proof of
C
-hardness of the MC problem uses formulae without clocks. This implies that
theproblems
A +t | =
?Ψ
andA +t | =
?Ψ +t
havethe samecomplexity. Theremark aboutthecomplexityofMCproblemsoftheformnil | = ϕ
showsthatA | =
?Ψ +t
and
A +t | =
?Ψ +t
alsohavethesamecomplexity.ThereforethecomplexityofMCdoesnotdependonwhether timeisaddedtothemodel,to thespecicationor
toboth.
References
1. L.Aceto,P.Bouyer,A.Burgueño,andK.G.Larsen,Thepowerofreach-
abilitytestingfortimedautomata,inProc.ofFSTTCS'98,LNCS1530,December
1998,pp.245256.
2. L. Aceto, A. Burgueño, and K. G. Larsen, Model checking viareachabil-
ity testing for timed automata, inProc. ofTACAS '98, LNCS1384, April1998,
pp.263280.
3. R.Alur,TechniquesforAutomaticVericationofReal-timeSystems,PhDthesis,
StanfordUniversity,1991.
4. R. Alur, C. Courcoubetis,and D. Dill, Model-checking in densereal-time,
InformationandComputation,104(1993),pp.234.
5. R. Alurand D. Dill, A theory of timedautomata,Theoretical ComputerSci-
ence,126(1994),pp.183235.
6. O.Bernholtz,M.Y.Vardi,andP.Wolper,Anautomata-theoretic approach
tobranching-timemodelchecking,inProc.ofthe6th.InternationalConferenceon
Computer-Aided Verication, CAV'94, D. Dill, ed., vol. 818of LectureNotes in
ComputerScience,California,USA,June1994,Stanford,Springer-Verlag.
7. A.K.Chandra,D.C. Kozen,andL.J.Stockmeyer,Alternation,J.Assoc.
Comput.Mach.,28(1981),pp.114133.
nitestateconcurrentsystem usingtemporallogic,ACMTrans.onProgramming
LanguagesandSystems,8(1986),pp.244263.
9. R. Cleaveland,A linear-time model-checking algorithm forthe alternation-free
modal
µ
-calculus,FormalMethodsinSystemsDesign,2(1993),pp.121147.10. C.CourcoubetisandM.Yannakakis,Minimumandmaximumdelayproblems
inreal-timesystems,FormalMethodsinSystemDesign,(1992),pp.385415.
11. S.Demri andP.Schnoebelen,Thecomplexityofpropositionallineartemporal
logics in simple cases (extended abstract), inProc. 15thAnn.Symp.Theoretical
Aspectsof ComputerScience(STACS'98), LNCS1373,Paris, France,Feb.1998,
SpringerVerlag,1998,pp.6172.
12. S.Dziembowski,M.Jurdzi«ski,andD.Niwi«ski,Ontheexpressioncomplex-
ity of the modal
µ
-calculus model checking. Unpublishedmanuscript, November 1996.13. E. A.Emerson, C. S. Jutla,and A. P.Sistla,On model-checking forfrag-
mentsof
µ
-calculus,inProceedingsoftheFifthInternationalConferenceComputer AidedVerication,Elounda,Greece, July1993, C.Courcoubetis, ed.,vol. 697ofLectureNotesinComputerScience,Springer-Verlag,1993,pp.385396.
14. M. Hennessy and R. Milner,Algebraiclaws for nondeterminism andconcur-
rency,J.Assoc.Comput.Mach., 32(1985),pp.137161.
15. T. A. Henzinger, X. Nicollin, J. Sifakis, and S. Yovine, Symbolic model
checkingforreal-timesystems,InformationandComputation,111(1994),pp.193
244.
16. D.Kozen,Resultsonthepropositional
µ
-calculus,TheoreticalComputerScience, 27(1983),pp.333354.17. F. Laroussinie and K. G. Larsen, CMC: A tool for compositional model-
checking of real-time systems, inProc. IFIP Joint Int. Conf. FormalDescription
Techniques&ProtocolSpecication,Testing,andVerication(FORTE-PSTV'98),
KluwerAcademicPublishers,1998,pp.439456.
18. F. Laroussinie,K.G.Larsen,andC.Weise,Fromtimedautomatatologic-
andback,inProc.ofthe20th.InternationalSymposiumonMathematicalFounda-
tionsofComputerScience,MFCS'95,J.WiedermannandP.Hájek,eds.,vol.969of
LectureNotesinComputerScience,Prague,CzechRepublic,August28-Septem-
ber11995,Springer-Verlag,pp.529539.
19. K. G. Larsen, P. Pettersson,and W. Yi,Model-checking for real-time sys-
tems, in Proceedings of the 10th International Conference on Fundamentals of
Computation Theory, H. R. (Ed.), ed., Dresden, Germany,August 1995, LNCS
965,pp.6288.
20. ,UPPAALinaNutshell,JournalofSoftwareToolsforTechnologyTransfer,
1(1997),pp.134152.
21. O.LichtensteinandA.Pnueli,Checkingthatnitestateconcurrentprograms
satisfytheirlinearspecication,inConferenceRecordoftheTwelfthAnnualACM
Symposium on Principles of Programming Languages, New Orleans, Louisiana,
Jan.1985, pp.97107.
22. A.P.SistlaandE.M.Clarke,Thecomplexityofpropositionallineartemporal
logics,J.Assoc.Comput.Mach.,32(1985),pp.733749.
23. T.A.HenzingerandP.-H.Ho,andH.Wong-Toi,HyTech:AModelChecker
for HybridSystems, Journal ofSoftware Toolsfor Technology Transfer,1(1997),
pp.110122.
24. S.Yovine,Kronos:AVericationToolforreal-TimeSystems,JournalofSoftware
ToolsforTechnologyTransfer,1(1997),pp.123133.