Linearise product of two integer variables for MILP

163 Views Asked by At

First up I'm new to this sort of task so please bare with me. I'm trying to linearise (for use in a MILP written in GAMS) the following constraint:

$$ f_{h,n} \le \beta_{n} x_{h,n} \sum_{n} C_n x_{h,n} $$

with:

$$ 0 \le x_{h,n} \le 100 $$ $$ 0 \le f_{h,n} $$

where $x_{h,n}$ is an integer variable and $\beta_n$ and $C_n$ are constant by $n$. One option I've been investigating is to binary expand $x_{h,n}$ as:

$$ x_{h,n} = \sum_{k=0}^7 2^k m_{h,n,k} $$

where $m_{h,n,k}$ is a binary variable and then make use of the ability to linearise the product of two binaries (see e.g. this link). However, I'm getting a bit lost how to write the usual constraints:

$$ z_{h,n} \le m_{h,n,k} $$ $$ z_{h,n} \le m_{h,k} $$ $$ z_{h,n} \ge m_{h,n,k} + m_{h,k} - 1 $$

Does this still work ok given the nested summation? And could anyone please assist with the formulation (in GAMS if at all possible but no worries if not).

Many thanks