首页 | 本学科首页   官方微博 | 高级检索  
     

基于深度优先搜索的一般图匹配算法
引用本文:虞成诚,钟声,胡绍华.基于深度优先搜索的一般图匹配算法[J].计算机工程与科学,2008,30(12):45-48.
作者姓名:虞成诚  钟声  胡绍华
作者单位:1. 海南大学计算机科学与技术系,海南,海口,570228
2. 南昌广播电视大学,江西,南昌,330000
基金项目:海南省自然科学基金资助项目,海南省教育厅资助项目
摘    要:对于一般图的匹配问题,Edmonds算法以Berge定理为基础,采用广度优先搜索增广路,图中可能存在“花”。遇到这种情况,要对它进行缩减“花”处理,再进行搜索。当找到增广路时,要将缩减图恢复,算法显得复杂。Gabow等算法使用先给固的顶点和边编号,并使用了不同数组和虚拟顶点,避免了处理花。算法的复杂性为O(n^3),但增加了空间复杂性。本文提出的基于深度优先搜索算法,在搜索增广路时不会出现“花”的情况,算法相对简单;同时,算法时间效率为O(n*degree(n)),degree(n)为顶顶点的平均度数。另外,当图的边动态增减时,使用该算法可以很快调整最大匹配,并且该算法空间复杂性在同一数量级也可以推广到广度优先搜索。

关 键 词:匹配问题  组合优化算法  图匹配

Matching Algorithms for General Graphs Based on Depth-First Search
YU Cheng-cheng,ZHONG Sheng,HU Shao-hua.Matching Algorithms for General Graphs Based on Depth-First Search[J].Computer Engineering & Science,2008,30(12):45-48.
Authors:YU Cheng-cheng  ZHONG Sheng  HU Shao-hua
Affiliation:YU Cheng-cheng1,ZHONG Sheng1,HU Shao-hua2
Abstract:For the matching problem of general graphs,the Edmonds algorithm is usually used.When the breadth-first search algorithm is used to find an augmenting-path,a "flower" may be produced.In order to solve this problem,we can cut short the "flower" into a point,and keep on searching,then the obtained graph after finding the augmenting-path is rehabilitated.The time efficiency of the algorithm is O(n4)since the graph is cut short and rehabilitated.However,when using the Gabow algorithm to find the augmenting-path,we should assign a fixed serial number to node and edges,and use different arrays and pseudo node,thus we need not to deal with the "flower",and the time efficiency of this algorithm is O(n3),but the space efficiency of the algorithm is reduced.This paper proposes a depth-first search algorithm,and it is shown that using the proposed algorithm,the "flowers" will not appear when searching an augmenting-path.Moreover,the time efficiency is increased to O(ndegree(n)),where degree(n)denotes the average degree of nodes.In addition,when either appending or deleting the edges in the graph,maximum matching can be computed quickly.It should be pointed out that if we follow this idea to consider the breadth-first search,the order of magnitude is identical to the one in depth-first search.
Keywords:matching problem  combinatorial optimization algorithm  graph matching
本文献已被 CNKI 维普 万方数据 等数据库收录!
点击此处可从《计算机工程与科学》浏览原始摘要信息
点击此处可从《计算机工程与科学》下载全文
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号