This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from math import * | |
""" | |
Read-me: | |
Call functions in this order: | |
problem = gen_matrix(v,c) | |
constrain(problem, string) | |
obj(problem, string) | |
maxz(problem) | |
gen_matrix() produces a matrix to be given constraints and an objective function to maximize or minimize. | |
It takes var (variable number) and cons (constraint number) as parameters. |