a java implementation of peirce’s existential graphs* faculty advisors: bram van heuveln...

22
A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student programmers: Elizabeth Hatfield, Debbie Kilpatrick, Lut Wong

Upload: kerry-carson

Post on 05-Jan-2016

217 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

A Java implementation of Peirce’s Existential Graphs*

faculty advisors:

Bram van Heuveln (Philosophy)

Dennis Higgins (Math & Computer Science)

student programmers:

Elizabeth Hatfield, Debbie Kilpatrick, Lut Wong

*Funding made possible by a TLTC Fast Tech Grant

Page 2: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Overview

• Background: Logic Systems

• Peirce’s Existential Graphs

• Our Project and its Motivation

• Implementation

• Demonstration!

Page 3: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Logic Systems

A Logic Puzzle• The body of Mr. X was found murdered in his

bedroom by the housemaid. Who did it?• Inspector Clouseau collects the following

information:– Only the butler and the housemaid could have had

access to Mr. X’s bedroom

– Only the butler knows about the secret alarm that Mr.X activates at night in his bedroom

– The alarm did not go off.

Page 4: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Logic Systems

Our Reasoning• “Either the butler or the housemaid killed

Mr. Body. However, if the housemaid would have killed Mr. Body, the alarm would have gone off, and the alarm didn’t go off, so the housemaid is in the clear. Therefore, the butler did it.”

• Can we formalize our reasoning? Yes. This is what logic systems do.

Page 5: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Logic Systems

Step 1: Logical Symbolization• Use symbols to represent simple propositions:

– H: The housemaid did it

– B: The butler did it

– A: The alarm went off

• Use further symbols to represent complex claims:– H B: The housemaid or the butler did it

– HA: If the housemaid did it, the alarm would go off

– ~A: The alarm did not go off

Page 6: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Logic Systems

Step 2: Logical Inference• Transform symbolic representations using

basic rules that reflect valid inferences:

H B

HA

~A

~H

B

2, 3 MT

A.

A.

A.

5.

4.

3.

2.

1.

1, 4 DS

Page 7: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Logic Systems

Completeness and Soundness• Logic Systems need to be complete and sound:

– Expressive Completeness: The system needs to be able to represent every possible logical expression.

– Deductive Completeness: The system needs to be able to infer anything that logically follows.

– Deductive Soundness: The system should not be able to infer anything that does not logically follow.

• Logic Systems can be proven to be complete and sound.

Page 8: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Logic Systems

The Trade-off• The rules in logic systems reflect simple logical

inferences. The simpler the inferences, the fewer rules the system will have to have in order to be complete, as more complex rules will reduce to sequences of more simple rules. However, this also means that the proof becomes longer. In other words, there is a trade-off between the number of rules of the system and the length of the proof.

Page 9: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Logic Systems

Example of the Trade-offH B

HA

~A

H

A

A.

A.

A.

A.

5.

4.

3.

2.

1.

2,4 E

6.

7.

~A

~H

3 R

4-6 ~I

8.

9.

13.

12.

11.

10.

B

B

H

~B

H

~H

B

B

14.

15.

A.

A.

A.

10 R

7 R

8 R

1,8-9,10-14 E

11-13 ~E

24 rules: 2 steps11 rules: 12 steps

Page 10: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Existential Graphs

Peirce’s Existential Graphs• A graphical logic system developed by Peirce

almost 100 years ago.• Peirce studied semiotics: the relationship between

symbols, meanings, and users. – Peirce found the linear notation and accompanying

rules of traditional logic systems (which he helped develop) restrictive, involved, and unintuitive.

– Existential Graphs allow the user to express logical statements in a completely graphical way.

Page 11: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Existential Graphs

Syntax of EG

‘P’

‘not P’

‘P and Q’

‘P or Q’

‘if P then Q’

Traditional EG

P P

~P

P&Q

PQ

PQ

P

Q

QP

P

QP

Page 12: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Existential Graphs

Inference Rules of EGDouble Cut

(De)Iteration

Erasure

Insertion

P P

QPQ

QP

QP

P

Q

PP

Page 13: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Existential Graphs

Proof in EGA

B

DE

DCE

BH AH

ABH

H AB

DE

H

H AB

Page 14: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Existential Graphs

Strength of EG• Compact

– Only Propositions and Cuts; Only 4 rules

• Easy to use– Less chance of making mistakes

• Fast– Transform rather than rewrite

• Intuitive– Many logical relationships come for free

• Maximum Logical Power– Expressively complete; deductively complete

Page 15: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Motivation

Initial Student ResponseBram has taught Existential Graphs in logic class:• Even though students were forced to draw

successive snapshots, students were more happy with Existential Graphs than traditional systems:– easier– faster– less mistakes– more fun

• Students were very excited at the idea of having an interactive interface

Page 16: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Motivation

Further Motivation• Interface for construction and manipulation of

Existential Graphs does not seem to exist• Conceptual advantages of the dynamic character of

logic proofs in EG remain unexplored• Software can be used in logic class• Implementation in Java, so that an applet can be put

on a home page for public use• Good experience

– Completed project can be presented at conference– Nice example of cross-curricular collaboration

Page 17: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

The Project

Required Functionality• The user should be able to:

– Generate Existential Graphs• Draw, delete, move, resize, and copy propositions and cuts

– Manipulate Existential Graphs• Apply rules of inference

• The system should:– Keep track of the logical relationships as expressed by

the Existential Graphs

– Check if the rules of inference are correctly applied by the user

Page 18: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

The Project

Desired added Functionality• File I/O

– To load and save existential graphs

– To load and save proofs as a series of images

• Proof Editor– Video buttons to play and rewind proofs

– Edit existing proofs

• Help and Tutorial– Instructions for use

– Examples

Page 19: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Implementation

Programming Team• We obtained a TLTC Fast Tech Grant• We invited three upper division Computer

Science students to develop this software:– Elizabeth Hatfield (now at IBM, Endicott)– Debbie Kilpatrick (working for Computer

Services, SUNY Oneonta)– Lut Wong (senior, CS and Chemistry major)

• We held a weekly meeting

Page 20: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Implementation

Division of Labor

E lizab e th H atfie ldp rog ram m er

w in d ow s ,icon s

D eb b ie K ilp a tric kp rog ram m er

w in d ow s ,m a in

L u t W on gp rog ram m er

g rap h ica l rep resen ta tionan d m an ip u la tion

D en n is H ig g in s , B ram van H eu ve lnsu p erviso rs

D en n is w orked on d a ta s tru c tu resB ram w orked on file I/O an d log ica l asp ec ts

Page 21: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Implementation

Project PhasingWe decided to implement in two phases:• Phase one: develop a Work Area

– Interface with full editing capabilities for generating Existential Graphs

– Main problem: interaction between graphical operations and corresponding internal logical data structure

• Phase two: develop a Proof Area– Interface for the manipulation of Existential Graphs– Main Problem: Perform checking to insure user

selections were legal

Page 22: A Java implementation of Peirce’s Existential Graphs* faculty advisors: Bram van Heuveln (Philosophy) Dennis Higgins (Math & Computer Science) student

Implementation

Current Status• Both phases are now complete, and we have

a minimally working system.

• Additional helpful features still need to be implemented

• On to the demonstration!