A company is opening a new franchise and wants to try minimizing their quarterly cost using linear programming. Each of their workers gets paid 500 per quarter and works 3 contiguous quarters per year. Additionally, each worker can only make 50 pairs of shoes per quarter. The demand (in pairs of shoes) is 600 for quarter 1, 300 for quarter 2, 800 for quarter 3, and 100 for quarter 4. Pairs of shoes may be put in inventory, but this costs $50 per quarter per pair of shoes, and inventory must be empty at the end of quarter 4.
I've been working on a solution to this but I'm having trouble formulating the three contiguous quarters constraint and any help is appreciated. Here is what I have, with w_i = workers in that quarter and i_i = inventory in quarter i:
minimize value: 500*(w_1 + w_2 + w_3 + w_4) + 50*(i_1 + i_2 + i_3);
CONSTRAINTS
subject to condition_1: 50*w_1 - i_1 = 600;
subject to condition_2: 50*w_2 + i_1 - i_2 = 300;
subject to condition_3: 50*w_3 + i_2 - i_3 = 500;
subject to condition_4: 50*w_4 + i_3 = 100;
subject to condition_9: i_1 >= 0;
subject to condition_10: i_2 >= 0;
subject to condition_11: i_3 >= 0;
subject to condition_12: w_1 >= 0;
subject to condition_13: w_2 >= 0;
subject to condition_14: w_3 >= 0;
subject to condition_15: w_4 >= 0;