Food Manufacture 2: Limiting the Number of Ingredients and Adding Extra Conditions


Constraints

The following additional constraints are used in this example:

  • for $\text {oil} \in \text {OILS and period} \in \text {PERIODS}$,

    \[ \Variable{Use[oil,period]} \le \Argument{Use[oil,period].ub}\cdot \Variable{IsUsed[oil,period]} \]
  • for $\text {period} \in \text {PERIODS}$,

    \[ \sum _{\text {oil} \in \text {OILS}} \Variable{IsUsed[oil,period]} \le \Argument{max\_ num\_ oils\_ used} \]
  • for $\text {oil} \in \text {OILS and period} \in \text {PERIODS}$,

    \[ \Variable{Use[oil,period]} \ge \Argument{min\_ oil\_ used\_ threshold}\cdot \Variable{IsUsed[oil,period]} \]
  • for $\text {oil} \in \Variable{\{ 'veg1','veg2'\} }\text { and period} \in \text {PERIODS}$,

    \[ \Variable{IsUsed[oil,period]} \le \Variable{IsUsed['oil3',period]} \]