Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have the following constraint functions:

$$g_{i_{min}} \leq y_{i+1}-y_{i} \leq g_{i_{max}}$$

$$y_{i_{max}}-y_{i} \geq h_{i}$$

$$v_{i_{min}} \leq \Biggl[\frac{(y_{i+1}-y_{i})^{3} (h_{i}+a)^{4}}{(h_{i}+b)^{4}}\Biggr] \leq v_{i_{max}}$$

$$Q_{i_{min}} \leq \Biggl[\frac{(y_{i+1}-y_{i})^{3} (h_{i}+a)^{10}}{(h_{i}+b)^{4}}\Biggr]$$

where $i=1,2,3$

The variables for minimization are $y_i$ and $h_i$. Note that $y_i$ are continuous and $h_i$ are discrete.

All $g_{i_{min}}, g_{i_{max}}, Q_{i_{min}},v_{i_{min}},v_{i_{max}}, y_{i_{max}},a,b$ are constant.

There are two objectives functions to minimize against:

$$f_{1}=\sum_{i=1}^3 h_i \quad\quad \text{(1)}$$

$$f_{2}=-\sum_{i=1}^4 y_i \quad\quad \text{(2)}$$

The idea is that $(1)$ should always be minimized first, and in the case of a draw, minimize $(2)$.

Any idea how to tackle this question?

On a second thought, I think for my application, I can combine the two objective functions into a single function. So my question how is is there anyway to minimize a set of nonlinear constraint equations, which some of the variables are discrete, and some are continuous?

share|cite|improve this question
Are all variables and constants positive? If so, you could try simplifying the last two constraint functions by raising to the 3rd power and multiplying throughout by $(h_i + b)^2$. I don't know if that'll get you any closer to a solution, but the equations will look less intimidating, so you may get more people willing to look at it. – Rahul Nov 26 '10 at 19:05
@Rahul, I've manipulated the equation a bit to get rid of fractional power. But as far as I can tell it is no less daunting then the previous version. – Graviton Nov 27 '10 at 6:59

This is not a complete answer. I'm assuming that you also have non-negativity constraints on all variables.

After looking at your question more carefully, I rearranged it to the following constraints: $$\begin{align} y_{i+1} - y_i & \in [g_{i_{\min}}, g_{i_{\max}}], \\ y_i & \le y_{i_{\max}} - h_i, \\ y_{i+1} - y_i & \in \left(1 + \frac{c}{h_i+b}\right)^{4/3}[w_{i_{\min}}, w_{i_{\max}}], \\ y_{i+1} - y_i & \ge R_{i_{\min}} \left(1 + \frac{c}{h_i+b}\right)^{4/3}\frac{1}{(h_i+a)^2},\end{align}$$ where $c = b - a$, $w_{i_{*}} = v_{i_{*}}^{1/3}$, and $R_{i_{\min}} = Q_{i_{\min}}^{1/3}$. Hopefully the abuse of notation in the third equation is understandable.

Now all the $y_i$ are on the left side of the constraints and the $h_i$ are on the right. This form should be easier to reason about. For example, I was initially concerned that the optimal $f_1$ might always be $0$. Note that all the right-hand sides get larger as the $h_i$ get smaller, so a solution with all $h_i = 0$ would only fail to be feasible if one of the lower bounds for $y_{i+1} - y_i$ became too large, i.e. incompatible with one of the upper bounds.

Also, since all the constraints except one involve only the differences between the $y_i$, you can decrease all $y_i$ by the same amount and still have a feasible solution, as long as none of them fall below zero. So when you get an optimal solution for $f_1$, you can subtract $\min\{y_j\}$ from $y_i$ and get the solution that minimizes $f_2$ for fixed $h_i$. That's not the same thing as only fixing $\sum h_i$, but it's something...

share|cite|improve this answer
I'm not sure how your proposal solve the problem; if I'm not mistaken, you are saying that we try to optimize for $f_i$ first, but how? – Graviton Nov 27 '10 at 9:29
@Ngu, can't you just use any standard nonlinear optimization software? Anyway, here's something else I thought of. You have two lower bounds on $y_{i+1}-y_i$ which depend on $h_i$; you also two upper bounds on the same quantity. All the $h_i$ seem to be effectively independent, so you can find the smallest $h_i$ that doesn't make any of the lower bounds exceed any of the upper bounds. I expect that should give you the optimal solution for $f_1$, but in case I overlooked something you may want to check it by computer as well. – Rahul Nov 27 '10 at 18:35

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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