An Approach To Formalization of an Extension of Floyd-Hoare Logic

Size: px
Start display at page:

Download "An Approach To Formalization of an Extension of Floyd-Hoare Logic"

Transcription

1 An Approach To Formalizaion of an Exension of Floyd-Hoare Logic Arur Korni lowicz 1, Andrii Kryvolap 2, Mykola Nikichenko 2, Ievgen Ivanov 2 1 Insiue of Informaics, Universiy of Bia lysok, Cio lkowskiego 1M, Bia lysok, Poland 2 Taras Shevchenko Naional Universiy of Kyiv 64/13, Volodymyrska Sree, Kyiv, Ukraine arurk@mah.uwb.edu.pl, krivolapa@gmail.com, nikichenko@unicyb.kiev.ua, ivanov.eugen@gmail.com Absrac. The classical Floyd-Hoare logic is defined for he case of oal pre- and poscondiions and parial programs (i.e. programs can be undefined on some inpu daa, bu condiions mus be defined on all daa). In his paper we propose an exension of his logic for he case of parial condiions and parial programs on hierarchically organized daa. These daa are based on he naming relaion and are called nominaive daa. They can convenienly represen many daa srucures used in programming. The semanics of he proposed logic is represened by special algebras of parial funcions and predicaes over nominaive daa. Operaions of hese algebras are called composiions. We presen an inference sysem for he menioned logic and propose an approach o is formalizaion in Mizar proof assisan. The obained resuls can be used in sofware verificaion. Keywords. Formal mehods, sofware verificaion, Floyd-Hoare logic, proof assisan, nominaive daa. Key Terms. Specificaion Process, Verificaion Process 1 Inroducion Floyd-Hoare logic [1 3] is a formal sysem widely used for reasoning abou program correcness. I is based on he noion of a Floyd-Hoare riple (asserion) which consiss of a precondiion, a program, and a poscondiion and means he following requiremen: when inpu daa saisfies he precondiion, he program oupu mus saisfy he poscondiion, if he program erminaes. Specificaion of program properies in erms of Floyd-Hoare riples is naural and reasoning is convenien hanks o a composiional proof sysem. A survey of he imporan resuls on properies of he Hoare s proof sysem (soundness, compleeness in specific senses) and is exensions was given in [3]. In he classical Floyd-Hoare logic predicaes (pre- and poscondiions) are assumed o be oal (defined on all daa) and programs can be parial (in he

2 sense ha if a program does no erminae, is resuling value is undefined). The abiliy o deal wih parialiy is an imporan aspec, because parial operaions frequenly arise in programming. In mos programming languages some basic operaions on daa such as arihmeic division are already parial. Furhermore, parialiy of programs may be caused by non-erminaion which can arise from loop consrucs and/or recursion. For similar reasons parialiy can arise in sofware specificaions. In [4] he following classificaion of parialiy phenomena in sofware specificaions was proposed: non-erminaion, i.e. if evaluaion of an expression does no erminae, is value is assumed o be undefined and he operaion is considered parial; error value, i.e. if some values of an operaion s argumen are illegal (e.g. division by zero, Pop operaion applied o an empy sack, ec.), he resul of he operaion on such values is assumed o be undefined and he operaion is considered parial; and nondeerminism, i.e. if a resul of an operaion on an argumen value is no deermined uniquely by he specificaion of his operaion (operaion is underspecified), he resul of applicaion of he operaion o such a value is assumed o be undefined and he operaion is considered parial. Oher opinions on he meanings of parialiy in sofware specificaions can be found in [5 7]. In [5] a axonomy of he ways of dealing wih parialiy in sofware specificaion languages and logics was proposed. Among differen approaches noable are excluding parial funcions from consideraion and providing alernaive noaions (e.g. graph of a parial funcion), using a hree-valued (many-valued) logic, where he hird value represens an undefined resul, or making all funcion applicaions denoe [5]. I should be noed ha almos all approaches ha ry o no allow parial programs and/or predicaes ha describe program guards or properies explicily and reduce or ranslae hem o he classical case of oal funcions and predicaes have drawbacks analyzed in deail in [4 6]. A more naural and poenially fruiful approach is o allow parialiy in boh programs and program specificaions and consruc non-classical proof sysems allowing explici reasoning abou properies of such programs and specificaions. This approach is applied in his paper o Floyd-Hoare logic. More specifically, in he classical Floyd-Hoare logic he predicaes describing program pre- and poscondiions are assumed o be oal. Bu obviously, i is desirable o be able o use parial operaions in pre- and poscondiions of programs, where parialiy may be inerpreed in one of he senses proposed in [4]. So i is desirable o obain an exension of Floyd-Hoare logic ha is able o deal wih boh parial programs and parial predicaes. We consider such an exension in his paper. In he previous works [8, 9] we have considered exensions of Floyd-Hoare logic o parial mappings over daa represened as parial mappings on named values (called nominaive ses) and proposed he corresponding inference sysems and invesigaed heir soundness and exensional and inensional compleeness. However, nominaive ses (which can be considered as parial funcions from names o values) naurally represen only a fla daa organizaion in low-level programming. Using Floyd-Hoare logic

3 wih parial mappings over nominaive ses for reasoning abou programs which operae on complex daa srucures (e.g. rees) is inconvenien, because one needs o ake ino accoun many low-level deails abou daa srucure implemenaion. For his reason, in his paper we propose an exension of Floyd-Hoare logic for he case of parial condiions and parial programs on hierarchically organized daa. As was shown in [10] hierarchically organized daa (more specifically, a class of such daa called nominaive daa [10]) is sufficien for represening many daa srucures (like mulidimensional arrays, liss, rees, ables, ec.) ha are frequenly used in programming. To develop such an exension we will adop he composiion-nominaive approach [11] o program formalizaion. This approach aims o propose a mahemaical basis for developmen of formal mehods of analysis and synhesis of sofware sysems and is grounded on several principles [11], including he Developmen principle (from absrac o concree), he Principle of inegriy of inensional and exensional aspecs, he Principle of prioriy of semanics over synax, Composiionaliy principle, and he Nominaiviy principle. The laer Nominaiviy principle saes ha nominaive daa [2] (a special class of hierarchically organized daa) are adequae mahemaical models of various forms of daa ha are processed and sored in compuing sysems. There exis several ypes of nominaive daa [11] (wih simple or complex names and wih simple or complex values), bu all of hem are based on naming relaions ha associae names and values. In he composiion-nominaive approach on he absrac level a compuing sysem is modeled as a parial funcion ha maps nominaive daa (inpu daa) o nominaive daa (oupu daa). Such funcions are called binominaive. Properies of daa are represened as parial predicaes on nominaive daa. Nominaive funcions and predicaes can be composed in many ways, e.g. by sequenial composiion, branching, and so on. Operaions ha consruc composed sysems from consiuens are called composiions. A se of composiions ogeher wih a se of funcions obained from a chosen se of basic funcions by applicaions of composiions forms an algebraic sysem (program algebra) which is a semanic model of a programming language. The synax of his language follows naurally from his semanic model: programs are represened as erms of he described algebra. The relaion of he above menioned noions o semanics of programming languages can be illusraed on a simple programming language WHILE [12]. This is an imperaive language in which programs are composed from saemens which conain boolean and arihmeic expressions. A program sae is an assignmen of values o variable names which can be modeled as a nominaive se. Semanics of a saemen can be represened as a parial binominaive funcion (a mapping from saes o saes) and semanics of a boolean or arihmeic expression can be represened as a funcion on nominaive daa which akes boolean or ineger values. Semanics of saemens are composed o obain semanics of a program. In accordance wih he composiion-nominaive approach he semanic componen of our Floyd-Hoare logic exension will be based on program algebra (a se of funcions and predicaes on nominaive daa which can be obained from

4 some chosen basic funcions and predicaes using a specific se of composiions). In his paper he carrier ses of our program algebra will consis of parial funcions and predicaes over nominaive daa wih complex names and complex values [10]. We will rea a Floyd-Hoare riple as a composiion wih wo predicaes on nominaive daa and a program (a parial binominaive funcion which belongs o he carrier se of he program algebra) as argumens. The predicaes represen pre- and poscondiions and he resul of he composiion is a predicae. However, he classical definiion of Floyd-Hoare riple validiy leads o Floyd-Hoare composiion ha is no monoone [8]. Monooniciy is one of he key properies used for reasoning abou programs. I is also imporan for reasoning abou loop-free programs and using hem as approximaions of programs wih loops. This explains he need of a special definiion of Floyd-Hoare composiion for he exension of Floyd-Hoare logic on parial predicaes which is monoone, bu converges o he classical definiion, if predicaes are oal. Such a definiion was presened in [8] and we will adap i o he case considered in his paper. To make our Floyd-Hoare logic exension pracically applicable for program verificaion one can implemen i in a proof assisan sofware [13]. Many well known proof assisans (e.g. Isabelle, Coq, PVS, ec.) provide a subsanial suppor for reasoning abou oal funcions, programs, predicae and are convenien for eiher formulaing he classical Floyd-Hoare logic axiomaically, or embedding i in heir logics. For example, Isabelle proof assisan includes he Hoare HOL (Higher-Order Logic)-based heory ha provides an implemenaion of Hoare logic for a simple imperaive programming language wih WHILE loops following [14, 15]. However, a suppor of reasoning abou programs using parial predicae pre- and poscondiions is generally no developed. We propose an approach o formalizaion of our exended Floyd-Hoare logic which suppors parial pre- and poscondiions in he proof assisan Mizar [16, 17]. This proof assisan is based on firs-order logic and axiomaic se heory (Tarski-Grohendieck se heory) and has one of he riches libraries of formalized mahemaical heories ha spans many branches of mahemaics. This library is called Mizar Mahemaical Library (MML). Consequenly, Mizar has well developed ools for working wih parial funcions and predicaes and is well-suied for our purposes. Besides, he Mizar sysem has a degree of proof auomaion suppor such as discovery of a lis of proven facs ha imply he curren goal which may be used as basis for implemening sofware verificaion in a semi-auomaic mode. To simplify and parially auomae applicaion of he Floyd-Hoare logic o proving program properies i is convenien o have a corresponding sysem of inference rules. The radiional inference sysem for he language WHILE [12] is sound and exensionally complee for he classical Floyd-Hoare logic wih oal predicaes [12] (exensional compleeness means ha pre- and poscondiions may be arbirary predicaes [12]; inensional compleeness means ha pre- and poscondiions should be presened by formulas of a given language). Soundness and compleeness are imporan for pracical applicabiliy of an inference sysem

5 (if a sysem is no sound, asserions ha can be inferred using his sysem may be false; if a sysem is no complee, some of he valid asserions could be impossible o infer). However, his inference sysem is no sound and complee for parial predicaes as was shown in [8]. To deal wih he soundness and complees problem we will modify he radiional inference sysem for he language WHILE and inroduce addiional consrains on inference rules ha correspond o he new definiion of validiy of Floyd-Hoare asserions, and invesigae is soundness and exensional compleeness. The obained resuls exend he resuls concerning inference sysems for a Floyd-Hoare logic wih parial predicaes over fla (nonhierarchical) daa obained in [8, 9]. The paper is organized in he following way. In Secion 2 we describe he noion of nominaive daa and define main operaions on hem. In Secion 3 we describe he semanic base of our exended Floyd-Hoare logic. In Secion 4 we specify he synax of our exended Floyd-Hoare logic. In Secion 5 we propose an inference sysem for our logic and consider problems of is soundness and compleeness. In Secion 6 we describe an approach o formalizaion of our exended Floyd-Hoare logic in Mizar. In Secion 7 we describe he relaed work. In Secion 8 we give conclusions. 2 Algebra of Nominaive Daa In he composiion-nominaive approach daa are reaed as nominaive daa. There are several ypes of nominaive daa, bu all of hem are based on naming relaions. The simples ype of nominaive daa is he class of nominaive ses which are parial mappings from a se of names (program variables) o a se of basic values. Oher ypes of nominaive daa represen hierarchical daa organizaions [10]. Before giving definiions, le us inroduce he following noaion. p To disinguish oal funcions from parial we will use he symbol for parial funcions and n for oal. We will also use he symbol for parial funcions wih finie graph. For any parial funcion f : D p D on some se D: f(d) denoes ha f is defined on d D; f(d) = d denoes ha f is defined on d D wih a value d D ; f(d) denoes ha f is undefined on d D; dom(f) = {d D f(d) } is he domain of a funcion (noe ha in differen branches of mahemaics here exis differen definiions of he domain of a parial funcions; we will adop he convenion used in recursion heory); We will denoe by f 1 (d 1 ) = f 2 (d 2 ) he srong equaliy, i.e. he condiion ha f 1 (d 1 ) if and only if f 2 (d 2 ), and if f 1 (d 1 ), hen f 1 (d 1 ) = f 2 (d 2 ). For any nonempy se V we will denoe by V + he se of all nonempy finie sequences (words) of elemens of V. For any word u V + we will denoe by u is lengh. If u, v V +, we will denoe by uv he concaenaion of u and v. We will wrie u v, if u is a prefix of v, and u < v, if u v, u v.

6 For any se of names V and a se of basic values A he corresponding class V A of nominaive ses is defined as V A = V p A. We will use he following noaions for nominaive ses: [v 1 a 1,..., v n a n ], where v 1,..., v n are names from V and a 1,... a n are aoms from A, denoes a nominaive se wih he graph {(v 1, a 1 ),..., (v n, a n )}; [v i a i i I], where I is some se of indices, means a nominaive se wih he graph {(v i, a i ) i I}; v a d, where d is a nominaive se, means ha d(v) = a, i.e. he value of he variable v in d is a; [] or denoes he empy nominaive se (a nowhere defined funcion). Nominaive daa are buil over classes of names V and basic values (aoms) A using naming relaions name value. A rough idea is ha a nominaive daa d is eiher an aom from A, or has he form [v 1 d 1,..., v n d n ], where v 1,..., v n are names from V and d 1,..., d n are eiher aoms or oher nominaive daa. Nominaive daa are classified in accordance wih he following 2 parameers [10]: values can be simple (unsrucured) or complex (srucured), and names can be simple (unsrucured) or complex (srucured). These parameers give 4 ypes of nominaive daa. To define he noion of a complex name we will use he Developmen principle (from absrac o concree) and consider he simples case of name consrucion: complex names are sequences of simple names which saisfy he associaiviy propery [10]. More specifically, we will assume ha complex names are consruced wih he help of concaenaion operaion (which is associaive). We will adop he following Principle of associaive consrucion and processing of complex names [10]: complex names are consruced from simple names using concaenaion, and daa wih complex names mus be processed by operaions ha ake ino accoun associaiviy of names. Moreover, we will require ha daa wih complex names saisfy he Principle of unambiguous associaive naming [10]: one complex name mus have a mos one corresponding value in any given daa. The definiions of 4 ypes of nominaive daa (T ND SS, T ND SC, T ND CS, T ND CC ) are given below. We will assume ha V and A are fixed nonempy ses of simple names and basic values. We will call he elemens of V + complex names. 1. Daa of he ype T ND SS (daa wih simple names and simple values) are elemens of he se V n A. For example, if u, v V, 1, 2 A. [u 1, v 2],

7 2. Daa of he ype T ND SC (daa wih simple names and complex values) are elemens of he se ND(V, A), where ND(V, A) = k 0 ND k (V, A), ( ND 0 (V, A) = A { }, ND k+1 (V, A) = ND k (V, A) V ) n ND k (V, A) for all k = 0, 1, 2,... Daa of his class are hierarchically consruced, for example, [u 1, v [w 2]], if u, v, w V and 1, 2 A. Such daa can be represened by oriened rees wih arcs labeled by names and leafs labelled by aoms. We will call any finie sequence of names p = (v 1, v 2,..., v k ) a pah. A pah in a given daa d ND(V, A) is a pah (v 1, v 2,..., v k ) such ha he value of he expression (...((d(v 1 ))(v 2 ))...(v k )) is defined (i corresponds o a pah from he roo o a leaf in a ree). If p = (v 1, v 2,..., v k ) is a pah in d, we will say ha (...((d(v 1 ))(v 2 ))...(v k )) is he value of p in d and denoe i as d(v 1, v 2,..., v k ). A erminal pah is a pah wih aomic or empy value. The rank of d is he leas k such ha d ND k (V, A). 3. Daa of he ype T ND CS (daa wih complex names and simple values) are elemens of he se NDV S(V, A), where NDV S(V, A) is he se of all elemens of A (V + n A) such ha eiher d A, or d V + n A and all srings from dom(d) are pairwise incomparable in he sense of he prefix relaion. For example, [uv 1, uw 2, w 3], if u, v, w V are differen and 1, 2, 3 A. 4. Daa of he ype T ND CC (daa wih complex names and complex values) are elemens of he se NDV C(V, A), where NDV C(V, A) is he se of all d ND(V +, A) such ha for any wo pahs (u 1, u 2,..., u k ) and (v 1, v 2,..., v l ) in d, neiher of which is a prefix of anoher, words u 1 u 2...u k and v 1 v 2...v l are incomparable in he sense of prefix relaion (principle of unambiguous associaive naming). For example, if u, v, w V are differen, 1, 2 A. [uv 1, w [uw 2]], In [8] i was shown how convenional daa srucures can be represened by differen kinds of nominaive daa. The mos complex and ineresing ype of nominaive daa is T ND CC, so we will use i in his paper.

8 The main operaions on nominaive daa are operaions of denaming (aking a value of a name), naming (assigning o a name a new value), and overlapping (overwriing). Below we give definiions of hese operaions for nominaive daa of he ype T ND CC. For any word u V + and any daa d NDV C(V, A) le us denoe (division of d by u). d/u = [v 1 d(v) d(v), v = uv 1, v 1 V + ] p Definiion 1. Associaive denaming v a : NDV C(V, A) NDV C(V, A) is an operaion wih a parameer v V + defined by inducion on lengh of v as follows: if v = 1, hen v a (d) = d(v), if d(v) ; v a (d) = d/v if d(v) and d/v, and v a (d) oherwise. if v = n > 1, hen v a (d) = v 1 a (x a (d)), where v = xv 1, x V, v 1 V n 1 (principle of associaive denaming). For example, (uv) a ([u [vw 1, u 2]]) = [w 1]. I is easy o check ha v a saisfies he following propery (associaiviy) u a (d) = u n a (u n 1 a (... u 1 a (d)...)) for all complex names u, u 1, u 2,..., u n V + such ha u = u 1 u 2...u n. Definiion 2. Naming is an operaion v : NDV C(V, A) NDV C(V, A) wih a parameer v V + such ha v(d) = [v d]. Overlapping can be considered as an operaion which updaes values in he firs argumen wih he values from he second argumen. I joins wo daa and resolves name conflics in favor of is second argumen. We will define wo kinds of overlapping: global and local. Global overlapping can be used for formalizaion of procedures calls and he local overlapping formalizes he assignmen operaor in programming languages. Definiion 3. Global overlapping is a binary operaion a : NDV C(V, A) NDV C(V, A) p NDV C(V, A) defined inducively by he rank of he firs argumen as follows. Le NDV C k (V, A) = NDV C(V, A) ND k (V, A) (daa of he rank no greaer han k).

9 Inducion base. If d 0 NDV C 0 (V, A), hen { d 1 a d 2 d 2, d 1 = and d 2 NDV C(V, A)\A; = undefined, d 1 A or d 2 A. Inducion sep. Assume ha he value d 1 a d 2 is defined for all d 1, d 2 such ha d 1 NDV C k (V, A). Le d 1 NDV C k+1 (V, A) and d 1 / NDV C k (V, A). Then d 1 a d 2 = d, where d NDV C(V, A) is defined by is values on names u V + : d(u) = d 2 (u), if u dom(d 2 ) and u does no have a proper prefix which belongs o dom(d 1 ). d(u) = d 1 (u) a (d 2 /u), if d 1 (u) and d 1 (u) / A, and u is a proper prefix of some elemen of dom(d 2 ); d(u) = d 2 /u, if d 1 (u) and d 1 (u) A, and u is a proper prefix of some elemen of dom(d 2 ); d(u) = d 1 (u), if d 1 (u) and u is no comparable (in he sense of prefix relaion) wih any elemen of dom(d 2 ); d(u), oherwise. The following examples illusrae his operaion: 1. [u d 1 ] a [v d 2 ] = [u d 1, v d 2 ], if u, v are incomparable in he sense of prefix relaion; 2. [uv d 1 ] a [u d 2 ] = [u d 2 ], i.e. a value under a name in he second argumen overwries a value under exension of his name in he firs argumen; 3. [u d 1 ] a [uv d 2 ] = [u (d 1 s [v d 2 ])] (d 1 / A), i.e., a value under a name in he second argumen modifies values under prefixes of his name in he firs argumen. Definiion 4. Local overlapping is an operaion v p a : NDV C(V, A) NDV C(V, A) NDV C(V, A) wih a parameer v V + such ha For example, d 1 v ad 2 = d1 a ( v(d 2 )). [u 1] v a[w 2] = [u 1, v [w 2]]. Definiion 5. An algebra of nominaive daa of ype T ND CC (denoed as NDA(V, A)) is an algebra wih he carrier NDV C(V, A) and he operaions { v} v V +, {v a } v V +, { v a} v V +.

10 3 Semanics of Exended Floyd-Hoare Logic Le Bool = {F, T } denoe he se of Boolean values, P r V,A p = NDV C(V, A) Bool. The elemens of P r V,A are called parial nominaive predicaes. They can be used o represen semanics of condiions in programs. Le F P rg V,A p = NDV C(V, A) NDV C(V, A). The elemens of F P rg V,A are called binominaive funcions. They can be used o represen semanics of programs. Muli-sored algebras on ses of parial nominaive predicaes and parial binominaive funcions can be used o define semanics of program logics [11, 18]. The operaions of such algebras will be called composiions. There are many possible ways o define composiions ha provide means o consruc complex programs from simpler ones. We have chosen he following composiions o include hem as basic o he logics of program level: parameric assignmen composiion AS x which corresponds o assignmen operaor := ; composiion of idenical program id which corresponds o he skip operaor of he WHILE language; composiion of sequenial execuion ; condiional composiion IF which corresponds o he if-hen-else operaor; cycle (loop) composiion WH which corresponds o he while-do operaor. We also need composiions ha provide he possibiliy o consruc predicaes describing properies of programs. The main composiion of his kind is he Floyd-Hoare composiion FH. I akes a precondiion, a poscondiion, and a program as inpus and yields a predicae ha represens respecive Floyd-Hoare asserion. We will also define a composiion of preimage predicae ransformer inspired by weakes precondiion inroduced by Dijksra [19]. Le us give definiions of he menioned composiions. Definiion 6. Disjuncion is a binary composiion : P r V,A P r V,A P r V,A such ha for all p, q P r V,A and d NDV C(V, A): T, if p(d) = T or q(d) = T, (p q)(d) = F, if p(d) = F and q(d) = F, undefined in oher cases. Definiion 7. Negaion is a unary composiion : P r V,A P r V,A such ha for all p P r V,A and d NDV C(V, A): F, if p(d) = T, ( p)(d) = T, if p(d) = F, undefined in oher cases.

11 We will consider conjuncion p q of predicaes p, q as an abbreviaion for ( p q). Definiion 8. Exisenial quanificaion over hierarchical daa is a unary composiion x : P r V,A P r V,A wih a parameer x V + such ha for all p P r V,A and d NDV C(V, A): T, if p(d x ad ) = T for some d NDV C(V, A), ( x p)(d) = F, if p(d x ad ) = F for all d NDV C(V, A), undefined in oher cases. For each n = 1, 2, 3,... denoe by Ūn(V ) he se of all uples (x 1,..., x n ) (V + ) n of n complex names such ha x 1, x 2,..., x n are pairwise incomparable in he sense of prefix relaion. Also, le us denoe Ū(V ) = n=1 Ūn(V ). Definiion 9. For each n = 1, 2, 3,..., superposiion of n funcions ino a funcion is a n+1-ary composiion S ˉx F : (F P rg V,A ) n+1 F P rg V,A wih a parameer ˉx = (x 1,..., x n ) Ūn(V ) such ha for all f, g 1,..., g n F P rg V,A and d NDV C(V, A): S ˉx F (f, g 1,..., g n )(d) = f(d a [x 1 g 1 (d),..., x n g n (d)]). Definiion 10. For each n = 1, 2, 3,..., superposiion of n funcions ino a predicae is a n+1-ary composiion S ˉx P : P r V,A (F P rg V,A ) n P r V,A wih a parameer ˉx = (x 1,..., x n ) Ūn(V ) such ha for all p P r V,A, g 1,..., g n F P rg V,A, and d NDV C(V, A): S ˉx P (p, g 1,..., g n )(d) = p(d a [x 1 g 1 (d),..., x n g n (d)]). Definiion 11. Denominaion is a null-ary composiion x : F P rg V,A wih a parameer x V + such ha for each d NDV C(V, A): x(d) = x a (d). Definiion 12. Assignmen over hierarchical daa is a composiion AS x : F P rg V,A F P rg V,A wih a parameer x V + such ha for each f F P rg V,A and d NDV C(V, A): AS x (f)(d) = d x af(d).

12 Definiion 13. Ideniy program composiion is a null-ary composiion id : F P rg V,A such ha for each d NDV C(V, A): id(d) = d. Definiion 14. Sequenial execuion is a binary composiion : F P rg V,A F P rg V,A F P rg V,A such ha for all f, g F P rg V,A and d NDV C(V, A): (f g)(d) = g(f(d)). Definiion 15. Branching is a ernary composiion IF : P r V,A F P rg V,A F P rg V,A F P rg V,A such ha for all r P r V,A (condiion), f, g F P rg V,A (branches bodies), and d NDV C(V, A): f(d), if r(d) = T and f(d), IF (r, f, g)(d) = g(d), if r(d) = F and g(d), undefined in oher cases. Definiion 16. While cycle is a binary composiion W H : P r V,A F P rg V,A F P rg V,A such ha for each r P r V,A (condiion), f F P rg V,A (loop body), and d NDV C(V, A): W H(p, f)(d) = f (n) (d), if here exiss an ineger n 0 such ha p(f (i) (d)) = T for all i = 0, 1,..., n 1 and p(f (n) (d)) = F, where f (i) denoes f f... f and f }{{} (0) = id; i and W H(p, f)(d), oherwise. Definiion 17. Monoone Floyd-Hoare composiion F H : P r V,A F P rg V,A P r V,A P r V,A is a composiion such ha for all p, q P r V,A (pre- and poscondiion), f F P rg V,A (program), and d NDV C(V, A): T, if p(d) = F or q(f(d)) = T, F H(p, f, q)(d) = F, if p(d) = T and q(f(d)) = F, undefined in oher cases.

13 Definiion 18. Predicae ransformer composiion is a binary composiion P C : F P rg V,A P r V,A P r V,A such ha for all q P r V,A, f F P rg V,A, and d NDV C(V, A): T, if f(d) and q(f(d)) = T, P C(f, q)(d) = F, if f(d) and q(f(d)) = F, undefined in oher cases. Predicae ransformer composiion is he same as Glushkov predicion operaion (sequenial execuion of a funcion and a predicae) [10]. We call his composiion (defined for parial predicaes) as preimage predicae ransformer composiion in order o relae i o he weakes precondiion predicae ransformer [19]. Noe ha F H(p, pr, q) = p P C(pr, q). The Floyd-Hoare composiion is called monoone, because i saisfies he following propery, as was shown in [8]: p p, q q, f f F H(p, f, q) F H(p, f, q ), where inclusion is undersood as inclusion of he graphs of funcions and predicaes. Definiion 19. An (associaive) nominaive program algebra N P A(V, A) is a wo-sored algebra < P r V,A, F P rg V,A ;,, { x} x V +, {S ˉx P }ˉx Ū(V ), {S ˉx F }ˉx Ū(V ), { x} x V +, id, {AS x } x V +,, IF, W H, F H, P C >. This algebra is he semanic base of our exension of Floyd-Hoare logic o parial predicaes and (hierarchical) nominaive daa wih complex names and complex values. 4 Synax and Inerpreaion Terms of he algebra NP A(V, A) defined over some ses of predicae symbols P s and program symbols P rs specify he synax (language) of he logic. Le us give definiions of he ses of program exs P V,P s,p rs, formulas F r V,P s,p rs, and Floyd-Hoare asserions F HF r V,P s,p rs. The ses P V,P s,p rs and F r V,P s,p rs are defined inducively (here we use he symbols of composiions in he purely synacic sense, i.e. hey are currenly no associaed wih semanics): 1. if pr P rs, hen pr P V,P s,p rs ; 2. if n 1, pr, pr 1,..., pr n P rs, and ˉx Ūn(V ), hen S ˉx F (pr, pr 1,..., pr n ) P V,P s,p rs ; 3. if x V + and pr P rs, hen AS x (pr) P V,P s,p rs ;

14 4. x P V,P s,p rs for each x V + and id P V,P s,p rs ; 5. if pr 1, pr 2 P V,P s,p rs, hen pr 1 pr 2 P V,P s,p rs ; 6. if Φ F r V,P s,p rs and pr 1, pr 2 P V,P s,p rs, hen IF (Φ, pr 1, pr 2 ) P V,P s,p rs ; 7. if Φ F r V,P s,p rs and pr P V,P s,p rs, hen W H(Φ, pr) P V,P s,p rs ; 8. if P P s, hen P F r V,P s,p rs ; 9. if Φ, Ψ F r V,P s,p rs, hen Φ Ψ, Φ Ψ F r V,P s,p rs ; 10. if Φ F r V,P s,p rs, hen Φ F r V,P s,p rs ; 11. if n 1, Φ F r V,P s,p rs, pr 1,..., pr n P rs, and ˉx Ūn(V ), hen S ˉx P (Φ, pr 1,..., pr n ) F r V,P s,p rs ; 12. if Φ F r V,P s,p rs and v V +, hen vφ F r V,P s,p rs. The se F HF r V,P s,p rs is he se of all formulas of he form {p}f{q}, where p, q F r V,P s,p rs and f P V,P s,p rs. Definiion 20. Le V be a se of basic names, P s be a se of predicae symbols, P rs be a se of program symbols, and A be an arbirary se. Then an inerpreaion J is a riple (NDA(V, A), I P s, I P rs ), where I P s : P s P r V,A is an inerpreaion mapping for predicae symbols and I P rs : P rs F P rg V,A is an inerpreaion mapping for program symbols. For any inerpreaion J = (NDA(V, A), I P s, I P rs ) we will denoe by J F r and J P he formula and program ex inerpreaion mappings V,P s,p rs J F r : F r P r V,A, V,P s,p rs J P : P F P rg V,A which are he sandard exensions of I P s and I P rs o F r V,P s,p rs V,P s,p rs and P respecively (defined by srucural inducion). Also, we will denoe by J F HF r he V,P s,p rs inerpreaion mapping of Floyd-Hoare asserions J F HF r : F HF r P r V,A defined as follows: J F HF r ({p}f{q}) = F H(J F r (p), J P (f), J F r (q)). In his paper we will no define inerpreaions explicily expecing ha hey are clear from he conex. For any P F r V,P s,p rs or P F HF r V,P s,p rs we will denoe by P J or (P ) J he predicae ha corresponds o P under inerpreaion J. We will omi he index J when i is clear from he conex. We will use he following noaion for any predicae p: p T = {d p(d) = T } is he ruh domain of a predicae p; p F = {d p(d) = F } is he falsiy domain p. Definiion 21. A formula P F r V,P s,p rs or a Floyd-Hoare asserion P F HF r V,P s,p rs is valid (irrefuable) in an inerpreaion J (denoed as J = P ), if P F J =. Definiion 22. A formula P F r V,P s,p rs or a Floyd-Hoare asserion P F HF r V,P s,p rs is valid (denoed as = P ), if i is valid in every inerpreaion.

15 Le us define he logical consequence relaion = F r V,P s,p rs F r V,P s,p rs : p = q = p q, where p q means p q for any p, q F r V,P s,p rs. We will also need he following special logical consequence relaions such ha p = T q p T J qt J p = F q q F J pf J = T, = F F r V,P s,p rs V,P s,p rs F r for every inerpreaion J; for every inerpreaion J. 5 Inference Sysem for a Floyd-Hoare Logic wih Parial Predicaes over Nominaive daa To make he program logic which we have defined applicable o sofware verificaion problems i is necessary o presen an inference sysem. Such an inference sysem could be based on he inference sysem for he classical Floyd-Hoare logic wih oal predicaes for he language WHILE [12], bu i is known be unsound in he case of parial predicaes [9] which is considered in he paper. For his reason addiional consrains need o be added o achieve a sound inference sysem. We will wrie X p o denoe ha a formula p is derived in some inference sysem X. An inference sysem X is sound, if X p = p for each formula p, and is complee, if = p X p for each p. Compleeness can be reaed in exensional or inensional approaches. For exensional compleeness [9] pre- and poscondiions can be arbirary predicaes. Inensional compleeness requires ha pre- and poscondiions are presened by formulas in a given language. The classical inference sysem for he language WHILE [12] can be presened in semanic form as follows (x V ): R AS {S x P (p, h)} AS x (h) {p} R SEQ R WH {p} f {q}, {q} g {r} {p} f g {r} {r p} f {p} {p} W H(r, f) { r p} R SKIP {p} id {p} R IF {r p} f {q}, { r p} g {q} {p} IF (r, f, g) {q} R CONS {p } f {q } {p} f {q} p p, q q This inference sysem is sound and exensionally complee for oal predicaes, bu for parial predicaes i is no sound [9], because rules R SEQ, R WH, and R CONS do no guaranee a valid derivaion from valid premises. As one of soluions we propose he following inference sysem AC wih added consrains (x V +, n 1, ˉx Ūn): R AS {S x P (p, h)} AS x (h) {p} R SFID {S ˉx P (p, g 1,..., g n )}S ˉx F (id, g 1,..., g n ){p}

16 R SF {p}s ˉx F (id, g 1,..., g n ) f{q} {p}s ˉx F (f, g 1,..., g n ){q} R SKIP {p} id {p} R SEQ R IF R WH {p} f {q}, {q} g {r} {p} f g {r} {r p} f {q}, { r p} g {q} {p} IF (r, f, g) {q} {r p} f {p} {p} W H(r, f) { r p} R CONS {p } f {q } {p} f {q}, p = P C(f g, r), p = T p, q = F q, p = P C(W H(r, f), r p) In his sysem consrains are presened via consequence relaions =, = T, = F. These relaions can be subsiued by he corresponding inference relaions (, T, F ), bu his quesion is ouside he scope of he paper and we will no go ino deail here. Theorem 1. AC {P C(pr, q)}pr{q} for each pr and q. Proof (presened for some arbirary inerpreaion J, bu for simpliciy sake we omi his J from he ex of his proof). Le us use inducion over he srucure of pr. Base of inducion. Le us prove ha AC {P C(AS x (h), q)}as x (h){q}. By he rule R AS, i is sufficien o show ha P C(AS x (h), q) = SP x (q, h). Using he definiion of P C and assignmen i is easy o check ha P C(AS x (h), q)(d) = q(d x ah(d)). Moreover, we have: SP x (q, h) = q(d a[x h(d)]) = q(d x ah(d)) = P C(AS x (h), q). Thus AC {P C(AS x (h), q)}as x (h){q}. For AC {P C(id, q)}id{q} he proof is obvious. Inducive sep. 1. The case when pr is S ˉx F (f, g 1,..., g n ) is sraighforward. 2. Consider he case of sequenial execuion. Given he premises AC {P C(pr 1, P C(pr 2, q))}pr 1 {P C(pr 2, q)}, AC {P C(pr 2, q)}pr 2 {q}, he required derivaion AC {P C(pr 1 pr 2, q)}pr 1 pr 2 {q} can be proved in he same way as in he proof of he sequenial execuion case in [9, Theorem 4.2], so we omi a deailed proof here. 3. Consider he branching composiion. Assume ha AC {P C(pr 1, q)}pr 1 {q}, AC {P C(pr 2, q)}pr 2 {q}.

17 Le us prove ha AC {P C(IF (r, pr 1, pr 2 ), q)}if (r, pr 1, pr 2 ){q}. Le us prove r P C(IF (r, pr 1, pr 2 ), q) = T P C(pr 2, q). If d ( r P C(IF (r, pr 1, pr 2 ), q)) T, hen we have r(d) = F, IF (r, pr 1, pr 2 )(d), and q(if (r, pr 1, pr 2 )(d)) = T. Then IF (r, pr 1, pr 2 )(d) = pr 2 (d). Thus pr 2 (d) holds and q(pr 2 (d)) = T, so P C(pr 2, q)(d) = T, so d P C(pr 2, q) T. Thus r P C(IF (r, pr 1, pr 2 ), q) = T P C(pr 2, q). Similarly, r P C(IF (r, pr 1, pr 2 ), q) = T P C(pr 1, q). Then by R CONS Then using R IF we conclude ha AC {r P C(IF (r, pr 1, pr 2 ), q)}pr 1 {q}, AC { r P C(IF (r, pr 1, pr 2 ), q)}pr 2 {q}. AC {P C(IF (r, pr 1, pr 2 ), q)}if (r, pr 1, pr 2 ){q}. 4. Le us prove AC {P C(W H(r, pr), q)}w H(r, pr){q} for each pr, q, r. Le p = P C(W H(r, pr), q). Le p be a predicae such ha: p (d) = T, if p(d) = T and p (d) = F oherwise. We have AC {P C(pr, p )}pr{p }. Le us show ha r p = T P C(pr, p ). Noe ha p T = p T, whence p = T p. Assume ha (r p )(d) = T. Then p (d) = p(d) = T, whence q(w H(r, pr)(d)) = T. Moreover, r(d) = T, so here exiss d = pr(d) such ha W H(r, pr)(d ) = W H(r, pr)(d) and q(w H(r, pr)(d )) = T. Then p (d ) = p(d ) = P C(W H(r, pr), q)(d ) = T. From p (d ) = T and d = pr(d) we have P C(pr, p )(d) = T. We conclude ha r p = T P C(pr, p ). Le us prove ha r p = F q. Assume ha q(d) = F. If r(d) = T hen ( r p )(d) = F. If r(d) = F, hen p(d) = P C(W H(r, pr), q)(d) = F, so p (d) = p(d) = F and ( r p )(d) = F. If r(d), hen p(d) = P C(W H(r, pr), q)(d), whence p (d) = F and ( r p )(d) = F. In all cases, ( r p )(d) = F. Thus r p = F q. Le us show ha p = T P C(W H(r, pr), r p ). Assume ha p (d) = T. Then p(d) = T. Then here exiss d such ha W H(r, pr)(d) = d and q(d ) = T, because p = P C(W H(r, pr), q). By he definiion of W H, r(d ) = F and W H(r, pr)(d ) = d. Because W H(r, pr)(d ) = d and q(d ) = T, we have p(d ) = T = P C(W H(r, pr), q)(d ). Then p (d ) = T and ( r p )(d ) = T. Then W H(r, pr)(d) = d and P C(W H(r, pr), r p )(d) = T. We conclude ha p = T P C(W H(r, pr), r p ). Then p = P C(W H(r, pr), r p ). Moreover, from r p = T P C(pr, p ) and R CONS, AC {r p }pr{p }, so AC {p }W H(r, pr){ r p } by he rule R WH. Because r p = F q and p = T p, we have AC {p}w H(r, pr){q} by R CONS. Thus AC {P C(W H(r, pr), q)}w H(r, pr){q}.

18 We have considered all composiions, so, aking ino accoun ha an inerpreaion J was chosen arbirary, we have ha AC {P C(pr, q)}pr{q} for each pr and q. Theorem 2. The inference sysem AC is sound. This heorem can be proved analogously o [8, Theorem 4]. The compleeness problems (exensional and inensional) are more difficul. In his case i is reasonable o idenify differen classes of predicaes (similarly o [8, 9]) and o prove compleeness for such classes of predicaes. In his case Theorem 1 is used. 6 Towards Formalizaion of Exended Floyd-Hoare Logic in Mizar We proposed a formalizaion of nominaive daa in Mizar in [20]. In he menioned work differen ypes of nominaive daa were defined as Mizar modes wih se parameers V and A which mean he ses of basic names and aomic values respecively. We can use his formalizaion as a basis for formalizaion of he exended Floyd-Hoare logic for programs over nominaive daa of he ypes T ND CC and T ND SC. 1) Define he mode of binominaive funcions over nominaive daa of he ype T ND SC (please refer o [20] for he definiion of TypeSCNominaiveDaa menioned below): reserve V for se; reserve A for se; reserve D for TypeSCNominaiveDaa of V, A; definiion le V, A, D; mode TypeSCBinominaiveFuncion of D is ParFunc of D, D; end; and, similarly, he mode of binominaive funcions over nominaive daa of he ype T ND CC. This gives us a formalizaion of F P rg V,A defined in Secion 3. 2) Analogously define he modes of parial predicaes over nominaive daa of he ypes T ND SC, T ND CC over V, A (P r V,A ). 3) Formalize P V,P s,p rs (program exs), F r V,P s,p rs V,P s,p rs (formulas), F HF r (and Floyd-Hoare asserions) as Mizar modes wih parameers V, P s, P rs. 4) Formalize he inerpreaion mapping in accordance wih Definiion 20. 5) Formalize he relaion of validiy in an inerpreaion in accordance wih Definiion 21 and he relaion of validiy in accordance wih Definiion 22. 6) Formalize he logical consequence relaion p = q = p q for p, q F r V,P s,p rs and he special logical consequence relaions p = T q p T J qt J for any inerpreaion J, and p = F q qj F pf J for any inerpreaion J. 7) Formulae he inference rules of he AC inference sysem described in Secion 5 as Mizar schemes and prove heir semanic validiy. Finally, he proven inference rules can be used o prove semanics properies of programs defined by concree program exs (elemens of P V,P s,p rs ).

19 7 Relaed Work Logical approaches o program specificaion and reasoning abou program properies were used in he works by R. Floyd [1] and T. Hoare [2]. These approaches were based on axiomaic sysems wih oal predicaes and used riples of a precondiion, program, and a poscondiion. Laer i became eviden ha parialiy of predicaes and programs needs o be aken ino accoun which gave rise o hree-valued logics which represened undefinedness of a predicae by a special hird value. In paricular, such logics were sudied by Lukasiewicz, Kleene, Bochvar and ohers. A he same ime many oher exensions of he Floyd-Hoare logic were proposed as a basis for program verificaion, including Dynamic logic and Separaion logic. In Dynamic logic [21] special modaliies ha allow usage of program exs and specificaions alongside are used. A Floyd-Hoare asserion {p}pr{q} can be replaced wih a formula p [pr]q, where [pr]q indicaes ha if a program pr erminaes, hen necessarily holds q. For deerminisic programs, [pr]q is equal o our preimage composiion which also allows use of specificaions and program exs ogeher. Separaion logic [22] was inroduced o deal wih widespread usage of heap and poiners in programming. This logic has special means for specifying heap properies. Bu only a heap funcion ha maps memory addresses o values is assumed o be parial. In oher aspecs only oal predicaes are considered. The ways of dealing wih parialiy in curren sofware specificaion languages (VDM, RSL, Z, ec.) are described in [4]. Mos approaches use eiher a manyvalued logic or underspecificaion for dealing wih parialiy. 8 Conclusions We have proposed an exension of he Floyd-Hoare logic for he case of parial condiions and programs on hierarchically organized daa called nominaive daa. Such daa can be used o convenienly represen many daa srucures used in programming. We have proposed an inference sysem for our exended Floyd- Hoare logic and invesigaed is soundness and exensional compleeness and propose an approach o is formalizaion in he Mizar sysem. In he fuure works we plan o implemen he proposed approach and apply he resuls o sofware verificaion asks. References 1. Floyd, R.: Assigning meanings o programs. Mahemaical aspecs of compuer science 19 (1967) 2. Hoare, C.: An axiomaic basis for compuer programming. Commun. ACM 12 (1969) Ap, K.: Ten years of Hoare s logic: A survey par I. ACM Trans. Program. Lang. Sys. 3 (1981) Hähnle, R.: Many-valued logic, parialiy, and absracion in formal specificaion languages. Logic Journal of he IGPL 13 (2005)

20 5. Jones, C.: Reasoning abou parial funcions in he formal developmen of programs. In: Proceedings of AVoCS 05. Volume 145., Elsevier, Elecronic Noes in Theoreical Compuer Science (2006) Gries, D., Schneider, F.: Avoiding he undefined by underspecificaion. Technical repor, Ihaca, NY, USA (1995) 7. Duzi, M.: Do we have o deal wih parialiy? Miscellanea Logica 5 (2003) Kryvolap, A., Nikichenko, M., Schreiner, W.: Exending Floyd-Hoare logic for parial pre- and poscondiions. In Ermolayev, V., Mayr, H., Nikichenko, M., Spivakovsky, A., Zholkevych, G., eds.: Informaion and Communicaion Technologies in Educaion, Research, and Indusrial Applicaions. Volume 412 of Communicaions in Compuer and Informaion Science. Springer Inernaional Publishing (2013) Nikichenko, M., Kryvolap, A.: Properies of inference sysems for Floyd-Hoare logic wih parial predicaes. Aca Elecroechnica e Informaica 13 (2013) Skobelev, V., Nikichenko, M., Ivanov, I.: On algebraic properies of nominaive daa and funcions. In Ermolayev, V., Mayr, H., Nikichenko, M., Spivakovsky, A., Zholkevych, G., eds.: Informaion and Communicaion Technologies in Educaion, Research, and Indusrial Applicaions. Volume 469 of Communicaions in Compuer and Informaion Science. Springer Inernaional Publishing (2014) Nikichenko, M., Shkilniak, S.: Mahemaical logic and heory of algorihms. Publishing house of Taras Shevchenko Naional Universiy of Kyiv, Ukraine (in Ukrainian) (2008) 12. Nielson, H., Nielson, F.: Semanics wih applicaions a formal inroducion. Wiley professional compuing. Wiley (1992) 13. Wiedijk, F.: The seveneen provers of he world. Foreword by Dana S. Sco. Volume 3600 of Lecure Noes in Arificial Inelligence. Springer-Verlag Berlin Heidelberg (2006) 14. Gordon, M.: Mechanizing programming logics in higher order logic. In Birwisle, G., Subrahmanyam, P., eds.: In Curren Trends in Hardware Verificaion and Auomaed Theorem Proving. Springer-Verlag (1989) 15. Von Wrigh, J., Hekanaho, J., Luosarinen, P., Langbacka, T.: Mechanizing some advanced refinemen conceps. Formal Mehods in Sysem Design (1993) Bancerek, G., Byliński, C., Grabowski, A., Korni lowicz, A., Mauszewski, R., Naumowicz, A., P ak, K., Urban, J.: Mizar: Sae-of-he-ar and beyond. Volume 9150 of Lecure Noes in Compuer Science. Springer (2015) Grabowski, A., Korni lowicz, A., Naumowicz, A.: Four decades of Mizar. Journal of Auomaed Reasoning 55 (2015) Nikichenko, M., Tymofieiev, V.: Saisfiabiliy in composiion-nominaive logics. Cenral Europ. J. Compuer Science 2 (2012) Dijksra, E.: A Discipline of Programming. 1s edn. Prenice Hall PTR, Upper Saddle River, NJ, USA (1997) 20. Ivanov, I., Korni lowicz, A., Nikichenko, M.: Formalizaion of nominaive daa in Mizar. Proceedings of TAAPSD 2015, December 2015, Taras Shevchenko Naional Universiy of Kyiv, Ukraine (2015) Harel, D., Tiuryn, J., Kozen, D.: Dynamic Logic. MIT Press, Cambridge, MA, USA (2000) 22. Sannella, D., Tarlecki, A.: Foundaions of Algebraic Specificaion and Formal Sofware Developmen. Monographs in Theoreical Compuer Science. An EATCS Series. Springer (2012)

Logic in computer science

Logic in computer science Logic in compuer science Logic plays an imporan role in compuer science Logic is ofen called he calculus of compuer science Logic plays a similar role in compuer science o ha played by calculus in he physical

More information

Almost Sure Degrees of Truth and Finite Model Theory of Łukasiewicz Fuzzy Logic

Almost Sure Degrees of Truth and Finite Model Theory of Łukasiewicz Fuzzy Logic Almos Sure Degrees of Truh and Finie odel Theory of Łukasiewicz Fuzzy Logic Rober Kosik Insiue of Informaion Business, Vienna Universiy of Economics and Business Adminisraion, Wirschafsuniversiä Wien,

More information

A NOTE ON THE STRUCTURE OF BILATTICES. A. Avron. School of Mathematical Sciences. Sackler Faculty of Exact Sciences. Tel Aviv University

A NOTE ON THE STRUCTURE OF BILATTICES. A. Avron. School of Mathematical Sciences. Sackler Faculty of Exact Sciences. Tel Aviv University A NOTE ON THE STRUCTURE OF BILATTICES A. Avron School of Mahemaical Sciences Sacler Faculy of Exac Sciences Tel Aviv Universiy Tel Aviv 69978, Israel The noion of a bilaice was rs inroduced by Ginsburg

More information

Longest Common Prefixes

Longest Common Prefixes Longes Common Prefixes The sandard ordering for srings is he lexicographical order. I is induced by an order over he alphabe. We will use he same symbols (,

More information

An Excursion into Set Theory using a Constructivist Approach

An Excursion into Set Theory using a Constructivist Approach An Excursion ino Se Theory using a Consrucivis Approach Miderm Repor Nihil Pail under supervision of Ksenija Simic Fall 2005 Absrac Consrucive logic is an alernaive o he heory of classical logic ha draws

More information

T L. t=1. Proof of Lemma 1. Using the marginal cost accounting in Equation(4) and standard arguments. t )+Π RB. t )+K 1(Q RB

T L. t=1. Proof of Lemma 1. Using the marginal cost accounting in Equation(4) and standard arguments. t )+Π RB. t )+K 1(Q RB Elecronic Companion EC.1. Proofs of Technical Lemmas and Theorems LEMMA 1. Le C(RB) be he oal cos incurred by he RB policy. Then we have, T L E[C(RB)] 3 E[Z RB ]. (EC.1) Proof of Lemma 1. Using he marginal

More information

Matrix Versions of Some Refinements of the Arithmetic-Geometric Mean Inequality

Matrix Versions of Some Refinements of the Arithmetic-Geometric Mean Inequality Marix Versions of Some Refinemens of he Arihmeic-Geomeric Mean Inequaliy Bao Qi Feng and Andrew Tonge Absrac. We esablish marix versions of refinemens due o Alzer ], Carwrigh and Field 4], and Mercer 5]

More information

Some Ramsey results for the n-cube

Some Ramsey results for the n-cube Some Ramsey resuls for he n-cube Ron Graham Universiy of California, San Diego Jozsef Solymosi Universiy of Briish Columbia, Vancouver, Canada Absrac In his noe we esablish a Ramsey-ype resul for cerain

More information

Application of a Stochastic-Fuzzy Approach to Modeling Optimal Discrete Time Dynamical Systems by Using Large Scale Data Processing

Application of a Stochastic-Fuzzy Approach to Modeling Optimal Discrete Time Dynamical Systems by Using Large Scale Data Processing Applicaion of a Sochasic-Fuzzy Approach o Modeling Opimal Discree Time Dynamical Sysems by Using Large Scale Daa Processing AA WALASZE-BABISZEWSA Deparmen of Compuer Engineering Opole Universiy of Technology

More information

Single-Pass-Based Heuristic Algorithms for Group Flexible Flow-shop Scheduling Problems

Single-Pass-Based Heuristic Algorithms for Group Flexible Flow-shop Scheduling Problems Single-Pass-Based Heurisic Algorihms for Group Flexible Flow-shop Scheduling Problems PEI-YING HUANG, TZUNG-PEI HONG 2 and CHENG-YAN KAO, 3 Deparmen of Compuer Science and Informaion Engineering Naional

More information

Removing Useless Productions of a Context Free Grammar through Petri Net

Removing Useless Productions of a Context Free Grammar through Petri Net Journal of Compuer Science 3 (7): 494-498, 2007 ISSN 1549-3636 2007 Science Publicaions Removing Useless Producions of a Conex Free Grammar hrough Peri Ne Mansoor Al-A'ali and Ali A Khan Deparmen of Compuer

More information

Notes for Lecture 17-18

Notes for Lecture 17-18 U.C. Berkeley CS278: Compuaional Complexiy Handou N7-8 Professor Luca Trevisan April 3-8, 2008 Noes for Lecure 7-8 In hese wo lecures we prove he firs half of he PCP Theorem, he Amplificaion Lemma, up

More information

An introduction to the theory of SDDP algorithm

An introduction to the theory of SDDP algorithm An inroducion o he heory of SDDP algorihm V. Leclère (ENPC) Augus 1, 2014 V. Leclère Inroducion o SDDP Augus 1, 2014 1 / 21 Inroducion Large scale sochasic problem are hard o solve. Two ways of aacking

More information

Lecture Notes 2. The Hilbert Space Approach to Time Series

Lecture Notes 2. The Hilbert Space Approach to Time Series Time Series Seven N. Durlauf Universiy of Wisconsin. Basic ideas Lecure Noes. The Hilber Space Approach o Time Series The Hilber space framework provides a very powerful language for discussing he relaionship

More information

Class Meeting # 10: Introduction to the Wave Equation

Class Meeting # 10: Introduction to the Wave Equation MATH 8.5 COURSE NOTES - CLASS MEETING # 0 8.5 Inroducion o PDEs, Fall 0 Professor: Jared Speck Class Meeing # 0: Inroducion o he Wave Equaion. Wha is he wave equaion? The sandard wave equaion for a funcion

More information

Chapter 2. First Order Scalar Equations

Chapter 2. First Order Scalar Equations Chaper. Firs Order Scalar Equaions We sar our sudy of differenial equaions in he same way he pioneers in his field did. We show paricular echniques o solve paricular ypes of firs order differenial equaions.

More information

CHAPTER 2 Signals And Spectra

CHAPTER 2 Signals And Spectra CHAPER Signals And Specra Properies of Signals and Noise In communicaion sysems he received waveform is usually caegorized ino he desired par conaining he informaion, and he undesired par. he desired par

More information

ODEs II, Lecture 1: Homogeneous Linear Systems - I. Mike Raugh 1. March 8, 2004

ODEs II, Lecture 1: Homogeneous Linear Systems - I. Mike Raugh 1. March 8, 2004 ODEs II, Lecure : Homogeneous Linear Sysems - I Mike Raugh March 8, 4 Inroducion. In he firs lecure we discussed a sysem of linear ODEs for modeling he excreion of lead from he human body, saw how o ransform

More information

14 Autoregressive Moving Average Models

14 Autoregressive Moving Average Models 14 Auoregressive Moving Average Models In his chaper an imporan parameric family of saionary ime series is inroduced, he family of he auoregressive moving average, or ARMA, processes. For a large class

More information

On Boundedness of Q-Learning Iterates for Stochastic Shortest Path Problems

On Boundedness of Q-Learning Iterates for Stochastic Shortest Path Problems MATHEMATICS OF OPERATIONS RESEARCH Vol. 38, No. 2, May 2013, pp. 209 227 ISSN 0364-765X (prin) ISSN 1526-5471 (online) hp://dx.doi.org/10.1287/moor.1120.0562 2013 INFORMS On Boundedness of Q-Learning Ieraes

More information

6.2 Transforms of Derivatives and Integrals.

6.2 Transforms of Derivatives and Integrals. SEC. 6.2 Transforms of Derivaives and Inegrals. ODEs 2 3 33 39 23. Change of scale. If l( f ()) F(s) and c is any 33 45 APPLICATION OF s-shifting posiive consan, show ha l( f (c)) F(s>c)>c (Hin: In Probs.

More information

Physics 235 Chapter 2. Chapter 2 Newtonian Mechanics Single Particle

Physics 235 Chapter 2. Chapter 2 Newtonian Mechanics Single Particle Chaper 2 Newonian Mechanics Single Paricle In his Chaper we will review wha Newon s laws of mechanics ell us abou he moion of a single paricle. Newon s laws are only valid in suiable reference frames,

More information

11!Hí MATHEMATICS : ERDŐS AND ULAM PROC. N. A. S. of decomposiion, properly speaking) conradics he possibiliy of defining a counably addiive real-valu

11!Hí MATHEMATICS : ERDŐS AND ULAM PROC. N. A. S. of decomposiion, properly speaking) conradics he possibiliy of defining a counably addiive real-valu ON EQUATIONS WITH SETS AS UNKNOWNS BY PAUL ERDŐS AND S. ULAM DEPARTMENT OF MATHEMATICS, UNIVERSITY OF COLORADO, BOULDER Communicaed May 27, 1968 We shall presen here a number of resuls in se heory concerning

More information

2. Nonlinear Conservation Law Equations

2. Nonlinear Conservation Law Equations . Nonlinear Conservaion Law Equaions One of he clear lessons learned over recen years in sudying nonlinear parial differenial equaions is ha i is generally no wise o ry o aack a general class of nonlinear

More information

STABILITY OF PEXIDERIZED QUADRATIC FUNCTIONAL EQUATION IN NON-ARCHIMEDEAN FUZZY NORMED SPASES

STABILITY OF PEXIDERIZED QUADRATIC FUNCTIONAL EQUATION IN NON-ARCHIMEDEAN FUZZY NORMED SPASES Novi Sad J. Mah. Vol. 46, No. 1, 2016, 15-25 STABILITY OF PEXIDERIZED QUADRATIC FUNCTIONAL EQUATION IN NON-ARCHIMEDEAN FUZZY NORMED SPASES N. Eghbali 1 Absrac. We deermine some sabiliy resuls concerning

More information

Vehicle Arrival Models : Headway

Vehicle Arrival Models : Headway Chaper 12 Vehicle Arrival Models : Headway 12.1 Inroducion Modelling arrival of vehicle a secion of road is an imporan sep in raffic flow modelling. I has imporan applicaion in raffic flow simulaion where

More information

GENERALIZATION OF THE FORMULA OF FAA DI BRUNO FOR A COMPOSITE FUNCTION WITH A VECTOR ARGUMENT

GENERALIZATION OF THE FORMULA OF FAA DI BRUNO FOR A COMPOSITE FUNCTION WITH A VECTOR ARGUMENT Inerna J Mah & Mah Sci Vol 4, No 7 000) 48 49 S0670000970 Hindawi Publishing Corp GENERALIZATION OF THE FORMULA OF FAA DI BRUNO FOR A COMPOSITE FUNCTION WITH A VECTOR ARGUMENT RUMEN L MISHKOV Received

More information

Section 3.5 Nonhomogeneous Equations; Method of Undetermined Coefficients

Section 3.5 Nonhomogeneous Equations; Method of Undetermined Coefficients Secion 3.5 Nonhomogeneous Equaions; Mehod of Undeermined Coefficiens Key Terms/Ideas: Linear Differenial operaor Nonlinear operaor Second order homogeneous DE Second order nonhomogeneous DE Soluion o homogeneous

More information

ON THE DEGREES OF RATIONAL KNOTS

ON THE DEGREES OF RATIONAL KNOTS ON THE DEGREES OF RATIONAL KNOTS DONOVAN MCFERON, ALEXANDRA ZUSER Absrac. In his paper, we explore he issue of minimizing he degrees on raional knos. We se a bound on hese degrees using Bézou s heorem,

More information

A Specification Test for Linear Dynamic Stochastic General Equilibrium Models

A Specification Test for Linear Dynamic Stochastic General Equilibrium Models Journal of Saisical and Economeric Mehods, vol.1, no.2, 2012, 65-70 ISSN: 2241-0384 (prin), 2241-0376 (online) Scienpress Ld, 2012 A Specificaion Tes for Linear Dynamic Sochasic General Equilibrium Models

More information

Stability and Bifurcation in a Neural Network Model with Two Delays

Stability and Bifurcation in a Neural Network Model with Two Delays Inernaional Mahemaical Forum, Vol. 6, 11, no. 35, 175-1731 Sabiliy and Bifurcaion in a Neural Nework Model wih Two Delays GuangPing Hu and XiaoLing Li School of Mahemaics and Physics, Nanjing Universiy

More information

Roughness in ordered Semigroups. Muhammad Shabir and Shumaila Irshad

Roughness in ordered Semigroups. Muhammad Shabir and Shumaila Irshad World Applied Sciences Journal 22 (Special Issue of Applied Mah): 84-105, 2013 ISSN 1818-4952 IDOSI Publicaions, 2013 DOI: 105829/idosiwasj22am102013 Roughness in ordered Semigroups Muhammad Shabir and

More information

10. State Space Methods

10. State Space Methods . Sae Space Mehods. Inroducion Sae space modelling was briefly inroduced in chaper. Here more coverage is provided of sae space mehods before some of heir uses in conrol sysem design are covered in he

More information

A New Perturbative Approach in Nonlinear Singularity Analysis

A New Perturbative Approach in Nonlinear Singularity Analysis Journal of Mahemaics and Saisics 7 (: 49-54, ISSN 549-644 Science Publicaions A New Perurbaive Approach in Nonlinear Singulariy Analysis Ta-Leung Yee Deparmen of Mahemaics and Informaion Technology, The

More information

Finish reading Chapter 2 of Spivak, rereading earlier sections as necessary. handout and fill in some missing details!

Finish reading Chapter 2 of Spivak, rereading earlier sections as necessary. handout and fill in some missing details! MAT 257, Handou 6: Ocober 7-2, 20. I. Assignmen. Finish reading Chaper 2 of Spiva, rereading earlier secions as necessary. handou and fill in some missing deails! II. Higher derivaives. Also, read his

More information

EXPLICIT TIME INTEGRATORS FOR NONLINEAR DYNAMICS DERIVED FROM THE MIDPOINT RULE

EXPLICIT TIME INTEGRATORS FOR NONLINEAR DYNAMICS DERIVED FROM THE MIDPOINT RULE Version April 30, 2004.Submied o CTU Repors. EXPLICIT TIME INTEGRATORS FOR NONLINEAR DYNAMICS DERIVED FROM THE MIDPOINT RULE Per Krysl Universiy of California, San Diego La Jolla, California 92093-0085,

More information

Approximation Algorithms for Unique Games via Orthogonal Separators

Approximation Algorithms for Unique Games via Orthogonal Separators Approximaion Algorihms for Unique Games via Orhogonal Separaors Lecure noes by Konsanin Makarychev. Lecure noes are based on he papers [CMM06a, CMM06b, LM4]. Unique Games In hese lecure noes, we define

More information

Undetermined coefficients for local fractional differential equations

Undetermined coefficients for local fractional differential equations Available online a www.isr-publicaions.com/jmcs J. Mah. Compuer Sci. 16 (2016), 140 146 Research Aricle Undeermined coefficiens for local fracional differenial equaions Roshdi Khalil a,, Mohammed Al Horani

More information

Retrieval Models. Boolean and Vector Space Retrieval Models. Common Preprocessing Steps. Boolean Model. Boolean Retrieval Model

Retrieval Models. Boolean and Vector Space Retrieval Models. Common Preprocessing Steps. Boolean Model. Boolean Retrieval Model 1 Boolean and Vecor Space Rerieval Models Many slides in his secion are adaped from Prof. Joydeep Ghosh (UT ECE) who in urn adaped hem from Prof. Dik Lee (Univ. of Science and Tech, Hong Kong) Rerieval

More information

Languages That Are and Are Not Context-Free

Languages That Are and Are Not Context-Free Languages Tha re and re No Conex-Free Read K & S 3.5, 3.6, 3.7. Read Supplemenary Maerials: Conex-Free Languages and Pushdown uomaa: Closure Properies of Conex-Free Languages Read Supplemenary Maerials:

More information

Query Answering over Fact Bases for Fuzzy Interval Ontologies

Query Answering over Fact Bases for Fuzzy Interval Ontologies Query Answering over Fac Bases for Fuzzy Inerval Onologies Gerald S. Plesniewicz, Vu Nguen Thi Min, Dmiry Masherov Naional Research Universiy MPEI e-mail1: salve777@mail.ru Absrac. Temporal onologies conain

More information

THE GEOMETRY MONOID OF AN IDENTITY

THE GEOMETRY MONOID OF AN IDENTITY THE GEOMETRY MONOID OF AN IDENTITY Parick DEHORNOY Universié decaen Main idea: For each algebraic ideniy I, (more generally, for each family of algebraic ideniy, acually for each equaional variey), here

More information

1 Review of Zero-Sum Games

1 Review of Zero-Sum Games COS 5: heoreical Machine Learning Lecurer: Rob Schapire Lecure #23 Scribe: Eugene Brevdo April 30, 2008 Review of Zero-Sum Games Las ime we inroduced a mahemaical model for wo player zero-sum games. Any

More information

We just finished the Erdős-Stone Theorem, and ex(n, F ) (1 1/(χ(F ) 1)) ( n

We just finished the Erdős-Stone Theorem, and ex(n, F ) (1 1/(χ(F ) 1)) ( n Lecure 3 - Kövari-Sós-Turán Theorem Jacques Versraëe jacques@ucsd.edu We jus finished he Erdős-Sone Theorem, and ex(n, F ) ( /(χ(f ) )) ( n 2). So we have asympoics when χ(f ) 3 bu no when χ(f ) = 2 i.e.

More information

GMM - Generalized Method of Moments

GMM - Generalized Method of Moments GMM - Generalized Mehod of Momens Conens GMM esimaion, shor inroducion 2 GMM inuiion: Maching momens 2 3 General overview of GMM esimaion. 3 3. Weighing marix...........................................

More information

I. Introduction to place/transition nets. Place/Transition Nets I. Example: a vending machine. Example: a vending machine

I. Introduction to place/transition nets. Place/Transition Nets I. Example: a vending machine. Example: a vending machine Inroducory Tuorial I. Inroducion o place/ransiion nes Place/Transiion Nes I Prepared by: Jörg Desel, Caholic Universiy in Eichsä and Karsen Schmid, Humbold-Universiä zu Berlin Speaker: Wolfgang Reisig,

More information

Ordinary Differential Equations

Ordinary Differential Equations Ordinary Differenial Equaions 5. Examples of linear differenial equaions and heir applicaions We consider some examples of sysems of linear differenial equaions wih consan coefficiens y = a y +... + a

More information

Lecture 20: Riccati Equations and Least Squares Feedback Control

Lecture 20: Riccati Equations and Least Squares Feedback Control 34-5 LINEAR SYSTEMS Lecure : Riccai Equaions and Leas Squares Feedback Conrol 5.6.4 Sae Feedback via Riccai Equaions A recursive approach in generaing he marix-valued funcion W ( ) equaion for i for he

More information

Average Number of Lattice Points in a Disk

Average Number of Lattice Points in a Disk Average Number of Laice Poins in a Disk Sujay Jayakar Rober S. Sricharz Absrac The difference beween he number of laice poins in a disk of radius /π and he area of he disk /4π is equal o he error in he

More information

Inventory Analysis and Management. Multi-Period Stochastic Models: Optimality of (s, S) Policy for K-Convex Objective Functions

Inventory Analysis and Management. Multi-Period Stochastic Models: Optimality of (s, S) Policy for K-Convex Objective Functions Muli-Period Sochasic Models: Opimali of (s, S) Polic for -Convex Objecive Funcions Consider a seing similar o he N-sage newsvendor problem excep ha now here is a fixed re-ordering cos (> 0) for each (re-)order.

More information

Matlab and Python programming: how to get started

Matlab and Python programming: how to get started Malab and Pyhon programming: how o ge sared Equipping readers he skills o wrie programs o explore complex sysems and discover ineresing paerns from big daa is one of he main goals of his book. In his chaper,

More information

Electrical and current self-induction

Electrical and current self-induction Elecrical and curren self-inducion F. F. Mende hp://fmnauka.narod.ru/works.hml mende_fedor@mail.ru Absrac The aricle considers he self-inducance of reacive elemens. Elecrical self-inducion To he laws of

More information

The Asymptotic Behavior of Nonoscillatory Solutions of Some Nonlinear Dynamic Equations on Time Scales

The Asymptotic Behavior of Nonoscillatory Solutions of Some Nonlinear Dynamic Equations on Time Scales Advances in Dynamical Sysems and Applicaions. ISSN 0973-5321 Volume 1 Number 1 (2006, pp. 103 112 c Research India Publicaions hp://www.ripublicaion.com/adsa.hm The Asympoic Behavior of Nonoscillaory Soluions

More information

On Multicomponent System Reliability with Microshocks - Microdamages Type of Components Interaction

On Multicomponent System Reliability with Microshocks - Microdamages Type of Components Interaction On Mulicomponen Sysem Reliabiliy wih Microshocks - Microdamages Type of Componens Ineracion Jerzy K. Filus, and Lidia Z. Filus Absrac Consider a wo componen parallel sysem. The defined new sochasic dependences

More information

SUPPLEMENTARY INFORMATION

SUPPLEMENTARY INFORMATION SUPPLEMENTARY INFORMATION DOI: 0.038/NCLIMATE893 Temporal resoluion and DICE * Supplemenal Informaion Alex L. Maren and Sephen C. Newbold Naional Cener for Environmenal Economics, US Environmenal Proecion

More information

Transitivity of Commutativity for Linear Time-Varying Analog Systems. Mehmet Emir KOKSAL

Transitivity of Commutativity for Linear Time-Varying Analog Systems. Mehmet Emir KOKSAL Transiiviy of Commuaiviy for Linear Time-Varying Analog Sysems Mehme Emir KOKSAL Deparmen of Mahemaics, Ondokuz Mayis Universiy, 5539 Aakum, Samsun, Turkey emir_koksal@homail.com Absrac: In his conribuion,

More information

Signal and System (Chapter 3. Continuous-Time Systems)

Signal and System (Chapter 3. Continuous-Time Systems) Signal and Sysem (Chaper 3. Coninuous-Time Sysems) Prof. Kwang-Chun Ho kwangho@hansung.ac.kr Tel: 0-760-453 Fax:0-760-4435 1 Dep. Elecronics and Informaion Eng. 1 Nodes, Branches, Loops A nework wih b

More information

Christos Papadimitriou & Luca Trevisan November 22, 2016

Christos Papadimitriou & Luca Trevisan November 22, 2016 U.C. Bereley CS170: Algorihms Handou LN-11-22 Chrisos Papadimiriou & Luca Trevisan November 22, 2016 Sreaming algorihms In his lecure and he nex one we sudy memory-efficien algorihms ha process a sream

More information

Expert Advice for Amateurs

Expert Advice for Amateurs Exper Advice for Amaeurs Ernes K. Lai Online Appendix - Exisence of Equilibria The analysis in his secion is performed under more general payoff funcions. Wihou aking an explici form, he payoffs of he

More information

Expanding an Extended Finite State Machine to aid Testability

Expanding an Extended Finite State Machine to aid Testability Expanding an Exended Finie Sae Machine o aid Tesabiliy R. M. Hierons Brunel Universiy Uxbridge Middlesex UB8 3PH UK rob.hierons@brunel.ac.uk T.-H. Kim Universiy of Oawa Oawa Onario KN 6N5 Canada aehyong@sie.uoawa.ca

More information

STATE-SPACE MODELLING. A mass balance across the tank gives:

STATE-SPACE MODELLING. A mass balance across the tank gives: B. Lennox and N.F. Thornhill, 9, Sae Space Modelling, IChemE Process Managemen and Conrol Subjec Group Newsleer STE-SPACE MODELLING Inroducion: Over he pas decade or so here has been an ever increasing

More information

DYNAMIC ECONOMETRIC MODELS vol NICHOLAS COPERNICUS UNIVERSITY - TORUŃ Józef Stawicki and Joanna Górka Nicholas Copernicus University

DYNAMIC ECONOMETRIC MODELS vol NICHOLAS COPERNICUS UNIVERSITY - TORUŃ Józef Stawicki and Joanna Górka Nicholas Copernicus University DYNAMIC ECONOMETRIC MODELS vol.. - NICHOLAS COPERNICUS UNIVERSITY - TORUŃ 996 Józef Sawicki and Joanna Górka Nicholas Copernicus Universiy ARMA represenaion for a sum of auoregressive processes In he ime

More information

Li An-Ping. Beijing , P.R.China

Li An-Ping. Beijing , P.R.China A NEW TYPE OF CIPHER: DICING_CSB Li An-Ping Beijing 100085, P.R.China apli0001@sina.com Absrac: In his paper, we will propose a new ype of cipher named DICING_CSB, which come from our previous a synchronous

More information

ACE 562 Fall Lecture 4: Simple Linear Regression Model: Specification and Estimation. by Professor Scott H. Irwin

ACE 562 Fall Lecture 4: Simple Linear Regression Model: Specification and Estimation. by Professor Scott H. Irwin ACE 56 Fall 005 Lecure 4: Simple Linear Regression Model: Specificaion and Esimaion by Professor Sco H. Irwin Required Reading: Griffihs, Hill and Judge. "Simple Regression: Economic and Saisical Model

More information

Final Spring 2007

Final Spring 2007 .615 Final Spring 7 Overview The purpose of he final exam is o calculae he MHD β limi in a high-bea oroidal okamak agains he dangerous n = 1 exernal ballooning-kink mode. Effecively, his corresponds o

More information

STA 114: Statistics. Notes 2. Statistical Models and the Likelihood Function

STA 114: Statistics. Notes 2. Statistical Models and the Likelihood Function STA 114: Saisics Noes 2. Saisical Models and he Likelihood Funcion Describing Daa & Saisical Models A physicis has a heory ha makes a precise predicion of wha s o be observed in daa. If he daa doesn mach

More information

Generalized Chebyshev polynomials

Generalized Chebyshev polynomials Generalized Chebyshev polynomials Clemene Cesarano Faculy of Engineering, Inernaional Telemaic Universiy UNINETTUNO Corso Viorio Emanuele II, 39 86 Roma, Ialy email: c.cesarano@unineunouniversiy.ne ABSTRACT

More information

A New Kind of Fuzzy Sublattice (Ideal, Filter) of A Lattice

A New Kind of Fuzzy Sublattice (Ideal, Filter) of A Lattice nernaional Journal of Fuzzy Sysems Vol 3 No March 2 55 A New Kind of Fuzzy Sublaice (deal Filer) of A Laice B Davvaz O Kazanci Absrac Our aim in his paper is o inroduce sudy a new sor of fuzzy sublaice

More information

Learning Objectives: Practice designing and simulating digital circuits including flip flops Experience state machine design procedure

Learning Objectives: Practice designing and simulating digital circuits including flip flops Experience state machine design procedure Lab 4: Synchronous Sae Machine Design Summary: Design and implemen synchronous sae machine circuis and es hem wih simulaions in Cadence Viruoso. Learning Objecives: Pracice designing and simulaing digial

More information

Two Coupled Oscillators / Normal Modes

Two Coupled Oscillators / Normal Modes Lecure 3 Phys 3750 Two Coupled Oscillaors / Normal Modes Overview and Moivaion: Today we ake a small, bu significan, sep owards wave moion. We will no ye observe waves, bu his sep is imporan in is own

More information

Learning to Take Concurrent Actions

Learning to Take Concurrent Actions Learning o Take Concurren Acions Khashayar Rohanimanesh Deparmen of Compuer Science Universiy of Massachuses Amhers, MA 0003 khash@cs.umass.edu Sridhar Mahadevan Deparmen of Compuer Science Universiy of

More information

d 1 = c 1 b 2 - b 1 c 2 d 2 = c 1 b 3 - b 1 c 3

d 1 = c 1 b 2 - b 1 c 2 d 2 = c 1 b 3 - b 1 c 3 and d = c b - b c c d = c b - b c c This process is coninued unil he nh row has been compleed. The complee array of coefficiens is riangular. Noe ha in developing he array an enire row may be divided or

More information

23.2. Representing Periodic Functions by Fourier Series. Introduction. Prerequisites. Learning Outcomes

23.2. Representing Periodic Functions by Fourier Series. Introduction. Prerequisites. Learning Outcomes Represening Periodic Funcions by Fourier Series 3. Inroducion In his Secion we show how a periodic funcion can be expressed as a series of sines and cosines. We begin by obaining some sandard inegrals

More information

ERROR LOCATING CODES AND EXTENDED HAMMING CODE. Pankaj Kumar Das. 1. Introduction and preliminaries

ERROR LOCATING CODES AND EXTENDED HAMMING CODE. Pankaj Kumar Das. 1. Introduction and preliminaries MATEMATIČKI VESNIK MATEMATIQKI VESNIK 70, 1 (2018), 89 94 March 2018 research paper originalni nauqni rad ERROR LOCATING CODES AND EXTENDED HAMMING CODE Pankaj Kumar Das Absrac. Error-locaing codes, firs

More information

Clarke s Generalized Gradient and Edalat s L-derivative

Clarke s Generalized Gradient and Edalat s L-derivative 1 21 ISSN 1759-9008 1 Clarke s Generalized Gradien and Edala s L-derivaive PETER HERTLING Absrac: Clarke [2, 3, 4] inroduced a generalized gradien for real-valued Lipschiz coninuous funcions on Banach

More information

Analyze patterns and relationships. 3. Generate two numerical patterns using AC

Analyze patterns and relationships. 3. Generate two numerical patterns using AC envision ah 2.0 5h Grade ah Curriculum Quarer 1 Quarer 2 Quarer 3 Quarer 4 andards: =ajor =upporing =Addiional Firs 30 Day 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 andards: Operaions and Algebraic Thinking

More information

Rainbow saturation and graph capacities

Rainbow saturation and graph capacities Rainbow sauraion and graph capaciies Dániel Korándi Absrac The -colored rainbow sauraion number rsa (n, F ) is he minimum size of a -edge-colored graph on n verices ha conains no rainbow copy of F, bu

More information

KEY. Math 334 Midterm III Winter 2008 section 002 Instructor: Scott Glasgow

KEY. Math 334 Midterm III Winter 2008 section 002 Instructor: Scott Glasgow KEY Mah 334 Miderm III Winer 008 secion 00 Insrucor: Sco Glasgow Please do NOT wrie on his exam. No credi will be given for such work. Raher wrie in a blue book, or on your own paper, preferably engineering

More information

More Digital Logic. t p output. Low-to-high and high-to-low transitions could have different t p. V in (t)

More Digital Logic. t p output. Low-to-high and high-to-low transitions could have different t p. V in (t) EECS 4 Spring 23 Lecure 2 EECS 4 Spring 23 Lecure 2 More igial Logic Gae delay and signal propagaion Clocked circui elemens (flip-flop) Wriing a word o memory Simplifying digial circuis: Karnaugh maps

More information

Single and Double Pendulum Models

Single and Double Pendulum Models Single and Double Pendulum Models Mah 596 Projec Summary Spring 2016 Jarod Har 1 Overview Differen ypes of pendulums are used o model many phenomena in various disciplines. In paricular, single and double

More information

Chapter 3 Boundary Value Problem

Chapter 3 Boundary Value Problem Chaper 3 Boundary Value Problem A boundary value problem (BVP) is a problem, ypically an ODE or a PDE, which has values assigned on he physical boundary of he domain in which he problem is specified. Le

More information

Math 315: Linear Algebra Solutions to Assignment 6

Math 315: Linear Algebra Solutions to Assignment 6 Mah 35: Linear Algebra s o Assignmen 6 # Which of he following ses of vecors are bases for R 2? {2,, 3, }, {4,, 7, 8}, {,,, 3}, {3, 9, 4, 2}. Explain your answer. To generae he whole R 2, wo linearly independen

More information

Hamilton- J acobi Equation: Weak S olution We continue the study of the Hamilton-Jacobi equation:

Hamilton- J acobi Equation: Weak S olution We continue the study of the Hamilton-Jacobi equation: M ah 5 7 Fall 9 L ecure O c. 4, 9 ) Hamilon- J acobi Equaion: Weak S oluion We coninue he sudy of he Hamilon-Jacobi equaion: We have shown ha u + H D u) = R n, ) ; u = g R n { = }. ). In general we canno

More information

EXERCISES FOR SECTION 1.5

EXERCISES FOR SECTION 1.5 1.5 Exisence and Uniqueness of Soluions 43 20. 1 v c 21. 1 v c 1 2 4 6 8 10 1 2 2 4 6 8 10 Graph of approximae soluion obained using Euler s mehod wih = 0.1. Graph of approximae soluion obained using Euler

More information

Let us start with a two dimensional case. We consider a vector ( x,

Let us start with a two dimensional case. We consider a vector ( x, Roaion marices We consider now roaion marices in wo and hree dimensions. We sar wih wo dimensions since wo dimensions are easier han hree o undersand, and one dimension is a lile oo simple. However, our

More information

Course Notes for EE227C (Spring 2018): Convex Optimization and Approximation

Course Notes for EE227C (Spring 2018): Convex Optimization and Approximation Course Noes for EE7C Spring 018: Convex Opimizaion and Approximaion Insrucor: Moriz Hard Email: hard+ee7c@berkeley.edu Graduae Insrucor: Max Simchowiz Email: msimchow+ee7c@berkeley.edu Ocober 15, 018 3

More information

23.5. Half-Range Series. Introduction. Prerequisites. Learning Outcomes

23.5. Half-Range Series. Introduction. Prerequisites. Learning Outcomes Half-Range Series 2.5 Inroducion In his Secion we address he following problem: Can we find a Fourier series expansion of a funcion defined over a finie inerval? Of course we recognise ha such a funcion

More information

Convergence of the Neumann series in higher norms

Convergence of the Neumann series in higher norms Convergence of he Neumann series in higher norms Charles L. Epsein Deparmen of Mahemaics, Universiy of Pennsylvania Version 1.0 Augus 1, 003 Absrac Naural condiions on an operaor A are given so ha he Neumann

More information

Online Appendix to Solution Methods for Models with Rare Disasters

Online Appendix to Solution Methods for Models with Rare Disasters Online Appendix o Soluion Mehods for Models wih Rare Disasers Jesús Fernández-Villaverde and Oren Levinal In his Online Appendix, we presen he Euler condiions of he model, we develop he pricing Calvo block,

More information

Relational Views Framework for Proving Linearizability

Relational Views Framework for Proving Linearizability Relaional Views Framework for Proving Linearizabiliy (of concurren libraries) Arem Khyzha Alexey Gosman Mahew Parkinson oncurren libraries Encapsulae efficien concurren algorihms - Java: java.uil.concurren

More information

Random Walk with Anti-Correlated Steps

Random Walk with Anti-Correlated Steps Random Walk wih Ani-Correlaed Seps John Noga Dirk Wagner 2 Absrac We conjecure he expeced value of random walks wih ani-correlaed seps o be exacly. We suppor his conjecure wih 2 plausibiliy argumens and

More information

Basilio Bona ROBOTICA 03CFIOR 1

Basilio Bona ROBOTICA 03CFIOR 1 Indusrial Robos Kinemaics 1 Kinemaics and kinemaic funcions Kinemaics deals wih he sudy of four funcions (called kinemaic funcions or KFs) ha mahemaically ransform join variables ino caresian variables

More information

0.1 MAXIMUM LIKELIHOOD ESTIMATION EXPLAINED

0.1 MAXIMUM LIKELIHOOD ESTIMATION EXPLAINED 0.1 MAXIMUM LIKELIHOOD ESTIMATIO EXPLAIED Maximum likelihood esimaion is a bes-fi saisical mehod for he esimaion of he values of he parameers of a sysem, based on a se of observaions of a random variable

More information

A Note on the Equivalence of Fractional Relaxation Equations to Differential Equations with Varying Coefficients

A Note on the Equivalence of Fractional Relaxation Equations to Differential Equations with Varying Coefficients mahemaics Aricle A Noe on he Equivalence of Fracional Relaxaion Equaions o Differenial Equaions wih Varying Coefficiens Francesco Mainardi Deparmen of Physics and Asronomy, Universiy of Bologna, and he

More information

Algebraic Attacks on Summation Generators

Algebraic Attacks on Summation Generators Algebraic Aacks on Summaion Generaors Dong Hoon Lee, Jaeheon Kim, Jin Hong, Jae Woo Han, and Dukjae Moon Naional Securiy Research Insiue 161 Gajeong-dong, Yuseong-gu, Daejeon, 305-350, Korea {dlee,jaeheon,jinhong,jwhan,djmoon}@eri.re.kr

More information

Variational Iteration Method for Solving System of Fractional Order Ordinary Differential Equations

Variational Iteration Method for Solving System of Fractional Order Ordinary Differential Equations IOSR Journal of Mahemaics (IOSR-JM) e-issn: 2278-5728, p-issn: 2319-765X. Volume 1, Issue 6 Ver. II (Nov - Dec. 214), PP 48-54 Variaional Ieraion Mehod for Solving Sysem of Fracional Order Ordinary Differenial

More information

Technical Report Doc ID: TR March-2013 (Last revision: 23-February-2016) On formulating quadratic functions in optimization models.

Technical Report Doc ID: TR March-2013 (Last revision: 23-February-2016) On formulating quadratic functions in optimization models. Technical Repor Doc ID: TR--203 06-March-203 (Las revision: 23-Februar-206) On formulaing quadraic funcions in opimizaion models. Auhor: Erling D. Andersen Convex quadraic consrains quie frequenl appear

More information

Appendix 14.1 The optimal control problem and its solution using

Appendix 14.1 The optimal control problem and its solution using 1 Appendix 14.1 he opimal conrol problem and is soluion using he maximum principle NOE: Many occurrences of f, x, u, and in his file (in equaions or as whole words in ex) are purposefully in bold in order

More information

Hedgehogs are not colour blind

Hedgehogs are not colour blind Hedgehogs are no colour blind David Conlon Jacob Fox Vojěch Rödl Absrac We exhibi a family of 3-uniform hypergraphs wih he propery ha heir 2-colour Ramsey numbers grow polynomially in he number of verices,

More information

ACE 562 Fall Lecture 5: The Simple Linear Regression Model: Sampling Properties of the Least Squares Estimators. by Professor Scott H.

ACE 562 Fall Lecture 5: The Simple Linear Regression Model: Sampling Properties of the Least Squares Estimators. by Professor Scott H. ACE 56 Fall 005 Lecure 5: he Simple Linear Regression Model: Sampling Properies of he Leas Squares Esimaors by Professor Sco H. Irwin Required Reading: Griffihs, Hill and Judge. "Inference in he Simple

More information