Center for AeroSpace. Information. (CASI). 800 Elkridge. Landing. Road. Linthicum. Heights,. MD 21090-2934. (301). 621-0390. National. Technical. Information.
NASA
/ TM-1998-206923
A PVS Graph Ricky
W.
Langley A
Air
Force
National
Library
Butler Research
Jon
Theory
Center,
Hampton,
Virginia
Sjogren Office
Aeronautics
of Scientific
and
Space Administration Langley Research Center Hampton, Virginia 23681-2199
February
1998
Research,
Washington,
DC
Available
from the following:
NASA Center for AeroSpace 800 Elkridge Landing Road Linthicum Heights, (301) 621-0390
Information
MD 21090-2934
(CASI)
National 5285 Port
Technical Royal
Information
Road
Springfield, VA 22161-2171 (703) 487-4650
Service
(NTIS)
Abstract This
pal)or
documents
the NASA
Langley
PVS graph
theory
library.
provides fimdanmntal definitions fi)r graphs, subgraphs, walks, paths, ated by walks, trees, cycles, degree, separating sets, aim four notions Theorems notiolis
provided include connectedness.
of
Ramsey's
and
Menger's
and
The
library
subgraphs gen(wof commcl_,dness.
tim equivalence
of all fimr
Contents 2
1
Introduction
2
Definition
3
Graph
Operations
5
4
Graph
Degree
6
5
Subgraphs
6
Walks
7
Connected
8
Circuits
14
9
Trees
15
2
of a Graph
7 and
8
Paths
13
Graphs
10 Ramsey's
Theorem
15
11 Menger's
Theorem
16
12 PVS
18
Theories
13 Concluding A
20
Remarks
APPENDIX:
Other
A.1
Gral)h
Inductions
A.2
Subgrat)hs
A.3 A.4
Maximmn Minimmn
A.5
Abstra(:t
Supporting
Theories
2O
.................................
G(_nerated
From
Walks
........................
Sul)grat)hs ............................... Walks .................................. Min an(t
Max
Thoori(_s
2O
.........................
21 21 22 23
1
Introduction
This the
paper
(l 0
connected?(del_vert(G,v)))
size(G)
bool
= NOT empty?(G) AND (FORALL (x,y: (vert(G))): (EXISTS (w: Walk(G)):
seq(w)(0)
= x AND
seq(w)(l(w)-l)
piece_connected?(G):
bool
= NOT empty?(G) AND (FORALL HI,H2: G = union(HI,H2) NOT IMPLIES
complected?(G):
l)rovides
path_connected,
bool
N0T
empty?(Hl)
AND
AND N0T
(x:
empty?(H2)
empty?(intersection(vert(Hl), vert(H2))))
= IF isolated?(G) THEN singleton?(G) ELSIF (EXISTS (v: (vert(G))): deg(v,G) (EXISTS
= y))
(vert(G))):
deg(x,G)
= i) THEN
= 1 AND
connected?(del_vert(G,x))) ELSE (EXISTS
(e: (edges(G))):
connected?(del_edge(G,e))) ENDIF
These
definitions
equivaleilce
aro
graph_connected[T:
are located
located in the
in the theory
graph_conn_defs graph_connected:
TYPE] : THEORY
13
theory.
The
following
lemmas
about
BEGIN
G:
VAR graph[T]
conn_eq_path
:THEOREM
8
= path_connected?(G)
path_eq_piece:
THEOREM
path_connected?(G)
piece_eq_conn:
THEOREM
piece_connected?(G)
conn_eq_complected:
END
connected?(G)
THEOREM
= piece_connected?(G)
= connected?(G)
connected?(G)
= complected?(G)
graph_connected
Circuits
A slightly
non-traditional
in tile same
place
(i.e.
definition
of circuit
a pre_circuit)
an(l
is used. is cyclically
reducible?(G: graph[T], w: Seq(G)): bool l(w) - 1 AND w(k-l) = w(k+l))
reduced?(G:
graph[T],
w:
cyclically_reduced?(G: reduced?(G,w)
pre_circuit?(G:
Seq(G)):
graph[T], AND w(1)
graph[T],
A circuit
bool
w:
=
reduced
(i.e.
(EXISTS
= NOT
Seq(G)):
graph[T],
that
starts
and
ends
cyclically_reduced?).
(k: posnat):
k
2 AND
/= w(l(w)-2)
w: prewalk):
bool
= walk?(G,w) w(0)
circuitT(G:
is a walk
w: Seq(G)):
bool
AND
= w(l(w)-l)
= walk?(G,w)
AND
cyclically_reduced?(G,w)
AND
pre_circuit?(G,w)
Tile
following cir_deg_G
prol)erties
are
: LEMMA
proved (EXISTS
in the
circuit_deg
(a,b:
(vert(G))):
a /= b AND deg(z,G)
circuit_deg
: LEMMA
FORALL
theory:
edge?(G)(a,z) >=
below(l(w))):
deg(w(i),G
14
AND
AND
edge?(G)(b,z)
2
(w: Walk(G),i: IMPLIES
vert(G)(z)
circuit?(G,w)
from(G,w))
>= 2
) IMPLIES
9
Trees
Trees
are
defin(,(I
G: VAR
r(,('ursiv(qy
as
follows:
graph[T]
tree?(G):
RECURSIVE
bool
= card [T] (vert (G) ) =
(EXISTS MEASURE
and
the
Tree
Tree:
type
TYPE
(v: (vert(G))): tree? (del_vert
size(G)
is defined
as follows:
= {G: graph[T]
I tree?(G)}
Theflmdammltall)ropertythattre(,s tree_no_circuits:
havenocircuitsist)rovt,din
THEOREM
(FDRALL
(w: N0T
10
Ramsey's
This
work
entitled Basin
builds "The
and
i, j: VAR n, p, q,
Walk(G)):
tree_circ
tree?(G)
=>
circuit?(G,w))
upon
a w_rification Prover
Kauflnann
of this and
theorem
Nuprl:
by
An
Natarajan
Experimental
Shankar Comt)arison"
2.
T ii: VAR
nat
g: VAR graph[T] G: VAR Graph[T] V: VAR
% nonempty
finite_set[T]
contains_clique(g, n): bool = (EXISTS (C: finite_set[T]): subset?(C,vert(g)) (FORALL
i,]:
i/=]
AND AND
card(C) C(i)
>= n AND AND
C(j)
contains_indep(g, n): bool = (EXISTS (D: finite_set[T]): "CLI
Technical
theory.
Theorem
Boycr-Moore
Matt
I 0R deg(v,G) = I AND [T] (G, v) ) )
1Report 58, .luly 17, 1990. 15
IMPLIES
edge?(g)(i,j)))
and
the
paper
by
David
subset?(D, (FORALL
vert(g)) i, j:
subgraph_clique:
AND
i/=j
card(D)
AND D(i)
(FORALL
LEMMA
>= n AND
AND
D(j)
IMPLIES
N0T
IMPLIES : LEMMA
(FORALL
contains_clique(g,
IMPLIES THEOREM
(EXISTS
contains_indep(g,
(G: Graph[T]):
IMPLIES
To
Menger's state
menger's
COml)licated G:
theoreln
one
We
size(G)
>= n
(contains_clique(G,
Ii)
contains_indep(G,
12))))
OR
graph[T]
=
first
define
begin
with
minimum the
(_oncept
separating
sets.
of a set)arating
This
is fairh"
set:
graph[T] VAR
e:
VAR
doubleton[T]
V:
VAR
finite_set[T]
T
del_verts(G,V): (# vert
:= difference[T](vert(G),V),
edges
:= {e
separates(G,V,s,t):
bool N0T
minimuln
nmst
system.
v,s,t:
In other
p))
Theorem
in a formal
VAR
p)
V),
(n: posnat):
(FORALL
11
p)
V), p))
(V: set[T]):
contains_indep(subgraph(g,
ramseys_theorem:
j)))
(V: set[T]):
contains_clique(subgraph(g,
subgraph_indep
edge?(g)(i,
words
theory.
The
(lesired
properties
net
result
min_sep_set(G,s,t):
v:
= N0T
V(s)
s and
(w:
we end
t when up
finite_set[T]
V(v)
AND
IMPLIES
N0T
prewalk):
set, we use an abstract is that
AND
(FDRALL
(EXISTS
V separates
separating
I edges(G)(e)
e(v))}
#)
AND
walk_from?(del_verts(G,V),w,s,t))
its removal minimum
with
V(t)
N0T
disconnects function
a function
s and
defined
min_sep_set
t.
in the with
(v:
(LAMBDA
(v: seps(G,s,t)):
16
seps(G,s,t)):
card(v)), true)]
the
abstract_min
all of the
= min[seps(G,s,t), (LAMBDA
To define
following
separable?(G,s,t):
bool
= (s /= t AND
min_sep_set_edge:
LEMMA
NOT
min_sep_set_card:
LEMMA
FORALL
NOT
separable?(G,s,t) IMPLIES min sep_set(G,s,t) = vert(G)
(s,t:
(vert(G))):
IMPLIES
min_sep_set_seps:
LEMMA
edge?(G)(s,t))
separates(G,V,s,t)
card(min_sep_set(G,s,t))
separable?(G,s,t)
IMPLIES
separates(G,min_sep
min_sep_set_vert:
LEMMA
separable?(G,s,t) IMPLIES
ends_not_in_min_sep_set:
\%'(, t,hen
Noxt,
w( _ define
nat
a prrdicato
independent?(wl,w2:
AND min_sep_set(G,s,t)(v) vert(G)(v)
separable?(G,s,t) AND min_sep_set(G, IMPLIES v /= s AND v /= t
independent? prewalk):
that
bool
(tofin(,s
of a set
(i,j: nat):
of ind(_t)(ul(hult
set_of_paths(G,s,t):
TYPE
ind_path_set?(G,s,t,(pset:
t)aths
i < l(wl)
- I AND
j > 0 AND
j < l(w2)
- I IMPLIES
/= seq(w2)(]))
is (h'fine(l
as follows:
(pl,p2:
in(h,t)('n(lent. easy_menger:
a set
\V(, can LEMMA
of paths now stat(, FORALL
is an
AND pset(p2)
ind_path_set?
M(ulg(w's (ips:
bool
tlmor(un
AND
pl
if all
in I)oth
pairs
0 AND
set_of_paths(G,s,t))):
(FORALL
In
wlmn
=
seq(wl)(i)
('on(:et)t
s, t)(v)
= card(min_sep_set(G,s,t))
(FORALL
The
set(G,s,t),s,t)
as f'olhnv,_:
(|(,fine sep_num
sep_num(G,s,t):
LEMMA
Max
1)o instantiated
T : TYPE size:
and
c()ntexts.
sul)grat)h that
t h('ori(_s min_walks
that
ill many
theories
in the
need
it is us('ful ways
that
satisfies
a t)arti('ular
a minimal
walk
to d(weh)l)
abstract
t() 1)rovid(_
(tifferent
flom inin
bv
()l).j(_('t for
flm('tion that
ol)j('('t
whi('h
t)y whi(:h the
rain
a min flmction
ol)jects flm(;tion
are
compared
must
hay('
abstract_min[T:
TYPE,
size:
[T -> nat],
P: pred[T]]:
abstract_max[T:
TYPE,
size:
[T -> nat] , P: pred[T]]
THEORY
alia
23
: THEORY
satis[v
is ime(t('d
s t() t rain
and
and lnaX
To simplify
the
detail.
abstract_max
The
In order exists
that
following
discussion, theory
for a minimum satisfies
the
tile
abstract_rain
is conceptually
only
identical.
function
property.
Thus,
to t)e defined, the
theory
theory
it is necessary contains
will be elat)orated that
at least
the following
one
assuming
in
ol)ject claus(,
ASSUMING T_ne: ASSUMPTION EXISTS
(t: T): P(t)
ENDASSUMING User's of this theory are required to prove that PVS's TCC generatioll mechanism). A flmction minimal? (S : T) is then (lefined minimal?(S):
this
assunlption
hol(ts
for their
tyl)e
T (via
as follows:
bool = P(S) AND (FORALL (SS: T): P(SS) IMPLIES size(S)