Quantcast
Channel: Yet Another Math Programming Consultant
Viewing all articles
Browse latest Browse all 809

PyMathProg: another Python based modeling tool

$
0
0

Project homepage: http://pymprog.sourceforge.net/

Uses GLPK as solver. Here is a small example:

frompymprogimport*
c=(10,6,4)
A=[(1,1,1),
(9,4,5),
(2,2,6)]
b=(10,60,30)
begin('basic')# begin modelling
verbose(True)# be verbose
x=var('x',3)#create 3 variables
maximize(sum(c[i]*x[i]foriinrange(3)))
foriinrange(3):
sum(A[i][j]*x[j]forjinrange(3))<=b[i]
solve()# solve the model
sensitivity()# sensitivity report
end()
#Good habit: do away with the model

There is quite some competition in this space. Some of the major competitors:


Viewing all articles
Browse latest Browse all 809

Trending Articles