简体   繁体   English

非确定性有限自动机接受和拒绝

[英]Non Deterministic Finite Automata acceptance and Rejection

Can an NFA ever accept a string which is not in the language? NFA 可以接受不在该语言中的字符串吗? I know that for an NFA to accept a string there has to be atleast one way by which it gets accepted and we can safely say that the NFA accepts it.我知道对于 NFA 接受字符串必须至少有一种方式来接受它,我们可以有把握地说 NFA 接受它。 But in case of Rejection ...can at times it may happen that if a string which doesn't belong to the language getting accepted by NFA?但是在拒绝的情况下......有时可能会发生这样的情况,如果一个不属于该语言的字符串被 NFA 接受?

The definition of the language accepted by an NFA says that it is the set of all strings that are accepted by the NFA. NFA 接受语言的定义说它是NFA 接受的所有字符串的集合。 So clearly, every string that is accepted belongs to the language, and thus the answer to your question is: No.很明显,接受的每个字符串都属于该语言,因此您的问题的答案是:不。

Rejection means: all possible computations for the given string either end in a non-accepting state or do not even read the entire string (if the automaton is not complete).拒绝意味着:给定字符串的所有可能计算要么以非接受状态结束,要么甚至不读取整个字符串(如果自动机不完整)。 Both of these possibilities exclude acceptance.这两种可能性都排除了接受。

For non-deterministic Turing Machines there exist notions of acceptance like: "more than half of the computations accept," or "an odd number of computations accept" ( Parity ) etc. There you can have accepting computations despite global rejection.对于非确定性图灵机,存在接受的概念,例如:“超过一半的计算接受”或“接受奇数个计算”(奇偶校验)等。尽管全局拒绝,您仍然可以接受计算。 But these notions are not widely used and I have never seen them applied to finite automata.但是这些概念并没有被广泛使用,我从未见过它们应用于有限自动机。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM