-1

Prove that language $Y=a^p$, where $p$ is prime is not regular.

Look at my proposition - is it ok ?

I use pumping lemma. Let's assume that $Y$ is regular. Let $s \in Y$. For this word we have partition $s=xyz$ such that $|y|>0$. Also we have that: $xy^0z, xy^{2}z, zy^3z... \in Y$ However it is impossible. Let's get $d$ such that $|xy|\mod d=0$. And $|y^d|\mod d = 0$. So $|xy^dz|\mod d = 0$. So it is condruction.

  • Why the down vote? There are errors in OP's english, but the approach is reasonable. Pumping lemma is one way to approach these kinds of problems. – voldemort Mar 18 '15 at 01:33
  • 1
    Earlier appearances of this same question: http://math.stackexchange.com/questions/181230/why-isnt-this-a-regular-language ; http://math.stackexchange.com/questions/356145/proving-that-language-is-not-regular-by-pumping-lemma ; http://math.stackexchange.com/questions/355900/proving-that-language-is-not-regular-by-pumping-lemma ; http://math.stackexchange.com/questions/1191112/prove-that-language-is-not-regular-prime-numbers – MJD Mar 18 '15 at 01:36

1 Answers1

1

That doesn’t work I’m afraid: $|xy|\bmod d=0$ does not guarantee that $|xy^dz|\bmod d=0$. For example, you might have $|x|=|y|=1$, $d=2$, and $|z|=2$, in which case $|xy^2z|=5$.

If $|xz|=r$ and $|y|=s\ge 1$, $|xy^kz|=r+ks$, and you need to show that there is always some $k\ge 0$ such that $r+ks$ is composite. If $r>1$ this is easy: take $k=r$. If $r=0$ it’s also easy; why?

The hardest case is $r=1$. If $s>1$, let $k=s^2$; why is $1+s^3$ composite? And what can you do if $s=1$?

Brian M. Scott
  • 631,399