# A Language for Mathematical Knowledge Management - Andrew Cmu

Διαχείριση

6 Νοε 2013 (πριν από 4 χρόνια και 11 μήνες)

140 εμφανίσεις

A Language for Mathematical
Knowledge Management

Steve Kieffer

Carnegie Mellon
University

2

What is Mathematical Knowledge?

Theorems

Definitions

Proofs

3

How do we “manage” it?

Experts

Books

Wikipedia?

4

Idea for MKM: Encyclopedia
Entries, Stored in Computers

5

How
transparent

is the entry,
to the
computer
?

6

What do we want to
do

with
mathematical knowledge?

Learn it

Study its history

Formally verify it

Study its logical structure

...

7

My Work

1. Parser

2. Database of definitions

3. Translator

4. Statistics on logical structure

5. GUI for concept exploration

8

Choice of Language

9

Choice of Language

10

Mizar

11

LPT

Designed by Friedman

Adds nice features to language of set theory

12

Terms in LPT

Ordered tuples
:

13

Terms in LPT

Function evaluation
:

14

Terms in LPT

Infix functions
:

15

Terms in LPT

Sets
:

16

Terms in LPT

Descriptions
:

17

Terms in LPT

Lambda

abstraction
:

18

Formulas in LPT

Predication
:

19

Formulas in LPT

Infix relations
:

20

Formulas in LPT

Quantifiers
:

21

R

is a partial order on
A

22

R

is a partial order on
A

23

What is parsing?

(
a

a
)

a

E

T

F

a

(

)

T

F

E

T

E

a

F

a

T

F

[[[
(
[[[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[[[
(
[[
[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[[[
(
[
[[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[[[
(
[
[[
a
]
F
]
T

[[
[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[[[
(
[
[[
a
]
F
]
T

[
[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[[[
(
[
[[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[[[
(
[[[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[[
[
(
[[[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[[
[
(
[[[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[
[
a
]
F
]
T
]
T
]
E

[[
[
(
[[[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[
[[
(
[[[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

[[[
(
[[[
a
]
F
]
T

[[[
a
]
F
]
T
]
E
]
E
)
]
F

[[
a
]
F
]
T
]
T
]
E

E

T

F

a

(

)

T

F

E

T

E

a

F

a

T

F

[

]

[

]

[

]

[

]

[

]

[

]

[

]

[

]

[

]

var

var

var

var

var

var

var

rel’n

]

[

formula

[

]

tuple

[

]

formula

[

]

term

formula

FCN [
f
]

f

= { <
x
,
y
> :
f
(
x
) =
y

}

26

Parsing method

Earley algorithm

n
3

runtime

parses any
context free grammar

Simple example

E

T

E

E

T

T

F

T

T

F

F

(
E
)

F

a

Grammar:

Input:

(

a

a

)

a

E

T

F

T

F

a

(

)

E

T

E

T

F

a

F

a

Earley algorithm

E

T

E

E

T

T

F

T

T

F

F

(
E
)

F

a

Grammar:

Input:

(

a

a

)

a

I
0

[E

T

E, 0]

[E

T, 0]

[T

F

T, 0]

[T

F, 0]

[F

(E), 0]

[F

a, 0]

I
1

[F

(

E), 0]

[E

T

E, 1]

[E

T, 1]

[T

F

T, 1]

[T

F, 1]

[F

(E), 1]

[F

a, 1]

I
2

[F

a

, 1]

[T

F

T, 1]

[T

F

, 1]

[E

T

E, 1]

[E

T

, 1]

[F

(E

), 0]

I
3

[E

T

E, 1]

[E

T

E, 3]

[E

T, 3]

[T

F

T, 3]

[T

F, 3]

[F

(E), 3]

[F

a, 3]

I
4

[F

a

, 3]

[T

F

T, 3]

[T

F

, 3]

[E

T

E, 3]

[E

T

, 3]

[E

T

E

, 1]

[F

(E

), 0]

I
5

[F

(E)

, 0]

[T

F

T, 0]

[T

F

, 0]

[E

T

E, 0]

[E

T

, 0]

I
6

[T

F

T, 0]

[T

F

T, 6]

[T

F, 6]

[F

(E), 6]

[F

a, 6]

I
7

[F

a

, 6]

[T

F

T, 6]

[T

F

, 6]

[T

F

T

, 0]

[E

T

E, 0]

[E

T

, 0]

(1)

(2)

(3)

(4)

(5)

(6)

I
7

[F

a

, 6]

[T

F

T, 6]

[T

F

, 6]

[T

F

T

, 0]

[E

T

E, 0]

[E

T

, 0]

6464215643
2

I
7

[F

a

, 6]

[T

F

T, 6]

[T

F

, 6]

[T

F

T

, 0]

[E

T

E, 0]

[E

T

, 0]

646421564
32

I
7

[F

a

, 6]

[T

F

T, 6]

[T

F

, 6]

[T

F

T

, 0]

[E

T

E, 0]

[E

T

, 0]

64642156
432

I
7

[F

a

, 6]

[T

F

T, 6]

[T

F

, 6]

[T

F

T

, 0]

[E

T

E, 0]

[E

T

, 0]

6464215
6432

I
5

[F

(E)

, 0]

[T

F

T, 0]

[T

F

, 0]

[E

T

E, 0]

[E

T

, 0]

646421
56432

I
4

[F

a

, 3]

[T

F

T, 3]

[T

F

, 3]

[E

T

E, 3]

[E

T

, 3]

[E

T

E

, 1]

[F

(E

), 0]

64642
156432

I
4

[F

a

, 3]

[T

F

T, 3]

[T

F

, 3]

[E

T

E, 3]

[E

T

, 3]

[E

T

E

, 1]

[F

(E

), 0]

6464
2156432

646
42156432

I
4

[F

a

, 3]

[T

F

T, 3]

[T

F

, 3]

[E

T

E, 3]

[E

T

, 3]

[E

T

E

, 1]

[F

(E

), 0]

64
642156432

I
4

[F

a

, 3]

[T

F

T, 3]

[T

F

, 3]

[E

T

E, 3]

[E

T

, 3]

[E

T

E

, 1]

[F

(E

), 0]

6
4642156432

I
2

[F

a

, 1]

[T

F

T, 1]

[T

F

, 1]

[E

T

E, 1]

[E

T

, 1]

[F

(E

), 0]

64642156432

I
2

[F

a

, 1]

[T

F

T, 1]

[T

F

, 1]

[E

T

E, 1]

[E

T

, 1]

[F

(E

), 0]

29

My Work

1. Parser

2. Database of definitions

3. Translator

4. Statistics on logical structure

5. GUI for concept exploration

30

Translation

LPT as language for proof system?

Set up translation to make database useable.

Database has set
-
theoretic foundational
definitions (e.g. von Neumann ordinals).

Translate into DZFC (“Definitional ZFC”), a
conservative extension of ZFC.

31

Comparison: LPT vs. DZFC

32

Comparison: LPT vs. DZFC

33

Comparison: LPT vs. DZFC

34

My Work

1. Parser

2. Database of definitions

3. Translator

4. Statistics on logical structure

5. GUI for concept exploration

35

Directed Acyclic Graph (DAG) of
Conceptual Dependencies

Depth: 4

Size: 5

36

DAG data

Max
Mean
Depth
32
10.77
Size
110
29.56
DAG depths
0
5
10
15
20
25
30
35
40
0
5
10
15
20
25
30
35
Depth
Frequency
DAG depths
38

Quantifier depth: alternating or
non
-
alternating

39

Expanding formulas

Definitional axiom for PORD in DZFC:

To expand, locate the definiens for each defined concept

appearing above.

:

:

:

Then plug in.

Definiens for PORD:

40

Expanding formulas

The result:

41

Three expansion levels

1. No expansion

2. Total expansion

3. Partial

lowest foundational concepts left
unexpanded

42

Eight data points

LPT

unexpanded DZFC

fully expanded DZFC

partially expanded DZFC

alt. LPT

alt. unexpanded DZFC

alt. fully expanded DZFC

alt. partially expanded DZFC

43

Quantifier depth data

Max
Mean
LPT
4
0.66
unexpanded DZFC
5
1.31
fully expanded DZFC
1235
78.68
partially expanded DZFC
552
38.54
alt. LPT
3
0.63
alt. unexpanded DZFC
5
1.18
alt. fully expanded DZFC
422
36.19
alt.partially expanded DZFC
239
22.16
44

Quantifier depth data

Depth
LPT
alt. LPT
0
178
178
1
118
120
2
30
35
3
14
8
4
1
0
Occurrences
(out of 341 definitions)

45

My Work

1. Parser

2. Database of definitions

3. Translator

4. Statistics on logical structure

5. GUI for concept exploration

46

Summary

1. Parser

2. Database of definitions

3. Translator

4. Statistics on logical structure

5. GUI for concept exploration