Farm Planning: How Much to Grow and Rear


Constraints

The following constraints are used in this example:

  • bounds on variables

  • for $\text {year} \in \text {YEARS}$,

    \begin{align*} & \quad \sum _{\text {age} \in \text {AGES}} \Argument{acres\_ needed[age]} \cdot \Variable{NumCows[age,year]} \\ & + \sum _{\text {group} \in \text {GROUPS}} \Variable{GrainAcres[group,year]} + \Variable{SugarBeetAcres[year]} \\ & \le \Argument{num\_ acres} \end{align*}
  • for $\text {age} \in \text {AGES} \setminus \{ \Argument{dairy\_ cow\_ selling\_ age}\} $ and $\text {year} \in \text {YEARS0} \setminus \{ \Argument{num\_ years}\} $,

    \[  \Variable{NumCows[age}+1,\Variable{year}+1\Variable{]} = (1 - \Argument{annual\_ loss[age]}) \cdot \Variable{NumCows[age,year]}  \]
  • for $\text {year} \in \text {YEARS}$,

    \[  \Variable{NumBullocksSold[year]} = \sum _{\text {age} \in \text {AGES}} \Argument{bullock\_ yield[age]} \cdot \Variable{NumCows[age,year]}  \]
  • for $\text {year} \in \text {YEARS}$,

    \[  \Variable{NumCows[0,year]} = \sum _{\text {age} \in \text {AGES}} \Argument{heifer\_ yield[age]} \cdot \Variable{NumCows[age,year]} - \Variable{NumHeifersSold[year]}  \]
  • for $\text {year} \in \text {YEARS}$,

    \[  \sum _{\text {age} \in \text {AGES}} \Variable{NumCows[age,year]} \le \Argument{max\_ num\_ cows} + \sum _{\substack{\text {y} \in \text {YEARS}:\\ \text {y} \le \text {year}}} \Variable{CapitalOutlay[y]}  \]
  • for $\text {group} \in \text {GROUPS}$ and $\text {year} \in \text {YEARS}$,

    \[  \Variable{GrainGrown[group,year]} = \Argument{grain\_ yield[group]} \cdot \Variable{GrainAcres[group,year]}  \]
  • for $\text {year} \in \text {YEARS}$,

    \begin{align*} & \quad \sum _{\text {age} \in \text {AGES}} \Argument{grain\_ req[age]} \cdot \Variable{NumCows[age,year]} \\ & \le \sum _{\text {group} \in \text {GROUPS}} \Variable{GrainGrown[group,year]} + \Variable{GrainBought[year]} - \Variable{GrainSold[year]} \end{align*}
  • for $\text {year} \in \text {YEARS}$,

    \[  \Variable{SugarBeetGrown[year]} = \Argument{sugar\_ beet\_ yield} \cdot \Variable{SugarBeetAcres[year]}  \]
  • for $\text {year} \in \text {YEARS}$,

    \begin{align*} & \quad \sum _{\text {age} \in \text {AGES}} \Argument{sugar\_ beet\_ req[age]} \cdot \Variable{NumCows[age,year]} \\ & \le \Variable{SugarBeetGrown[year]} + \Variable{SugarBeetBought[year]} - \Variable{SugarBeetSold[year]} \end{align*}
  • for $\text {year} \in \text {YEARS}$,

    \begin{align*} & \quad \sum _{\text {age} \in \text {AGES}} \Argument{cow\_ labour\_ req[age]} \cdot \Variable{NumCows[age,year]} \\ & + \sum _{\text {group} \in \text {GROUPS}} \Argument{grain\_ labour\_ req} \cdot \Variable{GrainAcres[group,year]} \\ & + \Argument{sugar\_ beet\_ labour\_ req} \cdot \Variable{SugarBeetAcres[year]} \\ & \le \Argument{nominal\_ labour\_ hours} + \Variable{NumExcessLabourHours[year]} \end{align*}
  • for $\text {year} \in \text {YEARS}$,

    \[  \Variable{Profit[year]} \ge 0  \]
  • $\displaystyle { 1 - \Argument{max\_ decrease\_ ratio} \le \frac{\sum \limits _{\substack{\text {age} \in \text {AGES}:\\ \text {age} \ge 2}} \Variable{NumCows[age,num\_ years]}}{\sum \limits _{\substack{\text {age} \in \text {AGES}:\\ \text {age} \ge 2}} \Argument{init\_ num\_ cows[age]}} \le 1 + \Argument{max\_ increase\_ ratio} }$