 worth is at least five, it's easy to write out what the sentence looks like. But some properties which are not definable are things like graph being connected or three-colourable or planar or having an even number of edges. And when we talk about Erwin Freud-Frasay games, we'll talk a bit about how you establish these properties. Okay, so one early program of research in finite model theory, which was started by Gorevitch and others in the 1980s, looked at the key theorems in classical model theory and to see what happens to those theorems when you restrict them to finite structures. And so two of the central pillars of classical model theory, so the compactness and completeness theorems fail, break down when restricted to finite structures. So let's just look at this quickly. So the compactness theorem says that if you have a theory or a t, a set of finite sentences, then t has a model if and only if every finite sub-theory, every finite subset of t has a model. And this fails on finite structures, which is easy to see by the following example. So if t consists of the set of sentences saying there exist at least n elements in the universe, then every finite subset of t, finite set of sentences has a finite model with any large enough finite set. But t itself has only infinite models. So this shows that compactness theorem fails on finite structures. Similarly, the completeness and incompleteness theorems of Gertl say that the set of first-order tautologies, the set of first-order sentences phi, such that phi holds for all structures a, including finite and infinite structures, this set is recursively innumerable but not co-ore. And it's interesting that on finite structures, the opposite holds, this is known as Schrodinger's theorem that the set of finite tautologies is co-ore but not re. So that's another big difference between classical and finite model theory. And maybe not surprisingly, nearly all of the classical theorems which rely on the compactness principle turn out to fail on finite structures. And this includes a large class of classical preservation interpolation and amalgamation theorems. But understanding exactly which classical theorems fail on finite structures and which hold on finite structures turns out to be quite a delicate matter. So I'll give a quick example of this. So here are three of the classical preservation theorems from classical model theory. So the first one, the Volsch-Tarski theorem says that formula phi is preserved under injective homomorphisms if and only if phi is logically equivalent to an existential sentence. So don't worry about the, I'm not going to go into any detail about these results, just want to point something out. So don't worry if the statement doesn't make immediate sense to you. But so a related theorem is Linden's theorem which says something similar but this time preservation under surjective homomorphisms is characterized in terms of being equivalent to a positive sentence, that is a first order sentence without negation. And then a third theorem known as the homomorphism preservation theorem, it sort of looks like the intersection of these two theorems and it says that if phi is preserved under all homomorphisms or if it's preserved under both injective and surjective homomorphisms then it's equivalent to a sentence which is both existential and positive. And so these results are statements about the class of all structures but if we restrict to just finite structures then it turns out that the first two of these theorems, Volsch-Tarski theorem and Linden's theorem, turn out to fail on finite structures and counter examples were given by Tate in 1959 for the first one and later for Linden's theorem. But it turns out that the homomorphism preservation theorem which looks very similar and looks almost like the intersection of these two turns out to hold on finite structures. So it's a bit of a delicate question which theorems hold and which ones fail. So this is one program of research in finite model theory. But one technique which applies to both the infinite and finite settings is that of Ehrenfreude-Frasse games. Okay, so that was a very, very quick overview of some of the differences between classical and finite model theory and the rest of the talk will be substantially different. So if that went too fast, you can ignore it. Okay, so now I'll go into a bit of detail about Ehrenfreude-Frasse games and maybe I'll try to slow down a bit here. And please again, now really feel free to interrupt me with questions if something's not clear. Okay, so an important parameter of first order formulas is quantifier rank. So this is defined as the maximum nesting depth of quantifiers in a formula. So there's an inductive definition for this. If we have atomic formula x equals y or r of x1 to x, r of some tuple of variables, this has quantifier rank 0, there's no quantifier. You know, negation and preserves quantifier rank and, you know, disjunction and conjunction, you take the maximum and then quantification, you increase the quantifier rank by 1. So there's a notion of k equivalence of two structures. So we'll say structures A and B are k equivalents if they satisfy the same sentences of quantifier rank k. So and we denote by this, a quiv sub k, this is the notation for k equivalence. So one key property of this notion of k equivalence is that for any fixed finite signature, there are only finitely many k equivalence classes. And another nice property of k equivalence is that it's a congruence with respect to a broad class of well-behaved structural operations, for instance disjoint union or categorical product of two structures. So for example, a Pfeffermann-Vot theorem says that if I have two pairs of structures A and A prime which are k equivalent and another pair B and B prime which are k equivalent, then the product of A and B is k equivalent to the product of A prime and B prime. Okay so k equivalence also gives us a kind of way of proving that a class of finite structures is not first order definable. So just an observation, if we have a class of finite structures C, then to show that it's not first order definable, it's necessary and sufficient to show that for every k there exists a pair of finite k equivalent structures A and B such that A belongs to the class C and B does not belong to the class C. This is a very useful, necessary and sufficient condition for showing that some class is not first order definable. So to see why that is, we can look at the kind of contrapositive statement. So suppose that C is first order definable. So then there's some formula phi which defines C. But this means that if we have structures A and B which are equivalent for k equivalent where k is the quantifier rank of that formula phi, then A belongs to C if and only if B belongs to C. Okay, anyway, this is a simple observation but I'm going to make kind of implicit use of it. Okay, so the Ehrenfreude-Frasse game gives us a way to characterize the quantifier rank you need in order to distinguish two structures in first order logic. And this was introduced separately by Ehrenfreude and Frase in 1953, 1961. So okay, so you've seen this already but I'll tell you the definition of the game one more time. So the k-round Ehrenfreude-Frasse game on a pair of structures A and B has two players which we call spoiler and duplicator although there are other names in the literature such as Samson and Delilah and non-equivalent and equivalent players. But here I'll use spoiler and duplicator. So the duplicator wants to prove to establish that A and B are k equivalent and the spoiler wants to refute that A and B are k equivalent. So those are their goals. So the way the game work is that in each of the k rounds of the game first the spoiler selects an element in either structure so he selects a structure and an element in that structure and then the duplicator selects an element in the other structure. And so this continues for k rounds and at the end of the game after all k rounds we have a sequence of k distinguished elements in A and a sequence of k distinguished elements in B and we say that duplicator wins the game if and only if these two k-tuples of elements describe a partial isomorphism between the two structures. Okay so that's the definition of the game and I'll work through some concrete examples so this will hopefully be very clear later on. Okay so the key theorem about Ehrenfreude-Frasse games is the following. So the duplicator has a winning strategy. So by the way this is a zero sum game so either spoiler or duplicator has a winning strategy for any given k and any given pair of structures A and B. So the duplicator has a winning strategy in the k-round Ehrenfreude-Frasse game on structures A and B if and only if A and B are k equivalent. So this is the key property of Ehrenfreude-Frasse game. And this has a straightforward proof by induction on formulas and there are similar games and variants of this game which characterize the finability in other logics. Okay so now let's look at some concrete examples of Ehrenfreude-Frasse games and to prove that certain classes of structures of first order structures are not first order definable. Okay so the first example I want to look at is the class of even linear orders of finite even linear orders. I want to show that this is not definable in first order logic. So a linear order is just a structure and here I'm talking always about finite structure so a finite set together with a linear order on that set and by even I just mean that there's an even number of elements. So the class of even linear orders is not first order definable. So how do you prove this using Ehrenfreude-Frasse games? Well for an arbitrary k we show that we give an example of a pair of structures A and B where A has even size, B has odd size and yet these are k equivalent. So in other words duplicator has a strategy in this game. So the structures we're going to use will let A be a linear order of size 2 to the k and B will be a linear order of size 2 to the k plus 1. And we're going to give a winning strategy for duplicator in the k round game on this pair of structures. So let's just see graphically how the duplicator strategy looks. So here are the two structures, the two linear orders and we can see that B has one more element than A does. So let's say in round one spoiler gets to pick which structure he plays in and so spoiler selects an element in one of these structures and let's just say he picks this red element in B below. So duplicator has to select an element in the other structure and what he'll do is he'll notice that this red element is closer to the left end point of B so he'll match that distance to the left side, okay? And in round two of the game spoiler again gets to pick one of these two structures and select an element. Let's say he plays this blue element in structure A. So this blue one is closer to the red point than to the right end point of A so the duplicator will match that distance in the structure B. Now in round three of the game maybe spoiler plays this green element which is now closer to the right end point than to its neighbor to the left and so similarly duplicator will match that distance on the right hand side and so on. Okay, so through these five rounds of the game we see that we have a partial isomorphism you know the pairs of pebbles that have been played in both structures give a partial isomorphism so far so so far duplicator is winning this game through the first five round but actually at this point the spoiler will win in the next round by playing this orange element in the structure B to which duplicator has no reply so no matter which element of A he colors orange and of course you can color the same element with multiple colors but it won't be a partial isomorphism so I hope this example visually illustrates kind of how how duplicator can win for as long you know for certain number of rounds so what can we say in general for these for pairs of what can we say in general for this game when A and B have differed by one element so so in general duplicator can win the K round game provided that both A and B have at least two to the K elements so duplicator can win for log many rounds and the winning strategy is just in rounds J of the game we preserve distances up to up to two to the K minus J okay so you can write it write this out formally how it works but I think it's it's pretty clear very simple example okay now I want to use this this our result about even linear orders to show that the class of connected graphs is not first order definable and this will illustrate another technique in model theory known as a first-order interpretation so the observation is for okay so for a linear order a of size n I'm going to define a graph g of a okay which will be a graph with the same vertex that is a where the edge relation is we put an edge between every two every two elements of distance to cyclically so this we just illustrated here so we've added purple edges here from it guys at distance two apart when wrapping around and so the observation is that if n is odd then the graph g g of a will be a single n cycle a connected graph and if n is even this graph g g of a will be a disjoint union of two cycles of size n over two so in other words connectivity of the graph g of a depends on the evenness of the graph a okay so so now here's our proof using this little observation of that the class of connected graphs is not first order definable so for for toward a contradiction let's assume we have some formula fee which defines connectivity we have some sentence which defines connectivity so I'm going to define a different sentence fee star by replacing each sub formula of the form edge you know there's an edge between x and y so each of those atomic formulas in fee with with the formula which says that either why has distance two from you know is x plus two or y is x minus two cyclically okay in this in this linear order so so fee is a sentence in the language of graphs but this fee star that we've translated it into is now a sentence about linear orders and the observation is that you know the the negation of this fee star is defining evenness of the class of linear orders which we showed which we just showed previously is impossible okay so now of course one can also prove directly that connectivity of graphs is not first order definable using earn for it for say games for example on the pair of structures you know one one encyclops versus the disjoint union of two encyclops but this reduction that we showed to to non-define ability of evenness of linear orders is illustrates this technique of interpretation so I just wanted to mention that was this clear so far I mean this is all very elementary okay so now I'm going to give a slightly more slightly more complicated example and this will lead to some more interesting result also okay so now I want to consider a class of set structures which I'll call set power set structures so I'll denote by set power sub n the following structure so the universe of the structure will consist of two what's known as sorts so it will be a disjoint union of a set of of atoms which will be just integers one to n and then as well as the set of all sets of atoms so the power set of this one to n and there'll be a and there'll be a single binary relation so there'll be two unary relations atoms and sets which name these two parts of our structure and then a binary relation in which just defines the set membership so I is in X in this relation if and only if I is a member of X okay so okay and and so that's set power sub n and in general of a finite set power set structure is any structure which is isomorphic to to set power sub n for some n and we'll say that the structure is even or odd according to the parity of n so that according to the number of atoms in the structure okay so structure has atoms and sets and then there are the set membership relation between those two sorts okay so the the first observation here is that the class of finite set power set structures is first-order definable and this is not completely obvious at first because something which we can't simply say in first-order logic is is the top expression here so that for every subset of atoms there's some set which which you know is you know which has the property that for every atom that atom belongs to the set if and only if in of excess because you know this is not a proper first-order formula because we've quantified overall subsets of atoms so instead the way you define this class of set power set structures is is the following so first of all we can we can write a formula which expresses that the empty set belongs to this to this set sort and then we say the following that for every set s and every atom the the union of s and that extra atom is also belongs to the set sort so this gives a closure property of the set of sets okay and this formula is exploiting the fact that we're talking about finite structures in a rather essential way so if our if our if our if our sort of sets contains the empty set and it's closed under the property that if you have something and you add an element you get you remain in in the in the sort then of course we contain every subset of atoms okay so now the theorem I want to show you using erin Freud-Frasay games is that the class of even set power sets however is not first-order definable so we we can't define the set of the class of set power sets with an even number of atoms okay and the way I'm going to show this is by considering again a pair of structures a and b where a is set power sub n and b is set power of n plus one and I'm so so one of those is even and one of them is odd but I'm going to show that duplicator has a winning strategy in the in the log n round erin Freud-Frasay game okay so this this establishes that the set of set power sets is not first-order definable and again I'm I'm going to give illustrate this strategy visually okay so so here's here's the here's the picture of the structures a and b so you we can see that a and b have the two sorts the set of atoms and then some cloud of sets and b has one extra element here this this this is kind of gray dot in the middle okay so we're going to give a winning strategy for log n rounds so let's let's say that in in in the first round of the game spoiler picks an element in the set sort of a and it happens to be this set of four elements okay so what should what should the spoilers reply be what element of b should he play well he'll play any any set of four elements in b and the key point is that four is less than half of the of the elements so now in the next round of the game let's say that spoiler plays this this blue set which contains three points and it intersects this red set in one point and has two other points but now you know it's it okay so so here duplicator will play a kind of similar configuration in the in the structure a and so far everything looks looks nice because these two sets are both kind of small contain fewer than half the elements but now in the next round let's say that spoiler moves back to the structure a and plays this green set which contains everything but two elements in a so now instead of matching the size of this set exactly will play something which matches the complement of this set so we'll play everything but but two points in the structure b and okay so now let's say there's this yellow set we match and keeps going like this so now at this point we have two sets which differ by you know one has two elements one has three elements and now will spoil it will start playing in the atom sort and okay so at this point in the game so far we have this partial isomorphism but then in the next round spoiler can win by playing this this blue point and then duplicator has no reply so okay I hope this this illustrates the general principle behind the winning strategy but so the kind of exercises to show that you can you can take the intuition here and and show formally that if a has n elements b has n plus one elements then then duplicator really can win can hold out for log n rounds so basically the the what the property that duplicator tries to preserve is that if you look at the sets which have been played you look at all Boolean combinations of those sets in one structure and the other structure and you want to match the sizes of those up to some parameter which is decreasing by a factor of two as you go along in the game so that's how you can make this formal okay so that so we just showed that the set of even set power set structures is not first order definable and now I'm going to give an application of this result to to show something nice about a variant of first order logic known as ordering variant first order logic okay so so here's a definition so we have a first order sentence fee which involves some extra some additional binary relation symbol which which is supposed to be a linear order okay so we'll say that this sentence is ordering variant if for every unordered finite structure a so for every finite structure a without a linear order if we take any two linear orders on a then a with the with the additional first linear order satisfies fee if and only if a satisfies fee with addition to you know when we add the second linear order so in other words the first order sent a first order sentence which speaks about a extra linear order is order invariant if and only if it doesn't depend on the choice of order that you put on the on the structure okay so so we say that a class of C of finite structures is order invariantly definable or it's definable in order invariant first order logic if there exists some order invariant sentence fee such that a a structure a an unordered structure a belongs to C if and only if a together with any an arbitrary linear order on a belongs models fee okay okay so now I want to show that the class of even set power set structures which we we just showed it's not first order definable but I want to show now that in fact it's order invariantly first order definable so the first order definable in order invariant first order logic so we've already defined the set of all set power set structures in first order logic so all we need to do is define the the set of even ones within that class and how do we do that if we're given some arbitrary linear order on the entire universe so recall that in the universe of these structures is a disjoint union of sorry that where it says elements should be atoms so atoms and sets so we have some linear order on this but of course it induces by restriction a linear order on the set of atoms alone so but now to define evenness of the set of atoms we can say the following basically there exists some set which contains every other atom so it contains the first at the minimal it contains the minimal atom according to this linear order it does not contain the maximum atom in this linear order and for every two consecutive atoms it contains exactly one of them okay so okay so this is something which can will hold if and only if the number of atoms is even okay so what we've what we've shown is this result of of Gravich that order invariant definability is more powerful than than ordinary first order definability so we've given an example which shows this and so this result has is kind of some application to to relational database theory so I'll mention this briefly the so in in database theory people of course consider relational database abstractly but in fact any physical you know in implementation of a relational database will impose some extra relation on data so for example a linear order or some or some successor relation and kind of question that arises as well is it possible to exploit this this extra structure in some query language like a SQL which you can think of as being like first order logic in some kind of representation independent fashion so if you're going to make use of this some some extra linear order imposed on your data well you know you'd want to make sure that you're not you know since that's something which depends not on the database itself but the representation you you want to make sure that you're not sensitive to the choice of linear order so so this this question you know when you translate it into what into the finite model theory language is precisely asking if order invariant definability is more powerful than first-order definability so so if instead of order invariance you could consider some other kind of auxiliary relation and ask about invariance with respect to that so one one one other question that people had asked is if what about invariance with respect to an auxiliary successor relation and some a result of mine is that even successor invariant definability turns out to be more powerful than first-order definability and the counter example is kind of based on grave it just counter example but it has some extra ingredients so it combines various you know standard erinfoid-frase games on set power sets on long paths on random graphs so it's kind of a nice application of many different erinfoid-frase games okay so that that's the concludes what I wanted to say about erinfoid-frase games and now I'll move on to the to the main part of the talk which will be about logic and random structures so zero one laws in particular so the study of asymptotic properties of logical expressions is a one major area in finite model theory and so here I'll discuss the I'll give a proof of the the classic zero one law and then I'll mention some connections to actually to computational complexity okay so so I'm sure you're familiar but the definition of air dish rainy random graph GNP is so this is a random graph with vert you know with n vertices vertex at 1 to n in which for every pair of vertices we independently put it connect them by an edge with probability p so we flip some biased coin independently for every pair of vertices and add an edge with probability p and so in in this talk I'll consider two you know two kind of versions of this so the uniform random graph is where we you know each edge is included with probability one half so this is denoted g and one half and I'll also be mentioning some results which which concern air dish rainy random graphs GNP where p looks like n to the minus alpha for some constant alpha between zero and one okay so this is these are particular model of sparse random graphs okay so the the classic zero one law for first order logic which is which is proved independently by by Fagan and also in Soviet Union well so the zero one law says that with respect to the uniform random graph g g and one half for every first order sentence fee if you look at the probability that g and one half satisfies fee then that that tends to either to zero or to one okay so every first order sentence holds either hold asymptotically almost surely or its negation holds asymptotically almost surely with respect to the random graph okay and I'm gonna give a proof of this so the the proof of this zero one law uses the following graph property known as k extendability of the k extension property which I'll denote by x sub k okay so this property says that for every set s of at most k minus 1 vertices and every subset of s every subset t of s we can find some vertex in the graph outside of s which is adjacent to everything in t and non-adjacent to everything in s minus t so so that's the statement and okay so kind of just illustrate this for the four extension axiom says that for every three vertices for instance this this red yellow and blue vertices then for every subset of those vertices is witnessed by in terms of adjacency to some other vertex in the graph so for every three vertices we can find eight vertices where you know one is not adjacent to anything one is adjacent to all three and for every subset we can we can witness it okay so so that's x sub k so so the first lemma about this k k extendability is that if we have two graphs g and h which are both k extendable then they're k equivalent they satisfy the same first order sentences up to quantifier rank k and this is something we can show very easily by considering the erinford-frase game so what we have to do is take take two k extendable graphs g and h and give a winning strategy for duplicator in the k-round game and this is this is a extremely simple because all we all we need to do is just match partial isomorphism in each round so you know if if spoiler plays some yellow element which has an edge then we can find a yellow element which has an edge and similarly if he plays a blue element which has an edge only to the yellow and not to the red well then there exists some blue element which hasn't you know is adjacent only to the yellow and not to the red simply by by this k extendability and and so on and we can just match partial isomorphism for k rounds okay and now the second key lemma about this k extendability is that well the uniform random graph g and one half is almost surely k extendable okay so so here's here's the proof of it so I'm gonna look at the probability that a random graph g and one half is not k extendable I'm gonna show that that tends to zero okay so so the the event that g is not k extendable is the you know the union of events that g does not satisfy the k extension axiom with respect to some particular s and t in the definition so we just use a simple union bound and this is at most the sum over overall overall s and t right so s is a set of size at most k and t is a subset of s that g does not satisfy the k extension property with respect to that s and t okay and just what that what that literally means is that that for for every x which is not outside of the set s that I either x has an edge to something which is an s minus t or an or it's not adjacent to something in t okay but by independence that probability looks like a one half to the n minus k exactly and the number of such pairs s and t is at most n to the k times 2 to the k something like that so so we get a bound of the form something like 4nk over 2 to the n and for since k is fixed this goes to this goes to zero as n grows okay so we've proved that almost surely g is k extendable okay and now this gives us our proof of the zero one law so I'm going to give a slightly different statement actually of the zero one law so so the the zero one law here that I stated before says for every fee first-order sentence fee it's it's limiting probability is either zero or one but we can actually look at there's a kind of equivalent formulation of this in terms of two independent random graphs g and h so the zero one law I claim is equivalent to the following statement that for every first-order formula fee almost surely g satisfies fee if and only if h satisfies fee so talking about two independent uniform random graphs and yeah this this follows formally because if you look at the probability that g satisfies fee if and only if h satisfies fee this is the probability that g satisfies fee squared plus one minus probability that g satisfies fee squared and if this you know tends to zero or one and then this one tends to one okay so here's the proof now of the zero one law so okay let k be the quantifier rank of our sentence fee and take two independent random graphs g and h so almost surely they're both k extendable therefore they're k equivalent and therefore one satisfies fee if and only if the other satisfies fee okay so this proves the the you know the equivalent statement of our zero one law is that clear okay so now I'm going to talk about some some some other zero one laws just just mention them not going into any proofs so a very a very interesting beautiful result of shale on Spencer gives a zero one law for first-order logic with respect to the random graph GN n to the minus alpha where alpha is any irrational number between zero and one and here it's actually essential that alpha is irrational I'll come back to that in a moment but so this so first-order logic has a zero one law for such graphs another very very very interesting result which is not a zero one law but is known as a convergence law is for first-order logic with respect to a random unary function so so here we consider structures consisting of some finite set and a random unary function on that set and this is a this this is a result due to Lynch so for every first order sentence fee in the language of unary function there's there's some real numbers see some limit between zero and one such that the probability that for that a random unary function on n elements satisfies fee tends to that see and moreover the limiting probability see is an expression that you can write write down using integer you know constants and operations plus times divides and X okay but there are there are other settings where we can say that there's in fact no zero one law and not even any convergence law so first of all if we look at instead of just random graph where the only relation is adjacency but let's say we look at random graphs ordered random graphs of random graph together with a linear order then clearly that first order logic has no zero one law because we can express the sentence you know we can express that there exists an edge between the first and second vertices in this linear order so that has limit probability one half but we can ask well but maybe there's some convergence law still so maybe there's some limit probability for every sentence and in fact that's that's not the case so there exists a first-order sentence in the language of ordered graphs such that the probability that a n vertex ordered graph satisfies fee does not converge and similarly if we look at a rational a rational number alpha between zero and one then then there's a first-order sentence in the language of unordered graph such that g and n to the minus alpha of the limit probability that that satisfies the probability that that satisfies feed is not converge and similarly if we look at instead of random unary function but if we look at a random binary function then again we have a non-convergence there's no convergence law and each of these counter examples has something in common which is that they they show that you can in such random structures with high probability you can interpret some very small initial segment of arithmetic and then say and then which lets you somehow speak about the size of the structure so that's how you get some some non-convergence okay so now I want to mention a an interesting open question so I already defined for you the order and very first-order logic so very interesting open question is whether this logic has a zero one law so that's that's a okay so now let me discuss a different kind of convergence law so so now I'm going to look at an extension of first-order logic by a what's known as a parity quantifier mod to quantifier so the way that mod to quantifier works is that for a formula phi with us with some free variable x then we can form a formula of the form mod to x of of phi so this expresses that phi of x holds for an even number of x okay so this logic is only well-defined on finite structures but so this is an extension of first-order logic by mod to quantifier and a very nice recent result of colitis and coparty gives what's called a modular convergence law for this logic f o parity so the modular convergence law says that for every first-order sentence phi in this lot and in f o mod 2 there exists two constants a sub 0 and a sub 1 such that the limit probability so you know the probability that GN 1 half satisfies phi as you take large you know a large even integer n tends to a 0 and the probability for for large odd numbers n tends to a 1 so this so there's you know two two can two limits and this result actually holds for any mod p quantifier for p being any prime and in which case you get p limiting probabilities and the proof is very nice because it takes it combines techniques from complexity theory and algebra as well as logic so in particular involves approximation by low degree polynomials and the Gowers norm and quantifier elimination so that's a very nice result and one one open question coming out of that work is whether there exists a similar modular convergence law if rather than a mod mod p quantifier for some prime p if we have for instance a mod 6 quantifier or you know you know for any composite number or indeed any prime power is also open so I think in a moment I'll talk about connections to circuit complexity but you know some of you may be familiar with this you know they're open open questions still about this AC0 with mod 6 quantifiers and in my mind getting a result about first order logic with mod 6 quantifiers would potentially shed some some some light on the AC0 with mod 6 quantifiers so it's a very interesting question okay so now I want to talk about correlated you know some make an analogy between zero one laws and actually complexity theory by talking about correlated pairs of random structures so so in this slide this is a repeat of the previous slide where I'm giving the zero one law the two formulations I had of the zero one law so when G and H were independent random structures then the zero one law says that almost surely G you know for every first order sentence fee G satisfies fee if and only if H satisfies fee okay so that's for independent random structures G and H and in fact it follows from this that we we we get in fact if we take G and H not to be independent random structures but we're going to to take a correlated pair of random structure so so we're going to condition on G and H differing at exactly one edge so that the symmetric difference between the edge sets of G and H is exactly one even if we condition this way then then still for random for any first order sentence fee G satisfies fee if and only if each satisfies fee almost surely so this I'll you know refer to as a kind of correlated zero one law and it just follows formally from the previous thing so that's where that's talking about the language of unordered graphs so now it follows actually for any constant it also follows just from this yeah okay so but now the question is so what if we add some background relations now to our graphs G and H so such as a linear order or arithmetic then what happens to these to this zero one law this correlated zero one law for such graphs so okay so so here's the question so so now I'm going to add to the background of our graphs G and H I'm going to add some arithmetic predicates so plus times in a linear order and what happens to this zero one law to this correlated zero one law well you know we already saw that the zero one law failed if you have a linear order because you can you can talk about you know they're an edge between first and second elements in the graph but the the amazing fact is that this this correlated zero one law turns out to hold if you if you have a rhythmic even if you have arithmetic in the background and and in fact you know this this correlated zero one law for random graphs with with with the plus and times is in fact you know kind of hiding a statement about circuit complexity and in fact it kind of directly implies that the parity is not in AC zero so so sorry so so we so we're taking random graphs G and H conditioned on G and H differing at exactly one edge so this is the symmetric difference between the edge set of G and edge set of H or in other words you can you can first take a uniform random G and then take a uniform random edge and flip it that's how you get H so the first the first two statements here are just the zero one law that we saw before so here we're talking about independent random G and H and the point I'm making is that the zero one law implies directly implies this weaker statement which is saying that if G and H are not independent but but they differ at one edge then then still we have this this kind of correlated version of zero one law so then in the next slide I'm saying I'm looking at G and H but now I'm enriching the I'm adding extra relations so now we can also talk about a plus times and a linear order on on the universe of this of these random graphs and then I'm making the point that the zero one law fails so the zero one law is becomes false but this this this weaker correlated zero one law continues to hold even if we even if we're allowed to talk about these background relations okay no this is this is for sex this is this is a disguised version this is literally equivalent to the statement that eight that you know D log time uniform AC zero has average sensitivity you know little of one is exactly equivalent yeah I'm just I'm just trying to you know this way of explaining zero one law and correlated zero one law is my my own you know I guess I guess so sorry I'm trying to draw some kind of analogy between the two things yeah I don't know if it's you know I'm not claiming it's a particularly fruitful way of looking at this but I think it's an interesting new you know you know you could look at different degrees of correlation and try to you know try to bridge the gap but anyway I think there's some relation yeah okay so okay so now in the last part of the talk I'm going to describe some connections to circuit complexity okay so this is the famous diagram from Imerman's book on descriptive complexity okay so so so as we heard in the new just talk so descriptive complexity is concerned with the characterization of complexity classes using logic and so the the you know a typical result in this field is that this Fagan's theorem that says that existential second order logic captures the complexity class NP and in this talk I'm concerned with first order logic and there's a very nice descriptive complexity characterization of first order logic in terms of the complexity class AC zero or constant polynomial size Boolean circuits okay so let me let me just give the definition of Boolean circuits and here since I'm talking about properties of graphs I'll be considering Boolean circuits which take n vertex graphs as inputs so there will be you know n choose two variables you know x of ij which which you know indicate the presence of an edge between vertices i and j and then the circuit is built up out of and or not gates where the and and or gates can have you know unbounded fan in so any number of wires coming in and then there'll be a single designated output gate so every such circuit computes a function from n vertex graphs to zero one so some Boolean function and AC zero denotes the complexity class of languages recognized by constant depth polynomial size families of Boolean circuits okay so the the descriptive complexity result saying first order logic equals AC zero is following result actually maybe maybe there this is kind of discovered independently by different people with slightly different formulations but so the result is that so for every first order formula fee there's some constant depth Boolean circuit of polynomial size which basically evaluates you know computes whether fee is true or false given some encoding of a structure of size and okay so I'm not going to go into this is a bit a bit hand wavy the statement but okay so the as I was saying before so this is here I've just written that from from the last slide in the previous part this kind of correlated zero one law for these structure so as I said this is this is a you know directly translates in via this descriptive complexity characterization into the statement that you know every Boolean function in uniform AC zero has average sensitivity little low of n so this implies parity is not an AC zero for instance okay so actually we can refine this this this kind of characterization even further by looking at a relating the certain parameter of Boolean of first order formulas called width so this corresponds to circuit size I'll define it I'll define width in the next slide but but if you look at the if you look at the this construction if you have a first order formula fee with width k then then the equivalent circuit you get will have size order of n to the k okay so so what is the width of a yeah so in yeah so in this that yeah so so fo with bit is equivalent to fo with plus times in linear order or even the plus times it's all equivalent so when I you know when I talk about uniform AC zero so yeah so so so the so in fact you know their versions of this equivalence for uniform AC zero or non-uniform AC zero but in fact if you have AC zero on structures with a bit predicate then this is giving you d log time uniform AC zero so that yeah but for this talk actually you know for what I'm going to talk about actually I'm non-uniform AC zero everything will apply to non-uniform AC zero okay so so the width of a first order formula is the maximum number of free variables in any sub formula okay so equivalently a formula has width at most k if and only if it's equivalent via some renaming of the of the variables to a formula which has at most k distinct variable symbols and here's an example of that so consider the following formula which will be in the language of ordered graph and it will say that there exists an increasing path of length 5 so the formula just says well there exists x1 and x2 where x1 is less than x2 and there's an edge and there's an x3 which is greater than x2 and an edge to x2 and so on so there's some increasing path of length 5 in the ordered graph so I claim that this formula actually has width 2 there are five variables and but it has width 2 and and we can see this by the fact that we're able to rename these variables and you know in order to have only only two of them okay anyway so so number of variables is also the same thing as width okay and so I'll denote by FO superscript k the set of first-order sentences of width at most k so this is also known as the k variable fragment of first-order logic because you can think of it as a class of formulas with at most k distinct variable names and so this this gives a kind of stratification of first-order logic which is known as the width or variable hierarchy and that there's a version of the erin Freud-Frasay game which characterizes you know rank in this k variable fragment you know this is often called the k pebble game so the basic question that that that you know people have considered is over which classes of finite structures is this this width hierarchy the number of variables hierarchy strict in terms of expressive power so so just for example if we're concerned with a class of all finite structures then it's easy to see that the that the width hierarchy is strict in terms of expressive power because the sentence there exists at least k elements you know the universe has size at least k is something we can express with the by width k formula by a formula k variables but not by a formula with with smaller width so but if we look over the class of finite linear orders with with no additional structure then in fact it's easy to see that the hierarchy collapses to its two variable fragment so in other words every first-order sentence in on the class of finite linear orders is equivalent to a sentence which has only two variables and actually the previous example kind of showed this that you can talk about how large a linear order is by you know just using to recycling two variables and a much harder result shows that over the class of linear colored linear orders or linear orders with with some any number of unary relations the hierarchy collapses to its three variable fragment in fact the fold both for finite colored linear orders and for the class of infinite colored linear orders this is a result of a puzzle and but one question along these lines which had been open for a long time is whether this hierarchy is strict on the class of finite ordered graphs and a natural a natural property to consider in trying to separate this variable is the property of whether if there exists a k click because it's obvious how to define with k variable sentence that there exists a k click in an ordered graph but it's not clear how to do so with fewer than k variables even if you have access to some linear order and if so you know for for k equals two we you know we one can prove explicitly that you know two variables are insufficient to prove to express that there exists a three click and this is something you can show explicitly by playing the two pebble erinfoid frasse game on on the suitable pair of ordered structures for instance if you take these two you know kind of complete binary tree with this with this ordering and then we add an edge like this to make a to make a three click a triangle in the in the bottom graph then you can show by taking large enough structures with only two variables you know you the number of rounds you need to separate these two for a spoiler to win this game is increasing so that shows that three click is not definable with two variables on ordered graphs but this was this was basically the limit of what we know how to prove kind of using explicit erinfoid frasse game yeah so ordered graph i just mean you know there are two relations uh you know in a adjacency relation in a linear order but that you know we require the linear order to define the linear order okay so okay so the the so the result that pretending to this with hierarchy i'm going to give a statement which is kind of in the form of a of a another like correlated version of a zero one law so okay so if we if we consider a random graph at the g and p where p is a threshold probability for the existence of k click so that is g can g this g and p contains a k click with probability exactly one half and it turns out that for that this threshold probability is of the form into the minus alpha for some constant alpha so we consider such a random graph g and that will let h be you know this the the kind of correlated random structure will take g and will uniformly plant a k click somewhere on g so this is a pair of structures where g has a k click with probability one half but h has a k click with probability one but so what i showed is that if you have a sentence fee of width at most k over four then almost surely g together with you know even g satisfies fee if and only if h satisfies fee even if you're allowed to talk about you know arithmetic on the on the vertices of g and h so this is a okay so i'm trying to make an analogy with other correlated zero one law before but you know here here this applies to not all first order sentences but just first order sentences up to width k over four okay so some some correlaries of this result are that well this shows in particular that k click the k click property is not definable with k over four variables on the class of ordered graphs and in fact this even holds in some kind of average case sense so of course this implies that k over four variable fragment is less expressive than the k variable fragment of first order logic on the class of ordered graphs so this shows that the hierarchy the width hierarchy for ordered graphs does not does you know is infinite it doesn't collapse and in fact a a nice corollary of these results which is which is pointed out to me by neal emerman is that the fact that the hierarchy doesn't collapse in fact it implies that it's strict for ordered graphs so for every k there's some property of ordered graphs which is definable with k plus one variable but not with not with k variables okay so so this answers that question about you know width hierarchy for ordered graphs so i wanted to mention some some upper bounds for this problem so in fact this this k over four turns out to be tight in the context of average case definability of k click so amano gave a first order sentence of width k over four plus some constant number of variables in the language of graphs in the language of graphs with arithmetic which almost surely defines the existence of a k click for for this random graph g at the threshold and a recent recent result of of mine still unpublished is that in fact even with if you only have a linear order then still with k over four plus constant many variables you can almost surely define the presence of a k click so that that that kind of shows that the lower bound is really tight for the k click property and i just wanted to mention that you know unlike the the you know two pebble game before where you can give explicit examples of structures this is actually using results in circuit complexity to prove a really proving a lower bound about boolean circuits and then using the descriptive complexity characterization of first order logic to to obtain the result on in lot and you know about first order logic so the the statement of the result in terms of circuits is simply the boolean constant that boolean circuits of size order of n to the k over four cannot solve k click in the average case and just to mention some some things about this result so this this in fact holds not just for constant depth but for depth up up to depth log of n over k squared log log n and this is all really almost tight because if you could improve this to any depth order of log of n over log log n then that would imply a separation of complexity classes nc1 from np and this this result is you know breaks out of what had been known as a size depth tradeoff which was a feature of previous lower bounds for k click on depth d circuits which were not even average case lower bounds but in the worst case so what had been known previously is that for depth d circuits boolean circuits to define k click you needed size omega of n to some constant times k over d squared something like that and the point being that the d's lower bound degrade very rapidly with the with the with the depth whereas the n to the k over four lower bound holds without any decay but only up to a certain d and somehow this this this led to this answered some questions in complexity theory and and led to some kind of size hierarchy theorem for ac0 and just to mention I'm not going to get into the proof at all but just to mention some things about the proof so these the previous lower bounds for the k click problem as indeed many lower bounds for ac0 properties use a technique known as a hostage switching lemma and they use these in a kind of conventional conventional way and you know this is what leads to this this undesirable dependence on the depth parameter d in the exponent of the lower bound so so in my proof I'm using switching lemma it does rely on switching lemma but it's using it in a in a very different way and there's some key new ingredients in in the proof for instance there's a new a new notion of average sensitivity with respect to some kind of shape and and you know somehow we identify a class of bottleneck shapes which is what what's giving this k to the four lower bound so it looks like I'm finishing a little bit early but I wanted to okay so just here's some references you can look at to learn more about about these subjects and finally just let me just repeat the two open questions that I raised in the talk so is there a zero one law for order invariant first order logic and the second question is does this modular convergence law of colitis and co-party hold for for instance first order logic with the mod six quantifier so thank you