Blame and Coercion: Together Again for the First Time

Size: px
Start display at page:

Download "Blame and Coercion: Together Again for the First Time"

Transcription

1 Blame and Coercion: Together Again for the First Time Supplementary Material Jeremy Siek Indiana University, USA Peter Thiemann Universität Freiburg, Germany Philip Wadler University of Edinburgh, UK Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from permissions@acm.org. PLDI 15, June 13 17, 2015, Portland, OR, USA. Copyright c 2015 ACM /15/06... $

2 A. Positive and negative subtyping Lemma 1 (Positive and negative subtyping). 1. A <: + B iff A p = B BC safe C p. 2. A <: B iff A p = B BC safe C p. Proof. A <: + B implies A = p B BC safe C p and A <: B implies A = p B BC safe C p is proved by mutual induction on the definition of A = p B BC. s for positive subtyping: p ι = ι BC = id ι satisfies ι <: + ι and id ι safe C p. A B = p A B BC = A p = A BC B = p B BC. From the assumption A B <: + A B, we obtain A <: A and B <: + B. By induction, we get that A p = A BC safe C p and B = p B BC safe C p, which proves the claim. = p BC = id satisfies <: + and id safe C p. G = p BC = G!. Immediate because G <: +. A = p BC = A = p G BC ; G! where A, A G, and A G. Hence, it must be that G = and A = A B so that A = p G BC = A B p = BC = = p A BC B p = BC. Since <: A and B <: +, the result holds by induction. = p G BC. Not applicable because : + G. = p A BC where A, A G, and A G. Not applicable because : + A. s for negative subtyping: p ι = ι BC = id ι satisfies ι <: ι and id ι safe C p. A B = p A B BC = A p = A BC B = p B BC. From the assumption A B <: A B, we obtain A <: + A and B <: B. By induction, we get that A p = A BC safe C p and B = p B BC safe C p, which proves the claim. = p BC = id satisfies <: and id safe C p. G = p BC = G!. Immediate because G <:. A = p BC = A = p G BC ; G!. If A <:, then it must be that A <: G. Hence, the claim holds by induction. = p G BC = G? p is safe for p and <: G holds. = p B BC = G? p ; G = p B BC (where B, B G, and G B). <: B is satisfied regardless of B. Hence, it must be that G = so that B = A B and we need to examine = p A B BC = A p = BC = p B BC. As A <: + and <: B we can argue by induction that A p = BC safe C p and = p B BC safe C p. The reverse implication is proved by similar mutual induction on the definition of the translation.

3 B. Bisimulation between coercions and threesomes Here we give the full proof of Proposition 16. Lemma 2 (Compose Identity Threesomes). s id A CS = s and id A CS s = s Proof. The proof is a straightforward induction on s and A. Lemma 3. If M s and t V 2, then M s t V 2. Proof of Proposition 16. Part 1 and 2. We proceed by case analysis on M M, in each case proving the two statements: 1. If M C N then M S N and N N for some N. 2. If M S N then M C N and N N for some N. (Here we assume parts 3 and 4, which we later prove independently.) Both statements are vacuously true because k cannot reduce. k k M M op( M) op( M ) 1. op( k) op( M ) op( k) δ(op, k) δ(op, k) 2. op( M) op( k) op( k) δ(op, k) δ(op, k) x x Both statements are vacuously true because x cannot reduce. M M λx:a. M λx:a. M Both statements are vacouously true because lambda terms cannot reduce. M 1 M 1 M 2 M 2 M 1 M 2 M 1 M 2 1. We proceed by case analysis on M = M 1 M 2 C N. So either M 1 reduces, M 2 reduces, or they are both values. Suppose M 1 reduces, i.e., M 1 C M 3. From M 1 M 2 M, we have M = M 1 M 2 and M 1 M 1 and M 2 M 2. By the induction hypothesis, M 1 S M 3 and M 3 M 3. So M 1 M 2 S M 3 M 2 and M 3 M 2 M 3 M 2. The case for M 2 reducing is essentialy the same as for M 1 reducing. Suppose M 1 and M 2 are values. We proceed by cases on M 1. M 1 = k: M cannot reduce; M 1 = λx:a. M 11: part of beta redex, see (a) below; M 1 = V c d : part of coercion redex, see (b) below; M 1 = V G! : M cannot reduce. Let V 2 = M 2. (a) (λx:a. M 11) V 2 C M 11[x := V ] We have (λx:a. M 11) V 2 M 1 M 2 then proceed by case analysis on (λx:a. M 11) V 1. V 2

4 Subcase M 11 M 11 λx:a. M 11 λx:a. M 11 (λx:a. M 11) V 2 (λx:a. M 11) V 2 Subcase λx:a. M 11 U λx:a. M 11 U id A B CS M 11[x := V 2] M 11[x := V 2] (λx:a. M 11) V 2 U id A B CS V 2 (U V 2 id A CS ) id B CS ((λx:a. M 11) V 2 id A CS ) id B CS M 11[x := V 2] M 11[x := V 2 id A CS ] id B CS (b) (V c d ) W C (V W c ) d We proceed by induction on V c d M 1. There are two cases to consider. (Rule (iii) does not apply because the premise would relate a value to a function application.) Subcase rule (i). V c d M 11 V c d : A B V c d M 11 id A id B We have M 11 1 and V c d 1 by induction. So we have 1 = U (s 1 s 2) c d CS and V U s 1 s 2. (V c d ) W The left is related to the right by rule (iii). Subcase rule (ii). because (M 11 id A id B ) M 2 U (s 1 s 2) c d CS id A id B V 2 U (s 1 s 2) c d CS (id A id B) V 2 Lemma 2 (V W c ) d (U (s 1 s 2) c d CS ) V (V c d ) W (V W c ) d V M 11 s (M 11 s c CS d CS ) M 2 W M 2 W c M 2 c CS V W c (M 11 s ) (M 2 c CS ) (V W c ) d (M 11 s c CS d CS ) M 2 2. We proceed by case analysis on M 1 M 2 S N. (a) (λx:a. M 11) V 2 S M 11[x := V 2] M 1 M 2 (λx:a. M 11) V 2 (λx:a. M 11) V M 11[x := V 2] M 11[x := V 2] 2 2

5 (b) (U s t ) W S (U W s ) t M 1 M 2 ( c n d n c 1 d 1 ) V 2 (U s t ) W ( (V 2 c 1 c n )) d n d 1 (U W s ) t M 1 M 1 c CS = s M 1 c M 1 s 1. We proceed by case analysis on M 1 c C N. (a) id A C V1 ida M 1 id A CS (b) G! G? p C V1 G! G? p V 1 id A CS M 1 id G CS ; G! G? p ; id G CS (c) G! H? p C blame p V 1 id G CS ; G! G? p ; id G CS V G! H? p M 1 id G CS ; G! H? p ; id H CS 1 M 1 p A B blame p blame p (d) c; d C c d (e) p A B C blame p 2. We proceed by case analysis on M 1 t S N. c; d c d p A B M 1 t M 1 p A B blame p blame p (a) U id ι S U M1 idι id ι U id ι U

6 (b) U id S U M 1 id id U id (c) M 2 s t S M 2 s t U M 1 c M 2 s t We have M 1 M 2 s and therefore M 1 c M 2 s t. (d) U p A B S blame p M 1 c M 2 s t M 1 p A B p A B U p A B blame p blame p M 1 M 1 s c CS = t M 1 c M 1 s t 1. We proceed by case analysis on M 1 c C N. (a) id A C id A (b) G! G? p C G! G? p M 1 s id A CS M 1 s G! G? p (c) G! H? p C blame p G! H? p M 1 s M 1 s G! H? p ; id H CS M 1 p A B (d) c; d C c d (e) p A B C blame p blame p blame p c; d c d p A B M 1 s t M 1 s p A B M 1 p A B blame p blame p

7 2. We proceed by case analysis on M 1 s t S N. (a) U id ι S U. There are two cases for s t = id ι: i. s = t = id ι M 1 id ι id ι U id ι U ii. s = id ι; ι! and t = ι? p ; id ι. In that case, the assumption is M 1 U id ι; ι!. By inversion, M 1 = M 11 ι! and M 11 U id ι. By further inversion, M 11 U. Hence: M 11 ι! ι? p ι! ι? p U id ι U (b) U id S U M 1 id id U id (c) M 2 s s t S M 2 s s t U M 1 c M 2 s s t M 1 c M 2 s s t We have M 1 M 2 s s and therefore M 1 M 2 s s. With t CS = c we conclude M 1 c M 2 s s t. (d) U p A B S blame p There are three ways that we could have s t = p A B. i. s = (g; G!), t = (H? p ; i) M 1 c U p A B G! H? p blame p blame p ii. s = p A B We have M 1 U p A B so by the induction hypothesis M1 blame p. M 1 c U p A B blame p blame p iii. t = p A B M 1 p A B p A B blame p U p A B blame p

8 M 1 M 1 s M 2 t 1 d CS = t 2 M 1 d M 1 s (t 1 t 2) M 2 1. We proceed by case analysis on M 1 d C N, but every case is vacuously true because they require M 1 to be a value, but M 1 corresponds to a function application. 2. We proceed by cases on M 1 s (t 1 t 2) M 2 S N. We have M 1 U s 1 s 2 W t 1. So M 1 = (M 2 M 3 c c 1 ) d 1 where c d CS = t 1 t 2 and c 1 d 1; ; c n d n CS = s 1 s 2. (M 2.. c k d k M 3 c c 1..).. d 1 d (V 2.. c k d k V 3 c c 1..).. d 1 d U s 1 s 2 t 1 t 2 W (V 2 W c c 1.. c n ) d n.. d 1 d (U W t 1 s 1 ) s 2 t 2 Part 3. We show that the term M on the right can become a value V that corresponds to V. We proceed by induction on V. V = k. We proceed by cases on k M, but we only have one case to consider. Subcase k k Take V = k. V = λx:a. N. We proceed by induction on (λx:a. N) M. Subcase N N λx:a. N λx:a. N We take V = λx:a. N. λx:a. N M 1 id A B CS = id A id B Subcase λx:a. N M 1 id A id B By the inner induction hypothesis we have the following. Now suppose = λx:a. N. Then id A id B is a value. On the other hand, suppose = U s t. λx:a. N M 1 id A id B V 1 id A id B λx:a. N U s t id A id B U s t V = G!. We proceed by induction on G! M. There is one case to consider. (Rule (iii) does not apply because the premises would relate a value to a function application.) Subcase rule (i) G! M 1 G! M 1 id CS G! M 1 id V 1 id Subcase rule (ii) G! V M 1 s G! M 1 s G! CS 1

9 The inner induction hypothesis gives us V1 M 1 s Suppose = k. Then k G! CS is a value. By Lemma 3 we have k G! M 1 s G! CS k G! CS Suppose V 1 = λx:a. N. Then (λx:a. N ) G! CS is a value. By Lemma 3 we have G! M 1 s G! CS (λx:a. N ) G! CS Suppose = U g; H!. Then has type, but that contradicts it having type G. Suppose = U s t. We have G! U s t G! CS By Lemma 3 we conclude U (s t ); G! G! M 1 s G! CS U (s t ); G! V = c d. We proceed by induction on c d M. There are three cases to consider. (Rule (iii) does not apply because the premise would relate a value to a function application.) Subcase rule (i) c d M 1 c d : A B id A B CS = t c d M 1 t We have M 1 and c d by the inner induction hypothesis. We proceed by cases on with the knowledge that it is of function type. Suppose = λx:a. e. Then id A id B is a value and we relate the left to the right by rule (i). Suppose = U c d. c d U c d id A CS id A CS Subcase rule (ii) M 1 s c d CS = t U (c d ) ( id A CS id A CS ) Lemma 2 c d U c d c d M 1 s t We have M 1 s and by the inner induction hypothesis. Then applying some case analysis on we have c CS d CS V and c d V for some V. Part 4. We show that the term M on the left can become a value that corresponds to V. We proceed by induction on V. V = k. By inversion on M k we have M = k, which is already a value, so we take V = M. V = λx:a. N. By inversion on M λx:a. N we have M = λx:a. N and take V = M. V = U s t. Inversion of M U s t gives us two cases to consider. Subcase for rule (i) M U M : A id A CS = s t M U s t

10 By the induction hypothesis, M C V where V U. Then the left and right sides are related by rule (i). Subcase for rule (ii). M 1 U s c CS = t M 1 c U s t We have M = M 1 c and (s t ) = s t. By the induction hypothesis, M 1 C where U s. We proceed with a nested induction on c. Suppose c = id A. id A U s id A CS Lemma 2 U s Suppose c = G!. Then t = G! CS = id G CS ; G!, but that contradicts (s t ) = s t. Suppose c = G? p. Then t = G? p ; id G CS. With (s t ) = s t, we have s = (s t); G!. Then from U (s t); G! we have = V 2 G! with V 2 U s t for some V 2. So we obtain: G? p V 2 G! G? p U (s t); G! G? p ; id G CS Lemma 2 V 2 U s t Next suppose c = c 1 c 2, then c 1 c 2 is already a value. From U s and c CS = t we have c U s t by rule (ii). Suppose c = (c 1; c 2). We have t = c 1 CS c 2 CS. We obtain the following with two uses of the the inner induction hypothesis. c 1; c 2 U s t c 1 c 2 IH V 2 c 2 IH V 3 U s c 1 CS c 2 CS Suppose c = p A B. Then t = p A B and (s t ) = p B, but (s t ) = s t so we have a contradiction. V = U g; G!. Considering M U g; G!, only rule (ii) applies. Subcase (ii): IH IH M 1 U s c CS = t M 1 c U s t By the induction hypothesis, we have M 1 C and U s. We proceed by nested induction on c. Suppose c = id. id U s id CS U s Lemma 2 Suppose c = H!. Then we have H! U s H! CS. Suppose c = H? p. Then t = H? p CS = H? p ; id H CS. But that contradicts (s t) = (g; G!). Suppose c = c 1 c 2. Then t = c 1 c 2 CS = c 1 CS c 2 CS. But that contradicts (s t) = (g; G!).

11 Suppose c = (c 1; c 2). We use the same reasoning as for the corresponding case in V = U s t, that is, we obtain the following with two uses of the the inner induction hypothesis. c 1; c 2 c 1 c 2 IH V 2 c 2 IH V 3 U s t U s c 1 CS c 2 CS Suppose c = p A B. Then t = p A B and (s t ) = p B, but (s t ) = (g; G!) so we have a contradiction. Part 5 and 6. blame p blame p IH IH

12 C. Translation is bisimilar Here we sketch the proof of Proposition 17. Proposition 17. M M CS. Proof. (Sketch). By induction on M. The only non-trivial case is for M c where we need to apply rules (i) and (ii) to establish. In all other cases, the congruence rules are sufficient.

Geometric interpretation of signals: background

Geometric interpretation of signals: background Geometric interpretation of signals: background David G. Messerschmitt Electrical Engineering and Computer Sciences University of California at Berkeley Technical Report No. UCB/EECS-006-9 http://www.eecs.berkeley.edu/pubs/techrpts/006/eecs-006-9.html

More information

Blame for All. Amal Ahmed, Robert Bruce Findler, Jeremy Siek, Philip Wadler

Blame for All. Amal Ahmed, Robert Bruce Findler, Jeremy Siek, Philip Wadler Blame for All Amal Ahmed, Robert Bruce Findler, Jeremy Siek, Philip Wadler Vs. Part I The bit you know from before with a twist A simple untyped program let inc = λx. x + 1 in let app = λf. λx. f x in

More information

Optimality of an Algorithm Solving the Bottleneck Tower of Hanoi Problem

Optimality of an Algorithm Solving the Bottleneck Tower of Hanoi Problem 25 Optimality of an Algorithm Solving the Bottleneck Tower of Hanoi Problem YEFIM DINITZ AND SHAY SOLOMON Ben-Gurion University of the Negev Abstract. We study the Bottleneck Tower of Hanoi puzzle posed

More information

Blame, coercion, and threesomes: Together again for the first time

Blame, coercion, and threesomes: Together again for the first time Blame, coercion, and threesomes: Together again for the first time Draft, 19 October 2014 Jeremy Siek Indiana University jsiek@indiana.edu Peter Thiemann Universität Freiburg thiemann@informatik.uni-freiburg.de

More information

Total Ordering on Subgroups and Cosets

Total Ordering on Subgroups and Cosets Total Ordering on Subgroups and Cosets Alexander Hulpke Department of Mathematics Colorado State University 1874 Campus Delivery Fort Collins, CO 80523-1874 hulpke@math.colostate.edu Steve Linton Centre

More information

Threesomes, With and Without Blame

Threesomes, With and Without Blame hreesomes, With and Without Blame Jeremy G. Siek 1 and Philip Wadler 2 1 University of Colorado at Boulder 2 University of Edinburgh Abstract. he blame calculus of Wadler and Findler gives a high-level

More information

Maximum Achievable Gain of a Two Port Network

Maximum Achievable Gain of a Two Port Network Maximum Achievable Gain of a Two Port Network Ali Niknejad Siva Thyagarajan Electrical Engineering and Computer Sciences University of California at Berkeley Technical Report No. UCB/EECS-2016-15 http://www.eecs.berkeley.edu/pubs/techrpts/2016/eecs-2016-15.html

More information

Information Storage Capacity of Crossbar Switching Networks

Information Storage Capacity of Crossbar Switching Networks Information Storage Capacity of Crossbar Switching etworks ABSTRACT In this work we ask the fundamental uestion: How many bits of information can be stored in a crossbar switching network? The answer is

More information

Lecture Notes on Sequent Calculus

Lecture Notes on Sequent Calculus Lecture Notes on Sequent Calculus 15-816: Modal Logic Frank Pfenning Lecture 8 February 9, 2010 1 Introduction In this lecture we present the sequent calculus and its theory. The sequent calculus was originally

More information

Copyright 1972, by the author(s). All rights reserved.

Copyright 1972, by the author(s). All rights reserved. Copyright 1972, by the author(s). All rights reserved. Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are

More information

A Weak Post s Theorem and the Deduction Theorem Retold

A Weak Post s Theorem and the Deduction Theorem Retold Chapter I A Weak Post s Theorem and the Deduction Theorem Retold This note retells (1) A weak form of Post s theorem: If Γ is finite and Γ = taut A, then Γ A and derives as a corollary the Deduction Theorem:

More information

Parametric Polymorphism and Operational Improvement

Parametric Polymorphism and Operational Improvement Parametric Polymorphism and Operational Improvement JENNIFER HACKETT, University of Nottingham, UK GRAHAM HUTTON, University of Nottingham, UK Parametricity, in both operational and denotational forms,

More information

CS 436 HCI Technology Basic Electricity/Electronics Review

CS 436 HCI Technology Basic Electricity/Electronics Review CS 436 HCI Technology Basic Electricity/Electronics Review *Copyright 1997-2008, Perry R. Cook, Princeton University August 27, 2008 1 Basic Quantities and Units 1.1 Charge Number of electrons or units

More information

Adaptive Online Gradient Descent

Adaptive Online Gradient Descent University of Pennsylvania ScholarlyCommons Statistics Papers Wharton Faculty Research 6-4-2007 Adaptive Online Gradient Descent Peter Bartlett Elad Hazan Alexander Rakhlin University of Pennsylvania Follow

More information

Preliminary Results on Social Learning with Partial Observations

Preliminary Results on Social Learning with Partial Observations Preliminary Results on Social Learning with Partial Observations Ilan Lobel, Daron Acemoglu, Munther Dahleh and Asuman Ozdaglar ABSTRACT We study a model of social learning with partial observations from

More information

On the Impact of Objective Function Transformations on Evolutionary and Black-Box Algorithms

On the Impact of Objective Function Transformations on Evolutionary and Black-Box Algorithms On the Impact of Objective Function Transformations on Evolutionary and Black-Box Algorithms [Extended Abstract] Tobias Storch Department of Computer Science 2, University of Dortmund, 44221 Dortmund,

More information

Natural Deduction. Formal Methods in Verification of Computer Systems Jeremy Johnson

Natural Deduction. Formal Methods in Verification of Computer Systems Jeremy Johnson Natural Deduction Formal Methods in Verification of Computer Systems Jeremy Johnson Outline 1. An example 1. Validity by truth table 2. Validity by proof 2. What s a proof 1. Proof checker 3. Rules of

More information

Multiple Limit Cycles for Predator- Prey Models

Multiple Limit Cycles for Predator- Prey Models Multiple Limit Cycles for Predator- Prey Models Hofbauer, J. and So, J.W.H. IIASA Working Paper WP-89-069 September 1989 Hofbauer, J. and So, J.W.H. (1989) Multiple Limit Cycles for Predator-Prey Models.

More information

The natural numbers. Definition. Let X be any inductive set. We define the set of natural numbers as N = C(X).

The natural numbers. Definition. Let X be any inductive set. We define the set of natural numbers as N = C(X). The natural numbers As mentioned earlier in the course, the natural numbers can be constructed using the axioms of set theory. In this note we want to discuss the necessary details of this construction.

More information

Natural Deduction for Propositional Logic

Natural Deduction for Propositional Logic Natural Deduction for Propositional Logic Bow-Yaw Wang Institute of Information Science Academia Sinica, Taiwan September 10, 2018 Bow-Yaw Wang (Academia Sinica) Natural Deduction for Propositional Logic

More information

Complexity Tradeoffs for Read and Update Operations

Complexity Tradeoffs for Read and Update Operations Complexity Tradeoffs for Read and Update Operations Danny Hendler Department of Computer-Science Ben-Gurion University hendlerd@cs.bgu.ac.il Vitaly Khait Department of Computer-Science Ben-Gurion University

More information

Copyright 1996, by the author(s). All rights reserved.

Copyright 1996, by the author(s). All rights reserved. Copyright 1996, by the author(s). All rights reserved. Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are

More information

Electric-Energy Generation Using Variable-Capacitive Resonator for Power-Free LSI: Efficiency Analysis and Fundamental Experiment

Electric-Energy Generation Using Variable-Capacitive Resonator for Power-Free LSI: Efficiency Analysis and Fundamental Experiment Electric-Energy Generation Using Variable-Capacitive Resonator for Power-Free SI: Efficiency Analysis and Fundamental Experiment Masayuki Miyazaki, Hidetoshi Tanaka, Goichi Ono, Tomohiro Nagano*, Norio

More information

A Note on the Recursive Calculation of Incomplete Gamma Functions

A Note on the Recursive Calculation of Incomplete Gamma Functions A Note on the Recursive Calculation of Incomplete Gamma Functions WALTER GAUTSCHI Purdue University It is known that the recurrence relation for incomplete gamma functions a n, x, 0 a 1, n 0,1,2,..., when

More information

Stability Analysis of Predator- Prey Models via the Liapunov Method

Stability Analysis of Predator- Prey Models via the Liapunov Method Stability Analysis of Predator- Prey Models via the Liapunov Method Gatto, M. and Rinaldi, S. IIASA Research Memorandum October 1975 Gatto, M. and Rinaldi, S. (1975) Stability Analysis of Predator-Prey

More information

CS 6110 Lecture 28 Subtype Polymorphism 3 April 2013 Lecturer: Andrew Myers

CS 6110 Lecture 28 Subtype Polymorphism 3 April 2013 Lecturer: Andrew Myers CS 6110 Lecture 28 Subtype Polymorphism 3 April 2013 Lecturer: Andrew Myers 1 Introduction In this lecture, we make an attempt to extend the typed λ-calculus for it to support more advanced data structures

More information

Test Generation for Designs with Multiple Clocks

Test Generation for Designs with Multiple Clocks 39.1 Test Generation for Designs with Multiple Clocks Xijiang Lin and Rob Thompson Mentor Graphics Corp. 8005 SW Boeckman Rd. Wilsonville, OR 97070 Abstract To improve the system performance, designs with

More information

Lecture Notes on Cut Elimination

Lecture Notes on Cut Elimination Lecture Notes on Cut limination 15-816: Linear Logic Frank Pfenning Lecture 7 February 8, 2012 After presenting an interpretation of linear propositions in the sequent calculus as session types, we now

More information

10 Propositional logic

10 Propositional logic 10 The study of how the truth value of compound statements depends on those of simple statements. A reminder of truth-tables. and A B A B F T F F F F or A B A B T F T F T T F F F not A A T F F T material

More information

Propositional Language - Semantics

Propositional Language - Semantics Propositional Language - Semantics Lila Kari University of Waterloo Propositional Language - Semantics CS245, Logic and Computation 1 / 41 Syntax and semantics Syntax Semantics analyzes Form analyzes Meaning

More information

Compound Propositions

Compound Propositions Discrete Structures Compound Propositions Producing new propositions from existing propositions. Logical Operators or Connectives 1. Not 2. And 3. Or 4. Exclusive or 5. Implication 6. Biconditional Truth

More information

Strategies for Proofs

Strategies for Proofs G. Carl Evans University of Illinois Summer 2013 Today Practice with proofs Become familiar with various strategies for proofs Review: proving universal statements Claim: For any integer a, if a is odd,

More information

A Characterization of Regular Expressions under Bisimulation

A Characterization of Regular Expressions under Bisimulation A Characterization of Regular Expressions under Bisimulation J. C. M. BAETEN Technische Universiteit Eindhoven, Eindhoven, The Netherlands F. CORRADINI Università di Camerino, Camerino, Italy AND C. A.

More information

Implementing Memristor Based Chaotic Circuits

Implementing Memristor Based Chaotic Circuits Implementing Memristor Based Chaotic Circuits Bharathwaj Muthuswamy Electrical Engineering and Computer Sciences University of California at Berkeley Technical Report No. UCB/EECS-2009-156 http://www.eecs.berkeley.edu/pubs/techrpts/2009/eecs-2009-156.html

More information

Approximation Metrics for Discrete and Continuous Systems

Approximation Metrics for Discrete and Continuous Systems University of Pennsylvania ScholarlyCommons Departmental Papers (CIS) Department of Computer & Information Science May 2007 Approximation Metrics for Discrete Continuous Systems Antoine Girard University

More information

Trade Space Exploration with Ptolemy II

Trade Space Exploration with Ptolemy II Trade Space Exploration with Ptolemy II Shanna-Shaye Forbes Electrical Engineering and Computer Sciences University of California at Berkeley Technical Report No. UCB/EECS-2009-102 http://www.eecs.berkeley.edu/pubs/techrpts/2009/eecs-2009-102.html

More information

Online Appendix to The Recovery of a Schema Mapping: Bringing Exchanged Data Back

Online Appendix to The Recovery of a Schema Mapping: Bringing Exchanged Data Back Online Appendix to The Recovery of a Schema Mapping: Bringing Exchanged Data Back MARCELO ARENAS and JORGE PÉREZ Pontificia Universidad Católica de Chile and CRISTIAN RIVEROS R&M Tech Ingeniería y Servicios

More information

Sec$on Summary. Mathematical Proofs Forms of Theorems Trivial & Vacuous Proofs Direct Proofs Indirect Proofs

Sec$on Summary. Mathematical Proofs Forms of Theorems Trivial & Vacuous Proofs Direct Proofs Indirect Proofs Section 1.7 Sec$on Summary Mathematical Proofs Forms of Theorems Trivial & Vacuous Proofs Direct Proofs Indirect Proofs Proof of the Contrapositive Proof by Contradiction 2 Proofs of Mathema$cal Statements

More information

Thank you so much for your interest in The Measured Mom printables!

Thank you so much for your interest in The Measured Mom printables! Thank you so much for your interest in The Measured Mom printables! Uppercase Letters on Four Lines A-Z is for personal or classroom use. By using it, you agree that you will not copy, reproduce, or change

More information

Formulas for which Contraction is Admissible

Formulas for which Contraction is Admissible Formulas for which Contraction is Admissible ARNON AVRON, Department of Computer Science, School of Mathematical Sciences, Tel Aviv University, Tel Aviv 69978, Israel. E-mail: aa@math.tau.ac.il Abstract

More information

Lecture Notes on Classical Linear Logic

Lecture Notes on Classical Linear Logic Lecture Notes on Classical Linear Logic 15-816: Linear Logic Frank Pfenning Lecture 25 April 23, 2012 Originally, linear logic was conceived by Girard [Gir87] as a classical system, with one-sided sequents,

More information

Congruence of Bisimulation in a Non-Deterministic Call-By-Need Lambda Calculus

Congruence of Bisimulation in a Non-Deterministic Call-By-Need Lambda Calculus Congruence of Bisimulation in a Non-Deterministic Call-By-Need Lambda Calculus Matthias Mann Johann Wolfgang Goethe-Universität, Frankfurt, Germany Congruence of Bisimulation p. 1/21 Lambda Calculi and

More information

1. Propositions: Contrapositives and Converses

1. Propositions: Contrapositives and Converses Preliminaries 1 1. Propositions: Contrapositives and Converses Given two propositions P and Q, the statement If P, then Q is interpreted as the statement that if the proposition P is true, then the statement

More information

Midterm 1. Your Exam Room: Name of Person Sitting on Your Left: Name of Person Sitting on Your Right: Name of Person Sitting in Front of You:

Midterm 1. Your Exam Room: Name of Person Sitting on Your Left: Name of Person Sitting on Your Right: Name of Person Sitting in Front of You: CS70 Discrete Mathematics and Probability Theory, Fall 2018 Midterm 1 8:00-10:00pm, 24 September Your First Name: SIGN Your Name: Your Last Name: Your Exam Room: Name of Person Sitting on Your Left: Name

More information

Laver Tables A Direct Approach

Laver Tables A Direct Approach Laver Tables A Direct Approach Aurel Tell Adler June 6, 016 Contents 1 Introduction 3 Introduction to Laver Tables 4.1 Basic Definitions............................... 4. Simple Facts.................................

More information

University of Illinois at Chicago Department of Computer Science. Final Examination. CS 151 Mathematical Foundations of Computer Science Fall 2012

University of Illinois at Chicago Department of Computer Science. Final Examination. CS 151 Mathematical Foundations of Computer Science Fall 2012 University of Illinois at Chicago Department of Computer Science Final Examination CS 151 Mathematical Foundations of Computer Science Fall 01 Thursday, October 18, 01 Name: Email: Print your name and

More information

Overview. I Review of natural deduction. I Soundness and completeness. I Semantics of propositional formulas. I Soundness proof. I Completeness proof.

Overview. I Review of natural deduction. I Soundness and completeness. I Semantics of propositional formulas. I Soundness proof. I Completeness proof. Overview I Review of natural deduction. I Soundness and completeness. I Semantics of propositional formulas. I Soundness proof. I Completeness proof. Propositional formulas Grammar: ::= p j (:) j ( ^ )

More information

Copyright 1965, by the author(s). All rights reserved.

Copyright 1965, by the author(s). All rights reserved. Copyright 1965, by the author(s). All rights reserved. Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are

More information

Sums of Squares. Bianca Homberg and Minna Liu

Sums of Squares. Bianca Homberg and Minna Liu Sums of Squares Bianca Homberg and Minna Liu June 24, 2010 Abstract For our exploration topic, we researched the sums of squares. Certain properties of numbers that can be written as the sum of two squares

More information

Copyright 1966, by the author(s). All rights reserved.

Copyright 1966, by the author(s). All rights reserved. Copyright 1966, by the author(s). All rights reserved. Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are

More information

On the Complexity of Optimal K-Anonymity

On the Complexity of Optimal K-Anonymity On the Complexity of Optimal K-Anonymity Adam Meyerson Department of Computer Science University of California Los Angeles, CA awm@cs.ucla.edu Ryan Williams Computer Science Department Carnegie Mellon

More information

Ackermann s Function

Ackermann s Function Ackermann s Function George Tourlakis February 18, 2008 1 What The Ackermann function was proposed, naturally, by Ackermann. The version here is a simplification offered by Robert Ritchie. What the function

More information

Weights in Stable Marriage Problems Increase Manipulation Opportunities

Weights in Stable Marriage Problems Increase Manipulation Opportunities Weights in Stable Marriage Problems Increase Manipulation Opportunities Maria Silvia Pini mpini@math.unipd.it Francesca Rossi frossi@math.unipd.it Toby Walsh NICTA and UNSW Sydney, Australia toby.walsh@nicta.com.au

More information

Mathematical Logic (IX)

Mathematical Logic (IX) Mathematical Logic (IX) Yijia Chen 1. The Löwenheim-Skolem Theorem and the Compactness Theorem Using the term-interpretation, it is routine to verify: Theorem 1.1 (Löwenheim-Skolem). Let Φ L S be at most

More information

Blame and Coercion: Together Again for the First Time

Blame and Coercion: Together Again for the First Time Blame and Coercion: Together Again for the First Time Jeremy Siek Indiana University, USA jsiek@indiana.edu Peter Thiemann Universität Freiburg, Germany thiemann@informatik.uni-freiburg.de Phili Wadler

More information

A non-classical refinement of the interpolation property for classical propositional logic

A non-classical refinement of the interpolation property for classical propositional logic Accepted for publication in Logique & Analyse A non-classical refinement of the interpolation property for classical propositional logic Peter Milne Abstract We refine the interpolation property of the

More information

Confusion of Memory. Lawrence S. Moss. Department of Mathematics Indiana University Bloomington, IN USA February 14, 2008

Confusion of Memory. Lawrence S. Moss. Department of Mathematics Indiana University Bloomington, IN USA February 14, 2008 Confusion of Memory Lawrence S. Moss Department of Mathematics Indiana University Bloomington, IN 47405 USA February 14, 2008 Abstract It is a truism that for a machine to have a useful access to memory

More information

The following techniques for methods of proofs are discussed in our text: - Vacuous proof - Trivial proof

The following techniques for methods of proofs are discussed in our text: - Vacuous proof - Trivial proof Ch. 1.6 Introduction to Proofs The following techniques for methods of proofs are discussed in our text - Vacuous proof - Trivial proof - Direct proof - Indirect proof (our book calls this by contraposition)

More information

Correspondence between Kripke Structures and Labeled Transition Systems for Model Minimization

Correspondence between Kripke Structures and Labeled Transition Systems for Model Minimization Correspondence between Kripke Structures and Labeled Transition Systems for Model Minimization Rob Schoren Abstract This document is mainly an extension of the work of Michel Reniers and Tim Willemse,

More information

Some Applications of Logic to Feasibility in Higher Types

Some Applications of Logic to Feasibility in Higher Types Some Applications of Logic to Feasibility in Higher Types ALEKSANDAR IGNJATOVIC and ARUN SHARMA The University of New South Wales While it is commonly accepted that computability on a Turing machine in

More information

Foundations of Programming Languages and Software Engineering

Foundations of Programming Languages and Software Engineering Foundations of Programming Languages and Software Engineering Jan-Georg Smaus (Peter Thiemann) Universität Freiburg July 2011 Abstract Data Types Foundations of Programming Languages and Software Engineering

More information

Copyright 1984, by the author(s). All rights reserved.

Copyright 1984, by the author(s). All rights reserved. Copyright 1984, by the author(s). All rights reserved. Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are

More information

The min cost flow problem Course notes for Search and Optimization Spring 2004

The min cost flow problem Course notes for Search and Optimization Spring 2004 The min cost flow problem Course notes for Search and Optimization Spring 2004 Peter Bro Miltersen February 20, 2004 Version 1.3 1 Definition of the min cost flow problem We shall consider a generalization

More information

Simulating a Fountain

Simulating a Fountain Simulating a Fountain 209 Simulating a Fountain Lyric P. Doshi Joseph Edgar Gonzalez Philip B. Kidd Maggie L. Walker Governor s School for Government and International Studies Richmond, VA Advisor: John

More information

Basic Problems in Multi-View Modeling

Basic Problems in Multi-View Modeling Basic Problems in Multi-View Modeling Jan Reineke Stavros Tripakis Electrical Engineering and Computer Sciences University of California at Berkeley Technical Report No. UCB/EECS-2014-4 http://www.eecs.berkeley.edu/pubs/techrpts/2014/eecs-2014-4.html

More information

Craig Interpolation Theorem for L!1! (or L!! )

Craig Interpolation Theorem for L!1! (or L!! ) Craig Interpolation Theorem for L!1! (or L!! ) Theorem We assume that L 1 and L 2 are vocabularies. Suppose =!, where is an L 1 -sentence and is an L 2 -sentence of L!!. Then there is an L 1 \ L 2 -sentence

More information

Fermat's Little Theorem

Fermat's Little Theorem Fermat's Little Theorem CS 2800: Discrete Structures, Spring 2015 Sid Chaudhuri Not to be confused with... Fermat's Last Theorem: x n + y n = z n has no integer solution for n > 2 Recap: Modular Arithmetic

More information

CS 151 Complexity Theory Spring Solution Set 5

CS 151 Complexity Theory Spring Solution Set 5 CS 151 Complexity Theory Spring 2017 Solution Set 5 Posted: May 17 Chris Umans 1. We are given a Boolean circuit C on n variables x 1, x 2,..., x n with m, and gates. Our 3-CNF formula will have m auxiliary

More information

On the Standardization Theorem for λβη-calculus

On the Standardization Theorem for λβη-calculus On the Standardization Theorem for λβη-calculus Ryo Kashima Department of Mathematical and Computing Sciences Tokyo Institute of Technology Ookayama, Meguro, Tokyo 152-8552, Japan. e-mail: kashima@is.titech.ac.jp

More information

Feasibility-Preserving Crossover for Maximum k-coverage Problem

Feasibility-Preserving Crossover for Maximum k-coverage Problem Feasibility-Preserving Crossover for Maximum -Coverage Problem Yourim Yoon School of Computer Science & Engineering Seoul National University Sillim-dong, Gwana-gu Seoul, 151-744, Korea yryoon@soar.snu.ac.r

More information

Landscapes and Other Art Forms.

Landscapes and Other Art Forms. Landscapes and Other Art Forms. Darrell Whitley Computer Science, Colorado State University Permission to make digital or hard copies of part or all of this work for personal or classroom use is granted

More information

Statistics on Data Streams

Statistics on Data Streams Statistics on Data Streams T. H. Merrett McGill University March 6, 8 This is taken from [SZ4, Chap. 5]. It is the first of three applications they develop based on their review of timeseries techniques

More information

Source Code Metrics for Programmable Logic Controller (PLC) Ladder Diagram (LD) Visual Programming Language

Source Code Metrics for Programmable Logic Controller (PLC) Ladder Diagram (LD) Visual Programming Language Source Code Metrics for Programmable Logic Controller (PLC) Ladder Diagram (LD) Visual Programming Language Lov Kumar lov.kumar@in.abb.com Raoul Jetley raoul.jetley@in.abb.com ABB Corporate Research Center

More information

Effectiveness of Reverse Body Bias for Leakage Control in Scaled Dual Vt CMOS ICs

Effectiveness of Reverse Body Bias for Leakage Control in Scaled Dual Vt CMOS ICs Effectiveness of Reverse Body Bias for Leakage Control in Scaled Dual Vt CMOS ICs A. Keshavarzi, S. Ma, S. Narendra, B. Bloechel, K. Mistry*, T. Ghani*, S. Borkar and V. De Microprocessor Research Labs,

More information

Algorithm 808: ARfit A Matlab package for the estimation of parameters and eigenmodes of multivariate autoregressive models

Algorithm 808: ARfit A Matlab package for the estimation of parameters and eigenmodes of multivariate autoregressive models Algorithm 808: ARfit A Matlab package for the estimation of parameters and eigenmodes of multivariate autoregressive models TAPIO SCHNEIDER New York University and ARNOLD NEUMAIER Universität Wien ARfit

More information

Integer Least Squares: Sphere Decoding and the LLL Algorithm

Integer Least Squares: Sphere Decoding and the LLL Algorithm Integer Least Squares: Sphere Decoding and the LLL Algorithm Sanzheng Qiao Department of Computing and Software McMaster University 28 Main St. West Hamilton Ontario L8S 4L7 Canada. ABSTRACT This paper

More information

CSCI.6962/4962 Software Verification Fundamental Proof Methods in Computer Science (Arkoudas and Musser) Chapter p. 1/33

CSCI.6962/4962 Software Verification Fundamental Proof Methods in Computer Science (Arkoudas and Musser) Chapter p. 1/33 CSCI.6962/4962 Software Verification Fundamental Proof Methods in Computer Science (Arkoudas and Musser) Chapter 4.1-4.8 p. 1/33 CSCI.6962/4962 Software Verification Fundamental Proof Methods in Computer

More information

Bisimulation for conditional modalities

Bisimulation for conditional modalities Bisimulation for conditional modalities Alexandru Baltag and Giovanni Ciná Institute for Logic, Language and Computation, University of Amsterdam March 21, 2016 Abstract We give a general definition of

More information

CS 70 Discrete Mathematics and Probability Theory Fall 2016 Seshia and Walrand Midterm 1 Solutions

CS 70 Discrete Mathematics and Probability Theory Fall 2016 Seshia and Walrand Midterm 1 Solutions CS 70 Discrete Mathematics and Probability Theory Fall 2016 Seshia and Walrand Midterm 1 Solutions PRINT Your Name: Answer: Oski Bear SIGN Your Name: PRINT Your Student ID: CIRCLE your exam room: Dwinelle

More information

Group-Contribution Estimation of the Critical Properties of Hydrocarbons

Group-Contribution Estimation of the Critical Properties of Hydrocarbons Oil & Gas Science and Technology Rev. IFP, Vol. 62 (2007), No. 3, pp. 391-398 Copyright 2007, Institut français du pétrole DOI: 10.2516/ogst:2007031 Group-Contribution Estimation of the Critical Properties

More information

CSE 311: Foundations of Computing I Autumn 2014 Practice Final: Section X. Closed book, closed notes, no cell phones, no calculators.

CSE 311: Foundations of Computing I Autumn 2014 Practice Final: Section X. Closed book, closed notes, no cell phones, no calculators. CSE 311: Foundations of Computing I Autumn 014 Practice Final: Section X YY ZZ Name: UW ID: Instructions: Closed book, closed notes, no cell phones, no calculators. You have 110 minutes to complete the

More information

Strong Normalization with Singleton Types

Strong Normalization with Singleton Types Electronic Notes in Theoretical Computer Science 70 No 1 (2002) URL: http://wwwelseviernl/locate/entcs/volume70html 19 pages Strong Normalization with Singleton Types Judicaël Courant 1 LRI, CNRS UMR 8623

More information

Polynomial-Time Perfect Matchings in Dense Hypergraphs

Polynomial-Time Perfect Matchings in Dense Hypergraphs Polynomial-Time Perfect Matchings in Dense Hypergraphs Peter Keevash School of Mathematical Sciences, Queen Mary, University of London London E 4NS United Kingdom p.keevash@qmul.ac.uk Fiachra Knox School

More information

Chapter 3 Deterministic planning

Chapter 3 Deterministic planning Chapter 3 Deterministic planning In this chapter we describe a number of algorithms for solving the historically most important and most basic type of planning problem. Two rather strong simplifying assumptions

More information

Extensional Equivalence and Singleton Types

Extensional Equivalence and Singleton Types Extensional Equivalence and Singleton Types CHRISTOPHER A. STONE Harvey Mudd College and ROBERT HARPER Carnegie Mellon University We study the λ S calculus, which contains singleton types S(M ) classifying

More information

Reducing Delay Uncertainty in Deeply Scaled Integrated Circuits Using Interdependent Timing Constraints

Reducing Delay Uncertainty in Deeply Scaled Integrated Circuits Using Interdependent Timing Constraints Reducing Delay Uncertainty in Deeply Scaled Integrated Circuits Using Interdependent Timing Constraints Emre Salman and Eby G. Friedman Department of Electrical and Computer Engineering University of Rochester

More information

Interpolation in Logics with Constructors

Interpolation in Logics with Constructors Interpolation in Logics with Constructors Daniel Găină Japan Advanced Institute of Science and Technology School of Information Science Abstract We present a generic method for establishing the interpolation

More information

Probabilistic Bisimilarity as Testing Equivalence

Probabilistic Bisimilarity as Testing Equivalence Probabilistic Bisimilarity as Testing Equivalence Yuxin Deng a,, Yuan Feng b a Shanghai Key Laboratory of Trustworthy Computing, MOE International Joint Lab of Trustworthy Software, and International Research

More information

Complete Induction and the Well- Ordering Principle

Complete Induction and the Well- Ordering Principle Complete Induction and the Well- Ordering Principle Complete Induction as a Rule of Inference In mathematical proofs, complete induction (PCI) is a rule of inference of the form P (a) P (a + 1) P (b) k

More information

A The equivalence of the torus and the product of two circles in homotopy type theory

A The equivalence of the torus and the product of two circles in homotopy type theory A The equivalence of the torus and the product of two circles in homotopy type theory KRISTINA SOJAKOVA, Carnegie Mellon University Homotopy type theory is a new branch of mathematics which merges insights

More information

Finding Telescopers with Minimal Depth for Indefinite Nested Sum and Product Expressions

Finding Telescopers with Minimal Depth for Indefinite Nested Sum and Product Expressions Finding Telescopers with Minimal Depth for Indefinite Nested Sum and Product Expressions Carsten Schneider Research Institute for Symbolic Computation J. Kepler University, A-4040 Linz, Austria Carsten.Schneider@risc.uni-linz.ac.at

More information

The min cost flow problem Course notes for Optimization Spring 2007

The min cost flow problem Course notes for Optimization Spring 2007 The min cost flow problem Course notes for Optimization Spring 2007 Peter Bro Miltersen February 7, 2007 Version 3.0 1 Definition of the min cost flow problem We shall consider a generalization of the

More information

Randomized Truthful Auctions of Digital Goods are Randomizations over Truthful Auctions

Randomized Truthful Auctions of Digital Goods are Randomizations over Truthful Auctions Randomized Truthful Auctions of Digital Goods are Randomizations over Truthful Auctions Aranyak ehta Georgia Institute of Technology 802, Atlantic Dr. Atlanta, USA aranyak@cc.gatech.edu Vijay V. Vazirani

More information

There are seven questions, of varying point-value. Each question is worth the indicated number of points.

There are seven questions, of varying point-value. Each question is worth the indicated number of points. Final Exam MAT 200 Solution Guide There are seven questions, of varying point-value. Each question is worth the indicated number of points. 1. (15 points) If X is uncountable and A X is countable, prove

More information

CIS 500 Software Foundations Fall October. Review. Administrivia. Subtyping

CIS 500 Software Foundations Fall October. Review. Administrivia. Subtyping CIS 500 Software Foundations Fall 2002 Administrivia Prof. Pierce out of town Nov. 5 14 No office hours Nov 5, 7, 12, or 14 Next Wednesday: guest lecturer (on Chapter 16) Following Monday: review session

More information

What is Logic? Introduction to Logic. Simple Statements. Which one is statement?

What is Logic? Introduction to Logic. Simple Statements. Which one is statement? What is Logic? Introduction to Logic Peter Lo Logic is the study of reasoning It is specifically concerned with whether reasoning is correct Logic is also known as Propositional Calculus CS218 Peter Lo

More information

CS154 Final Examination

CS154 Final Examination CS154 Final Examination June 7, 2010, 7-10PM Directions: CS154 students: answer all 13 questions on this paper. Those taking CS154N should answer only questions 8-13. The total number of points on this

More information

Induction on Failing Derivations

Induction on Failing Derivations Induction on Failing Derivations Technical Report PL-Sep13 September 2013, with addenda from Spring 2016 ay Ligatti Department of Computer Science and Engineering University of South Florida Abstract A

More information

Solving Satisfiability and Implication Problems in Database Systems

Solving Satisfiability and Implication Problems in Database Systems Solving Satisfiability and Implication Problems in Database Systems SHA GUO, WEI SUN, and MARK A. WEISS Florida International University Satisfiability, implication, and equivalence problems involving

More information

VAN DER WAERDEN S THEOREM.

VAN DER WAERDEN S THEOREM. VAN DER WAERDEN S THEOREM. REU SUMMER 2005 An arithmetic progression (AP) of length k is a set of the form A = {a, a+d,..., a+(k 1)d} which we ll also denote by A = a+[0, k 1]d. A basic result due to Van

More information