最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

如何测试Dijkstra算法获得最短路径的效率?

SEO心得admin76浏览0评论
本文介绍了如何测试Dijkstra算法获得最短路径的效率?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我的教授让我向他展示Dijkstra算法如何有效地获得最短路径。他说,它需要在应用程序中应用,以证明该算法可行。但我相信这种算法可以很有效,或者可以通过研究工作并应用于不同的场景。所以,我怎么能通过研究测试Dijsktra的算法呢?或者您是否知道已经证明这一点或情景的研究。我只需要向我的教授证明它可以有效地获得最短的路径。在此先感谢。

My Professor ask me to show him how Dijkstra Algorithm will be efficient to get the shortest path. He said that it needs to be apply in an application to prove that this algorithm will work. But i believe this algorithm can be efficient or can works through study and apply in different scenarios. So guys how can i test the Dijsktra's algorithm through study? Or do you know a study that already proven this or scenarios. I just need to prove my Professor that it can be efficient in getting the shortest path. Thanks in advance.

推荐答案

这是逐步检查效率的一种方法。 1.实施Dijkstras算法您喜欢的编程语言。 2.查找现有实现或实现第二种算法。 3.在同一台计算机上运行相同输入数据的算法。 4.a确认实际找到了最短路径。 4.b比较两种算法之间的执行时间。 4。 c您还可以检查使用的内存,使用的CPU时间等。 This is step-by-step for one way to check the efficiency. 1. Implement Dijkstras algorithm in a programming language of your preference. 2. Find an existing implementation or implement a second algorithm. 3. Run the algorithms of the same input data on the same computer. 4.a Verify that the shortest path actually was found. 4.b Compare the execution time between the two algorithms. 4.c You can also check memory used, CPU time used etc.

发布评论

评论列表(0)

  1. 暂无评论