2016-12-09 40 views
0

我無法運行通過apt-get安裝的名爲dist的GLPK解算器(glpsol)。它拋出以下:示例中的GLPK無效指示器錯誤

$ glpsol dist.mod 
GLPSOL: GLPK LP/MIP Solver, v4.60 
Parameter(s) specified in the command line: 
dist.mod 
Reading problem data from 'dist.mod'... 
dist.mod:1: invalid indicator record 
MPS file processing error 

編輯:與-m運行返回不同的錯誤:

172 lines were read 
Generating cost... 
dist.mod:103: fact contains w02 which not within specified set; see (1) 
MathProg model processing error 

回答

1

您必須指定在哪個符號的modelfile寫入(GLPK支持多種格式的問題)。 默認情況下,它會嘗試讀取示例mathprog-problem-file上失敗的freemps-problem-file。

嘗試使用glpsol -m dist.mod處理mathprog例子。