<<

Today. Complete Graph. K4 and K5

Types of graphs. Kn complete graph on n vertices. Complete Graphs. All edges are present. Trees. Everyone is my neighbor. Hypercubes. Each is adjacent to every other vertex. K5 is not planar. How many edges? Cannot be drawn in the plane without an edge crossing! Each vertex is incident to n 1 edges. − Prove it! Alas. Different course. Sum of degrees is n(n 1). − = Number of edges is n(n 1)/2. ⇒ − Remember sum of is 2 E . | |

A , a tree. Trees. Equivalence of Definitions.

Definitions: Theorem: A connected graph without a cycle. “G connected and has V 1 edges” | | − ≡ A connected graph with V 1 edges. “G is connected and has no cycles.” | | − A connected graph where any edge removal disconnects it. Graph G = (V ,E). Lemma: If v is a degree 1 in connected graph G, G v is connected. A connected graph where any edge addition creates a cycle. − Binary Tree! Proof: Some trees. For x = v,y = v V , 6 6 ∈ there is path between x and y in G since connected. and does not use v (degree 1) = G v is connected. ⇒ − no cycle and connected? Yes. V 1 edges and connected? Yes. v y More generally. | | − removing any edge disconnects it. Harder to check. but yes. Adding any edge creates cycle. Harder to check. but yes. To tree or not to tree! x Proof of only if. Proof of if Tree’s fall apart.

v Thm: Thm: Thm: Removing a single disconnects V /2 nodes from each “G connected and has V 1 edges” “G is connected and has no cycles” = “G connected and has | | | | − ≡ ⇒ other. “G is connected and has no cycles.” V 1 edges” | | − Proof of = : By induction on V . Proof: ⇒ | | Base Case: V = 1. 0 = V 1 edges and has no cycles. Walk from a vertex using untraversed edges. | | | | − Until get stuck. Induction Step: Claim: Degree 1 vertex. Claim: There is a degree 1 node. Proof of Claim: Proof: First, connected = every vertex degree 1. Idea of proof. ⇒ ≥ Can’t visit more than once since no cycle. Sum of degrees is 2 V 2 | | − Entered. Didn’t leave. Only one incident edge. Point edge toward bigger side. Average degree 2 2/ V − | | Removing node doesn’t create cycle. Remove center node. Not everyone is bigger than average! New graph is connected. By degree 1 removal lemma, G v is connected. − Removing degree 1 node doesn’t disconnect from Degree 1 lemma. G v has V 1 vertices and V 2 edges so by induction − | | − | | − By induction G v has V 2 edges. = no cycle in G v. − | | − ⇒ − G has one more or V 1 edges. And no cycle in G since degree 1 cannot participate in cycle. | | −

Hypercubes. Recursive Definition. Hypercube: Can’t cut me! Complete graphs, really connected! But lots of edges. V ( V 1)/2 | | | | − Trees, But few edges. ( V 1) | | − just falls apart! A 0-dimensional hypercube is a node labelled with the empty string of bits. Hypercubes. Really connected. V log V edges! Thm: Any subset S of the hypercube where S V /2 has | | | | | | ≤ | | Also represents bit-strings nicely. An n-dimensional hypercube consists of a 0-subcube (1-subcube) S edges connecting it to V S; E S (V S) S which is a n 1-dimensional hypercube with nodes labelled 0x (1x) ≥ | | − | ∩ × − | ≥ | | G = (V ,E) − with the additional edges (0x,1x). Terminology: V = 0,1 n, | | { } (S,V S) is cut. E = (x,y) x and y differ in one bit position. − | | { | } 101 111 (E S (V S)) - cut edges. 01 11 ∩ × − 001 011 Restatement: for any cut in the hypercube, the number of cut 0 1 edges is at least the size of the small side. 110 00 10 000 100 010 2n vertices. number of n-bit strings! n 1 n2 − edges. 2n vertices each of degree n total degree is n2n and half as many edges! Proof of Large Cuts. Induction Step Idea Induction Step

Thm: For any cut (S,V S) in the hypercube, the number of cut − edges is at least the size of the small side. Thm: For any cut (S,V S) in the hypercube, the number of − cut edges is at least the size of the small side, S . Use recursive definition into two subcubes. | | Two cubes connected by edges. Proof: Induction Step. Thm: For any cut (S,V S) in the hypercube, the number of − Case 1: Count edges inside Recursive definition: cut edges is at least the size of the small side. Case 2: Count inside and across. subcube inductively. H0 = (V0,E0),H1 = (V1,E1), edges Ex that connect them. Proof: H = (V0 V1,E0 E1 Ex ) Base Case: n = 1 V= 0,1 . ∪ ∪ ∪ { } S = S0 S1 where S0 in first, and S1 in other. S = 0 has one edge leaving. S = φ has 0. ∪ { } | | Case 1: S V /2, S V /2 | 0| ≤ | 0| | 1| ≤ | 1| Both S0 and S1 are small sides. So by induction. Edges cut in H S . 0 ≥ | 0| Edges cut in H S . 1 ≥ | 1| Total cut edges S + S = S . ≥ | 0| | 1| | |

Induction Step. Case 2. Hypercubes and Boolean Functions.

Thm: For any cut (S,V S) in the hypercube, the number of − cut edges is at least the size of the small side, S . | | Proof: Induction Step. Case 2. S V /2. | 0| ≥ | 0| Recall Case 1: S , S V /2 | 0| | 1| ≤ | | The cuts in the hypercubes are exactly the transitions from 0 S V /2 since S V /2. | 1| ≤ | 1| | | ≤ | | sets to 1 set on boolean functions on 0,1 n. = S edges cut in E . { } Have a nice weekend! ⇒≥| 1| 1 S V /2 = V S V /2 Central area of study in computer science! | 0| ≥ | 0| ⇒ | 0 − | ≤ | 0| = V0 S0 edges cut in E0. Yes/No Computer Programs Boolean function on 0,1 n ⇒≥| | − | | ≡ { } Edges in Ex connect corresponding nodes. Central object of study. = = S S edges cut in E . ⇒ | 0| − | 1| x Total edges cut: S + V S + S S = V ≥ | 1| | 0| − | 0| | 0| − | 1| | 0| V = V /2 S . | 0| | | ≥ | | Also, case 3 where S V /2 is symmetric. | 1| ≥ | |