brute_force_knapsack: Knapsack probelm with brute force algorithm

Description Arguments Value Author(s) References

View source: R/brute_force_knapsack.R

Description

brute force algo going through all possible alternatives and return the maximum value found with element with complexity .

Arguments

x

is a data frame hiaving 2 column 'w' and 'v' where w is weight if items and v is the value of item

W

capacity of knapsack i.e total weight that knapsack can contain in it

parallel

default it set to FALSE , if you have mac/linux or windows you can set it TRUE

Value

return list which have maxValue and and item number of elemnts that knapsack have in it

Author(s)

rabnawaz & saman

References

https://en.wikipedia.org/wiki/Knapsack_problem


rjkhan/RCourse-lab6 documentation built on May 6, 2019, 2:34 p.m.