graph theory-an introductory course-bela bollobas

194
urauuaie iexis in Mathematics Bela Bollobas Graph Theory An Introductory Course Springer-Verlag

Upload: loorj-rodriguezg

Post on 11-Nov-2014

224 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Graph Theory-An Introductory Course-Bela Bollobas

urauuaie iexisin Mathematics

Bela Bollobas

Graph Theory

An Introductory Course

Springer-Verlag

Page 2: Graph Theory-An Introductory Course-Bela Bollobas

Graduate Texts in Mathematics 63Editorial BoardJ. H. Ewing F. W. Gehring P. R. Halmos

Page 3: Graph Theory-An Introductory Course-Bela Bollobas

Graduate Texts in Mathematics

1 TAKEUTI/ZARING. Introduction to AxiomaticSet Theory. 2nd ed.

3334

HIRSCH. Differential Topology.SPITZER. Principles of Random Walk. 2nd

2 OXTOBY. Measure and Category. 2nd ed. 35 WERMER. Banach Algebras and Several3 SCHAEFFER. Topological Vector Spaces. Complex Variables. 2nd ed.4 HILTON/STAMMBACH. A Course in

Homological Algebra.36 KELLEY/NAMIOKA et al. Linear Topological

Spaces.5 MAC LANE. Categories for the Working

Mathematician.3738

MONK. Mathematical Logic.GRAUERT/FRITZSCHE. Several Complex

6 HUGHES/PIPER. Projective Planes. Variables.7 SERRE. A Course in Arithmetic. 39 ARVESON. An Invitation to C*-Algebras.8 TAKEUTI/ZARING. Axiornetic Set Theory. 40 KEMENY/SNELL/KNAPP. Denumerable Mark

9 HUMPHREYS. Introduction to Lie Algebras Chains. 2nd ed.and Representation Theory. 41 APOSTOL. Modular Functions and Dirichlet

10 COHEN. A Course in Simple Homotopy Series in Number Theory. 2nd ed.Theory. 42 SERRE. Linear Representations of Finite

11 CONWAY. Functions of One Complex Groups.Variable. 2nd ed. 43 GILLMAN/JERISON. Rings of Continuous

12 BEALs. Advanced Mathematical Analysis. Functions.13 ANDERSON/FULLER. Rings and Categories of

Modules. 2nd ed.4445

KENDIG. Elementary Algebraic Geometry.LOEvE. Probability Theory 1. 4th ed.

14 GOLUBITSKY/GUILEMIN. Stable Mappings andTheir Singularities.

4647

Lo`EVE. Probability Theory 11. 4th ed.MOISE. Geometric Topology in Dimension

15 BERBERIAN. Lectures in Functional Analysis and 3.

and Operator Theory. 48 SACHS/WU. General Relativity for16 WINTER. The Structure of Fields. Mathematicians.17 ROSENBLATT. Random Processes. 2nd ed. 49 GRUENBERG/WEIR. Linear Geometry. 2nd I18 HALMOS. Measure Theory. 50 EDWARDS. Fermat's Last Theorem.

19 HALMOS. A Hilbert Space Problem Bcok.2nd ed.

51 KLINGENBERG. A Course in DifferentialGeometry.

20 HUSEMOLLER. Fibre Bundles. 3rd ed. 52 HARTSHORNE. Algebraic Geometry.21 HUMPHREYS. Linear Algebraic Groups. 53 MANIN. A Course in Mathematical Logic.22 BARNES/MACK. An Algebraic Introduction to

Mathematical Logic.54 GRAVER/WATKINS. Combinatorics with

Emphasis on the Theory of Graphs.23 GREUB. Linear Algebra. 4th ed. 55 BROWN/PEARCY. Introduction to Operator24 HOLMES. Geometric Functional Analysis and Theory I: Elements of Functional Analysi:

Its Applications. 56 MASSEY. Algebraic Topology: An25 HEWITT/STROMBERG. Real and Abstract

Analysis. 57Introduction.CROWELL/F0x. Introduction to Knot Then:

26 MANES. Algebraic Theories. 58 KoBLrtz p-adic Numbers, p-adic Analysi;27 KELLEY. General Topology. and Zeta-Functions. 2nd ed.28 ZARISKI/SAMUEL. Commutative Algebra. Vol. 59 LANG. Cyclotomic Fields.

1. 60 ARNOLD. Mathematical Methods in Classi29 ZARISKI/SAMUEL. Commutative Algeba. Vol. Mechanics. 2nd ed.

11. 61 WHITEHEAD. Elements of Homotopy Theo30 JACOBSON. Lectures in Abstract Algebra 1.

Basic Concepts.62 KARGAPOLOV/MERLZIAKOV. Fundamentals

the Theory of Groups.31 JACOBSON. Lectures in Abstract Algebra 11.

Linear Algebra.6364

BOLLOBAS. Graph Theory.EDWARDS. Fourier Series. Vol. 1. 2nd ed.

32 JACOBSON. Lectures in Abstract Algebra III.Theory of Fields and Galois Theory. continued 4fter Uutex

Page 4: Graph Theory-An Introductory Course-Bela Bollobas

Be1a Bollobas

Graph TheoryAn Introductory Course

Springer-VerlagNew York Berlin Heidelberg London Paris

Tokyo Hong Kong Barcelona Budapest

Page 5: Graph Theory-An Introductory Course-Bela Bollobas

Be1a BollobasDepartment of Pure Mathematicsand Mathematical StatisticsUniversity of Cambridge16 Mill LaneCambridge CR2 ISBENGLAND

Editorial BoardJ.H. Ewing F.W. Gehring P.R. HalmosDepartment of Mathematics Department of Mathematics Department of MathematicsIndiana University University of Michigan Santa Clara UniversityBloomington, IN 47405 Ann Arbor, Michigan 48109 Santa Clara, California 95053USA USA USA

Mathematical Subject Classification: 05-01, 05Cxx

With 80 Figures

Library of Congress Cataloging in Publication DataBollobas, Bola.

Graph theory.(Graduate texts in mathematics: 63)Includes index.1. Graph theory. I. Title. II. Series.

QA 166. B662 51V.5 79-10720

All rights reserved. No part of this book may be translated or reproduced in any formwithout written permission from Springer-Verlag, 175 Fifth Avenue, New York,New York, 10010 USA.Printed and bound by R.R. Donnelley and Sons, Harrisonburg, VA.

© 1979 by Springer-Verlag New York Inc.

Printed in the United States of America.

9 8 7 6 5 4

ISBN 0-387-90399-2 Springer-Verlag New York Berlin HeidelbergISBN 3-540-90399-2 Springer-Verlag Berlin Heidelberg New York

Page 6: Graph Theory-An Introductory Course-Bela Bollobas

To Gabriella

Page 7: Graph Theory-An Introductory Course-Bela Bollobas

There is no permanent place in theworld for ugly mathematics.

G. H. HardyA Mathematician's Apology

Page 8: Graph Theory-An Introductory Course-Bela Bollobas

Preface

This book is intended for the young student who is interested in graphtheory and wishes to study it as part of his mathematical education. Ex-perience at Cambridge shows that none of the currently available texts meetthis need. Either they are too specialized for their audience or they lack thedepth and development needed to reveal the nature of the subject.

We start from the premise that graph theory is one of several courseswhich compete for the student's attention and should contribute to hisappreciation of mathematics as a whole. Therefore, the book does notconsist merely of a catalogue of results but also contains extensive descriptivepassages designed to convey the flavour of the subject and to arouse thestudent's interest. Those theorems which are vital to the development arestated clearly, together with full and detailed proofs. The book therebyoffers a leisurely introduction to graph theory which culminates in a thoroughgrounding in most aspects of the subject.

Each chapter contains three or four sections, exercises and bibliographicalnotes. Elementary exercises are marked with a - sign, while the difficultones, marked by t signs, are often accompanied by detailed hints. In theopening sections the reader is led gently through the material: the resultsare rather simple and their easy proofs are presented in detail. The latersections are for those whose interest in the topic has been excited : the theoremstend to be deeper and their proofs, which may not be simple, are describedmore rapidly. Throughout this book the reader will discover connectionswith various other branches of mathematics, including optimization theory,linear algebra, group theory, projective geometry, representation theory,probability theory, analysis, knot theory and ring theory. Although mostof these connections are not essential for an understanding of the book, thereader would benefit greatly from a modest acquaintance with these subjects.

vii

Page 9: Graph Theory-An Introductory Course-Bela Bollobas

Preface

The bibliographical notes are not intended to be exhaustive but rather toguide the reader to additional material.

I am grateful to Andrew Thomason for reading the manuscript carefullyand making many useful suggestions. John Conway has also taught thegraph theory course at Cambridge and I am particularly indebted to him fordetailed advice and assistance with Chapters II and VIII. I would like tothank Springer-Verlag and especially Joyce Schanbacher for their efficiencyand great skill in producing this book.

Cambridge Bela BollobasApril 1979

Page 10: Graph Theory-An Introductory Course-Bela Bollobas

Contents

Chapter IFundamentals 1

1. Definitions 1

2. Paths, Cycles and Trees 63. Hamilton Cycles and Euler Circuits 11

4. Planar Graphs 16

5. An Application of Euler Trails to Algebra 19

Exercises 22

Notes 25

Chapter lIElectrical Networks 26

1. Graphs and Electrical Networks 26

2. Squaring the Square 33

3. Vector Spaces and Matrices Associated with Graphs 35

Exercises 41

Notes 43

Chapter IIIFlows, Connectivity and Matching 44

1. Flows in Directed Graphs 45

2. Connectivity and Menger's Theorem 50

3. Matching 53

4. Tutte's 1-Factor Theorem 58

Exercises 61

Notes 66

ix

Page 11: Graph Theory-An Introductory Course-Bela Bollobas

x Contents

Chapter IVExtremal Problems 67

1. Paths and Cycles 682. Complete Subgraphs 713. Hamilton Paths and Cycles 754. The Structure of Graphs 80

Exercises 84Notes 87

Chapter VColouring 88

1. Vertex Colouring 892. Edge Colouring 933. Graphs on Surfaces 95

Exercises 98Notes 102

Chapter VIRamsey Theory 103

1. The Fundamental Ramsey Theorems 1032. Monochromatic Subgraphs 1073. Ramsey Theorems in Algebra and Geometry 1104. Subsequences 115

Exercises 119Notes 121

Chapter VIIRandom Graphs 123

1. Complete Subgraphs and Ramsey Numbers-The Use of the Expectation 1242. Girth and Chromatic Number-Altering a Random Graph 1273. Simple Properties of Almost All Graphs-The Basic Use of Probability 1304. Almost Determined Variables-The Use of the Variance 1335. Hamilton Cycles-The Use of Graph Theoretic Tools 139

Exercises 142Notes 144

Chapter VIIIGraphs and Groups 146

1. Cayley and Schreier Diagrams 146

2. Applications of the Adjacency Matrix 155

3. Enumeration and P6lya's Theorem 162

Exercises 169

Notes 173

Subject Index 175

Index of Symbols 179

Page 12: Graph Theory-An Introductory Course-Bela Bollobas

CHAPTER I

Fundamentals

The purpose of this introduction is to familiarise the reader with the basicconcepts and results of graph theory. The chapter inevitably contains alarge number of definitions and in order to prevent the reader growingweary we prove simple results as soon as possible. The reader is not expectedto have complete mastery of Chapter I before sampling the rest of thebook, indeed, he is encouraged to skip ahead since most of the terminologyis self-explanatory. We should add at this stage that the terminology ofgraph theory is far from being standard, though that used in this book iswell accepted.

§1 Definitions

A graph G is an ordered pair of disjoint sets (V, E) such that E is a subsetof the set of unordered pairs of V. Unless it is explicitly stated otherwise, weconsider only finite graphs, that is V and E are always finite. The set V isthe set of vertices and E is the set of edges. If G is a graph then V = V(G)is the vertex set of G and E = E(G) is the edge set. An edge {x, y} is said tojoin the vertices x and y and is denoted by xy. Thus xy and yx mean exactlythe same edge, the vertices x and y are the endvertices of this edge. If xy E E(G)then x and y are adjacent or neighbouring vertices of G and the vertices xand y are incident with the edge xy. Two edges are adjacent if they haveexactly one common endvertex.

As the terminology suggests, we do not usually think of a graph as anordered pair, but as a collection of vertices some of which are joined by

1

Page 13: Graph Theory-An Introductory Course-Bela Bollobas

2 I Fundamentals

4

Figure 1.1. A graph.

edges. It is then a natural step to draw a picture of the graph. In fact, some-times the easiest way to describe a graph is to draw it. the graph G =({1, 2, 3, 4, 5, 6}, {12, 14,16, 25, 34, 36, 45, 56}) is immediately comprehendedby looking at Figure 1.1.

We say that G' = (V', E) is a subgraph of G = (V, E) if V' c V andE' c E. In this case we write G' c G. If G' contains all edges of G that jointwo vertices in V' then G' is said to be the subgraph induced or spanned byV' and is denoted by G[V']. A subgraph G' of G is an induced subgraph ifG' = G[V(G')]. If V = V, then G' is said to be a spanning subgraph of G.These concepts are illustrated in Figure 1.2.

We shall often construct new graphs from old ones by deleting or addingsome vertices and edges. If W c V(G) then G - W = G[V\W] is the sub-graph of G obtained by deleting the vertices in Wand all edges incident withthem. Similarly if E' c E(G) then G - E' = (V(G), E(G)\E'). If W = {w}and E' = {xy} then this notation is simplified to G - w and G - xy.Similarly, if x and y are non-adjacent vertices of G then G + xy is obtainedfrom G by joining x to y.

If x is a vertex of a graph G then instead of x E V(G) we usually writex e G. The order of G is the number of vertices; it is denoted by J G1. Thesame notation is used for the number of elements (cardinality) of a set: I X I

denotes the number of elements of the set X. Thus I G I = I V(G) 1. The sizeof G is the number of edges; it is denoted by e(G). We write G" for an

1

6

4 4

Figure 1.2. A subgraph, an induced subgraph and a spanning subgraph of the graphin Figure I.1.

Page 14: Graph Theory-An Introductory Course-Bela Bollobas

§1 Definitions 3

Figure 1.3. Graphs of order at most 4 and size 3.

arbitrary graph of order n. Similarly G(n, m) denotes an arbitrary graph oforder n and size m.

Two graphs are isomorphic if there is a correspondence between theirvertex sets that preserves adjacency. Thus G = (V, E) is isomorphic toG' = (V', E') if there is a bijection 0: V -+ V' such that xy e E ifl 4(x)4(y)EE'.Clearly isomorphic graphs have the same order and size. Usually we donot distinguish between isomorphic graphs, unless we consider graphs witha distinguished or labelled set of vertices (for example, subgraphs of a givengraph). In accordance with this convention, if G and H are isomorphicgraphs then we write either G = H or simply G = H. In Figure 1.3 we showall graphs (within isomorphism) that have order at most 4 and size 3.

The size of a graph of order n is at least 0 and at most (z). Clearly forevery m, 0 S m S (Z), there is a graph G(n, m). A graph of order n and size(2) is called a complete n-graph and is denoted by K"; an empty n-graph E"has order n and no edges. In K" every two vertices are adjacent, while in E"no two vertices are adjacent. The graph K' = E' is said to be trivial.

The set of vertices adjacent to a vertex x e G is denoted by 1"(x). Thedegree of x is d(x) = I r(x) 1. If we want to emphasize that the underlyinggraph is G then we write rG(x) and da(x); a similar convention will be adoptedfor other functions depending on an underlying graph. Thus if x e H = G[W]then

rH(x) = {y e H: xy a E(H)} = rG(x) n W.

The minimum degree of the vertices of a graph G is denoted by b(G) andthe maximum degree by A(G). A vertex of degree 0 is said to be an isolatedvertex. If b(G) = 0(G) = k, that is every vertex of G has degree k then Gis said to be k-regular or regular oJ' degree k. A graph is regular if it is k-regular for some k. A 3-regular graph is said to be cubic.

If V(G) = {x1, x2, ... , x"} then (d(xi))i is a degree sequence of G. Usuallywe order the vertices in such a way that the degree sequence obtained inthis way is monotone increasing or monotone decreasing, for exampleb(G) = d(xt) S ... <_ d(x") = 0(G). Since each edge has two endvertices,the sum of the degrees is exactly twice the number of edges:

n

d(xi) = 2e(G).

In particular, the sum of degrees is even:"

Y d(xi) 0 (mod 2).1

(1)

(2)

Page 15: Graph Theory-An Introductory Course-Bela Bollobas

4 I Fundamentals

This last observation is sometimes called the handshaking lemma, since itexpresses the fact that in any party the total number of hands shaken iseven. Equivalently, (2) states that the number of vertices of odd degree iseven. We see also from (1) that b(G) S L2e(G)/nj and A(G) >- (2e(G)/n].Here LxJ denotes the greatest integer not greater than x and lxi _ -L-xJ.

A path is a graph P of the form

V(P) = {x0, X1, ... , x,}, E(P) = {x0xl, xlx2,... , x,_ lx,}.

This path P is usually denoted by x0x1 ... x,. The vertices x0 and x, are theendvertices of P and I = e(P) is the length of P. We say that P is a pathfrom x0 to x, or an x0-x1 path. Of course, P is also a path from x, to x0 or anx1-x0 path. Sometimes we wish to emphasize that P is considered to gofrom x0 to x, and then call x0 the initial and x, the terminal vertex of P. Apath with initial vertex x is an x-path.

The term independent will be used in connection with vertices, edges andpaths of a graph. A set of vertices (edges) is independent if no two elementsof it are adjacent; a set of paths is independent if for any two paths eachvertex belonging to both paths is an endvertex of both. Thus P,, P2 . ... . P,Eare independent x-y paths if V(P,) n V(P) = {x, y} whenever i 0 j. Also,W c V(G) consists of independent vertices if G[W] is an empty graph.

Most paths we consider are subgraphs of a given graph G. A walk Win Gis an alternating sequence of vertices and edges, say x0, al, x1, a2, ... , a,, x,where a, = x.-I xi, 0 < i < 1. In accordance with the terminology above,W is an x0-x, walk and is denoted by xoxl ... x,; the length of W is 1. Thiswalk W is called a trail if all its edges are distinct. Note that a path is a walkwith distinct vertices. A trail whose endvertices coincide (a closed trail) iscalled a circuit. If a walk W = xoxl ... x, is such that l 3, x0 = x, andthe vertices x,, 0 < i < 1, are distinct from each other and x0 then W is saidto be a cycle. For simplicity this cycle is denoted by X1x2 ... x1. Note thatthe notation differs from that of a path since x1x, is also an edge of thiscycle. Furthermore, x1x2 ... x,, X,x,_1 ... x1, X2x3 ... X,X1, Xixi_1 ...x1x,x,_1 ... xi+1 all denote the same cycle.

The symbol P denotes an arbitrary path of length I and C' denotes acycle of length 1. We call C' a triangle, C° a quadrilateral, C' a pentagon, etc.(See Figure 1.4). A cycle is even (odd) if its length is even (odd).

Given vertices x, y, their distance d(x, y) is the minimum length of anx-y path. If there is no x-y path then d(x, y) = oo.

A graph is connected if for every pair {x, y} of distinct vertices there is apath from x tq y. Note that a connected graph of order at least 2 cannotcontain an isolated vertex. A maximal connected subgraph is a component

Figure I.4. The graphs K', E3, P', C' and C°.

Page 16: Graph Theory-An Introductory Course-Bela Bollobas

§1 Definitions 5

Figure 1.5. A forest.

of the graph. A cutvertex is a vertex whose deletion increases the number ofcomponents. Similarly an edge is a bridge if its deletion increases the numberof components. Thus an edge of a connected graph is a bridge if its deletiondisconnects the graph. A graph without any cycles is a forest or an acyclicgraph; a tree is a connected forest. (See Figure 1.5.) The relation of a tree to aforest sounds less absurd if we note that a forest is a disjoint union of trees;in other words, a forest is a graph whose every component is a tree.

A graph G is a bipartite graph with vertex classes V1 and V2 if V(G) _V1 u V2, V1 n V2 = 0 and each edge joins a vertex of V1 to a vertex of V2.Similarly G is r-partite with vertex classes V1, V2, ... , V, if V(G) = V1 u V2 u

u V V n V = 0 whenever 1 5 i < j < r, and no edge joins twovertices in the same class. The graphs in Figure 1.1 and Figure 1.5 are bi-partite. The symbol K(n1, . . . , n,) denotes a complete r-partite graph: ithas n, vertices in the ith class and contains all edges joining vertices indistinct classes. For simplicity we often write K°"9 instead of K(p, q) andK,(t) instead of K(t, ... , t).

We shall write G u H = (V(G) u V(H), E(G) u E(H)) and kG for theunion of k disjoint copies of G. We obtain the join G + H from G u Hby adding all edges between G and H. Thus, for example, K2.3 = E2 + E3

There are several notions closely related to that of a graph. A hypergraphis a pair (V, E) such that Vn.E = 0 and E is a subset of Y(V), the powerset of V, that is the set of all subsets of V. In fact, there is a simple 1-1 cor-respondence between the class of hypergraphs and the class of certainbipartite graphs. Indeed, given a hypergraph (V, E), construct a bipartitegraph with vertex classes V and E by joining a vertex x e V to a hyperedgeSeEiffxeS.

By definition a graph does not contain a loop, an "edge" joining a vertexto itself; neither does it contain multiple edges, that is several "edges"joining the same two vertices. In a multigraph both multiple edges andmultiple loops are allowed; a loop is a special edge.

If the edges are ordered pairs of vertices then we get the notions of adirected graph and directed multigraph. An ordered pair (a, b) is said to bean edge directed from a to b, or an edge beginning at a and ending at b, andis denoted by 56 or simply ab. The notions defined for graphs are easilycarried over to multigraphs, directed graphs and directed multigraphs,mutatis mutandis. Thus a (directed) trail in a directed multigraph is an

Page 17: Graph Theory-An Introductory Course-Bela Bollobas

6 I Fundamentals

alternating sequence of vertices and edges: x0, e1, x1, e2, .... el, x1, such thatei begins at xi _ 1 and ends at xi.

An oriented graph is a directed graph obtained by orienting the edges,that is by giving the edge ab a direction aa1 or h-a. Thus an oriented graph isa directed graph in which at most one of as and occurs.

§2 Paths, Cycles and Trees

With the concepts defined so far we can start proving some results aboutgraphs. Though these results are hardly more than simple observations,and our main aim in presenting them is to familiarize the reader with theconcepts, in keeping with the style of the other chapters we shall call themtheorems.

Theorem 1. Let x be a vertex of a graph G and let W be the vertex set of acomponent containing x. Then the following assertions hold.

i. W = (y e G: G contains an x-y path).ii. W = {y e G: G contains an x-y trail}.iii. W = {yeG:d(x,y) < cc}.iv. For u, v E V = V(G) put uRv iff uv E E(G), and let 1 be the smallest

equivalence relation on V containing R. Then W is the equivalence classof X.

This little result implies that every graph is the vertex disjoint union of itscomponents (equivalently, every vertex is contained in a unique component),and an edge is a bridge if it is not contained in a cycle.

Theorem 2. A graph is bipartite if it does not contain an odd cycle.

PROOF. Suppose G is bipartite with vertex classes V, and V2. Let x1x2 ... X1be a cycle in G. We may assume that x, e V1. Then x2 e V2, X3 a V1, andso on: xi a V1 if i is odd. Since x, a V2, we find that l is even.

Suppose now that G does not contain an odd cycle. Since a graph isbipartite if each component of it is, we may assume that G is connected.Pick a vertex x e V(G) and put V, = (y:d(x, y) is odd ] , V2 = V\ V. There is noedge joining two vertices of the same class V, since otherwise G would containan odd cycle. Hence G is bipartite.

Theorem 3. A graph is a forest if for every pair {x, y} of distinct vertices itcontains at most one x-y path.

PROOF. If x1x2 ... X1 is a cycle in a graph G then x1x2 ... x, and x,x, aretwo x1-x, paths in G.

Page 18: Graph Theory-An Introductory Course-Bela Bollobas

§2 Paths, Cycles and Trees 7

Conversely, let Pt = x0x1 ... x, and P2 = xoY1Y2 . Ykxi be twodistinct x0-x, paths in a graph G. Let i + 1 be the minimal index for whichxi+ 1 96 Yi+ , and let j be the minimal index for which j Z i and yj+ 1 is avertex of P1, say yj+1 = xh. Then xixi+ 1 ... xhY;Yj-1 Yi+ 1 is a cycle in G.

Theorem 4. The following assertions are equivalent for a graph G.

i. G is a tree.ii. G is a minimal connected graph, that is G is connected and if xy e E(G)

then G - xy is disconnected. [In other words, G is connected and everyedge is a bridge.]

iii. G is a maximal acyclic graph, that is G is acyclic and if x and y are non-adjacent vertices of G then G + xy contains a cycle.

PROOF. Suppose G is a tree. Let xy a E(G). The graph G - xy cannot containan x-y path xz1z2 ... ZkY since otherwise G contains the cycle xz1z2 ... zky.Hence G - xy is disconnected and so G is a minimal connected graph.Similarly if x and y are non-adjacent vertices of the tree G then G contains apath xz1z2 ... zky and so G + xy contains the cycle xz1z2 ... zky. HenceG + xy contains a cycle and so G is a maximal acyclic graph.

Suppose next that G is a minimal connected graph. If G contains a cyclexz1z2 ... zky then G - xy is still connected since in any u-v walk in Gthe edge xy can be replaced by the path xz1z2 ... zky. As this contradictsthe minimality of G, we conclude that G is acyclic so it is a tree.

Suppose finally that G is a maximal acyclic graph. Is G connected? Yes,since if x and y belong to different components, the addition of xy to Gcannot create a cycle xz1z2 ... zky since otherwise the path xz1z2 ... zky isin G. Thus G is a tree.

Corollary 5. Every connected graph contains a spanning tree, that is a treecontaining every vertex of the graph.

PROOF. Take a minimal connected spanning subgraph.

There are several simple constructions of a spanning tree of a graph G;we present two of them. Pick a vertex x and put Y = {y e G: d(x, y) = i},i = 0, 1, .... Note that if yi e Y, i > 0, and xz1z2 ... zi_ 1yi is an x-yi path(whose existence is guaranteed by the definition of V) then d(x, zj) = j forevery j, 0 < j < i. In particular, Vj 0 for 0 S j -< i and for every y e Vi,i > 0, there is a vertex y' c- Y_ 1 joined to y. (Of course, this vertex y' isusually not unique but for each y x we pick only one y'.) Let T be thesubgraph of G with vertex set V and edge set E(T) = {yy': y # x}. Then Tis connected since every y e V - {x} is joined to x by a path yy'y" ... X.Furthermore, T is acyclic since if W is any subset of V and w is a vertex inW furthest from x then w is joined to at most one vertex in W. Thus T is aspanning tree.

Page 19: Graph Theory-An Introductory Course-Bela Bollobas

8 1 Fundamentals

The argument above shows that with k = maxy d(x, y) we have Y 0for 0 5 i < k and V = V(G) = lJo l;. At this point it is difficult to resistthe remark that diam G = maxi, y d(x, y) is called the diameter of G andrad G = minx maxy d(x, y) is the radius of G.

If we choose x e G with k = maxy d(x, y) = rad G then the spanningtree T also has radius k.

A slight variant of the above construction of T goes as follows. Pickx e G and let T, be the subgraph of G with this single vertex x. Then T, is atree. Suppose we have constructed trees T, c T2 c - c Tk c G, whereTi has order i. If k < n = I G I then by the connectedness of G there is avertex y c- V(G) - V(Tk) that is adjacent (in G) to a vertex z E Tk. Let Tk+ t

be obtained from Tk by adding to it the vertex y and the edge yz. Then Tk+ tis connected and as yz cannot be an edge of a cycle in T,,, 1, it is also acyclic.Thus Tk+, is also a tree, so the sequence To c T, c ... can be continuedto T,,. This tree T is then a spanning tree of G.

The spanning trees constructed by either of the methods above haveorder n (of course!) and size n -- 1. In the first construction there is a 1-1correspondence between V - {x? and E(T), given by y - yy', and in thesecond construction e(Tk) = k -- 1 for each k since e(T) = 0 and Tk+ thas one more edge than Tk. Since by Theorem 4 every tree has a uniquespanning tree, namely itself, we have arrived at the following result.

Corollary 6. A tree of order n has size n - 1; a forest of order n with k com-ponents has size n - k.

The first part of this corollary can be incorporated into several othercharacterizations of trees. In particular, a graph of order n is a tree if it isconnected and has size n - 1. The reader is invited to prove these character-izations (Exercise 9).

Corollary 7. A tree of order at least 2 contains at least 2 vertices of degree 1.

PROOF. Let d, < dZ < ... < d be the degree sequence of a tree T of ordern > 2. Since T is connected, b(T) = d, >- 1. Hence if T had at most onevertex of degree 1, by (1) and Corollary 6 we would have

2e(T)=2n-2d;>-1+2(n-1).ft

A well known problem in optimization theory asks for a relatively easyway of finding a spanning subgraph with a special property. Given a graphG = (V, E) and a positive valued cost function f defined on the edges,

f : E R', find a connected spanning subgraph T = (V, E') of G for which

.f (T) = E .f (xy)xyeE'

Page 20: Graph Theory-An Introductory Course-Bela Bollobas

§2 Paths, Cycles and Trees 9

is minimal. We call such a spanning subgraph T an economical spanningsubgraph. One does not need much imagination to translate this into a"real life" problem. Suppose certain villages in an area are to be joined to awater supply situated in one of the villages. The system of pipes is to consistof pipelines connecting the water towers of two villages. For any two villageswe know how much it would cost to build a pipeline connecting them,provided such a pipeline can be built at all. How can we find an economicalsystem of pipes?

In order to reduce the second problem to the above problem aboutgraphs, let G be the graph whose vertex set is the set of villages and in whichxy is an edge if it is possible to build a pipeline joining x to y; denote thecost of such a pipeline by f (xy) (see Figure 1.6). Then a system of pipescorresponds to a connected spanning subgraph T of G. Since the system hasto be economical, T is a minimal connected spanning subgraph of G, that is aspanning tree of G.

The connected spanning subgraph T we look for has to be a minimalconnected subgraph since otherwise we could find an edge a whose deletionwould leave T connected and then T - a would be a more economicalspanning subgraph. Thus T is a spanning tree of G. Corresponding to thevarious characterizations and constructions of a spanning tree, we haveseveral easy ways of finding an economical spanning tree; we shall describefour of these methods.

(1) Given G and f : E(G) -+ I, we choose one of the cheapest edges of G,that is an edge a for which f (a) is minimal. Each subsequent edge will bechosen from among the cheapest remaining edges of G with the only re-striction that we must not select all edges of any cycle, that is the subgraph ofG formed by the selected edges is acyclic.

The process terminates when no edge can be added to the set E' of edgesselected so far without creating a cycle. Then T, = (V(G), E') is a maximalacyclic subgraph of G so, by Theorem 4(iii) it is a spanning tree of G.

(2) This method is based on the fact that it is foolish to use a costly edgeunless it is needed to ensure the connectedness of the subgraph. Thus let usdelete one by one those costliest edges whose deletion does not disconnectthe graph. By Theorem 4(ii) the process ends in a spanning tree T2.

4

Figure I.6. A graph with a function f: E R+; the number next to an edge xy is thecost f (xy) of the edge.

Page 21: Graph Theory-An Introductory Course-Bela Bollobas

10 I Fundamentals

(3) Pick a vertex x, of G and select one of the least costly edges incidentwith x,, say x,x2. Then choose one of the least costly edges of the form xix,where 1 < i S 2 and x 0 {x1, x2}. Having found vertices x1, x2, . . ., xkand an edge xix;, i < j, for each vertex xj with j < k, select one of the leastcostly edges of the form xix. say xixk+, where 1 < i < k andxk+ 1 0 {x,, x2, ... , xk}. The process terminates after we have selectedn - 1 edges. Denote by T3 the spanning tree given by these edges. (SeeFigure 1.7.)

1 1 1

Figure 1.7. Three of the six economical spanning trees of the graph shown in Figure 1.6.

(4) This method is applicable only if no two pipelines cost the same. Theadvantage of the method is that every village can make its own decision andstart building a pipeline without bothering to find out what the other villagesare going to do. Of course, each village will start building the cheapestpipeline ending in the village. It may happen that both village x and village ywill build the pipeline xy; in this case they meet in the middle and end upwith a single pipeline from x to y. Thus at the end of this stage some villageswill be joined by pipelines but the whole system of pipes need not be con-nected. At the next stage each group of villages joined to each other by pipe-lines finds the cheapest pipeline going to a village not in the group and beginsto build that single pipeline. The same procedure is repeated until a connectedsystem is obtained. Clearly the villages will never build all the pipes of acycle so the final system of pipes will be a spanning tree (See Figure 1.8.)

Theorem 8. Each of the four methods described above produces an economicalspanning tree. If no two edges have the same cost then there is a unique econo-mical spanning tree.

4+eFigure 1.8. The graph of Figure 1.6 w.ith a slightly altered cost function (0 < e <and its unique economical spanning tree.

Page 22: Graph Theory-An Introductory Course-Bela Bollobas

§3 Hamilton Cycles and Euler Circuits 11

PROOF. Choose an economical spanning tree T of G that has as many edgesin common with T, as possible. (T, is the spanning tree constructed by thefirst method.)

Suppose that E(T,) # E(T). The edges of T, have been selected one byone; let xy be the first edge of T, that is not an edge of T. Then T contains aunique x-y path, say P. This path P has at least one edge, say uv, that doesnot belong to T,, since otherwise T, would contain a cycle. When xy wasselected as an edge of T1, the edge uv was also a candidate. As xy was chosenand not uv, the edge xy can not be costlier than uv, that is f (xy) < f (uv). ThenT' = T - uv + xy is a spanning tree and since f (T') = f (T) - f (uv) +f(xy) < f(T), T' is an economical spanning tree of G. (Of course, thisinequality implies that f (T') = f (T) and f (xy) = f (uv).) This tree T' hasmore edges in common with T, than T, contradicting the choice of T. HenceT = T, so T, is indeed an economical spanning tree.

Slight variants of the proof above show that the spanning trees T2 andT3, constructed by the second and third methods, are also economical. Weinvite the reader to furnish the details (Exercise 19).

Suppose now that no two edges have the same cost, that is f (xy) # f (uv)whenever xy # uv. Let T4 be the spanning tree constructed by the fourthmethod and let T be an economical spanning tree. Suppose that To T4,and let xy be the first edge not in T that we select for T4. The edge xy wasselected since it is the least costly edge of G joining a vertex of a subtreeF of T4 to a vertex outside F. The x-y path in T has an edge uv joining avertex of F to a vertex outside F so f (xy) < f (uv). However, this is impos-sible since T' = T - tit, + xy is a spanning tree of G and f (T) < f (T).Hence T = T4. This shows that T4 is indeed an economical spanning tree.Furthermore, since the spanning tree constructed by the fourth method isunique, the economical spanning tree is unique if no two edges have thesame cost.

§3 Hamilton Cycles and Euler Circuits

The so-called travelling salesman problem greatly resembles the economicalspanning tree problem discussed in the preceding section, but the similarityis only superficial. A salesman is to make a tour of n cities, at the end of whichhe has to return to the head office he starts from. The cost of the journeybetween any two cities is known. The problem asks for an efficient algorithmfor finding a least expensive tour. (As we shall not deal with algorithmicproblems, we leave the term "efficient" undefined; loosely speaking analgorithm is efficient if the computing time is bounded by a polynomial inthe number of vertices.) Though a considerable amount of work has beendone on this problem, since its solution would have important practical

Page 23: Graph Theory-An Introductory Course-Bela Bollobas

12 I Fundamentals

Figure 1.9. A Hamiltonian cycle in the graph of the dodecahedron.

applications, it is not known whether or not there is an efficient algorithmfor finding a least expensive route.

In another version of the travelling salesman problem the route is requiredto be a cycle, that is the salesman is not allowed to visit the same city twice(except the city of the head office). A cycle containing all the vertices of agraph is said to be a Hamilton cycle of the graph. The origin of this term is agame invented in 1857 by Sir William Rowan Hamilton based on theconstruction of cycles containing all the vertices in the graph of the dode-cahedron (see Figure 1.9). A Hamilton path of a graph is a path containingall the vertices of the graph. A graph containing a Hamilton cycle is said tobe Hamiltonian.

In fact, Hamilton cycles and paths in special graphs had been studied wellbefore Hamilton proposed his game. In particular, the puzzle of the knight'stour on a chessboard, thoroughly analysed by Euler in 1759, asks for aHamilton cycle in the graph whose vertices are the 64 squares of a chessboardand in which two vertices are adjacent if a knight can jump from one squareto the other. Figure 1.10. shows two solutions of this puzzle.

If in the second, more restrictive version of the travelling salesman problemthere are only two travel costs, 1 and oo (expressing the impossibility of thejourney), then the question is whether or not the graph formed by the edgeswith travel cost 1 contains a Hamilton cycle. Even this special case of thetravelling salesman problem is unsolved: no efficient algorithm is known

7

Figure I.10. Two tours of a knight on a chessboard.

Page 24: Graph Theory-An Introductory Course-Bela Bollobas

§3 Hamilton Cycles and Euler Circuits 13

Figure I.11. Three edge-disjoint Hamilton paths in V.

for constructing a Hamilton cycle, though neither is it known that there isno such algorithm.

If the travel cost between any two cities is the same, then our salesman hasno difficulty in finding a least expensive tour: any permutation of the n - 1cities (the nth city is that of the head office) will do. Revelling in his new foundfreedom, our salesman decides to connect duty and pleasure and promisesnot to take the same road xy again whilst there is a road uv he hasn't seen yet.Can he keep his promise? In order to plan a required sequence of journeysfor our salesman we have to decompose K" into the union of some edgedisjoint Hamilton cycles. For which values of n is this possible? Since K" is(n - 1)-regular and a Hamilton cycle is 2-regular, a necessary condition isthat n - 1 is even, that is n is odd. This necessary condition also followsfrom the fact that e(K") = "n(n - 1) and a Hamilton cycle contains n edges,so K" has to be the union of (n - 1) Hamilton cycles.

Let us assume now that n is odd, n - 3. Deleting a vertex of K" we see thatif K" is the union of +(n - 1) Hamilton cycles K"-' is the union of J(n - 1)Hamilton paths. (In fact n - 1 has to be even if K"-' is the union of someHamilton paths since e(K"-') = (n - 1)(n - 2) and a Hamilton path inK"-' has n - 2 edges.) With the hint shown in Figure 1.11 the reader canshow that for odd values of n the graph K"-' is indeed the union of J(n - 1)Hamilton paths. In this decomposition of K"-' into J(n - 1) Hamiltonpaths each vertex is the endvertex of exactly one Hamilton path. (In fact,this holds for every decomposition of K"-' into (n - 1) edge-disjointHamilton paths since each vertex x of K"-' has odd degree so at least oneHamilton path has to end in x.) Consequently if we add a new vertex toK"-' and complete each Hamilton path in K"-' to a Hamilton cycle in K"then we obtain a decomposition of K" into J(n - 1) edge disjoint Hamiltoncycles. Thus we have proved the following result.

Theorem 9. For n >- 3 the complete graph K" is decomposable into edgedisjoint Hamilton cycles ijf n is odd. For n >- 2 the complete graph K" is decom-posable into edge disjoint Hamilton paths ijf n is even.

The result above shows that if n >- 3 is odd, then we can string together(n - 1) edge-disjoint cycles in K" to obtain a circuit containing all the edges

of K". In general a circuit in a graph G containing all the edges is said to bean Euler circuit of G. Similarly a trail containing all edges is an Euler trail.

Page 25: Graph Theory-An Introductory Course-Bela Bollobas

14 I Fundamentals

Figure I.12. The seven bridges on the Pregel in Konigsberg.

A graph is Eulerian if it has an Euler circuit. Euler circuits and trails arenamed after Leonhard Euler, who in 1736 characterized those graphs whichcontain them. At the time Euler was a professor of mathematics in St.Petersburg, and was led to the problem by the puzzle of the seven bridgeson the Pregel (see Figure 1.12) in the ancient Prussian city of Konigsberg(birthplace of Kant; since 1944 it has belonged to the USSR and is calledKaliningrad). Could anyone plan a walk in such a way that he would crosseach bridge once and only once?

It is clear that such a walk is possible if the graph in Figure 1.13 has anEuler trail.

Theorem 10. A non-trivial connected graph has an Euler circuit iff each vertexhas even degree.

A connected graph has a Euler trail from a vertex x to a vertex y x iffx and y are the only vertices of odd degree.

PROOF. The conditions are clearly necessary. For example, if XIX2 ... X, isan Euler circuit in G and x occurs k times in the sequence x1, x2, ... ,then d(x) = 2k.

We prove the sufficiency of the first condition by induction on the numberof edges. If there are no edges, there is nothing to prove so we proceed to theinduction step.

Let G be a non-trivial connected graph in which each vertex has evendegree. Since e(G) >_ 1, we find that 6(G) >_ 2 so, by Corollary 7, G containsa cycle. Let C be a circuit in G with the maximal number of edges. Suppose

C

B

Figure I.13. A graph of the Konigsberg bridges.

Page 26: Graph Theory-An Introductory Course-Bela Bollobas

§3 Hamilton Cycles and Euler Circuits 15

Figure 1.14. The circuits C and D.

C is not Eulerian. As G is connected, C contains a vertex x which is in anon-trivial component H of G - E(C). Every vertex of H has even degreein H so by the induction hypothesis H contains an Euler circuit D. Thecircuits C and D (see Figure 1.14) are edge-disjoint and have a vertex incommon, so they can be strung together to form a circuit with more edgesthan C. As this contradicts the maximality of e(C), the circuit C is Eulerian.

Suppose now that G is connected and x and y are the only vertices ofodd degree. Let G* be obtained from G by adding to it a vertex u togetherwith the edges ux and uy. Then by the first part G* has an Euler circuit C*.Clearly C* - u is an Euler trail from x to y.

Theorem 10 implies that there is no walk satisfying the conditions of theKonigsberg bridge puzzle, since the associated graph in Figure 1.13 hasfour vertices of odd degree. The plan of the corridors of an exhibition is alsoeasily turned into a graph: an edge corresponds to a corridor and a vertexto the conjunction of several corridors. If the entrance and exit are the same,a visitor can walk along every corridor exactly once if the correspondinggraph has an Eulerian circuit. In general a visitor must have a plan in orderto achieve this: he cannot just walk through any new corridor he happensto come to. However, in a well planned (!) exhibition a visitor would becertain to see all the exhibits provided he avoided going along the samecorridor twice and continued his walk until there were no new exhibitsahead of him. The graph of such an exhibition is said to be randomly Eulerianfrom the vertex corresponding to the entrance (which is also the exit). SeeFigure 1.15 for two examples. Randomly Eulerian graphs are also easilycharacterized (Exercises 24-26).

x

Figure I.15. G is randomly Eulerian from x; His randomly Eulerian from both u and v.

Page 27: Graph Theory-An Introductory Course-Bela Bollobas

16

§4 Planar Graphs

I Fundamentals

The graph of the corridors of an exhibition is a planar graph: it can be drawnin the plane in such a way that no two edges intersect. Putting it a bit morerigorously, it is possible to represent it in the plane in such a way that thevertices correspond to distinct points and the edges to simple Jordan curvesconnecting the points of its endvertices in such a way that every two curvesare either disjoint or meet only at a common endpoint. The above representa-tion of a graph is said to be a plane graph.

There is a simple way of associating a topological space with a graph,which leads to another definition of planarity, trivially equivalent to the onegiven above. Let pt, p2, ... be distinct points in 683, the 3-dimensionalEuclidean space, such that every plane in 683 contains at most 3 of these points.Write (pi, p) for the straight line segment with endpoints pi and p; (openor closed, as you like). Given a graph G = (V, E), V = (xt, x2, ... , xn), thetopological space

n

R(G) = I-) {(pi, p): xixj e E}U

U {pi} c 1183I

is said to be a realization of G. A graph G is planar if R(G) is homeomorphicto a subset of 682, the plane.

Let us make some more remarks in connection with R(G). A graph His said to be a subdivision of a graph G or a topological G graph if H is obtainedfrom G by subdividing some of the edges, that is by replacing the edges bypaths having at most their endvertices in common. We shall write TG for atopological G graph. Thus TG denotes any member of a rather large familyof graphs; for example TK3 is an arbitrary cycle and TO is an arbitrarycycle of length at least 8. It is clear that for any graph G the spaces R(G) andR(TG) are homeomorphic. We shall say that a graph G is homeomorphic to agraph H if R(G) is homeomorphic to R(H) or, equivalently, G and H haveisomorphic subdivisions.

At the first sight one may think that in the study of planar graphs one mayrun into topological difficulties. This is certainly not the case. It is easilyseen that the Jordan curves corresponding to the edges can be assumed tobe polygons. More precisely, every plane graph is homotopic to a planegraph representing the same graph, in which the Jordan curves are piecewiselinear. Indeed, given a plane graph, let 6 > 0 be less than half the minimaldistance between two vertices. For each vertex a place a closed disc D. ofradius 6 about a. Denote by J. the curve corresponding to an edge a = aband let as be the last point of J. in D. when going from a to b. Denote byJa the part of J. from as to ba. Let e > 0 be such that if a # Ii then X. andJ' are at a distance greater than 3e. By the uniform continuity of a Jordancurve each Ja can be approximated within c by a polygon Ja from as to b8.To get the required piecewise linear representation of the original graph

Page 28: Graph Theory-An Introductory Course-Bela Bollobas

§4 Planar Graphs

ba

Figure 1.16. Constructing a piecewise linear representation.

17

simply replace each J,, by the poygon obtained from Ja by extending it inboth directions by the segments aa, and b,,b (see Figure 1.16).

A less pedestrian argument shows that every planar graph has a straightline representation: it can be drawn in the plane in such a way that the edgesare actually straight line segments (Exercise 28).

If we omit the vertices and edges of a plane graph G from the plane, theremainder falls into connected components, called faces. Clearly eachplane graph has exactly one unbounded face. The boundary of a face is theset of edges in its closure. Since a cycle (that is a simple closed polygon)separates the points of the plane into two components, each edge of a cycleis in the boundary of two faces. A plane graph together with the set of facesit determines is called a plane map. The faces of a plane map are usuallycalled countries. Two countries are neighbouring if their boundaries have anedge in common.

If we draw the graph of a convex polyhedron in the plane then the facesof the polyhedron clearly correspond to the faces of the plane graph. Thisleads us to another contribution of Leonhard Euler to graph theory, namelyEuler's polyhedron theorem or simply Euler's formula.

Theorem 11. If a connected plane graph G has n vertices, m edges and f faces,then

n - m + f = 2.

PROOF. Let us apply induction on the number of faces. If f = 1 then G doesnot contain a cycle so it is a tree and the result holds.

Suppose now that f > 1 and the result holds for smaller values of f.Let ab be an edge in a cycle of G. Since a cycle separates the plane, the edgeab is in the boundary of two faces, say S and T. Omitting ab, in the new planegraph G' the faces S and T join up to form a new face, while all other faces ofG remain unchanged. Thus if n', m' and f' are the parameters of G' thenn'=n,m'=m-1andf'=f- 1. Hence n-m+f=n'-m'+f'=2.

O

Page 29: Graph Theory-An Introductory Course-Bela Bollobas

18 I Fundamentals

Let G be a connected plane graph with n vertices, m edges and f faces;furthermore, denote by f the number of faces having exactly i edges in theirboundaries. Of course

f = f, (3)

and if G has no bridge then

Y1 =2m, (4)

since every edge is in the boundary of two faces. Relations (3), (4) and Euler'sformula give an upper bound for the number of edges of a planar graph oforder n. This bound can be improved if the girth of the graph, that is thenumber of edges in a shortest cycle, is large. (The girth of an acyclic graph isdefined to be oo.)

Theorem 12. A planar graph of order n > 3 has at most 3n - 6 edges. Further-more, a planar graph of order n and girth at least g, 3 < g < oo, has size atmost

maxIg y-(n-2),n- 1}.-)PROOF. The first assertion is the case g = 3 of the second, so it suffices toprove the second assertion. Let G be a planar graph of order n, size m andgirth at least g. If n 5 g - 1 then G is acyclic so m < n - 1. Assume nowthat n >- g and the assertion holds for smaller values of n. We may assumewithout loss of generality that G is connected. If ab is a bridge then G - ab isthe union of two vertex disjoint subgraphs, say G, and G2. Putting n, _I G; 1, m; = e(G;), i = 1, 2, by induction we find

m=m, +m2+ 1 <max{ g (n, -2),n, - 19-2

+ max 2 (n2 - 2), n2

< max{ 92

(n - 2), n - 1 }.L

On the other hand, if G is bridgeless, (3) and (4) imply

2m1i=> I > g/ =9rt ze t

Hence, by Euler's formula,

m+2==rn+f <n+ 2m,

9

Page 30: Graph Theory-An Introductory Course-Bela Bollobas

§5 An Application of Euler Trails to Algebra

and so

19

m< g (n-2).g-2Theorem 12 can often be used to show that certain graphs are non-planar.

Thus K5, the complete graph of order 5, is non-planar since e(K5) = 10 >3(5 - 2), and K3' 3,3 the complete 3 by 3 bipartite graph is non-planar sinceits girth is 4 and e(K3,3) = 9 > (4/(4 - 2))(6 - 2). The non-planarity ofK3' 3 implies that it is impossible to join each of 3 houses to each of 3 wells bynon-crossing paths, as demanded by a well-known puzzle (see Figure 1.17).

Figure I.17. Three houses and three wells.

If a graph G is non-planar then so is every topological G graph, andevery graph containing a topological G graph. Thus the graphs in Figure 1.18are non-planar since they contain TK5 and TK3,3

, respectively.It is somewhat surprising that the converse of the trivial remarks above

is also true. This beautiful result was proved by Kuratowski in 1930; as theproof is rather long though elementary, we shall not give it here.

Figure I.18. G contains a TK`and H contains a TK3.3.

Theorem 13. A graph is planar iff it does not contain a subdivision of K5 orK3,3 .

§5 An Application of Euler Trails to Algebra

To conclude this chapter we shall show that even simple notions like theones presented so far may be of use in proving important results. The resultwe are going to prove is the fundamental theorem of Amitsur and Levitzki

Page 31: Graph Theory-An Introductory Course-Bela Bollobas

20 I Fundamentals

on polynomial identities. The commutator of two elements a and b of aring S is [a, b] = ab - ba. Similarly, if ai a S, 1 < i < k, we write

[al, a2, ... , ak] _ Y sgn(a)aolao2 ... aok,a

where the summation is over all permutations a of the integers 1, 2, ... , k.If [al, a2, ... , ak] = 0 for all ai e S, 1 < i < k, then S is said to satisfy thek-th polynomial identity. The theorem of Amitsur and Levitzki states that thering Mk(R) of k by k matrices with entries in a commutative ring R satisfiesthe 2k-th polynomial identity.

Theorem 14. Let R be a commutative ring and let A1, A2 i ... , A2k a Mk(R).Then [A1, A2, ... , A2k] = 0.

PROOF. We shall deduce the result from a lemma about Euler trails in directedmultigraphs. Let G be a directed multigraph of order n with edges el, e2, ... ,e,,,. Thus each e; is an ordered pair of not necessarily distinct vertices. Every(directed) Euler trail P is readily identified with a permutation of{1, 2, ... , m}; define s(P) to be the sign of this permutation. Given not neces-sarily distinct vertices x, y of G, put s(G; x, y) = Ep e(P), where the sum-mation is over all Euler trails from x to y.

Lemma 15. If m z 2n then y) = 0.

Before proving this lemma, let us see how it implies Theorem 14. WriteE, e M (R) for the matrix whose only non-zero entry is a 1 in the ith row andjth column. Since [A1, A2, ... , is R-linear in each variable and{E, : 1 < i,j - n} is a basis of M (R) as an R-module, it suffices to proveTheorem 14 when Ak = E,k jk for each k. Assuming this is the case, let G be thedirected multigraph with vertex set 11, 2, ... , n}, whose set of directed edges is{iljl, i2j2, ... , i2J20. By the definition of matrix multiplication a productAo1Aa2 ... Ao2. is E, if the corresponding sequence of edges is a (directed)Euler trial from i to j and otherwise the product is 0. Hence [A 1, A2, ... , A2i1= yi,; e(O; i, j)Eij. By Lemma 15 each summand is 0 so the sum is also 0.

PROOF OF LEMMA 15. We may clearly assume that d has no isolated vertices.Let G' be obtained from d by adding to it a vertex x', a path of lengthm + 1 - 2n from x' to x and an edge from y to x' (see Figure 1.19). Then

Zx,

Figure 1.19. The construction of 0.

Page 32: Graph Theory-An Introductory Course-Bela Bollobas

§5 An Application of Euler Trails to Algebra 21

G' has order n + (m + 1 - 2n) = m + 1 - n and size m + m + 1 - 2n + 1= 2(m + 1 - n). Furthermore, it is easily checked that 1 e(G; x, y) I =E(G'; x', x') I . Hence it suffices to prove the theorem when m = 2n and

x=y.Given a vertex z, let d+(z) be the number of edges starting at z and let

d(z) be the number of edges ending at z. Call d(z) = d +(z) + d(z) thedegree of z and f(z) = d+(z) - d-(z) the flux at z. We may assume thatG contains an Euler circuit (an Euler trail from x to x), otherwise there isnothing to prove. In this case each vertex has 0 flux and even degree at least 2.Furthermore, we may assume that there is no double edge (and so no doubleloop) for otherwise the assertion is trivial.

In order to prove the theorem in the case m = 2n and x = y we applyinduction on n. The case n = 1 being trivial, we turn to the induction step.We shall distinguish three cases.

(i) There is a vertex b # x of degree 2; say e, = ab ends at b and em _ 1 = bestarts at b. If a = c the assertion follows by applying the induction hypo-thesis to G - b. If a # c then without loss of generality x # c. Let e1 = cc1,e, = CC,, ... , e, = cc, be the edges starting at c. For each i, 1 < i < t,construct a graph Gi from G - b by omitting ei and adding e; = aci (seeFigure 1.20). Then e(G; x, x) = Yi=t e(Gi; x, x) = 0.

Figure I.20. The construction of Gi.

(ii) There is a loop at a vertex b # x of degree 4. Let ebe the loop at band let em _ 2 = ab and em _ t = be be the other edges at b. Let do be obtainedfrom G - b by adding to it an edge 2 = ac. Then E(G; x, x) = e(Go; x, x)=0.

(iii) The cases (i) and (ii) do not apply. Since m = 2n = Y; di and eachvertex distinct from x has degree at least 4, either each vertex has degree 4or else d(x) = 2, there is a vertex of degree 6 and all other vertices have degree4. It is easily checked (Exercise 32) that there are two adjacent vertices ofdegree 4, say a and b, since otherwise (ii) would hold. Now we shall apply ourfourth and final graph transformation. This is more complicated than theprevious ones since we shall construct two pairs of essentially differentgraphs from G: the graphs G1, G2, H6 and H7 shown in Figure 1.21. EachEuler trail from x to x in G is transformed to an Euler trail in exactly one ofGt and O. However, the graphs GI and G2 contain some spurious Eulertrails: Euler trails that do not come from Euler trails in G. As these spurious

Page 33: Graph Theory-An Introductory Course-Bela Bollobas

22

H6

Figure 1.21. The graphs (1, C1, C2,146 and 11,.

G2

H7

Euler trails are Euler trails in exactly one of 116 and 177 and they exhaustall the Euler trails of 176 and 177, we find that

2 x 7

E(G; x, x) _ Y- E(G,; x, x) - Y- E(Fli; x, x).1 6

The first two terms are 0 because of (i) and the second two terms are 0because of (ii) so E(d; x, x) = 0, completing the proof of Lemma 15.

EXERCISES

1. (i) Show that every graph contains two vertices of equal degree.(ii) Determine all graphs with one pair of vertices of equal degree.

2. Prove that the complement of a disconnected graph is connected.

3. Show that in a graph G there exists a set of cycles such that each edge of G belongsto exactly one of these cycles if every vertex has even degree.

4. Show that in an infinite graph G with countably many edges there exists a setof cycles such that each edge of G belongs to exactly one of these cycles if forevery X c V(G) the set of edges joining X to V(G) - X is even or infinite.

5. Show that d1 5 d2 5 5 d is the degree sequence of a tree iff d1 z 1 and1,d,=2n-2.

I Fundamentals

Page 34: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 23

6. Show that every integer sequence d, < d2 < < d" with d, > I and E, d; _2n - 2k, k >- 1, is the degree sequence of a forest with k components.

7. Characterize the degree sequence of forests!

8. Prove that a regular bipartite graph of degree at least 2 does not have a bridge.

9. Let G be a graph of order n. Prove the equivalence of the following assertions.(i) G is a tree.(ii) G is connected and has n - 1 edges.(iii) G is acyclic and has n - 1 edges.(iv) G = K" for n = 1, 2, and if n > 3 then G # K" and the addition of an

edge to G produces exactly one new cycle.

10. Let .d = {A,, A2.... , A"} be a family of n (> I) distinct subsets of a set X with nelements. Define a graph G with vertex set .d in which A; A; is an edge if thereexists an x c- X such that A, A A3 = {x}. Label the edge A;A; with x. For H c Glet Lab(H) be the set of labels used for edges of H. Prove that there is a forestF c G such that Lab(F) = Lab(G).

It. (10 continued) Deduce from the result in the previous exercise that there is anelement x c X such that the sets A, - {x}, A2 - {x}, ..., {A"} - {x} are alldistinct. Show that this need not hold for any n if 1,d 1 = n + 1.

12. A tournament is a complete oriented graph, that is a directed graph in which forany two distinct vertices x and y either there is an edge from x to y or there is anedge from y to x, but not both. Prove that every tournament contains a (directed)Hamilton path.

137 Let G be a connected graph of order n and let 1 < k < n. Show that G containsa connected subgraph of order k.

14.- Prove that the radius and diameter of a graph satisfy the inequalities

rad G < diam G < 2 rad G,

and both inequalities are best possible.

15- Given d >- 1, determine

max min{diam T: T is a spanning tree of G}.diam G =d

16. Denote by /3o(G) the maximum number of independent vertices in G. Prove thatif G does not contain a triangle then A(G) < f3o(G) and deduce that e(G) < Inflo(G),where n = I G I.

177 Show that if for every vertex z of a directed graph there is an edge starting at z(that is d+(z) > 0) then the graph contains a (directed) cycle.

18. A grading of a directed graph 0 = (V, E) is a partitioning of Y into sets V, V2,.. -, Yksuch that if zy e E' then x c- V and y E V +, for some i.

Given a directed graph G and a (non-directed) path P = xox, ... x denoteby v(xo, x,; P) the number of edges xixi+, minus the number of edges x;+,x;.Prove that G has a grading if v(xo, x,; P) is independent of P for every pair ofvertices x0, x,.

Page 35: Graph Theory-An Introductory Course-Bela Bollobas

24 I Fundamentals

19. Complete the proof of Theorem 8 by showing in detail that both the second andthird methods construct an economical spanning tree.

20. Show how the fourth method in Theorem 8 can be applied to find an economicalspanning tree even if several edges have the same cost (cf. Figure 1.6).

21. Show that every economical spanning tree can be constructed by each of the firstthree methods.

22. Deduce from Theorem 10 that a graph contains an Euler circuit if all but atmost one of its components are isolated vertices and each vertex has even degree.State and prove an analogous statement about the existence of an Eulerian trailfrom x to y.

23. The following algorithm for finding an Euler circuit x,x2 ... X. in a graph Gis due to Fleury. Pick x1 arbitrarily. Having chosen x1, x2, ... , Xk, put Gk =G - {x,x2, x2x31 ..., xk_,xk}. If Xk is isolated in Gk, terminate the algorithm.Otherwise let xk+, be a neighbour of xk in Gk such that xkxk+, is not a bridge,unless every edge of Gk incident with xk is a bridge.

Prove that if G has an Euler circuit then the trail x,x2 ... x, constructedby the algorithm is an Euler circuit.

24. A graph G is randomly Eulerian from a vertex x if any maximal trail starting at xis an Euler circuit. (If T = xx, .. x, then T is a maximal trail starting at x ifx, is an isolated vertex in G - E(T).) Prove that a non-empty graph G is randomlyEulerian from x if G has an Euler circuit and x is contained in each cycle of G.

25. Let F be a forest. Add a vertex x to F and join x to each vertex of odd degreein F. Prove that the graph obtained in this way is randomly Eulerian from x.

26. Prove that a graph G is randomly Eulerian from each of two vertices x and yif G is the union of an even number of x-y paths, any two of which have only xand y in common.

27. How would you define the number of sides of a face so that formula (4) continuesto hold for graphs with bridges? Rewrite the proof of Theorem 12 accordingly.

28 Prove that every planar graph has a drawing in the plane in which every edge is astraight line segment. [Hint. Apply induction on the order of maximal planargraphs by omitting a suitable vertex.]

29. A plane drawing of an infinite graph is defined as that of a finite graph with theadditional condition that each point has a neighbourhood containing at most onevertex and meeting only edges incident with that vertex.

Show that Kuratowski's theorem does not hold for infinite graphs, that isconstruct an infinite non-planar graph without TKS and TK 3' 3

Is there an infinite non-planar graph without a TK`?

30. Let d, < d2 < . . . < d be the degree sequence of a planar graph.(i) By making use of an upper bound for YI d,, show that if d, >- 4 then

LV d? <2(n+3)2-62.

Page 36: Graph Theory-An Introductory Course-Bela Bollobas

Notes 25

(ii) Prove by induction on n that if n >- 4 then

Yd?<2(n+3)Z-62.

Show that equality can hold for every n > 4.

31 ' Determine the maximum of Yi d? where dl 5 d2 < < d, is the degreesequence of a planar graph with girth at least 4 (that is without triangles). What isthe maximum if the girth is at least g > 4?

32. Fill in the small gap in the proof of Lemma 15: show that if cases (i) and (ii) donot apply then there are two adjacent vertices of degree 4.

Notes

Theorem 14 is in K. Kuratowski, Sur le probleme des courbes gauches entopologie, Fund. Math. 15 (1930) 271-283; for a simpler proof see G. A.Dirac and S. Schuster, A theorem of Kuratowski, Indag. Math. 16 (1954)343-348.

The theorem of S. A. Amitsur and J. Levitzki (Theorem 14) is in Minimalidentities for algebras, Proc. Amer. Math. Soc. 1 (1950) 449-463; the proofgiven in the text is based on R. G. Swan, An application of graph theory toalgebra, Proc. Amer. Math. Soc. 14 (1963) 367-373 and Correction to " Anapplication of graph theory to algebra," Proc. Amer. Math. Soc. 21 (1969)379-380.

Page 37: Graph Theory-An Introductory Course-Bela Bollobas

CHAPTER II

Electrical Networks

This chapter is something of a diversion from the main line of the book, sosome readers may wish to skip it. Only the concepts introduced in thefirst half of §3 will be used later, in. §2 of Chapter VIII.

It does not take long to discover that an electrical network may be viewedas a graph, so the simplest problems about currents in networks are exactlyquestions about graphs. Does our brief acquaintance with graphs help usto tackle the problems? As it will transpire in the first section, the answer isyes; for after a short review of the basic ideas of electricity we make use ofspanning trees to obtain solutions. Some of these results can be reformulatedin terms of tilings of rectangles and squares, as we shall show in §2. The lastsection introduces elementary algebraic graph theory which is then appliedto electrical networks.

It should be emphasised that in the problems we consider we use hardlymore than the terminology of graph theory; virtually the only concept tobe used is that of a spanning tree.

§1 Graphs and Electrical Networks

A simple electrical network can be regarded as a graph in which each edgee, has been assigned a real number r, called its resistance. If there is a potentialdifference pi between the endvertices of ei, say a and b, then an electricalcurrent wi will flow in the edge e, from a to b according to Ohm's law:

26

Page 38: Graph Theory-An Introductory Course-Bela Bollobas

§1 Graphs and Electrical Networks 27

Though to start with we could restrict our attention to electrical networkscorresponding to graphs, in the simplifications that follow it will be essentialto allow multiple edges, that is to consider multigraphs instead of graphs.Furthermore, we orient each edge arbitrarily from one endvertex to the otherso that we may use pi to denote the potential difference in the edge ei, meaningthe difference between the potentials of the initial vertex and the end vertex.Similarly w, is the current in the edge ei, meaning the current in ei in thedirection of the edge. (Note that we regard a negative current - w, as apositive current wi in the other direction.) Thus, throughout the section weconsider directed multigraphs, that is directed graphs which may containseveral edges directed from a to b. However, in this section there is no dangerof confusion if we use ab to denote an edge from a to b; in the next sectionwe shall be more pedantic. Thus

wan = - Wba and Pan = - Pba

In many practical problems electrical currents are made to enter thenetwork at some points and leave it at others, and we are interested in theconsequent currents and potential differences in the edges. These aregoverned by the famous laws of Kirchhoff (another renowned citizen ofKonigsberg).

Kirchhoffs potential (or voltage) law states that the potential differencesround any cycle x1x2 ... xk sum to 0:

PX,X2 + Px2X3 + ... + PXk - /Xk + PxkX1 = 0.

Kirchhoff's current law postulates that the total current outflow from anypoint is 0:

Wab + Wac + ' ' ' + wau + wasp = 0.

Here ab, ac, ... , au are the edges incident with a, and wasp denotes theamount of current that leaves the network at a. (In keeping with our con-vention, W .a = - wasp is the amount of current entering the network at a.)For vertices not connected to external points we have

wan+Wac+...+waa=0.

Note that if we know the resistances, then the potential law can be re-written as a restriction on the currents in the edges. Thus we may considerthat the currents are governed by the Kirchhoff laws only; the physicalcharacteristics of the network (the resistances) affect only the parameters inthese laws.

It is also easily seen that the potential law is equivalent to saying that onecan assign absolute potentials Va, Vb, ... to the vertices a, b, ... so that thepotential difference between a and b is Va - Vb = pan. If the network isconnected and the potential differences pan are given for the edges, then weare free to choose arbitrarily the potential of one of the vertices, say Va, butthen all the other potentials are determined. In this section we shall work

Page 39: Graph Theory-An Introductory Course-Bela Bollobas

28 II Electrical Networks

with the potentials, usually choosing the potential of one of the vertices tobe 0, but we must keep in mind that this is the same as the application of thevoltage law.

In the most fundamental problems current is only allowed to enter thenetwork at a single point s, the source, and only leave it at another point t,the sink. (We shall indicate later that the general problem can be reducedto these fundamental problems.) If the size of the current from s to t is wand the potential difference between s and t is p, then by Ohm's law r = p1wis the total resistance of the network between s and t. As an example of theuse of the Kirchhoff laws we shall evaluate the total resistance between s andt of the simple network shown in Figure II.1.

b

1-e-f

V. Vb = 2(1 - e)

-e

Figure II.1. The resistances, the currents and the potentials.

This network has 5 resistors, of values 1, 2, 3, 4 and 5 ohms, as shown inthe first picture. If we suppose that a unit current flows into the system at sand leaves it at t, then the consequent edge currents must be as in the secondpicture, for suitable values of e and f. Finally, the potentials V, = 0, V., Vb, V5assigned to the vertices must satisfy Ohm's law, so V. = 1 e = e, Vb =2(1 - e) and Vs = V. + 5(e + f) 6e + 5f. Ohm's law has to be satisfiedin two more edges, ab and bs, giving us

V. =e= P,-4- 3f =2(1 -e)+3f

and

V,=6e+5f=Vb+4(1-e-f)=2(1-e)+4(1-e-f).Hence

e = 2 - 2e + 3f

and

6e + 5f = 6 - 6e - 4f,

giving e = 4/7, f = - 2/21 and V, = 6e + 5f = 62/21. In particular, thetotal resistance from s to t is (V, - V,)/w = 62/21.

The calculations are often simplified if we note that Kirchhoff's equationsare linear and homogeneous in all currents and potential differences. Thisimplies the so-called principle of superposition: any combination of solutionsis again a solution. As an application of the principle of superposition one

Page 40: Graph Theory-An Introductory Course-Bela Bollobas

§1 Graphs and Electrical Networks 29

can show that any current resulting from multiple sources and sinks can beobtained by superposing flows belonging to one source and one sink, that issolutions of the fundamental problems mentioned above can be used tosolve the general problem. Furthermore, the principle of superposition impliesimmediately that there is at most one solution, no matter how the sourcesand sinks are distributed. Indeed, the difference of two distinct solutions is aflow in which no current enters or leaves the network at any point. If inthis flow there is a positive current in some edge from a to b, then by thecurrent law a positive current must go from b to c, then from c to d, etc.,giving a trail abcd.... Since the network is finite, this trail has to returnto a point previously visited. Thus we obtain a circuit in whose edges positivecurrents flow in one direction. But this is impossible since it implies that thepotential of each vertex is strictly greater than that of the next one roundthe circuit.

Before proving the existence of a solution (which is obvious if we believein the physical interpretation), we shall calculate the total resistance of twonetworks. Unless the networks are very small, the calculations can get veryheavy, and electrical engineers have a number of standard tricks to make themeasier.

The very simple networks of Figure 11.2 show two resistors r1 and r2connected first in series and then in parallel. Let us put a current of size 1

rs

a

Figure II.2. Resistors connected in series and in parallel.

through the networks, from s to t. What are the total resistances? In the firstcase

Va=r1 and Vs=V,+r2=r1+r2so the total resistance is

r=r1+r2.In the second case, when they are connected in parallel, if a current of size egoes through the first resistor and so a current of size 1 - e through thesecond, then

r2V,=r1e=r2(1 -e), so e=

r1 + r2

Page 41: Graph Theory-An Introductory Course-Bela Bollobas

30

and the total resistance is given by

r1r2or

1=

1

+Ir= - ---.

r1 + r2 r r1 r2

11 Electrical Networks

This indicates that reciprocals of resistances, or conductances, are just asnatural as the resistances themselves, and indeed are slightly more convenientin our presentation. (The conductance of an edge of resistance 1 ohm is1 mho). What we have shown now is that for series connection the resistancesadd and for parallel connection the conductances add.

The use of conductances is particularly convenient when consideringcertain limiting cases of Ohm's law. If the resistance of an edge ab is 0, thenwe necessarily have V,, = Vb, and from an electrical point of view the verticescan be regarded as identical. In the usual slang, a has been "shorted" (short-circuited) to b. Of course, a may be shorted to b if there is some other reasonwhy V. = Vb. At the other extreme, we can introduce edges of 0 conductancewithout effecting the currents and potentials. Conversely, we make an edgehave 0 conductance by "cutting" it. Of course, an edge of 0 resistance is saidto have oo conductance and an edge of 0 conductance is said to have 00resistance.

Let us see now how the acquaintance with resistors in series and in paralleland the possibility of shorting vertices can help us to determine the totalresistance. As an example, let us take the network formed by the edges of acube, in which each edge has 1 ohm resistance. What is the total resistanceacross an edge st? Using the notation of the first picture in Figure 11.3,we see that by symmetry V. = V and Vd = Vf, so c can be shorted to a and fto d, giving us the second picture. From now on we can simplify resistorsconnected parallel and in series, until we find that the total resistance is 12.Knowing this, it is easy to recover the entire current flow.

Another important device in practical calculations is the so-calledstar-delta transformation. If a vertex v is joined to just three vertices, say

1 - bc

1 1

d 1 t

11 1 e

a

1 4

d t I d

s

Figure 11.3. Calculating the total resistance of a cube.

Page 42: Graph Theory-An Introductory Course-Bela Bollobas

§ I Graphs and Electrical Networks 31

a

Al

B v cb c b 'A = S/A

Figure 11.4. The star-delta transformation; S = AB + BC + CA.

a, b and c, by edges of resistances A, B and C, then we call v the center of astar, as in the first picture of Figure 11.4. If no current is allowed to enter orleave at v, then we are allowed to replace this star by the delta-configurationshown in the second picture of Figure 11.4, because, as the reader shouldcheck, these two networks have the same total resistances across all threepairs ab, be and ca. Of course we may apply the transformation in reverse,replacing A', B', C' by A = B'C'/T, B = C'A'/T and C = A'B'/T, whereT = A' + B' + C. Incidentally, the formulae become symmetrical if weuse resistances in the first transformation and conductances in the second:A' = B + C + BC/A, and a = /3' + y' + fl'y'/a', where a, #,... are theconductances.

As an application of the star-delta transformation, let us calculate thetotal resistance of a tetrahedron across an edge, in which the resistances areas in Figure 11.5. The pictures speak for themselves.

Figure 11.5. Applications of the star-delta transformation.

1

We shall conclude this section on a slightly more theoretical note: weshall prove the existence of a solution. More precisely, we shall show that if acurrent of size 1 is put through a network then the current in an edge can beexpressed in terms of the numbers of certain spanning trees. For simplicitywe assume that the graph G of the network is connected, each edge has unitresistance, and a current of size 1 enters at a vertex s and leaves at t.

Page 43: Graph Theory-An Introductory Course-Bela Bollobas

32 11 Electrical Networks

Theorem 1. Given an edge ab, denote by N(s, a, b, t) the number of spanningtrees of G in which the (unique) path from s to t contains a and b, in this order.Define N(s, b, a, t) analogously and write N for the total number of spanningtrees. Finally, let w,b = {N(s, a, b, t) - N(s, b, a, t))/N.

Distribute currents in the edges of G by sending a current of size wb froma to b for every edge ab. Then there is a total current size l from s to t satisfyingthe Kirchhoff laws.

PROOF. For each spanning tree T there is exactly one neighbour XT of sthat is on the s-t path PT contained in T. Hence Eber(,) N(s, s, b, t) = N,where F(s) is the set of neighbours of s. Since N(s, b, s, t) = 0 for every vertexb e F(s), we find that EbE r(,)w,b = 1. By symmetry Y',, E r(r) w = 1; soKirchhoff's current law is satisfied at s and t provided a current of size 1enters the network at s and leaves it at t.

To prove the theorem we have to show that if no current is allowed to enteror leave the network at any other point then the current and potential lawsare satisfied.

Let us take the current law first; to simplify the situation multiply allcurrents by N. What is the contribution of a spanning tree T to the currententering and leaving a vertex y distinct from s and t? If y is not on the s-tpath PT then T contributes nothing to N(s, x, y, t) or N(s, y, x, t). Now if y ison the s-t path PT, say PT = s ... xyz ... t, then T contributes 1 toN(s, y, z, t) and it also contributes 1 to N(s, x, y, t). In other words T con-tributes a current of size I from y and a current of size I into y. Thus thecurrent law is satisfied.

As all edges have the same resistance, the potential law claims that thetotal current in a cycle with some orientation is zero. To show this we proceedas earlier, but first reformulate slightly the definition of N(s, a, b, t). Call aforest F a thicket if it has exactly two components, say F, and F such thats is in F, and t is in F,. Then N(s, a, b, t) is the number of thickets F = F. U F,for which a e F, and b e F, and N(s, b, a, t) is defined analogously. What isthen the contribution of a thicket F = F, u F, to the total current in acycle? It is the number of cycle edges from F, to F, minus the number ofcycle edges from F, to F,; so it is zero.

The proof above can be rewritten word for word to give a solution inthe case when the edges have arbitrary conductances. For a spanning tree Tdefine the weight w(T) of T as the product of the conductances of its edges.Let N* be the sum of the weights of all the spanning trees, let N*(s, a, b, t)be the sum of the weights of all the spanning trees in which b follows a onthe (unique) s-t path in the tree, and let N*(s, b, a, t) = N*(t, a, b, s).

Theorem 2. There is a distribution of currents satisfying Kirchhoff's laws inwhich a current of size 1 enters at s and leaves at t. The value of the current inan edge ab is given by {N*(s, a, b, t) - N*(s, b, a, t)}/N.*

Page 44: Graph Theory-An Introductory Course-Bela Bollobas

§2 Squaring the Square 33

Corollary 3. If the conductances of the edges are rational and a current of size1 goes through the network then the current in each edge has rational value.

§2 Squaring the Square

This is a diversion within a diversion; we feel bound to draw attention to afamous problem arising from recreational mathematics which is related tothe theory of electrical networks. Is there a perfect squared square? In otherwords, is it possible to subdivide a closed square into finitely many (butat least two) square regions of distinct sizes that intersect only at theirboundaries?

Let us consider a squared rectangle, say the one shown in Figure 11.6;the number in a square is the length of its side. Let us cut this rectangle outof a sheet of nichrome (or any other material with low conductivity) and let usput rods made of silver (or some other material of high conductivity) at thetop and bottom.

4

2

2

3 3

Figure 11.6. A (non-perfect) squaring of a 6 x 7 rectangle.

What happens if we ensure that the silver rod at the top is at 7 volts whilethe rod at the bottom is kept at 0? Of course a uniform current will flowfrom top to bottom. In fact the potential at a point of the rectangle willdepend only on the height of the point: the potential at height x will be xvolts. Furthermore, there will be no current across the rectangle, only fromtop to bottom. Thus the current will not change at all if (i) we place silverrods on the horizontal sides of the squares and (ii) cut narrow slits alongthe vertical sides, as shown in the first picture of Figure 11.7.

Now since silver is a very good conductor, the points of each silver rodhave been shortened, so can be identified. Thus as an electric conductor thewhole rectangle behaves like the plane network shown in the second pictureof Figure 11.7, in which the conductance of an edge is equal to the conductance

Page 45: Graph Theory-An Introductory Course-Bela Bollobas

34 II Electrical Networks

V,=7

a

b

V,=5

Vs=3

V,=07tt

Figure 11.7. The electrical network associated with our rectangle.

of the corresponding square from top to bottom. Clearly the conductance ofa rectangle from top to bottom is proportional to the length of a horizontalside and the resistance is proportional to a vertical side. Consequently allsquares have the same resistance, say unit resistance, so all edges in Figure11.7 have unit resistance. What is the potential drop in an edge? It is the sidelength of the corresponding square. What is the resistance of the wholesystem? The ratio of the horizontal side of the original big rectangle to thevertical side, that is a.

Since the process above is reversible, that is every squared rectangle canbe obtained from some network we have an effective tool to help us in oursearch for squared squares. Take a connected planar graph G and turn itinto an electrical network by giving each edge resistance 1. Calculate thetotal resistance from a vertex s to a vertex t. If this is also 1, the network maycorrespond to a suitably squared square. If the potential differences in theedges are all distinct, all squares have different sizes, so we have a perfectsquared square.

Of course, at this stage our problem is far from being solved; we do noteven know that there must exist a squared square. However, we have a chanceto search systematically for a solution. Many squared squares have been

29

50

33

Figure 11.8. A perfect squared square: a tiling of a square with 21 incongruent squares.

Page 46: Graph Theory-An Introductory Course-Bela Bollobas

§3 Vector Spaces and Matrices Associated with Graphs 35

found with the help of computers, but the first examples were found withoutcomputers by Sprague in 1939 and by Brooks, Smith, Stone and Tutte in1940. The smallest number of squares that can tile a square is 21; Figure 11.8shows this tiling, due to Duijvestijn. In fact, this is the only tiling of order 21.

The connection between squaring a rectangle and electrical networksgives us immediately a beautiful result first proved by Dehn in 1903. Corollary3 tells us that if each edge has resistance 1 and a current of size 1 flowsthrough the system then in each edge the value of the current is rational.This translates to the following result about squared rectangles.

Theorem 4. If a rectangle can be tiled with squares then the ratio of twoneighbouring sides of the rectangle is rational.

Equivalently: a rectangle can be tiled with squares if it can be tiled withcongruent squares.

It is easily seen that electrical networks can be used to obtain tilings ofrectangles of prescribed shapes: an edge e of resistance r corresponds to arectangle in which the height is r times the base. The reader is encouraged tosolve the exercises based on this simple idea (Exercises 9-12); some otherexercises concern related packing problems (Exercises 13-15).

§3 Vector Spaces and Matrices Associated withGraphs

The vertex space C0(G) of a graph G is the complex vector space of allfunctions from V(G) into C. Similarly the edge space C1(G) is the complexvector space of all functions from E(G) into C. In these definitions it issometimes convenient to replace the complex field by F2, the field of order 2,or by other fields. We shall take V(G) = {vt, v2, ... , and E(G) ={e,, e2, ... , em} so that dim C0(G) = n and dim C1(G) = m. The elements ofC0(G) are usually written in the form x = =t xivi or x = (xi)j. The sumD_, x, vi is a formal sum of the vertices but if we think of v; as the functionV(G) -+ C which is 0 everywhere, except at the vertex vi, where it is 1, thenv1 ,.. v is a basis of C0(G) and the sum above simply expresses an elementin terms of the basis elements. Similarly an element of C, (G) may be writtenas y = Y-1 , yi e; or y = (yi)T. We call (v,, ... , the standard basis of thevertex space C0(G) and (e,, ... , the standard basis of the edge space.We shall endow these spaces with the inner product in which the standardbases are orthonormal: <x, y> = Li xiyi.

In this section we shall be concerned mostly with the edge space C1(G);to start with we define two subspaces which will turn out to be orthogonalcomplements of each other. Let L be a cycle in G with a given cyclic orienta-tion L = u,u2 ... u,. If ei = ujuj+, and ei is oriented from u; to u;+t then

Page 47: Graph Theory-An Introductory Course-Bela Bollobas

36 II Electrical Networks

e2

Figure 11.9. If the thick cycle L is oriented anti-clockwise, its vector in C1(G) iszL = (-1, 1 , 1, -1, 1,0,...,0).

we say that e; is oriented as L. This oriented cycle L can be identified withan element ZL of C1(G):

1 if e; E E(L) and e, is oriented as L,zL(e;) _ -1 if e, E E(L) and e; is not oriented as L,

0 if e1 * E(L).

A simple example is shown in Figure 11.9. Denote by Z(G) the subspaceof C1(G) spanned by the vectors z1, as L runs over the set of cycles; Z(G) isthe cycle space of G.

Let now P be a partition V = 1' u V2 of the vertex set of G. Consider theset (V1, V2) of edges from V1 to V2; such a set of edges is called a cut. Thereis a vector up in C1(G) called a cut vector, naturally associated with thispartition P:

11 if e1 goes from V1 to V.

up(e) _ -1 if e; goes from V2 to V1

0 if e. 0 E(V1, V2).

We write U(G) for the subspace of the edge space C1(G) spanned by all thecut vectors up; U(G) is the cut (or cocycle) space of G.

Theorem 5. The inner product space C1(G) is the orthogonal direct sum ofthe cycle space Z(G) and the cut space U(G). If G has n vertices, m edges andk components then

dim Z(G) = m - n +k and dim U(G) = n- k.

PROOF. Let us see first that Z(G) and U(G) are orthogonal. Let L be a cycleand P a partition V = V1 u V2. What is the product <ZL, up>? It is simplythe number of edges of L going from V1 to V2 in the orientation of L, minusthe number of edges of L from V2 to V1. Thus <ZL, up> = 0 for every cycle Land partition P, so Z(G) and U(G) are indeed orthogonal.

Since the dimension of C1(G) is the number of edges, m, both assertionswill be proved if we show that dim Z(G) Z m - n + k and dim U(G) zn - k. We shall first prove this under the assumption that G is connected;the general case will follow easily.

Page 48: Graph Theory-An Introductory Course-Bela Bollobas

§3 Vector Spaces and Matrices Associated with Graphs 37

Thus let us assume that G is connected, that is k = 1. Let T be a spanningtree of G. We shall make use of T to exhibit m - n + 1 independent vectorsin Z(G) and n - 1 independent vectors in U(G). We may choose the indicesof the edges in such a way that et, e2, ... , 1 are the tree edges and e,,,

1, ... , e,,, are the remaining edges, the chords of T.We know that for every chord ei (i > n) there is a (unique) oriented cycle

Ci such that zc,(ei) = 1 and zc,(ej) = 0 for every other chord e;, that iswhenever j >- n and j # i. (Shortly: zc,(e;) = bi; if j Z n, where bi; is theKronecker delta.) We call Ci the fundamental cycle belonging to ei (withrespect to T); zc, is a fundamental cycle vector (see Figure II. 10). Similarly by

e12

Figure 11.10. The fundamental cycle vector belonging to e9 is zr, = e9 - e2 + e, +e4 - e6, the fundamental cut vector belonging to e4 is u, , = e4 - e, 0 - e9.

deleting an edge ei of T the remainder of the spanning tree falls into twocomponents. Let V'1 be the vertex set of the component containing theinitial vertex of e; and let V'2 be the vertex set of the component containingthe terminal vertex of ei. If Pi is the partition V = Vi u VZ then clearlyup,(ej) = bi; for 1 < j < n - 1. The cut E(V', V'2) is the fundamental cutbelonging to e; (with respect to T) and up, is the fundamental cut vector.

It is easily seen that {zc,: n < i < m} is an independent set of cycle vectors.Indeed, if z = Y- Ai zc, = 0 then for every j Z n we have 0 = z(e;) =yul"=. A5id = ).j and so every coefficient A.; is 0. Similarly the fundamentalcut vectors up,, 1 < i < n - 1, are also independent. Hence dim Z(G) zm - n + 1 and dim U(G) >- n - 1, as required.

Finally, the general case k z 1 follows immediately from the case k = 1.For if G has components G1, G2, ... , Gk then C1(G) is the orthogonal directsum of the subspaces C1(Gi), i = 1, 2, ... , k; furthermore Z(Gi) _Z(G) n C1(Gi) and U(Gi) = U(G) n C1(Gi).

The proof above shows that dim Z(G), called the cyclomatic number ofG, and dim U(G) are independent of the field over which the edge space isdefined. The use of a spanning tree in the proof is not compulsory; in somecases, for instance in the case of a planar graph, there are other natural cycleand cut bases (cf. Exercise 16).

Page 49: Graph Theory-An Introductory Course-Bela Bollobas

38 11 Electrical Networks

There are several matrices naturally associated with a graph and itsvector spaces discussed above. The adjacency matrix A = A(G) = (a;) of agraph G is the n x n matrix given by

I 1 if v; v; E E(G),a;,=0 otherwise.

In order to define the incidence matrix of a graph we again consider anorientation of the edges, as in the definition of the cycle and cut spaces. Theincidence matrix B = B(G) = (b;) of G is the n x m matrix defined by

1 if v; is the initial vertex of the edge e;,b;; _ -1 if v; is the terminal vertex of the edge e;,

0 otherwise.

There is a simple connection between the two matrices A and B.

Theorem 6. BY = D - A, where B` denotes the transpose of B and D is then x n diagonal matrix in which (D);; is d(v;), the degree of the vertex v; in G.

PROOF. What is (BB`);;? It is Y-, , b;, b;,, which is d(vi) if i = j, -1 if v; v; isan edge (if e, = v; v j is directed from v; to v;, then b;, b;, = 1(-1) _ -1and all other products are 0), and 0 if v; v; is not an edge and i 0 j.

We may and will identify the matrices A and B with the linear mapsA: C0(G) - C0(G) and B: C1(G) C0(G) they define in the standard bases:(Ax); = Yj=l a;;x; and (By), b;;y;. If we wanted to be pedantic,we would write the vectors in the vertex and edge spaces as column vectors,or we would put Ax` and By, where t stands for transposition; we shall notdo this since there is no danger of confusion. If C is a cycle then clearlyBzc = 0 e C0(G); in fact, it is easily shown (cf. Exercise 17) that the cyclespace is exactly the kernel of B. Thus the rank of B is r(B) = m - (m - n + k)= n - k. Furthermore, the transpose of B maps C0(G) into C1(G), and theimage of B' is exactly the cut space (cf. Exercise 18).

In Chapter VIII we shall discuss in some detail the eigenvalues and eigen-vectors of the adjacency matrix.; in this section we shall use the matrices tosolve the electrical network problem discussed in the first section. In fact,it was Kirchhoff who first realized the applicability of matrix algebra tograph theory, exactly in connection with the electrical network problem.

How can we formulate the Kirchhoff laws in terms of matrices and vectorsin the edge space? Let us assume that G' is the graph of our electrical network;V(G') = {v1, v2, ... , 1}, E(G) = {el, e2, ... , em.}, the network is con-nected and we have a voltage generator ensuring that the potential differencebetween v, and v; is g; - g; volts for 1 < i < j < k. In order to expressKirchhoff's laws in a neat form, we add a vertex v to G', and join it tov1, v2,..., Vk; the new graph is G. Let m = m' + k and em,+; = i =1, 2, ... , k, so that V(G) = {v1, v2, ... , and E(G) = {e1, e2, ... , em}.

Page 50: Graph Theory-An Introductory Course-Bela Bollobas

§3 Vector Spaces and Matrices Associated with Graphs 39

Give the edges of G' an arbitrary orientation and let wi be the amount ofcurrent flowing in the edge ei in the direction of ei; thus wi = -1 means acurrent of 1 ampere in the opposite direction. Direct each new edgefrom v to vi and let w..+i be the total current entering the network at vi.Once again, +i = -1 means that a current of 1 ampere leaves the networkat vi. The vector w = (w1, w2, ... , e C1(G) is the current vector. In thisnotation Kirchhoff's current law takes the form

Bw = 0. (1)

We have no greater difficulty in formulating Kirchhoff's potential lawin matrix form. Let pi be the potential difference in the edge ei and let p =(Pt, P2, ... , pm) a CI(G) be the potential vector. The potential law states that<z, p> = 0 for every cycle z e C1(G). Instead of postulating this about everycycle, we collect all necessary information into a single matrix. As before, wechoose a spanning tree Tin G and label the edges so that e1, e2, .. ., 1

are the tree edges and e,,, 1, ... , em are the chords. Let C be the m x(m - n + 1) matrix whose ith column is the fundamental cycle vectorzc, _ , ,, belonging to the edge e _ 1 +i, i = 1, 2, ... , m - n + 1. Since thefundamental cycle vectors form a basis of the cycle space, the potential lawtakes the form

CP = 0, (2)

where Cdenotes the transpose of C.Now in order to find the current through the edges of G' we need one

more equation, namely the equation relating the potential to the current,the resistance and the voltage generator. For i < m' let ri be the resistanceof the edge ei and postulate that each new edge ej (j Z m' + 1) has resistancer; = 0. We may assume that ri > 0 for every i 5 m' since otherwise the edgeei could have been cut. Let R be the m x m diagonal matrix with (R)ii = r,.Finally, let g = (0, ... , 0, g1, g2, ... , gi,) e C1(G) be the vector of the voltagegenerator. Then clearly

p=Rw+g. (3)

This equation contains all the information we have about the electric currentin addition to the Kirchhoff laws.

In order to solve (1), (2) and (3) for w and p, we shall split C1(G) as ET + EN,where ET is the subspace spanned by the tree edges and EN is spanned by thechords, the edges not belonging to T. Let w = (WT, wN) and p = (PT, PN)be the corresponding splittings; furthermore, writing B for the matrixobtained from B by omitting the last row, we have

C = (CT) and $ = (BT BN)N

As the columns of C are the fundamental cycles, CN is the (m - n + 1) x(m - n + 1) identity matrix 1. Since the kernel of B contains the cycles,

Page 51: Graph Theory-An Introductory Course-Bela Bollobas

40 II Electrical Networks

BC = 0 and so 9C = 0, giving BTCT = -BN. Now BT is invertible, as thereader should check (cf. Exercise 19), so

CT, = -BT'BN.

After this preparation we can easily solve our equations.

Theorem 7. The electric current w satisfying p = Rw + g is given by w =- C(C`RC) - 'C'g.

PROOF. Equation (1) implies that BTWT + BNWN = 0, SO WT = -BT'BNWN= CTWN. Hence W = CwN. Combining (2) and (3) we find that C'Rw +C`g = 0 and so (C`RC)wN = -Cg. As VRC is easily shown to be invertible,the result follows.

Clearly Theorem 7 is valid in a somewhat more general situation, notonly when G and g are defined as above. In fact, the following conditions aresufficient (and more or less necessary) for the existence of a unique currentw: g; r; = 0 for every i and the edges ej with rj = 0 form a connected subgraph.

Furthermore, the results hold for multigraphs, that is "graphs" in whichseveral edges may join the same pair of vertices. The reader may find itnecessary to check that all the concepts (incidence matrix, cycle and cutspaces, fundamental cycles and cuts) can be defined as before and the proofsof the results remain unchanged.

By considering multigraphs one can set up Theorem 7 in a slightly simplerform without adding a new vertex to the graph G' of the network. Thus if thecurrent enters G' at a vertex a and leaves it at a vertex b, then we join a to b bya new edge e of 0 resistance (even if a and b had been joined before), andpostulate (by choosing g = (0, 0, ... , 0, 1), where e is the last edge) that thepotential difference in e is 1. Using this set-up one can check that the ratioof the current in e; to the total current (that is the current in e) is indeedgiven by Theorem 1 of §1, though this checking is rather tedious and involved.On the other hand, it is very easy to express the total number of spanningtrees in a graph in terms of the incidence matrix.

To do this we make use of two facts. The first is an extension of the observa-tion that BT is invertible: the modulus of the determinant of an (n - 1)x (n - 1) submatrix of $ is 1 if the edges corresponding to the columns

form a tree and 0 otherwise (cf. Exercise 19). The second is the Cauchy-Binetformula of linear algebra, stating that if K is a p x q matrix (p < q) and L is aq x p matrix then det KL = N], det Kp L p = >P det K4, det LP. Here thesummation is over all p-subsets P of {1, 2, ... , q}, and K,. is the p x p sub-matrix of K formed by the columns of K indexed with elements of P and Lp isthe submatrix of L formed by the corresponding rows of L. Putting the twotogether we arrive at the following formula.

Theorem 8. The number of spanning trees of G is det A .

Page 52: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 41

EXERCISES

I.- Verify the formulae in the star-delta transformation.

In Exercises 2-6 all edges are assumed to have unit resistance.

2.- Calculate the resistance of the network shown in Figure 1.1 measured between thevertices 2 and 3.

3. For each different pair of vertices of a cube calculate the resistance between them.

4. What is the resistance between two adjacent vertices of (a) an octahedron, (b) adodecahedron and (c) an icosahedron?

5. Suppose each edge of a connected network is in the same number of spanningtrees. Prove that the total resistance between two adjacent vertices is (n - 1)/e,where n is the order and e is the size of the network. Verify your answers toExercise 4.

6. By applying suitable star-delta transformations, calculate the resistance of adodecahedron between the midpoints of two adjacent edges.

7. Give a detailed proof of Theorem 2.

8. Find the squared rectangle indicated in Figure 11. 11.

I

Figure II. 11. A squaring of the 69 x 61 rectangle.

9. Which squared rectangle corresponds to the network in Figure 11.12? Rotate therectangle through 90° and draw the network for this rectangle.

Figure II.12. A plane network.

10.- How many essentially different squared rectangles correspond to the networkof the cube in Exercise 3?

Page 53: Graph Theory-An Introductory Course-Bela Bollobas

42 II Electrical Networks

11. Find the tiling associated with Figure 11. 13.

Figure 11.13. A network with edges of differing resistance.

12. Find the simple perfect squared square given by the network in Figure 11.14.(This example was found in 1964 by J. Wilson.)

Figure ][1.14. A network. giving a perfect squared square.

13. Show that an equilateral triangle cannot be dissected into finitely many in-congruent equilateral triangles.

14. Prove that if a rectangular parallelepiped can be decomposed into cubes then theratios of its sides are rational.

15. Show that a cube cannot be dissected into finitely many incongruent cubes.

16. Show that in a maximal plane graph the boundaries of bounded faces form acycle basis.

17. Show that the cycle space is the kernel of the map C,(G)-+ C0(G) defined by theincidence matrix B.

18. Let B` be the transpose of B. Show that the cut space is the image of the mapC0(G) -, CI(G) defined by M.

19. Let F be a set of n - 1 edges of a graph of order n with incidence matrix B. LetLIF be an (n - 1) x (n - 1) submatrix of B whose columns correspond to theedges of F. Prove that BF is invertible if F is the edge set of a tree.

20. Deduce from Theorem 8 that there are n"-Z trees on n distinguishable vertices.

Page 54: Graph Theory-An Introductory Course-Bela Bollobas

Notes 43

Notes

The first squared square was published by R. Sprague, Beispiel einer Zer-legung des Quadrats in lauter verschiedene Quadrate, J. Reine Angew. Math.182 (1940) 60-64, closely followed by R. L. Brooks, C. A. B. Smith, A. H.Stone and W. T. Tutte, The dissection of rectangles into squares, Duke Math.J. 7 (1940) 312-340. The square shown in Fig. 11.8 was published in A. J. W.Duijvestijn, Simple perfect square of lowest order, J. Combinational TheorySer. B 25 (1978) 240-243.

The original proof of Theorem 4 is due to Max Dehn, Ober die Zer-legung von Rechtecken in Rechtecke, Math. Ann. 57 (1903) 314-322. Twosurvey articles the reader may wish to look at are W. T. Tutte, The quest ofthe perfect square, Amer. Math. Monthly 72 (1965), 29-35 and N. D. Kaza-rinoff and R. Weitzenkamp, Squaring rectangles and squares, Amer. Math.Monthly 80 (1973) 877-888.

Page 55: Graph Theory-An Introductory Course-Bela Bollobas

CHAPTER III

Flows, Connectivity and Matching

The results of this chapter have many applications in diverse branches inmathematics; in particular, Hall's marriage theorem is a useful tool inalgebra and analysis. Every result we are going to present is a necessary andsufficient condition for the existence of certain objects: in each case thebeauty of the theorem is that a condition whose necessity is obvious is shownto be also sufficient. In the natural formulation of our results we shall havetwo functions, say f and g, clearly satisfying f < g, and we shall show thatmax f = min g. The results of the chapter are closely interrelated so theorder they are proved in is a matter of taste; to emphasize this, some resultswill be given several proofs.

In the first chapter we looked at the simplest properties of connectivity.Now we shall go a step further and in §2 we shall prove the basic theoremabout connectivity, namely Menger's theorem, first proved in 1927. Thistheorem turns out to be one of the many consequences of a fundamentaltheorem about flows in directed graphs, the max-flow min-cut theorem.

Though this book is devoted almost exclusively to undirected graphs, weintroduce in the first paragraph the concept of a flow in a directed graphand go on to prove the max-flow min-cut theorem, partly because it pro-vides one of the simplest proofs of Menger's theorem and partly becauseit has a number of other important consequences concerning undirectedgraphs.

A set of independent edges in a graph is called a matching. In a bipartitegraph a matching can be identified with a flow and the max-flow min-cuttheorem takes the form of another widely applicable combinatorial result,Hall's marriage theorem. We discuss various forms of this result in §3.

Though we deduce the theorems of both Menger and Hall from themax-flow min-cut theorem, the results are in fact very closely related, and

44

Page 56: Graph Theory-An Introductory Course-Bela Bollobas

§1 Flows in Directed Graphs 45

because of their fundamental importance we give also independent proofsof each.

Hall's theorem tells us, in particular, when a bipartite graph has got a1 -factor, a subgraph whose vertex set is that of the original graph and inwhich every vertex has degree 1. The question of the existence of a 1-factorin an arbitrary graph is considerably harder. It is answered by a theorem ofTutte that we present in §4.

§1 Flows in Directed Graphs

Let G be a (finite) directed graph with vertex set V and edge set E. We shallstudy (static) flows in G from a vertex s (the source) to a vertex t (the sink).A flow f is a non-negative function defined on the edges; the value f (xy)is the flow or current in the edge zy. For notational simplicity we shall writef (x, y) instead off (xy) and a similar convention will be used for other func-tions. The only condition a flow from s to t has to satisfy is Kirchhoff'scurrent law: the total current flowing into each intermediate vertex (that isvertex different from s and t) is equal to the total current leaving the vertex.Thus if for x E V we put

h+(x)= {yeV:zyeE'},

F (x) = {y e V: TX C -E),

then a flow from s to t satisfies the following condition:

Y f (x, y) = Y f (z, x) for each x E V - {s, t j.yEr'(X) ZEr-(X)

Since

o = Efyer+(x)E f (x, y) - f (z, x)}

XEV-{s,t} ZEr-(X)

_ Y Izer-wY_ f (z, u) - Y_ f (u, Y)}

UE(S,t) yEr'(u)

we find that

Y_ f (s, y) - Y_ f (y, s) _ Y_ f (y, t) - Y_ f (t, y).yer`(s) yer-(s)

The common value, denoted by v(f), is called the value off or the amount offlow from s to t.

We wish to determine the maximal flow value from s to t provided theflow satisfies certain constraints. First we shall deal with the case when the

Page 57: Graph Theory-An Introductory Course-Bela Bollobas

46 111 Flows, Connectivity and Matching

so called capacity of an edge restricts the current through the edge. It willturn out that several other seemingly more complicated restrictions can bereduced to this case.

Let us fix our directed graph G = (V, E) and two vertices in it, say s andt. With each edge xy of d we associate a non-negative number c(x, y), calledthe capacity of the edge. We shall assume that the current flowing throughthe edge zy cannot be more than the capacity c(x, y).

Given two subsets X, Y of V we write E(X, Y) for the set of directedX-Y edges:

E(X, Y) _ {xy: x c- X, y e Y}.

Whenever g: J is a function, we put

g(X, Y) = I g(x, Y),

where the summation is over E'(X, Y). If S is a subset of V containing s butnot t then QS, S) is called a cut separating s from t. (Here S = V - S.) Ifwe delete the edges of a cut then no positive-valued flow from s to t can bedefined on the remainder. Conversely, it is easily seen that if F is a set ofedges after whose deletion there is no flow from s to t (that is v(f) = 0 forevery flow from s to t) then F contains a cut (Exercise 1). The capacity of acut E(S, S) is c(S, S) (see Figure III.1). It is easily seen (Exercise 2) that thecapacity of a cut is at least as large as the value of any flow, so the minimumof all cut capacities is at least as large as the maximum of all flow values.The celebrated max-flow min-cut theorem of Ford and Fulkerson statesthat this trivial inequality is, in fact, an equality. Before stating this theoremand getting down to the proof, let us justify the above use of the wordsminimum and maximum. Since there are only finitely many cuts, there is acut whose capacity is minimal. The existence of a flow with maximal valueis only slightly less trivial. Indeed,

v(f) <- Y_ c(x, Y)XyEE

for every flow f, so v = sup v()^) < x. Let ft, J'2.... be a sequence of flowswith lim v(f,) = v. Then, by passing to a subsequence, we may assume thatfor each zy e f the sequence (f (x, y)) is convergent, say to f (x, y). The

Figure III.!. A cut with capacity 12. (The numbers next to the edges indicate theircapacity.)

Page 58: Graph Theory-An Introductory Course-Bela Bollobas

§1 Flows in Directed Graphs 47

function f is a flow with value v, that is a flow with maximal value. In a similarway one can show that even if some of the edges have infinite capacity, thereis a flow with maximal value which can be either finite or infinite (Exercise 3).

Theorem 1. (Max-flow min-cut theorem.) The maximal flow value from s to tis equal to the minimum of the capacities of cuts separating s from t.

PROOF. We have remarked already that there is a flow f with maximal value,say v, and the capacity of every cut is at least v. Thus, in order to prove thetheorem we have to show that there is a cut with capacity v. We shall, infact, do considerably more than this: we shall give a very simple procedurefor constructing such a cut from a flow f with maximal value.

Define a subset S c V recursively as follows. Let s e S. If x e S and

c(x, Y) > f (x, Y)or

f (Y, x) > 0then let y E S.

We claim that QS, S) is a cut separating s from t with capacity v = v(f ).Let us see first why t cannot belong to S. If t belongs to S, we can find verticesx0 = s, x1, ... , x, t such that

E; = max{c(xi, xi+1) - f(xi, xi+1),f(xi+1, xi)) > 0

for every i, 0 < i < I - 1. Put c = mini c;. Then f can be augmented to aflow f * in the following way: if e; > f (xi+ 1, xi) then increase the flow inxi xi + 1 by E, otherwise decrease the flow in x;+ 1 xi by e. Clearly f * is a flowand its value is v(f *) = v(f) + c, contradicting the maximality of f. Thisshows that t 0 S so E(S, S) is a cut separating s from t.

Now v(f) is equal to the value of the flow from S to S defined in the ob-vious way:

I f (x, Y) - Y_ f (x, Y)xES,yES xeLyES

By the definition of S the first sum is exactly

I c(x, y) = c(S,xeS,yES

and each summand in the second sum is zero. Hence c(S, S) = v(f ), asrequired.

The max-flow min-cut theorem is the cornerstone of the theory to bepresented in this chapter. Note that the theorem remains valid (with ex-actly the same proof) if some of the edges have infinite capacity but themaximal flow value is finite.

The proof of the theorem also provides a surprisingly efficient algorithmfor finding a flow with maximal value if the capacity function is integral,

Page 59: Graph Theory-An Introductory Course-Bela Bollobas

48 III Flows, Connectivity and Matching

that is if c(x, y) is an integer for every edge zy. We start with the identicallyzero flow: fo(x, y) = 0 for every :ry c k We shall construct an increasingsequence of flows fo, fl, f2, ... that has to terminate in a maximal flow.Suppose we have constructed J;. As in the proof above, we find the set Sbelonging to fi. Now if t 0 S then f is a maximal flow (and E(S, S) is a minimalcut) so we terminate the sequence. If, on the other hand, t e S, then fi can beaugmented to a flow f + 1 by increasing the flow along a path from s to t.Since each v(f,) is an integer, we have v(f) >_ v(f _ 1) + 1, and the sequencemust end in at most E. ,,, c(x, y) steps.

Moreover, if c is integral the algorithm constructs a maximal flow whichis also integral, that is a flow whose value is an integer in every edge. Indeed,fo is integral and if f _ 1 is integral then so is f , since it is obtained from fi _ 1

by increasing the flow in a path by a value which is the minimum of positiveintegers. This result is often called the integrality theorem.

Theorem 2. If the capacity function is integral then there is a maximal flowwhich is also integral.

We shall rely on this simple result when we use the max-flow min-cuttheorem to find various paths in graphs. It is important to note that theresults do not claim uniqueness: the algorithm finds one of the maximalflows (usually there are many) and Theorem 2 claims that one of the maximalflows is integral.

The existence of the algorithm proves some other intuitively obviousresults as well. For instance, there is a maximal acyclic flow, that is one whichdoes not contain a flow around a cycle x1x2 ... Xk (see Exercise 4):

f(x1, X2) > 0,f(X2, x3) > 0, ... ,f(xk-1, Xk) > O,f(Xk, X1) > 0.

It may seem somewhat surprising that if instead of one source and onesink we take several of each, the situation does not become any more com-plicated. The only occasion we have to be a little more careful is the defini-tion of a cut. If s1, ... , sk are the sources and t1, ... t, are the sinks thenE(S, S) is a cut ifs, e S and t; E S for every i, j, 1 < i < k, 1 < j < 1.

In order to be able to apply the max-flow min-cut theorem, let us add anew source s and a new sink t to G, together with all the edges ssi and t; tof infinite capacity. Let H be the graph obtained in this way. Consider thoseflows from s1, ... , Sk to t1, ... , t, in G in which the total current entering(leaving) a source (sink) is not greater than the total current leaving (en-tering) it. These flows can easily be extended to a flow from s to t in H andthis extension establishes a 1-1 correspondence between the two sets offlows. Furthermore, a cut separating s from t in H that has finite capacitycannot contain an edge of the form ssi and tj t, so it corresponds to a cutof the same capacity in G, separating s1, ... , Sk from t1, ... , t,. Thus Theo-rem 1 has the following extension.

Page 60: Graph Theory-An Introductory Course-Bela Bollobas

§1 Flows in Directed Graphs 49

Theorem 3. The maximum of the flow value from a set of sources to a set ofsinks is equal to the minimum of the capacity of cuts separating the sourcesfrom the sinks.

Let us assume now that we have capacity restrictions on the vertices,except the source and the sink. Thus we are given a function c: V - Is, t} -R+ and every flow f from s to t has to satisfy the following inequality:

Y_ f (x, y) _ Y_ f (z, x) < c(x) for every x E V - Is, t}.yEr`(x) zer-(x)

How should we define a cut in this situation? A cut is a subset S of V - Is, t}such that no positive-valued flow from s to t can be defined on G - S. (Inorder to distinguish the two kinds of cuts we sometimes call this a vertex-cutand the other one an edge-cut. However, it is almost always clear which cutis in question.) Can we carry over the max-flow min-cut theorem to thiscase? Yes, very easily, if we notice that a flow can be interpreted to flow in avetex as well, namely from the part where all the currents enter it to the partwhere all the currents leave it. More precisely we can turn each vertex of Ginto an edge (without changing the nature of the directed graph) in such away that any current entering (and leaving) the vertex will be forced throughthe edge. To do this, replace each vertex x e V - Is, t} by two vertices, sayx - and x + , send each incoming edge to x - and send each outgoing edge tox+. Finally, add edges from x_ to x+ with capacity c(x_, x+) = c(x) (seeFigure 111.2). There is a simple 1-1 correspondence between the flows from

Figure III.2. Replacing a graph G with restrictions on the capacity of the vertices by agraph H with restrictions on the capacity of the edges.

s to t in G satisfying the capacity restrictions on the vertices and the flowsin the new graph H satisfying the capacity restrictions on (some of) theedges. Since in H only the edges x_x+ have finite capacities, an edge-cutof finite capacity in H consists entirely of edges of the form T_ x+ , so itcorresponds to a vertex-cut in G of the same capacity. Thus we have thefollowing form of Theorem 1.

Theorem 4. Let G be a directed graph with capacity bounds on the verticesother than the source s and the sink t. Then the minimum of the capacity of avertex-cut is equal to the maximum of the flow value from s to t.

Page 61: Graph Theory-An Introductory Course-Bela Bollobas

50 III Flows, Connectivity and Matching

Theorems 1, 3 and 4 can easily be combined into a single theorem. Weleave this to the reader (Exercise 6).

§2 Connectivity and Menger's Theorem

Recall that if any two vertices of a graph can be joined by a path then thegraph is said to be connected, otherwise it is disconnected. A maximal con-nected subgraph of a graph G is a component of G.

If G is connected and G - W is disconnected, where W is a set of verticesor a set of edges, then we say that W separates G. If in G - W two vertices sand t belong to different components then W separates s from t. We saythat a graph G is k-connected (k >_: 2) if either G is a Kk+ t or else it has atleast k + 2 vertices and no set of i - 1 vertices separates it. Similarly G isk-edge-connected (k >- 2) if it has at least two vertices and no set of at mostk - 1 edges separates it. A connected graph is also said to be 1-connectedand 1-edge-connected. The maximal value of k for which a connected graphG is k-connected is the connectivity of G, denoted by K(G). (If G is discon-nected, we put K(G) = 0.) The edge-connectivity 1(G) is defined analogously.

Clearly a graph is 2-connected if it is connected, has at least 3 verticesand contains no cutvertex. Similarly, a graph is 2-edge-connected if it isconnected, has at least 2 vertices and contains no bridge. It is often easy todetermine the connectivity of a given graph. Thus if 1 < I < n then K(P') =2(P`) = 1, K(C") = 1(C") = 2, K(K") = 2(K") = n - I and x(K`, ") = 2(K',")= 1. In order to correct the false impression that the vertex-connectivity isequal to the edge-connectivity, note that if G is obtained from the disjointunion of two K' by adding a new vertex x and joining x to every old vertex,then x(G) = 1, since x is a cutvertex, but 1(G) = I (see also Exercise 11).This last example shows that 1(G - x) may be 0 even when 1(G) is large.However, it is clear from the definitions that for every vertex x and edge xywe have

x(G) - 1 < K(G - x) and .1(G) - 1 < l(G - xy) < 2(G).

If G is non-trivial (that is has at least two vertices), then the parametersS(G), 2(G) and K(G) satisfy the following inequality:

K(G) < 1(G) < S(G).

Indeed, if we delete all the edges incident with a vertex, the graph becomesdisconnected, so the second inequality holds. To see the other inequality,note first that if G is complete then x(G) = 1(G) = I G I - 1, and if A(G) < 1then 1(G) = K(G). Suppose now that G is not complete, 2(G) = k >- 2 and{xtyt, x2y2, ... , xkyk} is a set of edges disconnecting G. If G -{x1, x2, ... , xk} is disconnected then x(G) < k. Otherwise each vertex xi

Page 62: Graph Theory-An Introductory Course-Bela Bollobas

§2 Connectivity and Menger's Theorem

X4

51

Figure 111.3. A 4-edge-connected graph G such that G - {x1, x2, x3, x4} is connected.

has degree at most k (and so exactly k), as shown in Figure 111.3. Deletingthe neighbours of x1, we disconnect G. Hence x = 1(G).

Another property immediate from the definition of vertex-connectivityis that if G1 and G2 are k-connected (k >- 1) subgraphs of a graph G havingat least k common vertices, then G1 u G2 is also k-connected. Indeed ifW c V(G1) u V(G2) has at most k - I vertices, then there is a vertex xin V(G1) n V(G2)\W. Therefore the connected subgraphs G1 - W andG2 - W of G have at least one vertex, namely x, in common, so G1 u G2 -W = (G1 - W) u (G2 - W) is connected.

Having seen in Chapter I how useful it is to partition a graph into itscomponents, that is into its maximal connected subgraphs, let us attempt asimilar decomposition using all maximal 2-connected subgraphs. A sub-graph B of a graph G is a block of G if either B is a bridge (and its endvertices)or else it is a maximal 2-connected subgraph of G. The remarks above showthat any two blocks have at most one vertex in common and if x, y aredistinct vertices of a block B then G - E(B) contains no x-y path. Thereforeevery vertex belonging to two blocks is a cutvertex of G, and, conversely,every cutvertex belongs to at least two blocks. Recalling that a cycle is 2-connected and an edge is a bridge if no cycle contains it, we find that Gdecomposes into its blocks B1, B2, ... , BP in the following sense:

P

E(G) = UE(B;) and E(B) n E(B;) _ 0 if i j.1

Suppose now that G is a non-trivial connected graph. Let bc(G) be thegraph whose vertices are the blocks and cutvertices of G and whose edgesjoin cutvertices to blocks: each cutvertex is joined to the blocks containingit. Then bc(G), called the block-cutvertex graph of G, is a tree. Each end-vertex of bc(G) is a block of G, called an endblock of G. If G is 2-connectedor it is a K2 (an "edge") then it contains only one block, itself; otherwisethere are at least two endblocks, and a block is an endblock if it containsexactly one cutvertex (Figure III.4).

The basic result in the theory of connectivity was proved by Menger in1927. It is the analogue of the max-flow min-cut theorem for (non-directed)graphs. Recall that two s-t paths are independent if they have only the verticess and t in common.

Page 63: Graph Theory-An Introductory Course-Bela Bollobas

52 III Flows, Connectivity and Matching

Figure 111.4. The construction of the block-cutvertex tree bc(G). B, is an endblock.

Theorem 5.

i. Let s and t be distinct non-adjacent vertices of a graph G. Then the minimalnumber of vertices separating s from t is equal to the maximal number ofindependent s-t paths.

ii. Let s and t be distinct vertices of G. Then the minimal number of edgesseparating s from t is equal to the maximal number of edge-disjoint s-tpaths.

PROOF. (i) Replace each edge xy of G by two directed edges, xy and yx, andgive each vertex other than s and t capacity 1. Then by Theorem 4 themaximal flow value from s to t is equal to the minimum of the capacity of acut separating s from t. By the integrality theorem (Theorem 2) there is amaximal flow with current I or 0 in each edge. Therefore the maximum flowvalue from s to t is equal to the maximal number of independent s-t paths.The minimum of the cut capacity is clearly the minimal number of verticesseparating s from t.

(ii) Proceed as in (i), except instead of restricting the capacity of thevertices, give each directed edge capacity 1.

The two parts of the above theorem are called the vertex form of Menger'stheorem and the edge form of Menger's theorem. One can easily deducethe edge form from the vertex form (Exercise 14), but the other implicationis not so easily proved. Since, as we have mentioned already, the max-flowmin-cut theorem can also be deduced from Menger's theorem, we shall giveanother proof of the vertex form of Menger's theorem from first principles.

SECOND PROOF OF THE VERTEX FORM OF MENGER'S THEOREM. Denote by kthe minimal number of vertices separating s and t. Then clearly there areat most k independent s-t paths and for k <_ 1 there are k independent s-tpaths.

Suppose the theorem fails. Take the minimal k >- 2 for which there is acounterexample to the theorem and let G be a counterexample (for theminimal k) with the minimal number of edges. Then there are at most k - 1independent s-t paths and no vertex x is joined to both s and t, otherwiseG - x would be a counterexample for k - 1.

Page 64: Graph Theory-An Introductory Course-Bela Bollobas

§3 Matching 53

Let W be a set of k vertices separating s from t. Suppose neither s nor tis adjacent to every vertex in W. Let Gs be obtained from G by replacingthe component of G - W containing s by a single vertex s' and joining s'to each vertex in W. In G, we still need k vertices to separate s' from t andsince the component we collapsed had at least two vertices, G, has feweredges than G. Since G is a counterexample of minimal size, in G, there are kindependent s'-t paths. The segments of these k paths from t to W are suchthat any two of them have exactly the vertex t in common. In particular, forevery w c- W one of these paths is a t-w path. If we carry out the analogousprocedure for t instead of s then we get k paths from s to W. These two setsof paths can be put together to give k independent s-t paths, contradictingour assumption. Hence for any set W of k vertices separating s from t eithers or t is adjacent to each vertex of W.

Let sx, x2 ... x, t be a shortest s-t path. Then I > 2 and, by the minimalityof G, in the graph G - x, x2 we can find a set Wo of k - 1 vertices separatings from t. Then both Wt = {x,} u Wo and W2 = {x2} u Wo are k-setsseparating s from t. Since t is not joined to x,, s is joined to every vertex inW,. Similarly, s is not joined to x2, so t is joined to every vertex in W2. Thisimplies the contradiction that s and t have at least one common neighbour:every vertex in Wo is a common neighbour of s and t and I Wo I = k - 1 > 1.

Corollary 6. A graph is k-connected (k > 2) f it has at least two vertices andany two vertices can be joined by k independent paths. A graph is k-edge-connected (k Z 2) iff it has at least two vertices and any two vertices can bejoined by k edge-disjoint paths.

Another characterization of k-connectivity is given in Exercise 12.Corresponding to the max-flow min-cut theorem for multiple sources

and sinks, one has the following version of Menger's theorem. If S and Tare arbitrary subsets of vertices of G then the maximal number of vertex-disjoint (including endvertices!) S-T paths is min{ I W 1: W c V(G), G - Whas no S-T path}. To see this add two new vertices to G, say s and t, join sto every vertex in S and t to every vertex in T, and apply Menger's theoremto the vertices s and t in the new graph.

§3 Matching

Given a finite group G and a subgroup H of index m, can you find m elementsof G, say gt, 92, ... , g,,,, such that [g, H, g2H, ... , g,. H} is the set of leftcosets of H and {Hg,, Hg2, ... , Hg,,,} is the set of right cosets? A reformula-tion of this problem turns out to be a special case of the following problemarising frequently in diverse branches of mathematics. Given a family

Page 65: Graph Theory-An Introductory Course-Bela Bollobas

54 111 Flows, Connectivity and Matching

.sad = {A1, A2, ... , Am} of subsets of a set X, can we find m distinct elementsof X, one from each Ai? A set {x1, x2, ... , x,,} with these properties (i.e.xi e Ai, xi # x j if i # j) is called a set of distinct representatives of the family.sat'. The set system sat is naturally identifiable with a bipartite graph withvertex classes V1 = sat and V2 = X in which A, a si is joined to every x e Xcontained in Ai. A system of distinct representatives is then a set of m in-dependent edges (thus each vertex in V1 is incident with one of these edges).We also say that there is a complete matching from V1 to V2.

It is customary to formulate this problem in terms of marriage arrange-ments. Given m girls and n boys, under what conditions can we marry offall the girls provided we do not want to carry matchmaking as far as to marrya girl to a boy she does not even. know?

It is clear that both the max-flow min-cut theorem and Menger's theoremimply a necessary and sufficient condition for the existence of a completematching. In fact, because of the special features of a bipartite graph, thereis a particularly simple and pleasant necessary and sufficient condition.

If there are k girls who altogether know at most k - 1 boys then we cannotfind suitable marriages for these girls. Equivalently, if there is a completematching from V1 to V2 then for every S c V1 there are at least ISI verticesof V2 adjacent to a vertex in S, that is

IF(S)I z ISI.The result that this necessary condition is also sufficient is usually calledHairs theorem. (P. Hall proved it in 1935, and an equivalent form of it wasproved by Konig and Egervary in 1931, but both versions follow immediatelyfrom Menger's theorem, proved in 1927.) We shall give three proofs. Thefirst is based on Menger's theorem or the max-flow min-cut theorem, theother two prove the result from first principles.

Theorem 7. A bipartite graph G with vertex sets V1 and V2 contains a completematching from V1 to V2 if

I F(S) 12t I S I for every S c V1.

We have already seen that the condition is necessary so we have to proveonly the sufficiency.

1ST PROOF. Both Menger's theorem (applied to the sets V1 and V2, as at theend of §2) and the max-flow min-cut theorem (applied to the directed graphobtained from G by sending each edge from V1 to V2, in which each vertexhas capacity 1) imply the following. If G does not contain a complete match-ing from V1 to V2 then there are T1 c V1 and T2 c V2 such that I T1 I +

I T2 I < I Vt I and there is no edge from V1 - T1 to V2 - T2. Then01 - T1) c T2 so

.TI I

This shows the sufficiency of the condition.

Page 66: Graph Theory-An Introductory Course-Bela Bollobas

§3 Matching 55

2ND PROOF. In this proof, due to Halmos and Vaughan, we shall use thematchmaking terminology. We shall apply induction on m, the number ofgirls. For m = 1 the condition is clearly sufficient so we assume that m >- 2and the condition is sufficient for smaller values of m.

Suppose first that any k girls (1 5 k < m) know at least k + I boys.Then we arrange one marriage arbitrarily. The remaining sets of girls andboys still satisfy the condition, so the other m - 1 girls can be married offby induction.

Suppose now that for some k, there are k girls who altogether know ex-actly k boys. These girls can clearly be married off by induction. Whatabout the other girls? We can marry them off (again by induction) if theyalso satisfy the condition provided we do not count the boys who are alreadymarried. But the condition is satisfied since if some I girls to be marriedknow fewer than I remaining boys then these girls together with the first kgirls would know fewer than k + I boys.

3RD PROOF. This proof is due to Rado. Let G be a minimal graph satisfyingthe condition. It suffices to show that G consists of I V1 I independent edges.

If this is not so then G contains two edges of the form a1 x, a2 x, wherea1, a2 a V1 and x e V2. Since the deletion of either of these edges invalidatesthe condition, there are sets A 1, A2 C V1 such that I I'(Ai) I = I A;1 and a,is the only vertex of Ai(i = 1, 2) adjacent to x. Then

IF(A1) n r(A2)I = II'(A1 - {al}) n I'(A2 - {a2})I + 1>-IF(A1 r A2)I+1>IA1 nA21+1,

which implies the following contradiction:

Ir(A1 u A2)I = Ir'(A1) u r(A2)1 = Ir(A1)I + Ir(A2)I- Ir(A1)nr(A2)ISIA11+IA21-IA1 nA21-1.

A regular bipartite graph satisfies the conditions of Hall's theorem, soit has a complete matching. In turn this implies that we can indeed find groupelements g1, 92, ... , g, as required at the beginning of the section.

Let us reformulate the marriage theorem in terms of sets of distinctrepresentatives.

Theorem 7'. A family sat = {A1i A2, ... , A,,} of sets has a set of distinctrepresentatives iff

U Ai >-IFI foreveryFc{1,2,...,m}.

There are two natural extensions of the marriage theorem. Suppose themarriage condition is not satisfied. How near can we come to marrying off

Page 67: Graph Theory-An Introductory Course-Bela Bollobas

56 III Flows, Connectivity and Matching

all the girls? When can we marry off all the girls but d of them? Clearlyonly if any k of them know at least k - d boys. This obvious necessary con-dition is again sufficient.

Corollary 8. Suppose the bipartite graph G = G2(m, n) with vertex sets V1, V2satisfies the following condition:

I F(S) I z I S I - d for every S c V1.

Then G contains m - d independent edges.

PROOF. Add d vertices to V2 and join them to each vertex in V1. The newgraph G* satisfies the condition for a complete matching. At least m - dof the edges in this matching belong to G.

The next extension concerns matchmaking for boys in a polygynouscountry, where the ith boy intends to marry di girls.

Corollary 9. Let G be a bipartite graph with vertex classes V1 = {x1, ... , x,,}and V2 = {yl,... , Then G contains a subgraph H such that dH(xi) = diand 0 < dH(yi) 5 1 if

T(S) I > ` di for every S c V1.

xi each vertex in F'(xi).Then there is a subgraph H if the new graph has a matching from the newfirst vertex class to V2. The result i'ollows from Theorem 7.

Of course, Corollary 9 also has a defect form which the reader is en-couraged to state and deduce from this.

The reader is probably aware of the fact that these corollaries are stillspecial cases of the max-flow min-cut theorem. In fact, the bipartite graphversion of the max-flow min-cut theorem is considerably more generalthan the corollaries above.

Theorem 10. Let G = G2(m, n) be a bipartite graph with vertex classesV 1 = {x1, ... , xm} and V 2 = { y , . .. , For S c V1 and 1 S j 5 n denoteby Si the number of edges from yj to S. Let dl,..., dm and et, ... , e be naturalnumbers and let d >- 0. Then there exists a subgraph H of G with

m

e(H)z d, - d,

dH(xi)<di, 1 Si5mand

d11(y) Se;, 1 5jSn,

Page 68: Graph Theory-An Introductory Course-Bela Bollobas

§3 Matching 57

Uf for every S c V1 we haven

d; < E min{Sj, ej} + d.x,ES j=1

PROOF. Turn G into a directed graph G by sending each edge from V1 to V2.Give each edge capacity 1, a vertex xi capacity d; and a vertex y j capacity e j.Then there is a subgraph H with required properties if in (i there is a flowfrom V1 to V2 with value at least Yi d; - d and, by the max-flow min-cuttheorem, this happens iff every cut has capacity at least Em d, - d. Nowminimal cut-sets are of the form T u U u E(V1 - T, V2 - U), whereT c V1 and U c V2. Given a set T, the capacity of such a cut will be minimalif a vertex yj belongs to U if its capacity is smaller than the number of edgesfrom S = V1 - T to yj. With this choice of U the capacity of the cut isexactly

d. + min{Sj, ej}.xje T 1

The condition that this is at least Yi d. - d is clearly the condition in thetheorem.

The reader is invited to check that the second proof of Theorem 7 can berewritten word for word to give a proof of the exact form of this result (thatis with d = 0) and the defect form (the case d z 0) can be deduced from itas Corollary 8 was deduced from Theorem 7 (Exercise 26).

To conclude this section we prove another extension of the marriagetheorem. This is Dilworth's theorem concerning partially ordered sets. Apartial order < on a set is a transitive and irreflexive relation defined onsome ordered pairs of elements. Thus if x < y and y < z then x < z, butx < y and y < x cannot both hold. A set with a partial order on it is apartially ordered set. The relation x 5 y expresses the fact that either x = yor else x < y. A subset C of a partially ordered set P is a chain (or tower) iffor x, y e C either x< y or y < x. A set A CF is an antichain if x< yimplies that {x, y} ¢ A. See Figure 111.5 for an example.

Figure 111.5. A partially ordered set and a maximal antichain. (An edge indicatesthat its upper endvertex is greater than its lower endvertex.)

Page 69: Graph Theory-An Introductory Course-Bela Bollobas

58 III Flows, Connectivity and Matching

What is the smallest number of chains into which we can decompose apartially ordered set? Since no two elements of an antichain can belong tothe same chain, we need at least as many chains as the maximal size of anantichain. Once again, the trivial necessary condition is, in fact, sufficient.

Theorem 11. If every antichain in a (finite) partially ordered set P has at mostm elements then P is the union of m chains.

PROOF. Let us apply induction on I P I. If P = 0 there is nothing to proveso we suppose that I P I > 0 and the theorem holds for sets with fewer ele-ments.

Let C be a maximal chain in P. (Thus if x 0 C then C u {x} is no longer achain.) If no antichain of P - C has m elements then we are home by in-duction. Therefore we may assume that P - C contains an antichainA = {ai,a2,...,am}.

Define the lower shadow of A as

S- = {x E P: x < ai for some i},

and define the upper shadow S+ of A analogously. Then P is the union of thetwo shadows since otherwise A could be extended to an antichain withm + 1 elements. Furthermore, neither shadow is the whole of P since themaximal element of C does not belong to S- and the minimal element of Cdoes not belong to S. By the induction hypothesis both shadows can bedecomposed into m chains, say

m m

S- =UCH and S' U C,:'.1 1

Since different ai belong to different chains, we may assume that ai a Ciand ai a Ci .

The proof will be completed if we show that a, is the maximal element ofCi and the minimal element of C, t. For in that case the chains Ci- and C,:'can be strung together to give a single chain Ci and then P = Ui Ci.

Suppose then that, say, ai is not the maximal element of Ci : ai < x forsome x e C,-. Since x is in the lower shadow of A, there is an a; e A withx < a;. However, this implies the contradiction ai < as.

§4 Tutte's 1-Factor Theorem

A factor of a graph is a subgraph whose vertex set is that of the whole graph.If every vertex of a factor has degree r then we call it an r factor. How canwe characterize graphs with a 1-factor? If G has a 1-factor H and we deletea set S of vertices of G, then in a component C of G - S an even numberof vertices are on edges of H contained in C and the other vertices of C are

Page 70: Graph Theory-An Introductory Course-Bela Bollobas

§4 Tutte's I-Factor Theorem 59

Figure 111.6. A graph G with a 1-factor: ISI = 4 and G - S has 2 odd components.

on edges of H joining a vertex of C to a vertex of S. In particular, for everyodd component C of G - S (that is a component with an odd number ofvertices) there is an edge of H joining a vertex of C to a vertex of S. Now theedges of H are independent, so this implies that the graph G - S has atmost IS I odd components, one for each vertex in S (see Figure 111.6).

The necessity of the condition we have just found is rather trivial, but itis not clear at all that the condition is also sufficient. This surprising anddeep result was first proved by Tutte in 1947. It will be convenient to denoteby q(H) the number of odd components of a graph H, that is the number ofcomponents of odd order.

Theorem 12. A graph G has got a 1 factor iff

q(G - S) < I S I for every S c V (G). (*)

PROOF. We know that the condition is necessary. We shall prove the suffi-ciency by induction on the order of G. For I G I = 0 there is nothing to prove.Now let G be a graph of order at least one satisfying (*) and suppose thatthe theorem holds for graphs of smaller order.

Let So c V(G) be a non-empty set for which equality holds in (*). Denoteby C,, C2, ... , Cm, M = ISO I Z 1, the odd components of G - So and letD,, D2,... , D, be the even components of G - So. If the theorem is trueand G does contain a 1-factor F then for each C; there is at least one edgeof F that joins a vertex of C; to a vertex in So. Since m = I So 1, for each C.there is exactly one such edge, say c, s,, c; e C,, s; e So. Each C; - c; containsa 1-factor, (a subgraph of F), and each D, contains a 1-factor (a subgraph ofF). Finally, the edges s,c,, s2 c2, ... , sC. form a complete matching fromSo into the set {C1, C2, ... , Cm}.

The proof is based on the fact that one can find an So which has all theproperties described above. How shall we find such a set So? Let So be amaximal non-empty subset of V(G) for which equality holds in (*). Ofcourse, a priori it is not even clear that there is such a set So. With S = 0the condition (*) implies that G has an even order. If s is any vertex of Gthen G - {s} has odd order so it has at least one odd component. Since (*)

Page 71: Graph Theory-An Introductory Course-Bela Bollobas

60 III Flows, Connectivity and Matching

holds, G - {s} has exactly one odd component. Hence for every S = {s}we have equality in (*). This establishes the existence of So.

As before, C1, C2, ... , M = ISO 1, are the odd components of G - Soand D1i D2,... , Dk are the even components.

(i) Each D; has a 1 factor. Indeed, if S c V(D) then

q(G-SouS)=q(G-So)+q(Dj -S)<ISouSI=ISoI+ISI,so

q(D; -- S) < IS 1.

Hence by the induction hypothesis D; has a 1-factor.(ii) If c e Ci then C. - c has a 1-/actor. Assume that this is false. Then by

the induction hypothesis there is a set S c V(Ci) - {c} such that

q(Ci -- {c} u S) > ISI.

Since

q(Ci - {c) u S) + I S {c} I = I Ci I = 1 (mod 2),

this implies that

q(Ci-{c} uS) - ISI+2.

Consequently

ISO u{c} uSI=ISoI+1+ISI-q(G-So u{c} uS)=q(G-So)-- I +q(Ci - {c} uS)> ISOI+ I +ISI,

so in (*) we have equality for the set So u {c} u S as well. This contradictsthe maximality of So.

(iii) G contains m independent edges of the form sici, s, e So and ci E Ci,i = 1, 2, ... , m. To show this let us consider the bipartite graph H = G2(m, m)with vertex classes V1 = {C1, C21 ... , C} and V2 = So, in which Ci is joined toa vertex s c- So if and only if G contains an edge from s to Ci. The assertionabove is true if H has a 1-factor, that is a matching from V1 to V2. Fortu-nately we have got the weapon to check this: Hall's theorem. Given A C V1,put B = FH(A) c V2 (see Figure 111.7). Then (*) implies that

IAI :! q(G-B)-<IBI.

Hence the graph H satisfies Hall's condition, so it has 1-factor.We are almost home. To complete the proof we just put together the

information from (i), (ii) and (iii). We start with the m independent edgessici, si e So, ci e Ci. Adding to this set of edges a 1-factor of each Ci - ci,1 < i 5 m, and a 1-factor of each D;, 1 < j S k, we arrive at a 1-factorof G.

It is once again very easy to obtain a defect form of the above result.

Page 72: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 61

Figure 111.7. The construction of H from G. The set A = (C2, C3) determines B c Soby the rule B = 1711(A).

Corollary 13. A graph G contains a set of independent edges covering all butat most d of the vertices iff

q(G - S) S ISI + d for every S c V(G).

PROOF. Since the number of vertices not covered by a set of independentedges is congruent to I G I modulo 2, we may assume that

d m I G I (mod 2).

Put H = G + K°, that is let H be obtained from G by adding to it a set Wof d vertices and joining every new vertex to every other vertex, old and new.Then G contains a set of independent edges covering all but d of the verticesif H has got a 1-factor. When does (*) hold for H? If 0:0 S' c V(H) andW - S' 96 0 then H - S' is connected so q(H - S') S 1 and then (*) doeshold; if W c S' then with S = S' - W we have q(H - S') = q(G - {S'\W })= q(G - S), so (*) is equivalent to

q(G-S)SIS'J=ISI+d.

Ex> tcisEs

1.- Suppose F is a set of edges after whose deletion there is no flow from s tot withpositive value. Prove that F contains a cut separating s from t.

2.7 By summing an appropriate set of equations show that the capacity of a cut is atleast as large as the maximum of the flow value.

3.- Let (; = (V, E) be a directed graph and let c be an extended-real-valued capacityfunction on E. (Thus c(x, y) is a non-negative real or + oc.) Let s and t be twovertices. Prove that either there is a flow from s to t with infinite value or else thereis a flow with maximal finite value.

4. By successively reducing the number of circular flows in G, prove that there is amaximal flow without circular flows in which no current enters the source andno current leaves the sink.

5. Use the method of Exercise 4 to show that if the capacity function is integral thenthere is a maximal flow that is also integral.

Page 73: Graph Theory-An Introductory Course-Bela Bollobas

62 III Flows, Connectivity and Matching

6. Formulate and prove the max-flow min-cut theorem for multiple sources andsinks with bounds on the capacity of the edges and vertices.

7. (Circulation theorem). A circulation in a directed graph G is a flow without asource and a sink. Given a lower capacity l(x, y) and an upper capacity c(x, y)for each edge zy with 0 < l(x, y) c(x, y) we call a circulation g feasible if

1(x, .V) g(x, Y) < c(x, Y)

for every edge zy. Prove that there exists a feasible circulation if

1(S, S) <; c( S, S) for every S c V.

[Note that the necessity of the condition is trivial since in a feasible circulationthe function l forces at least l(S, S) current from S to S and the function c allowsat most c(S, S) current into S from S. To prove the sufficiency, adjoin a sink s anda source t to G, send an edge from s to each vertex of G and send an edge fromeach vertex of G to t. Define a capacity function c* on the edges of the new graphG* by putting c*(x, y) = c(x, y) - 1(x, y), c*(s, x) = l(V, x) and c*(x, t) = l(x, V).Then the relation

f(x, Y;' = g(x, Y) - l(x, Y)

sets up a 1-1 correspondence between the feasible circulations g in G and flowsf in G* from s to t with value l(V, V). Rewrite the condition given in the max-flowmin-cut theorem in the form required in this result.]

8.' Let H be a bipartite multigraph without loops, with vertex classes V, and V2. (ThusH may contain multiple edges, that is two vertices belonging to different classesmay be joined by several edges, which are said to be parallel.) As usual, given avertex x we denote by r(x) the sel: of edges incident with x and by d(x) = I f'(x) Ithe degree of x. Prove that, given any natural number k, the set E of edges can bepartitioned into sets E,, E2, ... , E,, such that for every vertex x and every set E,we have

Ldk)J < If(x)nE;I < IAx)I

where, as in the rest of the book, z] is the least integer not less than z and [z]-[-z].

Thus if we think of the partition (J' E; as a colouring of the edges with k colours,then the colouring is equitable in the sense that in each vertex the distribution ofcolours is as equal as possible. [Hint. Construct a directed graph H = (V, U V2, k)from H by sending an edge from x to y iff x e V, , v e V2 and H contains at least one

H H

V,

Figure 111.8. The graphs H, H and

Page 74: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 63

xy edge. Let G be obtained from H by adding a vertex u and all the edges ux, yu,for x e V, and y e V2, as shown in Figure 111.8. Define an appropriate upper andlower capacity for each edge of G and prove that there is a feasible integral circula-tion. Use this circulation to define one of the colour classes.]

9. (Exercise 8+ continued) Show that we may require that, in addition to theproperty above, the colour classes are as equal as possible, say I E, 15 I E2 I< < I E, I < I E, I + 1, and in each set of parallel edges the distribution ofcolours is as equal as possible.

10. Let d, S d2 <- 5 d be the degree sequence of a graph G. Suppose that

d;j+k-IProve that G is k-connected.

It. Let k and I be integers 1 < k < 1. Construct graphs G,, G2 and G3 such that(i) K(GB) = k and A(G1) = 1,

(ii) K(G2) = k and ,c(G2 - x) = I for some vertex x,(iii) K(G3 - x) = k and A(G3 - xy) = I for some edge xy.

12. Given U c V(G) and a vertex x e V(G) - U, an x-U fan is a set of I U I paths fromx to U, any two of which have exactly the vertex x in common. Prove that a graphG is k-connected if I G I >- k + 1 and for any k-set U c V(G) and vertex x notin U, there is an x-U fan in G. [Hint. Given a pair (x, U), add a vertex u to Gand join it to each vertex in U. ('heck that the new graph is k-connected if Gis. Apply Menger's theorem for x and u.]

13. Prove that if G is k-connected (k >- 2) and {x1, x2, ..., xk} c V(G) then thereis a cycle in G that contains all x,, 1 < i < k.

14. The line graph L(G) of a graph G = (V, E) has vertex set E and two verticesa, fl e E are adjacent if they have exactly one vertex of G in common. By applyingthe vertex form of Menger's theorem to the line graph L(G), prove that the vertexform of Menger's theorem implies the edge form.

15. Show that if )(G) = k >- 2 then the deletion of k edges from G results in at most2 components. Is there a similar result for vertex-connectivity?

16. Let G be a connected graph with minimum degree S(G) = k > 1. Prove that Gcontains a path x,x2 ... xk such that G - {x,, x2, ... , xk} is also connected.[Hint. Let x,x2 ... x, be a longest path. Note that I > k + 1. Suppose thatG - {x,, x2, ... , xk} is disconnected and let yo y, ... y,,, be a longest path in acomponent C not containing xk+IXk+2 ... x1. Then dc(yo) < m but yo cannot bejoined to k - m of the vertices x,, ... , xk.]

17. Let G = G2(m. n) be a bipartite graph with vertex classes V, and V2 containinga complete matching from V, to V2.(i) Prove that there is a vertex x e V, such that for every edge xy there is a

matching from V, to V. that contains xy.(ii) Deduce that if d(x) = d for every x e V, then G contains at least d ! complete

matchings if d < m and at least d(d - 1) . . . (d - m + 1) complete matchingsifd>m.

18. Let A = (a,;)', be an n x n stochastic matrix, that is let a;; >- 0 and _, a,; _Y-;_, ai; = 1 for all i, j. Show that A is in the convex hull of n x n permutation

Page 75: Graph Theory-An Introductory Course-Bela Bollobas

64 III Flows, Connectivity and Matching

matrices, i.e. there are A, > 0, >; A, = 1, and permutation matrices P,, P2, ... , P.such that A = Yi A;P,. [Let a,; 1a,j1, A = (a!r, and let G = G2(n, n) bethe bipartite graph naturally associated with A*. Show that G has a completematching and deduce that there area permutation matrix P and a real A, 0 < A 5 1,such that A-AP =B=(b,)i is such thatb;j - 0,D" Ib.,=Y_j=1 b;;=1-Afor all i, j, and B has at least one more 0 entry than A.]

19. Prove the following form of the Schriider-Bernstein theorem. Let G be a bi-partite graph with vertex classes X and Y having arbitrary cardinalities. LetA c X and B c Y. Suppose there are complete matchings from A into Y andfrom B into X. Prove that G contains a set of independent edges covering allthe vertices of A u B. [Hint. Consider the components of the union of thematchings.]

20. Deduce from Exercise 19 that every bipartite graph contains a set of independentedges such that each vertex of maximum degree (that is degree .(G)) is incidentwith one of the edges. Deduce that a non-empty regular bipartite graph has a1-factor.

21. An r x s Latin rectangle based on 1, 2, ... , n is an r x s matrix A = (a,j) suchthat each entry is one of the integers 1, 2, ..., n and each integer occurs in eachrow and column at most once. Prove that every r x n Latin rectangle A can beextended to an n x n Latin square. [Hint. Assume that r < n and extend A to an(r + 1) x n Latin rectangle. Let Aj be the set of possible values of a,+,,,, thatis let A; = {k: 1 5 k S n, k * a,j}. Check that {Aj:1 5 j 5 n) has a set ofdistinct representatives.]

Prove that there are at least n! (n - 1)! ... (n - r + 1)! distinct r x n Latinrectangles based on 1, 2, .... n. [Hint. Apply Exercise 17(ii).]

22. Let A be an r x s Latin rectangle and denote by A(i) the number of times thesymbol i occurs in A. Show that A can be extended to an n x n Latin squareitfA(i)> r + s - nfor every i = 1,2,...,n.

23. We say that G is an (r, r - k)-regular graph if r - k 5 8(G) 5 A(G) 5 r. Provethat for 1 5 k S s 5 r every (r, r - k)-regular graph contains an (s, s - k)-regularfactor. [Hint. Assume s = r - 1. Take a minimal (r, r - k)-regular factor. Notethat in this factor no two vertices of degree r are adjacent. Remove a set of in-dependent edges covering the vertices of degree r.]

24' Recall Tychonov's theorem from general topology: the product of an arbitraryfamily of compact spaces is compact. Deduce from this the following extensionof Hall's theorem.

Let G be an infinite bipartite graph with vertex classes X and Y, such that eachvertex in X is incident with finitely many edges. Then there is a complete matchingfrom X into Y if I r(A) I I A I for every finite subset A of X.

Show that the finiteness condition cannot be omitted.

25. Prove that a 2-edge-connected cubic graph has a 1-factor. [This result is calledPetersen's theorem. In order to prove it check that the condition of Tutte'stheorem is satisfied. If 0 # S <= V(G) and C is an odd component of G - Sthen there are at least two S - C edges, since G is 2-edge-connected. Furthermore,since G is cubic, there are at least three S - C edges. Deduce that q(G - S) 5 1 S 1.]

Page 76: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 65

26. Imitate the second proof of Theorem 7 to give a direct proof of the case d = 0of Theorem 10 and then deduce from it the general cased > 0.

27. Let G be a graph of order n with at most r > 2 independent vertices. Prove thatif d is any orientation of G which does not contain a directed cycle (acyclicorientation) then G contains a directed path of length at least [n/r] - 1. [Hint.Apply Dilworth's theorem, Theorem 11.]

28. Deduce from Exercise 27 the following result. Given a set of rk + 1 distinctnatural numbers, either there exists a set of r + 1 numbers, none of which dividesany of the other r numbers, or else there exists a sequence ao < a, < < aksuch that if 0 < i < j < k then ai divides a;.

29. Describe all maximal graphs of order n = 21 which do not contain a 1-factor.[Hint. Read it out of Tutte's theorem (Theorem 12).]

30. (cf. Exercise 29) Describe all maximal graphs of order n which contain at most kindependent edges. [Hint. Apply Corollary 13.]

31. Make use of Exercise 30 and the convexity of the binomial coefficient (z), x 2,

to prove that if n >- k + 1 then the maximal size of a graph of order n with atmost k independent edges is

(max.

(2k 2+ 1), (2) + k(n - k)

Show also that the extremal graphs (that is the graphs for which equality holds)are one or both of the graphs K2k+ 1 u E"- 2k-1 and Kk + E" 1'. (See Figure 111.9.)

K7 U E2

K3 E6

11

Figure 111.9. For k = 3, n = 9 there are two extremal graphs: K7 u E2 andK3+E6.

32. Call a sequence d,, d2, .... d" of integers graphic if there is a graph G with vertexset V(G) = {x z2, ... , x"} such that d(xi) = di, 1 5 i 5 n. (The graph G is said torealize (d1)i.) Show that d, > d2 Z >- d, is graphic if so is the sequence

d2 - 1, d3 - 1,...,dd,+i - 1,dd,+2,dd,+3,...,d".

33. Use the algorithm given in the previous exercise to decide which of the follow-ing sequences are graphic: 5, 4, 3, 2, 2, 2; 5, 4, 4, 2, 2, 1; 4, 4, 3, 3, 2, 2, 2 and5, 5, 5, 4, 2, 1, 1, 1. Draw the graphs realizing the appropriate sequences con-structed by the algorithm.

Page 77: Graph Theory-An Introductory Course-Bela Bollobas

66

Notes

III Flows, Connectivity and Matching

The basic book on flows is L. R. Ford, Jnr. and D. R. Fulkerson, Flows inNetworks, Princeton University Press, Princeton, 1962. It not only containsall the results mentioned in the chapter concerning flows and circulations,but also a number of applications to standard optimization problems.

The fundamental theorems of Menger, Hall and Tutte are in K. Menger,Zur allgemeinen Kurventheorie, Fund. Math. 10 (1927) 96-115, P. Hall, Onrepresentatives of subsets, J. London Math. Soc. 10 (1935) 26-30), and W. T.Tutte, A factorization of linear graphs, J. London Math. Soc. 22 (1947)107-111. The proof of Tutte's theorem we gave is due to T. Gallai, NeuerBeweis eines Tutte'schen Satzes,.Magyar Tud. Akad. Kozl. 8 (1963) 135-139,and was rediscovered independently by I. Anderson, Perfect matchings in agraph, J. Combinatorial Theory Ser. B 10 (1971) 183-186 and W. Mader,Grad and lokaler Zusammenhang in endlichen Graphen, Math. Ann. 205(1973) 9-11. The result in Exercises 8 and 9 is due to D. de Werra, Multi-graphs with quasiweak odd cycles, J. Combinatorial Theory Ser. B 23 (1977)75-82.

A slightly simpler form of the result in Exercise 23 is due to W. T. Tutte;the proof indicated in the hint was found by C. Thomassen. An extensivesurvey of results concerning connectivity and matching can be found inChapters I and II of B. Bollobas, Extremal Graph Theory, Academic Press,London and New York, 1978.

Page 78: Graph Theory-An Introductory Course-Bela Bollobas

CHAPTER IV

Extremal Problems

At least how many edges are in a graph of order n if it is forced to contain apath of length 1? A cycle of length at least 1? A cycle of length at most l?A complete graph K'? These questions are special cases of the so calledforbidden subgraph problem: given a graph F, determine ex(n; F), the maximalnumber of edges in a graph of order n not containing F. The forbidden sub-graph problem is a prime example of the rather large family of extremalproblems in graph theory. In this chapter we present the fundamental resultconcerning the forbidden subgraph problem and discuss some closely re-lated extremal questions. We have to emphasize that we do not intend toprovide an overall view of extremal graph theory.

Before going into the details, it is appropriate to say a few words aboutthe terminology. If for a given class of graphs a certain graph parameter,say the number of edges or the minimum degree, is at most some number f,then the graphs for which equality holds are the extremal graphs of theinequality. As a trivial example, note that an acyclic graph of order n has atmost n - 1 edges, and the extremal graphs are the trees of order n. In theforbidden subgraph problem a graph is extremal if it does not contain F andhas ex(n; F) edges. In the previous chapter Tutte's factor theorem enabledus to solve a beautiful extremal problem: how many edges guarantee k + 1independent edges? In this case F consists of k + 1 independent edges, thatis F = (k + 1)K2. Exercise 31 of Chapter III claims that for n - 2k + 1the extremal graphs of ex(n; F) are K2k+ i u E"- 2k- i and/or Kk + E"-k.

The material in this chapter falls conveniently into two parts: the oddsections concern paths and cycles while the even ones are about completesubgraphs. We have chosen to alternate the topics in order to have thesimpler results first, as in most other chapters.

The first section is about paths and cycles (short and long) in graphs of

67

Page 79: Graph Theory-An Introductory Course-Bela Bollobas

68 IV Extremal Problems

large size. Among others we shall give a good bound on ex(n; P'), the maximalnumber of edges in a graph of order n without a path of length 1. We shallalso present some fundamental results about Hamilton cycles.

One of the best known theorems in graph theory, Turin's theorem,determines the function ex(n; K'). The second section is devoted to thistheorem together with some related results.

When discussing ex(n; P') and ex(n; K'), we mostly care about the casewhen n is large compared to I and r. We get rather different problems if Fand G have the same order. A prime example of these problems will bediscussed in the third section, the problem of Hamilton cycles. Over theyears considerable effort has gone into the solution of this problem and in acertain rather narrow sense the present answers are satisfactory.

The fourth section is devoted to a deep and surprising theorem of Erdosand Stone. The theorem concerns ex(n; F), where F is a complete r-partitegraph with t vertices in each class, but as an immediate corollary of thisresult one can determine ex(n; F)/n2 for every graph F.

§1 Paths and Cycles

In its natural formulation our first theorem gives a lower bound on the orderof a graph in terms of the minimum degree and the girth, the length of ashortest cycle. Equivalently, the result gives an upper bound on the girthin terms of the order and minimum degree.

Theorem 1. For g > 3 and b > 3 put

no(g, b) =

+8

2 {(b - 1)(° 1'/z - 1) if g is odd,

2if g is evenU-2 2 fo-1)012-1}

Then a graph G with minimum degree b and girth g has at least no(g, b) vertices.

PRoox. Suppose first that g is odd, say g = 2d + 1, d z 1. Pick a vertex x.There is no vertex z for which G contains two distinct z-x paths of length atmost d, since otherwise G has a cycle of length at most 2d. Consequentlythere are at least 6 vertices at distance 1 from x, at least b(b - 1) vertices atdistance 2, and so on, at least b(b - 1)d-1 vertices at distance d from x(Figure IV.1). Thus

n>- 1 +6+b(6-- 1)+...+6(6 - 1)d-1,

.

as claimed.

Page 80: Graph Theory-An Introductory Course-Bela Bollobas

§1 Paths and Cycles 69

I

Figure IV. 1. The cases 6 = g = 5 and 6 = 4, g = 6.

Suppose now that g is even, say g = 2d. Pick two adjacent vertices, sayx and y. Then there are 2(S - 1) vertices at distance 1 from {x, y}, 2(8 - 1)2vertices at distance 2, and so on, 2(8 - 1)°-1 vertices at distance d - 1 from{x, y}, implying the required inequality.

Let Go be an extremal graph of Theorem 1, that is a graph with parameters6 and g, for which equality holds. The proof above implies that Go is regularof degree 6; if g = 2d + 1 then Go has diameter d and if g = 2d then everyvertex is within distance d - 1 of each pair of adjacent vertices. It is easilyseen that no(g, 6) is also the maximal number for which there is a graph withmaximum degree b having the latter property (Exercise 1). We call Go aMoore graph of degree 6 and girth g, or, if g = 2d + 1, a Moore graph ofdegree 6 and diameter d. In Chapter VIII we shall use algebraic methods toinvestigate Moore graphs.

Let us see now what we can say about long cycles and paths in a graph.If a graph of order n is Hamiltonian then its circumference, that is the lengthof a longest cycle, is n, while the length of a longest path is n - 1. However,every non-Hamiltonian connected graph contains at least as long paths asthe circumference of the graph. Indeed, if C = x 1x2 ... x, is a longest cycleand l < n then there is a vertex y not on C adjacent to a vertex of C, say x1,and then yx 1x2 ... x, is a path of length 1.

Theorem 2. Let G be a connected graph of order n z 3 such that for any twonon-adjacent vertices x and y we have

d(x) + d(y) > k.

Ifk = n then G is Hamiltonian and if k < n then G contains a path of lengthk and a cycle of'length at least (k + 2)/2.

PROOF. Assume that G is not Hamiltonian and let P = x1x2 ... x, be alongest path in G. The maximality of P implies that the neighbours of x1and x, are vertices of P. As G does not contain a cycle of length 1, x1 is notadjacent to x1. Furthermore the path P cannot contain vertices xi and x; +tsuch that x, is adjacent to xi+, and x, is adjacent to xi since otherwisex1x2 ... x;x,x1_1 ... x;+1 is a cycle of length 1 (Figure IV.2). Consequentlythe sets

r(x1) = {x;: x1 xj e E(G)} and r+(x,) = {xi+ 1: x, x, a E(G)}

Page 81: Graph Theory-An Introductory Course-Bela Bollobas

70 IV Extremal Problems

Figure IV.2. The construction of a cycle of length I.

are disjoint subsets of {x2, x3, . .. , x,} and so

k<d(xl)+d(.z,)<l- 1 <n-1.The first two assertions of the theorem follow from this inequality. If k = n,this is impossible, so G is Hamiltonian. If k < n then P has length ! - 1 > k.

Finally, the assertion about cycles is even simpler. Assume that d(x1) Zd(x,) so d(x1) >- Fk/21, where Izl denotes the least integer not less than z.Put t = max{i: x1x; e E(G)}. Then t > d(x1) + 1 > Ik/21 + 1 and G con-tains the cycle x1x2 ... x, of length t.

In §3 we shall make use of the proof of this theorem to obtain detailedinformation about graphs without long cycles and paths. For the momentwe confine ourselves to noting two consequences of Theorem 2.

Theorem 3. Let G be a graph of order n without a path of length k(> 1). Then

e(G)Sk21n.

A graph is an extremal graph (that is equality holds for it) if all its componentsare complete graphs of order k.

PROOF. We fix k and apply induction on n. The assertion is clearly true ifn < k. Assume now that n > k and the assertion holds for smaller valuesof n.

If G is disconnected, the induction hypothesis implies the result. Now ifG is connected, it contains no K' and, by Theorem 2, it has a vertex x ofdegree at most (k - 1)/2. Since G -- x is not an extremal graph

e(G)<d(x)+e(G-x)<K2I+k2I(n-1)=k2In. El

Theorem 4. Let G be a graph of order n in which every cycle has length at mostk (k >- 2). Then

e(G) <k

(n - 1).

A graph is an extremal graph iff it is connected and all its blocks are completegraphs of order k.

Page 82: Graph Theory-An Introductory Course-Bela Bollobas

§2 Complete Subgraphs 71

The proof of this result is somewhat more involved than that of Theorem3. Since a convenient way of presenting it uses `simple transforms' to beintroduced in §3, the proof is left as an exercise (Exercise 25) with a detailedhint.

§2 Complete Subgraphs

What is ex(n; K'), the maximal number of edges in a graph of order n notcontaining a K', a complete graph of order r? If G is (r - 1)-partite then itdoes not contain a K' since every vertex class of G contains at most onevertex of a complete subgraph. Thus ex(n; K') is at least as large as themaximal size of an (r - 1)-partite graph of order n. In fact, there is a unique(r - 1)-partite graph of order n that has maximal size. This graph is thecomplete (r - 1)-partite graph T,_ 1(n) that has L(n + k - 1)/(r - 1)jvertices in the kth class (Figure IV.3). In other words, T,_ 1(n) is the complete(r - 1)-partite graph of order n whose classes are as equal as possible: saythere are nk vertices in the kth class and n1 < n2 5 ... S n,_ 1 < n1 + 1.Indeed, let G be an (r - 1)-partite graph of order n and maximal size.

Figure IV.3. The Turin graph T3(7).

Clearly G is a complete (r - 1)-partite graph. Suppose the classes are notas equal as possible, say there are m1 vertices in the first class and m2 zm1 + 2 in the second. This is impossible since by transferring one vertexfrom the second class to the first we would increase the number of edges by(m1+1)(m2-1)-m1m2=m2-m1 -1Z1.

The number of edges in T,_ 1(n) is usually denoted by t,_ 1(n); thus t2(n) _Ln2/4J. A fundamental theorem of Turin states that the trivial inequalityex(n; K') > t,_ 1(n) is, in fact, an equality for every n and r. We shall showfirst that the degree sequence of a graph without a K' is dominated by thedegree sequence of an (r - 1)-partite graph. In view of the remarks abovethis will imply Turin's theorem.

Theorem 5. Let G be a graph with vertex set V that does not contain K', acomplete graph of order r. Then there is an (r - 1)-partite graph H withvertex set V such that for every vertex z e V we have

dG(z) 5 dy(z).

Page 83: Graph Theory-An Introductory Course-Bela Bollobas

72 IV Extremal Problems

If G is not a complete (r - 1)-partite graph then there is at least one vertex zfor which the inequality above is strict.

PROOF. We shall apply induction on r. For r = 2 there is nothing to provesince G is the empty graph E", which is 1-partite. Assume now that r >- 3and the assertion holds for smaller values of r.

Pick a vertex x e V for which d,;(x) is maximal and denote by W the setof vertices of G that are joined to x. Then Go = G[W] does not contain aK'- t otherwise with x it would form a K'. By the induction hypothesis wecan replace Go by an (r - 2)-partite graph Ho with vertex set W in such away that dG0(y) 5 dH0(y) for every y e W. Add to Ho the vertices in V - Wand join each vertex in V - W to each vertex in W. To complete the prooflet us check that the graph H obtained in this way has the required properties.

If z e V - W then dH(z) = dH(x) = dc(x) >- dG(z) and if z e W thendH(z) = dH0(z) + n - I W z n - I W dc(z). Thus da(z) < dH(z)holds for every z e V.

Can H contain a complete subgraph of order r? Clearly not, since acomplete subgraph of H has at most one vertex in V - W and most r - 2vertices in W.

What can we say about G if e(G) = e(H)? Then e(G0) = e(H0), so bythe induction hypothesis Go is a complete (r - 2)-partite graph and

ec(W, W) = eH(W, WV) _ I

Hence

e(G[W]) _= e(H[W]) = 0,

implying that G is a complete (r - 1)-partite graph.

We now give Turin's theorem in its original form.

Theorem 6. ex(n; K') = t,_,(n) and T,_ 1(n) is the unique graph of order n andsize t,_ 1(n) that does not contain a complete graph of order r.

1ST PROOF. Since T,_ 1(n) is the unique (r - 1)-partite graph of order n andmaximum size, both assertions follow from Theorem 5.

In order to emphasize the significance of Theorem 6, we prove it fromfirst principles also. This proof is based on the fact that T,-,(n) is almostregular: S(T,_,(n)) = n - In/(r - 1)1, A(T,_,(n)) = n - [n/(r - 1)], and ifx is a vertex of minimum degree in T,_ 1(n) then T,_ t(n) - x is exactlyT-t(n-1).

2ND PROOF. Fix r >- 3 and apply induction on n. For n < r the assertion istrivial so suppose that n > r and the theorem holds for smaller values of n.

Suppose G has n vertices, t,_ 1(n) edges and it contains no K'. As T,_ 1(n)is a maximal graph without a K' (that is no edge can be added to it without

Page 84: Graph Theory-An Introductory Course-Bela Bollobas

§2 Complete Subgraphs 73

creating a K') the induction step will follow if we show that G is exactly aT, _ , (n). Since the degrees in T, _ 1(n) differ by at most 1, we have

8(G) S 8(Ti_1(n)) S A(Tr_1(n)) S 0(G).

Let x be a vertex of G with degree d(x) = S(G) < 8(T,_ 1(n)). Then

e(G-x)=e(G)-d(x)ze(Tr_1(n-1)),so by the induction hypothesis Gx = G - x is exactly a T,_ 1(n - 1).

A smallest vertex class of Gx contains L(n - 1)/(r - 1)J vertices and thevertex x is joined to all but

n - 1 - \n - [r n ll) -[n -

- 1)

vertices of Gx. Since x cannot be joined to a vertex in each class of Gx, ithas to be joined to all vertices of Gx save the vertices in a smallest vertexclass. This shows that G is exactly a T, - 1(n) graph.

The proof above can easily be adapted to give a number of related results(cf. Exercises 7, 8).

Now let us turn to the problem of Zarankiewicz, which is the analog ofTuran's problem in bipartite graphs. Write G2(m, n) for a bipartite graphwith m vertices in the first class and n in the second. What is the maximumsize of a G2(m, n) if it does not contain a complete bipartite graph with svertices in the first class and t in the second? This maximum is usuallydenoted by z(m, n; s, t). The following simple lemma seems to imply a verygood upper bound for the function z(m, n; s, t).

Lemma 7. Let m, n, s, t, r, k be integers, 2 < s S m, 2 < t < n, 0 5 k, 0 Sr < m, and let G = G2(m, n) be a graph of size z = my = km + r without aK(s, t) subgraphlha\ving s vertices in the first class and tin the second. Then

m1 Y 1 (m - r(k 1) 5 (s - 1)(t) (1)

PROOF. Denote by V1 and V2 the vertex classes of G. We shall say that a t-set(i.e., a set with t elements) T of V2 belongs to a vertex x e V1 if x is joined toevery vertex in T. The number of t-sets belonging to a vertex x e V1 is (°( tSince the assumption on G is exactly that each t-set in V2 belongs to at mosts - 1 vertices of V17 we find that

_y(d(x)')tS(s- 1)(t). (2)

r, 05r<mandf(u)=(",)isaconvexfunction of u for u ;-> t, inequality (2) implies (1).

Page 85: Graph Theory-An Introductory Course-Bela Bollobas

74 IV Extremal Problems

Theorem 8. z(m, n, s, t) < (s - 1)'/(n - t + 1)m'-"") + (t - 1)m.

PROOF. Let G = G2(m, n) be an extremal graph for the function z(m, n; s, t),that is let G be a bipartite graph of size z(m, n; s, t) = my without a K(s, t)subgraph. As y < n, inequality (1) implies

(y - (t - 1))` < (s - 1) (n - (t - 1))m-'.

As a consequence of Theorem 8 we see that if t >- 2 and c > (t - 1)'l`are fixed then for every sufficiently large n we have

z(n, n; t, t) < cn2-tl/`). (3)

The method of Lemma 7 gives also an upper bound for ex(n; K20)), themaximum number of edges in a graph of order n without a complete t by tbipartite subgraph.

Theorem 9. ex(n; K2(t)) < 30 - 1)'/`(n - t + 1)n'-("') + Y t - 1)n< 3{t - 1)'/tn2-(1/n + Jtn.

PROOF. Let G be an extremal graph. As in Lemma 7, let us say that a t-setof the vertices belongs to a vertex x if x is joined to every vertex of the t-set.Since G does not contain a K2(t), every t-set belongs to at most t - 1 vertices.Therefore if G has degree sequence (d;); then Yi d, = 2 ex(n; K2(t)) and

<(t- 1)(')

implying the result.

It is very likely that inequality (3) gives the correct order of magnitude ofz(n, n; t, t) for every t >- 2 as n -+ oo but this has been proved only for t = 2and 3. In fact, it is rather hard to find non-trivial lower bounds forz(m, n; s, t). In Chapter VII we shall use the probabilistic method to obtaina lower bound. To conclude the section we prove an elegant result for t = 2that indicates the connection between the problem of Zarankiewicz anddesigns, in particular, projective spaces.

Theorem 10. z(n, n; 2, 2) < 4n{1 + (4n - 3)'/2) and equality holds for in-finitely many values of n.

PROOF. Note that with z = Jn{1 + (4n - 3)1/2} we have

(z-n)z=n2(n-1).Suppose that there is a bipartite graph G = G2(n, n) of size greater than zthat does not contain a quadrilateral (that is a K(2, 2)). Denote byd1, d2, ... , d the degrees of the vertices of G in the first vertex class, say V1.

Page 86: Graph Theory-An Introductory Course-Bela Bollobas

§3 Hamilton Paths and Cycles

Then Yi d. = e = e(G) >z and, as in the proof of Lemma 7, we have

n (d)(n)

1 2 e z(z - n) n

2n e - 2 > 2n = 2).

75

This shows that the inequality does hold.In fact, the proof so far tells us a considerable amount about the graphs

G for which equality can be attained. We must have d, = d2 = = d = dand any two vertices in the second vertex class V2 of G have exactly onecommon neighbour. By symmetry each vertex of V2 has degree d and anytwo vertices in V, have exactly one common neighbour.

Call the vertices in V, points and the sets F(x), x e V1, lines. By the remarksabove there are n points and n lines, each point is on d lines and each linecontains d points, there is exactly one line through any two points and anytwo lines meet in exactly one point. Thus we have arrived at the projectiveplane of order d - 1. Since the steps are easy to trace back, we see that equa-lity holds for every n for which there is a projective plane with n points. Inparticular, equality holds for every n = q2 + q + 1 where q is a prime power.

In conclusion, let us see the actual construction-of G for the above valuesof n. Let q be a prime power and let PG(2, q) be the projective plane overthe field of order q. Let V, be the set of points and V2 the set of lines. Then

IV1I=IV21 =q2+q+1=n.Let G be the bipartite graph G2(n, n) with vertex classes V, and V2 in whichPl (P e V,, l e V2) is an edge if the point P is on the line 1. (See Figure IV.4.)Then G has n(q + 1) = -n{1 + (4n - 3)1/2) edges and it does not contain aquadrilateral.

n-+n+0,1,3

Figure IV.4. PG(2, 2) and the corresponding bipartite graph.

§3 Hamilton Paths and CyclesA class of graphs is said to be monotone if whenever a graph L belongs to theclass and M is obtained from L by adding to it an edge (but no vertex) thenM also belongs to the class. Most theorems in graph theory can be expressedby saying that a monotone class .,K is contained in a monotone class 9.

Page 87: Graph Theory-An Introductory Course-Bela Bollobas

76 IV Extremal Problems

Of course, these classes are usually described in terms of graph invariantsor subgraphs contained by them. For example, the simplest case of Turan'stheorem, discussed in the previous section, states that the class A ={G(n, m): m > n2/4} is contained in Y = {G: G contains a K3}. It is worthnoting that a class Ov of graphs is said to be a property of graphs if L e Y andL = M imply M e Y.

How should we go about deciding whether or not A is contained in Y?In some cases there is a simple and beautiful way of tackling this problem.Suppose we have a class 9" of triples (G, x, y), where G is a graph and x andy are non-adjacent vertices of G, such that if (G, x, y) e .f and G e A' thenG belongs to Y if G+ = G + xy does. This holds, for example, if .° is theproperty of containing a K' and .9 = {(G, x, y): I r(x) n F(y) I < r - 2}.In this case G can be replaced by G. If G+ also contains two non-adjacentvertices, say u and v, such that (G' , u, v) e .07 then we can repeat the opera-tion: we can replace G+ by G++ = G + + uv. Continuing in this way wearrive at a graph G* zD G which belongs to 9 if G does, and which is aclosure of G with respect to J, that is it has the additional property that forno vertices a, b e G* does (G*, a, b) e 9" hold. Thus it is sufficient to decideabout these graphs G* e A' whether or not they belong to Y.

Of course the method above is feasible only if (i) the class .- is simpleenough, (ii) it is easy to show that G belongs to 0 if G+ does and (iii) if westart with a graph G e A then a graph G* E A is easily shown to belong to9. In this section we give two examples that satisfy all these requirements:we shall give sufficient conditions for a graph to contain a Hamilton cycleor a Hamilton path. Because of the special features of these examples it willbe convenient to use slightly different notation and terminology.

Let n and k be natural numbers and let 0 be a class of graphs of order n.We say that .° is k-stable if whenever G is an arbitrary graph of order n, xand y are non-adjacent vertices of G and d(x) + d(y) >- k then G has property0 if G+ = G + xy has it also. It is easily seen that for every graph G oforder n there is unique minimal graph G* = Ck(G) containing G such that

do-(x) + do.(y) < k - 1 for xy 0 E(G*).

In the notation of the previous paragraph, we shall take

9- = {(G, x, y): I G I = n, xy 0 E(G), d(x) + d(y) >- k},

which is certainly simple enough, so (i) will be satisfied. It is also encouragingthat G* = Ck(G) is unique. Almost by definition we have the followingprinciple of stability: if 9 is a k-stable property of graphs of order n then Ghas property 0 iff Ck(G) has it also. We call Ck(G) the k-closure of G.

Requirement (ii) is also satisfied, since the gist of the proof of Theorem 2is that the property of containing a Hamilton cycle is n-stable and theproperty of containing a Hamilton path is (n - 1)-stable. Indeed if d(x) +d(y) >_ n - 1 whenever x and y are non-adjacent distinct vertices, then thegraph is connected so the proof of Theorem 2 can be applied. (In fact, this

Page 88: Graph Theory-An Introductory Course-Bela Bollobas

§3 Hamilton Paths and Cycles 77

is exactly what inspired the notion of a k-closure.) By the stability principlewe obtain the following reformulation of Theorem 2 in the case k = n orn - 1.

Lemma 11. G is Hamiltonian iff C"(G) is and G has a Hamilton path iff sodoes C,-,(G).

Depending on the amount of work we are able and willing to put in atthis stage (cf. requirement (iii)), we obtain various sufficient conditions fora graph to be Hamiltonian. Of course, the case k = n of Theorem 2 is ob-tained without any work, and so is the case k = n - 1, since the conditionsimply immediately that C"(G) = K" in the first case and C" _ ,(G) = K" inthe second, and K" is Hamiltonian if n Z 3. In order to make better use ofLemma 11, we shall prove the following ungainly technical lemma.

Lemma 12. Let k, n and t be natural numbers, t < n, and let G be a graph withvertex set V(G) = {x,, x2, ... , x"}, whose k-closure Ck(G) contains at mostt - 1 vertices of degree n - 1. Then there are indices i, j, 1 < i < j < n, suchthat x; x j 0 E(G) and each of the following four inequalities holds:

j>max{2n-k-i,n-t+1}d(xi)<i+k-n, d(x;)<j+k-n-1, (4)

d(xi) + d(xj) < k - 1.

Remark. Note that it is not assumed that the degree sequence d(xt),&2),..., d(x") of G is ordered in any way.

PROOF. The graph H = Ck(G) is not complete so we can define two indicesi and j as follows:

j = max{l: dH(x,) n - 1},i = max{l: x, x; 0 E(H)}.

Then xix; 0 E(H) so,

dH(xi) + dH(x;) < k - 1,

which implies the fourth inequality in (4). Each of the vertices

xj+l, xj+2, ... , X"

has degree n - 1 in H so

n-j<t-1and

n - j S 8(H) 5 dH(xi).

Page 89: Graph Theory-An Introductory Course-Bela Bollobas

78 IV Extremal Problems

The vertex xj is joined to the n -- j vertices following it and to the j - i - 1vertices preceding it, so

dH(x;)>-n-j+j-i- 1 =n - i- 1.These inequalities enable us to show that the indices i, j, 1 < i < j < n,satisfy the remaining three inequalities in (4). Indeed,

dc(x) <dH(xi)<k-1-dH(xi)k-I-(n-i-1)=i+k-n,dG(x;)<dH(x;)<k-1-dH(x) k-1-(n-j)=j+k-n-1,i+j>-(n-dH(x;)- 1)+(n-.dH(x))>>-2n- 1 - (k - 1) = 2n - k.

Combining Lemma 11 and Lemma 12 (with t = n - 1 and k = n orn - 1) we obtain rather complicated but useful conditions for the existenceof a Hamilton path or cycle.

Theorem 13. Let G be a graph with vertex set V(G) = {x,, X2....n >- 3. Let e = 0 or 1 and suppose there are no indices i, j, 1 < i < j < n,such that x; xj E(G) and

j>-n-i+e,d(xi)5i-e, d(x;)<j- 1 - e,

d(xi) + d(x;) < n - 1 - e.

If e = 0 then G has a Hamilton cycle and if e = 1 then G has a Hamilton path.

This theorem has the following beautiful consequence.

Corollary 14. Let G be a graph with degree sequence dt < d2 < < d,,,n >- 3, and let e = 0 or 1. Suppose

n - k whenever dk< k-a<3{n-e).If e = 0 then G has a Hamilton cycle and if e = 1 then G has a Hamilton path.

We draw the attention of the reader to Exercises 21 and 22 which showthat the assertions in the corollary above are in some sense best possible.In particular, if dt < d2 < ... < d is a graphic sequence such that

d._k<n--k and dkSk<2

then there is a graph G with vertex set {xt, x2, ... , such that d(xi) > di,1 < i < n, and G does not have a Hamilton cycle.

Page 90: Graph Theory-An Introductory Course-Bela Bollobas

§3 Hamilton Paths and Cycles

Figure IV.5. An x-path and a simple transform of it.

79

There is another customary way of showing that a graph has a Hamiltoncycle or path. Let S be a longest xo-path in G, that is a longest path beginningat x0: S = x0 x1 ... xk. Then I'(xk) c {xo, xt, ... , xk_ t} since otherwise Scould be continues to a longer path. If xk is adjacent to x;, 0 < j < k - 1,then S' = xoxt ... x;xkxk_t ... xj+t is another longest x0-path. We callS' a simple transform of S. It is obtained from S by erasing the edge x;x;+tand adding to it the edge xkxj. Note that if S' is a simple transform of Sthen S is a simple transform of S' and S has exactly d(xk) - 1 simple trans-forms. The result of a sequence of simple transforms is called a transform(See Figure IV.5).

Let L be the set of endvertices (different from x0) of transforms of S andput N={xjeS:x;_1eLorxj+teL}andR= V - NuL.ThusListhecollection of the last vertices of the transforms, N is the collection of theirneighbours on S and R is the rest of the vertices.

Theorem 15. The graph G has no L-R edges.

PROOF. Recall that there is no L - (V(G) - V(S)) edge, since S is a longestx0-path, so in particular V(S) = V(P) for every transform P of S.

Suppose xi x; a E(G), where xi e L and x j e R. Let Si be a transform of Sending in xi. Since at least one neighbour of xj on Si is the endvertex of asimple transform of Si, xj cannot have the same neighbours on S and Si,since otherwise x; would belong to N. However, when the edge x;. x,j' = j - 1 or j + 1, is erased during a sequence S -+ S' -+ S" -. -+ Si ofsimple transformations, one of the vertices xj., x; is put into L and the otherinto N. Thus xj e L u N = V(G) - R, contradicting our assumption.

We will make use of Theorem 15 later in Chapter VII. The last tworesults of this section are also obtained with the use of simple transforms.

Theorem 16. Let W be the set of vertices of even degree in a graph G and letx0 be a vertex of G. Then there are an even number of longest x0-paths endingin W.

PROOF. Let H be the graph whose vertex set is the set Y of longest xo-pathsin G, in which Pt E Y is joined to P2 e Y_ if P2 is a simple transform of Pt.Since the degree of P = xoxt ... Xk e Y in H is d(xk) - 1, the set of longestpaths ending in W is exactly the set of vertices of odd degree in H. The

Page 91: Graph Theory-An Introductory Course-Bela Bollobas

80 IV Extremal Problems

number of vertices of odd degree is even in any graph, so the proof is com-plete.

Theorem 17. Let G be a graph in which every vertex has odd degree. Thenevery edge of G is contained in an even number of Hamilton cycles.

PROOF. Let xo y c- E(G). Then in G' = G - xo y only xo and y have evendegree, so in G' there are an even number of longest xo-paths that end in y.Thus either G has no Hamilton cycle that contains xo y or it has a positiveeven number of them.

§4 The Structure of Graphs

As we saw in §2 on the example of a Turan graph T,.- ,(n), a graph of order nwith -((r - 2)/(r - 1) + o(1))n2 edges does not necessarily contain a K', acomplete graph of order r. (Here and in what follows we use Landau's nota-tion o(1) to denote a function tending to 0 as n - oo.) The main aim of thissection is to prove the deep result of Erdos and Stone, proved in 1946, thatif e > 0 then en2 more edges ensure not only a K', but a K,(t), a completer-partite graph with t vertices in each class, where t -+ oo as n - oo.

A sharper version of the theorem is due to Bollobas and Erdos; this isthe result we shall present here. The simple proof is based on two lemmas.The first lemma enables us to replace a condition on the size by a conditionon the minimum degree; the second is a technical lemma in the vein ofLemma 7.

Lemma 18. Let 0 < a < a + e < I and put q = (e/2)"2. Then every graphG of order n >- 2a/E and size at least (a + e)n2 contains a subgraph H withI H I = h Z qn and minimum degree at least ah.

PROOF. Define a sequence of graphs Go = G z) Gt G2 ... with I Gk I =n - k as follows. If Gk has a vertex xk of degree less than a(n - k) then putGk+t = Gk - Xk, if 6(Gk) >- a(n - k) then terminate the sequence. Theassertion of the theorem follows if we show that the sequence has to terminatein a graph Gk with h = n - k >- in.

Suppose this is not so and we arrive at a graph Gk with h = n - k < qn.By construction

e(Gk) >- J(a + e)n2 - a{n + (n - 1) + + (h + 1)).

On the other hand

e(Gk) 5 e(K') =\2/

Page 92: Graph Theory-An Introductory Course-Bela Bollobas

§4 The Structure of Graphs 81

so

en2 - an + ah + h < (1 - a)h2,

contradicting our assumptions.

Lemma 19. Let r>-2,1 <t<q and N = n - (r - 1)q> 1. Let G be agraph of order n that contains a K,_ 1(q), say K, but does not contain a Kr(t).Then G has at most

e = ((r - 2)q + t)N + 2qN' - (1 1`)

edges of the form xy, where x e IK and y c- G - R.

PROOF. Let S1, S2, ... , S,_ 1 be the vertex classes of IZ and put S = U; 1 Si.

Thus I Si I = q and I S I = (r - 1)q. Let x 1, X2, ... , xN be the vertices of G - IZand put Ai = r(xi) n S, i = 1, 2, ... , N. With this notation the lemmastates that

N

YIAiI <e.1

Call a set W c S a centipede if it has exactly t vertices in each set Si.Since G does not contain a K,(t), every centipede is contained in at mostt - 1 of the A.. We may assume that J Ai I > (r - 2)q + t for i < M andA; I < (r - 2)q + t for i > M. For i < M and j < r - 1 put aij = I A; n S j I .

Then aij >- t and A, containsr-1 (au)

t

centipedes. Since altogether there are (q)r-1 centipedes and each one ofthem is contained in at mosstHt - 1 sets Ai, we have

aij_< t

i=1 j=1 t t

The required estimate follows from this inequality and the convexity ofthe binomial coefficients. Indeed putting ai = Y;--1 aij - (r - 2)q, one has

F- I aij) > (q)r -2 (a),f] ( -

so

Y(al)<(t- (q).

As (',) is a convex function of x, on putting a = Y-1 ajM the last inequalityimplies

M(') <- (t - 1) (q).

Page 93: Graph Theory-An Introductory Course-Bela Bollobas

82

Thus

and

Since

IV Extremal Problems

a < (t - 1)1ltgM1-(ln) + t < 2gM_1It + t

JAJ < 2qM- lit + M((r - 2)q + t).

N

E JAJ <(N - M)((r - 2)q + t),M+1

the required estimate does hold.

Theorem 20. Let r >- 2 be an integer and let 0 < e < 1/2(r - 1). Then thereexists a d = d(e, r) > 0 such that y 'n is sufficiently large and

m>- {z(r- 2)/(r - 1)+e}n2then every graph of order n and size m contains a K,(t) with t >- Ld log nJ.

PROOF. We shall apply induction on r. For r = 2 Theorem 9 implies thatany d < -1/log(2e) will do for d(e, 2). Indeed, if there is a graph G(n, m)without a K2(t) where m >- en' and t = Ld log nj, then by Theorem 9 wehave

en2 < J1-(t - 1)1/tn2-(1/t) + 3-tn,

that is

2enI t < (t -- 1)'" + tn-1+(l/t)

However, this inequality cannot hold if n is sufficiently large.Now assume that r > 2 and the result holds for smaller values of r. For

the sake of convenience we write K,(x) for K,(Qx]).By Lemma 18 every graph of order N > 4/e and size at least

{Z (r - 2)/(r - 1) + e}N2 contains a subgraph GE(n) having order n >- el12Nand minimum degree at least {(r -- 2)/(r - 1) + e}n.

Pute,=3-{(r-2)/(r-1)-(r-3)/(r-2)}={2(r-1)(r-2)}-1>0

and e, = d(e r - 1) > 0. Then er depends only on r, so by the inductionhypothesis if n is large then every GE(n) contains a Kr-1(e, log n) = K,_ 1(q).We shall show that d = d(e, r) == e,(r - 1)e/4 will do for the theorem, that isevery GE(n) contains a Kr(d log n) = Kr(t) if n is large enough.

Since with t = er(r - 1) 2 log n we have 'd log N < t, it suffices toshow that if n is sufficiently large Then every GE(n) contains a K,(t). Supposethis is not so : G = GE(n) contains a K, _ 1(q), say fc, but no Kr(t).

By Theorem 9 there are at most f (t - 1)lttg2 (lit) + 3-gt edges in asubgraph spanned by the q vertices in a class of K, so there are at most

A =(r

21)q2 + (r -- 1){I(t - 1)11tg2-ln + 3-gt}

Page 94: Graph Theory-An Introductory Course-Bela Bollobas

§4 The Structure of Graphs 83

edges in the subgraph spanned by the whole of K. Furthermore, by Lemma19, at most B = ((r - 2)q + t)(n - (r - 1)q) + 2qn'-('1`) edges join K toG - R. Finally, as b(G) >- {(r - 2)/(r - 1) + e}n, we must have

2A + B z (r - 1)gb(G) >- {(r - 2) + e(r - 1)}qn,and so

2gnt -clip + (r - 1)q2 + to >- s(r - 1)qn.

We have arrived at a contradiction, since this inequality does not hold forlarger values of n.

Remark. In a certain sense Theorem 20 is best possible: for every a and rthere is a constant d,* tending to 0 with e such that the graph described inthe theorem need not contain a K,(t) with t = Ld* log nJ. In fact, we shallsee in Chapter VII Theorem 3 that if 0 < e < I and dZ > - 2/log(2c), thenfor every sufficiently large n there is a graph G(n, m) not containing a K2(t),where m = Len2J and t = [d2* log nj. This result will imply immediately(cf. Exercise 6 of Chapter VII) that if r > 2 and 0 < e < {r - 1)-2 thenany value greater than - 2/log(2(r - 1)2e) will do for, d*.

Since d log n oo as n - oo, Theorem 20 has the following immediatecorollaries.

Corollary 21. Let F = K,(t), where r >- 2 and t z 1. Then the maximal sizeof a graph of order n without a K,(t) is

ex(n; F) =1 r - 2 + o(1) n2.2{r-1

Corollary 22. Let F1, F2i ... , F, be non-empty graphs. Denote by r the mini-mum of the chromatic numbers of the F;, that is let r be the minimum numberfor which at least one of the F. is contained in an F = K,(t) for some t. Thenthe maximal size of a graph of order n not containing any of the F. is

1 r-22

ex(n; F1, F2, ... , Ft) =2 Ir - 1 + 004n .

PROOF. The Turan graph T,_ 1(n) does not contain any of the F;, so

ex(n; F1, F2, ... , F,) > e(T,_ 1(n)) = t,_ 1(n) =Jr

- + o(1)}n2.

Conversely, since, say F; c F = K,(t) for some j and t,

ex(n; F1, F2, ... , F,) < ex(n; F) 5 ex(n; F) =1 Jr - 22 r - 1 + 0(1) n2. El

Theorem 20 is the basis of a rather detailed study of the structure ofextremal graphs, giving us considerably more accurate results than Corollary22. This theory is, however, outside the scope of our book.

Page 95: Graph Theory-An Introductory Course-Bela Bollobas

84 IV Extremal Problems

The density of a graph G of order n is defined to be e(G)/(z). The upperdensity of an infinite graph G is the supremum of the densities of arbitrarilylarge finite subgraphs of G. It is surprising and fascinating that not everyvalue between 0 and 1 is the upper density of some infinite graph; in fact,the range of the upper density is a countable set.

Corollary 23. The upper density of an infinite graph G is 1, 1, 4, J, ... , or 0.Each of these values is the upper density of some infinite graph.

PROOF. Let G, be the complete r-partite graph with infinitely many verticesin each class. Since the density of K,(t) tends to 1 - (1/r) as t tends to 00,the upper density of G, is 1 - (1/r), proving the second assertion.

Now let a be the upper density of G and suppose

a>1 - 11 (r>2).

Then there is an e > 0 such that G contain graphs H,, of order nk with n,, -+ 00satisfying e(H,) z 3{1 - (1/(r - 1)) + s)nk. By Theorem 20 each Hk con-tains a subgraph K,(tk) with tk - 00; the subgraphs K,(t,,) show that a >1 - (1/r).

EXCERCISES

(i) Let G be a graph of order n, maximum degree A > 3 and diameter d. Letno(g, S) be as in Theorem 1. Prove that n S n0(2d + 1, A) with equality if Gis A-regular and has girth 2d - 1.

(ii) Let G be a graph of order n, maximum degree A > 3, and suppose everyvertex is within distance d - 1 of each pair of adjacent vertices. Prove thatn < no(2d, A), with equality iff G is A-regular and has girth 2d.

2. Prove Theorem 4 for k = 3 and 4.

3. Prove that the maximal number of edges in a graph of order n without an evencycle is L1(n - 1)J. Compare this with the maximum size of a graph withoutan odd cycle.

4. Show that a tree with 2k endvertices contains k edge-disjoint paths joining distinctendvertices.

5. Suppose x is not a cutvertex and has degree 2k. Prove that there are k edge-disjoint cycles containing x. [Cf. Exercise 4.]

6.- Show that a graph with n vertices and minimum degree Yr - 2)n/(r - 1)J + 1contains a K'.

7. Let G have n z r + 1 vertices and t,-,(n) + 1 edges.(i) Show that G contains two K' subgraphs with r - 1 vertices in common.(ii) Prove that for every p, r < p <; n, G has a subgraph with p vertices and at least

t,-I(p) + 1 edges.

Page 96: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 85

8. Prove that for n Z 5 every graph of order n with Ln2/4J + 2 edges contains twotriangles with exactly one vertex in common.

9. Prove that if a graph with n vertices and Ln2/4J - I edges contains a trianglethen it contains at least Ln/2J - I - I triangles. [Hint. Let x,x2x3 be a triangleand denote by m the number of edges joining {x,, x2, x3} to V(G) - {x1, x2, x3}.Estimate the number of triangles in G - {x1, x2, x3} and the number of trianglessharing a side with x,x2x3.]

10.' (i) Show that the edges of a graph of order n can be covered with not more thanLn2/4J edges and triangles.

(ii) Let G be a graph with vertices x1, x2, ..., x,,, n >- 4. Prove that there is aset S, I S I < [.n2/4J, containing non-empty subsets X1, X2, ..., X. such thatx;x;is an edge of Gif X;nX, # 0.

11.- Let 1 < k < n. Show that every graph of order n and size (k - 1)n - (2) + 1contains a subgraph with minimum degree k, but there is a graph of order n andsize (k - 1)n - (2) in which every subgraph has minimum degree at most k - 1.[Hint. Imitate the proof of Lemma 18.]

127 Show that a graph of order n and size (k - 1)n - (2) + 1 contains every treeof order k + 1.

13. Let G be a graph of order n which does not contain a cycle with at least one of itsdiagonals. Prove that if n > 4 then G has at most 2n - 4 edges.

Show that if n z 6 and G has 2n - 4 edges then G is the complete bipartitegraph K(2, n - 2). [Hint. Consider a longest path in G.]

14- Let k > 1 and let G be a graph of order n without an odd cycle of length less than2k + 1 > 5. Prove that S(G) 5 Ln/2J and T2(n) is the only extremal graph,unless n = 2k + 1 = 5, in which case there is another extremal graph, C5.

15' Let G be a graph of order n without an odd cycle of length less than 2k + 1 >t 5.Prove that if G does not contain [n/2] independent vertices then b(G) <2n/(2k + 1). Show that equality holds only for n = (2k + 1)t and the extremalgraphs are obtained from a cycle C2k+ 1 by replacing each vertex by t vertices,as in Figure IV.6.

Figure IV.6. The graph C5(2).

16. Let x1, x2, ..., x be vectors of norm at least 1 in a Euclidean space. Prove thatthere are at most Ln2/4J unordered pairs i, j such that I xi + x; I < 1. [Hint. Showthat ifIx,I= 1x21=Ix31 =1then Ix1+xjI>t 1 for some I,), 1 5i<j<3.]

17' Let X and Y be independent identically distributed random variables takingvalues in a Euclidean space. Prove that P(I X + Y I z x) >- }P(I X I >- x)2 forevery x >- 0.

Page 97: Graph Theory-An Introductory Course-Bela Bollobas

86 IV Extremal Problems

18. Let x,, x2, .... x,, c- R2 be such that Ixi - x;1 5 1. Prove that at most 3p2 ofthe distances lxi - xjj are greater than 2/2. [Hint. Show that among any fourof the points there are two within distance /2/2 of each other.]

19. The clique number cl(G) of a graph G is the maximum order of a complete subgraphof G. Show that if a regular graph of order n contains a complete subgraph oforder [n/2J + 1 then it is a complete graph, but for every p, 1 S p 5 n/2, thereis a regular graph G of order n with cl(G) = p.

20. We say that a set W c V(G) covers the edges of a graph G if every edge of G isincident with at least one vertex in W. Denote by ao(G) the minimum number ofvertices covering the edges of G. Prove that if G has n vertices and m edges thenao(G) 5 2mn/(2m + n), with equality iff G = pK' for some p and r, that is if eachcomponent of G is a K' for some r. [Hint. Note that ao(G) = n - cl(G), and ifcl(O) = p then by Turin's theorem e(G) 5 tp(n), so m = (2) - e(t) > (2) - tp(n).]

21. (Cf. Corollary 14.) Let d, 5 d2 <; < d be a graphic sequence such that forsome k

nd,<<k<2 and

Show that there is a non-Hamiltonian graph G with vertex set {x,, x2, ...,such that d(x,) z di, 1 < i S n (cf. Figure IV.7).

Figure IV.7. The graph (K2 u E3) + K3 has no Hamilton cycle and (K2 u E')+ K2 has no Hamilton path.

22. (Cf. Corollary 14) Let d, < d2 < < d be a graphic sequence such that forsome k

dk5k-1<}(n-1) andProve that there is a graph G with vertex set {x,, x2, ... , such that d(x;) >- di,1 < i < n, and G does not contain a Hamilton path (cf. Figure IV.7).

23. Prove that a non-Hamiltonian graph of order n z 3 has at most (Z) - (n - 2)edges and there is a unique extremal graph.

Prove that a graph of order n z 2 without a Hamilton path has at most(2) - (n - 3) edges and K"-' uu E' is the unique extremal graph.

24. Given S < n/2, determine the maximal number of edges in a graph G of order nwithout a Hamilton cycle (path), provided S(G) = S.

25. Prove Theorem 4 by making use of simple transforms of a longest xo-path P =xox, ... x,. [Hint. Apply induction on n. If b(G) 5 k/2, the result follows byinduction, otherwise consider the set L of endvertices of simple transforms of P.Put I = I L1, r = max,EL d(x) and note that l z r and the neighbours of eachx e L are contained in {x x,_ ..., x,_k+,}. Deduce that e(G) - e(G - L)S l(k - I) + l(r + I - k) 5 kl/2 and complete the proof by applying the inductionhypothesis to G - L.]

Page 98: Graph Theory-An Introductory Course-Bela Bollobas

Notes 87

26. Let 1 < a, < a2 < < ak < x be natural numbers. Suppose no ai dividesthe product of any two others. Prove that k < n(x) + x213, where, as usual, n(x)denotes the number of primes not exceeding x. [Hint. Put V , = (1, 2, ... , Lx213 j )and V2 = {x: x213 < b < x and b is a prime}. Show first that ai = b;c;, wherehi, ci E V = V, U V2. Let G be the graph (with loops) with vertex set V whoseedges (loops) are b;ci. Note that G does not contain a path of length 3.]

27.' (Cf. Exercise 26). Let 1 < a, < a2 < . . . < ak < x be natural numbers. Supposea; a; # aka, unless {i, j} = {h, l}. Prove that k < n(x) + cx3'4 for some constantc > 0. [Hint. The graph G of Exercise 26 contains no quadrilaterals; applyTheorem 8 to the bipartite subgraph of G with vertex classes V, and V2. Recall theprime number theorem, namely that (tr(x)log x)/x -+ I as x - oo.]

28. Denote by Dk(n) the maximum number of occurrences of the same positivedistance among n points in 11k. Prove that Dk(n)/n2 =- (1/2[k/2]) if'k z 2. [Hint. (i) Note that if x c- {z c- 68k: zi + z2 = I and z; = 0 if i > 2} andyE{zet :z +z4=1andzi=0ifi#3or41thenIx-y/2. (ii) Deducefrom Theorem 20 that Dk(n) is at least as large as claimed.]

NotesThe results concerning Hamilton cycles and paths presented in the chapterall originate in a paper of G. A. Dirac: Some theorems on abstract graphs,Proc. London Math. Soc. 2 (1952) 69-81. The notion of the k-closure dis-cussed in §3 was introduced in J. A. Bondy and V. Chvatal, A method in graphtheory, Discrete Math. 15 (1976) 111-135; Corollary 14, characterizingminimal forcibly Hamiltonian degree sequences, is in V. Chvatal, OnHamilton's ideals, J. Combinatorial Theory Ser. B 12 (1972) 163-168. Thespecial case of Theorem 17 concerning cubic (that is 3-regular) graphs wasproved by C. A. B. Smith, and was first mentioned in W. T. Tutte, On Hamil-tonian circuits, J. London Math. Soc. 21 (1946) 98-101; the theorem itself is dueto A. G. Thomason, Hamiltonian cycles and uniquely edge colourable graphs,Annals of Discrete Math. 3 (1978) 259-268.

The fundamental theorem of Turin concerning complete subgraphs is inP. Turin, On an extremal problem in graph theory (in Hungarian), Mat. esFiz. Lapok 48 (1941) 436-452; its extension, Theorem 6, giving more in-formation about the degree sequence of a graph without a K' is in P. Erdos,On the graph theorem of Turin (in Hungarian), Mat. Lapok 21 (1970)249-251. The Erdos-Stone theorem is in P. Erdos and A. H. Stone, On thestructure of linear graphs, Bull. Amer. Math. Soc. 52 (1946) 1087-1091, itsextension, Theorem 20, is in B. Bollobas and P. Erdos, On the structure ofedge graphs, Bull. London Math. Soc. 5 (1973) 317-321. A rather detailedexposition of the results concerning the structure of extremal graphs,referred to at the end of §4, can be found in Chapter VI of B. Bollobas,Extremal Graph Theory, Academic Press, London-New York-SanFrancisco, 1978; Chapter III of the same book concerns cycles and containsmany more results than we could present in this chapter.

Page 99: Graph Theory-An Introductory Course-Bela Bollobas

CHAPTER V

Colouring

We wish to arrange the talks in a congress in such a way that no participantwill be forced to miss a talk he would like to hear, that is that there are noundesirable clashes. Assuming a good supply of lecture rooms enabling us tohold as many parallel talks as we like, how long will the program have tolast? Let us reformulate this question in terms of graphs. Let G be the graphwhose vertices are the talks and in which two talks are joined if there is aparticipant wishing to attend both. What is the minimum value of k for whichV(G) can be partitioned into k classes, say V1, V2, ..., Vk, such that no edgejoins two vertices of the same class? As in §4 Chapter IV, we denote thisminimum by X(G) and call it the (vertex) chromatic number of G. The termin-ology originates in the usual definition of X(G): a colouring of the verticesof G is an assignment of colours to the vertices in such a way that adjacentvertices have distinct colours; X(G) is then the minimal number of colours ina (vertex) colouring of G.

Let us remark here that we shall use real colours (red, blue, ...) only ifthere are few colours, otherwise the natural numbers will be our "colours".Thus a k-colouring of the vertices of G is a function c: V(G) --+ {1, 2,... , k}such that each set c -1(j) is independent.

Another scheduling problem goes as follows. Each of n businessmenwishes to hold confidential meetings with some of the others. Assumingthat each meeting lasts a day and at each meeting exactly two businessmenare present, in how many days can the meetings be over? In this case oneconsiders the graph H whose vertices correspond to the n businessmen andtwo vertices are adjacent if the two businessmen wish to hold a meeting.Then the problem above asks for the minimal number of colours in an edge-colouring of H, that is in a colouring of the edges of H in such a way that no

88

Page 100: Graph Theory-An Introductory Course-Bela Bollobas

§1 Vertex Colouring 89

two adjacent edges have the same colour. This number, denoted by X'(H),is the edge chromatic number of H.

In this chapter we shall present some of the basic properties of the vertexand edge chromatic numbers. The final section (§3) is devoted to colouringplanar graphs and to a very brief outline of the proof of the best knownresult in graph theory, the so called four colour theorem.

§1 Vertex Colouring

In Chapter I. §2 we noted the trivial fact that a graph is bipartite if it doesnot contain an odd cycle. Thus X(G) z 2 if G contains an edge and X(G) z 3if G contains an odd cycle. For k z 4 we do not have a similar character-ization of graphs with chromatic number at least k, though there are somecomplicated characterizations (cf. Exercises 32-35). Of course, if G K'k

then X(G) >_ k and if G does not contain h + 1 independent vertices thenX(G) >_ I G I /h. However, it is not easy to see that there are triangle-freegraphs of large chromatic number (cf. Exercise 11), though in Chapter VIIwe shall show that there exist graphs with arbitrarily large chromaticnumber and arbitrarily large girth. The difficulty we encounter in findingsuch graphs shows that it would be unreasonable to expect a simple character-ization of graphs with large chromatic number. Thus we shall concentrateon finding efficient ways of colouring a graph.

How should one try to colour the vertices of a graph with colours 1, 2, ...using as few colours as possible? A simple way is as follows. Order thevertices, say x,, x2, .... x and then colour them one by one: colour x, 1,then colour x2 1 if x, x2 0 E(G) and 2 otherwise, and so on, colour each vertexthe smallest colour it can have at that stage. This so-called greedy algorithmdoes produce a colouring, but this colouring may and usually does use manymore colours than necessary. Figure V.1 shows a bipartite (i.e., 2-colourable)graph for which the greedy algorithm wastes four colours. However, it iseasily seen (Exercise 3 -) that for every graph the vertices can be ordered insuch a way that the greedy algorithm uses as few colours as possible. Thus it isnot surprising that it pays to investigate the number of colours needed bythe greedy algorithm in various orders of the vertices.

X, - x3 xs x7

1 2 3 4x2 x4 x6 xs

Figure V.1. In the order x,, x2, ... , xe the greedy algorithm needs four colours.

Page 101: Graph Theory-An Introductory Course-Bela Bollobas

90 V Colouring

Let us start with an immediate consequence of the algorithm.

Theorem 1. Let k = maxH 5(H), where the maximum is taken over all spannedsubgraphs of G. Then X(G) < k + 1.

PROOF. Write x for a vertex of degree at most k, and put G -By assumption has a vertex of degree at most k. Let one ofthem and put G - {x,,, Continuing inthis way we enumerate all the vertices.

Now the sequence x,, x2, ... , xn is such that each x j is joined to at mostk vertices preceding it. Hence the algorithm will never need colour k + 2to colour a vertex.

It is, of course, very easy to improve the efficiency of the greedy algorithm.If we already know a subgraph Ho which can be coloured with few colours,in particular, if we know a colouring of Ho with X(Ho) colours, then we maystart our sequence with the vertices of H0, colour Ho in an efficient wayand apply only then the algorithm to colour the remaining vertices. Thisgives us the following extension of Theorem 1.

Theorem 2. Let Ho be a spanned subgraph of G and suppose every subgraphH satisfying Hoc H c G, V(H D) # V(H), contains a vertex x c- V(H)- V(H0) with dH(x) < k. Then

x(G) 5 max{k + 1, X(Ho)}.

In some cases the problem of colouring a graph can be reduced to theproblem of colouring certain subgraphs of it. This happens if the graph isdisconnected or has a cutvertex or, slightly more generally, contains acomplete subgraph whose vertex set disconnects the graph. Then we maycolour each part separately since, at worst by a change of notation, we canfit these colourings together to produce a colouring of the original graph,as shown in Figure V.2.

G

G3

31 'b2

Figure V.2. The vertex set of the thick triangle disconnects G;

X(G) = maxlX(G1), X(G2), X(G3)).

Page 102: Graph Theory-An Introductory Course-Bela Bollobas

§1 Vertex Colouring 91

As a rather crude consequence of Theorem 1 we see that X(G) < A + 1,where A = A(G) is the maximum degree of G, since maxHCG 6(H)< A(G).Furthermore, if G is connected and not A-regular then clearly maxHCG S(H)< A - 1 so X(G) < A. The following result, due to Brooks, takes care of theregular case.

Theorem 3. Let G be a connected graph with maximal degree A. Suppose G isneither a complete graph nor an odd cycle. Then X(G) < A.

PROOF. We know already that we may assume without loss of generality thatG is 2-connected and A-regular. Furthermore, we may assume that A > 3,since a 2-regular 3-chromatic graph is an odd cycle.

If G is 3-connected, let x,, be any vertex of G and let xt, x2 be two non-adjacent vertices in r(x ). If G is not 3-connected, let x be a vertex for whichG - x,, is separable, so has at least two blocks. Since G is 2-connected, eachendblock of G - x has a vertex adjacent to x,,. Let xt and x2 be such verticesbelonging to different endblocks.

In either case we have found vertices x1, x2 and x such that G - {xt, x2}is connected, xtx2 0 E(G) but xtx a E(G) and x2x e E(G). Let t e V -{xt, x2, be a neighbour of x,,, let x or x,,- 1, etc.Then the order x1, x2, x3, ... , X. is such that each vertex other than x isadjacent to at least one vertex following it. Thus the greedy algorithm willuse at most A colours, since xt and x2 get the same colour and x is adjacentto both.

Another colouring algorithm can be obtained by reducing the problem tocolouring two other graphs derived from G. This reduction also enables us toobtain some information about the number of colourings of a graph with agiven set of colours.

Let a and b be non-adjacent vertices of a graph G. Let G' be obtained fromG by joining a to b, and let G" be obtained from G by identifying a and b.Thus in G" there is a new vertex ab instead of a and b, which is joined to thevertices adjacent to at least one of a and b (Figure V.3). The colourings of Gin which a and b get distinct colours are in 1-1 correspondence with thecolourings of G'. Indeed c: V(G) -+ {1, 2, .. ., k} is a colouring of G withc(a) 0 c(b) if c is a colouring of G'. Similarly the colourings of G in which

G G' G"

a

Figure V.3. The graphs G' and G".

Page 103: Graph Theory-An Introductory Course-Bela Bollobas

92 V Colouring

a and b get the same colour are in a 1-1 correspondence with the colouringsof G". In particular, if for a natural number x and a graph H we write pH(x)for the number of colourings of a graph H with colours 1, 2, ... , x, then

PG(X) == Pa(x) + PG"(x) (1)

By definition x(G) is the least natural number k for which pG(k) > 1. Thusboth the remarks above and relation (1) imply that

x(G) = min{x(G'), x(G,)}. (2)

The basic properties of pH(x) are given in our next result.

Theorem 4. Let H be a graph with it >- 1 vertices, in edges and k components.Then

n--k

PH(x) `_ I(-1)'aix"-',

=o

where ao = 1, al = in and ai > O for every i, 0 < i < n - k.

PROOF. We apply induction on n + in. For n + in = 1 the assertions aretrivial so we pass to the induction step. If in = 0, we are again home sincein this case k = n and as every map f : V(H) - { 1, 2, . . ., x} is a colouringof H, we have pH(x) = x". If in :> 0 we pick two adjacent vertices of H, saya and b. Putting G = H - ab we find that G' = H. Since e(G) = in - 1 andI G" I + e(G") < n - 1 + in, by the induction hypothesis the assertions of thetheorem hold for pG(x) and Note now that G" has k components andG has at least k components. Therefore

n-k

PG(X) = x" - (m - 1)x" -' + Y_ (-1)'bi x"i=2

where bi >- 0 for each it andn-k

i=2

where ci > 0 for each i. Hence, by (1),

PH(x) = PG'(X) = PG(x) - PG°(x) = x" -MX,, -I

n-k=x"-mx"-' +Y (-1)'aixn-i

,

=2

n-k

+ Y (-1)'(bi + ci)x" -'i=2

where ai > 0 for each i.

Because of Theorem 4 we are justified in calling pH(x) the chromaticpolynomial of H. The chromatic polynomial is closely connected to variousenumeration problems, some of which will be discussed in Ch. VIII. In par-

Page 104: Graph Theory-An Introductory Course-Bela Bollobas

§2 Edge Colouring 93

ticular, the modulus of each coefficient of p,(x) is the number of certainsubgraphs of H (cf. Exercise 12+).

Let us describe now the algorithm based on the reduction G - {G', G"}.Given a graph G, construct a sequence of graphs Go, G1, ... as follows. PutGo = G. Having constructed G;, if G, is complete, terminate the sequence,otherwise let G, + 1 be G; or G". The sequence has to end in a complete graphG,, say of order I G, I = k. A k-colouring of G, can easily be lifted to a k-colouring of the original graph G, so X(G) < k. In fact, equality (2) showsthat X(G) is the minimum order of a complete graph in which a sequenceGo, G1,... can terminate.

There are other problems that can be tackled by the reduction G -'{G', G"}; a beautiful example is Exercise 16+.

§2 Edge Colouring

In a colouring of the edges of a graph G the edges incident with a vertexget distinct colours, so X'(G), the edge chromatic number, is at least aslarge as the maximum degree, A(G) = maxx d(x),

x'(G) >- 0(G) (3)

At first sight it is somewhat surprising that this trivial inequality is in fact,an equality for large classes of graphs, including the class of bipartite graphs.Indeed, Exercise 22 of Chapter III, which is a consequence of Hall's theorem,asserts that the edge set E(G) of a bipartite graph G can be partitioned into0(G) classes of independent edges, that is X '(G) = 0(G).

Another trivial lower bound on X '(G) follows from the fact that if G doesnot contain fi + 1 independent edges, then each colour class has at most $edges so we need at least Fe(G)/J31 colour classes to take care of all the edges:

x'(G) ? re(G)/pl. (4)

Similarly to Theorem 9 of Chapter 1, it is easily shown that if G is a completegraph of order at least 2 then equality holds in (4), that is X'(K") = n - 1 if nis even and X'(K") = n if n >- 3 is odd (Exercise 28).

How can one obtain an upper bound for X'(G)? Since each edge is adjacentto at most 2(0(G) - 1) edges, Theorem 1 implies that

X'(G) < 20(G) - 1.

Furthermore, if A(G) >: 3, the theorem of Brooks gives

X'(G) < 20(G) - 2.

At first sight this inequality seems reasonably good. However, the followingfundamental theorem of Vizing shows that this is not the case, for the edge-chromatic number is almost determined by the maximum degree.

Page 105: Graph Theory-An Introductory Course-Bela Bollobas

94 V Colouring

Theorem 5. A(G) < x '(G) < 0(G) + 1.

PROOF. Put A = A(G) and assume that we have used 1, 2, ... , A + 1 tocolour all but one of the edges. We are home if we can show that this un-coloured edge can also be coloured.

We say that a colour is missing at a vertex z if no edge incident with zgets that colour. If z is incident with d'(z) < d(z) < A edges that have beencoloured, then A + 1 - d'(z) colours are missing at z. In particular, at eachvertex at least one colour is missing. Our aim is to move around the coloursand the uncoloured edge in such a way that a colour will be missing at bothendvertices of the uncoloured edge, enabling us to complete the colouring.

Let xy, be the uncoloured edge; let s be a colour missing at x and let t,be a colour missing at y,. We shall construct a sequence of edges xy,, xy2 , ... ,and a sequence of colours t1, t2, ... such that t, is missing at y; and xyi+

1

has colour t;. Suppose we have constructed xy,, .. ., xy; and to ... , t;.There is at most one edge xy of colour t;. If y 0 {y...... y;}, we put y;+ i = Yand pick a colour t;+, missing at yi+,, otherwise we stop the sequence.These sequences have to terminate at most A(G) terms; let xy...... xyh andt,, ... , th be the complete sequences. Let us examine the two reasons thatmay have forced us to terminate these sequences.

(a) No edge xy has colour th. Then recolour the edges xy;, i < h, givingxy; the colour t;. In the colouring we obtain every edge is coloured, exceptXYh. However, since th occurs neither at x nor at yh, we may complete thecolouring by assigning th to xyh.

(b) For some j < h the edge xyj has colour th. To start with, recolour theedges xy;, i < j, giving xy, the colour t;. In this colouring the uncoloured edgeis xy;. Let H(s, th) be the subgraph of G formed by the edges of colour sand th. Each vertex of H(s, th) is incident with at most 2 edges in H(s, th) (one ofcolour s and the other of colour th) so the components of H(s, th) are pathsand cycles. Each of the vertices x, and yh has degree at most 1 in H(s, th),so they cannot belong to the same component of H(s, th). Thus at least oneof the following two cases has to hold.

(bl) The vertices x and yj belong to distinct components of H(s, th). Inter-change the colours s and th in the component containing yj. Then the colours is missing at both x and y,, so we may complete the colouring by giving xyjthe colour s.

(b2) The vertices x and yh belong to distinct components of H(s, th).Continue the recolouring of the edges incident with x by giving xy; the colourt, for each i < h, thereby making x.yh the uncoloured edge. This change doesnot involve edges of colour s and th, so H(s, th) has not been altered. Nowswitch around the colours in the component containing yh. This switchmakes sure that the colour s is missing at both x and yh, so we can use s tocolour the so far uncoloured edge xyh.

Note that the proof above gives an algorithm for colouring the edgeswith at most A + 1 colours.

Page 106: Graph Theory-An Introductory Course-Bela Bollobas

§3 Graphs on Surfaces

§3 Graphs on Surfaces

95

The most famous problem in graph theory is undoubtedly the four colourproblem: prove that every plane graph is 4-colourable. The weaker assertion,namely that every plane graph is 5-colourable, is an almost immediateconsequence of Euler's formula.

Theorem 6. Every plane graph is 5-colourable.

PROOF. Suppose the assertion is false and let G be a 6-chromatic plane graphwith minimal number of vertices. By Theorem 12 of Chapter I G has a vertexx of degree at most 5. Put H = G - x. Then H is 5-colourable, say withcolours 1, 2, ... , 5. Each of these colours must be used to colour at least oneneighbourhood of x, otherwise the missing colour could be used to colour x.Hence we may assume that x has 5 neighbours, say x1, x2, ..., x5 in somecyclic order about x, and the colour of xi is i, i = 1, 2, ... , 5. Denote byH(i, j) the subgraph of H spanned by the vertices of colour i and j.

Suppose first that x1 and x3 belong to distinct components of H(1, 3).Interchanging the colours 1 and 3 in the component of x1, we obtain another5-colouring of H. However, in this 5-colouring both x1 and x3 get colour 3,so 1 is not used to colour any of the vertices x1, ... , x5. This is impossiblesince then x can be coloured 1.

Since x1 and x3 belong to the same component of H(l, 3), there is an x1-x3path P13 in H whose vertices are coloured 1 and 3. Analogously H containsan x2-x4 path P24 whose vertices are coloured 2 and 4. However, this isimpossible, since the cycle xx1P13x3 of G separates x2 from x4 but P24cannot meet this cycle (Figure V.4).

Clearly not every plane graph is 3-colourable. Indeed, K4 is planar andit does need 4 colours. Another 4-chromatic planar graph is obtained by join-ing all five vertices of a C5 to a sixth vertex. Thus if we want to determineXo = max{X(G): G is planar} then we see immediately that Xo > 4 andXo < 5 and the problem is to prove Xo < 4.

Instead of a plane graph we may wish to consider a graph drawn on anorientable surface of genus y > 0 and ask for X,, the maximum of the chromatic

P13

Figure V.4. The paths P,3 and P24.

Page 107: Graph Theory-An Introductory Course-Bela Bollobas

96 V Colouring

number of such a graph. We shall see in a moment that in this problem weencounter a rather different difficulty. For our limited purpose it will sufficeto remark that an orientable surface S. of genus y >- 1 is obtained from asphere by attaching to it y "handles", and a graph of order n drawn on SYhas at most 3n + 6(y - 1) edges. Thus S1 is the torus, and every toroidalgraph (that is, graph that can be drawn on a torus) of order n has at most 3nedges. The following easy upper bound on the chromatic number of a graphdrawn on an orientable surface of genus y >- 1 was obtained by Heawoodin 1890.

Theorem 7. The number of colours needed to colour a graph drawn on anorientable surface of genus y I is at most

H(y) _ [4{7 + 1 + 48y}j.

PROOF. Let G be the graph in question and let H be any subgraph of G. ByTheorem 1 we are home if we show that 8(H) < H(y) - 1. If H has n vertices,it has at most 3n + 6(y - 1) edges so

b(H) < min{n - 1, 6 +L'21) I}

n JI

Hence the result follows if

12(y - 1)6 +

H(y) - 1 - H(y) - 1.RWitha little work one can check that this inequality indeed holds.

By applying a stronger colouring result than the trivial Theorem 1, onecan show that H(y) - 1 colours suffice to colour a graph on SY unless thegraph contains a complete graph of order H(y). Thus xY = H(y) if K"can be drawn on S. Heawood gave a false proof of the assertion xY = H(y);the first correct proof, due to R.ingel and Youngs, was found only over 75years later. Note that the difficulty in proving this deep result lies in findinga drawing of a fixed and single graph, K'(1), on a surface of genus y > 0. Onthe other hand, in order to solve the four colour problem one has to show thatevery plane graph can be coloured with four colours. Thus the problem ofdetermining xo has almost nothing to do with the problem of determiningX. for y >- 1.

Before saying a few words about the solution of the four colour problem,let us point out that H(1) = 7 is easily proved; in fact, this was indeed provedby Heawood. All one needs is that K' can be drawn on the torus. Recallingthat a torus can be obtained from a rectangle by identifying opposite sides,Figure V.5 shows a required drawing.

We saw in Chapter I. §4 that a plane graph G determines a map M = M(G)consisting of the plane graph G and the countries determined by the planegraph. A colouring of a map is a colouring of the countries such that no two

Page 108: Graph Theory-An Introductory Course-Bela Bollobas

§3 Graphs on Surfaces

1

1 2 3 1

Figure V.5. A drawing of K' on the torus.

97

countries sharing an edge in their boundaries get the same colour. Showthat every plane map can be coloured with four colours. This is the originalform of the four colour problem, as posed by Francis Guthrie in 1852. Histeacher, de Morgan, circulated it amongst his colleagues, but the problem wasfirst made popular in 1878 by Cayley, who mentioned it before the RoyalSociety. Almost at once "proofs" appeared, by Kempe in 1879 and by Tait in1880. Heawood's refutation of Kempe's proof was published in 1890, thoughhe modified the proof to obtain the five colour theorem. Tait's paper alsocontained false assumptions which prompted Petersen to observe in 1891that the four colour theorem is equivalent to the conjecture that every2-connected cubic planar graph has edge chromatic number three (Exercise27). Contributions to the solution since the turn of the century includeBirkhoff's introduction of the chromatic polynomial and works by variousauthors giving lower bounds on the order of a possible counterexample. In1943 Hadwiger made a deep conjecture containing the four colour problemas a special case: if x(G) = k then G is contractible to K' (see Exercises 18-20).

In hindsight the most important advance was made by Heesch, whodeveloped the method of discharging to find unavoidable sets of reducibleconfigurations. The problem was at last solved by Appel and Haken in 1976,making use of a refinement of Heesch's method and fast electronic com-puters. The interested reader is referred to some papers of Appel and Haken,and to the book of Saaty and Kainen for a detailed explanation of the under-lying ideas of the proof. All we have room for is a few superficial remarks.

What makes the five colour theorem true? The following two facts: (i) aminimal 6-chromatic plane graph cannot contain a vertex of degree atmost 5, and (ii) a plane graph has to contain a vertex of degree at most 5.We can go a step further and ask why (i) and (ii) hold. A look at the proofshows that (i) is proved by making a good use of the paths P.,, called Kempechains after Kempe, who used them in his false proof of 1879, and (ii) followsimmediately from Euler's formula n - e + f = 2.

The attack on the four colour problem goes along similar lines. A con-figuration is a connected cluster of vertices of a plane graph together withthe degrees of the vertices. A configuration is reducible if no minimal 5-chromatic plane graph can contain it, and a set of configurations is un-avoidable if every plane graph contains at least configuration belonging to

Page 109: Graph Theory-An Introductory Course-Bela Bollobas

98 V Colouring

the set. In order to prove that every plane graph is 4-colourable, one sets outto find an unavoidable set of reducible configurations. How should one showthat a configuration is reducible`? Replace the cluster of vertices by a smallercluster, 4-colour the obtained smaller graph and use Kempe chains to showthat the 4-colouring can be "pulled back" to the original graph. Howshould one show that a set of configurations is unavoidable? Make extensiveuse of Euler's formula. Of course, one may always assume that the graph is amaximal plane graph. Assigning a charge of 6 - k to a vertex of degree k,Euler's formula guarantees that the total charge is 12. Push charges aroundthe vertices, that is transfer some charge from a vertex to some of its neigh-bours, until it transpires that the plane graph has to contain one of the con-figurations.

Looking again at the five colour theorem, we see that the proof was basedon the fact that set of configurations of single vertices of degree at most 5 isan unavoidable set of configurations (for the five colour theorem).

The simplistic sketch above does not indicate the difficulty of the actualproof. In order to rectify this a little, we mention that Appel and Hakenhad to find over 1900 reducible configurations to complete the proof.Furthermore, we invite the reader to prove the following two simpleassertions.

1. The configurations in Figure V.6 are reducible.

iFigure V.6. Three reducible configurations; in the second examples the outer verticesmay have arbitrary degrees.

2. Let G be a maximal planar graph of order at least 25 and minimumdegree 5. Call a vertex a major vertex if its degree is at least 7, otherwisecall it a minor. Then G contains one of the following:

(a) a minor vertex with 3 consecutive neighbours of degree 5,(b) a vertex of degree 5 with minor neighbours only,(c) a major vertex with at most one neighbour of degree at least 6.

EXERCISES

1.- Show that a graph G has at least ("P) edges.

2. For each k >_ 3 find a bipartite graph with vertices x,, x2, ..., x for which thegreedy algorithm uses k colours. Can it be done with n = 2k 2? Show that itcannot be done with n = 2k - 3.

Page 110: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 99

Given a graph G, order its vertices in such a way that the greedy algorithm usesonly k = y(G) colours.

4.- Let d, >- d2 > ... >- d" be the degree sequence of G. Show that in an orderx,, x2, ..., x", d(x,) = di, the greedy algorithm uses at most max min{d; + 1, i)colours, and so if k is the maximal natural number for which k S dk + 1 theny(G) 5 k.

5. Deduce from Exercise 4 that if G has n vertices then

y(G) + y(G) < n + 1.

6.- Show that y(G) + y(G) >- 2,/n.

7. Let d, d, and d2 be non-negative integers with d, + d2 = d - 1. Prove that ifA(G) = d then the vertex set V(G) of G can be partitioned into two classes, sayV(G) = V, v V2, such that the graphs Gi = G[Y] satisfy A(G;) S di, i = 1, 2.[Hint. Consider a partition V(G) = V, v V2 for which d,e(G2) + d2e(G,) isminimal.]

8. (Exercise 7 continued) Let now d, dl, d2, ..., d, be non-negative integers withYi (d; + 1) = d + 1. Prove that if 0(G) = d then there is a partition V(G) _U' I; such that the graphs G; = G[V] satisfy.(Gi) < d;, i = 1, 2, ... , r.

9. Given natural numbers r and t,,2r < t, the Kneser graph K;') is constructed asfollows. Its vertex set is T('), the set of r-element subsets of T = {1, 2, ..., t}, andtwo vertices are joined if they are disjoint subsets of T. Figure V.7 shows K521, theso called Petersen graph. Prove that y,(K;')) < t - 2r + 2, 3 andy(K6')=4.

Figure V.7. The Petersen graph and the Grotzsch graph.

10. Check that the Grotzsch graph (Figure V.7) has girth 4 and chromatic number 4.Show that there is no graph of order 10 with girth at least 4 and chromatic number4.

11 .' Try to construct a triangle free graph of chromatic number 1526 without lookingat Chapters VI or VII.

12' Let H be a graph of order n with edges e,, e2, ..., e", and chromatic polynomialPH(x) = E""=o (-1)'r; x"-'. Call a set of edges a broken cycle if it is obtained fromthe edge set of a cycle by omitting the edge of highest index. Show that c; is thenumber of I-element subsets of the edges containing no broken cycle. [Hint.Imitate the proof of Theorem 4, choosing e, for ab. Put G = H - e, so thatH = G' and pH(x) = pG(x) - pG..(x). If an edge of G" comes from two edges of G,say from xa = e; and xb = eh, label it with ek, where k = max{i, h}; otherwisekeep the label it had in G (and H). Let F be a set of edges of H containing no

Page 111: Graph Theory-An Introductory Course-Bela Bollobas

100 V Colouring

broken cycle of H. Note that if e, F then F is a set of edges of G containingno broken cycle, and if e, e F then F - (e,) is a set of edges of G" containing nobroken cycle.]

13. Let pG(x) = Y_"=o (-1)'aix"-' be the chromatic polynomial of G. Prove that a2 =(2) - k3(G), where m = e(G) and k3(G) is the number of triangles in G.

14. Show that there is a unique graph (;0 of order n and size m = Ln2/4J such that if Gis also of order n and size m then

PO(x) <_ Pc"(x)

whenever x is sufficiently large.

15.- Find graphs G and H of order n and same size such that X(G) < X(H) but po(x) <PH(X) if x is sufficiently large.

16' Given a connected graph G containing at least one cycle, define a graph H on theset S of all spanning trees of G by joining T, to T2 if I E(T,)\E(T2) I = 1. (Cf.simple transform of an x-path, p. i9). Imitate the proof of the fact that pH(x) is apolynomial (Theorem 4) and the proof suggested in Exercise 12+, to show thatH is not only Hamiltonian, but every edge of it is contained in a Hamiltoniancycle.

17.' We say that a graph G has a suhgraph contractible to a graph H with vertexset {y,, ... , yk} if G contains vertex disjoint connected subgraphs G,, ... , Gksuch that, for i # j, yi y; e E(H) if G has a G;-G; edge.

Prove that for every natural number p there is a minimal integer c(p) such thatevery graph with chromatic number at least c(p) has a subgraph contractibleto K°. Show that c(1) = 1, c(2) = 2 and c(n + 1) < 2c(n) - 1 for n >- 2.[Hint. Pick xo E G and let Sk be -:he "sphere" of centre xo and radius k; Sk ={x e G: d(xo, x) = k}. Show that X,' G) < X(Sk) + X(Sk+1) for some k.]

18.+ Hadwiger's conjecture states that c(p) = p for every p. Prove this for p < 4.

19. Deduce from Kuratowski's theorem, Theorem 13 of Chapter I, that a graph isplanar if it has no subgraph contractible to K5 or K3.3.

20. Show that the truth of Hadwiger's conjecture for p = 5 implies the four colourtheorem.

2l.- Show that a map M = M(G) can be 2-coloured (see p. 96) if every vertex of Ghas even degree.

22' Suppose G is a cubic plane graph. Prove that the map M(G) is 3-colourable ifeach country has an even number of sides.

23.- Let M = M(G) be a triangular map, that is a map in which every country hasthree sides. Show that M is 3-colourable unless G = K.

24.- Prove that a map M = M(G) is 4-colourable if G has a Hamilton cycle.

257 For each plane graph G construct a cubic plane graph H such that if M(H) isis 4-colourable then so is M(G).

Page 112: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 101

26.- According to Tait's conjecture every 3-connected cubic plane graph has a Hamiltoncycle. (i) Show that Tait's conjecture implies the four colour theorem. (ii) Byexamining the graph in Figure V.8 disprove Tait's conjecture.

Figure V.B. Tutte's counterexample to Tait's conjecture

27' Let G be a cubic plane graph. Show that G is 3-edge-colourable if M(G) is 4-colourable. [Hint. Let 1, a, b and c be the elements of the Klein fourgroup C2 x C2,so that a2 = b2 = c2 = 1. Colour the edges with a, b and c, and the countrieswith 1, a, b and c.]

28." Find the edge chromatic number of K".

29. The cubic graph G has exactly one edge-colouring with X'(G) colours. Show thatX '(G) = 3 and that G has exactly 3 Hamilton cycles.

30. Let n = 2°. Show that K"' is not the union of p bipartite graphs but K" is.Deduce that if there are 2° + 1 points in the plane then some three of them deter-mine an angle of size at least n(1 - (11p)).

31. Let X(G) = k. What is the minimal number of r-chromatic graphs whose unionis G?

32. Show that a k-chromatic graph can be oriented in such a way that a longestdirected path has k vertices.

33. Show that if a graph G can be oriented in such a way that no directed path containsmore than k vertices then X(G) S k. [Hint. Omit a minimal set of edges to destroyall directed cycles. For a vertex x let c(x) be the maximal number of vertices on adirected path in the new graph starting at x. Check that c is a proper colouring.]

34. Denote by 'Pk the set of (isomorphism classes of) graphs of chromatic numberat least k. Let G1 and G2 be vertex disjoint graphs in 'Sk and let aibi be an edgeof Gi, i = 1, 2. Let G = G1 V G2 be obtained from G, u G2 by omitting the edges

G,

a, b,

G=G,VG2GZ

Figure V.9. The Hajds operation.

Page 113: Graph Theory-An Introductory Course-Bela Bollobas

102 V Colouring

a,b,, a2 b2, adding the edge b,b2 and identifying the vertices a1 and a2. (The opera-tion V is said to be the Hajds operation, see Figure V.9.) Prove that G e',k-

3 5.' Let JV'k be the smallest collection of (isomorphism classes of) graphs such that(1) Kk e Jk, (2) if H e .#'k and G H then G C_ .W'k, (3) if H E .$",, and G isobtained from H by identifying two non-adjacent vertices, then G e irk, (4) ifG,, G2 e irk and G = G1 \7 G2 then G e)t'k. Prove that .lt'k = Sk. [Hint.Exercise 33 implies that .at''k c 40k . Assume that the converse inclusion is false andlet G e Sk\irk be a counterexamp,e of minimal order and maximal size. G cannotbe a complete q-partite graph so it contains vertices a, b, and b2 such thatb1b2 E E(G) but ab1, ab2 tE E(G). Let G, = G + ab1 and G2 = G + ab2. ThenG1 and G2 are not counterexamples so belong to .)E'k. Find out how G can beobtained from copies of G1 and G, by the allowed operations.]

36. Let k be a natural number. Prove that an infinite graph is k-colourable if everyfinite subgraph of it is. [Hint. Apply Tychonov's theorem as in Exercise 24 ofChapter III.]

NotesTheorem 3 is in R. L. Brooks, On colouring the nodes of a network, Proc.Cambridge Phil. Soc. 37 (1941) 194--197, and Vizing's theorem, Theorem 5, isin V. G. Vizing, On an estimate of the chromatic class of a p-graph (in Russian),Diskret. Analiz 3 (1964) 23-30, A detailed account of results concerningcolouring graphs on surfaces, culminating in Ringel and Youngs' proof ofHeawood's conjecture, can be found in Map Color Theorem, Grundlehrender math. Wiss. 209, Springer-Verlag, Berlin, 1974. The use of the dis-charging procedure in attacking the four colour problem is described in H.Heesch, Untersuchungen zum Vierfarbenproblem, B-I-Hochschulskripten810/810a/810b, Bibliographisches Institut, Mannheim, Vienna, Zurich,1969. The proof of the four colour theorem appears in K. Appel and W.Haken, Every planar map is four colourable, Part I : discharging, Illinois J.of Math. 21 (1977) 429-490 and K. Appel, W. Haken and J. Koch, Everyplanar map is four colourable, Part II: reducibility, Illinois J. of Math. 21(1977) 491-567. A history of the four colour problem and a digest of itsproof are provided by T. L. Saaty and P. C. Kainen, The Four Color Problem,Assaults and Conquest, McGraw-Hill, New York, 1977. The partition resultsof Exercises 7 and 8 are in L. Lovasz, On decomposition of graphs, Studia Sci.Math., Hungar. 1 (1966) 237-238.

The result in Exercise 33 is due to T. Gallai, On directed paths and circuits,in Theory of Graphs (P. Erdos and G. Katona, eds.), Academic Press, NewYork, 1968, 115-118, and that of Exercise 35 was proved by G. Hajos,Ober eine Konstruktion nicht n-farbbarer Graphen, Wiss. Zeitschr. MartinLuther Univ. Halle-Wittenberg, Math.-Natur. Reihe 10 (1961) 116-117.

Colouring is a naturally appealing part of graph theory and the subjecthas a vast literature. Many of the fundamental results are due to G. A. Dirac;for these and other results see Chapter V. of B. Bollobas, Extremal GraphTheory, Academic Press, London and New York, 1978.

Page 114: Graph Theory-An Introductory Course-Bela Bollobas

CHAPTER VI

Ramsey Theory

Show that in a party of six people there is always a group of three whoeither all know each other or are all strangers to each other. This well knownpuzzle is a special case of a theorem proved by Ramsey in 1928. The theoremhas many deep extensions which are important not only in graph theory andcombinatorics but in set theory (logic) and analysis as well. In this chapterwe prove the original theorems of Ramsey, indicate some variations andpresent some applications of the results.

§1 The Fundamental Ramsey Theorems

We shall consider partitions of the edges of graphs and hypergraphs. Forthe sake of convenience a partition will be called a colouring, but one shouldbear in mind that a colouring in this sense has nothing to do with the edgecolourings considered in Chapter V. Adjacent edges may have the samecolour and, indeed, our aim is to show that there are large subgraphs all ofwhose edges have the same colour. In a 2-colouring we shall always choosered and blue as colours; a subgraph is red (blue) if all its edges are red (blue).

Given a natural number s, there is an n(s) such that if n >_ n(s) then everycolouring of the edges of K" with red and blue contains either a red K' or ablue K'. In order to show this and to give a bound on n(s), we introduce thefollowing notation: R(s, t), called Ramsey number, is the minimum of nfor which every red-blue colouring of K" yields a red K' or a blue K`. (Weassume that s, t Z 2, for we adopt the reasonable convention that every K'is both red and blue since it has no edges.) A priori it is not clear that R(s, t)

103

Page 115: Graph Theory-An Introductory Course-Bela Bollobas

104 VI Ramsey Theory

is finite for every s and t. However, it is obvious that

R(s, t) = R(t, S) for every s, t > 2

and

R(s, 2) = R(2, s) = s,

since in a red-blue colouring of K° either there is a blue edge or else everyedge is red. The following result shows that R(s, t) is finite for every s and t,and at the same time it gives a bound on R(s, t).

Theorem 1. Ifs > 2 and t > 2 then

R(s, t) < R(s -- 1, t) + R(s, t - 1) (1)

and

-R(s, t)

Is + t 2

s-1(2)

PROOF. (i) When proving (1) we may assume that R(s - 1, t) and R(s, t - 1)are finite. Let n = R(s - 1, t) + R(s, t - 1) and consider a colouring of theedges of K" with red and blue. We have to show that this colouring containseither a red KS or a blue K'. Let x be a vertex of K". Since d(x) = n - 1 =R(s - 1, t) + R(s, t - 1) - 1, either there are at least n1 = R(s - 1, t) rededges incident with x or there are at least n2 = R(s, t - 1) blue edges incidentwith x. By symmetry we may assume that the first case holds. Consider asubgraph K"' of K" spanned by n1 vertices joined to x by a red edge. If K"'has a blue K', we are home. Otherwise K"' contains a red Ks-' which formsa red Ks with x.

(ii) Inequality (2) holds if s = 2 or t = 2 (in fact, we have equality sinceR(s, 2) = R(2, s) = s). Assume now that s > 2, t > 2 and (2) holds for everypair (s', t') with 2 < s', t' and s' + t' < s + t. Then by (1) we have

R(s, t) < R(s - 1, t) + R(s, t - 1)

_<IsSt 23\+IsS t l 31=IsS t l21.

The result easily extends to colourings with arbitrarily (but finitely)many colours: given k and s1, s2.... , Sk, if n is sufficiently large then everycolour of K" with k colours is such that for some i, 1 < i < k, it contains aKsi coloured with the i-th colour. (The minimal value of n for which thisholds is usually denoted by Rk(s, , ... , sk).) Indeed, if we know this for k - 1colours, then in a k-colouring of K" we replace the first two colours by a newcolour. If n is sufficiently large (depending on s1, s2, ... , sk) then either thereis a Ksi coloured with the i-th colour for some i, 3 < i < k, or else there is a

Page 116: Graph Theory-An Introductory Course-Bela Bollobas

§1 The Fundamental Ramsey Theorems 105

K'", m = R(s1, s2), coloured with the new colour, that is coloured with thefirst two (original) colours. In the first case we are home and in the second, fori = 1 or 2 we can find a Ks' in K' coloured with the i-th colour.

In fact, Theorem 1 also extends to hypergraphs, that is to colourings of theset X(') of all r-tuples of a finite set X with k colours. This is one of the theoremsproved by Ramsey.

Denote by R(')(s, t) the minimum of n for which every red-blue colouringof X(') yields a red s-set or a blue t-set, provided I X I = n. Of course, a setY c X is called red (blue) if every element of y(r) is red (blue). Note thatR(s, t) = R(2)(s, t). As in the case of Theorem 1, the next result not onlyguarantees that R(')(s, t) is finite for all values of the parameters (whichis not at all obvious a priori), but also gives an upper bound on R(r)(s, t). Theproof is an almost exact replica of the proof of Theorem 1. Note that if r >min{s, t} then R(')(s, t) = min{s, t} and if r = s < t then R(')(s, t) = t.

Theorem 2. Let 1 < r < min{s, t}. Then R(')(s, t) is finite and

R(')(s, t) < R(r-1)(R(')(s - 1, t), R(r)(s, t - 1)) + 1.

PROOF. Both assertions follow if we prove the inequality under the assump-tion that R(r-1)(u, v) is finite for all u, v, and R(')(s - 1, t), R(')(s, t - 1) arealso finite.

Let X be a set with R(r-1)(R(')(s - 1, t), R(')(s, t - 1)) + 1 elements.Given any red-blue colouring of X('), pick an x E X and define a red-bluecolouring of the (r - 1)-sets of Y = X - {x} by colouring a E Y(r-1) thecolour of {x} v a E X('). By the definition of the function R(r- 1)(U, v) we may

assume that Y has a red subset Z with R(')(s - 1, t) elements.Now let us look at the colouring of Z('). If it has a blue t-set, we are home,

since Z(') C X(') so a blue t-set of Z is also a blue t-set of X. On the otherhand if there is no blue t-set of Z then there is a red (s - 1)-set, and its unionwith {x} is then a red s-set of X. O

Very few of the non-trivial Ramsey numbers are known, even in the caser = 2. It is easily seen that R(3, 3) = 6 and with some work one can showthat R(3, 4) = 9, R(3, 5) = 14, R(3, 6) = 18, R(3, 7) = 23 and R(4, 4)= 18. Because of (1) any upper bound on an R(s, t) helps to give an upperbound on every R(s', t'), s' >- s, t' >- t. Lower bounds for R(s, t) are not easyto come by either. In Chapter VII we shall apply the method of randomgraphs to obtain lower bounds on the Ramsey numbers R(s, t).

As a consequence of Theorem 2 we see that every red-blue colouring ofthe r-tuples of the natural numbers contains arbitrarily large monochromaticsubsets; a subset is monochromatic if its r-tuples have the same colour.Ramsey proved that, in fact, we can find an infinite monochromatic set.

Theorem 3. Let c : A(') --+ {1, ... , k j be a k-colouring of the r-tuples (1 5 r < ao)of an infinite set A. Then A contains a monochromatic infinite set.

Page 117: Graph Theory-An Introductory Course-Bela Bollobas

106 VI Ramsey Theory

PROOF. We apply induction on r. Note that the result is trivial for r = 1 soassume that r > 1 and the theorem holds for smaller values of r.

Put A0 = A and pick an element x 1 e A0. As in the proof of Theorem 2,define a colouring c,: B1r -11 - { 1, ... , k} of the (r - 1)-tuples of B1 =Ao - {x1} by putting c1(T) = c(r v {x1}), T e B1'-11 By the inductionhypothesis B1 contains an infinite set Al all whose (r - 1)-tuples have thesame colour, say d1 (d1 e {1, ... , k}). Let now x2 e A1i B2 = Al - {x2}and define a k-colouring c2: B(2'-1) -+ { 1, ... , k} by putting c2(T) =c(T v {x2}), T E BZ -11. Then B2 has an infinite set A2 all of whose (r - 1)-tuples have the same colour, say d2. Continuing in this way we obtain aninfinite sequence of elements: x1, x2, ... , an infinite sequence of colours:d1, d2, ... , and an infinite nested sequence of sets: A0 Al D A2such that xi a A i _ 1 and all r-tuples whose only element outside A. (u = 0, 1, )is xi have the same colour di. The infinite sequence must take at least oneof the k values 1, 2, .. ., k infinitely often, say ni -+ oo and d,,, = 1 for every i.Then by the construction each r-tuple of the infinite set {x,,,, x112, ...} hascolour 1.

In some cases it is more convenient to apply the following version ofTheorem 3. (R is the set of natural numbers.)

Theorem 3'. For each r e N, colour the set f J of r-tuples of N with k, colourswhere k, e N. Then there is an infinite set M c t\1 such that for every r anytwo r-tuples of M have the same colour, provided their minimal elements arenot less than the rth element of M.

PROOF. Put Mo = t\J. Having chosen infinite sets Mo c - - - M,_ 1, letM, be an infinite subset of M,_ 1 such that all the r-tuples of Mr have the samecolour. This way we obtain an infinite nested sequence of infinite sets:Mo M1 .PickaleM1,a2E:M2 - {1,...,a1},a3eM3 - {1,...,a2},etc. Clearly M = {a1, a2,...) has the required properties.

Either Theorem 2 and the colour-grouping argument described afterTheorem 1, or Theorem 3 and a compactness argument imply the following.Given r and s1, s2, ... , Sk, then for large enough I X I every colouring of X1'1with k colours is such that for some i, 1 < i < k, there is a set S, c X,SiI I = si, all of whose r-sets have colour i. The smallest value of I X I for

which this is true is denoted by Rk'(s1, s2, ... , sk); thus R1''(s, t) = R2(')(s, t)and Rk(s1, s2i ... , SO = S2, ... , SO. The upper bound forRk')(s1, s2, ..., SO implied by Theorem 2 is not very good. Imitating theproof of Theorem 2 one arrives at .a better upper bound (cf. Exercise 8):

Rk (S SO Rka- 1>(Rk c.11,51 - 1, S2, Si), . . . ,1, ... , ... ,

Rk'1(s1, ... , Sk- 1, Sk - 1)) + 1.

Page 118: Graph Theory-An Introductory Course-Bela Bollobas

§2 Monochromatic Subgraphs

§2 Monochromatic Subgraphs

107

Let H1 and H2 be arbitrary graphs. Given n, is it true that every red-bluecolouring of the edges of K" contains a red H1 or a blue H2? Since H. is asubgraph of Kst, where s; = IH;I, the answer is clearly "yes" if n > R(sl, s2).Denote by r(H1, H2) the smallest value of n that will ensure an affirmativeanswer. Note that this notation is similar to the one introduced earlier:R(sl, s2) = r(KSt, KS2). Clearly r(H1i H2) - I is the maximal value of n forwhich there is a graph G of order n such that H1 ¢ G and H2 ¢ G.

The numbers r(H1i H2), sometimes called generalized Ramsey numbers,have been investigated fairly extensively in recent years. We shall determiner(H1, H2) for some simple pairs (H1, H2).

Theorem 4. Let T be a tree of order t. Then r(KS, T) = (s - 1)(t - 1) + 1.

PROOF. The graph (s - 1)K'-1 does not contain T, its complement,K,-,(t - 1), does not contain KS, so r(KS, T) > (s - 1)(t - 1) + 1.

Let now G be a graph of order n = (s - 1)(t - 1) + 1 whose complementdoes not contain KS. Then X(G) >- In/(s - 1)] = t so it contains a critical sub-graph H of minimal degree at least t - I (see Theorem I of Chapter V). Itis easily seen that H contains (a copy on T. Indeed, we may assume thatTl c H, where T1 = T - x and x is an endvertex of T, adjacent to a vertexy of T1 (and of H). Since y has at least t - 1 neighbours in H, at least one of itsneighbours, say z, does not belong to T1. Then the subgraph of H spannedby T1 and z clearly contains (a copy on T.

As we know very little about r(KS, Kt), it is only to be expected thatr(G1i G2) has been calculated mostly in the cases when both G1 and G2 aresparse (have few edges compared to their orders), e.g., when G1 = sH1and G2 = tH2. The following simple lemma shows that for fixed H1 andH2 the function r(sH1, tH2) is at most s I H1 I + t I H2 I + c, where c dependsonly on H1 and H2, and not on s and t,

Lemma 5. r(G, H1 u H2) < max{r(G, H1) + I H2I , r(G, H2)). In particular,r(sH1, H2) <_ r(H1, H2) + (s - 1)IH1 I-

PROOF. Let n be equal to the right hand side and suppose there is a red-blue colouring of K" without a red G. Then n >- r(G, H2) implies that thereis a blue H2. Remove it. Since n - I H21 > r(G, H1), the remainder containsa blue H1. Hence K" contains a blue H1 v H2.

Theorem 6. Ifs >- t >- 1 then

r(sK2, tK2) = 2s + t - 1.

Page 119: Graph Theory-An Introductory Course-Bela Bollobas

108 VI Ramsey Theory

PROOF. The graph G = K2s-' a E--' does not contain s independent edgesand G = E2s-' + K`-' does not contain t independent edges. Hencer(sK2, tK2) > 2s + t - 1.

Trivially r(sK2, K2) = 2s. We shall show that

r((s + 1)K2, (t + 1)K2) < r(sK2, tK2) + 3.

This is sufficient to complete the proof since then

r((s + 1)K2, (t + 1)K2) < r(sK2, tK2) + 3 < r((s - 1)K2, (t - 1)K2) + 6<r((s-t+1)K2,K2)+3t=2(s-t+1)+3t=2s+t+2.

Let G be a graph of order n = r(sK2, tK2) + 3 > 2s + t + 2. If G = K" thenG (s + 1)K2 and if G = E" then G (t + 1)K2. Otherwise there arethree vertices, say x, y and z such that xy e G, xz 0 G. Now either G - {x, y, z}contains s independent edges and then xy can be added to them to forms + 1 independent edges of G or else G - {x, y, z} contains t independentedges and then xz can be added to them to form t + 1 independent edgesof G.

Theorem 7. Ifs >- t > 1 and s >_: 2 then r(sK', tK3) = 3s + 2t.

PROOF. Let G=K"-' u (K' +E 21- '). Then G does not contain s in-dependent triangles and G = E3c-' + (K' u K2t-') does not contain tindependent triangles. Hence r(sK3, tK3) is at least as large as claimed.

It is easily shown that r(2K', K3) = 8 and r(2K3, 2K3) = 10 (Exercise12). Hence repeated applications of Lemma 5 give

r(sK3, K3) < 3s + 2,

and to complete the proof it suffices to show that for s >- 1, t >- 1 we have

r((s + 1)K3, (t + 1)K 3) < r(sK3, tK3) + 5.

To see this let n = r(sK3, tK3) + 5 and consider a red-blue colouring ofK". Select a monochromatic (say red) triangle K, in K". If K" - K, containsa red sK3 then we are home. Otherwise K" - K, contains a blue triangle Kb(it even contains a blue tK3). We may assume that at least five of the nineK, - Kb edges are red. At least two of these edges are incident with a vertexof Kb, and, together with an edge of K, they form a red triangle K* meetingKb. Since K" - K* - Kb has r(sK3, tK3) vertices, it contains either a redsK3 or a blue W. These are disjoint from both K* and Kb, so K" containseither a red (s + 1)K3 or a blue (t + 1)K3.

By elaborating the idea used in the proofs of the previous two theoremswe can obtain good bounds on r(sK°, tKQ), provided max(s, t) is large

Page 120: Graph Theory-An Introductory Course-Bela Bollobas

§2 Monochromatic Subgraphs

compared to max(p, q). Let p, q > 2 be fixed and choose to such that

to minfp, q} > 2r(KP, Ku).

Put C = r(to KP, to Kq).

109

Theorem 8. Ifs > t >- I then

ps + (q - 1)t - 1 < r(sKP, tKq) < ps + (q - 1)t + C.

PROOF. The graph KPs- 1 u E(q" 1)`-' shows the first inequality. As in theproofs of the previous theorems, we fix s - t and apply induction on t. ByLemma 5 we have

r(sKP, tKq) < (s - t)p + r(tKP, tKq) < ps + C,

provided t < to. Assume now that t to, and the second inequality holdsfor s, t.

Let G be a graph of order n = p(s + 1) + (q - 1)(t + 1) + C suchthat G ;6 (s + 1)KP and G (t + 1)Kq. Suppose no KP of G and K9 of Ghave a vertex in common. Denote by Vp the set of vertices of G that are in KPsubgraphs and put V. = V - Vp, np = I V,, I, nq = I I. No vertex x e Vq isjoined to at least r(Kp-1, Kq) vertices of VP since otherwise either there isa KP of G containing x or else there is a K9 of G containing vertices of VP.Similarly every vertex y e VP is joined to all but at most r(KP, Kq- 1) - 1vertices of Vq. Hence

ngr(KP-1, Kq) + npr(KP,K" 1) > npnq.

However, this is impossible, since np >- sp, nq tq so np 2r(Kp-1, Kq)and nq >- 2r(KP, Kq-1). Therefore we can find a KP of G and a Kq of G witha vertex in common.

When we omit the p + q - 1 vertices of these subgraphs, we find that theremainder H is such that H :;6 sKP and H ;6 tKq. However, I H I = ps+ (q - 1)t + C, so this is impossible.

One is inclined to imagine that the various Ramsey theorems hold forfinite graphs because the graph whose edges we colour is K" and not somesparse graph with few edges.

Let us consider now another generalization of the original Ramseyproblem for finite graphs. Let H, G1, G2, ... , Gk be graphs. Denote by

the following statement: for every colouring of the edges of H with coloursC I , c2, ... , Ck there is an index i such that H contains a subgraph isomorphicto G. whose edges are of colour c;. If G. = G for each i then instead ofH - (G1, G2, ..., Gk) we usually write H - (G)k. Note that

r(G1, G2) = min{n: K" -+ (G1, G2)} = max{n: Kn-1 - (G1, G2)}.

Page 121: Graph Theory-An Introductory Course-Bela Bollobas

110

Figure VI.1. The graph C3 + C5.

VI Ramsey Theory

Clearly it is harder to find a monochromatic subgraph in a sparse graph thanin a complete graph and for given G, and G2 it may not be easy to find asparse graph H (sparse in some given sense) such that H - (G1, G2). Thusone may not find immediately a graph H without a K6 for which H -+(K3, K3). (Such a graph is shown in Figure VI.1). Going even further, onemay ask the following difficult question: is there a graph H with cl(H) = 3(so without a K°) such that H -+ (K3, K3)? Note that Theorem 1 does notguarantee the existence of such an H. To conclude the section we only statea deep theorem of Negetfil and Rod I showing that the answers to the questionsof this type are in the affirmative.

Theorem 9. Given graphs G1, G,, ..., Gk there is a graph H such that cl(H)= max, stsk cl(G;) and H -' (G,, G2, ... , Gk). D

§3 Ramsey Theorems in Algebra and Geometry

Given an algebraic or geometric object and a collection 1 of finite subsetsof the elements, is it true that whenever we colour the elements with kcolours (i.e., partition them into k classes), at least one of the colour classescontains at least one member of P" In this section we discuss some questionsof this type for Euclidean spaces, finite vector spaces, various semigroupsand objects belonging to rather general categories. We prove only one ortwo simple results, since the prool's of the deep results are well beyond thescope of these notes, though the statements themselves are very easily under-stood.

Let 9 be a collection of finite subsets of a set M. In accordance with thenotation used in the previous section, M -' (9)k means that in every k-colouring of M there is a monochromatic set PcJ, i.e., if M = M, u u Mkthen P c M; for some i c [1, k] __ { 1, ... , k} and PE .3P. When discussingwhether M -' (9)k holds or not, the following compactness theorem enablesus to replace M by a finite subset of it.

Theorem 10. M __+ (1)k ii f there is a.finite set X c M such that X -+ (9a)k.

Page 122: Graph Theory-An Introductory Course-Bela Bollobas

§3 Ramsey Theorems in Algebra and Geometry III

PROOF. If M ,4 (Y),, then clearly X ¢ (Y)k for every finite set X.A k-colouring of M is a point of the space [1, k]'; for c c- [1, k]m and

x e M the projection of c into the x component, nz(c), is exactly c(x) e [1, k]= {1, 2, ... , k}, the colour assigned by c to x. As almost always, we give[1, k] the discrete topology and [1, k]Mthe product topology. By the familiarTychonov theorem from general topology, the space [1, k]"' is compactsince it is a product of compact spaces.

Given a finite set X c M, let N(X) be the set of colourings in which Xdoes not contain a monochromatic set P e Y. If c 0 N(X) and d e [1, k]'agrees with c on X (that is d I X = c I X) then d 0 N(X). Therefore[1, k]m - N(X) is open and so N(X) is closed. (In fact, N(X) is triviallyclopen, i.e. both open and closed.)

Let us turn now to the proof of the second implication. Assume thatX 74 (Y),k for every finite set X c M. This means exactly that N(X) 0for every finite set X. Since N(X) n N(Y) N(X u Y), the system{N(X): X c M is finite} of closed sets has the finite intersection property.The compactness of [1, k]' implies that nX N(X) : 0. Every c E nX N(X)is a k-colouring of M without a monochromatic set P e Y.

Let L be a finite set of points in 68', the m-dimensional Euclidean space.As another variant of the notation used so far, 68" -+ (L)k means that inevery k-colouring of 68" there is a monochromatic L' congruent to L. We saythat L is Ramsey if for every k there is an n such that R" - (L)k.

Theorem 11. Let P be a pair of points at distance 1 apart. Then

682 - (P)3 but 682 f (P),.

PROOF. Figure VI.2 shows the first assertion. For suppose that in a red-blue-yellow colouring of the seven points there is no monochromatic adjacent

Figure VI.2. Adjacent points are at distance 1.

pair. We may assume that x is red. Then yt, zt are blue and yellow so xt isred. Similarly x2 is red, but xt and x2 are adjacent.

Figure VI.3 shows that 682 -+ (P), is false.

Page 123: Graph Theory-An Introductory Course-Bela Bollobas

112 VI Ramsey Theory

Figure VI.3. The hexagons have side a, 1/,/7 < a < 1/2.

It is interesting that we do not know the maximal value of k for which682 -+ (P)k.

Theorem 12. Let Q2 be the (vertex :set of a) unit square. Then 116 -i (Q2)2.

PROOF. Consider a red-blue colouring of R6. Then, in particular, we have ared-blue colouring of the following fifteen points of 686:x;; = (x;,, ... , x6),1 < i < j < 6, x = 0 unless k = i or j and x; = x; = 11,T2. Consider aK6 with vertex set {v,, ... , v6}, and colour edge v; vj (i < j) with the colourof xs;. Since r(C4, C4) = 6 (the easy proof of this is left to the reader asExercise 13), by symmetry we may assume that the edges vl v2, v2 v3, v3 v4are all red. It is easily checked that the points x12, x23, x34 and x14 form aunit square and this square is, of course, red.

Given L1 (zz R" and L2 c 68m', we define L1 x L2 c R" 112 by L1 xL2 = {(xl, ... , XM I

(xl, ... , xm,) E Ll, (xmi+l, ... , XM I E L 2 1 -

T h e o r e m 13. If L1 and L2 are Ramsey then so is L1 x L2.

PROOF. Given k, there is an m such that Rm -+ (L1)k. Hence by the com-pactness theorem there is a finite subset X c 68m such that X -+ (L1)k. PutI = 01. Since L2 is Ramsey, there is an n such that 68" - (L2),. Every k-colouring of 6Bm+" = R" x R" restricts to a k-colouring c: X x 68" -,[1, k] = {1, 2,... , k}. This gives an 1 = 01-colouring of 68" with colours[1, k]x: simply colour yo a 68" with the function f e [1, k]x that tells us howthe points of X x {yo} are coloured: f(yo) = c(x, yo). In this 1-colouringthere is a monochromatic L2 c: I11", i.e., an L2 c 68" such that for x E X,and yl, y2 e L2 the points (x, yl), (x, y2) have the same colour (in the originalk-colouring). Assigning this common colour to x, we obtain a k-colouringof X. It has a monochromatic L1 c: X, providing us with a monochromaticL1 xL2.

Page 124: Graph Theory-An Introductory Course-Bela Bollobas

§3 Ramsey Theorems in Algebra and Geometry 113

A brick in R" is a set congruent to

B = {(Eta1, 1;2a2, ... , is"a"): ei = 0 or 1},

where ai > 0. A unit simplex in W' shows that 1k ({O, 11). so every 2-pointset is Ramsey. Hence Theorem 13 has the following consequence.

Theorem 14. Every subset of a brick is Ramsey.

Call a set L c R' spherical if it is imbeddable in some sphere (of arbitrarydimension and radius). It is somewhat more complicated to show that if aset is not spherical then it is not Ramsey (Exercise 20). It is rather curiousthat though there are many sets (and many very simple sets, e.g., an obtusetriangle) that are spherical but not subsets of bricks, it is not known aboutany of them whether they are Ramsey or not.

The following very significant extension of Ramsey's theorem was provedby Hales and Jewett.

Theorem 15. Let S be a commutative infinite semi group. Let L be a finite subsetof S and let Y = {a + nL: a e S, n e N}, where nL = {nx: x e L}. Then

S -* (9)k for every k.

The proof is too difficult to present in these notes. However, we state thistheorem partly because it is the cornerstone of very general results provedby Graham, Leeb and Rothschild, asserting that certain categories are"Ramsey", and partly because we shall prove a special case of this theorem.The next theorem was conjectured by Rota; it is one of the most strikingconsequences of the results about Ramsey categories.

Theorem 16. Given a finite field F and natural numbers n and k, there is anatural number N such that if F", the N-dimensional vector space over F, iscoloured with k colours then F" contains a monochromatic n-dimensionalaffine subspace.

Furthermore, given a finite field F and natural numbers n, m and k, there isan M such that if the set of k-dimensional subspaces of Fm is coloured with kcolours, then there is an n-dimensional subspace in which all k-dimensionalsubspaces have the same colour.

The classical theorem of van der Waerden (Theorem 17 below) is a specialcase of Theorem 15. Here we present it with a proof due to Graham andRothschild, since the proof gives back the flavour of the arguments used inthe deepest results of the theory. As customary, we write N for the set ofnatural numbers and [m, n] for {m, m + 1, ... , n}.

Page 125: Graph Theory-An Introductory Course-Bela Bollobas

114 VI Ramsey Theory

Theorem 17. Given p, k e N, there exists an integer W(p, k) such that in anyk-colouring of [1, W(p, k)] there is a monochromatic arithmetic progressionconsisting of p terms.

PROOF. Let I and m be natural numbers. Two m-tuples (x I , ... , xm),

(Y1, , ym) e [0, 1](') are said to be I-equivalent if they agree up to and in-cluding the last occurrences of 1. with the convention that any two sequencesnot containing 1 are equivalent. We write S(l, m) for the following state-ment:

Given k e N, there exists W(1, m, k) such that for every function

c:[1, W(!, m, k)] -+ [1, k]

there exist a, d 1, ...., dm e N such that

a+ l Y di _ W(l, m, k) and c (a + Y_xidi l

is constant on each l-equivalence class of [0, l](m'.

1

Note that van der Waerden's theorem is exactly the assertion S(p, 1),but the theorem holding for every p is equivalent to the truth of S(l, m) forevery I and m. We shall prove S(1, m) by induction, starting with the trivialassertion S(1, 1) and proving two different induction steps.

(i) If S(l, m) holds for some m ? 1 then so does S(l, m + 1). To see this,fix kand put W = V'(l,m,k), W' = W(l, 1,kw)andW, = [(j - 1)W + 1,/W],1 < j < W'. Let c: [1, WW'] -+ [1, k] be any k-colouring. This induces a kw-colouring c' of [1, W] that colours j c- [1, W] with the function f E [1, k]I1, wi

describing the colouring of Wi: f(w) = c((j - 1)W + w), 1 < w < W (cf.the proof of Theorem 3). By the choice of W', there exist a' and d', a' + Id' <W' such that c'(a') = c'(a' + d') _= c'(a' + (I - 1)d'). Let us apply S(l, m) tothe interval [(a' - 1)W + 1, a'W], k-coloured with c. Then there exista,dI-,...,dmE N such that

(a' - 1)W+ I a<a+l>di<a'WI

and c(a + Yi xidi) is constant on I-equivalence classes. Put dm+I = d'W.Then a, d1, ... , dm+I are such that

T + I

a+- I di<WW'

and

m+1

c a + xidi

is constant on each I-equivalence class of [0, 1](m+ 1). (See Figure VI.4.)

Page 126: Graph Theory-An Introductory Course-Bela Bollobas

§4 Subsequences

a a+2: x;d, a+d'W a+2d'W

W, W; Ww.

115

1 a' a'+d' a'+2d' W'

Figure VIA Illustration to part (i). The colour of j e [1, W] tells us how W; is coloured.

(ii) If S(l. m) holds for every m then S(l + 1, 1) also holds. This is an almostimmediate consequence of the pigeonhole principle. For let c : [ 1, W (l, k, k)][1, k] be given. Then there exist a, d,, ... , dk E N such that a + l Yi d, <W(l, k, k) and c(a + Yi xid;) is constant on /-equivalence classes. Thecolours c(a + Yi ld), s = 0, 1, ... , k cannot be all different so there exists, t, 0 < s < t < k, such that

Then

c(a+Y_ Id1) =c \\la+Y_ ld;1.

\c a

+Es

1 / +1

is constant for j e [0,1].Since S(1, 1) is trivial, by induction S(l, m) is true for every 1 and m.

Van der Waerden's theorem has many interesting and deep extensions.Among others, Rado determined when a system

n

2a;jxj=0, i= 1,.. m,j=1

of linear equations with integer coefficients has a monochromatic solutionin every colouring of N with finitely many colours. As a particular case ofRado's theorem and the compactness theorem one obtains the followingresult. Given integers k and n, there exists N = N(k, n) such that if [1, N]is k-coloured then there is a set A of n natural numbers such that >a E A a < Nand all the sums El e b, 0 B c A have the same color. At the end of thenext section we discuss a beautiful extension of this to infinite sets.

§4 Subsequences

Let (f,,) be a sequence of functions on a space T. Then we can find an in-finite subsequence such that one of the following two alternatives holds:

a. if is any subsequence of (_f;,.) then sup I N f I >_ 1/N for every N >_ 1,b. if (f,;) is any subsequence of (f,.) then sup I i f,; I < 1/N for some N >_ 1.

Page 127: Graph Theory-An Introductory Course-Bela Bollobas

116 V1 Ramsey Theory

This rather difficult assertion about sequences of functions is, in fact, animmediate consequence of a Ramsey type result about infinite sets.

As usual, 2' denotes the set of subsets of M, M(r) is the set of r-tuples ofM and M1°'1 denotes the set of countably infinite subsets of M. N is the setof natural numbers and 11, n] = {1, 2,... , n}. A family .F c 2101 is calledRamsev if there exists an M e N'' such that either Mew) c ,F or M(') c2"-F.

Of course, 210' can be identified with the cartesian product 11;E" T,,, whereT = {0, I). We give T the discrete topology and the product 2" the producttopology. In this topology 2" is a compact Hausdorff space. A weak formof a theorem due to Galvin and Prikry states that open subsets of 2" areRamsey. (This is easily seen to imply the above assertion about sequencesof functions.) To prove this result it is convenient to use the notation andterminology introduced by Galvin and Prikry. M, N, A and B are infinitesubsets of N. X, Y are finite subsets of N. X < a means that x < a for everyx e X ; X < M means that X < m for every m e M. An M-extension of X isa set of the form X u N where X < N and N c M. Let us fix now a family.F c 2". We say that M accepts X if every M-extension of X belongs to F;M rejects X if no N c M accepts X.

Lemma 18. If N rejects 0 then there exists an M e N(`°) that rejects everyX C M.

PROOF. Note first that there is an Mo such that every X c Mo is eitheraccepted or rejected by M,,. Indeed, put No = N, ao = 1. Suppose that wehave defined No N, . Nk and a; e N; - N;+,, 0 < i < k - 1. Pickak a Nk. If Nk - {ak} rejects {ao, ... , ak} then put Nk+1 = Nk - {ak},

otherwise let Nk+, be an infinite subset of Nk - {ak} that accepts { a0 , . .. , ak).Then Mo = {ao, a,, ...} will do.

By assumption Mo rejects 00. Suppose now that we have chosenbo, b,, ... , bk_, such that Mo rejects every X c {bo, b1, ... , bk_ 1}. ThenMo can not accept infinitely many sets of the form X u {c;}, j = 1, 2, ... ,since otherwise {c1, c2, ...} accepts X. Hence Mo rejects all but finitelymany sets of the form X u {c,'.. As there are only 2k choices for X, thereexists a bk such that Mo rejects every X c {bo, b1, ... , bk}. By constructionthe set M = {bo, b,, ...) has required property.

Theorem 19. Every open subset of 2" is Ramsey.

PROOF. Let ,F c 2" be open and assume that A(') ¢ F for every A e N('),i.e., N rejects 0. Let M be the set whose existence is guaranteed by Lemma18. If M(') ¢ 2" - .F, let A e n F. Since F is open, it contains aneighbourhood of A so there is an integer a e A such that if B n { 1, 2, ... , a)= A n { 1, 2, ... , a) then Be JF. But this implies that M accepts A n{1, 2, ... , a), contrary to the choice of M. Hence M('° c 2" - ,F provingthat ,F is Ramsey.

Page 128: Graph Theory-An Introductory Course-Bela Bollobas

§4 Subsequences 117

Denote by V") the family of finite subsets of X. A family .moo c Nt ')

is dense if .F, n M("0 0 for every M e N(') and it is thin if no memberof F0 is an initial segment of another member (that is if X < Y impliesX0FoorXu YOFe).

Corollary 20. Let .tea c t\!(`"') be dense. Then there is an M e N(c0) such thatevery A c M has an initial segment belonging to .moo.

PROOF. Let F = {F c R : F has an initial segment belonging to .F, 1. Then.F is open so there is an M e N(') such that either M('c F, in which casewe are home, or else M(`°) c 2" - F. The second alternative cannot holdsince it would imply M(`°') n .moo = 0.

This corollary enables us to deduce an extension of the original Ramseytheorem for infinite sets (Theorem 3).

Corollary 21. Let c NN"be a thin family. Then for any k-colouring ofF0 there is an infinite set A c IQJ such that all members of F o contained in Ahave the same colour.

PROOF. It suffices to prove the result for k = 2. Consider a red and bluecolouring of ° o : yo = Fred U Fblue If Fred is dense then let M be theset guaranteed by Corollary 20. For every F e ,moo n 2M there is an infiniteset N c M with initial segment F. Since .F0 is thin, F is the unique initialsegment of N that belongs to F0. Hence F e so every member of F ocontained in M is red.

On the other hand if 3F fed is not dense then 2M n .Fred = 0 for someinfinite set M. Hence 2M n .moo c Fblue

Let us now turn to the result concerning monochromatic sums we pro-mised at the end of the previous section. This beautiful result, conjecturedby Graham and Rothschild and first proved by Hindman, is not very nearto the results given in this section, but the striking proof given by Glazerillustrates the rich methods that can be applied in infinite Ramsey theory.

Theorem 22. For any k-colouring of 101 there is an infinite set Act kJ suchthat all sums Y-xex x, 0 # X c A, have the same colour.

We shall not give a detailed proof but only sketch one for those who are(at least rather vaguely) familiar with ultrafilters on N and know that theset $1 of all ultrafilters is a compact topological space (the Stone-techcompactification of IOJ with, of course, the discrete topology). The proofwhich is due to Glazer, is at least as beautiful as the theorem and it is con-siderably more surprising.

Page 129: Graph Theory-An Introductory Course-Bela Bollobas

118 VI Ramsey Theory

Let us recall that a filter F on fJ is a collection of subsets of N such that(i) if A, Be .F, then A n B E. , (ii) if A E ,F and A c B then B e .f and(iii) .F 96 2'y, that is 0 0 F. Zorn's lemma implies that every filter is con-tained in a maximal filter, called ultrafilter. IM is an ultrafilter then for everyA c N either A e V or else N - A ERI. This implies that every ultrafilterql defines a finitely additive 0-1 measure m on 210':

m(A)f if A E91,

0 if N - A EV.

Conversely, clearly every finitely additive 0-1 measure on 2' defines anultrafilter. If there is a finite set of measure 1 then one of the elements, say a,of that set has also measure 1, and so V = {A c N : a E Al. These ultra-filters are called principal. Not every ultrafilter is principal: the ultrafilterscontaining the filter .F = {A c N: N - A is finite} are not principal.

That ultrafilters can be useful in proofs of Ramsey theorems can be seenfrom the following very simple proof of the case r = 2 of Theorem 3. Let*be a non-principal ultrafilter. Let NI21 = P1 U P2 u u Pk. For n e N letA0) = {m: (n, m) e P,}. Then exactly one of the sets AI"), AZ"), ... , Ak") be-longs to W, say the set A(%). Now with B, = {n: c(n) = i} we have N _B1 u u Bk so again exactly one of these sets, say Bj, belongs to'l. Finally,pick a1 e B;, a2 E B; n Ar'), a3 E B; n A("') n A;"21, etc. With A = {a1, a2, ...}we have A(2) c P;.

Let us turn at last to the sketch of Glazer's proof of Theorem 22. Let usdefine an addition on fiN by

V +*-_ {A N: {nENl:A-nEgl}EYom}

where 1&,*' EfNandA-n={a-n:aeA,a>n}.With some effort one can check that '?l + V is indeed an ultrafilter and

that with this addition fife becomes a semigroup. Furthermore, the semi-group operation is right-continuous, i.e. for a fixed Y E fiN the map fNl -+fN, given by ctl - Y + Rl, is continuous. By applying a short and standardtopological argument we see that the properties above imply that /JN hasan idempotent element, that is an element 9 with Y + Y = Y. This o isnonprincipal since if {p} E .9 then {2p} E Y + Y so {p} 0.3 + Y.

Let now A E Y. Then by the definition of the addition

A*={nEN:A-nEP}EIThus if a E A n A* then B = (A - a) n (A - {a}) E .30. (We could replaceA by A - {a} since .9 is not principal) Hence for every A E .0 there exista e A and B c A - {a} such that B E :1/ and a + B c A.

Of course, this ultrafilter 9 has nothing to do with any colouring of N.However, just as any non-principal ultrafilter enabled us to find a mono-chromatic infinite set in a direct way, this idempotent .9 enables us to findan appropriate infinite set. Let N = C, u u Ck be the decomposition

Page 130: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 119

of N into colour classes. Exactly one of these colour classes, say C;, belongsto i. Put A 1 = C; . Select a, a A, and A2 e .°l, A2 c A, - {a1 } such thata, + A2 c A,. Then select a2 E A2 and A3 E 1, A3 c A2 - {a2} such thata2 + A3 c A2, etc. The set A = {a,, a2,...} clearly has the requiredproperty: every infinite sum E.E x x, X c A, has colour i.

Finally, it should be emphasised that the infinite Ramsey results presentedin this section form only the tip of an iceberg: the Ramsey theory of infinitesets, called partition calculus, is an essential and very cultivated branch ofset theory, and it has a huge literature.

The foundations of partition calculus were laid down over twenty yearsago by Erdos and Rado, who also introduced the arrow notation, usedthroughout the chapter, to formulate assertions about large cardinals.

EXERCISES

1. Show the equivalence of Theorem 3 and Rk''(s...... sk) < oc,(i) directly,(ii) using Theorem 10.

2. Prove that R(3, 4) = 9.

Figure VI.5. A graph showing R(3, 4) > 9.

3. Extending the construction in Figure VI.5, find for each t >_ 2 a t-regular graphwhich shows that R(3, t + 1) z 3t.

4. By considering the graph with vertex set 7L,7 (the integers modulo 17) in which iis joined to j if i - j = ± 1, ±2, +4 or ±8, show that R(4, 4) = 18.

5. Prove that R(3, 5) = 14.

6. Let e be an edge of V. Show that r(K° - e, K') = 11 (cf. Exercise 4).

7. By considering the 3-colouring of K16 with vertex set GF(16), the field of order 16,in which the colour of an edge ij depends on the coset of the group of the cubicresidues to which i - j belongs, show that R3(3, 3, 3) = 17. (You have to checkthat the graph is well defined.)

8. Establish the upper bound for Rk"(s,..... sk) given at the end of §1.

Page 131: Graph Theory-An Introductory Course-Bela Bollobas

120 VI Ramsey Theory

9." Given 2 < k < n, denote by ck(n) the maximal integer which is such that in everyk-colouring of the edges of K" we --an find a connected monochromatic subgraphof order ck(n). Show that c,(n) = n. (See Exercise 13 of Chapter I.)

10.- Prove that c"_,(n) = 2 if n >- 2 is even and c. (n) = 3 if n > 3 is odd. [Hint.Use Theorem 9 of Chapter I.]

11' Prove that

2+I if n=2 (mod4),

2Jotherwise

12. Check that r(2K3, K3) = 8 and r(2K3, 2K3) = 10.

13. Show that r(C°, C°) = 6.

14. By using the proof of Theorem 9 of Chapter IV prove that rk(C4, Ca, ... , C4) <k2+k+2.

15.' Using two-dimensional vector spaces over finite fields (cf. Theorem 10 of ChapterIV), show that

rk(C4, C`., ... , C4) = k2 + O(k).

16. By considering H, = P5 and H2 = K'"3, show that

r(H,, N2) >t min r(H;, Hr)=1.2

need not hold.

17! Let HP, Hq be graphs of order p and q, respectively and let cl(HP) = i, cl(Hq) = j.Then there is a constant C depending only on p and q such that

ps + qt - min{si, tj} - 2 <; r(sH, tHq) < ps + qt - min{si, tj} + C.

[Hint. Find a red Kj1p-'1, say R., a blue K'19-", say B, and a set N of ij other verticessuch that the RN edges are red and the BN edges are blue. Cf. the proof of Theorem8.]

18. Prove that a set ;xo, x ... , x (= R" is non-spherical if for some cir r

c;(xi - x0) = 0 and c;(Ix,12 - Ixo12) = b 54 0.1 ,

19. Let b, c1, ... , c, a R, b s 0. Show that there exists an integer k and some k-colouringof R' such that the equation

c{x;-xa)=b

has no solution with xo, x,,. ., x, all the same colour.

20. Prove that every Ramsey set is spherical. [Hint. Given a non-spherical set{xo, x1, ...., x,} c R", find (c) and b as in Exercise 18. Choose a k and a k-colouringof R' as in Exercise 19. Use this k-colouring to define a k-colouring of II8" bycolouring x e R" with the colour of I x 12.]

On) = -

Page 132: Graph Theory-An Introductory Course-Bela Bollobas

Notes 121

21. Let f (n) be the minimal integer N such that whenever X is a set of N pointsin a plane, no three of which are collinear, X contains n points forming a convexn-gon. Show that f (n) 5 n) for every n z 4. Can you give a better boundfor f(5)?

22. Let S be an infinite set of points in the plane. Show that there is an infinite set A c Ssuch that either A is contained in a line or no three points of A are collinear.

23. Show that Rk(3, 3, ... , 3) < [ek!] + 1.

24. Deduce from Exercise 23 the following theorem of Schur: If we partition thenatural numbers not exceeding ek! into k classes then the equation x + y = zis solvable in at least one of the classes.

25. Show that there is an infinite set of natural numbers such that the sum of any twoelements has an even number of prime factors.

26+ Show that there is a sequence n, < n2 < . . . of natural numbers such that ifr < i, < i2 < < i, then Z;_, n,; has an even number of prime factors if rhas an odd number of prime factors.

27. Define a graph with vertex set [1, N]t2j by joining a < b to b < c. Show that thisgraph does not contain a triangle and its chromatic number tends to infinitywith N. (See Exercise 11 of Chapter V.)

28. Let g, (x), g2(x), ..., g (x) be bounded real functions and let f (x) be anotherreal function. Let a and b be positive constants. Suppose maxi (gi(x) - g;(y)) > bwhenever f (x) - f (y) > e. Prove that f is bounded.

Notes

The fundamental Ramsey theorems are in F. P. Ramsey, On a problem offormal logic, Proc. Lond. Math. Soc. (2) 30 (1930) 264-286. Theorems 4,7and 8 are due to V. Chvatal, P. Erdos and J. Spencer and can be found inS. A. Burr, Generalized Ramsey theory for graphs-a survey, in Graphsand Combinatorics (R. Bari and F. Harary, eds.) Springer-Verlag, 1974,pp. 52-75. For some of the deep results of Ne§ettil and Riidl, one of which isTheorem 9, see J. Ne?±ettil and V. Rodl, The Ramsey property for graphswith forbidden subgraphs, J. Combinatorial Theory Ser. B, 20 (1976) 243-249, and Partitions of finite relational and set systems, J. CombinatorialTheory Ser. A 22 (1977) 289-312.

The geometric Ramsey results of §3 can be found in P. Erdos, R. L.Graham, B. L. Rothschild, J. Spencer and E. G. Straus, Euclidean Ramseytheorems, 1, J. Combinatorial Theory Ser. A, 14 (1973) 344-363. Theorem 15is in A. Hales and R. I. Jewett, Regularity and positional games, Trans.Amer. Math. Soc. 106 (1963) 222-229. Rota's conjecture is proved in R. L.Graham and B. L. Rothschild, Ramsey's theorem for n-parameter sets,Trans. Amer. Math. Soc. 159 (1971) 257-292. The results concerning Ramsey

Page 133: Graph Theory-An Introductory Course-Bela Bollobas

122 VI Ramsey Theory

categories are given in R. L. Graham, K. Leeb and B. L. Rothschild, Ramsey'stheorem for a class of categories, Adv. in Math. 8 (1972) 417-433 (Errata,ibid 10 (1973) 326-327). Van der Waerden's theorem is in B. L. van derWaerden, Beweis einer Baudetschen Vermutung, Nieuw Archief voorWiskunde 15 (1927) 212-216. The simple proof we give is from R. L. Grahamand B. L. Rothschild, A short proof of van der Waerden's theorem onarithmetic progressions, Proc. Amer. Math. Soc. 42 (1974) 385-386.

Rado's theorem, mentioned at the end of §3 is from R. Rado, Studien zurKombinatorik, Math. Zeitschrift 36 (1933) 424-480.

The first results of §4 are in F. Galvin and K. Prikry, Borel sets and Ram-sey's theorem, J. Symbolic Logic 38 (1973) 193-198; Glazer's proof ofHindman' theorem is in W. W. Comfort, Ultrafilters: some old and somenew results, Bull. Amer. Math. Soc. 83 (1977) 417-455.

Exercise 5 is in R. E. Greenwood and A. M. Gleason, Combinatorialrelations and chromatic graphs, Canad, J. Math. 7 (1955) 1-7, and Exercise 9in a remark of F. Galvin and Schur's theorem (Exercise 24) is in I. Schur,Ober die Kongruenz x"' + y' =_ z"" (mod p), Jahr. Deutsch. Math. Ver. 25(1916) 114-116.

Page 134: Graph Theory-An Introductory Course-Bela Bollobas

CHAPTER VII

Random Graphs

"Give a `good' lower bound on the Ramsey number R(s, s), that is showthat there exists a graph of large order such that neither the graph nor itscomplement contains a KS". "Show that for every natural number k thereis a k-chromatic graph which does not contain a triangle". It does not takelong to realize that the constructions that seem to be demanded by questionslike these are not easily come by. Later we show that for every k there is agraph with the latter property, but even for k = 4 our graph has at least232 vertices. This book does not contain a picture of such a graph. Indeed,the aim of this chapter is to show that in order to solve these problems wecan use probabilistic methods to demonstrate the existence of the graphswithout actually constructing them. (It should be noted that we never usemore than the convenient language of probability theory, since all theprobabilistic arguments we need can be replaced by counting the number ofobjects in various sets.) This phenomenon is not confined to graph theoryand combinatorics; in the last decade or two probabilistic methods havebeen used with striking success in Fourier analysis, in the theory of functionspaces, in number theory, in the geometry of Banach spaces, etc. However,there is no area where probabilistic (or counting) methods are more naturalthan in combinatorics.

In most cases we use one of two closely related probabilistic models. Westart with a fixed set of n distinguished (labelled) vertices. Then either wechoose every edge with some probability p, 0 < p < 1, independently ofthe choices of other edges or else we take all graphs of order n and size M,and consider them as points of a probability space, having equal probability.In the first case we shall write W(n, P(edge) = p) for the probability space,in the second case we write #(n, M). Of course in a more complicated model

123

Page 135: Graph Theory-An Introductory Course-Bela Bollobas

124 VII Random Graphs

we would choose the edges with given probabilities from several disjointsubsets of edges.

In the first two sections we shall show that a random graph can be avaluable weapon in attacking straightforward questions concerning graphs,including the ones mentioned above. However, random graphs are clearlyof interest in themselves. A random graph can be viewed as an organismthat develops by acquiring more and more edges as p or M increases. It isfascinating and rather surprising that a given property may appear rathersuddenly at a certain stage of the development. In the last two sections wepresent some examples of this phenomenon.

§1 Complete Subgraphs and Ramsey Numbers-theUse of the Expectation

Let n, N and M be natural numbers, 0 < M < N = (z). We shall considerthe set S2 = 5r(n, M) of all graphs of size M with vertex set V = {1, 2, ... , n}.Clearly S2 has (M) elements; in particular, if M = 0 then S2 = {E"} and ifM = N = (z) then 1 = {K"}. (We use M for the number of edges in orderto emphasise that M tends to be of larger order than n. We cannot use esince the base of the natural logarithm occurs in many of our formulae.)For the sake of convenience we view i2 as a probability space, in which thepoints (i.e., graphs) have equal probability, 1/I S2 I . Then all graphic in-variants occur as random variables on 0, so we may talk of their expectedvalue, standard deviation, etc. In our calculations we shall often make useof various estimates of binomial coefficients. For convenience we list themnow. First recall Stirling's formula

=(ne)

where a depends on n but is between 0 and 1. The following estimates, inwhich 0 < x < x + y S a and x < b < a, are obtained by expanding thebinomial coefficient and occasionally applying Stirling's formula (1).

2_ / (6)b s 2 (aa b)

a < ,a a b) 6/b\6 < (eba)

(a - x - yJa -xJX b-xy/\b/ '

(2)

(aa

bly(b e(3)

In inequalities (3) we assume also that xy = 0.

Page 136: Graph Theory-An Introductory Course-Bela Bollobas

§1 Complete Subgraphs and Ramsey Numbers-the Use of the Expectation 125

As our first illustration of the use of the language of probability in graphtheory we give a lower bound for the Ramsey number R(s, t). This lowerbound is based on the expected number of complete subgraphs of a givenorder. For G E Q denote by X, = X,(G) the number of K' subgraphs in G.Then X, is an integer valued random variable on the probability space 0.

Theorem 1. The expected number of K' subgraphs contained in a graph

G E S2 = #(n, M) is

E(Xs)- \s/

(N -- (i)) M) t

PROOF. As we noted earlier, I fII = (a). In order to calculate the expectednumber of K' subgraphs in G cS2, first we compute the number of graphsG E 0 that contain a fixed complete subgraph Ko of order s. If Ko c G then(2) of the edges of G are determined (i.e., are in KO) and the remaining M - (2)edges have to be chosen from a set of N - (2) = (s) - (2) edges. Thus

(N - (2)1lM - (2)

of the graphs G E Q contain Ko. As there are (s) choices for K0, the expectednumber of K' subgraphs contained in G E Q is as claimed.

Theorem 2. Ifs, t >- 3 then

In particular

R(s, t) > exp((s - 1)(t - 1)l 2(s + t) J?

R(s, s) > eltio>c= tl=is

PROOF. Note first that the graph G = (t - 1)K'- t does not contain a K'and its complement, K, - t(s - 1), does not contain a K`, so R(s, t)(s - 1) (t - 1) + 1. Therefore we may assume that

n = I exp((s

2(s )+t t) 1)}l > (s - 1)(t - 1) + 1,

so, in particular 8 < s < t.Let

M-is+tNJ, M'=N-M<s+tN+1,

let E, be the expected number of K' subgraphs in a graph of order n and sizeM, and, similarly, let E, be the expected number of K' subgraphs in the

Page 137: Graph Theory-An Introductory Course-Bela Bollobas

126 VII Random Graphs

complement of such graphs (i.e., in the graphs G(n, M')). Let us estimate theexpression for Es, given in Theorem 1, by using inequalities (2) and (3).We obtain

log ES 5 s(log n + 1 - log s) -

Similarly

t As - 1)s+t 2

< - s(s - 1) + I - s(logs - 1) < -3.2(s + t)

log E, < t(log n + I - log t) -s t(t - 1) + t(t - 1)

s+t 2 n(n-1)t(t - 1) t(t - 1)2(s+t)+1 t(logt-1)+n(n-1)<-3.

Hence ES + E, < 1 so there is a graph G E i2 which does not contain a KSand whose complement does not contain a K'. Hence R(s, t) >- n, as claimed.

Clearly the bound given in Theorem 2 is very bad for s = 3 and large t.In §2 we shall sketch a more refined version of the proof above, that gives amuch better bound for R(3, t). However, first we apply a straightforwardargument to obtain lower bounds in the problem of Zarankiewicz (cf.Theorems 8 and 10 in Chapter IV).

Theorem 3. Let 2 < s < n,, 2 < t < n2, a = (s - 1)/(st - 1) and /3 =(t - 1)/(st - 1). Then there is a bipartite graph G2(n1, n2) of size

\1 -Iii )n1 2 BJ

that does not contain a K(s, t) (with s vertices in the first class and t verticesin the second class).

PROOF. Let

n=n, + 112,V, _ 11, 2,... , n,),V2 = {n, + 1, n, + 2, ... , n1 + n2},E={ij:iEV,,jeV2},

M = Lni-°n'z--Oj.

We shall consider the probability space R = W(n, M; E) consisting of the(Ii) graphs with vertex set V = V, u V2 having exactly M edges from Eand none outside E. (Note that this is not the probability space considered

Page 138: Graph Theory-An Introductory Course-Bela Bollobas

§2 Girth and Chromatic Number-Altering a Random Graph 127

in the previous theorems.) The expected number of K(s, t) subgraphs con-tained in a graph G e S2 is

(nst /

(nt.,) EM

- st) (IMI) t,

since the first factor is the number of ways the first class of K(s, t) can bechosen, the second factor is the number of ways the second class can bechosen and since K(s, t) has st edges. By (3) we have

Y1r M1 1-a 1-BE,,< ntnz - -n1 nz

SW ntnz s!t!

Thus there is a graph Go ef2 that contains fewer than (1/s!t!)ni n2complete bipartite graphs K(s, t). Omit one edge from each K(s, t) in Go.The obtained graph G = G2(nt, n2) has at least

Ln1-an2-Pj - ni-an2-0 > 1 - - ni-an2-eS !t! I s t! I

edges and contains no K(s, t).

By similar methods one can construct a graph of order n and size

I (1 _ stI)nz-cs+r-zlan-112

I

that does not contain a K(s, t) (see Exercise 4).

11

It is a fact of life that the answers produced with the aid of random graphsusually differ from the best possible ones by a factor of 2. For example,random graphs give R(s, s) > 2s/z, whereas one would expect the actualvalue of R(s, s) to be around 2. Similarly it is thought that there are graphsof order n with c,n2-11/`l edges containing no K(t, t), where c, is a positiveconstant depending only on t; random graphs show that c,n2-(2/i) edges

are possible. However, in both these cases random graphs produce the bestknown lower bounds.

§2 Girth and Chromatic Number-Alteringa Random Graph

When looking for graphs with a certain property, we sometimes turn a setof graphs into a probability space and hope that most graphs in that spacehave the required property. If this does not happen, all is not lost, for we cantry to alter the graph slightly to make it have that property. We shall il-lustrate this point with a particularly simple example. Throughout the

Page 139: Graph Theory-An Introductory Course-Bela Bollobas

128 VII Random Graphs

section, we work with the probability space 0 = 1(n, M) of all graphs ofsize M with a fixed set of n distinguished vertices.

Theorem 4. Given natural numbers b > 3 and g >- 4 there is a graph of orderat most (26)0 whose minimum degree is at least S and whose girth is at least g.

PROOF. Let 0 = 1(n, M), where n = (26)9 and M = Sn. Denote by Z,(G)the number of cycles of length 1 in a graph G; thus Z, is a random variableon the space Q. What is E(Z,), the expected value of Z,? A cycle Co of lengthI determines I edges of a graph G containing it; the remaining M - I edgesof G have to be chosen from a set of (z) - 1 = N - I edges. Since there are(;) choices for the vertex set of Co and, given the vertex set, there are 1 - 1)!ways of choosing CO,

E(ZI) - i(l - 1)!nll N - lNll(f-l) M) 21 n'\N/

In the inequality above we applied (3) with a = N, b = M, x = I and y = 0.Summing over I we find that

g-1 g-1I j6nj'

E E(Z,) < n- < E (2S)' < n.1=3 1=3 21 N 1=3

Hence there is a graph G e G(n, Sn) that contains at most n - 1 cycles oflength at most g - 1. Therefore, by omitting one edge from each cycle oflength at most g - 1, we obtain a graph H of order n and size M' > (S - 1)n.We know from the simple Exercise 11 of Chapter IV that H contains a graphwith minimum degree at least S.

The next result solves the second problem posed in the introduction ofthis chapter.

Theorem 5. Given natural numbers k >- 4 and g 4, there is a k-chromaticgraph of girth g (and order k49 + g).

PROOF. Let 0 = W(n, M), where n = k49 and M = k3n. Then, as in the pre-vious proof, we have

9-1 g-1Y E(Z,) < Y (2k3)' < 2(2k3y-' < 1

n718.1=3 1=3

Put f = 2(2k3)a-' and denote by S21 the set of graphs in S2 that contain atmost 3f cycles of length less than g. Then trivially (or by Chebyshev'sinequality, see §4), we have

P(S21) ? 4.

Now we put p = (n/k) + 1 = k4g-' + 1 and estimate P(i22), the measureof the set f12 of graphs G that do not contain a p-set with at most 3f edges.

Page 140: Graph Theory-An Introductory Course-Bela Bollobas

§2 Girth and Chromatic Number-Altering a Random Graph 129

Clearly the graphs in f22 are not (k - 1)-colourable. Furthermore, even ifwe omit any 3f of their edges, we still cannot colour them with k - 1 colours.In order to estimate P(112) we calculate the expectation of IP' = IP `(G),the number of p-sets of vertices in which G has exactly l edges. There are (P)ways of choosing a set of p vertices; there are

\(l)/ways of choosing l edges joining vertices of such a set; and the remainingM - I edges can be chosen in

(M-(1))

ways. Thus

E(IP

r)

=

(n)

p\( l))

(N

M (l))(N

1

Applying (3) and summing over l we find that

r

E(1 1) <ro \ p

M(p) (2)1I

< kPeP\+ 31p6`texp{ -knl}.

The logarithm of the right hand side is at most

n+3+3n718+3n718logn-kn < - n.

Consequently3r

E(Ip') < e-" < 3r=o

and so

Therefore

Not n n2) >- 4.

Every graph H e Q n f12 can be altered in a very simple way to providea graph with the required properties. Indeed, since H e 01, it contains atmost 3f cycles of length less than g. Let F be obtained from H by omitting3f edges of H, at least one from each cycle of length less than g. Then F hasgirth g(F) > g. Since H e f'2, this graph F does not contain p = (n/k) + 1independent vertices and so X(F) >- k. Let G be the disjoint union of a cycleCO and a k-chromatic subgraph of F.

Page 141: Graph Theory-An Introductory Course-Bela Bollobas

130 VII Random Graphs

In §1 we promised to sketch a proof of a lower bound for the Ramseynumber R(3, t), given by Erdos. The sketch will be rather rough since thedetails of the proof are somewhat technical and cumbersome.

Theorem 6. There is a constant c > 0 such that

R(3, t) >- ct

log t)for every t >- 2.

It suffices to show that there is a (large) positive constant A such that forevery n there is a graph G" without triangles and without [An" log nJ in-dependent vertices. Indeed, it is easily checked that if there is such a constantthen c = 4A 2 will do in the theorem.

In order to show the existence of A, we choose a constant B > 0 and con-sider the probability space fl == 4%(n, M), where M = LB-112n312 J. GivenG E S2, let E* be a minimal set of edges whose removal destroys every trianglein G. If H = G - E* contains a set W of p = [Bn1"2 log nj independentvertices, then every edge of G[WJ has to be contained in a triangle of G whosethird vertex is outside W. One can show that if B and n are sufficiently large,say B > Bo and n >- no, then most graphs G e KI do not contain such a set W.Clearly A = Bo no has the required properties.

§3 Simple Properties of Almost All Graphs-theBasic Use of Probability

In this section we shall introduce and examine the model 9(n, P(edge) = p).The graphs in this model are such that the edges are chosen independentlyand with the same probability p, 0 < p < 1. Thus 9(n, P(edge) = p) con-sists of all graphs with a fixed set of n distinguishable vertices, and theprobability of a graph with m edges is p'"q"_m where q = 1 - p and, asbefore, N = (2). Thus q is the probability that a given pair of vertices arenot joined by an edge, and N is the maximum possible number of edges. Wesaw in the preceding section how useful it is to know that most graphs in amodel have a certain property. Now we shall go a step further, namely weshall discuss properties shared by almost all graphs. Given a property Q,we shall say that almost every (a.e.) graph (in a probability space Q,, con-sisting of graphs of order n) has property Q if P(G e Q,,: G has Q) - 1 asn - oo. In this section we shall always take Q. = W(n, P(edge) = p), where0 < p < 1 may depend on n.

Let us assume first that 0 < p 1 is fixed, that is p is independent of n.There are many simple properties holding for a.e. graph in 1(n, P(edge)

p). For instance, if H is an arbitrary fixed graph, then a.e. G e #(n, P(edge) = p)contains H as a spanned subgraph. Indeed, if H I = h, then the probability

Page 142: Graph Theory-An Introductory Course-Bela Bollobas

§3 Simple Properties of Almost all Graphs-the Basic Use of Probability 131

that the subgraph of G spanned by a given set of h vertices is isomorphicto H is positive, say r > 0. Since V(G) contains Ln/hJ disjoint subsets of hvertices each, the probability that no spanned subgraph of G is isomorphicto H is at most (1 - r)i"/kl, which tends to 0 as n - oo. The following resultis a strengthened version of this observation.

Theorem 7. Let 1 < h < k be fixed natural numbers and let 0 < p < 1 befixed also. Then in 9(n, P(edge) = p) a.e. graph G is such that for everysequence of k vertices x I, x2 , ... , xk there exists a vertex x such that xxi e E(G)ifI <i <hand xxi*E(G)ifIt < i <k.

PROOF. Let x1, x2 , ... , xk be an arbitrary sequence. The probability that avertex x e W = V(G) - {x1, ... , xk} has the required properties is pkgk-k.

Since for x, y e W, x # y, the edges xxi are chosen independently of theedges yxi, the probability that no suitable vertex x can be found for thisparticular sequence is (1 - pkgk-')nSince there are n(n - 1) ... (n - k + 1)choices for the sequence x1, x2, ... , xk, the probability that there is asequence x1, x2, ... , xk for which no suitable x can be found is at most

E = nk(1 - pkgk-k)n-k

Clearly E -+ 0 as n - oo.

By a result of Gaifman concerning first order sentences, Theorem 7 im-plies that for a fixed 0 < p < 1 every first order sentence about graphs iseither true for a.e. graph in 1r(n, P(edge) = p) or is false for a.e. graph. Thoughthis result looks rather sophisticated, it is in fact weaker than the shallowTheorem 7, for given any first order sentence, Theorem 7 enables us todeduce immediately whether the sentence holds for a.e. graph or it is falsefor a.e. graph. In particular, each of the following statements concerningthe model 1(n, P(edge) = p) for a fixed p, 0 < p < 1, is an immediate con-sequence of Theorem 7.

1. For a fixed integer k, a.e. graph is k-connected.2. A.e. graph has diameter 2.3. Given a graph H, a.e. graph G is such that whenever Fo c G is isomorphic

to a subgraph F of H, there exists an Ho isomorphic to H satisfyingF0 c H0 G.

Rather naturally, most statements we are interested in are not first ordersentences, since they concern large subsets of vertices. "For a given E > 0,a.e. graph has at least 3{p - E)n2 edges and at most -(p + E)n2 edges"."Almost no graph can be coloured with n 1/2 colours". "A.e. graph containsa complete graph of order (log n)/(log(1/p))". "Given E > 0, a.e. graph isJ(p - E)n-connected ". These statements are all true for a fixed p and areeasily proved (see Exercises 8-11); however, none of them is a first ordersentence.

Page 143: Graph Theory-An Introductory Course-Bela Bollobas

132 VII Random Graphs

Now we shall examine the model S2 = #(n, P(edge) = p) under the as-sumption that 0 < p < 1 depends on n but pn2 -+ oo and (1 - p)n2 -+ oo asn -+ oo. As before, we put N = (2) and for M = 0, 1, ... , N we denote byOm the set of graphs in M). Clearly 1 = UM=0 f2M, and the elementsof S2M have equal probability both in 1(n, M) and P(edge) = p).

We shall show that the models f2 = 4(n, P(edge) = p) and I#(n, M) arevery close to each other, provided M is about pN, the expected number ofedges of a graph in Q.

Writing P for the probability in f2, we see that

P(AM) = f M 1pMgN-M

Hence

P(f2M) M + 1 q4)

P(f2M+ 1) N - M p (

This shows that P(f2M)/P(fZM+,) increases with M, and P(f2M) is maximalfor some M satisfying pN - 1 < M < pN + 1. Furthermore, if 0 < E < 1and n is sufficiently large then, since pn2 -+ oo as n -+ oo,

P(?M)< 1 - E

ROM+1)

provided M < (1 - E)pN, and

P(QM+:.) < (1 + E)-1

NOM)

when M > (1 + E)pN. Putting N, = L(1 + E)pNJ and N_, = 1(1 - E)pNI,we see from these inequalities that a.e. graph G in f2 satisfies N_, < e(G) 5N,, that is

NE

l -+ 1PI U QMM=N

(5)

Another consequence of (4) is that there is an n > 0 (in fact, any 0 < n < iwould do) such that

lpnlPOM >1

M=0(6)

if n is sufficiently large. Now (5) and (6) imply that if 0* c 0 is such thatP(i2*) -+ 1 as n -+ oo, then for any E > 0 there are M1 and M2, such that(1 - E)pN < M1 < pN < M2 < (1 + E)pN and

I (IM, n (2*--+1 as n -+ oo U = 1 2) (7).,

I 34M, I

Page 144: Graph Theory-An Introductory Course-Bela Bollobas

§4 Almost Determined Variables-the Use of the Variance 133

We call a set f2* c Q convex if G c -!Q* whenever G, c G c G2 andG 1, G2 E 0*; a convex property of graphs is defined analogously. It is easilyseen that for a convex set 0* relation (7) implies that

I0M n Q*II0MI

-1 as n - oo, (7')

whenever M, < M < M2, in particular, if M = [pN j. Let us restate theassertions above as a theorem about the connection between the modelsW(n, P(edge) = p) and Wr(n, M).

Theorem 8. Let 0 < p = p(n) < 1 be such that pn2 - oo and (1 - p)n2 -+ coas n -+ oo, and let Q be a property of graphs.(i) Suppose e > 0 is fixed and, if (1 - e)pN < M < (1 + e)pN, then a.e.

graph in 4(n, M) has Q. Then a.e. graph in 4(n, P(edge) = p) has Q.(ii) If Q is a convex property and a.e. graph in 1(n, P(edge) = p) has Q, then

a.e. graph in 1(n, LpNj) has Q.

§4 Almost Determined Variables-the Use of theVariance

If X = X(G) is a non-negative variable on 0 = 9(n, M) or S2 =1(n, P(edge) = p), and the expectation of X is at most a, then

P(X < ta) >- t t I fort > 1.

Thus if the expectation of X is very small then X is small for most graphs.This simple fact was used over and over again in the first two sections.However, if we want to show that X is large or non-zero for almost everygraph in 0 then the expected value itself very rarely can help us, so we haveto try a slightly more sophisticated attack. We usually turn to the variancefor help. Recall that if p = E(X) is the expectation of X then

Var(X) = a2(X) = E((X - p)2) = E(X2) - p2

is the variance of X and a = o(X) > 0 is the standard deviation. Chebyshev'sinequality, which is immediate from first principles, states that if t > 0 then

0,2

P(IX-µI>t)<2.

Page 145: Graph Theory-An Introductory Course-Bela Bollobas

134

In particular, if 0 < t < it then

so

P(X =0)<P(IX -µ1>

Q2

P(X := 0) < 2.µ

(8)

In the examples we consider X = X (G) is usually the number of subgraphsof G contained in a family .F = {F1., F2, ...}. Here the family °.F may dependon n and every graph F e .F has the same labelled vertex set as G. Thenclearly

E(X2) = E P(G contains F' and F"), (9)(F'. F" )

where the summation is over all ordered pairs (F', F"), F', F" e IF.In this section we shall consider the space f = c#(n, P(edge) = p), where

0 < p < 1 is fixed; we know that this space is near to 9r(n, M), where M =[pn2/2J. As before, we write q = 1 - p for the probability that two givenvertices are not adjacent. Furthermore, we use Landau's notation 0(f (n))for a term that, when divided by f (n), remains bounded as n -+ oo. Similarly,off (n)) denotes a term that, when divided by f (n), tends to 0 as n -+ oo.Thus 0(1) is a bounded term and o(1) is a term tending to 0.

Our aim is to make use of the variance to show that certain graph in-variants are almost determined in our model 1(n, P(edge) = p). The firsttheorem concerns the maximal degree. In its proof we shall make use of aspecial case of the classical De Moivre-Laplace theorem concerning theapproximation of the binomial distribution by the normal distribution.Let 0 < c = c(n) = 0(1) and put d(c) = Lpn + c(pqn log n)"J. Supposex(c) = c(log n)"2 - oo. Then

k = d(c)

e =i2 du(n)pk

q"-k = (1 + o(1)) 1 f.(C)k 2n

(10)

Furthermore

I nlpkq"-k = (I + 0(1)) _ (Pqn) 1/2f

00

-e"2

duk=d(c) k it x(c)

_ (1 + o(1)) 41 (pqn log n)-l/2n-c2

= o(n-c2-i/2). (11)

VII Random Graphs

Page 146: Graph Theory-An Introductory Course-Bela Bollobas

§4 Almost Determined Variables-the Use of the Variance 135

Theorem 9. If 0 < p < 1 is fixed then in Q = 4(n, P(edge) = p) the maximaldegree of almost every graph is

pn + (2pqn log n)112 + o(n log n)'12.

PROOF. Let c > 0 and denote by X, = Xc(G) the number of vertices of degreeat least d(c) _ Lpn + c(pqn log n)'12J. Then, by (10),

µc=E(Xc)=nnE(n-Ipkq t-k

k = d(c) k

= (1 + o(1))(21tc2 log n)- 1/2n' -(c2/2)

and

E(X2) < E(XC)

n-' n-' n-2 n-2p+ n(n - 1) k,+k2-2

q2n-2-k,-k2

k, =(c) k2=d(c) k1 - 1 k2 - 1

=µC+(1 +o(1))p .

In the estimation of E(X2) the term

In - 2 In - 2 pkI+k2-2q 2n-2-k,-k2(k, - 1) k2 - 1)

is the probability that, given vertices a, b e G, a b, the vertex a is joinedto k, - 1 vertices in V(G) - {a, b} and b is joined to k2 - I vertices inV(G) - {a, b}.

Now if c = J2 - E, where 0 < E < 2, then j , > (1 + o(1))n`, so E(X2) _(I + o(1))µc and a2(XC) = o(p ). Therefore, by (8),

P(XC = 0) = 0(1).

Thus G almost surely has a vertex of degree at least

pn + (J2 - E)(pgn log n)"2

On the other hand, if c = J2 + E, e > 0, then uc = o(n-`) so

P(Xc >- 1) = o(n-`).

The result above has an interesting consequence.

Corollary 10. If 0 < p < 1 and c > J(3/2) then in #(n, P(edge) = p) almostno graph has two vertices of equal degree whose degrees are at least

d(c) = Ipn + c(pqn log n) 1/2j.

Page 147: Graph Theory-An Introductory Course-Bela Bollobas

136 V11 Random Graphs

PROOF. The probability of the existence of two such vertices is at most

2n2 n-1 2 k1 n-1-kkc)

{(nk - 1 P 9

and by (11) this is o(1).

Combining Theorem 9 with Corollary 10 we see that a.e. graph has aunique vertex with maximum degree.

In the next theorem we again consider the case when p varies with n.We say that a function t(n) is a threshold function for a property Q of graphsif

lim P"" (Q) =(0 if p/t(n)

n_ 1 if p/t(n)-+ 0,

-4 00.

Here Pn,,,(Q) denotes the probability that in W(n, P(edge) = p) a graph hasproperty Q. The existence of a threshold function means that in the evolu-tion of a random graph, i.e. in the process a graph acquires more and moreedges, the property emerges rather abruptly. In this section we prove a basicresult about threshold functions. The next section will be devoted to thebeautiful result that the property of being Hamiltonian has a sharp thresholdfunction.

Theorem 11. Let k >_ 2, k - 1 <_ 1 < (Z) and let F = G(k, !) be a graph withaverage degree (21/k) at least as large as that of any of its subgraphs. Thenn- k11 is a threshold function for F, that is if pnk1' - 0 then in #(n, P(edge) = p)almost no graph contains F and if pnk-' -4 oo then almost every graph contains F.

PROOF. Let p = yn-k1', 0 < y < nkl', and denote by X = X(G) the numberof copies of F contained in G e (n, P(edge) = p). Denote by kF the numberof graphs with a fixed set of k labelled vertices that are isomorphic to F.Clearly kF < 0. Then

µ = PY = E(X) = ()kFP'(1 - p)(: )-c < nk(YIn-k) = Y'>

so E(X) -+ 0 as y -+ 0, showing the first assertion.Now let us estimate the variance of X when y is large. Note that there is a

constant c, > 0 such that

µY > c1y' for every y. (12)

According to (9), we have to estimate the probability that G contains twofixed copies of F, say F and V. Put

As = Z P(G contains Fand F"),J

Page 148: Graph Theory-An Introductory Course-Bela Bollobas

§4 Almost Determined Variables-the Use of the Variance 137

where Y means that the summation is over all pairs (F', F") with s verticesin common. Clearly

Ao < X12.

Furthermore, in a set of s vertices F' has t < (l/k)s edges. Hence, countingfirst the choices for F' and then for F" with s >_ 1 common vertices with F,we find that for some constants cz and c3,

AS n - k I "Sslk(k)

sk -s)kPqE Cz nk-s(yn-k/1)!-t

r <ls/k

_< c2n-'y1

+ c3Y1-t

Here in the last step we separated the term with t = 0 from the rest. Con-sequently, making use of (12), we find that

E(X2) ko '<l+ctµz µz 4Y

for some constant c4. Therefore, by (8),

zP(X=0)<Uz<c4y 1

so y-+ co.

The most striking example of a graphic invariant being almost determinedin a random graph is that of the clique number, the maximal order of a com-plete subgraph. It turns out that for a fixed p, 0 < p < 1, the clique numberof almost every graph in 9(n, P(edge) = p) is one of three possible values. Infact, for most values of n (in a well defined sense) the clique number of almostevery graph is just a function of p and n. We shall confine ourselves to provinga simple result in this direction. As in Theorem 1, denote by X, = X,(G) thenumber of K' subgraphs in G e 1(n, P(edge) = p). Then

E(X) = (n )plzlr

since we have (;) choices for the vertex set of a K' and, having chosen thevertex set, we have no choice for the (z) edges. Let d = d(n, p) be the greatestnatural number for which

(;)p 1.

Page 149: Graph Theory-An Introductory Course-Bela Bollobas

138 VII Random Graphs

For simplicity we put b = 1/p. It is easily checked with the aid of Stirling'sformula that

bait < n

and

_ n ("2 2) n d n c°#') n d

d + 2p p(d+1)p Sdp--* 0,

(13)

Theorem 12. Let 0 < p < 1 be fixed. Then the clique number of almost everygraph G e #(n, P(edge) = p) is d - 1, d or d + 1.

PROOF. The assertion is equivalent to the following:

P(Xd+ 2 > 0) -' 0,P(Xd_1>0)-1.

Note that, by (13)

E(Xd+2)

so the first assertion is clear.Let now r = d - 1. Let us use (9) to calculate the second moment of Xr,

summing separately over pairs of K' subgraphs with exactly I vertices incommon:

E(X:) _ (r) (r) (n - r)p2(5)-(4)_

1=0 r 1 r l

Since

with ar = a(X,) we have

_21ognd to

+ O(log log n).g b

2

µ: = E(Xr)2 = (n) puf)r

Q; E(X; )z= 2 -1<-14r µr 1=2

(r (n- l) -(l)

(n) p

r

2 r (r!)2 n-ibc4)!= l!((r - 1)!)2

By assumption E(X,+1) Z 1, sonr+ 1 > b2 1)(r + 1)

implying

nZb"2((r+1)!)li('+i)

Page 150: Graph Theory-An Introductory Course-Bela Bollobas

§5 Hamilton Cycles-the Use of Graph Theoretic Tools

Hence2 r 12

µr I= 1! ((r - 1)!)2((r + 1)!)ua+1) P

r

2 Y_r2min(l,r-l)PI(r+1-I)/2

1=2

139

=0(1).This proves the second assertion.

§5 Hamilton Cycles-the Use of Graph TheoreticTools

In the proofs so far we always adopted a more or less head-on attack. Wehardly needed more from graph theory than the definitions of the conceptsinvolved, the emphasis was on the use of probability theory. This section isdevoted to a beautiful result of Posa, the proof of which is based on a non-trivial result in graph theory. Of course, in the ideal use of probabilisticmethods in graph theory we would have a mixture of all the ideas presentedin the four sections. Thus we would prepare the ground by using non-trivialgraph theoretic results and would apply probability theory to get informa-tion about graphs in a probability space tailor made for the problem. Wecould then select an appropriate graph which we would afterwards alterwith the aid of powerful graph theoretic tools.

It is easily seen that if E > 0 then almost all graphs of order n and sizeM = [(z + E)n log n] are connected and one can also show that almost nograph of order n and size M = f(z - E)n log n] is connected (Exercise 14).In particular, almost no graph of order n and size M = L(Z - E)n log n]contains a Hamilton cycle. It is fascinating that roughly the same number ofedges as are needed to ensure connectivity already ensure the existence of aHamilton cycle. Our next aim is to prove this beautiful theorem of Posa.

The basis of the proof of this result is Theorem 15 of Chapter IV. Let Sbe a longest x0-path in a graph H and write L for the set of endvertices of thetransforms of S. Denote by N the set of neighbours of vertices of L on S andput yP = V(H) - L u N. Then Theorem 15 of Chapter IV states that H hasno L-i edge. All we shall need from this is that if I L I = I 5 I H 1/3 thenthere are disjoint sets of size l and I H I - 31 + 1, that are joined by no edgeof H.

For the sake of convenience we shall work with the space

1(n, P(edge) = P), p =c log n

n

We start with a simple lemma in the vein of Theorem 4. Denote by D, thenumber of pairs (X, Y) of disjoint subsets of V such that I X I = t, I Y I =n - 3t, and G has no X-Y edge.

Page 151: Graph Theory-An Introductory Course-Bela Bollobas

140 VII Randon Graphs

Lemma 13. Let c > 3 and 0 < y < 3 be constants and let p = (c log n)/n.Then in 1(n, P(edge) = p) we have

P(D, > 0 for some t, I < t < yn) = O(n3-`).

PROOF. Put fl = (c - 3)/4c. Clearlylynl lynJ n n -- t

E (D() _ - (t)n / 1 - p)t(n 3t)

t=1 r=1 - 3tIn - 1) n 3 [an] 1 3[ t(n - 3t)<n (1-p)- + Y. n (1-p)

2 t=2 t!

[yn]+ Y 22n(1 - p)t(n-3[).

t=[fin]+1

Now since (1 - p)n < n-`, we haven3(1 - p),--3 < (1 - p)3n3-`,

n3t(1 - p)t(n - 3t)\< nt(3 -(c(w - 39)/n)) < n3-Q if 2 t < fin

and

22n(1 - p)t(n-3t) < n(2n/(loan))-((n-3t)t/n) = 0(n-B(1-3y)n) if fin < t < yn.

Consequently

lynJ

Y E(D,) = O(n3t=1

implying the assertion of the lemma. 0

Theorem 14. Let p = (c log n)/n and consider the space 4(n, P(edge) = p).If c > 3 and x and y are arbitrary vertices, then almost every graph contains aHamilton path from x to y. I f c > 9 then almost every graph is Hamiltonian con-nected: every pair of distinct vertices is joined by a Hamilton path.

PROOF. Choosey < in such a way that cy > 3 if c > 9 and cy > 1 if c > 3.Let us introduce the following notation for certain events in

4(n, P(edge) = p), whose general element is denoted by G.

D = {D, = 0 for every t, l <_ t 5 [yn j },E(W, x) = {G[W] has a path of maximal length, whose endvertex is

joined to x},E(W, x I w) = {G[ W] has a w-path of maximal length among the w-paths,

whose endvertex is joined to x},F(x) = {every path of maximal length contains x},

H(W) = {G[W] has a Hamilton path},H(x, y) = {G has a Hamilton x-y path),

HC = {G is Hamiltonian connected}.

Page 152: Graph Theory-An Introductory Course-Bela Bollobas

§5 Hamilton Cycles-the Use of Graph Theoretic Tools 141

The complement of an event A is A.Note that by Lemma 13 we have

P(D) = 1 - P(D) = O(n 3-,).

Let I W I = n - 2 or n - 1 and let us estimate P(D n E(W, x)), wherex 0 W. Let G e D n E(W, x) and consider a path S = xo x t ... xk of maximallength in G[W]. (By introducing an ordering in W, we can easily achievethat S is determined by G[W].) Let L = L(G[W]) be the set of endverticesof the transforms of the xo-path S and let R be as in Theorem 15 of ChapterIV (applied to G[W]). Recall that I R I >- I W I + 1 - 3 I L I and there is noL - R edge, so no L-R u {x} edge either. Since G e D and I R u {x} I>n - 31 L 1, we find that I L 12! yn. As L was determined independently of theedges incident with x, we have

P(D n E(W, x)) < P(G e D and x is not joined to L(G[W]))<(1 - p)''"<n-`Y.

Exactly the same proof implies that

P(D n E(W, x I w)) < n

provided IW =n-2orn- 1, we WandxOW.Note now that F(x) c E(V - {x}, x), so

P(H(V)) = P U F(x)) < P(D n U F(x)) + P(D)xcV XCV

Y P(D n F(x)) + P(D) < nP(D n E(V - {x}, x)) + P(D)xe V

< n' `Y + O(n3-`).

This proves that if c > 3 then almost every graph has a Hamilton path.Now let x and y be distinct vertices and put W = V - {x, y}. By the

first part

P(H(W)) < 2n' -`Y + O(n3-`).

Since

H(x, y) - H(W) n E(W, y) n E(W, x I y),

we have

P(H(x, y)) < P(H(W)) + P(D n E(W, y)) + P(D n E(W, x I y)) + P(D)< 2nt-`Y + 2n-`Y + O(n3-`).

Therefore, if c > 3 then almost every graph contains a Hamilton path fromxtoy.

Page 153: Graph Theory-An Introductory Course-Bela Bollobas

142 VII Random Graphs

Finally, as there are (z) choices for an unordered pair (x, y), x 0 y,

P(HC) < > P(H(x, y)) _< n3-`r + O(n2-`Y)

x#y

Thus if c > 9 then almost every graph is Hamiltonian connected.

Since every Hamiltonian connected graph is Hamiltonian (contains aHamilton cycle), by Theorem 8 we have, in particular, that if c > 9 thenalmost every graph in 4(n, [(c log n)/nj) is Hamiltonian. In fact, one can seethat the essential part of the proof gives this result with c > 6 as well. Inde-pendently of Posa, Korshunov proved a sharper and essentially best possibleform of Theorem 14: the assertion holds for every c > 1.

EXERCISES

1. Let G = (V, E) be a directed graph with m edges and without loops. Prove that Vcan be partitioned into sets V, and V2 such that G contains more than m/4 edgesfrom V, to V2.

2. Given an integer k > 2 and a graph G, denote by p'k'(G) the minimal number ofedges of G whose omission results in a k-partite graph. Prove that if G = G(n, m)then

p(k)(G) < m{ l(r2

1 ) + (k - I) \2/ I(2n)

where n = kr + 1, 0 < I < k. Show furthermore that

ptk'(G) 5 m[n/kJ

n

[Hint. Consider all graphs of the form H = lK'+' u (k - I)K' with vertexset V(G). Note that the expected number of edges common to G and H is

3. Prove that there is a tournament of order n (see Exercise 12 of Chapter I) thatcontains at least n!2-"+' directed Hamiltonian paths.

4. Show that there is a graph of order n and size [j(1 - (1/s!t!))n2-as+,-2U(sr-,»j

that does not contain a K(s, t).

5. Given 2 < s < n, let d be the maximal integer for which there is a G3(n, n, n)without a K3(s, s, s), in which every vertex is joined by at least d edges to each ofthe other two classes. Prove a lower bound for d.

6. Use Theorem 3 to prove that if r ;> 2, 0 < E < (r - l)-2 and

2

log(2(r - 1)2e)

then for every sufficiently large n there is a graph G(n, m) not containing a K,(t),where m > {(r - 2)/2(r - 1) + E}n2 and t = [d* log n]. (Note that this showsthat Theorem 20 of Chapter IV is essentially the best possible.)

Page 154: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 143

7. Show that a given vertex has degree I in about 2/e2 of the graphs in W(n, n).

In Exercises 8-13 the model W(n, P(edge) = p) is used and 0 < p < 1 is assumedto be fixed. The same model is used in Exercises 14-19 but p varies with n asindicated.

8T Show that for r. > 0 a.e. graph has at least '(p - e)n2 edges and at most -(p + r)n2edges.

9. Give a lower bound on the chromatic number of a.e. graph.

10. Show that a.e. graph contains a complete graph of order at least log n/log(1/p).

11. Prove that a.e. graph G satisfies.

d(G) = ).(G) = K(G) = pn - (2pqn log n)112 + o(n log n)112,

where q = I - p.

12. Estimate the maximal value of t for which a.e. graph contains a spanned K'` _K(t, t). Estimate the corresponding value for K,(t) = K(t, ... , t).

13. Let 0 < c < 1. Prove that a.e. graph has the property that for every set W ofk = [c 1092 n j vertices there is a vertex xl for each subset Z of W such that xl isjoined to each vertex in Z and to none in W - Z. Note that for c = 1 it isimpossible to find even a set of 2* vertices disjoint from W. [Hint. Refine the proofof Theorem 7.]

14. Prove that (log n)/n is a sharp threshold function for connectivity, in the sensethat if e > 0 and p = ((1 - r)log n)/n then almost no graph is connected whileif e > 0 and p = ((I + E)log n)/n then a.e. graph is connected.

15' Sharpen the previous result as follows. If p = ((log n)/n) + (2x/n) then the prob-ability that G is connected is e '_. [Show first that a.e. G consists of a componentand isolated vertices.]

16. Let p = ((log n)/n) + (C(n)/n), where C(n) -+ oo arbitrarily slowly. Prove thata.e. G contains a 1-factor. [Use Tutte's theorem, Theorem 12 of Chapter III,ignoring the parity of the components.]

17. Show that 1/n is a threshold function for F1 in Figure VII.!, that is if pn - 0 thenalmost no graph contains F1 and if pn - oo then a.e. graph does.

18. What is the threshold function for F2 in Figure VII. I?

A

Figure VII.1. The graphs F,, F2 and F3.

Page 155: Graph Theory-An Introductory Course-Bela Bollobas

144 VII Random Graphs

19. Let e > 0. Prove that if p = n-("2)- `then almost no graph contains F3 in FigureVII.! but if p = n-I'I'I" then a.e. graph does. [Find a suitable graph F3 that hasaverage degree 2 + e.]

20.- Consider random directed graph; in which all edges are chosen independentlyand with the same probability p. Prove that there is a constant c such that ifp = c((log n)/n)'12 then a.e. directed graph contains a directed Hamilton cycle.[Hint. What is the probability that a graph contains both edges ab and 6a?Apply Theorem 14 to the random graph formed by the double edges.]

21.- Note that the suggested solution of Exercise 20 gives two directed Hamiltoncycles with the same underlying (non-directed) edge set. Show that with p =(1 - e)((log n)/n)'"2 almost no directed graph contains such a pair of Hamiltoncycles.

22. Show that there are at least (2'/In!) + o(2"/n !) non-isomorphic graphs of order n.[Hint. Show that a.e. graph in 4(n, P(edge) has trivial automorphism group;for the automorphism group see p. 157.]

Notes

Perhaps the first combinatorial result proved by probabilistic methods isthe assertion of Exercise 3, proved by T. Szele in Combinatorial investi-gations concerning directed complete graphs (in Hungarian), Mat. Fiz.Lapok 50 (1943) 223-256; for a German translation see KombinatorischeUntersuchungen fiber gerichtete vollstandige Graphen, Publ. Math. Debre-cen 13 (1966) 145-168. However, the first papers that gave real impetus tothe use of random graphs are two papers of P. Erdos : Graph theory andprobability, Canad. J. Math. 11(1959) 34-38, contains Theorem 6 and Graphtheory and probability II, Canad. J. Math. 13 (1961) 346-352, contains thelower bound on R(3, t) given in Theorem 6.

The result about first order sentences which we mentioned after Theorem7 is due to R. Fagin, Probabilities on finite models, J. Symb. Logic 41(1976)50-58.

The fundamental paper on the growth of random graphs is P. Erdos andA. Renyi, On the evolution of random graphs, Publ. Math. Inst. Hungar.Acad. Sci. 5 (1960) 17-61. This paper contains a detailed discussion ofsparse random graphs, covering amongst other things the distribution of theircomponents and the occurrence of small subgraphs (Theorem 11).

The sharpest results in the direction of Theorem 12 are in B. Bollobasand P. Erdos, Cliques in random graphs, Math. Proc. Cambridge Phil. Soc.80 (1976) 419-427. Posa's theorem (Theorem 14) is in L. Posa, Discrete Math.14 (1976) 359-364, its sharper form is in A. D. Korshunov, Solution of aproblem of Erdos and Renyi, on Hamilton cycles in nonoriented graphs,Soviet Mat. Doklady 17 (1976) 760--764.

For standard results of probability theory, including Chebyshev's in-equality and the approximation of the binomial distribution by the Poisson

Page 156: Graph Theory-An Introductory Course-Bela Bollobas

Notes 145

distribution the reader is referred to W. Feller, An Introduction to Proba-bility Theory and Its Applications, Vol. 1 3rd ed., Wiley, New York, 1974,and A. Renyi, Foundations of Probability, Holden-Day, San Francisco, 1970,especially to the sections on the De Moivre-Laplace formula.

Random graphs and other combinatorial structures are investigatedin depth in the book by P. Erdos and J. Spencer, Probabilistic Methods inCombinatorics, Academic Press, New York and London, 1974.

Page 157: Graph Theory-An Introductory Course-Bela Bollobas

CHAPTER VIII

Graphs and Groups

In this chapter we examine some interactions between graphs and groups.Some problems concerning groups are best attacked by using graphs.Although in this context a graph is hardly more than a visual or computa-tional aid, its use does make the presentation clearer and the problems moremanageable. The methods are useful both in theory and in practice: they helpus to prove general results about groups and particular results about in-dividual groups. The first section, about Cayley and Schreier diagrams,illustrates well both these aspects It also contains an informal account ofgroup presentations.

If each member of a class of graphs is known to have particularly pleasantsymmetry properties, in other words if it has a large automorphism group,then we may often make use of this to obtain additional information aboutthe class. In some cases this extra information enables us to determine theclass almost completely. The second section shows how we can do thisusing the properties of the adjacency matrix.

Some classes of labelled graphs are easily enumerated, as we shall see in§3. Other enumeration problems, such as counting isomorphism classesof graphs, lead us to the study of orbits of permutation groups. The high-light of the section is the fundamental theorem enumerating such orbits,namely Polya's theorem.

§1 Cayley and Schreier Diagrams

Let A be a group generated by a, b, .... The graph of A, also called its Cayleydiagram, with respect to these generators is a directed multigraph whoseedges are coloured with the generators: there is an edge from x to y coloured

146

Page 158: Graph Theory-An Introductory Course-Bela Bollobas

§1 Cayley and Schreier Diagrams

a

147

Figure VIII.1. The Cayley diagrams of (i) the cyclic group C4 generated by a, (ii) theKlein four-group with generators a, b and (iii) the symmetric group S3 with generatorsa = (123) and b = (12).

with a generator g if xg = y. To illustrate this concept in Figure VIII.1,we show the Cayley diagrams of three small groups.

A Cayley diagram is regular, and so is its colouring, in the followingsense: for each vertex x and each generator (colour) g there is exactly oneedge of colour g starting at x and exactly one edge of colour g ending at x.Furthermore, at most one edge goes from x to another vertex y. If we knowthe Cayley diagram of a group then we can easily answer questions in termsof the generators. What is the element aba2b in S3? It is the end of the directedwalk starting at 1 whose first edge has colour a, the second has colour b,the third a, the fourth a and, finally, the fifth b. By following this walk inthe third picture in Figure VIII.1, we find that aba2b = a2. In general, twoelements expressed as products of some generators are equal if the cor-responding walks starting at 1 end at the same vertex.

The Schreier diagram is a slight extension of the Cayley diagram. Thistime we have a group A, a set S of elements of A and a subgroup B of A.The Schreier diagram of A mod B describes the effect of the elements of S onthe right cosets of B: it is a directed multigraph whose vertices are the rightcosets of B, in which an edge of colour s e S goes from a coset H to a coset Kif Hs = K. (Thus a Cayley diagram is a Schreier diagram mod B = (11.)In most cases S is chosen to be a set of generators or a set which togetherwith B generates A. Instead of giving a separate illustration, note that if Ais the symmetric group on {1, 2, 3, 4), B is the subgroup of elements fixing1 and S = (a) with a = (1234) then the Schreier diagram is exactly the firstpicture in Figure VIII.!, that is the Cayley diagram of C4. Once again wenote that for each vertex H and each colour g e S exactly one edge colouredg starts at H and exactly one edge coloured g ends at H. However, some ofthe edges may be loops, that is they may start amd end at the same coset.Furthermore, there may be many edges of different colours joining twovertices.

Group diagrams do not tell us anything about groups that cannot beexpressed algebraically. However, the disadvantage of the algebraic ap-proach is that many lines of print are needed to express what is conveyedalmost instantaneously by a single diagram. These diagrams are especially

Page 159: Graph Theory-An Introductory Course-Bela Bollobas

148 VIII Graphs and Groups

helpful when we have a concrete problem to be solved by hand, and more-over the purely mechanical techniques involved are ideal for direct use on acomputer. Since the advent of fast electronic computers many otherwisehopeless problems have been solved in this way.

Group diagrams are particularly useful when attacking problems con-cerning groups given by means of their presentations. For the convenienceof the reader we recall the basic facts about group presentations. We aimthroughout for an intuitive description, rather than a rigorous treatment;the interested reader may fill in the details himself or turn to some specialistbooks on the subject. A word W in the symbols a, b, c, ... is a finite sequencesuch as ba-'ccaa-'b-'a; the empty sequence is denoted by 1. We call twowords equivalent if one can be obtained from the other by repeatedly re-placing xx - ' or x - 'x by 1(the empty word) or vice versa. Thus abb-'a-'c-'and cc - 'c - 'dd ' are both equivalent to c - '. In fact, we shall use the samenotation for a word and its equivalence class and so we write simplyabb-'a-'c-' = cc-'c-'dd-1 == c-'. Furthermore, for simplicityabbc-'c-'c-' = ab2c-', etc. The (equivalence classes of) words form agroup if multiplication is defined as juxtaposition: (ab-'c)(c-'ba) _ab-'cc-'ba = a2. Clearly a ' is the inverse of a and (a-'b-'c)-' = c - 'ba.This group is the free group generated by a, b, c.... and it is denoted by<a, b, c.... >.

Let Rµ, R,,... be words in the symbols a, b, c,... , let F = <a, b, c.... >and let K be the normal subgroup of F generated by R,, R...... Then thequotient group A = F/K is said to be the group generated by a, b, c.... andthe relators R,,, R,, ... ; in notation A = <a, b, c,... IRA' Rv,...>.

Once again we use a word to denote its equivalence class and writeequality to express equivalence. More often than not, a group presentationis written with defining relations instead of the more pedantic relators. Thus<a, b I a2 = b3> denotes the group <a, b I alb -3 >. A group is finitely presentedif in its presentation there are finitely many generators and relations. It iseasily seen that two words W, and W2 are equivalent in A if W2 can be ob-tained from W, by repeated insertions or deletions of as-', a-'a, bb-',... ,

the relators Rµ, R,, ... and their inverses Rµ ', As an example,note that in A = <a, b I a3b, b3. a4> we have a = aa3b = a`b = b. Hence1 = a3b(b3)-' = a = b and so A is the trivial group of order 1.

Even the trivial example above illustrates our difficulties when faced witha group given in terms of defining relations. However, groups defined bytheir presentations arise naturally in diverse areas of mathematics, es-pecially in knot theory, topology and geometry, so we have to try to over-come the difficulties. The fundamental problems concerning group presenta-tions were formulated by Max Dehn in 1911. These problems ask for generaland effective methods for deciding in a finite number of steps (i) whether twogiven words represent the same group element or not (word problem), (ii)whether they represent conjugate elements (conjugacy problem) and (iii)whether two finitely presented groups are isomorphic or not (isomorphism

Page 160: Graph Theory-An Introductory Course-Bela Bollobas

§1 Cayley and Schreier Diagrams 149

problem). All these problems have turned out to be problems in logic, andcannot be solved in general. Explicit solutions of these problems are alwaysbased on specific presentations and often make use of group diagrams.(Dehn himself was a particularly enthusiastic advocate of group diagrams.)

Let A = <a, b.... I R,,, R,, ...>. We shall attempt to construct the Cayleydiagram of A with respect to the generators a, b, .... Having got the Cayleydiagram, we clearly have a solution to the word problem for this presentation.

The Cayley diagram has the following two properties. (a) The (directed)edges have a regular colouring with a, b, ... , that is for each vertex x andgenerator g there is exactly one edge coloured g starting at x and exactlyone edge coloured g ending at x. (b) Every relation is satisfied at everyvertex, that is if x is a vertex and R, is a relator then the walk starting at xcorresponding to R. ends at x. How shall we go about finding the Cayleydiagram? We try to satisfy (a) and (b) without ever identifying two verticesunless we are forced to do so. Thus at each stage we are free to take a newvertex and an edge into it (or from it). We identify two vertices when either(b) or (a) force us to do so. If the process stops, we have arrived at the Cayleydiagram. Note that until the end we do not know that distinct vertices rep-resent distinct group elements.

As an example, let us see how we can find the Cayley diagram of A =<a, b I a3 = b2 = (ab)2 = 1 >. We replace each double edge corresponding tob by a single undirected edge; this makes the Cayley diagram into a graph.We start with the identity and with a triangle 123 corresponding to a3 = 1;for simplicity we use numbers 1, 2, ... to denote the vertices, reserving 1 forthe identity element. An edge coloured b must start at each of the vertices1, 2 and 3, giving vertices 4, 5 and 6. Now a3 = 1 must be satisfied at 6,giving another triangle, say 678, whose edges are coloured a, as in FigureVIII.2. At this stage we may care to bring in the relation (ab)2 = abab = 1.Checking it at 8, say, we see that the walk 86314 must end at 8, so the verticesso far denoted by 8 and 4 have to coincide. Next we check abab = 1 at 7:the walk 7(8 = 4) 125 must end at 7 so 5 and 7 are identical. All that remainsto check is that the diagram we obtained satisfies (a) and (b), so it is theCayley diagram of the group in question. In fact, the diagram is exactly thethird picture in Figure VIII.1, so the group is S3.

For p >_ q >_ r >_ 2 denote by (p, q, r) the group <a, b, c I a° = bQ = c' _abc = I>. Given specific values of p, q and r, with a little effort the reader

4} a

5 2/ \3 6/ \ 7

Figure VIII.2. Construction of a Cayley diagram.

Page 161: Graph Theory-An Introductory Course-Bela Bollobas

150

a5=b2=c2=abc= I

a3 = b3 = c' = abc = I

VIII Graphs and Groups

a3=b3=c2=abc=I

a'=b3=c'=abc=IFigure VIII.3. Some Cayley diagrams. The shaded regions correspond to abc = 1.

can find the Cayley diagram of the group (p, q, r) with respect to the genera-tors a, b and c. Figure VIII.3 shows some of these diagrams.

The diagrams above indicate some connection with tessellations. Thebeauty of the use of Cayley diagrams is that one can make good use of thisconnection. Indeed, the reader who is slightly familiar with tessellations ofthe sphere, the Euclidean plane and the hyperbolic plane, can easily provethe following result.

Theorem 1. If (1/p) + (1/q) + (1/r) > 1 then the group (p, q, r) is finite andhas order 2s where 1/s = (1/p) + (1/q) + (1/r) - 1. The Cayley diagram isa tessellation of the sphere (as in the first two pictures in Figure VIII.3).

If (1/p) + (1/q) + (1/r) S 1 then the group (p, q, r) is infinite. If equalityholds, the Cayley diagram is a tessellation of the Euclidean plane, otherwiseit is a tessellation of the hyperbolic plane (as in the last two pictures in FigureVIII.3).

As we remarked earlier, groups given by means of their presentationsarise frequently in knot theory. In particular, Dehn showed how a presenta-tion of the group of a (tame) knot (that is the fundamental group of lafter the removal of the knot) can be read off from a projection of the knot

Page 162: Graph Theory-An Introductory Course-Bela Bollobas

§1 Cayley and Schreier Diagrams 151

Figure VIII.4. The trefoil and the figure of eight.

into a plane. The projection of the knot forms the boundary of certainbounded domains of the plane. To each of these domains there correspondsa generator (the identity corresponds to the unbounded domain) and toeach cross-over there corresponds a relator. The general form of theserelators is easily deduced from the two examples shown in Figure VIII.4.(Indeed, readers familiar with the fundamentals of algebraic topology caneasily prove the correctness of this presentation.) The group of the trefoil(or clover leaf) knot is <a, b, c, d I ad - 'b, cd -'a, cbd -') and the group of thefigure of eight knot is <a, b, c, d, eIab - 'e, ad-'eb-', ed-'cb-', acd-'>.

Of course, before embarking on an investigation of the group, it is sensibleto attempt to simplify the presentation. For example, cbd-' = 1 means thatd = cb or bd -'c = 1. Thus the group of the trefoil knot is

<a, b, c, dad -' b, bd -'c, cd -'a>

or, equivalently,

<a, b, c l cb = ba = ac>.

We invite the reader to check that the Cayley diagram of this group is madeup of replicas of the ladder shown in Figure VIII.5. (Exercise 4). At eachedge three ladders are glued together in such a way that when looking atthese ladders from above, we see an infinite cubic tree (Figure VIII.5).

11

Figure VIII.S. The ingredients of the Cayley diagram of the trefoil knot.

Page 163: Graph Theory-An Introductory Course-Bela Bollobas

152 VIII Graphs and Groups

Having obtained the Cayley diagram, we can read off the properties we areinterested in. In the case of this group the method does not happen to betoo economical, but this is the way Dehn proved in 1910 that the group ofthe trefoil knot is not the group of a circle, which is infinite cyclic.

Schreier diagrams can be constructed analogously to Cayley diagrams.In fact, in order to determine the structure of a largish group given in apresentation it is often more advantageous to determine first the Schreierdiagram of a subgroup. In order to show this, we work through anotherexample, once again due to Dehn. What is the group

A = <a, bla2 = b5 = (ba)3 = 1>?

Let us construct the Schreier diagram of the cosets of the subgroup B gene-rated by b. As before, we take a vertex I for B and try to construct as big adiagram as conditions (a) and (b) allow us. (Recall that (a) requires thecolouring to be regular and (b) requires that each defining relation is satisfiedat each vertex.) However, in this case there is one more condition: the edgecoloured b starting at 1 must end in 1 (so it is a loop) since Bb = B. Thusafter two steps we have the diagram shown in Figure VIII.6. (Once again theedges coloured a will not be directed since a2 = 1.)

a

Figure VIII.6.

,-15

6

2\

The initial part of the Schreier diagram of A mod B.

Now let us check the condition bababa = 1 at vertex 6. The walk bababtakes us from 6 to 3, so there must be an edge coloured a from 3 to 6. Inorder to have edges coloured a starting at 4 and 5, we take up new vertices7 and 8, together with edges 47 and 58 coloured a. Next we check the con-dition ab-lab-lab-' = 1, which is equivalent to (ba)3 = 1 at 7, and findthat there is an edge from 7 to 8 coloured b. To satisfy b5 = 1 at 7 we takethree new vertices, 9, 10 and 11. Checking (ba)3 = 1 at 11 we find that thereis an edge from 9 to 11 coloured a. At this stage we are almost home, but noedge coloured a begins at 10, so we take a new vertex 12 joined to 10 by anedge coloured a. What does the condition ab-'ab-'ab-' = 1 tell us atvertex 12? The walk ab-'ab-'a starting at 12 ends at 12, so there must bean edge coloured b starting at 12 and ending at 12, giving us Figure VIII.7.This is the Schreier diagram we have been looking for, since the colouringis clearly regular and it is a simple matter to check that each defining relation

Page 164: Graph Theory-An Introductory Course-Bela Bollobas

§1 Cayley and Schreier Diagrams 153

a

,-4T

, Io

f" 1

12

6w- ''9Figure VIII.7. The complete Schreier diagram.

is satisfied at each vertex. In fact, a2 = 1 and b5 = 1 are obviously satisfied;since (ba)3 = 1 holds at 6 by construction, it also holds at each vertex ofthe walk 621236, etc.

This detailed and cumbersome description fails to do justice to themethod which, when performed on a piece of paper or on a blackboard, isquick and efficient. The reader is encouraged to find this out for himself.

What the Schreier diagram certainly tells us is the index of B: it is simplythe number of vertices. Indeed, Schreier diagrams are often constructed oncomputers just to determine the index of a subgroup. In some cases, as inthe example above, it tells us considerably more. The Schreier diagram isessentially a shorthand for the representation of A as a group of permuta-tions of the cosets of B. In this case a -+ (12) (36) (47) (58) (9 11) (10 12) andb - (1)(23456)(789 10 11)(12). Since the permutation corresponding to bhas order 5, which is exactly the order of b in A, we see that A is a group oforder 5.12 = 60 and is, in fact, isomorphic to A5, the alternating group on5 symbols.

If we want our Schreier diagram to carry more information, then we fixcertain representatives of the cosets and keep track of the effect of the genera-tors on these representatives. We decorate each cosec by its representative:if H is decorated by [h] then H = Bh. Now if there is an edge coloured afrom H = Bh to K = Bk, then we decorate this edge by [a] if ha = ak. SinceK = Bk = Ha = Bha, we see that a E B, so the edges are decorated withelements of B. Furthermore, if H, K and L are decorated with h, k and 1,and there are edges coloured a, b, c and decorated [a], [fl] and [y] joiningthem, as in Figure VIII.8, then habc = akbc = afllc = aflyh. In particular,

H[h] It .............. 9.................... .' L[11c[y]

Figure VIII.8. A cycle in a decorated Schreier diagram.

Page 165: Graph Theory-An Introductory Course-Bela Bollobas

154 VIII Graphs and Groups

B=

4

Figure VII1.9. The decorations induced by a spanning tree.

if h = 1 we have abc = afly. Of course, an analogous assertion holds forarbitrary walks starting and ending at B: the product of the colours equalsthe product of the decorations.

One of the simplest ways of decorating the vertices and edges makes useof spanning trees. Select a spanning tree of the Schreier diagram. DecorateB, the subgroup itself, by 1 (the identity) and decorate the edges of thespanning tree also by 1. This determines the decoration of every vertex (thatis coset) and every edge. Indeed, for each vertex H the spanning tree containsa unique path from B to H; clearly H has to be decorated with the productabc ... corresponding to this path. These coset representatives are said toform a Schreier system for B mod A. What is the decoration of a chord HK,an edge not in the tree? By the remark above it is the product of the colourson the B-H path, the edge HK and the K-B path, as in Figure VIII.9.

Since each element of B is the product of the colours on a closed walkfrom B to B in the Schreier diagram, the decorations of the chords generateB. Thus from a Schreier diagram we can read off a set of generators of B,independently of the structure of A.

Theorem 2. The subgroup B of A is generated by the decorations of the chords.O

In particular, the subgroup B in Figure VIII.9 is generated by b, ab3a',ab - 'ab - 'a -' and ababa - '.

It is equally simple to find a presentation of B, provided we have a presen-tation of A. This is obtained by the Reidemeister-Schreier rewriting process;we give a quick and loose description of it. The generators of this presenta-tion are the chords of the spanning tree; to distinguish chords of the samecolour we write c; for the edge coloured c starting at vertex i. For each vertexi and each relator R,, denote by R;' the (word of the) walk starting at i givenby R. expressed as a product of the c;, say Rµ = b;c;.... The reader caneasily fill in the missing details in the proof of the following beautiful result,due to Reidemeister and Schreier.

Theorem 3. The subgroup B has a presentation

i i 2 2 (]<a,, bl,... , a2, b2, ... R', ... , Ru, RY, ...>

Page 166: Graph Theory-An Introductory Course-Bela Bollobas

§2 Applications of the Adjacency Matrix 155

Now if we wish to preserve the connection between this presentation ofB and the original presentation of A, we simply equate c; with the decorationof the edge coloured c starting at vertex i.

If A is a free group, its presentation contains no relations. Hence theabove presentation of B contains no relations either, so B is also a free group.This is a fundamental result of Nielsen and Schreier.

Theorem 4. A subgroup of a free group is free. Furthermore, if A is a free groupof rank k (that is it has k free generators) and B is a subgroup of index n thenB has rank (k - 1)n + 1.

PROOF. The presentation of B given in Theorem 3 is a free presentation on theset of chords of the Schreier diagram. Altogether there are kn edges of whichn - 1 are tree edges; hence there are (k - 1)n + 1 chords.

It is amusing to note that Theorem 3 implies that the rank of a free groupis well defined. Indeed, suppose that A is freely generated by a, b, .... Thenevery directed multigraph with a distinguished vertex (corresponding tothe subgroup) and a regular colouring (by a, b,...) is the Schreier diagramof some subgroup B of A, for threre are no relations to be satisfied. Hencesubgroups of index n are in 1-1 correspondence with regularly colouredmultigraphs of order n. In particular, if A has k >- 2 generators, it has 2' - 1subgroups of index 2, for there are 2' multigraphs of order 2 regularlycoloured with k colours, but one of those is disconnected. The number ofsubgroups of index 2 is clearly independent of the presentation, so k isdetermined by A.

§2 Applications of the Adjacency Matrix

Recall from §3, Chapter II that the vertex space C0(G) of a graph G is thecomplex vector space of all functions from V(G) into C. Once again we takeV(G) = {v,, v2, ... , so that dim C0(G) = n and write the elements ofC0(G) in the form x = Y;_ , xi v, or x = (xi) i ; here xi is the value of x at vi,also called the weight at vi. The space C0(G) is given the natural inner productassociated with the basis (vi)1: <x, y> = Y"_, xiyi.

We shall concentrate on the adjacency matrix A = (ai) of G, the 0-1matrix where aij = 1 if vivj is an edge. As usual, A is identified with a linearendomorphism of C0(G). To start with, we recollect some simple facts fromlinear algebra. The matrix A is real and symmetric, so it is hermitian, that is<Ax, y> = <x, Ay>. Hence its numerical range

V(A) = {<Ax, x>: <x, x> = l}

is a closed interval of the real line. The eigenvalues of A are real, say A, >A2 > ... > A,, and V(A) is exactly the interval [A,, At]. (For simplicity an

Page 167: Graph Theory-An Introductory Course-Bela Bollobas

156 VIII Graphs and Groups

eigenvalue of A is said to be an eigenvalue of G). We shall write imax(G) forthe maximal eigenvalue A, and Ami.;(G) for the minimal eigenvalue A. Theinner product space C0(G) has got an orthonormal basis consisting ofeigenvectors of A. In particular, if m(A) denotes the (geometric or algebraic)multiplicity of an eigenvalue A then Y;_, m(Ai) = n. These remarks enableus to deduce some basic properties of the eigenvalues.

Theorem S. Let G be a connected graph of order n with adjacency matrix A.

(i) Every eigenvalue A of G satisfies I A I < A = A(G).(ii) A is an eigenvalue of G iff G is regular; if A is an eigenvalue then m(A) = 1.

(iii) If -A is an eigenvalue of G then G is regular and bipartite.(iv) If G is bipartite and A is an eigenvalue of G then so is -A, and m(A) _

M(-,I).(v) 8(G) _< .Zmax(G) < A(G).

(vi) If H is a spanned subgraph of G then Amin(G) S Amin(H) < Amax(H)imax(G)

PROOF. (i) Let x = (xi) be a non-zero eigenvector with eigenvalue A. Let x,be a weight with maximum modulus: I x, I ? I xi I for every i ; we may assumewithout loss of generality that xp = 1. Then

JAI = IAX,I = 1,Y=1

ap,x, I <. aP,Jxll C IxPJd(vP) < IxpIA = A, (*)1=1

showing I A I < A.(ii) If A = A is an eigenvalue and x, xp are chosen as in (i), then (*) im-

plies that d(vp) = A and x, = xp = 1 whenever v, is adjacent to v,,. In turnthis implies that d(v,) = A and x,, = x, = 1 whenever v,k is adjacent to v,,and so on; as G is connected d(vi) = A and x; = 1 for every i. Hence G isA-regular and x is j, the vector all of whose entries are 1.

Conversely, if G is A-regular then (Aj)i = Yi=, ail = A so Aj = Aj.(iii) If A = -A is an eigenvalue then, as in (ii) inequality (*) implies that

d(vp) = A and x, = -x,, = -1 whenever v, is adjacent to vp. As in (ii),this implies that G is A-regular. Furthermore, at each vertex v,k adjacent tov, the weight is 1, at each neighbour of vk it is - 1, and so on. The weight is 1at the vertices at an even distance from vP and it is -1 at the other verticesand every edge joins vertices of different weights. Thus G is bipartite, sayV = V, u V2, where vp a V1.

(iv) Suppose G is bipartite with vertex classes V, and V2. Let b be thefunction (vector) that is 1 on V, and - 1 on V2. Then x -+ bx = (bixi), isan automorphism of the vector space C0(G). Now if Ax = kx and v, e V1,say, then

(A(bx))i = aijbjxj = E a,,xj - Y aijxj = - a.,xjj=1 VJEV1 VJEV2 VjEV2

n

Y ai,xj - Y a;jxj = - . Qijxj = - Ax, = -A(bx)i.VjE Y, V)E V2 j= 1

Page 168: Graph Theory-An Introductory Course-Bela Bollobas

§2 Applications of the Adjacency Matrix 157

Hence b gives an isomorphism between ker(A - Al) and ker(A + Al),showing m(?) = m(- A).

(v) We know already that 1,,,,x(G) <_ A(G). Note that for j = (1, 1, ... , 1)we have <j, j> = n so

1 1 a a 1"V(A) 3 <Aj, j> = Yak, = - Y d(vk) > 8(G).

n nk=1 l=1 n k=1

Hence Amax(G) = max V(A) Z S(G).(vi) It suffices to prove the result for a spanned subgraph H of order

n - 1, say V(H) = {v1, v2, ... , v"_ 1 I.Let A' be the adjacency matrix of H. Then there is a vector y e C0(H)

such that <y, y> = 1 and <A'y, y> = Amax(H). Let x = (Y1, Y2' . , y.-,, 0).Then x e C0(G), <x, x> = 1 and <Ax, x> = <A'y, y> = 1max(H) e V(A). Con-sequently Amax(G) Z Amax(H). The other inequality is proved analogously.

It is reasonable to expect that a graph with many automorphisms willhave particularly pleasing properties and that these will be reflected in theadjacency matrix. The automorphism group of a graph G is the group, Aut G,of permutations of the vertices preserving adjacency. Every abstract groupcan be represented as the automorphism group of some graph. For instance,if F is any finite group, consider its Cayley diagram with respect to someset of generators. The automorphism group of this coloured and directedmultigraph is exactly F. It only remains to replace each edge of this diagramby a suitable subgraph which bears the information previously given by thedirection and colour. This produces a graph G with automorphism groupisomorphic to F. An example is shown in Figure VIII.10.

Each it e Aut G induces an endomorphism of C0(G) which is describedby a permutation matrix P. In fact, an arbitrary permutation matrix Qcorresponds to an automorphism of G precisely when it commutes with the

Figure VIII.10. A graph with automorphism group S3, constructed from the Cayleydiagram in Figure VIII.1.

Page 169: Graph Theory-An Introductory Course-Bela Bollobas

158 VIII Graphs and Groups

adjacency matrix A, that is AQ = QA. The group of these matrices thereforefaithfully represents Aut G. Regarding A as an endomorphism of C0(G),we find that the eigenspaces of A are invariant under P. In particular, if aneigenvalue of A is simple (that is it has multiplicity 1) then P must map aneigenvector to a multiple of itself. Thus if all eigenvalues are simple, we musthave P2 = I. This is a strong restriction on those permutations which mightcorrespond to automorphisms of G. For example-, if G has at least 3 verticesand every eigenvalue is simple, then Aut G cannot be vertex-transitive, sonot every pair of vertices can be interchanged by an automorphism.

These remarks indicate how the methods of representation theory maybe used to deduce restrictions on the adjacency matrix of graphs which haveextensive automorphism groups. The lack of space prevents us from ex-ploring this further. Instead, we shall use algebraic methods to study graphswhich are highly regular although this regularity is not expressed in termsof the automorphism group.

Algebraic methods are particularly useful if we want to prove that certainregularity conditions cannot be satisfied except perhaps for a small set ofparameters. A problem of this type arose in Chapter IV: for which valuesof k is there a k-regular graph of order n = k2 + I and girth 5? We shallshow later that if there is such a graph then k is 2, 3, 7 or 57. Group theory isparticularly rich in problems of this type, especially because of the searchfor sporadic simple groups. Later on we shall mention some examples.

Regularity, that is the condition that all vertices have the same degree k,is not sufficiently restrictive. There: are too many k-regular graphs of ordern (provided k < n and kn is even) so we have to go considerably further tofind interesting classes. Call a connected graph G highly regular with col-lapsed adjacency matrix C = (c;) if for every vertex x E V = V(G) there is apartition of V into sets Vl = {x }, V2, ... , Vp such that each vertex y E V; isadjacent to exactly cij vertices in V (see Figure VIII.11). It is immediatefrom the definition that G is regular, say every vertex has degree k. In thiscase each column sum in the collapsed matrix is k. The collapsed adjacency

3

0 1 0 0

13 0 2 0

0 2 0 3

0 0 1 0

0 1

02)

3 0 102

Figure VIII.11. The pentagon, the cube and the Petersen graph together with collapsedadjacency matrices.

Page 170: Graph Theory-An Introductory Course-Bela Bollobas

§2 Applications of the Adjacency Matrix 159

matrix C can be obtained from the adjacency matrix A as follows:

ci, _ E as where v, c- Vj.17.E VI

The point is exactly that the above sum is independent of the representativev, of V,. We are especially interested in the collapsed adjacency matrix Cif it is of a much smaller size than A.

Consider a partition V, = {v,), V2, ... , V. belonging to the vertexx = v, . Let P be the p-dimensional complex vector space of formal sumsYD z; Vi, zi c- C, and let n: C0(G) -p P be the linear map given by

p

rz Exi

v) = E x) V, .

=1 i=1 vJEV

Of course, C can be considered to map P into itself.

Theorem 6.

(i) 7rA = C7r, that is 7r(Ax) = C(irx) for every x e C0(G).(ii) The adjacency matrix A and the collapsed adjacency matrix C have the

same minimal polynomial. In particular, .l. is an eigenvalue of A iff it is aroot of the characteristic polynomial of C.

PROOF. (i) Let us show that n(Av,) = C(rzv,), where v, is the basis vectorcorresponding to an arbitrary vertex v, E Vi. To do this it suffices to checkthat the ith coordinates of the two sides are equal. Clearly irv, = V, so

(n(Av,)), _ Y as,V,E Vi

and

(C(irv,)); = (CV)i = cij

and these are equal by definition.(ii) Let q be the minimal polynomial of C. In order to prove q(A) = 0,

by symmetry it suffices to check that (q(A)x), = 0 for every x. This is indeedso:

(q(A)x)t = (n(q(A)x))1 = (q(C)(nx))1 = (0)t = 0.

Conversely, the minimal polynomial of A annihilates C since 7rC0(G) = P.O

This result enables us to restrict rather severely the matrices C that mayarise as collapsed adjacency matrices.

Theorem 7. Let G be a connected highly regular graph of order n with collapsedadjacency matrix C. Let All A21 ... , A, be the roots of the characteristic

Page 171: Graph Theory-An Introductory Course-Bela Bollobas

160 VIII Graphs and Groups

polynomial of C different from k, the degree of the vertices of G. Then there arenatural numbers m1, m2, .... m, such that

Emi=n-1and

i=1

Y_ m;Ai = -k.i=1

PROOF. We know from Theorem 5 that A,, A2, ... , A, are the eigenvalues ofA in addition to k, which has multiplicity 1. Thus if m(2i) is the multiplicityof ,1i then

r

1+ ,m(A)=n,i=I

since C0(G) has an orthonormal basis consisting of eigenvectors of A.Furthermore, since the trace of A is 0 and a change of basis does not alterthe trace,

tr A = k ± E m(A1)A1 = 0.i=1

The condition expressed in Theorem 7 is not easily satisfied, especiallyif A 1 i A2 , ... , A, are not rational numbers, so it does rule out the possibilityof constructing many highly regular graphs with seemingly feasible param-eters. For the so-called strongly regular graphs we shall rewrite the conditionin a more attractive form. A graph G is said to be strongly regular withparameters (k, a, b) if it is k-regular, any two adjacent vertices have exactlya common neighbours and any two non-adjacent vertices have b z Icommon neighbours. In other words, G is highly regular with collapsedadjacency matrix

0 1 0

C= k a b

0 k-a-1 k-bTheorem 8. If there is a strongly regular graph of order n with parameters(k, a, b) then

m1, m2 =

are natural numbers.

1 n- (n- 1)(b-a)-2k2 {(a - b)2 + 4(k - b))I/2

PROOF. The characteristic polynomial of the collapsed adjacency matrixC is

x3+(b-a-k)x2+ ((a-b)k+b-k)x+k(k- b).

Page 172: Graph Theory-An Introductory Course-Bela Bollobas

§2 Applications of the Adjacency Matrix 161

On dividing by x - k, we find that the roots different from k are

4(k-b)}1/2}.

By theorem 7 there are natural numbers m1 and m2 satisfying

mt+m2=n-1and

mt).1 + m2).2 = -k.

Solving these for m1 and m2 we arrive at the assertion of the theorem.

Theorem 8 is sometimes called the rationality condition for stronglyregular graphs. It is also easily proved without invoking Theorem 7. Indeed,if A is the adjacency matrix of a strongly regular graph with parameter(n, k, a, b), then

1k ifi=j,(A2)1 = a if v; vj e E(G),

b otherwiseHence

A 2 = k1 + aA + b(J - I - A),

where J is the matrix all whose entries are 1. Therefore J is a quadraticpolynomial in A, so J and A are simultaneously diagonalizable. Notingthat J has only two eigenvalues: n, with multiplicity 1, and 0, with multi-plicity n - 1, one can easily find that Al and A2 are as above (cf. Exercise 28).

Now we shall use the rationality condition to fulfil our promise con-cerning Moore graphs of diameter 2 (or girth 5).

Theorem 9. Suppose there is a k-regular graph G of order n = k2 + 1 anddiameter 2. Then k = 2, 3, 7 or 57.

PROOF. We know from Theorem 1 of Chapter IV that G is strongly regularwith parameters (k, 0, 1). By the rationality condition at least one of thefollowing two conditions has to hold:

(i) (n - 1) - 2k = k2 - 2k = 0 and n - 1 = k2 is even,(ii) 1 + 4(k - 1) = 4k - 3 is a square, say 4k - 3 = s2.

Now if (i) holds then k = 2.If (ii) holds then k = 4(s2 + 3); on putting this into the expression for

the multiplicity m1 we find that

(s2 + 3)2 +[(s2 + 3)2/16] - [(s2

+ 3)/2]m

'1

12 I

116 s

that is

s5+sa+6s3-2s2+(9-32m1)s- 15=0.

Page 173: Graph Theory-An Introductory Course-Bela Bollobas

162 VIII Graphs and Groups

Hence s divides 15 so s is one of the values 1, 3, 5 and 15, giving k = 1, 3, 7or 57. The case k = I is clearly unrealizable.

It is worth noting that for k = 2, 3 and 7 there are unique k-regulargraphs of order k2 + I and diameter 2 (and so girth 5). In particular fork = 2 it is a pentagon and for k 3 it is the Petersen graph. However, it isnot known whether or not k = 57 can be realized.

Sporadic simple groups are those simple groups which do not belong toone of the infinite sequences consisting of cyclic groups of prime order,alternating groups of degree at least 5 and simple groups of Lie type. Aswe remarked earlier, sporadic simple groups are often connected to stronglyregular graphs. For example, there is a strongly regular graph with param-eters (162, 105, 81) and the Maclaughlin group of order 898 128 000 is asubgroup of index 2 of the automorphism group of this graph. Similarly,there is a strongly regular graph with parameters (416, 100, 96) and theSuzuki group, which is a simple group of order 448 345 497 600, is a sub-group of index 2 of the automorphism group of this graph.

§3 Enumeration and P61ya's Theorem

We cannot end the book without considering perhaps the most basic ques-tion about graphs, namely, how many of them are there? We may want tocount graphs with a given set of vertices or we may be interested in thenumber of isomorphism classes of certain graphs. As we saw in Chapter VII,counting labelled graphs is relatively easy, for instance there are 2t7t = 2"labelled graphs on n vertices, of which (') have m edges. Furthermore, byapplying Theorem 8 of Chapter I [ to the complete graph, one can easilyshow that there are nn-2 labelled trees of order n. This result was first ob-tained by Cayley; we present it here with a proof due to Priifer, which isindependent of Theorem 8 of Chapter II.

Theorem 10. There are n"- 2 trees on n labelled vertices.

PROOF. As in Chapter VII, let V = {1, 2, ... , n} be the set of vertices. Givena tree T, associate a code with 7' as follows. Remove the endvertex with thesmallest label and write down the label of the adjacent vertex. Repeat theprocess until only two vertices remain. The code obtained is a sequence oflength n - 2 consisting of some numbers from 1, 2,... , n; of course anynumber may occur several times in the code (see Figure VIII.12). As thereader should check, each of the n" "- 2 possible codes corresponds to a uniquetree.

Page 174: Graph Theory-An Introductory Course-Bela Bollobas

§3 Enumeration and P6lya's Theorem 163

10' 11'x'4Figure VIII.12. The Prefer code of this tree is (3, 8, 11, 8, 5, 8, 3, 5, 3).

It is easily seen that the label of a vertex of degree d occurs exactly d - 1times in the Prefer code of the tree. Thus the proof has the following con-sequence.

Corollary 11. Let d, 5 d2 5 < d be the degree sequence of a tree: d, >- 1and Y"=, d; = 2n - 2. Then the number of labelled trees of order n withdegree sequence (d3; is given by the multinomial coefficient

n-2d, - 1,d2 - 1,...,d - 1)' 0

The difficulties we encounter change entirely if we wish to count certaingraphs within isomorphism. Given graphs G, and G2 with a commonvertex set V, when are they isomorphic? They are isomorphic if there is apermutation n of V which maps G, onto G2. Of course, strictly speaking ndoes not act on graphs, it only induces a permutation a of X = V12), thepairs of vertices, and it is a that maps an edge of G, into an edge of G2 and anon-edge of G, into a non-edge of G2. Now G; is naturally identified with asubset of X or, equivalently, with a function f : X -+ {0, 11. Therefore G, isisomorphic to G2 if there is a permutation a of X = V(2) (coming from apermutation n of V) such that a*f, =12, where a* is the permutation of theset of functions {0, 1}X induced by a. Thus counting graphs within iso-morphism is a special case of the following problem. Given sets X and Y,and a group F acting on X, let IF act on the set of functions Yx in the naturalway. How many orbits are there in Yx? The main aim of this section is topresent a beautiful theorem of Polya that answers this question.

Let I' be a group of permutations acting on a (finite) set X. For x, y e Xput x - y if y = ax for some a e F. Then - is an equivalence relation onX ; if x - y we say that x is equivalent to y under F. The equivalence class ofx is called the r-orbit (or simply orbit) of x, and is denoted by [x]. Forx, y E X put

r(x, y) = {a e r: ax = y}.

Of course, F(x, y) is non-empty if [x] = [y], that is x and y belong to thesame orbit. r(x) = r(x, x) is the stabiliser of x; it is a subgroup of r. Notethat if y = fix then

r(x, y) _ {a: ax = y} _ {a: ax = fix} _ {a: fl-'a a r(x)} _ fr(x),

Page 175: Graph Theory-An Introductory Course-Bela Bollobas

164 VIII Graphs and Groups

so I'(x, y) is a coset of F(x). We see that I F(x) I depends on the equivalenceclass of x, so we may put s([x]) = F(x) 1. Clearly

IF = U r(x, y),VE [x]

and this gives us

1171 = 1 [x] I l r(x) I= I [x] I S([x])

The theorem mentioned in the title of this section is based on a versionof a lemma due to Burnside concerning the sum of the "weights" of orbits.Let 01, . . . , 0, be the I'-orbits, let .4 be an arbitrary Abelian group (writtenadditively) and let w: X -+ A be a function that is constant on orbits. Wecall w a weight function and define the weight of O, by w(O,) = w(x), x e O,.For a permutation a e IF we denote by F(a) the set of elements fixed by a,that is F(a) = {x e X: ax = x}. Thus x e F(a) iff a e F(x).

Lemma 12.1 IF I J = 1 w(0i) = Za F LxE F(a) w(x).

PROOF.

Y_ Y_ w(x) = E Y_ WW = Y_ Y_ Y_ w(x)aErxEF(a) xEXaEr(x) i=-1 xEO;aeFix)

i_ w(0i) E E 1= i w(0) I o, I s(o,) = I r 1 i w(oi).i=1 XEo; i=1 i=1

The original form of Burnside's lemma is obtained on choosing A = 1and w = 1:

N(f) = 1 Y Y 1= 1 Y I F(a)IrIwhere N(r) = I is the number of orbits.

We shall illustrate by two very simple examples, that even Burnside'slemma can be used to calculate the number of equivalence classes of certainobjects.

EXAMPLE 1. Let X = (1, 2, 3, 4) and I = {1, (12), (34), (12)(34)}. What isN(r)? Clearly F(l) = {1, 2, 3, 41,, F((12)) = {3, 4), F((34)) = {1, 2} andF((12)(34)) = 0. Thus N(F) = 1,{4 + 2 + 2 + 01 = 2.

EXAMPLE 2. Consider all bracelets made up of 5 beads. The beads can be red,blue and green, and two bracelets are considered to be identical if one canbe obtained from the other by rotation. (Reflections are not allowed!) Howmany distinct bracelets are there?

Page 176: Graph Theory-An Introductory Course-Bela Bollobas

§3 Enumeration and P61ya's Theorem 165

In this case we choose X to be the set of all 35 = 243 bracelets and let rbe C5, the cyclic group of order 5, acting on X. Then the question is: howmany orbits does F' have? For the identity 1 e IF clearly F(1) = X. Forevery non-trivial rotation a e r only the 3 monochromatic bracelets areinvariant under a, so N(F) = 1{243 + 3 + 3 + 3 + 3} = 51.

The second example resembles a little the problem we really want totackle. Let F' be a group of permutations of a (finite) set D. Let R be another(finite) set and let us consider the set RD of all functions from D into R. Eacha e F can be made to act on R'; namely define a*: R' - R° by

(a*f)(d) = f(ad), feR',deD.Then

F* = {a*: a e F'}

is a group of permutations of RD; as an abstract group, it is isomorphic tor and we distinguish it from r only to emphasize that it acts on R° whileF acts on D.

As customary in connection with Pblya's theorem, we adopt an intuitiveterminology. D is called the domain and its elements are places, R is therange and its elements are figures, the functions in R° are called configura-tions, finally a pattern is an equivalence class of configurations under r*,that is a F'*-orbit. Our main aim is to calculate the number of distinct pat-terns.

The origin of this terminology is that a function f e R' is an arrangementof some figures into the places in such a way that for each place there isexactly one figure in that place, but each figure can be put into as manyplaces as we like. Two configurations mapped into each other by an elementof r* have the same pattern and are not distinguished. Thus in the secondexample the places are, say, 1, 2, 3, 4 and 5, the figures are r, b and g (for red,blue and green) and a configuration is a sequence of the type g, b, b, r, b, thatis a bracelet. The group r is generated by (12345) and distinct patternscorrespond to distinguishable bracelets.

In addition to counting the number of distinct patterns, we may wish tocount the number of patterns of a certain type. It turns out that all theseproblems can be solved at once, provided we learn enough about the cyclestructure of permutations in r acting on D, and are willing to store muchinformation about the patterns.

Each element a e F is an essentially unique product of disjoint cycles(cyclic permutations) acting on D. If a = 1 2 ... ,, is such a product, wesay that t, ... , c,,, are the cycles of a. In the product we include cycles oflength 1 as well so that every a e D appears in exactly one cycle; if I l; I denotesthe number of elements in then'"=1 I k I = d, where d = I D I is the numberof elements in D. Denote by jk(a) the number of cycles of a having length k;by the previous equality V'" ,1 kjk(a) = d. Note that I F(a) I, appearing inBurnside's lemma, is exactly j1(a), the number of elements of D fixed by a.

Page 177: Graph Theory-An Introductory Course-Bela Bollobas

166

We define the cycle sum of F to bed

Y_ H lk(a)k= t

VIII Graphs and Groups

where, as before d = I D 1. The reader should bear in mind that 2 depends onthe action of IF on D, not only on the abstract group r. Note also that thecycle sum is a polynomial in a,, a2, ... , ad with integer coefficients; it tellsus the distribution of cycles in the elements of r. When writing down a cyclesum, it is useful to remember that Yk=, kjk(a) = d for every a. The customarycycle index of r is Z(r; a,, ... , ad) = (1/I r I)2(r; a1,... , ad). As we shallconsider general rings instead of the more usual polynomial ring with ra-tional coefficients, we have to use the cycle sum since we cannot divideby Iri.

Let A be an arbitrary commutative ring and let w: R -+ A be a function.We call w(r) the weight of the figure r, and for k = 1, 2,... define the kthfigure sum as

sk = Y w(r)k.rER

Furthermore, the weight of a configuration f c- R' is

w(f) = fl w(f (a)).

Clearly any two configurations equivalent under r* have the same weight,so we may define the weight of a pattern 0, by

w(0,) = w(f ), f e Oi.

Our aim is to learn about the pattern sum

O,),S = i w(

where 01, 02, ... , 0, are the r*-orbits, that is the distinct patterns.Note that w(r), w(f ), sk and S are all elements of our commutative ring

A. If we have a way of determining the pattern sum S, it is up to us to chooseA and the weight function w: R -- .4 in such a way that S can be "decoded"to tell us all we want to know about various sets of patterns. In practice onealways chooses A to be a polynomial ring (7L[x], Q[x, y], etc.), and usuallyw(r) is a monic polynomial; the information we look for is then given bycertain coefficients of the polynomial S. We shall give several examplesafter the proof of our main result, Polya's enumeration theorem.

Theorem 13. (Polya's enumeration theorem)

Iris = 2(r;s,,s2i...,se).

Page 178: Graph Theory-An Introductory Course-Bela Bollobas

§3 Enumeration and P61ya's Theorem

PROOF. By Lemma 12

Iris = lri± <0) = E E w(f).i= 1 aer feF(a*)

167

Now clearly F(a*) = { f c- RI: f is constant on cycles of a}, so if c1, 21 ... , mare the cycles of a and a e i means that a is an element of the cycle , then

F((x*)={fER':riER and f(a)=ri if

Hencea)m d d

) = sJk(a)I

H ( Y w(r)kjk(

= 1 1Y w(f w(ri)= 1 k=1 reR k=feF(a*) (r;)CR i 1

givingd

iris = Y fl skk() _ 2(r; s1, s2, ... , Se).aerk=l

If I r I has an inverse in the ring A, say if A is a polynomial ring over therationals, then Theorem 13 can also be written in its more usual form:

s = z(r; s, S2, ... , Sd.

Let us illustrate now how the theorem can be applied.

EXAMPLE 3. Let us consider again the bracelets made up of five beads, whichcan be red, blue and green. Then D = 11, 2, 3, 4, 5} is the set of places of thebeads, R = {r, b, g} is the set of colours (figures) and IF is C51 the cyclicgroup of order 5 generated by the permutation (12345). The cycle sum is

= ai + 4a5. On choosing A = 7 and w(r) = w(b) = w(g) = 1, we findthat sk = 3 for every k, so 5S = 35 + 4.3. Since each pattern (bracelet) hasweight 1, there are #{35 + 12} = 51 distinct patterns (bracelets).

On choosing A = 7L[x, y] and w(r) = 1, w(b) = x, w(g) = y, we find thatS = J{(1 + x + y)5 + 4(1 + x5 + y5)}. Now it is easy to extract muchinformation from this form of S. For example, a bracelet has weight xy2 ifit has 2 red, 1 blue and 2 green beads. Thus the number of such bracelets isthe coefficient of xy2 in the polynomial S, that is (1/5)(5!/2!2!) = 6.

EXAMPLE 4. What happens if in the previous example we allow reflections?Then r is the dihedral group D5, the group of symmetries of the regularpentagon, whose cycle sum is a; + 4a5 + 5a1a2. Thus if we take, as before,A = 7L[x, y], w(r) = 1, w(b) = x and w(g) = y, we find that the number ofbracelets containing 2 red, l blue and 2 green beads is the coefficient of xy2 inlU{(1 + x + y)5 + 4(1 + x5 + y5) + 5(1 + x + y)(1 + x2 + y2)2}, thatis,3+1=4.

Page 179: Graph Theory-An Introductory Course-Bela Bollobas

168 VIII Graphs and Groups

EXAMPLE 5. This is the example P51ya used to illustrate his theorem. Place3 red, 2 blue and 1 yellow balls in the 6 vertices of an octahedron. In howmany distinct ways can this be done? The group of symmetries of the octa-hedron has cycle sum a; + 6a; a4 + 3ai a22 2+ 6a3 + 8a3 : a; comes fromthe identity, 6ai a4 from rotations through n about axes through the vertices,6a2 from rotations through it about axes through midpoints of edges, and,finally, a3 is the summand corresponding to a rotation through 2n/3 aboutan axis going through the centre of a face. On taking A = 7L[x, y], w(r) = 1,w(b) = x and w(y) = y, we see that the required number is the coefficient ofx2y in

{(1+x+y)6+6(1+x+y)2(1 +x4+y4)+ 3(1 + x + y)2(1 + x2 + y2)2 + 6(1 + x2 + y2)3 + 8(1 + x3 + y3)2},

that is, 3.

It should be clear by now that the theorem loses nothing from its general-ity if instead of a general commutative ring A we take 7L[x,: r e R], the poly-nomial ring over the integers in variables with the elements of R, and wedefine the weight function as w(r) x,. Then the pattern sum S contains allthe information the theorem can ever give us. In particular, if w: R -+ A isan arbitrary weight function then the corresponding pattern sum is obtainedby replacing x, by w(r) in S. However, if R is large, the calculations may getout of hand if we do not choose a "smaller" ring than 7L[x,: r e R], which istailor-made for the problem at hand. The choice of a smaller ring is, ofcourse, equivalent to a substitution into S.

EXAMPLE 6. Place red, blue, green and yellow balls into the vertices of anoctahedron. Denote by P; the set of patterns in which the total number ofred and blue balls is congruent to i modulo 4. What is I Po I - I P2 I ?

The cycle sum of the rotation group of the octahedron was calculated inExample 5 and was found to be 16 + 6a2a4 + 3a2a2 + 6a2 + 8a3.

Let A = C, the field of complex numbers, and put w(r) = w(b) = i,w(g) = w(y) = 1. Then for a pattern f we have Re w(f) = 1 if, f e Po, Re w(f)-1 if f e P2 and Re w(f) = 0 if f e P, U P3. Thus I Po I - 1 P2 1 is exactlythe real part of the pattern sum. As s, = 2(1 + 1), s2 = 0, s3 = 2(1 - i) ands4 = 4, we see immediately that after substitution the real part of each termis 0, SO 1P01 = I P21

We were first led to our study of the orbits of a permutation group byour desire to count the number of graphs within isomorphism. We realizedthat this amounted to counting the orbits of the group F,*, acting on 10, 1 }x,where X = V(2) and r, is the permutation group acting on X which is in-duced by the symmetric group acting on V. So according to Polya's theoremour problem is solved when we know the cycle sum of the permutation groupI',,. It is now a routine matter to write down an explicit expression for this

Page 180: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 169

cycle sum, though we don't display it here since its form is not very in-spiring. Furthermore, except for small values of n it is too unwieldy forpractical calculations and it is much easier to use asymptotic formulaederived by random graph techniques (see Exercises 22 and 23 of ChapterVII).

We remark finally that an extension of P61ya's theorem covers the casewhen there is also a group acting on the range of the functions. For instance,if we let S2 act on {0, 1) in the example above, we do not distinguish betweena graph and its complement, and may thereby compute the number of graphswhich are isomorphic to their complements.

EXERCISES

1. Draw the Cayley diagram of the quaternion group <a, b I a2 = b2 = (ab)2).

2. Find the orders of <a, bla3 = b3 = 1, ab = ba), <a, bIa4 = b3 = 1, ab = ba) and<a,bIa3 = b4 = (ab)2 = 1).

3. Use Euler's formula and information about the Cayley diagram to deduce thatin the group <a, b, c I as = b3 = c2 = (abc) -') we have a61 ° = 1.

4. Verify that the Cayley diagram associated with the trefoil knot is the diagramdescribed in Figure VIII.5.

5. Write down presentations of the knots shown in Figure VIII.13. Show that thegroup of the quinquefoil is isomorphic to < f, gI fs = g2) and the group of thetweeny is <a, blababa-'b-'a' babab-'a-'b'')

Figure V111.13. The quinquefoil and the tweeny.

6. Prove that no two of the groups of the knots shown in Figures V111.4 and VIIJ.13are isomorphic.

7. A closed orientable surface of genus 2 is obtained by identifying pairs of non-adjacent sides of an octagon, say as in Figure VIII.14. The fundamental grouphas a presentation <a1, a2, a3, a4l a,a 'a4a1 1a3a2a4 'a3'). Show that the Cayleydiagram is a tessellation of the hyperbolic plane. Deduce that any non-emptyreduced word W equal to 1 must contain a subword of length at least 5 which ispart of the cyclically written relator or its inverse. (A reduced word is one in whichno generator occurs next to its inverse.) [Hint. Consider the part of the walk Wfurthest from 1.]

Page 181: Graph Theory-An Introductory Course-Bela Bollobas

170 VIII Graphs and Groups

a4 a4

Figure VII1.14. An orientable surface of genus 2.

8. Show that the dihedral group D", the group of symmetries of a regular n-gon,has a presentation of the form (a, b lam = b2 = (ab)2 = 1). What is its Cayleydiagram?

9. Give a group whose Cayley diagram is the truncated cube having 8 triangular and6 octagonal faces.

10. Draw the Cayley diagram of (i) <a, blab = ba) in the Euclidean plane, (ii)(a, b I b", ab = ba) on an infinite cylinder, (iii) <a, b I d" = b" = 1, ab = ba) on atorus, (iv) <a, b, cla' = b' = c4 = abc = 1) in the hyperbolic plane.

11. Check the examples of Cayley diagrams illustrated in Figure VIII.3 and proveTheorem 1.

12.- Let A = <a, bla3 = b' = (ba)2 = 1) and B = <b>. What is the Schreier diagramof A mod B?

13.- A group A is generated by a, b and c, the Schreier diagram of A modulo a subgroupB is shown in Figure VIII.15. Read off a set of generators of B.

Figure VIII.15. The Schreier diagram of A mod B.

14. Let A be the free group on a, b and c, and let B be the subgroup consisting of allsquares. What is the Schreier diagram of A mod B? Find a set of free generatorsfor B.

15. How many subgroups of index 2 are there in a free group of rank k?

16. How many subgroups of index n are there in a free group on 2 generators?

Page 182: Graph Theory-An Introductory Course-Bela Bollobas

Exercises 171

17. Show that a subgroup B of a finitely generated free group F is of finite index in Fif B is finitely generated and there is a natural number n for which W" e B forevery word W.

18. What is the automorphism group of the Petersen graph (shown in Figure V111. 11)?Find the automorphism group of the Kneser graph KIV, where s Z 2r + I (seep. 99). Deduce that the automorphism group of K?i±1 is 3-arc-transitive, thatis any path of length 3 can be mapped into any other path of length 3 by an auto-morphism.

19. The Tutte 8-cage has vertices n1, n3, n5 for n = 1, 2, ... , 10, with edges joiningn5 to n, and n3, and n; to m; if In - ml _ ±i (mod 10). Show that the auto-morphism group of the Tutte 8-cage is 5-arc-transitive.

20. Find the automorphism group of the Grotzsch graph (see p. 99).

21. Does every tree have an Abelian automorphism group?

22. Construct a non-trivial tree with trivial automorphism group.

23. Let f (n) be the minimal size of a graph of order n with trivial automorphism group.Prove that f (n) < n for every n 7 and f (n)/n -+ 1 as n -+ cc.

24. Show that if it e Aut G has k odd cycles and I even cycles then G has at mostk + 21 simple eigenvalues.

25. Show that a connected graph G of odd order whose automorphism group isvertex transitive has exactly one simple eigenvalue.

26.- Let A be the adjacency matrix of a graph G. Show that (A');j is the number ofvi-v; walks of length 1.

27. Given k Z 2, po(x), p1(x), ... be polynomials defined by po(x) = 1, p,(x) = x,p2(x) = x2 - k and

P,(x) = xP,-,(x) - (k - 1)P,-2(x) I Z 3.

Show that if A is the adjacency matrix of a k-regular graph then (p,(A));; is thenumber of vi -vi walks of length l in which any two consecutive edges are distinct.

28. Complete the details of the second proof of Theorem 8, as suggested on p. 161.

29. Prove that the matrix J (all of whose entries are 1) is a polynomial in the adjacencymatrix A if G is regular and connected.

30. Combine Theorem 5(vi) and Theorem 1 of Chapter V to deduce that X(G) 5Zmu(G) + 1.

31. Let f,(x) = D.0 CkX"-k be the characteristic polynomial of (the adjacencymatrix of) a graph G. Show that co = 1, c1 = 0, c2 = -e(G) and -c3 is twicethe number of triangles in G.

32. Let fG(x) be the characteristic polynomial of G. Show that if e = xy is a bridgeof G then

G(X) = fc-e(x) - fG-(,.,}(X).

Page 183: Graph Theory-An Introductory Course-Bela Bollobas

172 VIII Graphs and Groups

Now let F be a forest with 2n vertices and denote by dk the number of k-elementsets of independent edges. [Thus d" is the number of 1-factors.] Prove that

fc(x) = x2" - d,xn-2 + d2x2"-4 + (-1)"d".

What are the possible values for d"?

33. Let G be a connected k-regular graph containing an odd cycle. At time 0 put acounter on a vertex. For each counter that is on a vertex x at time t, place a counteron every vertex adjacent to x at time t + 1 and remove the counters from t. Showthat n,(x)/k` tends to a limit as t - oo, where n,(x) is the number of counters onx at time t. What is the corresponding assertion if the counters are not removedfrom the vertices? [Hint. There is an orthonormal basis consisting of the eigen-vectors of the adjacency matrix.]

34. A k-regular graph G of order n is such that any two non-adjacent vertices can bemapped into any other such two by some automorphism of G. Show that G isstrongly regular. What are the eigenvalues of G? What is the condition that kand n have to satisfy?

35. Let C be the collapsed adjacency matrix of a highly regular graph. Show that(C')11 is the number of walks of length l from a vertex to itself. Interpret the otherentries of C.

36. Why must the collapsed adjacency matrix of the Petersen graph, as shown inFigure VIII. 11, have rational eigenvalues?

37. In the graph G every two adjacent vertices have exactly one common neighbourand every two non-adjacent vertices have exactly two common neighbours.Show that G is regular of degree 2k and has order 2k2 + 1, for some k in(1, 2, 7, 11, 56, 497}.

38. Let G be a strongly regular graph of order 100 with parameters (k, 0, b). What arethe possible values of k? Find the eigenvalues when k = 22.

39. Make use of the result of Exercise 19 to calculate the eigenvalues of the Tutte8-cage.

40. Give detailed proofs of Theorem 10 and Corollary 11.

41. Prove that the number of trees with n - 1 > 2 labelled edges is n"- 3.

42. Show that a given vertex has degree 1 in about 1/e of all labelled trees, wheree = 2.71828 .... (Cf. Exercise 7 in Chapter VII.)

43. Denote by R(n, k) the number of trees with n distinguishable vertices of whichexactly k have degree 1. Prove that

k- R(n, k) = (n - k)R(n - 1, k - 1) + kR(n - 1, k).n

44. Prove that there are

(m) n - 1 l+A!1 i (-1j m+jm! 1=o

Page 184: Graph Theory-An Introductory Course-Bela Bollobas

Notes 173

acyclic graphs on n distinguishable vertices having n - m edges. Deduce that thereare 4(n - 1)(n + 6)nn-4 forests with two components.

45. Show that the cycle sum of the symmetric group S. acting on the usual n letters is

Y nk'k

a'ai:2... aimH"

lk=1

j4i

where the summation is over all partitionsjl + 2j2 + + nj = n.

46. What is the cycle sum of S. acting on the unordered pairs of 5 elements? Howmany non-isomorphic graphs are there on 5 vertices? How many of them have5 edges?

47. Let Z(f ; a1, a2, ..., ad) be the cycle index of a permutation group F acting on a setD. Consider the action of r on the set of all k-subsets of D. How many orbits arethere?

48. Determine the cycle index of the rotations of the cube acting on (i) the vertices,(ii) the edges, (iii) the faces, (iv) the faces and vertices. In how many distinct wayscan you colour the vertices using some of n colours? The edges? The faces? Thevertices and faces?

49. Show that the cycle sum of C,,, the cyclic group of order n, is 2(C.; a1..... a.)=D, 0(k)a4"14, where ¢(k) is the Euler function.

50. Prove that the cycle index of the dihedral group D. (cf. Exercise 8) is

1w- lug if n is odd,Z(D.;a1....,a2.)=iZ(C

}alai}(an2l2 + a;aT-Z)i2) if n is even.

How many bracelets are there with 20 beads coloured red, blue and green?

51. How many distinct ways are there of colouring the faces of a dodecahedronwith red, blue and green, using each colour at least once?

Notes

There is a vast literature concerned with group presentations, includingthe use of Cayley and Schreier diagrams. The basic book is perhaps W.Magnus, A. Karrass and D. Solitar, Combinatorial Group Theory, SecondEdition, Dover, New York, 1976; the connections with geometry areemphasized in H. S. M. Coxeter, Regular Complex Polytopes, CambridgeUniversity Press, New York, 1974. Numerous articles deal with the com-putational aspect, in particular J. A. Todd and H. S. M. Coxeter, A practicalmethod for enumerating cosets of a finite abstract group, Proc. EdinburghMath. Soc. (2) 5 (1936) 26-34, which was the first paper in this line and J.Leech, Computer proof of relations in groups, in Topics in Group Theoryand Computation (M. P. J. Curran, ed.), Academic Press, New York, 1977,in which some more recent developments are described.

Page 185: Graph Theory-An Introductory Course-Bela Bollobas

174 VIII Graphs and Groups

Max Dehn posed the word problem in Ober unendliche diskontinuier-liche Gruppen, Math. Ann. 71 (1911) 116-144, and gave the above discussedpresentation of the group of the trefoil in Ober die Topologie des dreidimen-sionalen Raumes, Math. Ann. 69 (1910) 137-168. The word problem wasshown to be intrisically connected to logic by P. S. Novikov, On the algo-rithmic unsolvability of the word problem, Amer. Math. Soc. Transl. (2) 9(1958) 1-22 and G. Higman, Subgroups of finitely presented groups,Proc. Royal Soc. A, 262 (1961) 455-475. For the properties of knots andtheir groups the reader is referred to R. H. Crowell and R. H. Fox, Intro-duction to Knot Theory, Graduate Texts in Mathematics, Vol. 57, Springer-Verlag, New York, 1977.

An exposition of matrix methods in graph theory can be found in N. Biggs,Algebraic Graph Theory, Cambridge University Press, New York, 1974.The first striking result obtained in this way, Theorem 9, is due to A. J.Hoffman and R. R. Singleton, On Moore graphs with diameters 2 and 3,IBM J. Res. Dev. 4 (1960) 497-504. The connection between graphs andsporadic simple groups is discussed in detail in R. Brauer and C. H. Sah(editors), Theory of Finite Groups: a Symposium, Benjamin, Menlo Park,1969. Since then however several more sporadic groups have been found.

The fundamental enumeration theorem of G. Pdlya appeared in Kom-binatorische Anzahlbestimmungen fur Gruppen and chemische Verbin-dungen, Acta Math. 68 (1937) 145--254. Many enumeration techniques wereanticipated by J. H. Redfield, The theory of group-reduced distributions,Amer. J. Math. 49 (1927) 433-455. The standard reference book for Polya-type enumeration is F. Harary and E. M. Palmer, Graphical Enumeration,Academic Press, New York, 1973.

Page 186: Graph Theory-An Introductory Course-Bela Bollobas

Subject Index

Acyclic graph 5Adjacency matrix 38, 155Adjacent 1

Almost every 130Amount of flow 45Antichain 57Automorphism group 157

Bipartite graph 5Block 51

Block-cutvertex graph 51

Bridge 5Broken cycle 99Burnside's lemma 164

Capacity 46Cayley diagram 146Chain 57Charge 98Chord 37, 154Chromatic number 88Chromatic polynomial 92Circulation 62Clique number 86, 137Closed trail 4Cocycle space 36Collapsed adjacency matrix 158Colouring 88Complete graph 3

Complete matching 54Complete r-partite graph 5Component 4, 50Conductance 29Configuration 97, 165Conjugacy problem 148Connected graph 4, 50Connection in parallel 29Connection in series 29Connectivity 50Convex property 133Country 17Cover 86Cubic graph 3Current 27, 45Cut 36

space 36vector 36

Cutvertex 5

Cycle 4space 36sum 166

Cycles of a permutation 165Cyclomatic number 37

Defining relation 148Degree sequence 3Dehn's problems 148Density 84Diameter 8

175

Page 187: Graph Theory-An Introductory Course-Bela Bollobas

176

Dihedral group 167Directed graph 5

Directed multigraph 5

Discharging 97Distance 4Domain 165

Economical spanning tree 9Edge 1

chromatic number 89space 35

Eigenvalue 156Electrical current 26Empty graph 3

Endblock 51

Endvertex 1, 4Euler circuit 13Eulerian graph 14Euler's formula 17Euler trail 13

Even cycle 4Extremal graph 67

Face 17Factor 45, 58Fan 63Figure 165

sum 166Filter 118Flow 45Forbidden subgraph problem 67Forest 5

Four colour problem 97Free group 148Fundamental cut 37

vector 37Fundamental cycle 37

vector 37

Girth 18, 68Graph I

Graphic sequence 65Greedy algorithm 89Grotzsch graph 99

Hadwiger's conjecture 97, 100Hajos operation 102Hamilton cycle 12Hamiltonian graph 12Hamilton path 12Handshaking lemma 4Heawood's conjecture 96

Highly regular graph 158Hypergraph 5

Subject Index

Incidence matrix 38Incident I

Independent paths 51

Independent vertices, edges, paths 4Induced subgraph 2Initial vertex 4Integrality theorem 48Isolated vertex 3

Isomorphic graphs 3

Isomorphism problem 148

Join 5

k-chromatic graph 89k-connected graph 50k-edge-connected graph 50Kempe chain 97Kirchhoff's laws 27Kneser graph 99Knot 150

Latin rectangle 64Length 4Line graph 63

Loop 5

Map 96Matching 54Max-flow min-cut theoremMaximum degree 3

Method of Heesch 97Minimum degree 3

Monochromatic set 105Monotone class of graphsMoore graph 69, 161Multigraph 5

Multiple edge 5

47

75

Neighbouring 1

countries 17

Odd component 59Odd cycle 4Ohm's law 26Orbit 163Order of a graph 2Oriented graph 6

Partially ordered set 57

Partition calculus 119

Page 188: Graph Theory-An Introductory Course-Bela Bollobas

Subject Index

Path, xo-path 4, 79Pattern 165

sum 166Perfect squared square 33Petersen graph 99Planar graph 16Plane graph 16Polynomial identity 20Potential difference 26Presentation of groups 148Principle of superposition 28Problem of Zarankiewicz 73Projective plane 75

Radius 8Ramsey set 111

Randomly Eulerian 15, 24Range 165Rationality condition 161Realization of a graph 16Reducible configuration 97Regular graph 3

Reidemeister-Schreier rewriting process154

Relator 148Resistance 26r-partite graph 5

Schreier diagram 147Schreier system 154Set of distinct representatives 54Shadow 58Simple transform 79Sink 28, 45Size of a graph 2Source 28, 45

Spanned subgraph 2

Spanning subgraph 2

Standard basis 35Star-delta transformation 30Stochastic matrix 63Strongly regular graph 160Subdivision 16Subgraph 2

Tait's conjecture 101Terminal vertex 4Theorem of

Amitsur and Levitzki 20Appel and Haken 97Bollobas and Erdos 80, 82Bondy and Chvatal 87Brooks 91Dehn 35

177

Dilworth 57Dirac 87Erdos 87Erdos and Stone 68, 80Gallai 102Galvin and Prikry 116Graham, Leeb and Rothschild 113Hajos 102Hales and Jewett 113Hall 54Hindman 117Korshunov 144Kuratowski 19Lovasz 102Menger 52Nielsen and Schreier 155Petersen 64Pblya 166Posy 139Rado 115Ramsey 105Ringel and Youngs 96Smith 87Schroderand Bernstein 64

Thomason 87

Turan 72Tutte 58Tychonov 64van der Waerden 113

Topological graph 16Total resistance 28Tournament 23Trail 4Transform 79Travelling salesman problem 11

Tree 5

Trefoil knot 151Trivial graph 3

Ultrafilter 118Unavoidable configuration 97Upper density 84

Value of flow 45Vertex 1

space 35,155

Walk 4Weight 155

function 164

of a configuration 166Word 148

problem 148

Page 189: Graph Theory-An Introductory Course-Bela Bollobas
Page 190: Graph Theory-An Introductory Course-Bela Bollobas

Index of Symbols

ab directed edge 5A = A(G) adjacency matrix 38Aut G automorphism group

157be (G) block-cutvertex graph

51B = B(G) incidence matrix 38c(x, y) capacity 46C0(G) vertex space 35, 155C,(G) edge space 35cl(G) clique number 86C' cycle of length 1 4diam G diameter 8d(x) = d0(x) degree 3

d(x, y) distance 4e = e(G) size of a graph 2E = E(G) edge set 2E" empty graph 3

ex(n; F) extremal size 67, 71

G + HG u Hjk(a)

join 5

union 5

cycles of length k165

K" complete graph 3

K(p, q) = KC.1 complete bipartitegraph 5

K(n I ... , n,) complete r-partitegraph 5

K,(t) complete r-partitegraph 5

[m, n] thesetm,m+ 1,...,n113

M(W) countably infinitesubsets 116

finite subsets 117N number of orbits 164o(x), O(x) Landau's notation

F(a) fixed elements 164 [1, k]G graph 1

IGI order of a graph 2G - E' deletion of edges 2G[V'] spanned subgraphG - W deletion of verticesG + xy joining x toy 2G" graph of order n 2G(n, m) graph of order n and

size m 2G2(m, n) bipartite graph 73G = H isomorphic graphs

134the set 1,2,...,k

110

pH(x) chromatic polynomial92

2 P' path of length 1 42 9(V) power set 5

q(H)

rad GR(G)

number of oddcomponents 59radius of G 8realization of G 6

t,_ ,(n) size of a Turin graph3 71

179

Page 191: Graph Theory-An Introductory Course-Bela Bollobas

180

T,_ i(n) Turin graph 71

TG topological graph 162M power set 116U(G) cocycle space 36V = V(G) vertex set I

v(f) value of a flow 45w(f), w(r), w(0;) weights 166X(') set of r-tuples 105LzJ greatest integer :5z

62

[z] least integer a z 62z(m, n; s, t) Zarankiewicz number

73Z(G) cycle space 36Z(f'; a...... ad) cycle index 166

Index of Symbols

2(r; a,.., aa) cycle sum 166fla(G) independence number

23

F(x) = rG(x) vertices adjacent to x3

S(G) minimum degree 3

A(G) maximum degree 3

K(G) connectivity 50

A(G) edge-connectivity 50X(G) chromatic number

88

X '(G) edge-chromaticnumber 88

XY chromatic number ofsurface 95

Page 192: Graph Theory-An Introductory Course-Bela Bollobas

Graduate Texts in Mathematics

continued from page ii

65 WELLS. Differential Analysis on ComplexManifolds. 2nd ed.

94 WARNER. Foundations of DifferentiableManifolds and Lie Groups.

66 WATERHOUSE. Introduction to Affine Group 95 SHIRYAYEV. Probability.

Schemes. 96 CONWAY. A Course in Functional Analysis.67 SERRE. Local Fields. 2nd ed.68 WEIDMANN. Linear Operators in Hilbert

Spaces.97 KoBLITZ. Introduction to Elliptic Curves and

Modular Forms. 2nd ed.69 LANG. Cyclotomic Fields 11. 98 BROCKERIToM DIECK. Representations of70 MASSEY. Singular Homology Theory. Compact Lie Groups.71 FARKAS/KRA. Riemann Surfaces. 2nd ed. 99 GROVE/BENSON. Finite Reflection Groups.72 STILLWELL. Classical Topology and 2nd ed.

Combinatorial Group Theory. 2nd ed. 100 BERG/CHRISTENSEN/RESSEL. Harmonic

73 HUNGERFORD. Algebra. Analysis on Semigroups: Theory of Positive74 DAVENPORT. Multiplicative Number Theory. Definite and Related Functions.

2nd ed. 101 EDWARDS. Galois Theory.75 HOCHSCHILD. Basic Theory of Algebraic

Groups and Lie Algebras.102 VARADARAJAN. Lie Groups, Lie Algebras and

Their Representations.76 IITAKA. Algebraic Geometry. 103 LANG. Complex Analysis. 3rd ed.77 HECKE. Lectures on the Theory of Algebraic

Numbers.104 DuBRovIN/FoMENKO/NovwKOv. Modem

Geometry--Methods and Applications. Part78 BURRIS/SANKAPPANAVAR. A Course in 11.

Universal Algebra. 105 LANG. SL2(R).79 WALTERS. An Introduction to Ergodic

Theory.106 SILVERMAN. The Arithmetic of Elliptic

Curves.80 ROBINSON. A Course in the Theory of

Groups.107 OLVER. Applications of Lie Groups to

Differential Equations. 2nd ed.81 FORSTER. Lectures on Riemann Surfaces. 108 RANGE. Holomorphic Functions and Integral82 Borr/Tu. Differential Forms in Algebraic

Topology.Representations in Several ComplexVariables.

83 WASHINGTON. Introduction to CyclotomicFields.

109 LEHTO. Univalent Functions and TeichmullerSpaces.

84 IRELAND/ROSEN. A Classical Introduction to 110 LANG. Algebraic Number Theory.Modem Number Theory. 2nd ed. 111 HUSEMOLLER. Elliptic Curves.

85 EDWARDS. Fourier Series. Vol. H. 2nd ed. 112 LANG. Elliptic Functions.86 VAN LINT. Introduction to Coding Theory.

2nd ed.113 KARATZAS/SHREVE. Brownian Motion and

Stochastic Calculus. 2nd ed.87 BROWN. Cohomology of Groups. 114 KoBLrtz. A Course in Number Theory and88 PIERCE. Associative Algebras. Cryptography. 2nd ed.89 LANG. Introduction to Algebraic and Abelian

Functions. 2nd ed.115 BERGER/GosTIAux. Differential Geometry:

Manifolds, Curves, and Surfaces.90 BRONDSTED. An Introduction to Convex

Polytopes.116 KELLEY/SRINIVASAN. Measure and Integral.

Vol. 1.

91 BEARDON. On the Geometry of Discrete 117 SERRE. Algebraic Groups and Class Fields.

Groups. 118 PEDERSEN. Analysis Now.92 DIESTEL. Sequences and Series in Banach

Spaces.119 RoTMAN. An Introduction to Algebraic

Topology.93 DUBROVIN/FOMENKG/NOVIKGV. Modem

Geometry--Methods and Applications. Part I.2nd ed.

120 ZIEMER. Weakly Differentiable Functions:Sobolev Spaces and Functions of BoundedVariation.

Page 193: Graph Theory-An Introductory Course-Bela Bollobas

121 LANG. Cyclotomic Fields I and II. Combined2nd ed.

140 AUBIN. Optima and Equilibria. AnIntroduction to Nonlinear Analysis.

122 REMMERT. Theory of Complex Functions.Readings in Mathematics

141 BECKER/WEISPFENNING/KREDEL. Grdbner

Bases. A Computational Approach to123 EBBINGHAUS/HERMES et al. Numbers. Commutative Algebra.

Readings in Mathematics 142 LANG. Real and Functional Analysis. 3rd ed124 DUBROVIN/FOMENKO/NOVIKOV. Modem 143 DOOB. Measure Theory.

Geometry--Methods and Applications. PartIll.

144 DENNis/FARB. NoncommutativeAlgebra.

125 BERENSTEIN/GAY. Complex Variables: AnIntroduction.

145 VICK. Homology Theory. AnIntroduction to Algebraic Topology.

126 BoREL. Linear Algebraic Groups. 2nd ed.127 MASSEY. A Basic Course in Algebraic

Topology.146 BRIDGES. Computability: A

Mathematical Sketchbook.128 RAUCH. Partial Differential Equations. 147 ROSENBERG. Algebraic K-Theory and129 FULTON/HARRIS. Representation Theory: A Its Applications.

First Course.Readings in Mathematics

148 ROTmAN. An Introduction to theTheory of Groups. 4th ed.

130 DoDSON/POSrON. Tensor Geometry. 149 RATCLIFFE. Foundations of Hyperbolic131 LAM. A First Course in Noncommutative Manifolds.

Rings. 150 EISENBUD. Commutative Algebra with132 BEARDON. Iteration of Rational Functions. a View Toward Algebraic Geometry.133 HARRIS. Algebraic Geometry: A First Course. 151 SILvERMAN. Advanced Topics in the134 ROMAN. Coding and Information Theory. Arithmetic of Elliptic Curves.135 ROMAN. Advanced Linear Algebra. 152 ZIEGLER. Lectures on Polytopes.136 ADKINS/WEINTRAUB. Algebra: An Approach

via Module Theory.153 FULTON. Algebraic Topology: A First

Course.137 AxLER/BouRD0N/RAMEY. Harmonic Function

Theory.154 BROWN/PEARCY. An Introduction to

Analysis.138 COHEN. A Course in Computational 155 KASSEL. Quantum Groups.

Algebraic Number Theory. 156 KECHRis. Classical Descriptive Set139 BREDON. Topology and Geometry. Theory.

Page 194: Graph Theory-An Introductory Course-Bela Bollobas

Bela Bollobas read mathematics at the University of Budapest,gaining a doctorate for work in discrete geometry in 1967. He spentthe year 1967-68 in Moscow with Professor I.M. Gelfand. After ayear in Oxford he went to Cambridge, where in 1971 he received aPh.D. in functional analysis. He has been a fellow of Trinity Collegesince 1970 and a lecturer in pure mathematics at the Universityof Cambridge since 1971. This book has developed from courses ingraph theory.

Bela Bollobas has written numerous papers, mostly in graphtheory and functional analysis. His first book, Extremal GraphTheory, was published in 1978. He represented Oxford at modernpentathlon and Cambridge at fencing.

ISBN 0-387-90399-2ISBN 3-540-90399-2