1 What are Bit Strings? The View from Process Nick Rossiter Northumbria University.

Slides:



Advertisements
Similar presentations
CS2303-THEORY OF COMPUTATION Closure Properties of Regular Languages
Advertisements

Chapter 2 Revision of Mathematical Notations and Techniques
Chapter 1 Review In Algebra, we use symbols to stand for various numbers. One type of symbol used is a variable. An expression that contains at least one.
Four-level Architecture for Closure in Interoperability EFIS, 17th-18th July 2003 Nick Rossiter & Michael Heather Informatics, Northumbria University
Introduction The concept of transform appears often in the literature of image processing and data compression. Indeed a suitable discrete representation.
Language and Automata Theory
Cryptography and Network Security
COMP-421 Compiler Design Presented by Dr Ioanna Dionysiou.
Adjoint Typing: Is it Whitehead’s Category of the Ultimate?
Discrete Mathematics Lecture 5 Alexander Bukharovich New York University.
Number Theory and Cryptography
Copyright © Cengage Learning. All rights reserved. CHAPTER 1 SPEAKING MATHEMATICALLY SPEAKING MATHEMATICALLY.
CS2210(22C:19) Discrete Structures Relations Spring 2015 Sukumar Ghosh.
Traced Premonoidal Categories Nick Benton Microsoft Research Martin Hyland University of Cambridge.
1 Introduction to Computability Theory Lecture4: Regular Expressions Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture3: Regular Expressions Prof. Amos Israeli.
Introduction to Computability Theory
1 Introduction to Computability Theory Lecture7: PushDown Automata (Part 1) Prof. Amos Israeli.
1 Section 10.1 Boolean Functions. 2 Computers & Boolean Algebra Circuits in computers have inputs whose values are either 0 or 1 Mathematician George.
Theory and Applications
1 Category Theory in a ( E,M ) -category Some aspects of category theory, in particular related to universality, can be developed in any finitely complete.
Basic Concepts of Algebra
Category Theory By: Ashley Reynolds. HISTORY OF CATEGORY THEORY  In 1942–45, Samuel Eilenberg and Saunders Mac Lane introduced categories, functors,
Lecture 21: Languages and Grammars. Natural Language vs. Formal Language.
12 April 2009Instructor: Tasneem Darwish1 University of Palestine Faculty of Applied Engineering and Urban Planning Software Engineering Department Formal.
Regular Expressions. Notation to specify a language –Declarative –Sort of like a programming language. Fundamental in some languages like perl and applications.
Lecture Two: Formal Languages Formal Languages, Lecture 2, slide 1 Amjad Ali.
Theory of Computation, Feodor F. Dragan, Kent State University 1 Regular expressions: definition An algebraic equivalent to finite automata. We can build.
© Kenneth C. Louden, Chapter 11 - Functional Programming, Part III: Theory Programming Languages: Principles and Practice, 2nd Ed. Kenneth C. Louden.
Symposium 2: Applied Mathematics, Dynamical Systems, Logics and Category Theory CASYS’11 - International Conference on COMPUTING ANTICIPATORY SYSTEMS HEC.
Categories and Computer Science
Grammars CPSC 5135.
A Holistic Security Architecture for Distributed Information Systems – A Categorical Approach.
CIS552Relational Model1 Structure of Relational Database Relational Algebra Extended Relational-Algebra-Operations Modification of the Database.
Introduction to Graph Grammars Fulvio D’Antonio LEKS, IASI-CNR Rome,
Data Security and Encryption (CSE348) 1. Lecture # 12 2.
Products and Sums
1 The Contravariancy of Anticipatory Systems Dimitrios Sisiaridis, Michael Heather & Nick Rossiter Northumbria University, Newcastle NE2 1XE, UK Symposium.
Chapter 5 – Relations and Functions. 5.1Cartesian Products and Relations Definition 5.1: For sets A, B  U, the Cartesian product, or cross product, of.
21st May 2004Informatics Research Conference, Northumbria University 1 Some Fundamental Questions in Databases Nick Rossiter (with Michael Heather)
The Representation of Reality in Computational Form Nick Rossiter Visiting Fellow with Michael Heather and Dimitrios Sisiaridis Computing, Engineering.
© Kenneth C. Louden, Chapter 11 - Functional Programming, Part III: Theory Programming Languages: Principles and Practice, 2nd Ed. Kenneth C. Louden.
Lecture 2: Introduction to Category Theory Nick Rossiter, Computing Science, Newcastle University, England
Relations and their Properties
1 Typing in Information Systems Nick Rossiter, Michael Heather Computer Science and Digital Technologies Northumbria University, Newcastle NE1 8ST, UK.
The theory behind Functional Programming Functional: based on lambda calculus / combinators, recursion theory, category theory. By contrast with other.
1Computer Sciences Department. Book: INTRODUCTION TO THE THEORY OF COMPUTATION, SECOND EDITION, by: MICHAEL SIPSER Reference 3Computer Sciences Department.
Free and Open Systems Theory Nick Rossiter Michael Heather University of Northumbria
Donghyun (David) Kim Department of Mathematics and Physics North Carolina Central University 1 Chapter 0 Introduction Some slides are in courtesy of Prof.
Set Theory Concepts Set – A collection of “elements” (objects, members) denoted by upper case letters A, B, etc. elements are lower case brackets are used.
SECTION 2 BINARY OPERATIONS Definition: A binary operation  on a set S is a function mapping S X S into S. For each (a, b)  S X S, we will denote the.
A function is a rule f that associates with each element in a set A one and only one element in a set B. If f associates the element b with the element.
Module #3 - Sets 3/2/2016(c) , Michael P. Frank 2. Sets and Set Operations.
The Natural Metaphysics of Computing Anticipatory Systems Michael Heather Nick Rossiter University of Northumbria
1 Introduction to the Theory of Computation Regular Expressions.
Chapter 2 1. Chapter Summary Sets (This Slide) The Language of Sets - Sec 2.1 – Lecture 8 Set Operations and Set Identities - Sec 2.2 – Lecture 9 Functions.
Chapter 2 1. Chapter Summary Sets The Language of Sets - Sec 2.1 – Lecture 8 Set Operations and Set Identities - Sec 2.2 – Lecture 9 Functions and sequences.
WOSC 2008 Wroclaw1 Problems of Interoperability in Information Systems Nick Rossiter and Michael Heather CEIS, Northumbria University, UK
Basic Rules Of ALGEBRA.
Formal Language Theory
CS2210 Discrete Structures Relations
Copyright © Cengage Learning. All rights reserved.
Conditions for Interoperability
Copyright © Cengage Learning. All rights reserved.
The Process Semantics of Time and Space as Anticipation
Process in the World as a Transaction
Cryptography Lecture 19.
12 Chapter Chapter 2 Exponential and Logarithmic Functions.
Presentation transcript:

1 What are Bit Strings? The View from Process Nick Rossiter Northumbria University

2 Outline Process as a Monad/Comonad Underpinning by Cartesian Closed Category –Adjointness –Composition –Product/Exponentiation –Finite products Generation of Strings –Kleisli Category –Free Monoids

3 Current State of Play Process –Viewed as monad/comonad –Three cycles in each direction: One reflective – monad Other anticipatory – comonad –Handles transaction concept In databases (ACID) In universe

4 Example of Adjointness LR F G Endofunctor T = GF If conditions hold, then we can write F ┤ G The adjunction is represented by a 4-tuple: η and ε are unit and counit respectively

5

6 Cartesian Closed Category (CCC) Underpins applied category theory Basis of many fundamental structures in applications –Partial order –Boolean/Heyting algebras –Pullbacks/ Pushouts –Scott domains Also emerges in lambda calculus In computing functions become first-class data –Functional programming languages –Database design (normalisation)

7 Definition of CCC paraphrased CCC-1 There is a terminal object 1 CCC-2 Each pair of objects has a product with projections CCC-3 There is only one path between the product and the related objects.

8 In more detail: CCC-1 For every object A in the category, there is exactly one arrow A  Τ - Τ is the terminal object Category is closed on top Τ

9 CCC-2 Each pair of objects A and B of the category has a product A Χ B with projections π l : A Χ B  A π r : A Χ B  B Category has products and projections –Giving route to relationships

10 CCC-3a Notion of currying: change function on two variables to a function on one variable For function f: C X A  B Let [A  B] be set of functions from A to B Then there is a function: λf: C  [A  B] where λf(c) is the function whose value at an element a ε A is f(c,a)  Equivalent to typed lambda calculus  Examples: f : multiply(_,2)  R curries to λf: double(_)  R f : exponentiate(_,2)  R curries to λf : square(_)  R

11 CCC-3b For every pair of objects A and B, there is an object [A  B] and an arrow eval: [A  B] Χ A  B with the property that for any arrow f: C X A  B( C is product object) there is a unique arrow λf: C  [A  B] such that the following diagram commutes:

12 CCC-3c B C X A f eval λf X A [A  B] X A [A  B] is termed B A : all arrows from A to B, A is the exponent of B One path from product

13 Uniqueness The category is CCC if (other conditions satisfied) and : –λf is unique (one path) Notes –eval is also a function –eval: [A  B]  B refers to one A object and its associated B object -- eval: [A  B] X A  B refers to all A objects and their associated B objects

14 Finite Products CCC is not restricted to binary products Can have finite products For any objects A 1, …, A n and A of a CCC and any i=1,…,n, there is an object [A i  A] and an arrow: eval : [A i  A] X A i  A such that for any f: Π A k  A, there is a unique arrow: λ i f : Π A k  [A i  A] (k > 1) Finite products give construction of n-tuples which can represent strings. Note: this notation may offend Gödel’s theorems!

15 Abstract View of CCC An adjoint relationship –F ┤ G –Free functor F creates binary products –Underlying functor G checks for exponentials (one path)

16 Adjoints Left adjoint -- free functor on category C: _ X A: C  C For fixed object A and an object B, this gives binary product B X A and an arrow: f x id A : B X A  C X A Right adjoint – underlying functor G on value of object C on right-hand side: –Unique arrow λf : B  G(C) such that eval o (λf X A) = g Adjointness requires both left and right adjoints to exist

17 Composition for there to be a Right Adjoint C B X A g eval λf X A G(C) X A One path from product

18 Compositions for Adjointness with unit/counit Unit of adjunction η Counit of adjunction ε ε is eval _XA(G(C)) is GCXA _XA(B) is BXA _XA(f) is Fλf A G(_XA(A)) GC η f Gg _XA(G(C)) C _XA(B) g _XA(f) ε

19 Locally CCC Satisfied when: –The category C has pullbacks and either: The pullback functor has a right adjoint OR For every object A in C, the slice category C/A is cartesian closed Pullbacks express relationships over objects in a particular context Locally CCC provide more expressiveness in capturing the real world

20 Product vs Pullback A X B A B πlπl πrπr Product and projections A X C B A B πlπl πrπr C Pullback of A and B in the context of C

21 Kleisli Category Free algebra Based on monad earlier T = –where T is endofunctor GF for adjoint functors F ┤G –η is unit of adjunction η : 1 A  GFA –μ is multiplicationμ : GFGF  GF compares results of 2nd and 1st cycles –T is a category –A is an object in left-hand category

22 Kleisli Category 2 In Kleisli category –T = –The arrows are substitutions –μ can be thought of as carrying out a computation For arrow f : A  B –then A  TB –where T defines the substitutions as functions

23 Kleisli example For f : A  TB A = {g,h} and B = {i,j,k} f(g) = cddc, f(h) = ec Tf: TA  TTB TA is for example string ‘ghhg’ TTB is (cddc), (ec), (ec), (cddc) (concatenations) μ : TT  T is ‘cddcececcddc’  ‘ghhg’ In the comonad: δ : T  TT is ‘ghhg’  ‘cddcececcddc’ So we have string generation through substitution

24 Kleene Closure Given a set A: –The Kleene closure A* of a set A is defined as the set of strings of finite length of elements of A In adjointness terms: F : A  A* G : A*  A The closure is then GFA F is the free functor, adding structure G is the underlying functor, removing structure

25 Example A = {a, b, c, d, …., z}(alphabet) F(A) = A* = all finite strings constructed from A by F G(A*) returns the alphabet The closure relies on adjointness –F can be free and open (all possibilities) –G can check for language rules

26 Example 2 The adjoint (if it exists) is –F constructs all possibilities –G applies the language rules –η defines the change from A  GFA in the alphabet –ε defines the change from FGA*  A* in the language

27 Summary Category Theory provides a number of routes for generating strings: –n-tuples through cartesian closed categories –String expansion through substitution as in Kleisli categories –String generation through free functors as in the Kleene closure