SAT-Solving in CSP Trace Refinement

Size: px
Start display at page:

Download "SAT-Solving in CSP Trace Refinement"

Transcription

1 ST-Solving in CSP Trce Refinement Hristin Plikrev, Joël Ouknine nd. W. Roscoe Deprtment of Computer Science, Oxford University, UK bstrct In this pper, we ddress the problem of pplying ST-bsed bounded model checking (BMC) nd temporl k-induction to synchronous concurrent systems. We investigte refinement checking in the process-lgebric setting of Communicting Sequentil Processes (CSP), focusing on the CSP trces model which is sufficient for verifying sfety properties. We dpt the BMC frmework to the context of CSP nd the existing refinement checker FDR yielding bounded refinement checking which lso lys the foundtion for tiloring the k-induction technique. s refinement checking reduces to checking for reverse continment of possible behviours, we exploit the ST-solver to decide bounded lnguge inclusion s opposed to bounded rechbility of error sttes, s in most existing model checkers. Due to the hrder problem to decide nd the presence of invisible silent ctions in process lgebrs, the originl syntctic trnsltion of BMC to ST cnnot be pplied directly nd we dopt semntic trnsltion lgorithm bsed on wtchdog trnsformtions. We propose Boolen encoding of CSP processes resting on FDR s hybrid two-level pproch for clculting the opertionl semntics using supercombintors. We hve implemented prototype tool, SymFDR, written in C++, which uses FDR s shred librry for mnipulting CSP processes nd the stte-of-the-rt incrementl ST-solver MiniST 2.0. Experiments with BMC indicte tht in some cses, especilly in complex combintoril problems, SymFDR significntly outperforms FDR nd even copes with problems tht re beyond FDR s cpbilities. SymFDR in k-induction mode works resonbly well for smll test cses, but is inefficient for lrger ones s the threshold becomes too lrge, due to concurrency. Keywords: CSP, FDR, concurrency, process lgebr, ST-solving, bounded model checking, k-induction, sfety properties 1. Introduction Model checking [CGP99; BK08; BHvMW09] is powerful utomtic forml verifiction technique for estblishing correctness of systems. It requires finite-stte model of system, cpturing ll its possible behviours, nd specifiction property, usully modelled s formul in some kind of temporl logic. The model checker performs nlysis bsed on exhustive explortion of the stte spce of the system to either confirm or refute tht the system meets its specifiction. In the ltter cse, the model checker provides counterexmple trce for reproducing nd fixing the bug. Model checking is complete nd, therefore, relible when pronouncing system correct. The min chllenge in pplying model checking in prctice is the so-clled stte-spce explosion problem which tends to be even more severe in the context of concurrent systems. The stte-spce of concurrent system grows exponentilly with the number of its concurrent components nd the 1

2 number nd size of its dt vlues. This puts restrictions on the size of systems tht cn be trctbly nlysed. To llevite the stte-spce explosion problem, significnt number of techniques hve been proposed. Methods for decresing the size of the generted stte spce nd enhncing the model checking lgorithm include CEGR [CGJ + 00], prtil-order reductions [CGP99; Pel98], bounded model checking [BCCZ99], etc. Regrding stte-spce representtion, the mjor dichotomy is between explicit nd symbolic [BCM + 92; BCCZ99] model checking. Explicit model checking is bsed on explicit enumertion nd exmintion of individul sttes. Symbolic model checking relies on bstrct representtion of sets of sttes, generlly s Boolen formule, nd properties re vlidted using techniques such s BDD mnipultion or ST-solving. The recent dvnces of efficient ST-solvers hve significntly brodened the horizons of symbolic model checking. ST-bsed bounded model checking [BCCZ99] hs proven to be n extremely powerful technique, minly suited, due to its incompleteness, to flsifiction of properties. pproches for mking BMC complete include clculting completeness thresholds [CKOS04; CKOS05] or ugmenting BMC with k-induction [SSS00; ES03b] or Crig interpoltion [McM03] techniques. Both bounded nd unbounded ST-bsed model checking hve been minly investigted in the context of hrdwre nd sequentil softwre systems. In this pper, we ddress pplying BMC nd temporl k-induction [ES03b] to synchronous concurrent systems. The generl problem we investigte is refinement checking in process-lgebric settings nd, more specificlly, in the context of CSP [Ho85; Ros98; Ros10]. In process lgebrs, systems re modelled s interctions of collection of processes, communicting with ech other nd with the outer world vi messge pssing, s opposed to shred vribles. Using high-level lnguge, processes re defined compositionlly nd compiled into hierrchicl structure, strting with tomic process constructs nd combining those using opertors such s choice, prllel nd sequentil composition, hiding, etc. This llows for wy of describing rective systems tht is usully very concise nd much more economicl in stte spce thn shred-vrible lnguges. Unlike in conventionl model checking, where specifictions re generlly defined s temporllogic formule, in process lgebrs specifictions re defined s bstrct designs of the systems, i.e. s processes, which llows for step-wise development process. The refinement checking procedure decides whether the behviours of the system re subset of the behviours of the specifiction, i.e. whether the system refines the specifiction. Hence, the verifiction problem reduces to checking for reverse continment of behviours nd, therefore, to reverse lnguge inclusion. Developed in the lte 1970 s by Hore, CSP is one of the two originl process lgebrs. It llows for the precise description nd nlysis of event-bsed concurrency. n dvntge of the CSP frmework is tht it offers well-developed syntx, lgebric nd opertionl semntics, hierrchy of congruent denottionl semntic models, s well s forml theory of refinement nd compositionl verifiction. In terms of syntx nd semntics, mong other differences with existing formlisms for modelling concurrent systems, CSP supports the usge of brodcst communiction, recursion, s well s hiding nd renming of events, both of which re powerful mechnisms for bstrction. FDR [Ros94; FSE05] is cknowledged s the primry tool for CSP refinement checking nd hs been widely used for nlysing sfety-criticl systems. The core of FDR is refinement checking in ech of the semntic models, which is crried out on the level of the opertionl representtion of the CSP processes nd is implemented using explicit stte enumertion supplemented by hierrchicl stte-spce compression techniques. When deciding whether n implementtion process Impl refines normlised specifiction process Spec, FDR follows lgorithms exploring the Crtesin product of the stte spces of Spec nd Impl in wy comprble to conventionl model checking. lthough 2

3 until now FDR hs followed the explicit model checking pproch, there hs been some work on the symbolic model checking of CSP resulting in the BDD-bsed refinement checker RC [PY96] nd the model checker PT [SLDS08], both of which exploit fully compositionl encoding of CSP processes. PT verifies systems defined in version of CSP enhnced with shred vribles nd, within the BMC frmework, it uses specifictions defined s rechbility properties on the vlues of the shred vribles, which requires different model checking lgorithm bsed on rechbility nd not on lnguge continment. This pper reports our ttempts to integrte ST-bsed BMC nd temporl k-induction into FDR. The former technique is incomplete nd s such is only suitble to detecting bugs. k-induction, however, is complete nd cn lso be used for estblishing the correctness of systems. Hence, to the best of our knowledge, this is the first ttempt to pply unbounded ST-bsed refinement checking to CSP. We propose n lterntive Boolen encoding of CSP processes bsed on FDR s hybrid two-level pproch for clculting the opertionl semntics using supercombintors [Gol04]. s we del with with problem tht reduces to lnguge inclusion insted of to rechbility nd due to the presence of invisible hidden ctions in process lgebrs, the originl syntctic trnsltion of BMC to ST cnnot be pplied directly nd we dopt semntic trnsltion lgorithm bsed on wtchdog trnsformtions [RGM + 03]. Essentilly, this involves reducing refinement check into nlysing single process which is constructed by putting the implementtion process in prllel with trnsformed specifiction process. The ltter plys the role of wtchdog tht monitors nd mrks violting behviours. Within the scope of this pper, we only consider the trnsltion of trce refinement to ST checking. The result is prototype tool SymFDR 1 which, when combined with stte-of-the-rt ST-solvers such s MiniST 2.0 [ES03; EB05], sometimes outperforms FDR by significnt mrgin in finding counterexmples. We compre the performnce of SymFDR with the performnce of FDR, FDR used in non-stndrd wy, PT [SLD08] nd, in some cses, NuSMV [CCG + 02], lloy nlyzer [Jc06] nd stright ST encodings tilored to the specific problems under considertion. The reminder of the pper is orgnised s follows. In Section 2, we set out the necessry bckground on CSP nd FDR s two-level strtegy for performing refinement checks. We briefly describe the ides underlying ST-bsed BMC nd k-induction. In Section 3, we show how to dpt the wtchdog pproch [RGM + 03] to BMC nd, hence, to k-induction, while in Section 4, we summrise the methods we use to trnslte FDR s supercombintor representtion of stte mchine into input for ST-solver. Section 5 gives detils of how SymFDR is built on top of this, nd Section 6 offers experimentl evlution. 2. Preliminries 2.1. CSP nd FDR In this section, we give brief overview of CSP nd FDR. The interested reder is referred to [Ros98], [Ros10] nd [FSE05] for more detils. We restrict our focus to the trces model exclusively, intentionlly omitting informtion bout other more expressive models of CSP CSP Syntx In CSP, processes interct with ech other nd n externl environment by communicting events. More thn one process my hve to cooperte in the performnce of n event, i.e. hndshke on it. It 1 SymFDR s binries re expected to be online shortly. 3

4 is stndrd to distinguish between visible events tht might need the coopertion of other processes or the environment nd invisible internl ctions tht occur silently, re not observble or controllble outside process nd model n internl computtion such s nondeterminism, unfolding of recursion, bstrction of detils. Let Σ be finite lphbet of visible events with, Σ. denotes the invisible silent ction nd successful termintion of process specil ction which is visible but uncontrollble from outside nd cn only occur lst. In wht follows, we ssume tht Σ, Σ nd B Σ = Σ { }. R Σ Σ denotes renming reltion on Σ. For given process P, we denote by α P Σ the set of ll visible events tht P cn perform. We recll the core syntx of CSP. Definition 2.1. CSP process is defined recursively vi the following grmmr: P = STOP SKIP DIV x : P (x) P 1 P 2 P 1 P 2 P 1 P 2 P 1 P 2 P \ P R µ P F (P ) B STOP represents dedlocked process, i.e. process tht is not cpble of communicting ny visible or ctions. The prefixed process x : P (x) initilly offers the environment to perform ny event from nd subsequently behves like P (). DIV denotes livelock, i.e. process tht is engged in performing n infinite loop of internl ctions without ever communicting with the externl environment. The process SKIP denotes successful termintion nd is willing to perform t ny time. P 1 P 2 nd P 1 P 2 denote, respectively, externl nd internl choice of P 1 nd P 2. In the former cse the choice is resolved by the environment while in the ltter nondeterministiclly. The prllel composition P 1 B P 2 cn communicte n event from B only if both P 1 nd P 2 re redy to do so P 1 nd P 2 need to hndshke (synchronise) on the events in B, but cn perform independently on ll other events. In prctice, it is common to synchronise P 1 nd P 2 on their shred events, i.e. use B = α P1 α P2. The sequentil composition P 1 P 2 behves like P 1 until P 1 termintes successfully, t which point it silently evolves into P 2. P \ behves like P except tht ll events from re being hidden, i.e. turned into internl ctions. Hence, the events in P become invisible nd uncontrollble by other processes or the environment by mens of synchronistion. P R behves like P, except tht, whenever P cn perform n event, P R cn perform ny event b, such tht Rb. µ P F (P ) denotes recursive process. FDR supports the lnguge CSP M which extends core CSP with severl further opertors nd n extensive functionl lnguge. Our prototype tool SymFDR supports the full CSP M syntx, except tht it cnnot t present hndle scripts using the function chse Running Exmple: Milner s Scheduler Given fixed N N, scheduler must rrnge two clsses of events.i nd b.i for i {0,..., N 1}. There re two requirements the.i-s should occur in strict rottion, i.e..0,.1,...,.n 1 }{{},.0,.1....,.N 1,..., nd there should be precisely one b.i between ech pir of.i-s. }{{} In CSP, Milner s scheduler cn be modelled s ring of cell processes synchronised using extr events c.i, s illustrted on Figure 1. n bstrcted CSP script for Milner s scheduler estblishing the rottion specifiction is presented on Figure 2. i 1 denotes (i + 1)%N nd, likewise, i 1 (i 1)%N. For ech process Cell(i), we extend its lphbet α Cell(i) = {.i, b.i} with extr events c.i nd c.i 1 to use for synchronising with its neighbouring processes Cell(i 1 ) nd Cell(i 1 ), respectively. Cell(0 ) is defined in slightly different wy s the -sequence should strt with.0. 4

5 Figure 1: Milner s scheduler for N = 5 The scheduler is constructed by composing ll the cells in prllel nd hiding ll c-events on top s they hve been introduced solely for synchronistion purposes. Within Scheduler, the opertor corresponds to synchronising the two rgument processes on the set of their common events nd is fully ssocitive. Hence, cell cn perform n event only if ll other cells tht hve the sme event in their lphbet re lso offering to do so. { c } is shorthnd for {c.i i N}. We give rough ide of how Scheduler works nd why it preserves the rottion specifiction (modelled s Spec). The only process tht cn initilly perform n event is Cell(0 ) for ll i > 0, Cell(i) is blocked s it needs Cell(i 1 ) to lso offer c.i. fter Cell(0 ) communictes.0, the only thing tht cn hppen next is Cell(0 ) nd Cell(1 ) synchronising on c.1, thus enbling Cell(1 ) to perform.1. Concerning the sequence of -s, the sme process is repeted round the ring s, synchronising on c.i 1, Cell(i) psses token to Cell(i 1 ) to signify tht it is Cell(i 1 ) s turn to contribute n.i 1. Obviously, the second requirement for the scheduler is cptured s well, lso in the most generl wy. Cell(0 ) =.0 c.1 b.0 c.0 Cell(0 ) Cell(i) = c.i.i c.i 1 b.i Cell(i) if i > 0 Scheduler = (Cell(0 ) Cell(1 )... Cell(N 1 )) \ { c } Spec(i) =.i Spec(i 1) Spec = Spec(0) ssert Spec T Scheduler \ { b } Figure 2: CSP syntx Milner s scheduler Denottionl Semntics Trditionlly, the primry mens of understnding CSP descriptions hs been to use denottionl (behviourl) models, whereby process is identified with the set of observble behviours it cn exhibit. CSP supports hierrchy of severl such denottionl semntic models. Different models describe different types of behviours, providing more or less informtion bout process, with the nturl trde-off between the mount of detils recorded for process nd the complexity of working in the model. ll denottionl models re compositionl in the sense tht the denottionl vlue (the set of possible behviours) of ech process cn be computed in terms of the denottionl vlues of its 5

6 subcomponents. The vlue of recursive process is obtined using stndrd fixed-point theory in the style of Scott nd Strchey. In the simplest of ll models, the trces model, process P is identified with the set of its finite trces, denoted by trces(p ). Intuitively, trce of process is sequence of visible ctions tht the process cn perform. Nturlly, the set of trces of process is non-empty nd prefix-closed. For exmple, going bck to the scheduler described on Figure 2, trce of Cell(0 ) is ny prefix of (.0 c.1 b.0 c.0). The trces model records informtion bout wht process my do nd is, therefore, sufficient for verifying sfety properties. There re two different pproches for obtining the set trces(p ) either by constructing it inductively from the trces of its subcomponents, or by extrcting it from the opertionl representtion. Refer to [Ros98] for the rules underlying the first pproch. Just to give flvour of it in terms of Milner s scheduler: ˆ trces(spec) = { } {.0 t t trces(spec(1))}, ˆ trces(scheduler) = {t (Σ \ { c }) t trces(cell(0 )... Cell(N 1 ))}. Since denottionl vlues of processes re rther complex nd often infinite, FDR clcultes the behviours of process from its stndrd opertionl representtion which is justified by stndrd congruence theorems, presented nd proven in [Ros98; Ros88] Opertionl Semntics The opertionl semntics models CSP processes s lbelled trnsition systems (LTS s), with nodes denoting processes nd lbels denoting visible events or ctions. Since the LTS representtion is not unique, in terms of the opertionl semntics, two processes re considered equivlent if they re strongly bisimilr [Ros98]. The opertionl semntics cn generlly be clculted by repetedly pplying set of SOS-style inference rules, clled firing rules. Firing rules provide recipes for constructing n LTS out of CSP description of process. The recipes define how processes cn evolve by clculting the initil ctions vilble t ech node nd the possible results fter performing ech ction. The firing rules re presented below. We use n uxiliry process term Ω to denote ny process tht hs lredy terminted successfully. If F is CSP term with free process vrible X nd Q is CSP process, F [Q/X] represents the process obtined by substituting every free occurrence of X in F with Q. The lst three rules reflect the fct tht termintion is distributive P 1 P 2 termintes when both P 1 nd P 2 do. The reder is referred to [Ros98] for more informtion. SKIP x : P (x) P 1 P 2 Ω ( ) P () ( P 1 P 1 P 2 P 2 µ P F (P ) P 1 P 1 P 1 P 2 P 1 P 2 F [(µ P F (P ))/P ] P 2 P 2 P 1 P 2 P 1 P 2 (SKIP) ) ( ) (µ P F (P )) ( ) 6

7 b P 1 P 1 (b Σ ) b P 1 P 2 P 1 P 1 P 1 P 1 P 2 P 1 P 2 P 1 P 1 P 1 ; P 2 P 1 ; P ( Σ) 2 P P P P \ ( ) P \ P P P R Ω P 1 P 1 P 1 P 2 P 1 P 1 P 1 P 1 P 2 P 1 ( Σ \ ) P 2 P 1 P 1 P 2 P P P \ P \ P P P \ Ω b P 2 P 2 (b Σ ) ( b Σ ) P 1 P 2 P 2 ( ) P 1.P 1 P 1 ( Σ ) P 1 ; P 2 P 2 (\ ) (\ ) P P \ P \ ( Σ \ ) (\ Σ) P P P R P R P P R P b P R P 2 P 2 P 2 P 1 P 2 P 2 P 1 P 2 P 1, P 2 P 2 P 1 P 2 ( R ) (Rb) ( R Σ ) P 1 P 2 P 2 P 1 P 2 ( ) ( Σ \ ) ( Σ1) ( ) ( Σ2) P 1 P 1 P 2 P 2 P 1 P 2 Ω P 2 P 1 P 2 P 1 Ω Ω Ω Ω ( 1) ( 2 ) 7

8 Extrcting Behviours from Opertionl Semntics. We now present how behviours, in our cse trces, cn be retrieved from the opertionl semntics of process. Intuitively, trce of process is obtined by trimming the invisible ctions from n execution of the LTS underlying the opertionl representtion. Formlly, lbelled trnsition system is qudruple M = S, s 0, L, T, where S is finite set of sttes, s 0 S is the initil stte, L is finite set of lbels, T S L S is the trnsition reltion. For convenience, we write s s S, such tht s l s insted of (s, l, s ) T. Furthermore, we write s l if there exists l s. n execution of M is finite or infinite lternting sequence of sttes nd l i+1 events π = s 0 l 1 s 1 l 2... l n s n..., such tht s 0 is the initil stte nd for ll i 0, s i si+1. Going bck to our exmple, the LTS s of Cell(0 ) nd Cell(1 ) re depicted on Figure 3(b). Let P be finite-stte process nd OS P = S P, s P 0, L P = Σ,, T P be the LTS underlying the opertionl semntics of P. We write Σ to denote the set of finite words over Σ which might end with, nd similrly, (Σ ). For p, q S P, we use the following nottion: ˆ initils(p) = {l Σ p }, l i.e. initils(p) is the set of visible events tht cn be communicted from the stte p. ˆ For t = x i 0 i < n (Σ ) t, we write p q if there exists sequence of sttes x p 0, p 1,..., p n, such tht p 0 = p, p n = q nd p k k pk+1 for k {0,..., n 1}. t ˆ For t Σ, we write p = q if there exists t (Σ ), such tht p t q nd t = t Σ, i.e. t is t with ll the s removed. Then, we define trces(p ) = {t Σ q S P.s P 0 t = q} Opertionl Representtion in FDR The Two-Level pproch The SOS nottion for opertionl semntics llows the cretion of mny opertors tht do not fit in the denottionl world of CSP. ny CSP opertor cn be described using less generl combintor opertionl rules insted nd, conversely, ny opertor tht cn be given combintor opertionl semntics cn be derived nd given denottionl semntics in CSP [Ros10]. Combintor-style semntics cn be generlised to supercombintor opertionl semntics which is the one used in FDR. We give detils bout both combintor nd supercombintor semntics below. Combintor Rules. s with SOS, there re severl combintor rules for ech CSP opertor nd these llow us to infer the initil ctions vilble t ech process node out of its top-level opertor nd the initil ctions vilble t its immedite process rguments. The crucil difference compred to SOS rules origintes from the fct tht process rguments cn be viewed s switched on or off, depending on the context they re used in. Given compound CSP process P = (P 1,..., P n ), process rgument P i is considered switched on if its initil ctions re immeditely relevnt for the initil ctions of P nd switched off if does not need its initil ctions to deduce the resulting initil ction of P. For exmple: ˆ in P 1 P 2 = P 1 P 2, both P 1 nd P 2 re switched on ˆ in P 1 P 2, P 2 is initilly switched off until P 1 performs, t which point P 1 becomes switched off nd P 2 switched on ˆ in P, P is initilly switched off but gets switched on when is communicted 8

9 ˆ in P 1 P 2, P 1 nd P 2 re initilly switched off s the nondeterministic choice is only resolved fter is performed, t which point precisely one of the two processes becomes ctivted. Combintor rules keep trck of which processes re switched on t every given moment nd restrict SOS by llowing only two types of rules: ˆ rules enforcing tht whenever switched-on process rgument performs, this is promoted to of the compound process tht does not chnge its structure. ˆ rules combining visible events of switched-on process rguments (if ny) into resulting ction of the compound process. In those rules, switched-on process cn prticipte with either visible event or not be involved t ll, the ltter of which we denote with the symbol ɛ. Combintor rules lso need to indicte the structure of the successor term. In mny instnces, the structure is the sme s the initil one nd so does not hve to be mentioned explicitly in the rules. When the structure does chnge (i.e. processes become switched from on to off or conversely), this is indicted by CSP term in which the vrious rguments of the opertor my pper. In every cse, the successor stte contins the originl rgument if the ltter hs not prticipted in the ction, or the stte tht the rgument hs moved to if it did. Now formlly [Ros11], let P be compound process with top-level opertor, switched-on rguments P 1,..., P n (for some n 0) nd switched-off rguments Q = P λ λ Λ. Hving ny switched-on process rgument P i tht cn go vi to stte P i, the -promotion rule tkes the form: (P 1,..., P i,... P n, Q) (P 1,..., P i,... P n, Q). s this rule holds universlly for ny switched-on rgument of ny CSP opertor, -promotion rules do not need to be dded explicitly to the combintor opertionl semntics s they were in the SOS rules,, \, R,. Rules combining visible events tke the generl form ((x 1,..., x n ), y, T ), where x i Σ {ɛ}, y Σ, nd T is piece of CSP syntx specifying the structure of the successor term. The ide is tht whenever ll P i s tht hve x i ɛ cn perform x i nd go to sttes P i, they cn synchronise to mke the compound process P perform y nd enter stte T. The successor stte T is either Ω, if y =, or is specified by n open CSP term in which the free vribles re indices drwn from {1,..., n} {-λ λ Λ}, which get substituted ccording to the following rules: ˆ For i {1,..., n}, we distinguish different cses. If x i = ɛ or x i Σ, i is replced by P i or P i, respectively. If x i =, i does not pper in the successor term T ny more s P i becomes switched off. ˆ n index -λ for λ Λ indictes tht the process P λ hs become switched on nd is replced by P λ. We list the combintor rules below. In some of them, e.g. Σ \ Σ, R Σ, nd 1 2, the structure of the successor term does not chnge, i.e. the resulting stte is (P 1,..., P n, Q), where P i = P i if x i = ɛ nd P i = P i if x i Σ. In those cses, we omit T from the rules for simplicity. In rules SKIP, nd, there is no switched-on rgument initilly which we indicte by. Ω is nturlly switched off s it represents successful termintion. Hence, Ω nd Ω re viewed s unry opertors. 9

10 (( ),, Ω) (( ),, -1) (SKIP) ( ) (( ),, -1) nd (( ),, -2) ( ) ((, ɛ),, Ω) nd ((ɛ, ),, Ω) ( ) ((, ɛ),, 1) nd ((ɛ, ),, 2) ( Σ ) ((), ) nd (( ),, -2) ( Σ ) (( ),, Ω) (\ ) ((), ) if nd ((), ) if Σ \ (\ Σ ) (( ),, Ω) nd ((), b) when Rb ( R Σ ) ((, ɛ), ) nd ((ɛ, ), ) if Σ \ ((, ), ) if ( Σ1) ( Σ2) ((, ɛ),, Ω 2) nd ((ɛ, ),, 1 Ω) ( 1) ((), ) if Σ \ nd (( ),, SKIP) (Ω, Ω) Supercombintor Opertionl Semntics. Combintor opertionl semntics cptures precisely CSPdefinble opertors [Ros10; Ros11]. However, ctions of compound processes need to be clculted recursively on-the-fly out of the ctions of their subterms. Furthermore, successor sttes re presented s pieces of syntx which does not prove to be efficient when nlysing lrge systems. Supercombintor opertionl semntics is less generl but more efficient version of the combintor opertionl semntics [Ros10]. Supercombintor rules tke the form of combintor ones, but re generlised to combine together ctions of subprocesses nested under n rbitrry number of pplictions of CSP opertors. s there is no combintor rule for recursion, the only constrint is tht ny process rgument should be closed CSP term, i.e. should hve ll the recursion unwound. Bsed on this ssumption, ll process rguments hve combintor semntic rules which cn be composed together to obtin rules for the outermost CSP opertor. Hence, it trnsforms combintion of CSP opertors into single one. Furthermore, this cn be implemented efficiently in single run before the stte-spce explortion phse rther thn on-the-fly when needed using recursive clls. 10

11 We illustrte the pproch by exmple. Let P = 1 ( 2 (P 1, P 2 ), 3 (P 3, P 4 )) nd let us ssume for simplicity tht ll 1, 2 nd 3 hve their two rguments switched on nd their ppliction does not result in successor terms with different structure (formt). Considering the -promotion rules, if 2 or 3 hve rule tht genertes, this gets promoted by 1. For instnce, if 2 hs the rule ((, b), ), then we crete supercombintor rule ((, b, ɛ, ɛ), ) for the compound process 1. The other type of supercombintor rises when we cn mtch ll input requirements of one of 1 s combintors using combintors of 2 nd 3 tht produce visible results. For exmple, if 1, 2 nd 3 hve the rules ((, b), c), ((ɛ, ), ) nd ((b, d), b), respectively, then the composition will hve ((ɛ,, b, d), c). Supercompiling the process of ssociting supercombintor-style opertionl semntics to CSP process, follows hybrid high-/low-level pproch for clcultion nd representtion [Ros10]. It identifies ll true recursions nd compiles them on low level, generting explicit LTS s using the combintor rules. Wht remins for the high level re closed processes combined typiclly using prllel composition, hiding nd renming, lthough the dividing line is somewht more complex nd is drwn where sensible. For exmple, the choice opertors nd sequentil composition cn lso be lifted to the high level s long s their rguments re ll closed terms. The result of supercompiltion is high-level structure which consists of two prts. The first one is process tree with leves low-level compiled LTS s, nd internl nodes CSP opertors compiled on the high level, usully hiding, renming or prllel composition. Ech node, even if internl, represents process nd cn be interpreted s n LTS with its behviours deducible on-the-fly from the behviours of its children. The second prt of the high-level structure is set of supercombintors mpping ctions of number of lef processes to n event-outcome of the composite root process [Ros98]. In wht follows, we use the notions of supercombintors nd rules interchngebly. We note tht the list of lef processes together with the set of supercombintors is complete chrcteristion of the high-level process s the semntics of ll CSP opertors corresponding to the internl nodes in the process tree is cptured by the supercombintor rules. The structured process tree cn be used, though, for mking the whole high-level process completely explicit. The set of combintors is prtitioned with respect to the existing formts the different configurtions of switched on nd switched off lef processes. In the worst cse, the number of formts cn be exponentil in the number of leves, but in prctice this is rrely the cse nd quite often, there is just single formt, especilly when composing processes in prllel on the top level. Within supercombintor, ech process cn prticipte with visible event, silent ction, or not be involved t ll, the ltter of which we gin denote by ɛ. s with combintor rules, the supercompiler genertes two types of rules[ros98; Gol04; RRS + 01]: ˆ rule for lef process willing to perform which promotes ction of the root process, ˆ rules using visible ctions. Note tht the visible ctions tht the lef processes perform need not be the sme if hiding or renming is involved in the combintion being modelled. For exmple, if P = P nd Q = b Q, then if P performs nd Q performs b, P Q /b cn perform, where Q /b is the process Q with the event b being renmed to. Hence, ((, b), ) is vlid rule for the root process P Q /b with leves P nd Q. {} Going bck to our running exmple, fter supercompiling Scheduler \ { b }, we obtin the process tree depicted on Figure 3(). The simple recursive cell processes re compiled s leves nd {} 11

12 \{ b } \{ c } Cell 0 Cell 1 Cell 2 Cell 3 Cell 4 () (b) Figure 3: Opertionl semntics Milner s scheduler their LTS s generted explicitly. The root process contins just single formt with three types of supercombintors: ˆ if Cell(i) nd Cell(i 1) perform c.i 1, Scheduler \ { b } performs ˆ if Cell(i) performs.i, Scheduler \ { b } lso performs.i ˆ if Cell(i) performs b.i, Scheduler \ { b } performs Supercombintor opertionl representtion cn be considered n implicit LTS becuse it gives n initil stte nd sufficient informtion to clculte ll the trnsitions of the system on-the-fly. Given root high-level process, we refer to tuples of the current sttes of its lef processes s configurtions. When running the root process, FDR computes its initil ctions by checking which supercombintors re enbled from the current configurtion nd the current formt of the root. supercombintor might be disbled if not ll lef processes re currently ble to communicte the event tht they re responsible for within the supercombintor. Hence, the opertionl semntics of the root process cn be considered n implicit LTS, whose trnsitions cn be switched on nd off. The sttes re represented by pir of configurtion nd formt of the root. Trnsitions re modelled by supercombintors. For exmple, the supercombintor ((c.1, c.1, ɛ, ɛ, ɛ), ) (see Figure 3(b)) would be enbled iff Cell(0 ) is in its stte s 1 nd Cell(1 ) is in its stte s 0, independent of the current sttes of the other three cells. If this rule is enbled nd the trnsition tken, Cell(0 ) will go to stte s 2, Cell(1 ) will go to stte s 1, the other three cells will not progress nd Scheduler \ { b } will perform. To summrise, supercombintors cn be viewed s implicit stte-spce representtions. They re generted by mimicking the SOS or combintor rules, but yield more compct storge nd more efficient lgorithms. Therefore, FDR is most efficient when mnipulting processes with reltively simple sequentil leves composed in prllel or pplied hiding or renming upon. Of course, highlevel processes cn be explicted, i.e. trnsformed into explicit LTS s, pying potentilly exponentil price. This is quite logicl s expliction breks down the hierrchicl structure of system composed of concurrent processes nd mkes it sequentil Refinement Checking Given two CSP processes Spec nd Impl, the refinement check Spec Impl reduces to checking for reverse continment of possible behviours. For the trces model, Spec T Impl iff trces(impl) 12

13 trces(spec). FDR crries out the refinement check on the level of the LTS representtions OS Spec = S s, s s 0, L s, T s nd OS Impl = S i, s i 0, L i, T i. The lgorithm is similr to the stndrd one for deciding lnguge continment L() L(B) of nondeterministic utomt nd B, which reduces to checking whether L() L(B) = nd requires tht B be determinised priori. In similr fshion, s preprocessing step, FDR normlises OS Spec, so tht OS Spec reches unique stte fter ny trce. The normlistion procedure requires s precondition tht OS Spec be explicted nd therefore Spec sequentilised. Essentilly, the normlistion procedure trnsforms OS Spec into the unique equivlent -free deterministic bisimultion-reduced LTS. We remrk tht ny finite-stte CSP process cn be normlised, lthough potentilly incurring n exponentil blow-up. fter normlising OS Spec, FDR trverses the Crtesin product of OS Spec nd OS Impl in bredth-first mnner, checking for comptibility of mutully-rechble sttes. For the trces model, pir of sttes (s s, s i ) is comptible if initils(s i ) initils(s s ). If the property is violted, the bredth-first mode of serch gurntees tht the counterexmple generted is of miniml length ST-Bsed Model Checking Techniques In this section, we give brief summry of ST-bsed bounded model checking [BCCZ99] nd temporl k-induction [ES03b] Bounded Model Checking Bounded model checking is sound but generlly incomplete technique tht focuses on serching for counterexmples of bounded length only. The underlying ide is to fix bound k nd unwind the implementtion model for k steps, thus considering behviours nd counterexmples of length t most k. In prctice, BMC is conducted itertively by progressively incresing k until one of the following hppens: (1) counterexmple is detected, (2) k reches precomputed threshold clled completeness threshold [CKOS04; CKOS05], which indictes tht the model stisfies the specifiction, or (3) the model checking instnce becomes intrctble. Different notions of completeness threshold exist, minly bsed on the properties of the underlying grph of the system, e.g. dimeter (the longest shortest pth between ny two sttes), recurrence dimeter (the longest simple pth between ny two sttes), forwrd nd bckwrd rdius versions of both, the size of the stte spce, etc. [BCCZ99; CKOS04; CKOS05; BHvMW09]. simple pth is pth long which ll sttes re different nd, in generl, the recurrence dimeter of grph cn be rbitrrily longer thn its dimeter (the sme holding for rdii) if we consider clique of size n, it s dimeter would be 1, while the recurrence dimeter would be n 1. We remrk tht this problem is excerbted when modelling concurrent systems due to the exponentil blow up of the stte spce. It is importnt to note tht without knowing or reching completeness threshold, the BMC procedure is incomplete since we do not know t wht step it is correct to stop iterting nd declre tht the system preserves the desired property. Therefore, BMC is mostly suitble for detecting bugs rther thn for full verifiction, i.e. proving the bsence of bugs. The problem with completeness thresholds is two-fold. On one hnd, clculting the exct completeness threshold cn be s hrd s the model checking problem itself [CKOS05] nd, therefore, sound overpproximtions of it re usully used in prctice. On the other hnd, in some cses those overpproximtions cn be too lrge to hndle efficiently. ST-bsed BMC [BCCZ99] reduces the model checking problem to propositionl stisfibility problem. The ide is to construct t ech step k Boolen formul which is stisfible if nd only if 13

14 there is counterexmple of length k. This formul is fed into ST-solver which decides the model checking problem in question nd produces counterexmple, if ny. Due to the DFS-nture of the ST decision procedure, this technique llows for fst detection of counterexmples. Moreover, due to the itertive nture of the BMC frmework, the counterexmple generted is of miniml length. In the originl syntctic [BCCZ99] nd the subsequent semntic [CKOS04; CKOS05] trnsltion of BMC to ST, the implementtion is modelled by Kripke structure M nd verified ginst specifiction f defined s n LTL formul. The BMC instnce t ech step k is trnslted to Boolen formul ϕ k = M k f k, where M k encodes ll pths of M of length k nd f k represents ll pths of length up to k tht violte f. Figure 4: Encoding pths of length k Generlly, hving Boolen encoding of the stte spce (e.g. binry or one-hot encoding [KB05]), the Kripke structure M cn be represented symboliclly by pir of Boolen functions I(s), T (s, s ) defined s the chrcteristic functions of the set of initil sttes nd the trnsition reltion, respectively. We use s nd s s shorthnd for the vectors of Boolen vribles necessry for encoding sttes of M. We replicte seprte copy of stte vribles s i for ech time step i. Then M k = I(s 0 ) k 1 i=0 T (s i, s i+1 ) (see Figure 4). We illustrte the structure of the entire formul ϕ k with simple exmple in cse f = Gp, where p represents stte predicte with Boolen encoding P : k ϕ k = I(s 0 ) k 1 i=0 T (s i, s i+1 ) i=0 P (s i ) Temporl k-induction Temporl k-induction [SSS00; ES03b] is complete ST-bsed technique for verifying sfety properties. s opposed to BMC, it cn be used lso for estblishing correctness of systems. Given model I(s), T (s, s ) nd sfety property P (s), the method checks if ll rechble sttes of the model preserve P. k-induction builds upon BMC nd is lso conducted itertively, s presented in lgorithm 1. It provides two conditions for termintion in cse the property is not violted k-inductiveness of P for some k N or reching the bckwrd recurrence rdius of the model with respect to P. The property P is k-inductive if it cn be proven tht if P holds long ll pths of the system of length k, then it cnnot be violted on pth of length k + 1. The bckwrd recurrence rdius is the length of the longest simple pth from ny stte to stte violting P nd is vlid completeness threshold. For ech step k, the temporl induction proof consists of two prts bse cse nd n induction step. The bse cse Bse k is similr to BMC instnce we check if, strting from n initil stte, there is pth of length k tht violtes P (see Figure 5). In the bse cse, we ssume tht we hve lredy checked ll bse cses of shorter length nd strengthen the BMC instnce by stting tht P holds long ll initil pths of length up to k 1. If the bse cse is stisfible, we hve found counterexmple. Otherwise, we proceed with the induction step Step k which is designed to prove tht P is k-inductive. The induction step is strengthened nd mde complete by constrint Simple k 14

15 lgorithm 1 Temporl k-induction [ES03b] 1: for k = 0 to do 2: if stisfible(bse k ) then 3: return property violted nd counterexmple trce 4: end if 5: if unstisfible(step k Simple k ) then 6: return property holds 7: end if 8: end for requiring tht ll sttes on the (k +1)-pth be different. Hence, k-induction termintes with positive nswer when reching the bckwrd recurrence r rdius even if the property P hs not mnifested itself s k-inductive for ny k r. ( Bse k = I(s 0 ) 0 i<k (P (s i ) T (s i, s i+1 ))) P (s k ) ( Step k = 0 i<k+1 (P (s i) T (s i, s i+1 ))) P (s k+1 ) Simple k = 0 i<j k (s i s j ) Figure 5: k-induction ingredients [ES03b] We remrk gin tht, in mny cses, the bckwrd rdius of the model the longest shortest pth from ny stte to stte violting P, cn be considerbly smller thn its bckwrd recurrence rdius. However, the trnsltion of shortest pths between two sttes to ST involves plenty of existentil quntifiers nd is mostly suitble to using QBF engine insted of ST solver. s we re deling with sfety properties, we cn lso crry out the k-induction lgorithm bckwrds, strting from sttes tht violte P nd trying to prove tht initil sttes re never rechble. This cn be implemented by redefining Bse k nd Step k s depicted in Figure 6. This lgorithm gurntees termintion upon reching the forwrd recurrence rdius the longest simple pth to ny stte strting from n initil stte. ( Bse k = P (s 0 ) 0 i<k ( I(s i ) T 1 (s i, s i+1 ))) I(s k ) ( Step k = 0 i<k+1 ( I(s i) T 1 (s i, s i+1 ))) I(s k+1 ) Simple k = 0 i<j k (s i s j ) Figure 6: Bckwrd k-induction ingredients 3. Bounded Trce Refinement Frmework In this section, we present our itertive bounded refinement checking lgorithm. Our pproch for estblishing trce refinement is bsed on wtchdog trnsformtions [RGM + 03]. Our objective is the following. We re given two CSP processes Spec nd Impl nd n integer k. We im t checking whether Spec k T Impl, i.e. whether ll executions of the implementtion of length t most k gree with the specifiction. Similrly to BMC nd k-induction, we crry out the nlysis on the level of the 15

16 opertionl representtion of Spec nd Impl. We point out tht executions of length k cn correspond to trces of smller length if hving ctions entngled within, s defined in Section Chllenges s the LTS s underlying the opertionl semntics of processes re event-bsed models, we need to lso hndle events in our encoding. Let OS Spec = I s (s), T s (s, l, s ) nd OS Impl = I i (t), T i (t, l, t ) be the models of Spec nd Impl, respectively. t first glnce, the most nturl pproch for encoding bounded execution refinement would be to try to directly mirror the originl trnsltion of BMC to ST. We would need to similrly construct the Boolen formul ϕ k s conjunction of two formule to model ll executions of Impl of length k tht re not executions of Spec ϕ k = OS Impl k OS Spec k. Hence, we would be looking for n instntition of the vectors of Boolen vribles l 1,..., l k, such tht OS Impl k = I i (t 0 ) k 1 i=0 T i (t i, l i, t i+1 ) is stisfible nd OS Spec k = I s (s 0 ) k 1 i=0 T s (s i, l i, s i+1 ) is not. Due to the implicit universl quntifiction of s 0,..., s k in the unstisfibility check of OS Spec k, this nlysis is mostly suitble to QBF engine. Using ST-solver in this cse would men tht we would need to extinguish ll possible stisfying ssignment of l 1,..., l k in OS Impl k nd to prove the unstisfibility of OS Spec k over ech one of them. Furthermore, invisible ctions cn be rbitrrily interleved in the executions of Impl nd, therefore, syntcticlly different executions cn produce semnticlly equivlent trces. This cn led to reporting spurious counterexmples. To illustrte this, consider the executions,,, b,, c of Impl nd, b, c of Spec s depicted on Figure 7(b). Even though they correspond to the sme trce, b, c, they do not mtch pointwise nd,,, b,, c would be flsely reported s violtion of Spec. However, bookkeeping the possible sequences of -s stuttered in between visible events does not seem to be trivil nd computtionlly justifible on the level of Boolen functions. () (b) Figure 7: ctions in bounded trce refinement 3.2. The Wtchdog pproch s explined in Section 2.1.6, FDR performs the refinement check by normlising the specifiction nd looking for the existence of behviours tht the implementtion llows nd the specifiction does not. s n lterntive, the wtchdog pproch [RGM + 03; Ros10] reduces the refinement check to nlysing single process constructed by composing the implementtion in prllel with trnsformed specifiction process. The ltter plys the role of wtchdog tht monitors the implementtion nd flgs ny behviours tht re considered violting with respect to the specifiction. 16

17 In our settings, using wtchdog trnsformtions llows us to ctully reduce bounded execution continment to bounded rechbility which is lredy menble to ST. The wtchdog trnsformtion phse is performed by mens of FDR Preprocessing Phse Using FDR Our implementtion is intended s n lterntive bck-end for FDR, orthogonl to the stndrd explicit method of performing trce refinement. Currently, we use shred librry version of FDR for mnipulting CSP processes nd we mimic FDR up to the point of the finl stte-spce explortion phse. Therefore, SymFDR reuses FDR s compiler nd supercompiler nd the dt structures underlying the hybrid two-level opertionl representtion of processes, consisting of process tree nd set of supercombintors, s defined in Section t present, we use FDR to supercompile nd normlise Spec nd to retrieve OS Spec representing the opertionl semntics of Spec. Without loss of generlity, we ssume tht the implementtion Impl comprises the interction of c sequentil processes P 1,..., P c running in prllel, possibly using hiding, renming or other CSP opertors other thn recursion. We write Impl = P 1 P 2... P c to ctully denote high-level process Impl with lef processes P 1,..., P c, s defined in Section This form of representing concurrent systems fter supercompiltion is of no limittion nd, s mentioned in Section 2.1.1, we cn hndle the entire CSP M syntx nd functionlity prt from the function chse. We use FDR to supercompile Impl nd to retrieve both the set of supercombintors nd the set {OS Pi i {1,..., c}} Wtchdog Bounded Refinement-Checking lgorithm In nutshell, the min steps of our lgorithm re the following: 1. We trnsform Spec into process Wtchdog which llows the behviours of both Spec nd Impl nd, in fct, mny others, but mrks those tht do not conform to Spec. The trnsformtion is crried out on the level of the LTS nd not on the higher CSP description of Spec. It is most esily defined if the specifiction process is normlised so tht it reches unique stte fter following ny trce. The LTS of Wtchdog is then obtined s n extension of OS Spec we dd fresh stte sink nd mke OS Spec totl with respect to the lphbet α Spec α Impl by directing ll non-existing trnsitions to sink. Formlly, hving OS Spec = S s, s s 0, T s, L s = α Spec, OS Wtchdog = S w = S s {sink}, s s 0, T w, L w = α Spec α Impl, where the trnsition reltion T w is defined s follows: T w = T s {(sink, l, sink) l α Spec α Impl } {(s, l, sink) s S s, l α Spec α Impl, s l } The resulting process Wtchdog opertionlly psses through sink whenever executing trce tht is not llowed by Spec. 2. We construct process Refinement = Wtchdog Impl = α Impl α Spec Wtchdog α Impl α Spec (P 1 P 2... P c ). Refinement cptures precisely the behviours of Impl, but those behviours tht do not conform to Spec force Wtchdog to brk, i.e. pss through its sink stte. Hence, Refinement cn be used s n indictor whether Impl cn behve in wy incomptible with Spec. Wtchdog becomes just one of the sequentil lef processes of Refinement. It is evident then tht: 17

18 () Spec T Impl Wtchdog never reches its sink stte in ny execution of Refinement. (b) ll executions of Refinement forcing Wtchdog to pss through its sink stte constitute vlid counterexmples of the ssertion Spec T Impl. 3. We check whether Wtchdog cn rech its sink stte within k steps of the execution of Refinement. 4. Boolen Encoding of CSP Processes In this section we present our encoding of CSP processes into Boolen formule. First, we show how to encode sequentil or explicted processes, corresponding to lef processes in the opertionl representtion. Then, we show how to glue together sequentil processes with supercombintors to obtin n encoding of high-level process. In wht follows, we cll high-level process concurrent system. For illustrting the Boolen encoding in this section, we use the following nottion. X (Vrs) denotes the Boolen encoding of X with respect to the vector(s) of Boolen vribles Vrs. Generlly, to encode finite set of elements S, we use n injective mpping enc S : S {0, 1} m to ssocite ech element s S with unique bit vector b = (b 1,..., b m ) of certin size m. To represent elements of S s Boolen functions, we introduce n ordered vector of m distinct Boolen vribles x = (x 1,..., x m ). Ech vrible x i uniquely identifies the corresponding bit b i nd for ech s S, s (x) x=b = 1 iff enc S (s) = b. Typiclly, binry or one-hot [KB05] encoding of sets re used in prctice. The bsic ide behind binry encoding is to enumerte the elements of S in binry nottion nd represent them s Boolen functions over m = log 2 S Boolen vribles. In one-hot encoding, ech s S is represented by bit vector of size S in which precisely one bit is set to 1. To illustrte the two encodings, let us consider the set S = {s 0, s 1, s 2, s 3 }. If we consider the binry encoding s 0 = (00), s 1 = (01), s 2 = (10), s 3 = (11), vector of just two vribles x = (x 0, x 1 ) suffices nd s 1 (x) = x 0 x 1, for exmple. For the one-hot encoding s 0 = (1000), s 1 = (0100), s 2 = (0010), s 3 = (0001), we need vector x = (x 0, x 1, x 2, x 3 ) of four vribles nd s 1 (x) = x 0 x 1 x 2 x 3. lterntively, we cn use s 1 (x) = x 1, but in this cse we need to dd globl constrints enforcing tht precisely one bit is set to true t given time instnce. Those constrints cn be expressed by formul of size liner in S Encoding Sequentil Process s explined in Section 3.3, for ech sequentil lef process P, we obtin the explicit opertionl representtion of P using FDR. Let OS P = S, s 0, L = Σ,, T be the LTS ssocited with the finite-stte lef process P communicting over finite lphbet of events Σ. Using either binry or one-hot encoding of sets, we introduce vectors of Boolen vribles x nd y for encoding the set of sttes S nd the set of lbels L, respectively. We define I (x) = s 0 (x). In order to represent the trnsition reltion T, we employ copy x of x. x serves to represent the source sttes of trnsitions nd x the destintion sttes. Then, for t = (s src, l, s dest ) T, t (x, y, x ) = s src (x) l (y) s dest (x ). For ny s S, we write s (x ) to denote s (x)[x x], i.e. we represent s with respect to the vribles x nd then substitute the vribles x with x. The encoding of the entire trnsition reltion is the following: T (x, y, x ) = t T t (x, y, x ). We cn now represent sequentil process P implicitly by pir of Boolen functions T P (x, y, x ), I P (x). For given integer k, we define Pths(P, k) to be the set of ll executions s 0 l 1 s 1 l 2... l k s k of OS P of length k. In order to represent Pths(P, k) symboliclly, we replicte (k + 1) vectors of Boolen vribles x 0, x 1... x k for encoding the sttes s 0, s 1,..., s k nd k vectors of Boolen vribles 18

Process Algebra CSP A Technique to Model Concurrent Programs

Process Algebra CSP A Technique to Model Concurrent Programs Process Algebr CSP A Technique to Model Concurrent Progrms Jnury 15, 2002 Hui Shi 1 Contents CSP-Processes Opertionl Semntics Trnsition systems nd stte mchines Bisimultion Firing rules for CSP Model-Checker

More information

Refined interfaces for compositional verification

Refined interfaces for compositional verification Refined interfces for compositionl verifiction Frédéric Lng INRI Rhône-lpes http://www.inrilpes.fr/vsy Motivtion Enumertive verifiction of concurrent systems Prllel composition of synchronous processes

More information

Concepts of Concurrent Computation Spring 2015 Lecture 9: Petri Nets

Concepts of Concurrent Computation Spring 2015 Lecture 9: Petri Nets Concepts of Concurrent Computtion Spring 205 Lecture 9: Petri Nets Sebstin Nnz Chris Poskitt Chir of Softwre Engineering Petri nets Petri nets re mthemticl models for describing systems with concurrency

More information

KNOWLEDGE-BASED AGENTS INFERENCE

KNOWLEDGE-BASED AGENTS INFERENCE AGENTS THAT REASON LOGICALLY KNOWLEDGE-BASED AGENTS Two components: knowledge bse, nd n inference engine. Declrtive pproch to building n gent. We tell it wht it needs to know, nd It cn sk itself wht to

More information

Bisimulation. R.J. van Glabbeek

Bisimulation. R.J. van Glabbeek Bisimultion R.J. vn Glbbeek NICTA, Sydney, Austrli. School of Computer Science nd Engineering, The University of New South Wles, Sydney, Austrli. Computer Science Deprtment, Stnford University, CA 94305-9045,

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

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

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

Handout: Natural deduction for first order logic

Handout: Natural deduction for first order logic MATH 457 Introduction to Mthemticl Logic Spring 2016 Dr Json Rute Hndout: Nturl deduction for first order logic We will extend our nturl deduction rules for sententil logic to first order logic These notes

More information

1 Online Learning and Regret Minimization

1 Online Learning and Regret Minimization 2.997 Decision-Mking in Lrge-Scle Systems My 10 MIT, Spring 2004 Hndout #29 Lecture Note 24 1 Online Lerning nd Regret Minimiztion In this lecture, we consider the problem of sequentil decision mking in

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

1.3 Regular Expressions

1.3 Regular Expressions 56 1.3 Regulr xpressions These hve n importnt role in describing ptterns in serching for strings in mny pplictions (e.g. wk, grep, Perl,...) All regulr expressions of lphbet re 1.Ønd re regulr expressions,

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

Properties of Integrals, Indefinite Integrals. Goals: Definition of the Definite Integral Integral Calculations using Antiderivatives

Properties of Integrals, Indefinite Integrals. Goals: Definition of the Definite Integral Integral Calculations using Antiderivatives Block #6: Properties of Integrls, Indefinite Integrls Gols: Definition of the Definite Integrl Integrl Clcultions using Antiderivtives Properties of Integrls The Indefinite Integrl 1 Riemnn Sums - 1 Riemnn

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

p-adic Egyptian Fractions

p-adic Egyptian Fractions p-adic Egyptin Frctions Contents 1 Introduction 1 2 Trditionl Egyptin Frctions nd Greedy Algorithm 2 3 Set-up 3 4 p-greedy Algorithm 5 5 p-egyptin Trditionl 10 6 Conclusion 1 Introduction An Egyptin frction

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

THE EXISTENCE-UNIQUENESS THEOREM FOR FIRST-ORDER DIFFERENTIAL EQUATIONS.

THE EXISTENCE-UNIQUENESS THEOREM FOR FIRST-ORDER DIFFERENTIAL EQUATIONS. THE EXISTENCE-UNIQUENESS THEOREM FOR FIRST-ORDER DIFFERENTIAL EQUATIONS RADON ROSBOROUGH https://intuitiveexplntionscom/picrd-lindelof-theorem/ This document is proof of the existence-uniqueness theorem

More information

Finite Automata. Informatics 2A: Lecture 3. Mary Cryan. 21 September School of Informatics University of Edinburgh

Finite Automata. Informatics 2A: Lecture 3. Mary Cryan. 21 September School of Informatics University of Edinburgh Finite Automt Informtics 2A: Lecture 3 Mry Cryn School of Informtics University of Edinburgh mcryn@inf.ed.c.uk 21 September 2018 1 / 30 Lnguges nd Automt Wht is lnguge? Finite utomt: recp Some forml definitions

More information

1.9 C 2 inner variations

1.9 C 2 inner variations 46 CHAPTER 1. INDIRECT METHODS 1.9 C 2 inner vritions So fr, we hve restricted ttention to liner vritions. These re vritions of the form vx; ǫ = ux + ǫφx where φ is in some liner perturbtion clss P, for

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

CMDA 4604: Intermediate Topics in Mathematical Modeling Lecture 19: Interpolation and Quadrature

CMDA 4604: Intermediate Topics in Mathematical Modeling Lecture 19: Interpolation and Quadrature CMDA 4604: Intermedite Topics in Mthemticl Modeling Lecture 19: Interpoltion nd Qudrture In this lecture we mke brief diversion into the res of interpoltion nd qudrture. Given function f C[, b], we sy

More information

Week 10: Line Integrals

Week 10: Line Integrals Week 10: Line Integrls Introduction In this finl week we return to prmetrised curves nd consider integrtion long such curves. We lredy sw this in Week 2 when we integrted long curve to find its length.

More information

Lecture 1. Functional series. Pointwise and uniform convergence.

Lecture 1. Functional series. Pointwise and uniform convergence. 1 Introduction. Lecture 1. Functionl series. Pointwise nd uniform convergence. In this course we study mongst other things Fourier series. The Fourier series for periodic function f(x) with period 2π is

More information

NUMERICAL INTEGRATION. The inverse process to differentiation in calculus is integration. Mathematically, integration is represented by.

NUMERICAL INTEGRATION. The inverse process to differentiation in calculus is integration. Mathematically, integration is represented by. NUMERICAL INTEGRATION 1 Introduction The inverse process to differentition in clculus is integrtion. Mthemticlly, integrtion is represented by f(x) dx which stnds for the integrl of the function f(x) with

More information

Equality and Inequality in the Dataflow Algebra. A. J. Cowling

Equality and Inequality in the Dataflow Algebra. A. J. Cowling Verifiction nd Testing Reserch Group, Deprtment of Computer Science, University of Sheffield, Regent Court, 211, Portobello Street, Sheffield, S1 4DP, United Kingdom Emil: A.Cowling @ dcs.shef.c.uk Telephone:

More information

Learning Moore Machines from Input-Output Traces

Learning Moore Machines from Input-Output Traces Lerning Moore Mchines from Input-Output Trces Georgios Gintmidis 1 nd Stvros Tripkis 1,2 1 Alto University, Finlnd 2 UC Berkeley, USA Motivtion: lerning models from blck boxes Inputs? Lerner Forml Model

More information

CS 275 Automata and Formal Language Theory

CS 275 Automata and Formal Language Theory CS 275 Automt nd Forml Lnguge Theory Course Notes Prt II: The Recognition Problem (II) Chpter II.6.: Push Down Automt Remrk: This mteril is no longer tught nd not directly exm relevnt Anton Setzer (Bsed

More information

How to simulate Turing machines by invertible one-dimensional cellular automata

How to simulate Turing machines by invertible one-dimensional cellular automata How to simulte Turing mchines by invertible one-dimensionl cellulr utomt Jen-Christophe Dubcq Déprtement de Mthémtiques et d Informtique, École Normle Supérieure de Lyon, 46, llée d Itlie, 69364 Lyon Cedex

More information

Advanced Calculus: MATH 410 Notes on Integrals and Integrability Professor David Levermore 17 October 2004

Advanced Calculus: MATH 410 Notes on Integrals and Integrability Professor David Levermore 17 October 2004 Advnced Clculus: MATH 410 Notes on Integrls nd Integrbility Professor Dvid Levermore 17 October 2004 1. Definite Integrls In this section we revisit the definite integrl tht you were introduced to when

More information

Chapter 0. What is the Lebesgue integral about?

Chapter 0. What is the Lebesgue integral about? Chpter 0. Wht is the Lebesgue integrl bout? The pln is to hve tutoril sheet ech week, most often on Fridy, (to be done during the clss) where you will try to get used to the ides introduced in the previous

More information

20 MATHEMATICS POLYNOMIALS

20 MATHEMATICS POLYNOMIALS 0 MATHEMATICS POLYNOMIALS.1 Introduction In Clss IX, you hve studied polynomils in one vrible nd their degrees. Recll tht if p(x) is polynomil in x, the highest power of x in p(x) is clled the degree of

More information

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

Supervisory Control (4CM30)

Supervisory Control (4CM30) Supervisory Control (4CM30) Verifiction in mcrl2 Michel Reniers M.A.Reniers@tue.nl 2016-2017 Verifiction in mcrl2 M CIF = φ CIF iff M mcrl2 = φ mcrl2 1. Adpt CIF model 2. Formulte property in modl µ-clculus

More information

This lecture covers Chapter 8 of HMU: Properties of CFLs

This lecture covers Chapter 8 of HMU: Properties of CFLs This lecture covers Chpter 8 of HMU: Properties of CFLs Turing Mchine Extensions of Turing Mchines Restrictions of Turing Mchines Additionl Reding: Chpter 8 of HMU. Turing Mchine: Informl Definition B

More information

CS 275 Automata and Formal Language Theory

CS 275 Automata and Formal Language Theory CS 275 Automt nd Forml Lnguge Theory Course Notes Prt II: The Recognition Problem (II) Chpter II.5.: Properties of Context Free Grmmrs (14) Anton Setzer (Bsed on book drft by J. V. Tucker nd K. Stephenson)

More information

State space systems analysis (continued) Stability. A. Definitions A system is said to be Asymptotically Stable (AS) when it satisfies

State space systems analysis (continued) Stability. A. Definitions A system is said to be Asymptotically Stable (AS) when it satisfies Stte spce systems nlysis (continued) Stbility A. Definitions A system is sid to be Asymptoticlly Stble (AS) when it stisfies ut () = 0, t > 0 lim xt () 0. t A system is AS if nd only if the impulse response

More information

Riemann Sums and Riemann Integrals

Riemann Sums and Riemann Integrals Riemnn Sums nd Riemnn Integrls Jmes K. Peterson Deprtment of Biologicl Sciences nd Deprtment of Mthemticl Sciences Clemson University August 26, 203 Outline Riemnn Sums Riemnn Integrls Properties Abstrct

More information

Riemann Sums and Riemann Integrals

Riemann Sums and Riemann Integrals Riemnn Sums nd Riemnn Integrls Jmes K. Peterson Deprtment of Biologicl Sciences nd Deprtment of Mthemticl Sciences Clemson University August 26, 2013 Outline 1 Riemnn Sums 2 Riemnn Integrls 3 Properties

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

Informe Técnico / Technical Report

Informe Técnico / Technical Report DEPARTAMENTO DE SISTEMAS INFORMÁTICOS Y COMPUTACIÓN UNIVERSIDAD POLITÉCNICA DE VALENCIA P.O. Box: 22012 E-46071 Vlenci (SPAIN) Informe Técnico / Technicl Report Ref. No.: DSIC-II/03/10 Pges: 30 Title:

More information

CS 188: Artificial Intelligence Spring 2007

CS 188: Artificial Intelligence Spring 2007 CS 188: Artificil Intelligence Spring 2007 Lecture 3: Queue-Bsed Serch 1/23/2007 Srini Nrynn UC Berkeley Mny slides over the course dpted from Dn Klein, Sturt Russell or Andrew Moore Announcements Assignment

More information

Reinforcement Learning

Reinforcement Learning Reinforcement Lerning Tom Mitchell, Mchine Lerning, chpter 13 Outline Introduction Comprison with inductive lerning Mrkov Decision Processes: the model Optiml policy: The tsk Q Lerning: Q function Algorithm

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

1.4 Nonregular Languages

1.4 Nonregular Languages 74 1.4 Nonregulr Lnguges The number of forml lnguges over ny lphbet (= decision/recognition problems) is uncountble On the other hnd, the number of regulr expressions (= strings) is countble Hence, ll

More information

19 Optimal behavior: Game theory

19 Optimal behavior: Game theory Intro. to Artificil Intelligence: Dle Schuurmns, Relu Ptrscu 1 19 Optiml behvior: Gme theory Adversril stte dynmics hve to ccount for worst cse Compute policy π : S A tht mximizes minimum rewrd Let S (,

More information

Chapter 4 Contravariance, Covariance, and Spacetime Diagrams

Chapter 4 Contravariance, Covariance, and Spacetime Diagrams Chpter 4 Contrvrince, Covrince, nd Spcetime Digrms 4. The Components of Vector in Skewed Coordintes We hve seen in Chpter 3; figure 3.9, tht in order to show inertil motion tht is consistent with the Lorentz

More information

Review of basic calculus

Review of basic calculus Review of bsic clculus This brief review reclls some of the most importnt concepts, definitions, nd theorems from bsic clculus. It is not intended to tech bsic clculus from scrtch. If ny of the items below

More information

Math 1B, lecture 4: Error bounds for numerical methods

Math 1B, lecture 4: Error bounds for numerical methods Mth B, lecture 4: Error bounds for numericl methods Nthn Pflueger 4 September 0 Introduction The five numericl methods descried in the previous lecture ll operte by the sme principle: they pproximte the

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

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

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

Introduction to spefication and verification Lecture Notes, autumn 2011

Introduction to spefication and verification Lecture Notes, autumn 2011 Introduction to spefiction nd verifiction Lecture Notes, utumn 2011 Timo Krvi UNIVERSITY OF HELSINKI FINLAND Contents 1 Introduction 1 1.1 The strting point............................ 1 1.2 Globl stte

More information

The First Fundamental Theorem of Calculus. If f(x) is continuous on [a, b] and F (x) is any antiderivative. f(x) dx = F (b) F (a).

The First Fundamental Theorem of Calculus. If f(x) is continuous on [a, b] and F (x) is any antiderivative. f(x) dx = F (b) F (a). The Fundmentl Theorems of Clculus Mth 4, Section 0, Spring 009 We now know enough bout definite integrls to give precise formultions of the Fundmentl Theorems of Clculus. We will lso look t some bsic emples

More information

CMSC 330: Organization of Programming Languages. DFAs, and NFAs, and Regexps (Oh my!)

CMSC 330: Organization of Programming Languages. DFAs, and NFAs, and Regexps (Oh my!) CMSC 330: Orgniztion of Progrmming Lnguges DFAs, nd NFAs, nd Regexps (Oh my!) CMSC330 Spring 2018 Types of Finite Automt Deterministic Finite Automt (DFA) Exctly one sequence of steps for ech string All

More information

Goals: Determine how to calculate the area described by a function. Define the definite integral. Explore the relationship between the definite

Goals: Determine how to calculate the area described by a function. Define the definite integral. Explore the relationship between the definite Unit #8 : The Integrl Gols: Determine how to clculte the re described by function. Define the definite integrl. Eplore the reltionship between the definite integrl nd re. Eplore wys to estimte the definite

More information

5.7 Improper Integrals

5.7 Improper Integrals 458 pplictions of definite integrls 5.7 Improper Integrls In Section 5.4, we computed the work required to lift pylod of mss m from the surfce of moon of mss nd rdius R to height H bove the surfce of the

More information

LTL Translation Improvements in Spot

LTL Translation Improvements in Spot LTL Trnsltion Improvements in Spot Alexndre Duret-Lutz http://www.lrde.epit.fr/~dl/ VECoS'11 16 September 2011 Alexndre Duret-Lutz LTL Trnsltion Improvements 1 / 19 Context High-level

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

7.2 The Definite Integral

7.2 The Definite Integral 7.2 The Definite Integrl the definite integrl In the previous section, it ws found tht if function f is continuous nd nonnegtive, then the re under the grph of f on [, b] is given by F (b) F (), where

More information

MAA 4212 Improper Integrals

MAA 4212 Improper Integrals Notes by Dvid Groisser, Copyright c 1995; revised 2002, 2009, 2014 MAA 4212 Improper Integrls The Riemnn integrl, while perfectly well-defined, is too restrictive for mny purposes; there re functions which

More information

63. Representation of functions as power series Consider a power series. ( 1) n x 2n for all 1 < x < 1

63. Representation of functions as power series Consider a power series. ( 1) n x 2n for all 1 < x < 1 3 9. SEQUENCES AND SERIES 63. Representtion of functions s power series Consider power series x 2 + x 4 x 6 + x 8 + = ( ) n x 2n It is geometric series with q = x 2 nd therefore it converges for ll q =

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

Notes on specifying systems in EST

Notes on specifying systems in EST Robert Meolic, Ttjn Kpus: Notes on specifying systems in EST 1 Notes on specifying systems in EST Robert Meolic, Ttjn Kpus Fculty of EE & CS University of Mribor Robert Meolic, Ttjn Kpus: Notes on specifying

More information

Duality # Second iteration for HW problem. Recall our LP example problem we have been working on, in equality form, is given below.

Duality # Second iteration for HW problem. Recall our LP example problem we have been working on, in equality form, is given below. Dulity #. Second itertion for HW problem Recll our LP emple problem we hve been working on, in equlity form, is given below.,,,, 8 m F which, when written in slightly different form, is 8 F Recll tht we

More information

Bernoulli Numbers Jeff Morton

Bernoulli Numbers Jeff Morton Bernoulli Numbers Jeff Morton. We re interested in the opertor e t k d k t k, which is to sy k tk. Applying this to some function f E to get e t f d k k tk d k f f + d k k tk dk f, we note tht since f

More information

New Expansion and Infinite Series

New Expansion and Infinite Series Interntionl Mthemticl Forum, Vol. 9, 204, no. 22, 06-073 HIKARI Ltd, www.m-hikri.com http://dx.doi.org/0.2988/imf.204.4502 New Expnsion nd Infinite Series Diyun Zhng College of Computer Nnjing University

More information

Recitation 3: More Applications of the Derivative

Recitation 3: More Applications of the Derivative Mth 1c TA: Pdric Brtlett Recittion 3: More Applictions of the Derivtive Week 3 Cltech 2012 1 Rndom Question Question 1 A grph consists of the following: A set V of vertices. A set E of edges where ech

More information

Semantic reachability for simple process algebras. Richard Mayr. Abstract

Semantic reachability for simple process algebras. Richard Mayr. Abstract Semntic rechbility for simple process lgebrs Richrd Myr Abstrct This pper is n pproch to combine the rechbility problem with semntic notions like bisimultion equivlence. It dels with questions of the following

More information

Physics 116C Solution of inhomogeneous ordinary differential equations using Green s functions

Physics 116C Solution of inhomogeneous ordinary differential equations using Green s functions Physics 6C Solution of inhomogeneous ordinry differentil equtions using Green s functions Peter Young November 5, 29 Homogeneous Equtions We hve studied, especilly in long HW problem, second order liner

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

Review of Calculus, cont d

Review of Calculus, cont d Jim Lmbers MAT 460 Fll Semester 2009-10 Lecture 3 Notes These notes correspond to Section 1.1 in the text. Review of Clculus, cont d Riemnn Sums nd the Definite Integrl There re mny cses in which some

More information

We partition C into n small arcs by forming a partition of [a, b] by picking s i as follows: a = s 0 < s 1 < < s n = b.

We partition C into n small arcs by forming a partition of [a, b] by picking s i as follows: a = s 0 < s 1 < < s n = b. Mth 255 - Vector lculus II Notes 4.2 Pth nd Line Integrls We begin with discussion of pth integrls (the book clls them sclr line integrls). We will do this for function of two vribles, but these ides cn

More information

Improper Integrals, and Differential Equations

Improper Integrals, and Differential Equations Improper Integrls, nd Differentil Equtions October 22, 204 5.3 Improper Integrls Previously, we discussed how integrls correspond to res. More specificlly, we sid tht for function f(x), the region creted

More information

Uninformed Search Lecture 4

Uninformed Search Lecture 4 Lecture 4 Wht re common serch strtegies tht operte given only serch problem? How do they compre? 1 Agend A quick refresher DFS, BFS, ID-DFS, UCS Unifiction! 2 Serch Problem Formlism Defined vi the following

More information

Semantic Reachability. Richard Mayr. Institut fur Informatik. Technische Universitat Munchen. Arcisstr. 21, D Munchen, Germany E. N. T. C. S.

Semantic Reachability. Richard Mayr. Institut fur Informatik. Technische Universitat Munchen. Arcisstr. 21, D Munchen, Germany E. N. T. C. S. URL: http://www.elsevier.nl/locte/entcs/volume6.html?? pges Semntic Rechbility Richrd Myr Institut fur Informtik Technische Universitt Munchen Arcisstr. 21, D-80290 Munchen, Germny e-mil: myrri@informtik.tu-muenchen.de

More information

DIRECT CURRENT CIRCUITS

DIRECT CURRENT CIRCUITS DRECT CURRENT CUTS ELECTRC POWER Consider the circuit shown in the Figure where bttery is connected to resistor R. A positive chrge dq will gin potentil energy s it moves from point to point b through

More information

Global Session Types for Dynamic Checking of Protocol Conformance of Multi-Agent Systems

Global Session Types for Dynamic Checking of Protocol Conformance of Multi-Agent Systems Globl Session Types for Dynmic Checking of Protocol Conformnce of Multi-Agent Systems (Extended Abstrct) Dvide Ancon, Mtteo Brbieri, nd Vivin Mscrdi DIBRIS, University of Genov, Itly emil: dvide@disi.unige.it,

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

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

Reinforcement learning II

Reinforcement learning II CS 1675 Introduction to Mchine Lerning Lecture 26 Reinforcement lerning II Milos Huskrecht milos@cs.pitt.edu 5329 Sennott Squre Reinforcement lerning Bsics: Input x Lerner Output Reinforcement r Critic

More information

Global Types for Dynamic Checking of Protocol Conformance of Multi-Agent Systems

Global Types for Dynamic Checking of Protocol Conformance of Multi-Agent Systems Globl Types for Dynmic Checking of Protocol Conformnce of Multi-Agent Systems (Extended Abstrct) Dvide Ancon, Mtteo Brbieri, nd Vivin Mscrdi DIBRIS, University of Genov, Itly emil: dvide@disi.unige.it,

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

SUMMER KNOWHOW STUDY AND LEARNING CENTRE

SUMMER KNOWHOW STUDY AND LEARNING CENTRE SUMMER KNOWHOW STUDY AND LEARNING CENTRE Indices & Logrithms 2 Contents Indices.2 Frctionl Indices.4 Logrithms 6 Exponentil equtions. Simplifying Surds 13 Opertions on Surds..16 Scientific Nottion..18

More information

CS 188 Introduction to Artificial Intelligence Fall 2018 Note 7

CS 188 Introduction to Artificial Intelligence Fall 2018 Note 7 CS 188 Introduction to Artificil Intelligence Fll 2018 Note 7 These lecture notes re hevily bsed on notes originlly written by Nikhil Shrm. Decision Networks In the third note, we lerned bout gme trees

More information

Numerical Integration

Numerical Integration Chpter 1 Numericl Integrtion Numericl differentition methods compute pproximtions to the derivtive of function from known vlues of the function. Numericl integrtion uses the sme informtion to compute numericl

More information

Good-for-Games Automata versus Deterministic Automata.

Good-for-Games Automata versus Deterministic Automata. Good-for-Gmes Automt versus Deterministic Automt. Denis Kuperberg 1,2 Mich l Skrzypczk 1 1 University of Wrsw 2 IRIT/ONERA (Toulouse) Séminire MoVe 12/02/2015 LIF, Luminy Introduction Deterministic utomt

More information

Unit #9 : Definite Integral Properties; Fundamental Theorem of Calculus

Unit #9 : Definite Integral Properties; Fundamental Theorem of Calculus Unit #9 : Definite Integrl Properties; Fundmentl Theorem of Clculus Gols: Identify properties of definite integrls Define odd nd even functions, nd reltionship to integrl vlues Introduce the Fundmentl

More information

CS 275 Automata and Formal Language Theory

CS 275 Automata and Formal Language Theory CS 275 utomt nd Forml Lnguge Theory Course Notes Prt II: The Recognition Prolem (II) Chpter II.5.: Properties of Context Free Grmmrs (14) nton Setzer (Bsed on ook drft y J. V. Tucker nd K. Stephenson)

More information

Parse trees, ambiguity, and Chomsky normal form

Parse trees, ambiguity, and Chomsky normal form Prse trees, miguity, nd Chomsky norml form In this lecture we will discuss few importnt notions connected with contextfree grmmrs, including prse trees, miguity, nd specil form for context-free grmmrs

More information

New data structures to reduce data size and search time

New data structures to reduce data size and search time New dt structures to reduce dt size nd serch time Tsuneo Kuwbr Deprtment of Informtion Sciences, Fculty of Science, Kngw University, Hirtsuk-shi, Jpn FIT2018 1D-1, No2, pp1-4 Copyright (c)2018 by The Institute

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

CS5371 Theory of Computation. Lecture 20: Complexity V (Polynomial-Time Reducibility)

CS5371 Theory of Computation. Lecture 20: Complexity V (Polynomial-Time Reducibility) CS5371 Theory of Computtion Lecture 20: Complexity V (Polynomil-Time Reducibility) Objectives Polynomil Time Reducibility Prove Cook-Levin Theorem Polynomil Time Reducibility Previously, we lernt tht if

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

Event Structures for Arbitrary Disruption

Event Structures for Arbitrary Disruption Fundment Informtice XX (2005) 1 28 1 IOS Press Event Structures for Arbitrry Disruption Hrld Fecher Christin Albrecht Universität zu Kiel Technische Fkultät, Institut für Informtik, Hermnn-Rodewldstr.

More information

Genetic Programming. Outline. Evolutionary Strategies. Evolutionary strategies Genetic programming Summary

Genetic Programming. Outline. Evolutionary Strategies. Evolutionary strategies Genetic programming Summary Outline Genetic Progrmming Evolutionry strtegies Genetic progrmming Summry Bsed on the mteril provided y Professor Michel Negnevitsky Evolutionry Strtegies An pproch simulting nturl evolution ws proposed

More information

Nenofex: Expanding NNF for QBF Solving

Nenofex: Expanding NNF for QBF Solving Institute for Forml Models nd Verifiction (FMV) Johnnes Kepler University, Linz, Austri Nenofex Negtion Norml Form Expnsion Solver for Quntified Boolen Formule (QBF) propositionl formul + quntified vribles

More information

Extending CSP with tests for availability

Extending CSP with tests for availability Communicting rocess Architectures 2009 eter Welch, Hermn Roebbers nd Tobe Announced (Eds.) IOS ress, 2009 1 c 2009 The uthors nd IOS ress. All rights reserved. 1 Extending CS with tests for vilbility Gvin

More information

COMPUTER SCIENCE TRIPOS

COMPUTER SCIENCE TRIPOS CST.2011.2.1 COMPUTER SCIENCE TRIPOS Prt IA Tuesdy 7 June 2011 1.30 to 4.30 COMPUTER SCIENCE Pper 2 Answer one question from ech of Sections A, B nd C, nd two questions from Section D. Submit the nswers

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