5.2 Articulation Point and Biconnected Components

Поделиться
HTML-код
  • Опубликовано: 25 дек 2024

Комментарии • 212

  • @rahulvijayaragavan4903
    @rahulvijayaragavan4903 5 лет назад +28

    One of the reasons why i feel youtube is a boon is that it gets us to amazing teachers like you, which otherwise will be rare. I am in my 30s but students in this generations are really blessed. Hope they make use of it.

  • @yeyuksel
    @yeyuksel 4 года назад +435

    Even my grandma would understand this topic with your explanation

    • @destinyjames6117
      @destinyjames6117 3 года назад +8

      lmao sir yea his explanation is so clear

    • @Samuel_above_fake
      @Samuel_above_fake 2 года назад +5

      By seeing your dp, you may have the age around 25, therefore your grandma age may be around 60-70. So, the people who is having age around this range can't know English, therefore how can you say that your grandma can understand this without knowing English? Don't try to impress or show off here.....

    • @saikarthik559
      @saikarthik559 2 года назад +28

      @@Samuel_above_fake By seeing your long message we can say that you have wasted time by typing comment, therefore Don't try to waste your time again ok?....

    • @Samuel_above_fake
      @Samuel_above_fake 2 года назад +1

      @@saikarthik559 😂 I do fast typing, is there any problem for you???

    • @m1ckey007
      @m1ckey007 Год назад +12

      @@Samuel_above_fake that'll better help you in competitive programming... not commenting vague here. ☮

  • @AltairCrysis
    @AltairCrysis 2 года назад +7

    Wow, this was really clear -- I'd gone through 4 different explanations prior to watching this video, and this is the first time I actually understand what was going on! Great job!!

  • @ogawamateus
    @ogawamateus 8 месяцев назад +4

    Thank you so much! I spent way too long trying to solve this problem for my class and to no avail, but when I watched this video I found the solution right away! Thank you!

  • @cbbforever
    @cbbforever Месяц назад +1

    my lecturer spend tons of time to make a piece of garbage 100 pages' slide and explain this to us using 30 mins and I feel like nothing come in my mind, my time has been stolen. And you, my hero.

  • @hardikvansia3293
    @hardikvansia3293 6 лет назад +73

    Hats off to you ...
    Really great explanation.
    Appreciate your hardwork.

  • @rushikothari1261
    @rushikothari1261 4 года назад +23

    You and Ravindra Ravula sir are shaping many computer Engineers in our country 🇮🇳.

  • @mori1799
    @mori1799 3 месяца назад +1

    Clear, concise, and straight to the point. Thank you very much sir!

  • @jaatharsh
    @jaatharsh 4 года назад +5

    thanks for making the Video Sir, it was difficult for me to grasp this Algo at first,
    I watched ur explanation twice to get a better understanding.
    keep on posting such videos.

  • @807johnny807
    @807johnny807 6 лет назад +13

    Finally a great explanation, not those freaking recursive formulas

  • @allawhussein
    @allawhussein 2 года назад +1

    When an eight minute RUclips video is better than a whole lecture on the subject.

  • @Monica-cq2hr
    @Monica-cq2hr 3 года назад

    Sir thank u so much for this video ......I searched at many places .....but u r crystal clear and at the point.....

  • @amitmagar1675
    @amitmagar1675 4 года назад +9

    really appreciate your efforts to explain things so lucidly!

  • @pmoieni
    @pmoieni 4 года назад +1

    best explanation, algorithms are really hard but with your explanation who will not understand, thank you

  • @stith_pragya
    @stith_pragya Год назад +3

    Thank You So Much for this wonderful video........🙏🏻🙏🏻🙏🏻🙏🏻🙏🏻🙏🏻

  • @rohes8129
    @rohes8129 2 года назад +2

    Thanks man, thanks alot
    May GOD protect u and guide u❤️❤️❤️❤️❤️❤️

  • @romanarahman5980
    @romanarahman5980 5 лет назад +20

    I was soo confused about this topic but your explanation is amazing Sir. Thanks a lot

  • @gulfilizisik
    @gulfilizisik Год назад

    Dear Abdul Bari, thanks to you I like the algorithms! Thanks so much!

  • @ravipatel3624
    @ravipatel3624 4 года назад +5

    Classic explanation, hats off to you

  • @rohes8129
    @rohes8129 2 года назад +2

    Ur unbelievable sir!!
    Thanks again... ❤️❤️❤️🌹🌹🌹🌹🌹🌹🌹🌹🌹

  • @sahithmylavarapu9375
    @sahithmylavarapu9375 5 лет назад +4

    Simple ,clean ,neat .
    Thanks a lot 😊 sir ...

  • @mohammad_bilal951
    @mohammad_bilal951 4 года назад +3

    Dear Abdul Bari Sir
    Please KEEP UPLOADING more lectures to be honestly your videos make more sense and are very simple please keep up the good work.
    :)

  • @ManikandanM-wz2vb
    @ManikandanM-wz2vb 5 лет назад +1

    Thank u so much sir ,Your videos in algorithms is very helpful to me and it also arouses an interest.Finally ur way of teaching is mesmerising!!

  • @asrithraj1426
    @asrithraj1426 4 месяца назад +9

    our faculty copies from you😂😂😂

  • @ankitraina4047
    @ankitraina4047 4 года назад +2

    Teacher ho toh Abdul sir jesa vrna na ho :)

  • @miruvarshinifam5955
    @miruvarshinifam5955 3 года назад

    Thank you very much, sir, your explanation about all the topics is very simple and understandable.

  • @abi6ail
    @abi6ail 3 года назад +2

    Wow, great explanation, really helpful! thank you!

  • @pratyushsrivastava3783
    @pratyushsrivastava3783 6 лет назад +4

    abdul bhai ki jai ho. shukriya bhai......(x100)

  • @ilovancristian
    @ilovancristian 2 года назад

    Thank you! Also, I have found something related to the last statement: when is node/point 1 an articulation point (8:05). Maybe it helps somebody.
    First time this was confusing for me because I thought that if node 1 has more than 1 neighbor then 1 is an articulation point, but that is not true. For instance, if node 1 belongs to a cycle, then he has more than 1 neighbor, therefore he is not an articulation point.
    However, I found that 1 is an articulation point if he belongs to more than 1 biconex components. That is how I check if 1 is or not an articulation point.

  • @287MdSahil
    @287MdSahil 4 года назад

    Best explanation possible for this algorithm

  • @s9chroma210
    @s9chroma210 3 года назад

    Exam today, this saved me

  • @martonnemeth236
    @martonnemeth236 4 года назад +4

    Really good explanation, thank you.

  • @arnavattri5047
    @arnavattri5047 6 лет назад +9

    Awesome! Thank you, Sir! :)

  • @mgphyothant
    @mgphyothant 2 года назад

    Really good lecture for free, thank you sir.

  • @satishchandra6623
    @satishchandra6623 4 года назад +17

    But why this algorithm works? I mean why there is an articulation point when L(v)>=d[u]? Any explanation for this is highly appreciated?🙏

    • @raywang999
      @raywang999 4 года назад +15

      cp-algorithms.com/graph/cutpoints.html
      I'm still trying to understand it, but I understand it as this: We root the graph arbitrarily, creating a tree-like structure (i think it's called a dfs-tree), then notice 2 observations:
      A node is an articulation point if: it's the root and has more than 1 child OR
      A node is not the root and none of it's children have a back edge to the node's ancestors (aka. there's no cycles that lead back)
      To efficiently check if a node meets the second observation, we use the L and d arrays. Instead of thinking of L as low, think of it as the earliest time we visited a node. If the earliest time we visited a child (aka. L[v]) is less than the time we visited our current node (d[u]) then that means in our dfs, we visited v from an ancestor, which means v has a back-edge to an ancestor.
      More formally: iff L[v] < d[u], u is not an articulation point. Therefore, if L[v] >= d[u], u is an articulation point.
      Hope that helped!

    • @satishchandra6623
      @satishchandra6623 3 года назад +4

      @@raywang999 Great effort! It's Crystal clear now! Since we have an back edge means that the "Earliest time of child (aka L[v]) is already visited from ancestor, so will not become articulation point" ! Thank You! 🙌🙌

    • @MayankSharma-sf3hy
      @MayankSharma-sf3hy 3 года назад

      @@raywang999 where you understood it so deep any source?

    • @sohamdas9160
      @sohamdas9160 3 года назад

      @@raywang999 Thank you SO much!!!

    • @rakibmollik8043
      @rakibmollik8043 4 месяца назад

      Could you please write this explanation? It will be helpful for me.
      Tnx​@@satishchandra6623

  • @mohammedabdulazeem5656
    @mohammedabdulazeem5656 2 года назад

    Alhamdulillah, Very nice exxplanation

  • @starc701
    @starc701 4 года назад +5

    🙌🙌🙌🙌🙌🙌🙌🙌🙌🙌🙌🙌🙌THE GOD MR ABDUL BARI 🙌🙌🙌🙌🙌🙌🙌🙌🙌🙌🙌🙌🙌

  • @Akashash992
    @Akashash992 3 года назад

    Keep it going... Your explanation is awesome

  • @travisblack9519
    @travisblack9519 6 лет назад +5

    This is a very good explanation, thank you.

  • @suvijaashri4625
    @suvijaashri4625 4 года назад

    A very clear explanation sir.
    thanks a lot.

  • @SRNR_PODCAST.
    @SRNR_PODCAST. 3 года назад +1

    a goldmine in youtube

  • @karnansooriyakumar8002
    @karnansooriyakumar8002 2 года назад

    Thank you sir, very clear explanation🥰🥰

  • @jknair0
    @jknair0 2 года назад +4

    I didnot understand the lower dfs number was derived. what path is being taken. How are those determined as back edge. I can go from 5 -> 6 -> 3 -> 2 -> 1. Why are we determining 3 is lower dfs number?

    • @pavanmandru6481
      @pavanmandru6481 3 месяца назад +2

      Back tracking is only allowed once in finding articulation point.

  • @User-ow7rn
    @User-ow7rn 3 года назад

    sir ,at 3:33 why 2 is visited at 6th? why not at 2nd?generally in for loop ,we start from 1 to n,so 2 will come first,right?

  • @amrhamcho1853
    @amrhamcho1853 6 лет назад

    Excellent explanation, props to you, sir!

  • @TheWebPotato
    @TheWebPotato 6 лет назад +5

    Here, once we have found the articulation point. How do we know from which vertex to vertex do we have to draw an edge so that it is bi-connected? Thanks once again.

  • @taivinh1986
    @taivinh1986 3 года назад

    what a concise explanation

  • @herumuharman6305
    @herumuharman6305 3 года назад

    Finally I get it, thanks man.

  • @tanisharastogi6575
    @tanisharastogi6575 6 лет назад +17

    How has the formula been derived?

    • @0anant0
      @0anant0 4 года назад +6

      Tarjan's Algorithm

  • @marshallokafor5034
    @marshallokafor5034 2 года назад +1

    Dr. Abdul, there seems to be a confusion here Sir. What if we evaluate L[2] and its parent is V(3) which has a D[3] = 1. But V(3) is definitely an articulation point but this scenario i have just mentioned will evaluate to False. Can you clarify Sir?

  • @薇季芬
    @薇季芬 2 года назад

    3:59 low value
    5:17 find out articulation point

  • @swaroopajalasuthram2535
    @swaroopajalasuthram2535 4 года назад

    Tnq Soo much sir for u r valuable explanation.

  • @souvik33and37
    @souvik33and37 3 месяца назад

    thanks for this explanation

  • @marykapodistria7204
    @marykapodistria7204 3 года назад +2

    How does this work for 3 as the parent and 2 as the child? I mean the formula L[v] >= d[u] where u = 3 and v = 2. L[2] = 1 and d[3] = 3 thus this shows 3 is not an articulation point

    • @satishchandramedi9729
      @satishchandramedi9729 3 года назад

      ---------------------------------------Credits: Ray Wang-------------------------------------------------------
      cp-algorithms.com/graph/cutpoints.html
      I'm still trying to understand it, but I understand it as this: We root the graph arbitrarily, creating a tree-like structure (i think it's called a dfs-tree), then notice 2 observations:
      A node is an articulation point if: it's the root and has more than 1 child OR
      A node is not the root and none of it's children have a back edge to the node's ancestors (aka. there's no cycles that lead back)
      To efficiently check if a node meets the second observation, we use the L and d arrays. Instead of thinking of L as low, think of it as the earliest time we visited a node. If the earliest time we visited a child (aka. L[v]) is less than the time we visited our current node (d[u]) then that means in our dfs, we visited v from an ancestor, which means v has a back-edge to an ancestor.
      More formally: iff L[v] < d[u], u is not an articulation point. Therefore, if L[v] >= d[u], u is an articulation point.
      Hope that helped!

  • @ShaliniNegi24
    @ShaliniNegi24 2 года назад

    Wow, simply amazing !!

  • @sat3287
    @sat3287 4 года назад

    Best explanation.

  • @himanshusrihsk4302
    @himanshusrihsk4302 4 года назад

    Awesome explaination sir

  • @vbansal345
    @vbansal345 5 лет назад

    Sir , best explanation

  • @mrudhul145
    @mrudhul145 2 года назад

    This is a great video.

  • @sainaveen5659
    @sainaveen5659 4 года назад

    This explanation is 🔥..by the way that formula is derived from tarjan algorithm right?....

  • @mohammedadel8948
    @mohammedadel8948 2 года назад

    Thank you for your efforts

  • @usamaalioffical
    @usamaalioffical 5 лет назад

    Sir you are a living legend Your videos are awesome one thing that you should also add code in your videos of algorithms and explain it.Hope you will look into this matter.Lots of love from Pakistan

  • @liangtang2127
    @liangtang2127 5 лет назад +2

    very clear explanation, thank you so much!!

  • @barabenkag221
    @barabenkag221 5 лет назад

    Great! Really helpful! Thank you very much!

  • @nikhilkalyan6273
    @nikhilkalyan6273 5 лет назад +3

    in finding the least path L can we assume the path as 5->3->2->1 as it is a undirected graph?

  • @Tehbert321
    @Tehbert321 4 года назад

    Thank you! That was super helpful

  • @bushidocodes
    @bushidocodes 5 лет назад

    Can you please clarify how one algorithmically finds the "first backedge"? Based on what you show, where the root vertex resolves to the backedge from vertex 2, it seems like it must be level-synchronized BFS, where we compare all backedges in a given level and resolve to the highest reaching backedge. Is that what you would envision?

    • @bushidocodes
      @bushidocodes 5 лет назад

      One other thing I've noticed while implementing this is that there might be parts of the spanning tree that don't encounter any backedges when traversing downwards(e.g. 5 if we were to delete the backedge from 6). It seems that we could remove 6 without problem, but removing 5 would make 6 it's own graph. I think the way to get around that is to label vertices at having an L of MAX_INT to make sure the formula finds those as well, but ignore vertices iwth MAX_INT that are also leat nodes on the spanning tree.

  • @nikhilchunduri7247
    @nikhilchunduri7247 2 года назад +1

    jaii Bari sirrrrrrrrrrrrr💥

  • @nikhilendrarathore3040
    @nikhilendrarathore3040 4 года назад +1

    I am a little confused. If we take the parent-child pair of [1,4] then L[4] = 1 = d[1] then L[4] >= d[1]. Does that mean that 1 is also a articulation point?

    • @madhukumarganesh4987
      @madhukumarganesh4987 4 года назад +3

      the formula isn't valid for root node (node from which we started the dfs).

    • @subashkannan949
      @subashkannan949 3 года назад +1

      Exception in the root node

  • @ngn_two6001
    @ngn_two6001 6 лет назад

    Great explanation looking toward more videos about data structures

  • @spotlight4091
    @spotlight4091 6 лет назад +2

    Semma sir.continue

  • @adityawath7646
    @adityawath7646 2 года назад

    I watch his videos as brahmastra, when I didnt understood concept reading everywhere😅

  • @pjac744
    @pjac744 5 лет назад +3

    What would be the time complexity of this approach? Is it O(V*E)?

    • @dethswurl117
      @dethswurl117 5 лет назад

      The time complexity is the same as DFS which is O(V + E) according to: www.geeksforgeeks.org/articulation-points-or-cut-vertices-in-a-graph/

  • @divyanshuyadav4148
    @divyanshuyadav4148 5 лет назад +3

    how this algorithm will work for undirected linear graph (i.e. no cycle) ?

    • @mikloscsizmadia780
      @mikloscsizmadia780 4 года назад

      In that graph all of the vertices are articulation points exept the ones at the bottom of the dfs tree

  • @kermi123d
    @kermi123d 6 лет назад +1

    nice! but why not from 1 first to 2? i learned that its normal to do it in order. so 1-->2-->3-->5-->6-->3-->4-->1

    • @kermi123d
      @kermi123d 6 лет назад

      @@abdul_bari THX=)

    • @0anant0
      @0anant0 4 года назад

      The general algorithm for DFS visit is: while not visited, do DFS visit. So it doesn't matter where you start. You will get a diff DFS tree based on where you start and the order of nodes in the adj list.

  • @PBNinja
    @PBNinja 5 лет назад

    What if the vertex chosen when comparing has no back edge? What would be his Lowest Number? Should it be its discovery time? or the discovery time from its last descendant?

    • @PBNinja
      @PBNinja 5 лет назад

      @@abdul_bari Thank you very much!! You are the best

    • @satishchandramedi9729
      @satishchandramedi9729 3 года назад

      --------------------------------------- Credits: Ray Wang -------------------------------------------------------
      cp-algorithms.com/graph/cutpoints.html
      I'm still trying to understand it, but I understand it as this: We root the graph arbitrarily, creating a tree-like structure (i think it's called a dfs-tree), then notice 2 observations:
      A node is an articulation point if: it's the root and has more than 1 child OR
      A node is not the root and none of it's children have a back edge to the node's ancestors (aka. there's no cycles that lead back)
      To efficiently check if a node meets the second observation, we use the L and d arrays. Instead of thinking of L as low, think of it as the earliest time we visited a node. If the earliest time we visited a child (aka. L[v]) is less than the time we visited our current node (d[u]) then that means in our dfs, we visited v from an ancestor, which means v has a back-edge to an ancestor.
      More formally: iff L[v] < d[u], u is not an articulation point. Therefore, if L[v] >= d[u], u is an articulation point.

    • @PBNinja
      @PBNinja 3 года назад

      @@satishchandramedi9729 Thanks for the reply! I already passed the exams though. It was hard but this channel basically helped me a lot!

    • @satishchandramedi9729
      @satishchandramedi9729 3 года назад

      @@PBNinja That's great! But it might help you during campus recruitment hiring questions!

  • @DeekshithaRayabandi
    @DeekshithaRayabandi Год назад +2

    thankyou sir

  • @ayush5234
    @ayush5234 3 года назад +1

    Instead of L[v] >= d[u] , i wrote L[v]>=L[u]
    It passes most of the test cases but obviously some are failing. I am not able to draw any graph for which L[v]>=L[u] produces incorrect result. Can anybody help?

  • @himantabiswadeka6922
    @himantabiswadeka6922 3 года назад

    Sir, what if we take an array of size equal to that the number of vertices and insert the total number of incident edges per vertex( like we can calculate the indegree and outdegree of a directed graph), then input the adjacent matrix of the corresponding graph, the vertex having highest number of incident edges will be the articulation point in most cases! Sir, I don't have much knowledge regarding that, just asking can we do that?

  • @JayPatel-ur7ho
    @JayPatel-ur7ho 26 дней назад +1

    What about vertex 6? There is no child of 6.

  • @georgejoseph2553
    @georgejoseph2553 3 года назад

    Thankyou sir... 🙂

  • @arbazshaikh4447
    @arbazshaikh4447 4 года назад +2

    Great Explanation, Can you please make a video on Critical Connection in Networks Leetcode 1192

  • @destroyer_x9595
    @destroyer_x9595 Год назад

    Sir what happens if the graph has only one back edge ?
    will the values of L of those corresponding vertices be 0 ?

  • @notanonymous3976
    @notanonymous3976 2 года назад

    is the lowest number the lowest vertex value or the lowest discovery time?

  • @shahidsiddiqui6013
    @shahidsiddiqui6013 3 года назад

    Super understandable !

  • @sachidrolia9628
    @sachidrolia9628 5 лет назад +2

    sir please upload videos for decrease and conquer, transform and conquer

  • @thepinkcodon
    @thepinkcodon 4 года назад

    Sir, what do we do if we have to find cut vertices/articulation points bw a unique source and a unique sink in a DAG (Directed Acyclic Graph)?

  • @tadassatafarra7503
    @tadassatafarra7503 4 года назад +1

    why the L(6), i.e. L of vertex 6 isn't 1?
    we can use the path 6->3->2->1 and because L(1)=1 we can say that L(6)=L(1)=1

    • @mikloscsizmadia780
      @mikloscsizmadia780 4 года назад +1

      We can only go down on the tree, and ONCE we can go on a back-edge.

  • @afreedmohmmad
    @afreedmohmmad Год назад

    Sir what if back edge is not present for last number in spanning tree?what is lowest discovery number

  • @vishalgoyal9180
    @vishalgoyal9180 4 года назад

    By seeing your demonstration style i just want to buy your complete course.
    Is there any coupon available please .

    • @abdul_bari
      @abdul_bari  4 года назад +1

      Vishal there no other course on algorithms

  • @ashb8552
    @ashb8552 9 месяцев назад +1

    For 5 and 6
    Why cant we go from 3 to 2 and then 1
    Like 5->6->3->2->1

  • @JoffreyB
    @JoffreyB 4 года назад +2

    what if there's no back edge from a vertex?

    • @jay-rathod-01
      @jay-rathod-01 3 года назад

      assume there is no 6 vertex so now acc to formula 5>=3 so we still know that the d[3]=3 is still a articulation point. try it.

  • @user-um8ps3tl7h
    @user-um8ps3tl7h 5 лет назад +2

    Thank you ^^

  • @AnitShrestha
    @AnitShrestha 5 лет назад +1

    Thank you.

  • @lifeatovarun
    @lifeatovarun Год назад +2

    Sir this game aid i don't like it's does not touch supermacy of this channel it's really precious no need such

  • @shikhavyaghra3347
    @shikhavyaghra3347 3 года назад

    Wont 2 will be visited first as it come first in lexical order

  • @michaeldeguire2410
    @michaeldeguire2410 5 лет назад

    Why is vertex 1 not considered an articulation point since the low(4) = 1 and the num(1) = 1 -> 1>=1 ???

  • @sayandey1478
    @sayandey1478 3 года назад

    low [6] can be 1 also, why is it 3? we can go 1 via 3, right? I know it should be 3 but why? what's the definition

    • @harshitha.m.4189
      @harshitha.m.4189 3 месяца назад

      We can only go down on the tree, and ONCE we can go on a back-edge.

  • @shitposting2234
    @shitposting2234 5 месяцев назад +2

    one piece mentioned

  • @ajay.chawla
    @ajay.chawla 6 лет назад

    The back edges how are they used and how to connect them to find L. For one of the question there were only 2 back edges and thus i got L value 1 for all vertices. I didn't understand about L.

    • @ajay.chawla
      @ajay.chawla 6 лет назад

      @@abdul_bari sir suppose if the node is far from a back edge then what to do how to traverse that and get L for it

    • @ajay.chawla
      @ajay.chawla 6 лет назад

      Okay sir got it. Thank you :)

    • @satishchandramedi9729
      @satishchandramedi9729 3 года назад

      --------------------------------------- Credits: Ray Wang -------------------------------------------------------
      cp-algorithms.com/graph/cutpoints.html
      I'm still trying to understand it, but I understand it as this: We root the graph arbitrarily, creating a tree-like structure (i think it's called a dfs-tree), then notice 2 observations:
      A node is an articulation point if: it's the root and has more than 1 child OR
      A node is not the root and none of it's children have a back edge to the node's ancestors (aka. there's no cycles that lead back)
      To efficiently check if a node meets the second observation, we use the L and d arrays. Instead of thinking of L as low, think of it as the earliest time we visited a node. If the earliest time we visited a child (aka. L[v]) is less than the time we visited our current node (d[u]) then that means in our dfs, we visited v from an ancestor, which means v has a back-edge to an ancestor.
      More formally: iff L[v] < d[u], u is not an articulation point. Therefore, if L[v] >= d[u], u is an articulation point.