设计和评估计算数据库关系的传递闭包的算法

Hongjun Lu, K. Mikkilineni, J. Richardson
{"title":"设计和评估计算数据库关系的传递闭包的算法","authors":"Hongjun Lu, K. Mikkilineni, J. Richardson","doi":"10.1109/ICDE.1987.7272364","DOIUrl":null,"url":null,"abstract":"Recursive query evaluation is a capability of deductively-augmented database systems that conventional database systems do not support well, if at all. Many recursive queries involve computation of the transitive closure of a relation. Previously published algorithms for transitive closure are iterative in nature, performing repeated joins, unions, and differences until convergence is obtained. In this paper, we present an adaptation of Warren's algorithm for computing the transitive closure of a relation. Warren's algorithm was originally designed for a bit matrix representation of a binary relation; we have adapted it for use with a binary relation represented as a set of tuples, as in a relational database management system. This adapted algorithm computes the transitive closure in two passes over the relation. We analyze the performance of this algorithm, and compare it to the performance of two algorithms based on relational algebra: an iterative algorithm, and an improved version of the iterative algorithm that eliminates unnecessary I/O at the expense of more computation. We evaluate the performance of the algorithms for different source relation sizes, available memory sizes, join selectivities, and maximum path length. Our results show that no algorithm has uniformly superior performance; the adaptation of Warren's algorithm is superior when the source and result relations are not too much larger than main memory. We conclude that in future systems with large main memory, Warren's algorithm generally performs best, and thus should be implemented with the option of switching to an iterative algorithm when the source or result sizes are very large.","PeriodicalId":145433,"journal":{"name":"1987 IEEE Third International Conference on Data Engineering","volume":"69 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"1987-02-03","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"59","resultStr":"{\"title\":\"Design and evaluation of algorithms to compute the transitive closure of a database relation\",\"authors\":\"Hongjun Lu, K. Mikkilineni, J. Richardson\",\"doi\":\"10.1109/ICDE.1987.7272364\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"Recursive query evaluation is a capability of deductively-augmented database systems that conventional database systems do not support well, if at all. Many recursive queries involve computation of the transitive closure of a relation. Previously published algorithms for transitive closure are iterative in nature, performing repeated joins, unions, and differences until convergence is obtained. In this paper, we present an adaptation of Warren's algorithm for computing the transitive closure of a relation. Warren's algorithm was originally designed for a bit matrix representation of a binary relation; we have adapted it for use with a binary relation represented as a set of tuples, as in a relational database management system. This adapted algorithm computes the transitive closure in two passes over the relation. We analyze the performance of this algorithm, and compare it to the performance of two algorithms based on relational algebra: an iterative algorithm, and an improved version of the iterative algorithm that eliminates unnecessary I/O at the expense of more computation. We evaluate the performance of the algorithms for different source relation sizes, available memory sizes, join selectivities, and maximum path length. Our results show that no algorithm has uniformly superior performance; the adaptation of Warren's algorithm is superior when the source and result relations are not too much larger than main memory. We conclude that in future systems with large main memory, Warren's algorithm generally performs best, and thus should be implemented with the option of switching to an iterative algorithm when the source or result sizes are very large.\",\"PeriodicalId\":145433,\"journal\":{\"name\":\"1987 IEEE Third International Conference on Data Engineering\",\"volume\":\"69 1\",\"pages\":\"0\"},\"PeriodicalIF\":0.0000,\"publicationDate\":\"1987-02-03\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"59\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"1987 IEEE Third International Conference on Data Engineering\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.1109/ICDE.1987.7272364\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"1987 IEEE Third International Conference on Data Engineering","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/ICDE.1987.7272364","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 59

摘要

递归查询求值是演绎增强数据库系统的一种功能,传统数据库系统不能很好地支持这种功能。许多递归查询涉及关系的传递闭包的计算。以前发表的传递闭包算法本质上是迭代的,执行重复的连接、联合和差异,直到获得收敛。在本文中,我们提出了计算关系的传递闭包的Warren算法的一种改编。沃伦的算法最初是为二进制关系的位矩阵表示而设计的;我们对其进行了调整,使其可以用于表示为一组元组的二进制关系,例如在关系数据库管理系统中。这种改进的算法在关系的两次传递中计算传递闭包。我们分析了该算法的性能,并将其与基于关系代数的两种算法的性能进行了比较:一种是迭代算法,另一种是迭代算法的改进版本,它以更多的计算为代价消除了不必要的I/O。我们针对不同的源关系大小、可用内存大小、连接选择性和最大路径长度评估了算法的性能。我们的研究结果表明,没有一种算法具有一致的优越性能;当源和结果关系不大于主存时,Warren算法的自适应能力较优。我们的结论是,在未来具有大内存的系统中,Warren的算法通常表现最好,因此当源或结果大小非常大时,应该通过切换到迭代算法的选项来实现。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
Design and evaluation of algorithms to compute the transitive closure of a database relation
Recursive query evaluation is a capability of deductively-augmented database systems that conventional database systems do not support well, if at all. Many recursive queries involve computation of the transitive closure of a relation. Previously published algorithms for transitive closure are iterative in nature, performing repeated joins, unions, and differences until convergence is obtained. In this paper, we present an adaptation of Warren's algorithm for computing the transitive closure of a relation. Warren's algorithm was originally designed for a bit matrix representation of a binary relation; we have adapted it for use with a binary relation represented as a set of tuples, as in a relational database management system. This adapted algorithm computes the transitive closure in two passes over the relation. We analyze the performance of this algorithm, and compare it to the performance of two algorithms based on relational algebra: an iterative algorithm, and an improved version of the iterative algorithm that eliminates unnecessary I/O at the expense of more computation. We evaluate the performance of the algorithms for different source relation sizes, available memory sizes, join selectivities, and maximum path length. Our results show that no algorithm has uniformly superior performance; the adaptation of Warren's algorithm is superior when the source and result relations are not too much larger than main memory. We conclude that in future systems with large main memory, Warren's algorithm generally performs best, and thus should be implemented with the option of switching to an iterative algorithm when the source or result sizes are very large.
求助全文
通过发布文献求助,成功后即可免费获取论文全文。 去求助
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信