106
Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and 7) S. Gill Williamson

Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

  • Upload
    others

  • View
    4

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

Basic Concepts of GraphAlgorithms

Combinatorics for Computer Science (Units 6 and 7)

S. Gill Williamson

Page 2: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

c©S. Gill Williamson 2012

Page 3: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

Preface

From 1970 to 1990 I ran a graduate seminar on algebraic and algorithmiccombinatorics in the Department of Mathematics, UCSD. From 1972 to1990 algorithmic combinatorics became the principal topic. The seminarnotes from 1970 to 1985 were combined and published as a book, Com-binatorics for Computer Science (CCS), published by Computer SciencePress. Each of the ”units of study” from the seminar became a chapterin this book.

Here, we isolate a combined Unit 6 and Unit 7, corresponding to Chap-ter 6 and Chapter 7 of CCS, and reconstruct the original very helpful unitspecific index associated with these two units. Theorems, figures, etc.,are numbered sequentially: DEFINITION 6.10 and EXERCISE 6.29 re-fer to numbered items 10 and 29 of Unit 6 (or Chapter 6 in CCS). Unit 6contains basic material at an introductory level. Unit 7 applies Unit 6to a more advanced topic (planarity testing).

These notes focus on the visualization of algorithms through the use ofgraphical and pictorial methods. This approach is both fun and pow-erful, preparing you to invent your own algorithms for a wide range ofproblems. For further references and ongoing research, search the Web,particularly Wikipedia and the mathematics arXiv (arXiv.org).

Also available in this series are Basic Concepts of Linear Order (Unit 1),Sorting and Listing (Unit 2 and Unit 3)), and Polya Counting Theory(Unit 4). Units 6 and 7 are essentially independent of earlier units.

The exercises in this material were designed for student presentation inthe seminar. In many cases, these presentations were done after we hadgone through the entire unit. A good strategy is to read and understandthese exercises and return to the ones that interest you after you haveread the unit.

S. Gill Williamson, 2012http://cseweb.ucsd.edu/~gill

iii

Page 4: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

iv

Page 5: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

Table of Contents

Unit 6: Basic Concepts of Graph algorithms ...............1

Unit 7: Depth First Search and Planarity ................... 66

Subject Index ............................................................ 97

v

Page 6: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

vi

Page 7: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

Unit 6

Basic Concepts of Graph Algorithms

1

Page 8: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

2

Page 9: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

3

Page 10: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

4

Page 11: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

5

Page 12: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

6

Page 13: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

7

Page 14: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

8

Page 15: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

9

Page 16: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

10

Page 17: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

11

Page 18: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

12

Page 19: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

13

Page 20: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

14

Page 21: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

15

Page 22: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

16

Page 23: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

17

Page 24: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

18

Page 25: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

19

Page 26: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

20

Page 27: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

21

Page 28: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

22

Page 29: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

23

Page 30: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

24

Page 31: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

25

Page 32: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

26

Page 33: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

27

Page 34: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

28

Page 35: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

29

Page 36: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

30

Page 37: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

31

Page 38: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

32

Page 39: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

33

Page 40: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

34

Page 41: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

35

Page 42: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

36

Page 43: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

37

Page 44: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

38

Page 45: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

3.

39

Page 46: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

40

Page 47: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

41

Page 48: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

42

Page 49: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

43

Page 50: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

44

Page 51: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

45

Page 52: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

46

Page 53: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

47

Page 54: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

48

Page 55: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

49

Page 56: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

50

Page 57: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

51

Page 58: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

52

Page 59: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

53

Page 60: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

54

Page 61: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

55

Page 62: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

56

Page 63: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

57

Page 64: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

58

Page 65: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

59

Page 66: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

60

Page 67: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

61

Page 68: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

62

Page 69: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

63

Page 70: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

64

Page 71: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

65

Page 72: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

Unit 7

Depth First Search and Planarity

66

Page 73: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

67

Page 74: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

68

Page 75: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

69

Page 76: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

70

Page 77: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

71

Page 78: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

72

Page 79: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

73

Page 80: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

74

Page 81: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

75

Page 82: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

76

Page 83: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

77

Page 84: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

78

Page 85: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

79

Page 86: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

80

Page 87: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

81

Page 88: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

82

Page 89: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

83

Page 90: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

84

Page 91: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

85

Page 92: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

86

Page 93: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

87

Page 94: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

88

Page 95: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

89

Page 96: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

90

Page 97: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

91

Page 98: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

92

Page 99: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

93

Page 100: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

94

Page 101: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

95

Page 102: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

96

Page 103: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

Index

procedureBREAK(H), 48–50CONSTRUCT T AND B, 70ESEQ(T), 6INVPRU(T), 8JOIN(H), 48–50MAXSON, 35MOVE(t, δ, α, β), 18NEXT(Ti), 23NEXTPERM(A,m), 20PATH(e), 78PRU(T), 7SLOPPY PLANARITY TEST,

60–62construct lineal span. tree,

28

acyclicno cycles, 5

adjacency table, 4, 30, 77adjacent to a

VERT(b), 30articulation points graph, 50, 51automorphism group

graph, 40

backedges vs. chords, 68bicomponent tree, 54–60bicomponents

complexity issues, 73computing, 72, 73

biconnectedarticulation points, 51

biconnected graph, 47BIJ(A,B)

bijections A to B, 39–42bijections

BIJ(A,B), 39–42binary Gray code, 21breadth first, edges BRE(T), 13breadth first, vertices BRV(T),

13bridge SEG(e), 80bridge carrier, 80bridge graph, 58–62bridges

cycle, 52, 53subgraph, 53

canonical diagramstrees, 43

carrier of bridge, 80in cycle, 53, 54

componentsconnected, 5

connected graph, 5has lineal spanning tree, 25lineal spanning tree, 24

connected graphs on VCON(V), 36

connected graphs, four vertices,37

consistent embedding, 80contents, vcycle

bridges of, 52, 53carrier of bridge, 53, 54length n, 5

cycle bicomponent, 53cycle equivalent edges, 50

97

Page 104: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

cycle tree, 56, 57

data structureterminal, 33

depth firstedges, DFE(T), 11, 66, 67vertices, DFV(T), 11, 66, 67

depth first sequencesdefinition, 11

direct access modeldata structure, 28, 29

directed graph, 2doubly linked list

pointers, 30

edgedirected, 6incident on vertex, 6loop, 4natural directed, 9sequence, ESEQ(T), 6stack in tree, STACK(e), 12

edge action EPER(V)on PER(P2(V)), 39–42

edge set, 2edges

backedges, 68breadth first BRE(T), 13chords, 68cycle equivalent, 50postorder POSE(T), 12, 69–

71preorder PREE(T), 12, 69–

71, 74embedding, 2

consistent, 80preorder vertices, 75, 76properly ordered, 76

EPER(V)action on GRAPHS(V), 39–

42

graph

2-connected or biconnected,47

articulation points, 50, 51automorphism

stabilizer, 40bridge graph, 58–62chain of edges, 10connected, 5defined as triple, 2directed, 2, 4directed path, 10embedding of, 58–60intuitive idea, 1ordered, 4, 66planar, 58–60planar embedding, 58–60rank, nullity, 47, 48rooted lineal spanning tree,

25rooted lineal subtree, 25tree definition, 5undirected UND(G), 10

graphsisomorphism of, 38–42

greedy algorithm, 50

Hopcroft , 96hypergraph, 3

incidence function, 2inversion enumerator

polynomial, 36inversions

definition, 35isomorphic graphs, 39–42isomorphism of graphs, 38

Kuratowski subgraphs, 63

lineal spanning tree, 24, 68, 69algorithm for, 27chord, backedge, 34complexity, 28–34connected graph, 25

98

Page 105: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

first proof of, 26inversions in, 35second proof of, 27

lineal subtree, 25connected graph, 24, 68ordered, 24, 68

loop, 2, 4LOW1, LOW2 values, 72, 73

multigraph, 3multiset, 3

notationn = {1, . . . , n}, 6

ordered rooted tree, 42, 66orderly algorithm, 38, 43

basic mapping B, 44computing B−1, 44example, 45–47exercises, 46, 47

partitionset unordered Π(n, k), 17

pathlength n, 4

path directed, 10path tree, 78

example, 79PER(A)

permutations of A, 39–42PER(V)

permutations of vertices, 39–42

planarbipartite BRGR(C), 59–62

planar bipartite if e ≤ 2v − 4,62, 63

planar embeddingEuler e−v+r = 2, 63

planar embedding graph, 58–60planar graph, 58–60planar if e ≤ 3v−6, 62, 63planar not consistent, 81

planarity testoutline, 59–62

planarity testingMAX−MIN CHAIN, 94directly linked test, 91example, 82–91non-bichromatic SEGGR, 95relevant SEGGR(e,H), 92,

93pointers, 30–33polynomial

inversion enumerator, 36postorder edges, POSE(T), 12postorder vertices, POSV(T), 12Pruffer sequence of T, 7preface, iiipreorder edges, PREE(T), 12preorder vertices, PREV(T), 12principal subtree, 66

definition, 11

rank of Gedges in spanning forest, 47

segment graphbichromatic, 82planarity condition, 82

spanningforest, 24, 68subgraph, 24, 68tree, 24, 68tree - lineal, 24, 68tree - rooted, 24, 68

spanning forestchords, 24, 68rank of G, 47

spanning subgraph, 47stability subgroup

graph, 40stack

STACK(e′), 24stack in tree, edge, STACK(e),

13

99

Page 106: Basic Concepts of Graph Algorithmscseweb.ucsd.edu/~gill/AlgCombSite/Resources/_CreateSp6-7.pdf · Basic Concepts of Graph Algorithms Combinatorics for Computer Science (Units 6 and

stack in tree, vertex, STACK(x),13

subgraph

bridges of, 53

spanning, 47

subset action

of PER(A), 39–42

subsets of A: P(A)

size 2: P2(A), 39–42

subtree

lineal, 25

Tarjan, 96

Towers of Hanoi, 13–16

tree

breadth first order, 12

definition, 5

distance between vertices, 9

lineal spanning, 24, 68

natural directed, 9, 66

of cycles, 56, 57

of paths, 77–79

ordered rooted, 42, 66

ordered rooted ORTR, 9, 66

rooted RTR, 9, 66

subtree, 24, 68

unique path to root, 9

trees

all TR(V), 7

ancestor of y, 22, 68

canonical diagrams, 43

descendant of x, 22, 68

edge

initial vertex IN(e), 22

terminal vertex TM(e), 22

father of vertex, 22

lexicographic order, 9

lineal descendants, 22, 68

notation, 21

son of vertex, 22

trees rooted at v

TR(V, v), 36

vector notation← L, L →, x → L, etc.,

22vertex

adjacent, 4, 5, 66degree of, 6pendant, leaf, terminal, 6sequence, 4stack in tree, STACK(x), 12

vertex set, 2vertices

breadth first BRV(T), 13internal of tree INT(T), 8path equivalence, 5pendant of tree, PEND(T),

6postorder POSV(T), 12, 69–

71preorder PREV(T), 12, 69–

71, 74–76

100