文件名称:lab2
介绍说明--下载内容来自于网络,使用问题请自行百度
1) Given a knapsack with the capacity M and some items with its weight and profit, to solve it using Greedy method and Search tree method.
2) Then compare this results with ones of 0/1 Knapsack problem based on the capacity of M.
3) These items could be given likes:
• M = 30
• (P1, P2, P3, P4, P5, P6)=(25,24,15,18,22,35)
• (W1, W2, W3, W4, W5, W6) = (12, 15, 10, 8, 9, 11)
4) These items could constructed by the random() function in some range, such as: (Wmin, Wmax) and (Pmin, Pmax) and the number of item could be more.
-1) Given a knapsack with the capacity M and some items with its weight and profit, to solve it using Greedy method and Search tree method.
2) Then compare this results with ones of 0/1 Knapsack problem based on the capacity of M.
3) These items could be given likes:
• M = 30
• (P1, P2, P3, P4, P5, P6)=(25,24,15,18,22,35)
• (W1, W2, W3, W4, W5, W6) = (12, 15, 10, 8, 9, 11)
4) These items could constructed by the random() function in some range, such as: (Wmin, Wmax) and (Pmin, Pmax) and the number of item could be more.
2) Then compare this results with ones of 0/1 Knapsack problem based on the capacity of M.
3) These items could be given likes:
• M = 30
• (P1, P2, P3, P4, P5, P6)=(25,24,15,18,22,35)
• (W1, W2, W3, W4, W5, W6) = (12, 15, 10, 8, 9, 11)
4) These items could constructed by the random() function in some range, such as: (Wmin, Wmax) and (Pmin, Pmax) and the number of item could be more.
-1) Given a knapsack with the capacity M and some items with its weight and profit, to solve it using Greedy method and Search tree method.
2) Then compare this results with ones of 0/1 Knapsack problem based on the capacity of M.
3) These items could be given likes:
• M = 30
• (P1, P2, P3, P4, P5, P6)=(25,24,15,18,22,35)
• (W1, W2, W3, W4, W5, W6) = (12, 15, 10, 8, 9, 11)
4) These items could constructed by the random() function in some range, such as: (Wmin, Wmax) and (Pmin, Pmax) and the number of item could be more.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
周宇梁 201430571102.doc
lab2.cpp
lab2.cpp
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.