干货|十分钟快速掌握CPLEX求解VRPTW数学模型（附JAVA代码及CPLEX安装流程）

＊什么是VRPTW

＊CPLEX求解VRPTW实例

＊CPLEX操作补充说明

1.什么是VRPTW

• 什么是VRP？

VRP图示

• 什么是VRPTW？

2.CPLEX求解VRPTW实例

• 1.精确解算法（Exact methods）

• 2.途程构建启发式算法（Route-building heuristics）

• 3.途程改善启发式算法（Route-improving heuristics）

• 4.通用启发式算法（Metaheuristics）

VRPTW问题建模实例

result

routes=

[[0, 101]

[0, 5, 3, 7, 8, 10, 11, 9, 6, 4, 2, 1, 75, 101]

[0, 98, 96, 95, 94, 92, 93, 97, 100, 99, 101]

[0, 43, 42, 41, 40, 44, 46, 45, 48, 51, 50, 52, 49, 47, 101]

[0, 81, 78, 76, 71, 70, 73, 77, 79, 80, 101]

[0, 90, 87, 86, 83, 82, 84, 85, 88, 89, 91, 101]

[0, 101]

[0, 32, 33, 31, 35, 37, 38, 39, 36, 34, 101]

[0, 20, 24, 25, 27, 29, 30, 28, 26, 23, 22, 21, 101]

[0, 57, 55, 54, 53, 56, 58, 60, 59, 101]

[0, 67, 65, 63, 62, 74, 72, 61, 64, 68, 66, 69, 101]

[0, 13, 17, 18, 19, 15, 16, 14, 12, 101]]

cplex_time 157.077920593s bestcost 827.3

result

routes=

[[0, 101]

[0, 5, 3, 7, 8, 10, 11, 9, 6, 4, 2, 1, 75, 101]

[0, 98, 96, 95, 94, 92, 93, 97, 100, 99, 101]

[0, 43, 42, 41, 40, 44, 46, 45, 48, 51, 50, 52, 49, 47, 101]

[0, 81, 78, 76, 71, 70, 73, 77, 79, 80, 101]

[0, 90, 87, 86, 83, 82, 84, 85, 88, 89, 91, 101]

[0, 101]

[0, 32, 33, 31, 35, 37, 38, 39, 36, 34, 101]

[0, 20, 24, 25, 27, 29, 30, 28, 26, 23, 22, 21, 101]

[0, 57, 55, 54, 53, 56, 58, 60, 59, 101]

[0, 67, 65, 63, 62, 74, 72, 61, 64, 68, 66, 69, 101]

[0, 13, 17, 18, 19, 15, 16, 14, 12, 101]]

cplex_time 142.142142417s bestcost 827.3

http://paste.ubuntu.com/25476905/

3.CPLEX操作补充说明

1

Cplex64位版本下载地址可移步 留言区 获取百度云网盘链接~~

2

cplex.jar(在…\IBM\ILOG\CPLEX_Studio1263\cplex\lib目录下找到)

cplex1263.dll(在…\IBM\ILOG\CPLEX_Studio1263\cplex\bin\x64_win64目录下找到)。

1. 将cplex.jar加到工程的Build Path中：

Build Path->Configure Build Path

2. cplex1263.dll可以设置到运行时的环境中（VM arguments），或者添加到项目的Native library location（这里小编选用的是第二种）

—end—

0 条评论

3603

3289

2208

1613

4013

1.1K9

1815

2935

22310

4405