The stochastic programming farming problem involves deciding how to allocate 500 acres of land to three different crops: wheat, corn, and sugar beets. While the sales prices at harvest time are fixed, the yields per acre are not. The objective is to decide how to allocate the land such that the expected profit is maximised. Equivalently in standard form, we want to minimize costs less revenue. To incorporate the uncertainty component, we introduce randomly generated scenarios representing possible harvest yield outcomes for our expectation.
To solve this problem, we were tasked with constructing a Simplex Method solver and a Dantzig-Wolfe Decomposition Solver. Intuitively, we expect that the Dantzig-Wolfe method should perform better than the Simplex method as the decomposition reduces the size of the matrices involved at each step by solving smaller subproblems at a time.
Before constructing any solver, we must formulate the problem. For a given instance of the farming problem, we require n harvest yield cases corresponding to n possible scenarios in the instance. As we are assuming that each scenario is equally likely, a uniform distribution seems appropriate. In order to set bounds on the support of the uniform, we consider a couple of subject-matter considerations. First, any yield must be bounded below by 0. We cannot plant crops and harvest a negative amount per acre. Then, from a practicality perspective, it is unlikely that harvesting almost nothing or double the average would be common phenomena. To reflect this, the bounds on our uniform will be \((0.5,1.5)\) where 0.5 represents the case where a crop yields half the average and 1.5 represents a 50% increase in the yield.
To actually generate a scenarios, we draw three random values from the uniform distribution: one representing the yield multiplier for each crop. Note that 3 draws are made instead of a single one per scenario to allow the crops to produce different yields. However, I decided that each scenario should either reflect a positive harvest or a negative harvest, meaning that all the yields in one scenario should be above average or all yi