A Java implementation of Peirces Existential Graphs

Document Sample
A Java implementation of Peirces Existential Graphs Powered By Docstoc
					A Java Implementation of
Peirce’s Existential Graphs

        Bram van Heuveln
     Department of Philosophy
State University College at Oneonta

           March 22, 2001
 Background: Logic Systems
 Peirce’s Existential Graphs
 The Project

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
     Only the butler and the housemaid have a key
     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.
Logic Systems

Our Reasoning
  “Either the butler or the housemaid killed
  Mr. X. However, if the housemaid killed
  Mr. X, 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.
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
    HA: If the housemaid did it, the alarm would
    go off
    ~A: The alarm did not go off
 Logic Systems

 Step 2: Logical Inference
   Transform symbolic representations using
   basic rules that reflect valid inferences:

1. H  B         Assumption (A.)
2. HA           A.
3. ~A            A.
4. ~H            2, 3 MT
5. B             1, 4 DS
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
    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
  Logic Systems can be proven to be complete and
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 proofs get longer. In other words,
  there is a trade-off between the number of rules in
  the system and the length of a given proof.
 Logic Systems

 Example of the Trade-off
1. H  B         A.       10.    H          A.
2. HA           A.       11.     ~B        A.
3. ~A            A.       12.     H         10 R
4.   H           A.     13.       ~H        7R
5.   A           2,4 E 14.      B          11-13 ~E
6.   ~A          3R       15. B             1,8-9,10-14 E
7. ~H            4-6 ~I
8.   B           A.             24 rules: 2 steps
9.   B           8R             11 rules: 12 steps
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) involved and
     Existential Graphs allow the user to express
     logical statements in a completely graphical
Existential Graphs

Syntax of EG
                     Traditional   EG

     ‘P’                 P             P
   ‘not P’              ~P             P

  ‘P and Q’            P&Q         P       Q

   ‘P or Q’            PQ         P       Q

 ‘if P then Q’         PQ         P       Q
Existential Graphs

Inference Rules of EG
Double Cut                   P           P

(De)Iteration        P           Q   P       P   Q

Erasure                  P       Q       P

Insertion                        Q       P       Q
Existential Graphs

Proof in EG
 H B           H A        A

 H B           H          A

     B         H          A
     B         H          A   E   B
Existential Graphs

Strength of EG
     Only Propositions and Cuts; Only 4 rules
  Easy to use
     Less chance of making mistakes
     Transform rather than rewrite
     Many logical relationships come for free
  Maximum Logical Power
     Expressively complete; deductively complete
Existential Graphs

Student Response
Personal experience from teaching Existential
  Graphs in logic class:
  Even though students were forced to draw
  successive snapshots, students were more happy
  with Existential Graphs than traditional systems:
     less mistakes
     more fun
  Students were very excited at the idea of having
  an interactive interface
The Project

  EG presents an interesting alternative to traditional
  Interface for construction and manipulation of
  Existential Graphs can be used in logic class
  Software does not seem to exist
  Conceptual advantages of the dynamic character
  of logic proofs in EG remain unexplored
  Nice example of cross-curricular collaboration
  Nice example of integrating technology into the
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
The Project

Desired Additional 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
The Project

The Project Team
     Bram van Heuveln (Philosophy)
     Dennis Higgins (Math and Computer Science)
  We obtained a TLTC Fast Tech Grant
  We invited three upper division Computer Science
  students to develop this software:
     Elizabeth Hatfield
     Debbie Kilpatrick
     Lut Wong
  We held weekly meetings to discuss progress
The Project

Division of Labor

                    Dennis Higgins, Bram van Heuveln
                     Dennis worked on data structures
                 Bram worked on file I/O and logical aspects

  Elizabeth Hatfield          Debbie Kilpatrick             Lut Wong
     programmer                 programmer                programmer
      windows,                   windows,            graphical representation
        icons                      main                 and manipulation
  The Project

  Project Phasing
We decided to implement in two phases:
 Phase one: develop a Work Area
   Interface with full editing capabilities for generating
   and editing Existential Graphs
   Main problem: Correspondence between graphical
   operations and 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 are legal
The Project

Current Status
  Both phases are now complete, and we have
  a minimally working system
  Additional helpful features still need to be

Shared By: