2
5
r
e
v
i
s
i
o
n
:
1
9
9
4

1
1

1
2
m
o
d
i
f
i
e
d
:
1
9
9
4

1
1

1
3
McColms Conjecture
Yuri Gurevich
Neil Immerman
Saharon Shelah
,
and (FO+LFP) are recalled
in the next section.
Clearly, M1 implies M2. McColm observed that M3
implies M1. Phokion Kolaitis and Moshe Vardi proved
that M1 implies M3 [KV]. A nice exposition of all of
,
, see Corollary 3.10
and Theorem 4.1. We present the deterministic con
struction in full detail in Section 3. The randomized
construction is presented in Section 4; but, some of
the proofs are omitted due to lack of space.
Both constructions depend on the fact that the lan
guage L
,
, and thus (FO+LFP) is unable to count
the number of vertices in a large clique. The determin
istic construction extends naturally to Theorem 3.13:
an extension of our counterexample to the stronger
language (FO+LFP+COUNT) in which counting is
present.
Recall that (FO + ITER), is rstorder logic plus
an unbounded iteration operator (equivalent to the
while, and partial xed point operators). It
is known that the language (FO + ITER) captures
PSPACE on ordered structures [I82, V]. Abiteboul
and Vianu [AV] showed that P = PSPACE if and only
if, (FO + LFP) = (FO + ITER) on all sets of nite
structures.
In light of this, another interesting consequence of
the deterministic construction is Corollary 3.14 which
says that if P is not equal to PSPACE, then there is
a set of nite structures on which FO = (FO+ LFP),
5
2
5
r
e
v
i
s
i
o
n
:
1
9
9
4

1
1

1
2
m
o
d
i
f
i
e
d
:
1
9
9
4

1
1

1
3
but on which FO ,= (FO + ITER).
2 Background
We briey recall some background material. More
information on Descriptive Complexity and Finite
Model Theory can be found for example in [I89] and
[G].
Proviso Structures are nite. Vocabularies are 
nite and do not contain function symbols of positive
arity. In particular, the vocabulary of any L
,

formula is nite. Classes of structures are closed under
isomorphism. 2
If M is a structure then [M[ is the universe of M.
If X is a nonempty subset of M (that is, of [M[) then
M [ X is the induced substructure with universe X.
An rary global relation on a class K of struc
tures of the same vocabulary is a function that, given
a structure M K, produces an rary (local) relation
M
on [M[. By denition, M [= ( a) if and only if
a
M
. It is supposed that, for every isomorphism
from M to a structure N and every rtuple x
1
, . . . , x
r
of elements of M, M [= (x
1
, . . . , x
r
) N [=
((x
1
, . . . , x
r
)).
In this paper, an innitary formula means an L
,
formula of nite vocabulary. Recall that L
,
is the
generalization of rstorder logic that allows arbitrary
innite conjunctions and disjunctions provided that
the total number of individual variables, bound or free,
in the resulting formula is nite [B]. In other words,
innitary formulas are built from atomic formulas by
means of negation, existential quantication, universal
quantication and the following rule:
If
i
[ i I is a collection of inni
tary formulas that uses only a nite vocabulary
and a nite number of individual variables then
_
i
i
and
_
i
i
are innitary formulas.
The semantics is obvious. A [=
_
i
i
( a) if and only
if A [=
i
( a) for some i, and A [=
_
i
i
( a) if and
only if A [=
i
( a) for all i. Let L
k
,
be the sub
set of L
,
in which at most the k distinct variables
x
1
, x
2
, . . . , x
k
occur.
We next recall the denition of (FO + LFP). Con
sider a rstorder formula (P, v
1
, . . . , v
r
, v
r+1
, . . . , v
s
)
with free individual variables v
1
, . . . , v
s
where an r
ary predicate P has only positive occurrences; let
= Vocabulary() P. Given a structure M
and elements a
r+1
, . . . , a
s
of M, we have the following
rary relations on the universe [M[ of M:
P
0
= , P
i+1
=
(v
1
, . . . , v
r
) [ M [= (P
i
, v
1
, . . . , v
r
, a
r+1
, . . . , a
s
)
Since P is positive in , P
0
P
1
P
2
. . .. M1
asserts that, for every such , there exists a posi
tive integer j such that, for every M K and any
a
r+1
, . . . , a
s
M, P
j
=
i
P
i
.
The least xed point operator LFP can be applied
to the formula . The result is a new formula
LFP
P;v1,...,vr
(v
1
, . . . , v
s
)
of vocabulary . If M is a structure, a
1
, . . . , a
s
are
elements of M and relations P
i
are as above then
M [= LFP
P;v1,...,vr
(a
1
, . . . , a
s
) (a
1
, . . . , a
r
)
_
i
P
i
.
(FO + LFP) is the extension of rstorder logic with
this new formulaconstructor. Applications of LFP
can be nested and interleaved with other formula
constructors. It is obvious that (FO+LFP) is a subset
of L
,
.
Pebble games are a convenient tool to deal with in
nitary formulas. A kpebble game
k
(A, B) is played
by Spoiler and Duplicator on structures A, B of vocab
ulary . For each i 1, . . . , k, there are two pebbles
numbered i; there are 2k pebbles altogether. Starting
with Spoiler, the players alternate making moves. A
move consists of placing a free pebble at an element
of one of the two structures or removing one of the
pebbles from some element. If Spoiler puts a pebble
of number i at an element x of A (resp., an element
y of B), Duplicator must answer by placing the other
pebble number i at some element y of B (resp., some
element x of A). If Spoiler removes a pebble number
i, Duplicator must remove the other pebble number i.
Initially, all pebbles are free. At each evennumbered
state S, the pebbles dene a partial map
S
from A to
B. Dom(
S
) consists of the elements of A covered by
pebbles. If x A is covered by a pebble i then
S
(x)
is the element of B covered by the other pebble i. Ini
tially, all 2k pebbles are free. The goal of Duplicator is
to ensure that every such
S
is a partial isomorphism.
If the game reaches an even state S such that
S
is
not a partial isomorphism, Spoiler wins; otherwise the
game continues forever and Duplicator wins.
Fact 2.1 ([B, I82]) Let l k and consider the ver
sion of
k
E
j
=
_
d
k
, d
k+1
)
0 k < j
_
We next show how to interpret the new relation
symbols in the D
j
s such that: For all i, for all j i,
and for all a
1
, a
2
, . . . , a
ui
[D
j
[,
D
j
[= (
i
(a
1
, a
2
, . . . , a
ui
) S
i
(a
1
, a
2
, . . . , a
ui
)) (3.4)
FromEquation 3.4, it follows that each
i
is equiva
lent to a rstorder formula in fact, to an atomic for
mula for all but nitely many structures. Of course,
on any xed nite structure, the formula
i
is equiv
alent to a rstorder formula. Lemma 3.2 follows im
mediately.
Now we construct the D
j
s so that Equation 3.4
holds. D
0
j
dened above is just a graph, which may
be thought of as interpreting all of the new relations as
false. Assuming D
i1
j
has been dened, let D
i
j
be the
same as D
i1
j
except that for all a
1
, a
2
, . . . , a
ui
[D
j
[,
we interpret S
i
so that
D
j
[= (
i
(a
1
, a
2
, . . . , a
ui
) S
i
(a
1
, a
2
, . . . , a
ui
))
Note that by Equation 3.3, this doesnt aect any of
the previous steps.
Let D
j
= D
j
j
. This completes the construction,
guaranteeing that Equation 3.4 holds. This completes
the proof of Lemma 3.2. 2
3.2 One Free Variable Case: Relations
Replaced by Cliques
Now, we get rid of the new relation symbols, re
placing them by cliques attached to the vertices in the
D
j
s. The main result we will need is that formulas
from L
k
,
, i.e. innitary formulas with at most k
variables, cannot distinguish kcliques from rcliques
for any r > k.
Lemma 3.5 Let F be a nite, directed graph and let
v be a vertex in F. For i 1, let F
i
be the result of
replacing v by a clique of i new vertices: v
1
, . . . , v
i
.
Each edge v, w) or z, v) from F is replaced with i
new edges: v
j
, w) or z, v
j
), j = 1, 2, . . . , i. Let 1
k < r be natural numbers. Then F
k
and F
r
agree on
all formulas with at most k variables from L
,
.
proof This is proved by using the game
k
from
Fact 2.1. We have to show that the Duplicator has
a winning strategy for the kpebble game on F
k
and
5
2
5
r
e
v
i
s
i
o
n
:
1
9
9
4

1
1

1
2
m
o
d
i
f
i
e
d
:
1
9
9
4

1
1

1
3
F
r
. Her strategy is to answer any move outside of the
cliques with the same vertex in the other graph. A
move on one of the new cliques is likewise matched by
a move on the new clique in the other graph. Since
there are only k pebbles, there is always an unpebbled
vertex in either of the cliques to match with. Thus the
Duplicator has a winning strategy. It follows that F
k
and F
r
agree on all formulas from L
k
,
. 2
To make the deterministic construction easier to
understand we begin by doing it just for formulas with
only one free variable:
Lemma 3.6 There exists a set of nite directed
graphs, H = H
1
, H
2
, . . ., such that H admits xed
points of unbounded depth, and yet on H, every for
mula with at most one free variable that is expressible
with a least xed point operator is already rstorder
expressible.
proof Let
1
,
2
, . . . be the set of all formulas in
(FO+LFP) that have at most one free variable. The
construction of the H
j
s is similar to that of the D
j
s
of Lemma 3.2. The dierence is that instead of mak
ing the relation S
i
(d) hold, we will modify the size of
a certain clique that is connected to d.
We next dene the sequence of natural numbers:
v
0
< v
1
< v
2
< that will be the sizes of the
initial cliques. Let v
0
= 0, and inductively, let
v
i
= max(var(
i
), v
i1
+ 2
i+1
). In the construction
of H
j
we will modify the sizes of cliques that are ini
tially of size v
i
. The modication will add a number
of vertices to these cliques while keeping them smaller
than v
i+1
.
Dene the graph H
0
j
as follows: First, H
0
j
contains
D
0
j
, the directed segment of length j 1. For each
d [D
0
j
[ and for each i j, H
0
j
also contains the size
v
i
clique C
d,i
which has edges from each of its elements
to the vertex d.
Assuming H
i1
j
has been dened, let H
i
j
be the
same as H
i1
j
except that for each d [D
0
j
[ we add
n(d, i) vertices to the v
i
vertex clique C
d,i
. The num
ber n(d, i) is an i + 1 bit binary number such that:
(Bit 0 of n(d, i) is one.) (H
i1
j
[=
i
(d))
And, for 1 s i, let a
s
be a vertex in C
d,s
. Then,
(Bit s of n(d, i) is one.) (H
i1
j
[=
i
(a
s
))
Finally, let H
j
= H
j
j
. Dene the notation S _
k
T
to mean that S is a kvariable elementary substructure
of T. That is, S is a substructure of T and for all
rstorder formulas with var() k, and for all
a
1
, a
2
, . . . , a
k
[S[,
S [= (a
1
, a
2
, . . . , a
k
) T [= (a
1
, a
2
, . . . , a
k
)
We have constructed the H
j
s so that,
H
i1
j
_
vi
H
j
(3.7)
Equation 3.7 follows from Lemma 3.5 and the fact
the the construction of H
r
j
for r i proceeds by in
creasing the size of cliques whose size is at least v
i
.
Let a [H
j
[. If a = d [D
0
j
[ then,
(H
j
[=
i
(a)) (H
i1
j
[=
i
(d))
(Bit 0 of n(d, i) is one.)
If a is a member of a clique C
d,r
, let s = min(i, r).
Then,
(H
j
[=
i
(a)) (H
i1
j
[=
i
(a))
(Bit s of n(d, i) is one.)
Remember that v
i+1
is a xed constant. Further
more, there are at most 2
i+1
possible values for n(d, i).
It follows that there is a rstorder formula
i
(a) that
nds the appropriate d and s, and determines n(d, i)
which is the size of largest maximal clique connected
to d that has fewer than v
i+1
vertices. Next, compute
bit s of n(d, i) by table look up, and let
i
(a) be true
i this bit is one.
Thus, we have that for all j i and for all a [H
j
[,
H
j
[= (
i
(a)
i
(a)) 2
3.3 General Case: Arbitrary Arity
The reason that the general case is more compli
cated than the arity one case is that we must include
gadgets that identify tuples of nodes. We then must
contend with having arguments from these gadgets
and so the arities seem to multiply. We must therefore
be careful so that the arities remain bounded.
proof of Theorem 3.1: Let
1
,
2
, . . . be a listing of
all formulas in (FO + LFP). As we have mentioned,
arities might multiply. The base arity of the formula
i
is f
i
= free(
i
). We will use increased arities A
0
<
A
1
< . . . < A
j
dened by A
0
= 1, and inductively,
A
i
= 1 + (A
i1
)(2f
i
) (3.8)
Next dene the sequence of natural numbers: w
0
<
w
1
< w
2
< that will be the sizes of the ini
tial cliques. Let w
0
= 0, and inductively, let w
i
=
max(var(
i
), 1 +w
i1
+A
i1
).
5
2
5
r
e
v
i
s
i
o
n
:
1
9
9
4

1
1

1
2
m
o
d
i
f
i
e
d
:
1
9
9
4

1
1

1
3
To dene the graph G
j
, we begin as usual by includ
ing the directed segment D
0
j
. For each i, we include
enough gadgets: T
r
i
, r = 1, 2, . . . , n
i
, to encode all
possible sequences of length at most A
i
of elements of
[D
0
j
[. (Here, n
i
is equal to (j + 1)
Ai
.)
Each gadget T
r
i
consists of j A
i
cliques of size w
i
.
For each d [D
0
j
[ there are A
i
of these cliques, C
r
d,i
,
with edges to d. T
r
i
also contains one vertex t
r
i
with
edges to all the C
r
d,i
s, d = 1, . . . , j. When we want T
r
i
to encode the sequence d
1
, d
2
, . . . , d
Ai
we will choose
A
i
cliques, C
r
d1,i
, C
r
d2,i
, . . . , C
r
dA
i
,i
and increase their
sizes by 1, 2, . . . , A
i
vertices respectively. Note that
we have enough copies of each C
r
d,i
to tolerate any
number of repetitions of the same d. To skip one of the
members of the sequence, say d
t
, we increase no clique
by exactly t vertices. In this case we write d
t
= 0.
Thus, we have shown how to modify the gadget T
r
i
so that it codes any sequence of length A
i
from the
alphabet 0, 1, . . . , j. Note that no formula
t
with
t i can detect this modication!
Dene G
0
j
to include D
0
j
plus all of the T
r
i
s, 1
i j, 1 r n
i
.
Inductively, assume that G
i1
j
has been con
structed. Now, for each tuple a
1
, a
2
, . . . , a
fi
[G
i1
j
[,
if G
i1
j
[=
i
(a
1
, a
2
, . . . , a
fi
), then we will mod
ify one of the gadgets T
r
i
to encode the tuple,
a
1
, a
2
, . . . , a
fi
.
Lets rst consider the case that a
1
is a vertex from
some T
r1
i1
. In this case, T
r1
i1
codes a sequence,
b
11
, b
12
, . . . , b
1,Ai1
, each b
1t
0, 1, . . . , j (3.9)
To reencode this sequence, we rst just copy it.
Next, we have to indicate which vertex in T
r1
i1
, a
1
is. (It could be the vertex t
r1
i1
, or a vertex in one
of the unused cliques, C
r1
d,i1
, or in one of the cliques
C
r1
b1q,i1
that codes the q
th
element of the sequence of
Equation 3.9. In each case, we use the A
i1
extra slots
to encode which of these cases apply
1
. This is the rea
son for the factor of 2 in Equation 3.8 and while this
is slightly wasteful, it is simple and we are just trying
to prove that something is nite.
We have just explained how to encode a
1
in the rst
2A
i1
slots of T
r
i
. Similarly, code a
2
, . . . , a
fi
into the
next 2A
i1
(f
i
1) slots. (If one of the a
s
s comes from
a shorter sequence, then leave the rest of its positions
0.) Finally, in the one remaining slot, put a 1.
1
For those who want to know, the coding is done as follows:
If a
1
is the vertex t
r
1
i1
, then the extra A
i1
slots are all 0s. If
a
1
is in an unused C
r
1
d,i1
, then the rst two extra slots contain
ds and the rest are 0s. Finally, if a
1
is in C
r
1
b
1q
,i1
then put
b
1q
into the q
th
extra slot and leave the rest 0.
Let G
j
= G
j
j
. It follows just as in Equation 3.7
that, G
i1
j
_
wi
G
j
.
Again recall that each A
i
and w
i+1
is a xed con
stant. Thus, given a tuple, a
1
, . . . , a
fi
from [G
j
[, a
rstorder formula,
i
(a
1
, . . . , a
fi
), can express the ex
istence of the gadget T
r
i
that codes this tuple. Thus,
for all j i,
G
j
[= (
i
(a
1
, . . . , a
fi
)
i
(a
1
, . . . , a
fi
))
This complete the proof of Theorem 3.1. 2
We should note that Theorem 3.1 did not use any
properties of (FO + LFP) except that the language is
countable and each formula had a constant number of
variables. We thus have the following extension:
Corollary 3.10 Let L be any countable subset of for
mulas about graphs from L
,
on unordered structures is not expressive enough
to count.
In [CFI] a lower bound was proved on the lan
guage (FO + COUNT + LFP). This is a language
over twosorted structures: one sort is the numbers:
0, 1, . . . , n1 equipped with the usual ordering. The
other sort is the vertices: v
0
, v
1
, . . . , v
n1
with the
edge predicate. The interaction between the two sorts
is via counting quantiers. For example, the formula,
(i x)(x)
means that there exist at least i vertices x such that
(x). Here i ranges over numbers and x over ver
tices. The least xed point operator may be applied
to relations over a combination of number and vertex
variables. Dene the language (L + COUNT)
,
to
be the superset of (FO+COUNT+LFP) obtained by
adding counting quantiers to L
,
.
In [CFI] it is shown that the language (FO +
COUNT+LFP) and in fact even (L+COUNT)
,
does not express all polynomialtime properties, even
over structures of color class size four. Such structures
are almost ordered: they consist of an ordered set of
n/4 color classes, each of size four. Only the vertices
inside these color classes are not ordered. We glean
the following fact from [CFI].
5
2
5
r
e
v
i
s
i
o
n
:
1
9
9
4

1
1

1
2
m
o
d
i
f
i
e
d
:
1
9
9
4

1
1

1
3
Fact 3.11 ([CFI]) For each n > 0 there exist noni
somorphic graphs T
n
and
T
n
each with O(n) vertices,
such that T
n
and
T
n
are indistinguishable by all for
mulas with at most n variables from (FO + LFP +
COUNT), or even from (L + COUNT)
,
.
Useful in the proof of Fact 3.11 as well as in the next
theorem is the following modication of the game
k
,
:
Fact 3.12 ([IL]) The Duplicator has a winning strat
egy for the (
k
,
.
Using the above facts, we now prove a counterex
ample to a weaker version of McColms Conjecture:
Theorem 3.13 There exists a set of nite directed
graphs, = J
1
, J
2
, . . ., such that admits xed
points of unbounded depth and yet on , FO = (FO+
COUNT+LFP), i.e., every formula expressible with a
least xed point operator and counting is already rst
order expressible. In fact, this statement remains true
when (FO+COUNT+LFP) is replaced by an arbitrary
countable subset of (L + COUNT)
,
.
proof The idea of this construction is that everywhere
we started with a clique of size n in the previous proof,
we will start with a chain of copies of the graph T
n
from Fact 3.11. Then where previously we increased
the size of the clique to code some number b of bits, we
will instead ip some copies of T
n
to
T
n
, in a particular
length b chain of T
n
s.
The main dierences are that unlike the cliques,
there is not an automorphism mapping every point
in T
n
to every other point in T
n
. Furthermore, T
n
is distinguishable from T
n+1
using a small number of
variables.
Let f(j) be the number of formulas that are han
dled by the structure G
j
, and let v(j) be v
f(j)
, the
number of variables to be handled as in the proof of
Theorem 3.1. Observe that f(j) and thus v(j) may be
chosen to grow very slowly. In particular, we will make
sure that f(j), and in fact the number of vertices in
each T
v(j)
is less than j. Recall also that the graphs T
n
from Fact 3.11 are ordered up to sets of size four. We
introduce two new binary relations: Red edges from
each vertex in each T
v(i)
to the vertex i D
0
j
, and
Blue edges from each of the four vertices numbered
k in any of the T
v(i)
s to the vertex k D
0
j
. Thus,
any vertex chosen from G
j
will have a name that
consists of a pair of vertices from D
0
j
, together with a
bounded number of bits.
The construction and proof now follow as in the
proof of Theorem 3.1. 2
We also show,
Corollary 3.14 If P ,= PSPACE, then there exists a
set ( of nite structures such that FO = (FO + LFP)
on (; but, FO ,= (FO + ITER) on (.
proof Let ( be the set of all nite, ordered graphs.
If P ,= PSPACE, then there is a property S ( such
that S PSPACE P. Now, do the construction of
Theorem 3.1, starting with (. This construction as
sures that FO = (FO + LFP) on the resulting set (.
However, any rstorder formula has a xed number,
k, of variables. Thus, to , the noticeable changes dur
ing the construction involve at most k PTIME proper
ties. Therefore, S is still not recognizable in FO over
(. 2
One special case of McColms conjecture remains
open. This is a fascinating question in complexity the
ory and logic related to uniformity of circuits and log
ical descriptions, cf. [BIS]. Consider the structures
B = B
1
, B
2
, . . . where B
i
= 0, 1, . . . , i 1,
, BIT). Here is the usual ordering on the natural
numbers and BIT(x, y) holds i the x
th
bit in the bi
nary representation of the number y is a one.
Question 3.15 Is FO = (FO + LFP) over B?
The answer to Question 3.15 is Yes, i every
polynomialtime computable numeric predicate is al
ready computable in (FO + BIT). Equivalently, the
5
2
5
r
e
v
i
s
i
o
n
:
1
9
9
4

1
1

1
2
m
o
d
i
f
i
e
d
:
1
9
9
4

1
1

1
3
answer to Question 3.15 is Yes, i deterministic log
time uniform AC
0
is equal to polynomialtime uniform
AC
0
, cf. [BIS]. A resolution of this question would
thus answer an important question in complexity the
ory.
4 The Randomized Construction
We now sketch a quite dierent construction that
also disproves McColms conjecture. Throughout this
construction, P is a binary predicate. We will prove:
Theorem 4.1 Suppose that K
1
is a class of struc
tures of some vocabulary
1
, and L is an arbitrary
countable subset of L
,
. Let
2
be the extension of
1
with an additional binary predicate P. There exist
a class K
2
of
2
structures such that:
1. K
1
is precisely the class of
1
reducts of substruc
tures M
2
[ x [ P(x, x) where M
2
ranges over
K
2
.
2. Every Lformula is equivalent to a rstorder for
mula in K
2
.
The idea of the proof is relatively simple. Let
1
,
2
, . . . be a list of all Ldenable global relations
on K
1
. We attach a graph G to every M K
1
and
dene a projection function from elements of the new
sort to elements of the old sort. Relations
M
i
on the
old sort are coded by cliques of G; a tuple a belongs
to
M
i
if and only if there is clique of cardinality i
projected in a certain way onto a. The necessity to
have appropriate cliques is the only constraint on G;
otherwise the graph is random. We check that ev
ery Ldenable global relation reduces by rstorder
means to Ldenable global relations on the old sort
and thus is rstorder expressible. In fact, we beef L
up before executing the idea.
Let H be a hypergraph of cardinality 2.
Denition 4.2 An envelope for H is a Pstructure
E satisfying the following conditions:
[H[ [E[, and P is the identity relation on [H[.
P is irreexive and symmetric on [E[ [H[.
For every x [E[ [H[, there is a unique a H
with E [= P(x, a).
For every a [H[ and every x [E[ [H[, E [=
P(a, x).
2
Let E range over envelopes for H such that [E[
[H[ ,= .
Denition 4.3 Elements of H are nodes of E and
elements of [E[[H[ are vertices of E. G
E
is the graph
formed by P on the vertices. If E [= P(x, a) and a H
then a is called the projection of x and denoted F(x)
(or Fx). If X is a set of elements of E then F(X) is the
multiset Fx [ x X. If x is a sequence (x
1
, . . . , x
l
)
of elements of E then F( x) = (F(x
1
), . . . , F(x
l
)). 2
Let k be a positive integer 3.
Denition 4.4 A clique X of G
E
is a kclique if
F(X) HE(H) and [[X[[ < k. A vertex that does
not belong to any kclique is kplebeian. The kclosure
C
k
(X) of a subset X of E is the union of X and all
kcliques intersected by X. 2
Denition 4.5 E is kgood for H if it satises the
following conditions.
G
0
(k) All kcliques are pairwise disjoint.
G
1
(k) For every X [E[ of cardinality < k, there is
a kplebeian vertex z [E[ X with a predened
projection Fz which is Prelated to C
k
(X) in any
predened way that does not destroy any kclique
C C
k
(X). In other words, if a is a node,
Y C
k
(X) and Y does not include any kclique,
then there is a kplebeian vertex z F
1
(a) X
adjacent to every vertex in Y and to no vertex in
C
k
(X) Y .
G
2
(k) For every X [E[ of cardinality < k, there is
a kclique y
1
, . . . , y
l
[E[ X with any prede
ned projections Fy
m
and any predened pattern
R = (x, m) [ E [= P(x, y
m
) that does not de
stroy any kclique C C
k
(X). In other words,
if a = (a
1
, . . . , a
l
) is a tuple of nodes, l < k,
MS( a) is a hyperedge, R C
k
(X) 1, . . . , l,
no vertex is Radjacent to all the numbers, and
no number is Radjacent to all vertices of any
kclique C C
k
(X), then there is a tuple y =
(y
1
, . . . , y
l
) of distinct vertices such that F( y) =
a, y
1
, . . . , y
l
is a clique disjoint from X, and
E [= P(x, y
m
) (x, m) R for all x C
k
(X)
and all m.
2
Lemma 4.6 1. If E is kgood, X E and [[E[[ < k
then [[C
k
(X)[[ (k
1
)
2
.
5
2
5
r
e
v
i
s
i
o
n
:
1
9
9
4

1
1

1
2
m
o
d
i
f
i
e
d
:
1
9
9
4

1
1

1
3
2. If E is kgood then every hyperedge of cardinality
< k is the projection of some kclique.
3. In every kgood envelope, every clique C of car
dinality < k is a kclique. Moreover, if a clique
C C
k
(X) for some X of cardinality < k then
C is a kclique.
4. Let H
.
5. If E is k
> k then E is
kgood for H.
proof Omitted due to lack of space. 2
Theorem 4.7 There exists a kgood envelope for H.
proof Omitted due to lack of space. 2
4.1 The Game
Let M be a structure of some vocabulary
0
such
that every element of M interprets some individual
constant. It is supposed that
0
does not contain the
xed binary predicate P. Let H be a hypergraph on
[M[, so that [H[ = [M[. An envelope E for H can be
seen as a structure of vocabulary =
0
P where
the
0
reduct of the substructure E [ [H[ equals M
and no
0
relation involves elements of [E[ [H[.
Fix a positive integer k and let E and E
range over
kgood envelopes for H. We will prove that Duplicator
has a winning strategy in
k
(E, E
).
Denition 4.8 A partial isomorphism from E to
E
) = F(X).
2
Denition 4.9 A kcorrect partial isomorphism
from E to E
with domain
C
k
(Dom()). 2
Lemma 4.10 Suppose that is a knice partial iso
morphism from E to E
. Then
and
1
are knice,
(
)
1
= (
1
)
, and Range(
) = C
k
(Range()).
(E, E
(E, E
(E, E
0
(u
1
, . . . , u
s
, v
1
, . . . , v
l
) is satised. 2
Denition 4.15 A ktable (v
1
, . . . , v
l
) is a conjunc
tion such that:
Some 0table (v
1
, . . . , v
l
) is a conjunct of
(v
1
, . . . , v
l
).
If j < k and (v
1
, . . . , v
l
) is a (j, k)table consis
tent with (v
1
, . . . , v
l
) then either (v
1
, . . . , v
l
) or
(v
1
, . . . , v
l
) is a conjunct of (v
1
, . . . , v
l
).
There are no other conjuncts.
2
Fix a k
variable innitary formula (u
1
, . . . , u
l
, v
1
, . . . , v
m
)
and let ( u, v) be the conjunction of ( u, v) and some
ktable ( v). Let a be an ltuple of nodes of H and
b be an mtuple of nodes H. We introduce a relation
( u, v) on H.
5
2
5
r
e
v
i
s
i
o
n
:
1
9
9
4

1
1

1
2
m
o
d
i
f
i
e
d
:
1
9
9
4

1
1

1
3
Denition 4.16
( a,
b) E [= ( v)[(( a, v)) F( v) =
b].
2
Lemma 4.17
(E, E
. In particular, no sentence
(v
1
, . . . , v
m
)[ P(v
1
, d
1
) . . . P(v
m
, d
m
)
(c
1
, . . . , c
l
, v
1
, . . . , v
m
)],
where c
1
, . . . , c
l
, d
1
, . . . , d
m
are individual constants,
distinguishes between E and E
. 2
Theorem 4.18 Let x be an mtuple of vertices in E.
The following claims are equivalent:
1. E [= ( a, x).
2. H [=
,
formulas.
A global relation on a class K is decidable if there
exists an algorithm that, given (the encodings of) a
structure M K and a tuple a of elements of M
of appropriate length, decides whether M [= ( a) or
not. We are interested in a relativized version of this
denition where K is the collection of all structures
(that is, all nite structures) in the vocabulary of .
Let
= (, M, a, 1) [ L M [= ( a)
(, M, a, 0) [ L M ,[= ( a)
Denition 4.21 A global relation of vocabulary
is Ldecidable if there is an algorithm with oracle
that, given a structure M and a tuple a of elements
of M of appropriate length, decides whether M [= ( a)
or not. 2
Every global relation dened by a formula in L is
Ldecidable, and there there are only countably many
Ldecidable relations. List all Ldecidable irreexive
global relations on K
1
of positive arities:
2
,
3
4
, . . .,
and let r
i
be the arity of
i
. We suppose that r
i
(r
i
+
1)/2 i. Let M range over K
1
and i range over
positive integers 2.
For each M and each i, let
M
i
be the collection
of oriented multisets A such that OSet(A)
M
i
and
[[A[[ = i. Since 1 +2 +. . . +r
i
= r
i
(r
i
+1)/2 i,
M
i
is empty. Let H(M) be the hypergraph
_
[M[ ,
_
M
i
[ 1 i [[M[[
_
.
Set
2
=
1
P and let c(M) be the collection
of [[M[[good envelopes for H(M) of minimal possible
cardinality. (The minimal cardinality is not impor
tant; we will use only the following two consequences:
(i) c(M) is nite, and (ii) there is an algorithm that,
given M constructs some E c(M).) View envelopes
E c(M) as
2
structures where the
1
reduct of the
substructure E [ [M[ equals M and no
1
relation in
volves elements of [E[ [M[. For every K K
1
, let
c(K) =
MK
c(M). Finally, let K
2
= c(K
1
). By
the denition of envelopes (Denition 4.2), K
2
satis
es requirement 1 of Theorem 4.1. In order to prove
requirement 2, it suces to prove that every innitary
formula with Ldecidable global relation is rstorder
denable in K
2
.
For any global relation ( v) on K
1
, let
+
( v) be the
global relation on K
2
such that
E [=
+
( x) M [= (F( x))
5
2
5
r
e
v
i
s
i
o
n
:
1
9
9
4

1
1

1
2
m
o
d
i
f
i
e
d
:
1
9
9
4

1
1

1
3
if M K, E c(M) and x is a tuple of elements of
E of the appropriate length.
Lemma 4.22 If is Ldecidable then
+
is rst
order denable in K
2
.
proof Omitted due to lack of space. 2
Now let be an arbitrary innitary
2
formula
whose global relation is Ldecidable. We prove that
is equivalent to a rstorder formula in K
2
. Without
loss of generality, = (u
1
, . . . , u
l
, v
1
, . . . , v
m
) and
implies
P(u
1
, u
1
), . . . , P(u
l
, u
l
), P(v
1
, v
1
), . . . , P(v
m
, v
m
)
In other words, variables u
i
are node variables, and
variables v
j
are vertex variables.
Let k be the total number of variables in , K
1
=
M [ [[M[[ k and K
2
= c(K
1
), so that every
E K
2
is kgood. Since K
2
K
2
is nite, it suces to
prove that ( u, v) is equivalent to a rstorder formula
in K
2
. Let ( v) be an arbitrary ktable. Since there
are only nite many ktables, it suces to prove that
the formula ( v) = ( v) ( v) is equivalent to a rst
order formula over K
2
.
Dene a global relation
on K
1
as follows:
M [=
( a,
b) ( x)[(E [= ( x)) F( x) = a]
where E c(M). The choice of E does not matter.
Indeed, extend
1
with individual constants for each
element of M; call the resulting vocabulary
0
. Now
apply Lemma 4.17 with H = H(M).
Lemma 4.23
is Ldecidable.
proof Clear. 2
It is not quite true that (
)
+
is the global relation
of the formula on K
2
but this is close to truth. By
virtue of Theorem 4.18,
( u, v) [(
)
+
( u, v) ( v)
on K
2
. Indeed, consider any M K
1
. Extend
1
with individual constants for each element of M; call
the resulting vocabulary
0
. Now apply Theorem 4.18
with H = H(M). By Lemma 4.22, (
)
+
is rst
order denable in K
2
. It follows that is equivalent
to a rstorder formula on K
2
.
Acknowledgment
We are grateful to Anuj Dawar, Phokion Kolaitis,
Steven Lindell, and Scott Weinstein for stimulating
discussions.
References
[AV] S. Abiteboul and V. Vianu, Generic Computa
tion And Its Complexity, 32nd IEEE Sympo
sium on FOCS (1991), 209219.
[B] J. Barwise, On Moschovakis Closure Ordi
nals, J. Symb. Logic 42 (1977), 292296.
[BIS] D. Barrington, N. Immerman, H. Straubing,
On Uniformity Within NC
1
, JCSS 41, No.
3 (1990), 274  306.
[CFI] J. Cai, M. F urer, N. Immerman, An Opti
mal Lower Bound on the Number of Variables
for Graph Identication, Combinatorica 12 (4)
(1992) 389410.
[D] A. Dawar, Feasible Computation Through
Model Theory, PhD Dissertation, University
of Pennsylvania (1993).
[G] Y. Gurevich, Logic and the Challenge of Com
puter Science, in Current Trends in Theoreti
cal Computer Science, ed. E. B orger, Computer
Science Press, 1988, 157.
[I82] N. Immerman, Upper and Lower Bounds for
First Order Expressibility, JCSS 25, No. 1
(1982), 7698.
[I89] N. Immerman, Descriptive and Computational
Complexity, Computational Complexity The
ory, ed. J. Hartmanis, Proc. Symp. in Ap
plied Math., 38, American Mathematical Soci
ety (1989), 7591.
[IL] N. Immerman and E. S. Lander, Describing
Graphs: A FirstOrder Approach to Graph
Canonization, in Complexity Theory Retro
spective, Alan Selman, ed., SpringerVerlag,
1990, 5981.
[KV] Ph. Kolaitis and M. Vardi, Fixpoint Logic vs.
Innitary Logic in FiniteModel Theory, LICS
1992, 4657.
[M] G. McColm, When is Arithmetic Possible?
Annals of Pure and Applied Logic 50 (1990),
2951.
[V] M. Vardi, Complexity of Relational Query
Languages, 14th Symposium on Theory of
Computation (1982), 137146.