# Determining if $L$ = {${ a^nsb^n : s \in L(a^*b^*) ,\ n \ge 1 }$} is not a regular language using Pumping Lemma?

In short, is this similar to how $a^nb^n$ is not a regular langauge?

$L$ = {${ a^nsb^n : s \in L(a^*b^*) ,\ n \ge 1 }$}

For instance, if we have the string $w=a^psb^p$, and we know that $|xy| \le p$, there would simply be a disproportianate amount of a's or b's regardless of where we put $y$ ?

Your language is equal to $L(a^+b^+)$ (why?).
You cant use the pumping lemma to show that a language is regular, you can only show that if the lemma fails, then it is not regular. As an aside, the language you gave is regular, and as Yuval has said it is $L(a^+b^+)$, another way to look at $L(a^+b^+)$ is $L(a^1a^*b^*b^1)$ a DFA is the easiest way to show this one.
• we dont need to keep track, as long as there is at least one a and one b we can always say that the rest of the a's and b's are a part of s and that $n=1$. The $n$ is the trick in this language. Even if $n$ is something higher like $n=100$ we can still parse the string so that $n=1$. Take $w=a^{50} s b^{50}$ let $s_2$ = $a^{49} s b^{49}$, $s_2 \in a^* b^*$ so $w = a^1 a^{49} s b^{49}b^1 = a^1 s_2 b^1$ – lPlant Sep 27 '17 at 14:00