You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
`findFeasibleSolution` takes a list of `PolyConstraint`s.
18
-
The `PolyConstraint` type, as well as other custom types required by this library, are defined in the `Linear.Simplex.Types` module.
19
-
`PolyConstraint` is defined as:
17
+
`findFeasibleSolution` takes a list of `StandardConstraint`s.
18
+
The `StandardConstraint` type, as well as other custom types required by this library, are defined in the `Linear.Simplex.Types` module.
19
+
`StandardConstraint` is defined as:
20
20
21
21
```haskell
22
-
dataPolyConstraint=
22
+
dataStandardConstraint=
23
23
LEQVarsRational |
24
24
GEQVarsRational |
25
25
EQVarsRationalderiving (Show, Eq);
@@ -34,11 +34,11 @@ type Vars = [(Integer, Rational)]
34
34
A `Vars` is treated as a list of `Integer` variables mapped to their `Rational` coefficients, with an implicit `+` between each element in the list.
35
35
For example: `[(1, 2), (2, (-3)), (1, 3)]` is equivalent to `(2x1 + (-3x2) +3x1)`.
36
36
37
-
And a `PolyConstraint` is an inequality/equality where the LHS is a `Vars` and the RHS is a `Rational`.
37
+
And a `StandardConstraint` is an inequality/equality where the LHS is a `Vars` and the RHS is a `Rational`.
38
38
For example: `LEQ [(1, 2), (2, (-3)), (1, 3)] 60` is equivalent to `(2x1 + (-3x2) +3x1) <=60`.
39
39
40
-
Passing a `[PolyConstraint]` to `findFeasibleSolution` will return a feasible solution if it exists as well as a list of slack variables, artificial variables, and a variable that can be safely used to represent the objective for phase two.
41
-
`Nothing` is returned if the given `[PolyConstraint]` is infeasible.
40
+
Passing a `[StandardConstraint]` to `findFeasibleSolution` will return a feasible solution if it exists as well as a list of slack variables, artificial variables, and a variable that can be safely used to represent the objective for phase two.
41
+
`Nothing` is returned if the given `[StandardConstraint]` is infeasible.
42
42
The feasible system is returned as the type `DictionaryForm`:
43
43
44
44
```haskell
@@ -70,7 +70,7 @@ If a variable is not in this list, the variable is equal to 0.
There are many more examples in test/TestFunctions.hs.
125
-
You may use `prettyShowVarConstMap`, `prettyShowPolyConstraint`, and `prettyShowObjectiveFunction` to convert these tests into a more human-readable format.
125
+
You may use `prettyShowVarConstMap`, `prettyShowStandardConstraint`, and `prettyShowObjectiveFunction` to convert these tests into a more human-readable format.
0 commit comments