Processing math: 100%
Skip to main content

Graph Theory: Degree Sequence Algorithm ft Krita

Heyy! Welcome Back to my blog!

 Today we are doing Graph Theory. I somehow always get scared when someone mentions Graph theory. I have to overcome the fear. So here we go! I am writing some important theorems, terms, problems, etc that I learnt from the GT book. In short, Notes.

Book referred: Daniel A Marcus, Graph Theory, A Problem Oriented Approach

Chapter A:

  • Graph: A graph consists of points, which are called vertices and connections, which are called edges and which are indicated by line segments or curves joining certain pairs of vertices.
  • Degree: The degree of a vertex in a graph is the number of edges that occur at the vertex. The notation d(a) represents the degree of vertex A.
  • Degree Theorem: In any graph G, the sum of all the degrees is equal to twice the number of edges.

    This is because each edge contributes 2 to the sum of degrees i.e when an edge is removed,  \sum_{v\in G}d(v) decreases by 2.

  • Complete Graph: If all of the vertices in a graph are adjacent to each other, then the graph is called a complete graph. It is denoted as K_n.
  • Path in a Graph: Repetition is allowed 
  • Cycle: A cycle in a graph is a closed path in which the only repetation is the first and last vertex.
  • Cycle Graph: A cycle graph containing n vertices is denoted by C_n.



  • Complement of a Graph: The complement of a graph G_1 is another graph G_2 having the same set of vertices but including only those edges that are not in G_1.


  • Connected Graph: A graph is connected if every vertex is joined to every other vertex by a path. 
  • Disconnected Graph: Not connected.
  • Component: If a graph is disconnected, then it consists of two or more components. Each component is a connected subgraph H whose vertices are not adjacent to any vertices not in H.
  • Degree Sequence: The degree sequence of a graph is a list, or a sequence, of all the degrees of the vertices in the graph, including repetitions, usually in decreasing order.
     

    The above graph has degree sequence (5,4,3,2,2,1).
  • Distance: The distance between two vertices in the same component of a graph is the length of the shortest path joining these vertices. 
  • Diameter: If G is a connected graph, then the diameter of G is the maximum of all of the distances between vertices of G.
  • Max and Min degree: The maximum degree in a graph is denoted by \Delta and the minimum degree \delta.
The Degree Sequence Algorithm:
  • Start with the terms of the sequences in decreasing order.
  • Remove the largest term m and reduce the next m terms each by 1.
  • Rearrange the new sequence in decreasing order ( If needed)
The original sequence is the degree sequence of some graph iff the new sequence is.

Proof: Note that if the new sequence is graphic then clearly the old sequence is graphic too ( just add a new vertex.

Other direction. Let the degree sequence be (s,d_1,d_2,\dots,d_s,t_1,\dots,t_n). And let G be the graph for the degree sequence. Also, denote v(i) as the vertex with with degree i
Now, we delete v(s) from G. 
If v(s) is adjacent to d_1,d_2,\dots,d_s then we are done.
So say, v(s) is not adjacent to d_j. Hence, it must be adjacent to some other vertex say t_l. 
If t_l=d_j then we can just swap them.
If d_j>t_l then v(d_j) is adjacent to some vertex w that v(t_l) isn't. 

Hence we can join v(d_j),v(s) and v(w),v(t_l) and remove the edge v(d_j),v(w) and v(s),v(t_l).

And we can continue this process and make every v(d_i) adjacent to v(s).

Problem 1: Prove that if G_1 and G_2 are complementary graphs, then at least one of them must be connected. 

Proof: Let's say G_1 is disconnected then let vertex u,v be two vertices in same component and w be in the other component. Clearly uw,vw\not \in G_1\implies uw,vw\in G_2\implies there is a path between u,v in G_2. 

Hence in G_2, the diameter is 2. 

Problem 2: Suppose that a graph contains 11 vertices and that each vertex has a degree 5 or greater. Prove that the graph must be connected.

Proof: Let's say for the sake of contradiction, the graph is disconnected. Then we consider the components. Note that there must be at least 2 components and each component must have at least 6 vertices since each vertex has a degree 5 or greater. But this is not possible.

Problem 3: Show that in a graph with n vertices, if \delta +\Delta is greater than or equal to n-1 then the graph is connected.

Proof: If not, then consider the components. Clearly, there will be at least two components. So at least one component has \Delta +1 vertices and the other will have at least \delta +1 vertices. So the number of vertices would be at least \Delta+\delta +2> n. Not possible.

Problem 4: Prove that in any graph with minimum degree \delta , there exists a simple path of length greater than or equal to \delta .

Proof: Let \lambda be the length of the longest simple path. Then the endpoints of the longest path will have degree \le \lambda. But the endpoint will have at least \delta. So \delta\le \lambda.

Chapter B:
  • Isomorphism is graphs: If two graphs are isomorphic then they have the same number of vertices, the same number of edges, the same maximum and minimum degrees, same degree sequence, same length of the longest simple path, same cycle lenghts.
    However, satisfying this doesn't imply two graphs are isomorphic.
Chapter C:
  • Bipartite Graphs: It is a graph whose vertices can be separated into two sets X and Y in such a way that every edge in the graph has one endpoint in each set.

    Here we have X=\{A,C,F\},Y=\{B,D,E\}



  • Complete Bipartite Graphs: Every vertex in X is adjacent to every vertex in Y. They are denoted by symbol K_{m,n}, where m and n are vertices in X and Y.

    Note that K_{m,n} will have mn edges and vertices in X set will have degree n and vertices in Y set will have degree m.

    Here is K_{2,5}.


    Cycle Theorem for Bipartite Graphs: A graph is bipartite iff it contains no odd cycle.

    Proof: If the graph contains an odd cycle then it's not bipartite (colour the vertices, we won't be able to divide into two sets cause it's odd). 
    If the graph contains no odd cycle, then choose any vertex A from any component of Graph G. Assign it colour red and then colour the vertices adjacent to it Blue and then vertices adjacent to Blue vertices as Red and so on along simple paths from A.

    Note that no vertex will have two distinct colours. 
    Proof: Suppose not. Let the vertex be W. Then we get A\rightarrow W\rightarrow A an odd cycle.

Chapter D:
  • Tree: It is a graph that is connected and contains no cycles.
  • Forest: It is a graph in which each component is a tree.
  • Spanning Tree: A tree which is a subgraph of graph G and contains every vertex of G. Any connected graph would have a spanning tree.


Pruning a Tree: Removing a vertex of degree 1 from the tree along with the edge that occurs at that vertex. 

Here is the example,

Note that after pruning, we still get a tree.

Lemma: Prove that every tree with two or more vertex has at least two leaf vertices.
Proof: Consider the longest simple path in the tree. Let the end points be A,B. Let the other vertices of the graph not in the path be d_1,d_2,\dots,d_n and vertices in the path be v_1,\dots,v_k. Let v_i,v_j be adjacent to A,B respectively.
Note that d_1,d_2,\dots,d_n  are not adjacent to A,B since we considered the longest path and A is not adjacent to v_1,\dots ,v_{i-1}v_{i+1},\dots,v_k else it would form a cycle. Similar to B. Hence A,B have degree 1.

Tree Theorem 1:
Every tree with v vertices has exactly v-1 edges.
Proof: Just prune it. v-e is always 1.

Forest Corollary: In a forest with v vertices and k components, the number of edges is v-k.
Proof: Each component has v-e=1. 

Tree Theorem 2: In any Tree, there is exactly one simple path from any vertex to any other vertex.
Proof: Since T is connected, there is a simple path. If there are two different paths then we will get a cycle.


Cayley's Formula: In a labelled complete graph with n vertices, the number of spanning trees is n^{n-2}.

We prove it using Prufer's method which establishes a bijection between spanning trees and sequence of n-2 length which can be filled up in n^{n-2} ways since we have n numbers.

Converting the spanning-tree into Prufer's sequence: 
First label the graph with numbers. Now we construct the sequence S.

  • Find a leaf with the smallest label
  • Include the neighbour of the leaf and then delete the leaf 



Problem 1: Show that the average degree a tree in a tree is always less than 2. 
Proof: The number of edges is n-1 and the number of vertices is n. So the sum of degrees is 2n-2<2n.

Problem 2:
Show that the number of vertices of degree 1 in any tree must be greater than or equal to the maximum degree (\Delta) in the tree.
Proof: Let A have degree \Delta . Consider the \Delta subgraphs formed by A. Each will be a tree and will be disconnected ( or else we get cycle). Each tree will have one leaf. So we get \Delta leaves.


Problem 3: Show that if a graph has v vertices and v-1 edges and contains no cycle. It's connected.
Proof: If not, let there be k components. These components are connected and have no cycles, hence a tree. Then we will have v-k edges.


Problem 4: Show that if a graph has v vertices and v-1 edges and is connected, then the graph has no cycles.
Proof: Since it is connected, the graph contains a spanning tree. The spanning-tree contains v-1 edges. Hence the graph is a tree.


Three conditions:
If graph G satisfies any two of three conditions;
1. G has v and v-1 edges
2. G is connected
3. G contains no cycles,
then G satisfies all three conditions.

Yep, this was it for the Part A of the book! I also made my first Digital Art on Krita! It did take me a lot of time. How is it?

Yee, that's it for today's blog. I will post the sequel tomorrow.

Sunaina 💜

Comments

  1. Nice content, thank you for writing this :))

    ReplyDelete
  2. Replies
    1. Thankyou :).. The book is very nice, thanks for asking me to refer :)

      Delete
  3. ooo This might be useful for me someday when I stop doing geo and start gt :| (Not anytime soon though)
    Also the flower is very nice!

    ReplyDelete
    Replies
    1. Thankyou so much for commenting! Hehe, sure Geo for life!!!! I do have another GT post, whenever you want to refer just go to the notes page! Also pro people commenting
      :ORZ:

      Delete

Post a Comment

Popular posts from this blog

Solving Random ISLs And Sharygin Solutions! And INMO happened!!

Some of the ISLs I did before INMO :P  [2005 G3]:  Let ABCD be a parallelogram. A variable line g through the vertex A intersects the rays BC and DC at the points X and Y, respectively. Let K and L be the A-excenters of the triangles ABX and ADY. Show that the angle \measuredangle KCL is independent of the line g Solution: Note that \Delta LDK \sim \Delta XBK and \Delta ADY\sim \Delta XCY. So we have \frac{BK}{DY}=\frac{XK}{LY} and \frac{DY}{CY}=\frac{AD}{XC}=\frac{AY}{XY}. Hence \frac{BK}{CY}=\frac{AD}{XC}\times \frac{XK}{LY}\implies \frac{BK}{BC}=\frac{CY}{XC}\times \frac{XK}{LY}=\frac{AB}{BC}\times \frac{XK}{LY} \frac{AB}{LY}\times \frac{XK}{BK}=\frac{AB}{LY}\times \frac{LY}{DY}=\frac{AB}{DL} \implies \Delta CBK\sim \Delta LDK And we are done. We get that \angle KCL=360-(\angle ACB+\angle DKC+\angle BCK)=\angle DAB/2 +180-\angle DAB=180-\angle DAB/2 Motivation: I took a hint on this. I had other angles but I did...

Some problems in Olympiad Graph theory!

Hello there! It has been a long time since I uploaded a post here. I recently took a class at the European Girls' Mathematical Olympiad Training Camp 2024, held at CMI. Here are a few problems that I discussed! My main references were Po-Shen Loh's Graph theory Problem set (2008), Adrian tang's Graph theory problem set (2012) and Warut Suksompong's Graph Cycles and Olympiad Problems Handout and AoPS. I also referred to Evan Chen's Graph theory Otis Problem set for nice problems! Text Book Problems which are decent A connected graph G is said to be k-vertex-connected (or k-connected) if it has more than k vertices and remains connected whenever fewer than k vertices are removed. Show that every k-connected graph of order atleast 2k contains a cycle of length at least 2k. We begin with a lemma. Prove that a graph G of order n \geq 2k is k connected then every 2 disjoint set V_1 and V_2 of k distinct vertices each, there exist k...

My experiences at EGMO, IMOTC and PROMYS experience

Yes, I know. This post should have been posted like 2 months ago. Okay okay, sorry. But yeah, I was just waiting for everything to be over and I was lazy. ( sorry ) You know, the transitioning period from high school to college is very weird. I will join CMI( Chennai Mathematical  Institue) for bsc maths and cs degree. And I am very scared. Like very very scared. No, not about making new friends and all. I don't care about that part because I know a decent amount of CMI people already.  What I am scared of is whether I will be able to handle the coursework and get good grades T_T Anyways, here's my EGMO PDC, EGMO, IMOTC and PROMYS experience. Yes, a lot of stuff. My EGMO experience is a lot and I wrote a lot of details, IMOTC and PROMYS is just a few paras. Oh to those, who don't know me or are reading for the first time. I am Sunaina Pati. I was IND2 at EGMO 2023 which was held in Slovenia. I was also invited to the IMOTC or International Mathematical Olympiad Training Cam...

Introduction

  Hey Everyone!! This is my first Blog post. So let me give a brief introduction about myself. I am Sunaina Pati. I love solving Olympiad math problems,  learning crazy astronomical facts , playing hanabi and anti-chess, listening to Kpop , love making diagrams in Geogebra and  teaching other people maths 😊 . I love geometry , number theory and Combinatorics . I am starting this blog to keep myself a bit motivated in doing studies 😎 . Right now, I am planning to write walkthroughs on some of the best problems I tried over the week which can refer for hints 'cause solutions contain some major spoilers and one learns a lot while solving the problem on his own rather than seeing solutions . Also, there will be some reviews about Kpop songs, study techniques, my day to day lifestyles,exam reviews and ofc some non-sense surprises 😂.  I am planning to  try  posting every week on Sundays or Saturdays ( most probably) ! Though there is no guarantee about when I ...

Bio is Love..

Adios, everyone! Boards preparation at its peak :(  However, I am not able to study how I used to. Every time I try to study for boards, I just keep thinking much about a topic, stare at the book, jam a song or just start doing procrastination by bookmarking random cute problems in HSO. It's been more than a year I have studied like with a focus on a book. My lappy is being a big distraction tbh. So after INMO score come out, I will just give my lappy for repair and say papa to bring it back home after June 2.  Milk and Mocha I literally am taking 2 days to complete 1 bio chapter, some times even 3. The rate of my "slowness" is probably because I am like every 15 minutes checking discord to see if the INMO scores are out or not. So HBCSE, thank you for keeping me anxious.  Funfact:- we must be grateful that there is an organisation that is conducting these national Olys. There are some countries where no Olys are being conducted. ( Same dialogue which mumma uses, but in p...

New year with a new beginning! And a recap of 2024..and all the best for INMO 2025!

Hi everyone! Happy New Year :)  Thank you so much for 95k+ views!!! How was everyone's 2024? What are everyone's resolutions? ( Do write down in the comment section! And you can come back 1 year later to see if you made them possible!). And.. What about me?  A Better human being Well, I want to become a better human being this year compared to last year. From a very young age, my father has been saying to me, "It does not matter if you are a good mathematician, but you should be a nice human being." As a teenager, I never took the statement seriously. Well, all that mattered to me was to do good mathematically. Why should I care about other people's feelings? These were all my thoughts in high school.  So I ended up saying a few hurtful statements without realising that they were hurtful.  I never actually cared throughout my high school. You know, the world is too big, if I hurt person A, no worries, I will move on to person B and start a new friendship! As a res...

Geometry ( Finally!!!)

 This is just such an unfair blog.  Like if one goes through this blog, one can notice how dominated  Algebra is!! Like 6 out of 9 blog post is Algebra dominated -_- Where as I am not a fan of Algebra, compared to other genres of Olympiad Math(as of now). And this was just injustice for Synthetic Geo. So this time , go geo!!!!!!!!!!!  These problems are randomly from A Beautiful Journey through Olympiad Geometry.  Also perhaps I will post geo after March, because I am studying combi.  Problem:  Let ABC be an acute triangle where \angle BAC = 60^{\circ}. Prove that if the Euler’s line of \triangle ABC intersects AB and AC at D and E, respectively, then \triangle ADE is equilateral. Solution:  Since \angle A=60^{\circ} , we get AH=2R\cos A=R=AO. So \angle EHA=\angle DOA. Also it's well known that H and O isogonal conjugates.\angle OAD =\angle EAH. By ASA congruence, we get AE=AD. Hence \triangle ADE is equilateral....

How to prepare for INMO

Since INMO is coming up, it would be nice to write a post about it! A lot of people have been asking me for tips. To people who are visiting this site for the first time, hi! I am Sunaina Pati, an undergrad student at Chennai Mathematical Institute. I was an INMO awardee in 2021,2022,2023. I am also very grateful to be part of the India EGMO 2023 delegation. Thanks to them I got a silver medal!  I think the title of the post might be clickbait for some. What I want to convey is how I would have prepared for INMO if I were to give it again. Anyway, so here are a few tips for people! Practice, practice, practice!! I can not emphasize how important this is. This is the only way you can realise which areas ( that is combinatorics, geometry, number theory, algebra) are your strength and where you need to work on. Try the problems as much as you want, and make sure you use all the ideas you can possibly think of before looking at a hint. So rather than fixing time as a measure to dec...

Let's complex bash Part 1

I have to learn complex bash. And almost everyone knows that I am notes taking girl so thought why not make a post on complex bash ( so that I don't get emotionally demotivated lol).😇 There wasn't any need for learning complex bash, but it was in my dream checklist i.e " To learn a bash." And since I am not loaded with exams, I think it's high time to learn Bash and new topics.  Also if anyone from the "anti-bash" community is reading, sorry in advance and R.I.P.  Notes:- 1. Complex numbers are of the form z=a+ib, where a and b are real numbers and i^2=-1. 2. In polar form, z=r(\cos \theta+~~i\sin\theta)=~~re^{i\theta}, where r=~~|z|=~~\sqrt{a^2+b^2}, which is called the magnitude. 3. Here we used euler's formula i.e \cos \theta+~~i\sin\theta=~~e^{i\theta}. 4. The \theta is called the argument of z, denored \arg z. ( \theta can be considered in \mod 360 and it is  measured anti-clockwise). 5. The complex conjugate of z is ...

Problems I did this week [Jan8-Jan14]

Yeyy!! I am being so consistent with my posts~~ Here are a few problems I did the past week and yeah INMO going to happen soon :) All the best to everyone who is writing!  I wont be trying any new problems and will simply revise stuffs :) Some problems here are hard. Try them yourself and yeah~~Solutions (with sources) are given at the end! Problems discussed in the blog post Problem1: Let ABC be a triangle whose incircle \omega touches sides BC, CA, AB at D,E,F respectively. Let H be the orthocenter of DEF and let altitude DH intersect \omega again at P and EF intersect BC at L. Let the circumcircle of BPC intersect \omega again at X. Prove that points L,D,H,X are concyclic. Problem 2: Let ABCD be a convex quadrangle, P the intersection of lines AB and CD, Q the intersection of lines AD and BC and O the intersection of diagonals AC and BD. Show that if \angle POQ= 90^\circ then PO is the bisector of \angle AOD ...