带有连接的常规语言

发布于 2024-10-31 13:07:50 字数 116 浏览 1 评论 0原文

常规语言在以下操作下是封闭的:

init(L) = 字符串 w 的集合,使得对于某些 x,wx 在 L 中。

编辑: x 可以是任何字符串、字符或空字符串 我怎样才能证明这一点?

the regular languages are closed under the operation:

init(L) = the set of the strings w such that for some x, wx is in L.

EDIT :
x can be any string, a character or empty string
How can I prove that ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

弃爱 2024-11-07 13:07:50

好吧,第一次看错问题,现在明白了。这仍然是微不足道的。查看自动化,您搜索的是自动化的一部分,分为两个状态集 S1 和 S2,因此它们之间只有一个转换(如果它从 S1->S2 S1 当然包含起始节点,而 S2 包含结束节点)。这样的情况总是存在的(空语言除外),如果没有这样的节点可以添加一个,所以w只是一个包含空词的集合,这当然也是正则的(空语言情况也是如此)。

OK, misread the quesion on the first time, now I get it. It still trivial. Looking at the automate what you searching is a partion of the automate into two state sets S1 and S2, so that just one transition is between them (and if its from S1->S2 S1 contains of course the start node, and S2 the end node). Such exist always (exception empty language), in case there is no such node you can add one, so w is just a set containing the empty word, which is of course also regular (as well as the empty language case).

掩耳倾听 2024-11-07 13:07:50

除非我误会了,否则答案是你不能。因为这不是真的。

首先,让我们考虑语言 L = {aa, bb, cc} 和字母表 {a, b, c}

因此,init(L) = {a ,b,c}。但是,init(L) 中的每个元素都不在 L 中。

编辑:如果我们连接空字符,则 init(L) = {a, b, c, aa, bb, cc}。这仍然不等于L

Unless I'm misunderstanding, the answer is that you can't. Because it's not true.

First, let's consider the language L = {aa, bb, cc} and alphabet {a, b, c}

So, init(L) = {a, b, c}. However, each of the elemnts in init(L) are not in L.

Edit: If we are concatenating empty characters, then init(L) = {a, b, c, aa, bb, cc}. Which is still not equal to L.

走走停停 2024-11-07 13:07:50

一种语言是正规的,当且仅当有一个有限状态自动机可以识别它。因此,假设 L 是一种常规语言,而 A 是一个能够识别它的自动机。现在,如果有一组可能的转换从 A 开始并以“接受”状态结束,则称 A 的状态是“好”。定义一个新的自动机 A',其中所有到“好”状态的转换都被直接转换到接受状态所取代。那么A'识别的语言正是init(L)。

A language is regular iff there's a finite-state automaton that recognizes it. So, suppose L is a regular language and let A be an automaton that recognizes it. Now, say that a state of A is "good" if there's some set of possible transitions starting there and ending in the "accept" state. Define a new automaton A' in which all transitions to "good" states are replaced by direct transitions to the accept state. Then the language recognized by A' is exactly init(L).

桃气十足 2024-11-07 13:07:50

我认为这是一个新的DFA B,它使A(原始DFA)的所有状态可以达到A的最终状态为B的最终状态。

I think it's a new DFA B, that makes all the state of A(the original DFA) that can reach to the final states of A the final state of B.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文