0

I am trying to maximize the profit of a power plant. I have a constraint which is that the power plant, when operating, has a minimum and maximum capacity. (So a power block either has an output of zero or between min-max capacity). I am considering how to go about formulating this constraint. I considered some sort of step function, but this would make the constraint non smooth and thus not solvable with regular solvers? Is there some other way to write this function?

Many thanks

Jesse

1 Answers1

0

Most modern optimizers take direct value constraints on any variable, i.e. $$ x_{\min} \leq x \leq x_\max, \quad \text{where } x_\min, x_\max \in \mathbb{R}.$$

If not, why cannot you add two constraints $x \geq x_\min, x \leq x_\max$ to the model?

gt6989b
  • 54,422
  • the problem is the constraints on x is

    x > 0 or minCapacity < x < maxCapacity. How do you say x can be either zero OR greater than minCapacity?

    – Jesse RJ Dec 08 '14 at 19:21
  • @JesseRJ I don't understand your comment, likely a part got deleted by accident? – gt6989b Dec 08 '14 at 19:23
  • yes, i hit enter by mistake

    I want to say I have two conflicting constraints

    $x = 0$ OR $capacity_\min \leq x \leq capacity_\max$

    – Jesse RJ Dec 08 '14 at 19:30
  • @JesseRJ are you using linear optimization only, or can you have binary variables? – gt6989b Dec 08 '14 at 19:40
  • @JesseRJ Modern optimizers have a special type for that constraint. – gt6989b Dec 08 '14 at 19:40
  • yea I was thinking just now about adding a boolean variable. But I guess I would have to use an integer solver? I am still formulating my objecting function and havent chosen a solver yet – Jesse RJ Dec 08 '14 at 19:47
  • could you recommend a solver with that type of constraint? I have the matlab optimization toolbox but I dont think this constraint is included. I may be wrong? – Jesse RJ Dec 08 '14 at 19:51
  • @JesseRJ MATLAB is not a good solver. Maybe CVXOPT? http://abel.ee.ucla.edu/cvxopt/examples/index.html There are others that are free. The best paid one is CPLEX sold by IBM – gt6989b Dec 08 '14 at 19:55