Comparison of the Dijkstra’s Algorithm and the Floyd-Warshall’s Algorithm to Determine the Shortest Path between Hospitals in Several Cities in Lampung Province

Authors

  • Alenia Daynur Putriani Universitas Lampung, Indonesia
  • Wamiliana Universitas Lampung, Indonesia
  • Siti Laelatul Chasanah Universitas Lampung, Indonesia

DOI:

https://doi.org/10.31258/jomso.v1i2.22

Keywords:

shortest path, Dijkstra’s algorithm, Floyd-Warshall’s algorithm, running time

Abstract

Determining the shortest route from one node to another is a problem we often encounter in everyday life. The routes obtained are intended to minimize costs, travel time or distance. In this study, we compare Dijkstra’s and Floyd-Warshall’s algorithms to determine the shortest route between hospitals in some cities in Lampung Province. The efficiency of the two algorithms in solving this problem is assessed based on the program running time. The results show that both Dijkstra’s algorithm and Floyd-Warshall’s algorithm provide the shortest path in the same distance. However, the running time of the Dijkstra’s algorithm takes less time than Floyd-Warshall’s algorithm.

References

Cantona, A., Fauziah, and Winarsih. Impelementasi Algoritma Dijkstra pada Pencarian Lintasan Terpendek ke Museum di Jakarta, 2020, Jurnal Teknologi and Manajemen Informatika, Volume: 6 pp 27-34.

Rudiyanto, A. D., Wahyuddin, M. I., and Andrianingsih, 2020, Perbandingan Algoritma Floyd-Warshall and Dijkstra untuk Menentukan Lintasan Rumah Sakit Terdekat Lintasan Evakuasi Kecelakaan Lalu Lintas Berbasis Web. Journal of Information Technology and Computer Science, Volume: 3 pp 336–345.

Wang, X. Z. The Comparison of Three Algorithms in Shortest Path Issue, 2018, Journal of Physics Conference Series, Volume: 1087 pp 164–170.

Harahap, M. K., and Khairina, N. Pencarian Lintasan Terpendek dengan Algoritma Dijkstra, 2017, Jurnal & Penelitian Teknik Informatika, Volume: 2 pp 18-23.

Aulia, S. R, Wamiliana, Asmiati, and Notiragayu, 2023, Perbandingan Algoritme Dijkstra and Algoritme A * (A-Star) dalam Penentuan Lintasan Terpendek dari Dinas Pendidikan Provinsi Lampung ke Beberapa Sekolah Menengah Atas (SMA) Negeri di Provinsi Lampung. Jurnal Pepadun, Volume: 4 pp 83 – 190.

Darnita, Y., Toyib, R., and Rinaldi, 2017, Implementasi Algoritma Floyd-Warshall untuk Menentukan Letak and Lokasi Perusahaan Travel/Rental Mobil di Kota Bengkulu. Jurnal Pseudocode, Volume: 4 pp 144-155.

https://cp-algorithms.com/graph/all-pair-shortest-path-floyd-warshall.html, accessed in 20 Nov 2023.

Downloads

Published

2024-01-31 — Updated on 2024-05-30

Versions