Advertisement
simonjtyler

POEFS.A1.P3

Jan 14th, 2013
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. eqn[w_] = LogicalExpand[D[(200 - q1 - q2) (q1 + q2) - w q1 - q2^2, {{q1, q2}}] == 0
  2. && q1 >= 0 && q2 >= 0]
  3. Manipulate[
  4. Column@{
  5. Piecewise[{{w, 2 q > w}, {2 q, 2 q <= w}}] == 200 - 2 q // Reduce[# && q >= 0, q] &,
  6. Which[w < 0, Reduce[eqn[w][[{2, 3}]] /. q2 -> 0],
  7. w > 100, Reduce[eqn[w][[{1, 4}]] /. q1 -> 0],
  8. True, Reduce[eqn[w]]]},
  9. {{w, 100}, -50, 200, Appearance -> "Labeled"}]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement