[英]If a regular language only contains Kleene star, then is it possible that it comes from the concatenation of two non-regular languages?
I want to know that given a regular language L that only contains Kleene star operator (eg (ab)*), is it possible that L can be generated by the concatenation of two non-regular languages?我想知道给定一个只包含 Kleene 星号运算符(例如 (ab)*)的正则语言 L,是否可以通过两种非常规语言的串联生成 L? I try to prove that L can be only generated by the concatenation of two regular languages.
我试图证明 L 只能由两种正则语言的串联生成。
Thanks.谢谢。
This statement is false.这种说法是错误的。 Consider these two languages over Σ = {a}:
在 Σ = {a} 上考虑这两种语言:
L 1 = { a n |
L 1 = { 一个n | n is a power of two } ∪ { ε }
n 是二的幂 } ∪ { ε }
L 2 = { a n |
L 2 = { 一个n | n is not a power of two } ∪ { ε }
n不是二的幂 } ∪ { ε }
Neither of these languages are regular (the first one can be proven to be nonregular by using the Myhill-Nerode theorem, and the second is closely related to the complement of L 1 and can also be proven to be nonregular.这两种语言都不是正则的(第一种可以用Myhill-Nerode定理证明是非正则的,第二种与L1的补码密切相关,也可以证明是非正则的。
However, I'm going to claim that L 1 L 2 = a*.但是,我要声明 L 1 L 2 = a*。 First, note that any string in the concatenation L 1 L 2 has the form a n and therefore is an element of a*.
首先,请注意串联 L 1 L 2中的任何字符串都具有 a n的形式,因此是 a* 的元素。 Next, take any string in a*;
接下来,取 a* 中的任何字符串; let it be a n .
让它成为一个n 。 If n is a power of two, then it can be formed as the concatenation of a n from L 1 and ε from L 2 .
如果 n 是 2 的幂,则它可以由 L 1中的n和 L 2中的 ε 串联而成。 Otherwise, n isn't a power of two, and it can be formed as the concatenation of ε from L 1 and a n from L 2 .
否则,n 不是 2 的幂,它可以由 L 1中的 ε 和 L 2中的n串联而成。 Therefore, L 1 L 2 = a*, so the theorem you're trying to prove is false.
因此,L 1 L 2 = a*,所以您要证明的定理是错误的。
Hope this helps!希望这可以帮助!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.