2
$\begingroup$

In my Computer Science class we've been exploring the Simplex Method and the applications it has with discovering optimal solutions. I've loved the challenge how much easier it makes finding solutions to business-model problems.

One problem that I have though is understanding how constraints are set when you have non-matching units. For example, an assignment we completed dealt with finding the maximum profit of a precious-metal processing setup. Most constraints made sense as their units lined up (water used per material, hours of labor per material, hours of refining, etc.) but there were two I could not understand on how to implement. We had a limit of rock in tons and could extract only one type of ore per ton. Each ton contained 10 oz copper, 2 oz gold, 3 oz silver, and 1 oz platinum. We're limited to a max of 2000 tons of rock to use.

I correctly constructed the problem up to this point (note that each variable is represents an ounce):

Maximize z = 10.20c + 422.30g + 6.91s + 853.00p subject to
                30c +     15g +   19s +     12p ≤ 1000 (kW hours)
              1000c +   6000g + 4100s +   9100p ≤ 1000000 (gal. water)
                50c +     20g +   21s +     10p ≤ 640 (labor hours)
                 4c +      6g +   19s +     30p ≤ 432 (processing hours)

What I could not figure out was how to properly implement the maximum amount of ore and rock. I can't just put

 10c + 2g + 3s + p ≤ 2000
because it's mixing the ounce limit of each ore per ton with the constraint of maximum tons available. I tried using
 c + g + s + p ≤ 2000 
to indicate how many tons we use and which ores are chosen but they would/will not explain why this is wrong.

What's the proper way of identifying and defining these as constraints so that they can be added?

$\endgroup$
0
$\begingroup$

Not being able to model a constraint rings a bell that you might have defined inappropriate decision variables. Define the following decision variables

  1. $x_c$=number of tons from which (only) copper will be extracted.
  2. $x_g$=number of tons from which (only) gold will be extracted.

and similarly $x_s$ and $x_p$. Now you have the constraint that $$x_c+x_g+x_s+x_p\le2000$$

Your actual decision has to do with the question: "from how many tons will I extract (only) copper, gold, silver and from how many platinum?" So, accordingly you should define your decision variables.

$\endgroup$
  • $\begingroup$ Ok, so that certainly helps with ensuring we stay within our 2000 ton bounds. That makes more sense. After adding that should I then define the limit of the ounces per ore per ton in such a manner: (1/10)c ≤ x(sub c)? $\endgroup$ – Kamikaze Rusher Mar 16 '15 at 17:53
  • $\begingroup$ @KamikazeRusher No, I think you should discard the variables $c, s, g$ and $p$ and try to reformulate all the constraints with the help of the variables $x_c, x_g$ etc. The limit of ounces per ton will appear automatically when you will express the other constraints. For example using $x_c$ tons of copper means you are processing $10x_c$ ounces of copper etc. $\endgroup$ – Jimmy R. Mar 16 '15 at 17:55
  • $\begingroup$ So just to make sure I get this right, redefine variables as tons instead of ounces. In doing so adjust the coefficients accordingly (ie. 30c kW hours becomes 300x_c kW h). $\endgroup$ – Kamikaze Rusher Mar 16 '15 at 18:03
  • $\begingroup$ To be precise, variables will be number of tons. But, yes that is the idea. Did you manage to model all constraints know? If it works then there you are $\endgroup$ – Jimmy R. Mar 16 '15 at 19:20
  • $\begingroup$ I forgot to report back and thank you. I managed to adjust coefficients to their proper values $\endgroup$ – Kamikaze Rusher Mar 17 '15 at 20:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.