Is the language $a^nwa^n$ regular? The given description of language is:


  $\Sigma=\{a,b\}$ and $L=\{a^nwa^n:n\geq 1,w\in\Sigma^*\}$


I felt its regular as we can always interpret $aabaa$ in string $aaabaaa$ as $w$. That is we can always interpret $a^n(a+b)^*a^n$ as $a(a+b)^*a$. So isnt it correct to call this language regular. The book calls it not regular without any explanation. So I was just confused, what is correct.
Your language is regular, since it is identical to $a\Sigma^*a$.

Indeed, by definition of $L$, every word of the form $a\Sigma^*a$ is in $L$ (take $n = 1$). Conversely, every word in $L$ starts and ends with $a$ (and is of length at least 2), and so is of the form $a\Sigma^*a$.