International Journal of Modern Trends in Engineering and Research www.ijmter.com e-ISSN: 2349-9745 Comparative Analysis of Dynamic and Greedy Approaches for Dynamic Programming Jay Vala 1 , Dhara Monaka 2 , Jaymit Pandya 3 1 Asst. Prof., I.T. Department, G H Patel College of Engg & Tech, jayvala1623@gmail.com 2 Asst. Prof., B.C.A. Department, Nandkunvarba Mahila College, dhara.monaka123@gmail.com 3 Asst. Prof., I.T. Department, G H Patel College of Engg & Tech, erpandyajaymit@gmail.com Abstract— This paper analyze few algorithms of the 0/1 Knapsack Problem and fractional knapsack problem. This problem is a combinatorial optimization problem in which one has to maximize the benefit of objects without exceeding capacity. As it is an NP-complete problem, an exact solution for a large input is not possible. Hence, paper presents a comparative study of the Greedy and dynamic methods. It also gives complexity of each algorithm with respect to time and space requirements. Our experimental results show that the most promising approaches are dynamic programming. Keywords- knapsack, dynamic programming, greedy programming, NP-Complete, complexity I. INTRODUCTION The knapsack problem or rucksack problem is a problem in combinatorial optimization: Given a set of items, each with a mass and a value, determine the number of each item to include in a collection so that the total weight is less than or equal to a given limit and the total value is as large as possible. It derives its name from the problem faced by someone who is constrained by a fixed-size knapsack and must fill it with the most valuable items [1] . The 0-1 knapsack problem can solve using a partitioning algorithm for finding break item, weak reduction, strong upper bound, finding the solution vector and minimality. II. DIFFERENT APPROACHES TO PROBLEM 1) Greedy Approach A thief robbing a store and can carry a maximal weight of w into their knapsack. There are n items and i th item weigh wi and is worth vi dollars. What items should thief take? This version of problem is known as Fractional knapsack problem. The setup is same, but the thief can take fractions of items, meaning that the items can be broken into smaller pieces so that thief may decide to carry only a fraction of xi of item i, where 0 ≤ xi ≤ 1 [2][3] . 2) Dynamic Approach Again a thief robbing a store and can carry a maximal weight of w into their knapsack. There are n items and ith item weigh w i and is worth vi dollars. What items should thief take? This version of problem is known as 0-1 knapsack problem. The setup is the same, but the items