Converts MPS file to Scala/Prolog simplex DSL input.
- Download SoPlex.
- Select a MPS file from
soplex-2.2.0/check
directory. For example, selectafiro.mps
. - Copy the MPS in
mps-to-dsl
directory. python3 mps_to_dsl.py < afiro.mps
minimize (10.0*x(6) + -0.6*x(7) + -0.4*x(20) + -0.32*x(26) + -0.48*x(31)) subjectTo {
-1.0*x(3) + 0.109*x(13) <= 0.0
1.0*x(2) + 1.0*x(11) <= 310.0
-0.86*x(1) + -1.06*x(5) + -0.96*x(9) + -1.06*x(10) + 1.0*x(16) == 0.0
-1.0*x(20) + 1.4*x(26) <= 0.0
-1.0*x(8) + 1.0*x(14) <= 0.0
1.0*x(6) + 1.0*x(14) + 1.0*x(15) + 1.0*x(21) + 1.0*x(28) + 1.0*x(30) + -1.0*x(31) == 44.0
0.108*x(14) + 0.107*x(15) + -1.0*x(25) + 0.109*x(28) + 0.108*x(30) <= 0.0
-1.06*x(0) + 1.0*x(2) == 0.0
-1.0*x(7) + 1.4*x(31) <= 0.0
1.0*x(1) + -1.0*x(18) <= 0.0
-1.0*x(4) + 1.0*x(28) <= 500.0
1.0*x(11) + -0.43*x(13) == 0.0
-1.0*x(27) + 1.0*x(30) <= 0.0
1.0*x(5) + -1.0*x(12) <= 80.0
1.0*x(16) + 1.0*x(24) <= 300.0
-1.0*x(0) + 1.0*x(3) + 1.0*x(20) == 0.0
-1.0*x(1) + -1.0*x(5) + -1.0*x(9) + -1.0*x(10) + 1.0*x(25) + 1.0*x(26) == 0.0
2.191*x(4) + 2.219*x(8) + 2.364*x(12) + 2.429*x(18) + -1.0*x(19) + 2.279*x(22) + 2.386*x(23) + 2.249*x(27) + 2.408*x(29) <= 0.0
1.0*x(13) <= 500.0
0.301*x(0) + -1.0*x(17) <= 0.0
1.0*x(0) <= 80.0
1.0*x(15) + -1.0*x(22) <= 0.0
1.0*x(9) + -1.0*x(29) <= 0.0
1.0*x(7) + -1.0*x(13) + 1.0*x(17) + 1.0*x(19) == 0.0
-0.43*x(14) + -0.37*x(15) + 1.0*x(24) + -0.43*x(28) + -0.39*x(30) == 0.0
1.0*x(10) + -1.0*x(23) <= 0.0
0.326*x(1) + 0.301*x(5) + 0.313*x(9) + 0.313*x(10) + -1.0*x(21) <= 0.0
}
-0.39$4 + -0.37$19 + -0.43$20 + 1.0$22 + -0.43$26 :== 0.0.
1.0$13 + 1.0$22 :<= 300.0.
1.0$1 + -1.0$28 :<= 80.0.
1.0$0 + -1.06$25 :== 0.0.
1.0$12 + -1.0$16 + 1.0$27 + 1.0$29 :== 0.0.
-1.0$1 + 1.0$3 + -1.0$6 + -1.0$15 + -1.0$23 + 1.0$24 :== 0.0.
2.249$7 + 2.279$8 + 2.408$9 + 2.191$11 + -1.0$12 + 2.219$18 + 2.386$21 + 2.364$28 + 2.429$31 :<= 0.0.
1.0$0 + 1.0$10 :<= 310.0.
0.301$25 + -1.0$27 :<= 0.0.
-1.06$1 + -1.06$6 + 1.0$13 + -0.86$15 + -0.96$23 :== 0.0.
-1.0$2 + 1.0$4 + 1.0$14 + 1.0$17 + 1.0$19 + 1.0$20 + 1.0$26 :== 44.0.
1.0$4 + -1.0$7 :<= 0.0.
-1.0$5 + 1.4$24 :<= 0.0.
-1.0$8 + 1.0$19 :<= 0.0.
1.0$10 + -0.43$16 :== 0.0.
-1.0$3 + 0.108$4 + 0.107$19 + 0.108$20 + 0.109$26 :<= 0.0.
-1.0$11 + 1.0$26 :<= 500.0.
1.0$16 :<= 500.0.
1.0$6 + -1.0$21 :<= 0.0.
-1.0$9 + 1.0$23 :<= 0.0.
0.301$1 + 0.313$6 + 0.326$15 + -1.0$17 + 0.313$23 :<= 0.0.
0.109$16 + -1.0$30 :<= 0.0.
1.0$5 + -1.0$25 + 1.0$30 :== 0.0.
1.0$25 :<= 80.0.
1.4$2 + -1.0$29 :<= 0.0.
-1.0$18 + 1.0$20 :<= 0.0.
1.0$15 + -1.0$31 :<= 0.0.
-0.48$2 + -0.4$5 + 10.0$14 + -0.32$24 + -0.6$29 :-> min.