文件名称:dfa
-
所属分类:
- 标签属性:
- 上传时间:2016-11-09
-
文件大小:3.35kb
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
1) move[][]是状态迁移函数,move 的每一行代表一个状态,每一列代表一个输入符号,第0 列代表’a’,第1 列代表’b’,……,依此类推. 例如:move {{1,0},{1,2}, …},则表示此DFA 在状态0 时,当输入为’a’时,迁移到状态1,当输入为’b’ 时迁移到状态0;而DFA 在状态1 时,当输入为’a’时,迁移到状态1,当输入为’b’时迁移到状态2. 注意:默认状态0 是DFA 的初始状态.
2) accept_state[]是接受状态的集合,如accept_state[] {2, 3},则表示状态2和状态3 是接受状态.
3) word 是待识别的字符串.
如下例:
move accept_state word recognizeString()返回值
{{1,0},{1,2},{1,3},{1,0}} 3 aaabb true
同上 同上 abbab false
上表中move 和accept_state 表示的自动机如下图所示
-1) move [] [] is the state transition function, each line represents a move in the state, each column represents an input symbol, the first 0 on behalf of ' a' , the first representative of a ' b' , ......, and so on. For example: move {{1,0}, {1,2}, ...}, it means that the DFA state in 0:00, when the input is ' a' , the move to state 1, when the input migrated as ' b' when to the state 0 and DFA in the state 1, when the input is ' a' , the move to state 1, when the input status is migrating to ' b' 2. Note: the default state is the initial state of DFA 2) accept_state. [] is the set of accepting states, such as accept_state [] {2, 3}, it indicates that states 2 and 3 are accepting state 3) word is a string of cases to be identified as follows:.. move accept_state word recognizeString () returns value {{1,0}, {1,2}, {1,3}, {1,0}} 3 aaabb true ditto on abbab false move and automatic machine table accept_state represented as shown below
2) accept_state[]是接受状态的集合,如accept_state[] {2, 3},则表示状态2和状态3 是接受状态.
3) word 是待识别的字符串.
如下例:
move accept_state word recognizeString()返回值
{{1,0},{1,2},{1,3},{1,0}} 3 aaabb true
同上 同上 abbab false
上表中move 和accept_state 表示的自动机如下图所示
-1) move [] [] is the state transition function, each line represents a move in the state, each column represents an input symbol, the first 0 on behalf of ' a' , the first representative of a ' b' , ......, and so on. For example: move {{1,0}, {1,2}, ...}, it means that the DFA state in 0:00, when the input is ' a' , the move to state 1, when the input migrated as ' b' when to the state 0 and DFA in the state 1, when the input is ' a' , the move to state 1, when the input status is migrating to ' b' 2. Note: the default state is the initial state of DFA 2) accept_state. [] is the set of accepting states, such as accept_state [] {2, 3}, it indicates that states 2 and 3 are accepting state 3) word is a string of cases to be identified as follows:.. move accept_state word recognizeString () returns value {{1,0}, {1,2}, {1,3}, {1,0}} 3 aaabb true ditto on abbab false move and automatic machine table accept_state represented as shown below
(系统自动生成,下载前可以参看下载内容)
下载文件列表
dfa.doc
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.