Ask Your Question
0

Interactive simple Method

asked 2019-09-14 10:54:40 +0100

Cyrille gravatar image

updated 2019-09-14 16:15:39 +0100

FrédéricC gravatar image

The interactive simplex method is a very nice pedagogical tool. But it seems to work only with 2 variables. Could it be expanded at least until 3/4 and more constraints. I plan to use it to teach and do exams in a computer room if it is possible to expand it ?

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2019-09-14 17:05:17 +0100

rburing gravatar image

The documentation shows many examples with two variables, but in fact there is no restriction on the number of variables or constraints. Example with three variables and three constraints:

A = ([1, 1, 0], [3, 1, 0], [0, 0, 1])
b = (1000, 1500, 20)
c = (10, 5, 1)
P = InteractiveLPProblem(A, b, c, ["C", "B", "A"], variable_type=">=")
show(P)
P = P.standard_form()
P.run_simplex_method()

Three variables and two constraints:

A = ([1, 1, 0], [3, 1, 0])
b = (1000, 1500)
c = (10, 5, 1)
P = InteractiveLPProblem(A, b, c, ["C", "B", "A"], variable_type=">=")
show(P)
P = P.standard_form()
P.run_simplex_method()

Etc.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2019-09-14 10:54:40 +0100

Seen: 522 times

Last updated: Sep 14 '19