# using pumping lemma prove this language is not a context-free-language [duplicate]

How can one prove that the language below is not context-free using the pumping lemma?

$$\{ a^i b^m a^j b^m a^k b^m \mid i,j,k,m \geq 0 \}$$

• You cannot, since this language is context-free. May 15 '17 at 18:51
• can explain more for your answer ? @YuvalFilmus May 15 '17 at 18:56
• can you build a PDA/define a CFG for $b^mb^m$? If so, you can do it also for $a^*b^ma^*b^ma^*$.
– abc
May 15 '17 at 19:05
• sorry , i edited the language , so you said there is no possible way to prove ? @newbie May 15 '17 at 19:20
• The point of exercises such as this is to give you practice in using the pumping lemma. Whatever learning resource you're using (textbook, lecture notes, etc) probably already has several examples of using the pumping lemma. Us turning this exercises into another example for you probably won't help you a whole lot: the benefit comes from figuring it out yourself. May 15 '17 at 22:12

Suppose that $a^* b^m a^* b^m a^* b^m$ is context-free. Applying the inverse of the homomorphism defined by $a\mapsto a$ and $b,c,d \mapsto b$, we see that $a^* (b+c+d)^m a^* (b+c+d)^m a^* (b+c+d)^m$ is also context-free. Intersecting with the regular language $b^* a c^* a d^*$, we see that $b^m a c^m a d^m$ is also context-free. Applying the homomorphism defined by $a \mapsto \epsilon$ and $\sigma \mapsto \sigma$ for $\sigma=b,c,d$, we see that $b^mc^md^m$ is also context-free. But we know that it's not context-free.
• @DavidRicherby I am using the pumping lemma to prove that $b^mc^md^m$ is not context-free... :) May 16 '17 at 7:02