贪婪算法--- 拓扑排序(The greedy algorithm, topological sorting).doc

贪婪算法--- 拓扑排序(The greedy algorithm, topological sorting).doc

  1. 1、本文档共8页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
贪婪算法--- 拓扑排序(The greedy algorithm, topological sorting)

贪婪算法--- 拓扑排序(The greedy algorithm, topological sorting) Topological sort A complex project can usually be broken down into a set of small tasks, and the completion of these small tasks means the completion of the whole project. For example, the automobile assembly project can be divided into the following tasks: placing the chassis on the assembly line, installing the axle, placing the seat on the chassis, painting, loading the brakes, loading doors and so on. There are precedence relations between tasks. For example, the bottom plate should be put on the assembly line before loading the axle. The order of tasks can be represented by directed graphs called Activity On Vertex (AOV) networks. The vertices of the directed graph represent the task, and the directed edge (I, J) represents the precedence relationship: the task I must be completed before the task J starts. Figure 1 - 4 shows the six tasks of the project, the edge (1, 4) said the 1 task in task 4 before completion, the same edge (4, 6) said the 4 task in task 6 before completion, edge (1, 4) and (4, 6) together the 1 tasks in the task 6 before the start of the closed system is completed, before and after delivery. It can be seen that the edges (1, 4) are redundant, because sides (1, 3) and (3, 4) have implied this relationship. In many cases, tasks are carried out continuously, such as car assembly problems, or purchases of consumer goods (bicycles, childrens swings, mowers, etc.) that are usually required to be assembled. We can assemble according to the order we suggest. In the directed graph created by the task, the edge (I, J) indicates that in the assembly sequence, the task I is in front of the task J, and the sequence having this property is called the topological sequence (topological, orders, or topological sequences). The process of establishing topological sequences based on the directed graph of a task is called topological sorting (topological, sorting). Figure 1 - 4 of the task has a variety o

您可能关注的文档

文档评论(0)

jgx3536 + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

版权声明书
用户编号:6111134150000003

1亿VIP精品文档

相关文档