- 1、本文档共8页,可阅读全部内容。
- 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 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
您可能关注的文档
- 社区工作演讲稿(Community work speech).doc
- 祝福语文本文档(Blessing text document).doc
- 神奇成功的步骤(Magical steps to success).doc
- 神奇的成功步骤(Magical success steps).doc
- 神族开局(Protoss start).doc
- 神经营养性关节病x线征象的再探讨(Discussion on neurotrophic arthropathy of the X-ray signs).doc
- 确认识逻辑与语法、修辞的关系(Confirm the relation between logic and grammar and rhetoric).doc
- 硬笔书法基本笔画书写方法(Writing method for basic strokes of hard pen calligraphy).doc
- 离婚财产分割案例(Cases of divorce property division).doc
- 离心泵材质选型(Material selection of centrifugal pump).doc
- 北师大版小学数学三年级上册《寄书》教学设计.docx
- 统编版(部编版)语文二年级上册《雪孩子》教学设计.docx
- 统编版(部编版)语文二年级上册《八角楼上》教学设计.docx
- 北师大版小学数学三年级上册《长方形周长》教学设计.docx
- 北师大版小学数学三年级上册《丰收了》教学设计.docx
- 统编版(部编版)语文二年级上册《夜宿山寺》教学设计.docx
- 统编版(部编版)语文二年级上册《风娃娃》教学设计.docx
- 统编版(部编版)语文二年级上册《朱德的扁担》教学设计.docx
- 统编版(部编版)语文二年级上册《难忘的泼水节》教学设计.docx
- 统编版(部编版)语文二年级上册《纸船和风筝》教学设计.docx
文档评论(0)