Analysis of Complexity of Some Combinatorial Algorithms Using Halstead Metrics and Time Measures

The Knapsack problem is a combinatorial optimization problem for which finding an exact solution using exhaustive search methods is impractical. Therefore, approximate algorithms are usually considered when tackling this optimization problem. The goal of this study was to analyze the complexity of the Knapsack problem using three approximate algorithms: greedy, dynamic programming, and branch-and-bound methods. To achieve this, we measured the Halstead metrics and computational time complexity of these three algorithms. Our methodology involved solving a hypothetical Knapsack problem using the three algorithms in the same programming environment. Experiments were conducted with varying input datasets, and the time complexities of the algorithms were recorded for each experiment. The average time complexities were computed at the end of the experiments. Additionally, we calculated the Halstead metrics required for the study. Both the Halstead metrics and computational time metrics for the three algorithms were then compared. Our findings showed that the greedy approach was the most efficient heuristic, followed closely by the dynamic programming method, with the branch-and-bound algorithm being the least efficient. Future work will incorporate real-world data with specific item characteristics to enhance the relevance and applicability of the findings. Additionally, it will explore hybrid approaches that combine these algorithms to leverage their respective strengths and effectively address their weaknesses.

Authors

Publication Details

Journal
American Journal of Applied Mathematics and Statistics
Published
2024-08-25
DOI
https://doi.org/10.12691/ajams-12-3-4
Citations
2
Primary Topic
Computability, Logic, AI Algorithms
Type
article
Field-Weighted Citation Impact
0.72
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Analysis of Complexity of Some Combinatorial Algorithms Using Halstead Metrics and Time Measures

Bashar Bin Usman, Okeyinka Aderemi Elisha Ibrahim Abdullahi
2 citations
American Journal of Applied Mathematics and Statistics
Computability, Logic, AI Algorithms
0.72
article

Analysis of Complexity of Some Combinatorial Algorithms Using Halstead Metrics and Time Measures

Bashar Bin Usman, Okeyinka Aderemi Elisha Ibrahim Abdullahi
article en
2 citations

Abstract

The Knapsack problem is a combinatorial optimization problem for which finding an exact solution using exhaustive search methods is impractical. Therefore, approximate algorithms are usually considered when tackling this optimization problem. The goal of this study was to analyze the complexity of the Knapsack problem using three approximate algorithms: greedy, dynamic programming, and branch-and-bound methods. To achieve this, we measured the Halstead metrics and computational time complexity of these three algorithms. Our methodology involved solving a hypothetical Knapsack problem using the three algorithms in the same programming environment. Experiments were conducted with varying input datasets, and the time complexities of the algorithms were recorded for each experiment. The average time complexities were computed at the end of the experiments. Additionally, we calculated the Halstead metrics required for the study. Both the Halstead metrics and computational time metrics for the three algorithms were then compared. Our findings showed that the greedy approach was the most efficient heuristic, followed closely by the dynamic programming method, with the branch-and-bound algorithm being the least efficient. Future work will incorporate real-world data with specific item characteristics to enhance the relevance and applicability of the findings. Additionally, it will explore hybrid approaches that combine these algorithms to leverage their respective strengths and effectively address their weaknesses.

American Journal of Applied Mathematics and StatisticsVol. 12(3)
Openalex Percentile: Top 26%
Computability, Logic, AI Algorithms
0.72
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Analysis of Complexity of Some Combinatorial Algorithms Using Halstead Metrics and Time Measures — Bashar Bin Usman, Okeyinka Aderemi Elisha Ibrahim Abdullahi · American Journal of Applied Mathematics and Statistics (2024) | TGRS Research Map | TGRS