1

Why is the language $A=\{wtw^r: w,t\in\{0,1\}^*\text{ and }|w|=|t|\}$ not a context free language?

It is turning out to be really tricky. Is there an easy way to show this?

  • 1
    I tried pumping lemma but I think the problem is more tricky than I think. –  Nov 12 '15 at 20:32
  • 1
    Were you trying to prove it's context free or trying to prove its not ? If you tried proving it is, how pumping lemma is of help ? – advocateofnone Nov 12 '15 at 20:38
  • Please try to select more descriptive titles in the future that will be more helpful to others in describing or finding your question ("A context free language" is not very descriptive). – D.W. Nov 12 '15 at 20:51
  • Does this string work $1^{2p}0^p1^p1^{2p}$? –  Nov 12 '15 at 20:53
  • 1
    What have you tried? Have you tried the methods in our reference questions, e.g., http://cs.stackexchange.com/q/265/755 and http://cs.stackexchange.com/q/18524/755 and http://cs.stackexchange.com/q/33228/755? Have you searched carefully through other questions tagged [tag:context-free]? We expect you to search carefully and exhaust all approaches you can think of before asking, and to show us in the question what you tried. – D.W. Nov 12 '15 at 20:54
  • 1
    What do you mean "work"? Work for what? If you're trying to apply the pumping lemma, don't just guess -- try to work out the details carefully, and then write it down in the question. This may require substantial work on your part, but you're asking for help from others, so we expect you to do whatever parts you can on your own. – D.W. Nov 12 '15 at 20:55
  • 1
    Without trying it, I'd at least say that you're on the right track. What's wrong with trying the simpler $0^p1^p0^p$? (Again, having not tried it--just off the top of my head.) – Rick Decker Nov 12 '15 at 20:56
  • @RickDecker Does it work? I think there is a catch. –  Nov 12 '15 at 21:06
  • 1
    Could be. Try it or try your original idea. You'll learn a lot less if we did it than if you did. – Rick Decker Nov 12 '15 at 21:10

0 Answers0