knapsack/R/knapsack.R

#' @name knapsack
#' @title Solving knapsack problem using three different solutions 
#' @docType package
#' @description The knapsack problem or rucksack problem is a problem in
#'   combinatorial optimization: Given a set of items, each with a weight 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.
#'   
#' @section Functions:
#'   \describe{
#'     \item{\code{brute_force_knapsack(x, W)}}{returns the solution for knapsack problem using brute force algorithm.}
#'     \item{\code{greedy_knapsack(x, W)}}{returns  the solution for knapsack problem using Greedy approximation algorithm.}
#'     \item{\code{knapsack_dynamic(x, W)}}{returns  the solution for knapsack problem using Dynamic programming algorithm.}
#' }
#'
#' @references \url{http://en.wikipedia.org/wiki/Knapsack_problem}
#'
#'
#' @author Ali Etminan, Mohsen Pirmoradiyan
NULL
mpirmoradiyan/knapsack documentation built on Nov. 4, 2019, 7:31 p.m.