a java implementation of peirce’s existential graphs bram van heuveln dennis higgins faculty...
TRANSCRIPT
A Java implementation of Peirce’s Existential Graphs
Bram van Heuveln
Dennis Higgins
faculty advisors
Elizabeth Hatfield, Debbie Kilpatrick, Lut Wong
student programmers
Overview
• Background and Motivation
• Problem Specification
• Design Choices
• Current State and Future Developments
• Demonstration!
Background and motivation
Peirce’s Existential Graphs• A graphical logic system
– system to symbolize and infer statements
• 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 restrictive, involved, and unintuitive.
– Existential Graphs allow the user to express logical statements in a completely graphical way.
Background and motivation
Syntax of EG
‘P’
‘not P’
‘P and Q’
‘P or Q’
‘if P then Q’
Traditional EG
P P
~P, P’
P&Q, P*Q, PQ
P|Q, P+Q, PQ
PQ, P Q
P
Q
QP
P
QP
Background and motivation
Inference Rules of EGDouble Cut
(De)Iteration
Erasure
Insertion
P P
QPQ
QP
QP
P
Q
PP
Background and motivation
Example
Prove:(AB) C~C~B
Traditional (Fitch) EG
(A B) C
~C
B
A B
C
~C
~B
A.
A.
A.
3 I
1,4 E
2 R
3-6 ~I
BA
BA
C
C
C
A
B
CB
DE
DC
E
1.
2.
3.
4.
5.
6.
7.
Background and motivation
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
Background and 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 excited at the idea of having an interactive interface
Background and motivation
Further Motivation for the Project• 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
Problem Specification
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
Problem Specification
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
Problem Specification
Data StructureWanted! A data structure that is able to:• represent the abstract logical structure of an
Existential Graph,• store geometrical information of the actual size
and location of graph components, and• facilitate manipulations of the abstract logical
structure as well as of the geometrical information, thus forming some kind of interface between these two
Design Choices
Preliminary Decisions• The GUI will have two distinct parts:
– Work Area• place where the user has full editing capabilities to generate
individual Existential Graphs
– Proof Area• place where the user places finished Existential Graphs and
manipulates them conforming to the legal rules of inference
• A nested linked list data structure will be used– Abstract logical relationships represented by nesting
– Specific graphical information stored in each element
Design Choices
Project PhasingWe decided to implement in two phases:
• Phase one: develop an interface for the Work Area– Requires interface with full editing capabilities
– Requires data structure with full representation and manipulation capabilities
• Phase two: provide an interface for the Proof Area– After Phase 1, this should be a piece of cake!
Design Choices
Task Divisions• Debbie and Elizabeth: Interface lay-out design
– Frames, Panels, Buttons, etc.
• Elizabeth: Manipulation of Propositions– Add, move, and delete using keyboard and mouse
• Lut: Manipulation of Cuts– Move and resize using mouse
• Dennis: Data Structure• Bram: File I/O
Design Choices
JTreeDennis found a Java foundation class JTree, which
can be used for the nested structure– The Sheet of Assertion (SA) is the root of the Jtree,
children of the SA are the graphs that are ‘on’ the SA, children of these children are graphs at level 1, etc. Propositions form the leafs of the Jtree
– JTree supports various useful operations such as getting a node’s children, finding a parent for a given child, finding a path from the root to a node, etc.
– JTree has a built-in interface to display itself.
Design Choices
NodeGuyThe JTree nodes can hold user data. We made the
class NodeGuy which gets put into every JTree node. NodeGuy represents either a cut or a proposition, and contains the geometric information of this item.
This fairly simple class thus provides a go-between for the JTree and the Work Area. Each of these major classes can access and update NodeGuy information, and use it to display the expression in the proper way.
Current State and Future Developments
Phase 1: Work Area
The Work Area is as good as completed:• Our current program supports drawing, moving,
copying, and deleting propositions and cuts. Cuts can also be resized.
• The data structure gets correctly updated in accordance with the changes in graphical information and logical relationships.
Current State and Future Developments
Phase 2: Proof AreaThe Proof Area shouldn’t take too much time:• Move graphs from Work Area to Proof Area• Double Cut: Similar to adding/deleting cut• Iteration: Copy• Deiteration: Needs equivalence test• Erasure: Delete group• Insertion: Make graph in Work Area and move
to Proof Area