Pumping Lemma (For Regular Languages) | Example 1

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

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

  • @rayansailani4465
    @rayansailani4465 4 года назад +93

    Just to clarify things. the explanation is correct in the sense that he checks for the |xy|

  • @DMJ-wx9wq
    @DMJ-wx9wq 7 месяцев назад +3

    I think another approach to this question to make it more understandable to solve would be:
    - When partitioning w into xyz, partition such that the other 2 cases (exclude the case of pumping i >0) are also satisfied
    - With the cases you have (where the 2 other conditions satisfy), apply the pumping conidition i.e i = 1,2,3,4...
    - If any case fails then the pumping lemma fails
    Hope this helps.

  • @nasirmehmood7834
    @nasirmehmood7834 7 лет назад +352

    I think we are not suppose to proof second and third condition as |y| >0 & |xy|

  • @mustafaalan584
    @mustafaalan584 2 года назад +38

    Giving a value to P is not a correct solution for most of the University Exams and not an exact solution. Instead please give K+L+M to P. [ x=a^K, y=a^L, z=a^M+b^P ] Then when you increase the i which is on top of y, you will see that on the left side there will be L more a's according to rule |y|>0 . This is how you prove that it is not a regular language. (Case 2 and 3 are cancelled by the Rules 2 and 3. That's why there is no point to check those cases)

  • @hugonguyensg8402
    @hugonguyensg8402 2 года назад +21

    The part where you actually define p=7 is potentially misleading because p is just a symbolic threshold and will be useful in cases such as proofing inequalities by utilizing the 2nd and 3rd conditions in pumping lemma. So we don't necessarily need to know what is p. This example just need to use the 1st condition of the lemma to proof.

    • @adhikarisarthak
      @adhikarisarthak 7 месяцев назад +1

      Thank you! I lost 15 points because of this in my midterm.

  • @zihengtang8718
    @zihengtang8718 3 года назад +3

    the idea is that p is an abstract length, given that length of (xy) must be equal or less of p, y can only consist of letter(a)s, since the rule is a^pb^p. howeve given y is all letter(a)s, xy^iz for all i>=0 is not in the language, thus that it is not regular for any p value

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

    The pumping lemma was pumping me because my professor didn't teach it well. However you taught this so well thanks!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

  • @cyeganeh
    @cyeganeh 6 лет назад +10

    dude you fucking saved me for my final man. my teacher and tas could not teach this for their life, and your 2 videos on pumping lemmas explained what they could not explain. They had 2 and a half hours and you did it in 20 minutes. Thank you.

  • @ajinkyawandale2857
    @ajinkyawandale2857 7 лет назад +26

    In case 2 |xy| = 13 and in case 3 |xy| = 9 which violates the condition of pumping lemma which states that |xy| should be less than of equal to pumping length ( here 7 )

    • @nishatsayyed8326
      @nishatsayyed8326 7 лет назад

      Ajinkya Wandale how to find the values of |xy|???
      plz explain... that's the biggest confusion i am facing...

    • @Apreston14
      @Apreston14 7 лет назад +2

      it's just how many characters are in the x part + how many characters are in the y part

    • @ashishkumarpandey57
      @ashishkumarpandey57 7 лет назад +1

      since |xy|>P (P=7) in case 2 and case 3,they are invalid divisions of S into x, y and z. So proceed using case 1 only(there is only one way to divide S into x, y and z).

    • @85Esparta
      @85Esparta 6 лет назад

      yes, he explains this in the video, so in two different ways those two cases(2 and 3) are not pumpable

  • @thomaswillems6384
    @thomaswillems6384 4 года назад +63

    Thank you so much, this is so much clearer than how my professor teaches the pumping lemma, great job!

  • @yuriileso773
    @yuriileso773 6 лет назад +15

    In the 2nd and 3rd case you have broken 2th PL rule.
    I would recommend to use some parameters, not numerical values
    F.E. case 2:
    Let say, that PL length is just p;
    So, we chose the next string: a^p.b^p.
    x = a^t.b^s
    y = b^n
    z = b^i
    The 2nd rule of PL tells, that |xy|

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

      I'm trying to follow your explanation but got stuck at the "t+s+n

  • @SadmanAmin96
    @SadmanAmin96 7 лет назад +140

    Why we are going for case 2 and 3? They already broke the rule of |xy|

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

      Same doubt.

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

      How do you know to which category the pumping string belongs to? I mean, if we give a counter example for one case, we assume that the pumping string 'y' contains only a's. But we cannot be sure of that. What if the pumping string contains only b's (or) contains a mixture of both a's and b's. That is why we have to give a counter-example for all possibilities

    • @bkissa12
      @bkissa12 6 лет назад +3

      Thought the same. We had to divide it right first

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

      agreed

    • @미엘1
      @미엘1 5 лет назад +3

      @@aravindm5061 but, It doesn't satisfying case 2, 3

  • @saiakshay7659
    @saiakshay7659 3 года назад +11

    Thanks Neso academy for making me more confuse then I already was,The funny part is my cute little lecturer also followed this video and guess what, even he don't know why he assumed pumping lemma p=7 same as you

  • @umairzahid9290
    @umairzahid9290 5 лет назад +26

    At 6:40 |XY|

  • @chaturthi1920
    @chaturthi1920 2 года назад +14

    Please continue doing this great work sir ...it means a lot..

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

    Case 2 and case 3 are wrong. In these cases, |xy| is being grater than p, which is not possible. Case 2 and 3 would be possible is we would have taken the S something else like a^4 b^4 etc.

  • @philfernandez8526
    @philfernandez8526 4 года назад +13

    Thanks for making me more confused than I already was!

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

    Is there a reason that we are choosing y to be length of 4 for all of the cases?
    Also: for case 3 can y = aaab?

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

      I think yes, the point is just for finding a y that cannot be satisfied.
      Btw, I think in case 3, no matter how you choose the y string, the condition 3 |xy|

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

    L={a^i b^j c^k a^l b^m c^n | i>=3, j>=1, k>=2, l is an even number, m is odd no and n is any number divisible by 3 }
    Plz make video for this.

  • @unzilechris1330
    @unzilechris1330 7 лет назад +5

    This is great, thank you. I now understand how the pumping lemma works.

  • @shin81able
    @shin81able 4 года назад +6

    Thanks a lot for this video. One thing I don't get is the divide S part. Can you decide as u want or is there any rules for dividing or spliting into xyz strings? You mention there three cases:
    case 1: aaa aaaa bbb bbbb
    -> why does x has two a's and y four a's instead x has one a and y has 6 a's and z has all b's?
    x= aa
    y=aaaa
    z= abbb bbbb
    case 2: aaa aaaa bbb bbbb
    -> why do you split like this? Is there any reason?
    x = aaa aaaa bb
    y = bbbb
    z = b
    case 3: aaa aaaa bbb bbbb
    -> why do you split like this? Is there any reason?
    x = aaa aa
    y = aabb
    z = bbbb
    Thanks a lot for you answer

    • @jiaxuanng2396
      @jiaxuanng2396 2 года назад +8

      Bit late for this one, but yes, you may as long as it matches the case e.g. in the example a^n b^n. So it says case 1, a belongs in y; you could even have it so the substring x is empty e.g.:
      take p as 7:
      x=ϵ
      y=aaaaaaa
      z=bbbbbbb
      to verify the case:
      take i as 2 therefore we double the amount of a's =>
      x=ϵ
      y=aaaaaaaaaaaaaa
      z=bbbbbbb
      still this is broken as number of a's should equal number of b's
      However, at any point the y substring may not be empty as it would break the rule that |y| > 0.
      Hope it helps!

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

      @@jiaxuanng2396 tqsm

  • @jedc14
    @jedc14 6 лет назад +7

    The moment you give a fixed value to P, the theorem proves nothing. Also the cases 2 and 3 make non-sense, since they violate the constraint |xy|

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

    i can not afford to buy paid your course. i am in 3rd sem now btech. pleaseeeeee dont remove these lectures. its is extremely helpfull

  • @blindprogrammer
    @blindprogrammer 7 лет назад +15

    in the case 2: |XY| = 13 which is a violation of theorem as |XY|

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

      it is not a mistake. if the language was regular, |XY|

    • @STxFTW
      @STxFTW 6 лет назад +15

      @@TheFixieGuy This is not correct! We need to use make sure that all the theorem are "true" first in order for us to "use" the pumping lemma, if the conditions aren't true then that means that we cannot use the pumping lemme on that specific string in the first place

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

      @@STxFTW true

  • @n-4-v
    @n-4-v 3 года назад +8

    Neso Academy : Asks to go check out the previous video to view the theory.
    Also Neso Academy : Proceeds to show contents of previous video to solve example...

  • @akashvaidsingh
    @akashvaidsingh 7 лет назад +53

    plz sir upload these video as fast as possible ,
    Bcoz my exam is close.

    • @AndyD6
      @AndyD6 6 лет назад +14

      how did you do in your exam? i hope you did well, brotha. good luck to your past self

    • @rj-nj3uk
      @rj-nj3uk 5 лет назад

      @@AndyD6 backlog...

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

      @@rj-nj3uk what is backlog? ?

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

      @@AndyD6 it means he failed the exam lol.

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

    pumping lemma is a very broad and complicated topic; its really nice that you go into detail with the specific cases, but i think you should explain that the proof is not complete at the state you left it at; you only proved it for a specific P, and a specific length for Y. The video is great for forming intuition, but not a perfect step by step guide for proofs

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

    00:03 Example of proving a language is not regular using Pumping Lemma
    01:31 Proving regularity using Pumping Lemma
    03:02 Introduction to Pumping Lemma for Regular Languages
    04:54 Explanation of dividing a string into three parts
    07:14 Explaining the division of string into parts XY and Z
    09:20 Counting S and B occurrences for regular language verification
    11:02 Pattern mismatch leads to not being regular
    12:43 Pumping Lemma shows language is not regular

  • @dev4life
    @dev4life 5 лет назад +15

    how to assume pumping length?

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

    This is VERY transparent. Thank you.

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

    What if this lemma doesn't satisfy for P = 7, but does so for P > 7? For P > 100? You should prove it for a general case.

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

      For a general P,. you have to consider aaa...aa bbb...bbb with P a's and P b's.

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

      If it failed for P=7, that simply means Language isn't regular. Then there's no point in doing the same for all the other no of P.

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

      @@shahinshaikh07 that’s not true

  • @inowhy1930
    @inowhy1930 7 лет назад +7

    You are very good at explaining things! You must know that :) Thanks for the help!

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

    sir you can also provide the lectures notes for the particular video or the end up of the course . Its really helpful for me to learn easy manner

  • @computerknowledgehub
    @computerknowledgehub Год назад +1

    You are superb sir

  • @alexrubio40
    @alexrubio40 7 месяцев назад +1

    You a hard topic incredibly simple to understand, thank you

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

    If we set the pumping length to 7, S may be aaaabbbb, aaaaabbbbb, aaaaaabbbbbb, etc. Since we are proving the language A is not regular by contradiction, we only need to find one counterexample. The lecturer just selected aaaaaaabbbbbbb. Hope this reply may help someone who gets confused.

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

      proving by counter example and proving by contradiction are not the same thing

  • @brahimimohamed261
    @brahimimohamed261 Год назад +5

    I think that you can't use only p=7. Maybe this language is regular but it requires more than 7 states to be able to pump. This should be prooved with arbitrary p.

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

      I agree, the 7 here should be used just as an illustration, but the proof must be for an arbitrary p

    • @sunnycyberbum
      @sunnycyberbum Год назад +4

      @@rayanzakariahassici1936 but why isn't one contradiction enough?

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

    I've watched a lot of videos and read through a lot of books, but this is the first time I really understand pumping lemma

  • @zahiralam5440
    @zahiralam5440 7 лет назад +1

    please upload more video on context free grammer. and also upload about drawing a finite automata from context free grammers. thank u so much your video is helpful

  • @asadfarooq691
    @asadfarooq691 6 лет назад +3

    V good method of delivering Knowledge

  • @pratikshayeole6713
    @pratikshayeole6713 6 лет назад +7

    Sir how to select Y in a&b part?

  • @AhamedKabeer-wn1jb
    @AhamedKabeer-wn1jb 4 года назад +2

    Wonderfull explanation..

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

    Thank you, I read my lecture 3 times and it seamed so confusing and complicated. You make it look so easy just in 14 min. Thanks again!

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

    why u assume 7 in that pumping leagnth

  • @dhruvkotegaonkar300
    @dhruvkotegaonkar300 7 месяцев назад

    Sir course is no doubt awesome, but the background music at the end is🤌🤌🤌

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

    Very nice example and very nicely explained. Thanks !

  • @saurabhshrivastava224
    @saurabhshrivastava224 7 лет назад +4

    Can anyone please elaborate on what exactly is meant by pumping length? Examples would be appreciated.

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

    The condition 3 for pumping lemma is not satisfied can we still continue for proving it like this as explained!!???

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

    the length of xy in case 2 is greater than p
    but you earlier stated that the length of xy should be less than or equal to p

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

    Amazing explanation, does the choice of P matter? Thanks again!

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

      Nope

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

      It matters if you havent reached the minimum pumping length, you can choose any value including and over the minimum pumping length

  • @kittibilli140
    @kittibilli140 5 месяцев назад +1

    11:26 a=9,b=9 so why xy²z is not belongs to A it satisfy the condition please reply sir🙏🙏🙏🙏🙏🙏

    • @metalempire7926
      @metalempire7926 5 месяцев назад

      Because it doesn't follow the pattern of a^n b^n

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

    Sir, Can we assume P (also length of x,y and z)as any arbitrary number or is there any condition to choose? where P, |x|, |y| and |z| > 0

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

    so.... why 7? How do we choose p?

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

    Helpful and easy to understand

  • @somalinetworksolution283
    @somalinetworksolution283 7 лет назад

    thanks Sir please complete for us the course

  • @AnasKhan-gt5qe
    @AnasKhan-gt5qe 7 месяцев назад +1

    In case 2 and 3 the |xy| is not less than or equal to pumping lenght 7. Im confused 7:41

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

    Sir, In case 1
    There should be 16a
    Because we choose y=4 and we have to square the value of i.

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

      There should be only 8a - the exponent is special operation over strings

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

    All are ok but case no 3 seems mistake because here no of a=no of b after spliting s and again counting .
    so here its a regular language and you skipped counting of no of a and b in this case.
    pls check it sir...
    thank you a lot...

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

    what if it were a^n*b^m instead of a^n*a^n?

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

    How we divide the string in the 3 parts ... how you choose the length of X,Y&Z..?

    • @nibuer
      @nibuer 6 лет назад +20

      for people reading this now, it doesnt matter how many y's and x's you take in y aslong as it is less then the pumping length which he choose is 7. Case 2 and 3 he just proved it but before he even pumped it fails condition 2. Why? Because in order for you to even take b's for y x would have to be all of the a's so even if you took 1 b as y or 2 b's as y. No matter how many you take it will be over the pumping length but he just pumped it to prove it still is not regular. Samething goes for when y is in ab you can take 1a and 1b still have to take 6 a's and you will have a length of 8! Good luck every1 this class sucks dick

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

      Same doubt

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

    That is so stupid, i can choose "length of 3 will be in my language" and following the instructions, I will not have a string in my language

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

    Nyc vedio...Easy to understand...ty

  • @theworldstudy2199
    @theworldstudy2199 Год назад +1

    Why having 4 'a's initially when you raise 'a' to the power of 2 you write 8 'a's instead of 16?

    • @nabeelmirza8801
      @nabeelmirza8801 8 месяцев назад

      In string math, the power means that we are just concatenating. If power is 2, concatenate twice, if power is three, concatenate thrice

  • @ozgeaktas403
    @ozgeaktas403 Год назад +1

    abi cok iyisin ahmet hoca slayta hic boyle koymamis

  • @dr.nicksiz8251
    @dr.nicksiz8251 Год назад

    İngilizce bilenler için pahabiçilmez bir kaynak. İyi ki varsınız lan.

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

    case 2 is not possible because length of xy is not less than 7

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

    There might be a possibility that one of the three cases may satisfy xy^iz then should we consider regular or not regular

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

    Great Sirji
    Thanks a Lot

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

    Such a nice explanation.

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

    THANK YOU SO MUCH!! YOU ARE THE BEST!!

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

    Hey lenght of xy should be less than equal to p

  • @jamescommon478
    @jamescommon478 11 месяцев назад

    When adjusting the xyz values I think we always have to make sure that the conditions |y|>1 and |xy|

    • @nabeelmirza8801
      @nabeelmirza8801 8 месяцев назад

      Regarding your statement 1: Yes
      Statement 2 : p could be any number, you can take it as 1, or 1 billion

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

    What if one the three is equal to p sir

  • @conceptualstudy7196
    @conceptualstudy7196 8 месяцев назад

    What is pumping length? How it is 7 in our case....??? Waiting for reply

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

    You just saved my life, thanks!

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

      He crushed it rather.

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

    LOVE IT! Thank You So Much Sir!

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

    how did you split up x y and z

  • @suyash.01
    @suyash.01 4 года назад +78

    It is the first time I've seen this in Neso's videos. The explanation is incorrect!!!!

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

      Why?

    • @bro-ro2og
      @bro-ro2og 2 года назад

      Yes...

    • @ljdash9144
      @ljdash9144 2 года назад +14

      Because he is showing 2 cases in which obviously |xy| fails to be less or equal to P

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

      It's correct

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

      @@ljdash9144 if those 2 cases gets correct then it is regular...

  • @OtherDude
    @OtherDude 4 года назад +7

    Be careful doing proofs like this on an actual assignment. I lost points because I assumed a value for P

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

      What approach should we take then? :E

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

      @@rujin6259 just prove it for general P

  • @rj-nj3uk
    @rj-nj3uk 5 лет назад +1

    Exam se ek din pehle sab yahi discuss kar rahe hain. "Yeh pumping lemma kis bakre ka naam hain..".

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

    But the rule says to show that none of the cases satisfies all three conditions at the same time. But case 1 clearly satisfies all three conditions at the same time. So how is it not.regular

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

    When checking for the property |xy|

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

    You forgot to reject your first assumption by the end , "by contradiction A is not regular language".

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

    Well explained ❤️ thank you ❤️

  • @-BLakhan
    @-BLakhan Год назад

    sir can we say if any 1 of 3 conditions is violated then language is not regular

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

    Is case 2 and 3 the length of xy is not less than or equal to pumping length. Then why are you taking it like that?

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

    i love you thanks for the amazing explanation! better than my professor!

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

    Case 2 and case 3 are not applicable in the pumping lemma method since |xy| > P. Very misleading.

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

    if only i can get my bachelors in cs by watching all ur videos

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

    if we are proving 3 case that all 3 conditions are true or not then if case 1 satisfy |XY|

  • @saurabhdhoot1273
    @saurabhdhoot1273 7 лет назад

    sir please i request you to Complete your reasoning and aptitude series lectures...please as soon as possible

  • @istiaquehanindo3684
    @istiaquehanindo3684 4 месяца назад +1

    They call me the pumping LLama

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

    but in case-3 get equal no.of a's and b's ...?

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

    what abount |y| > 0 ?

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

    how to take x ,y, z conditions in a string

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

    In case 2 and 3 |xy|

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

      finally someone noticed it, also he didn't explained how to choose min pumping length

  • @AadeshingaleOfficial-zl5fd
    @AadeshingaleOfficial-zl5fd 3 месяца назад

    Nice Sir 😊

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

    I don't understand how you divide the xyz

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

    How do you know that P isn't greater than 7?

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

    What is the logic of dividing s=xyz?