It's a bit strange to post a .doc. Anywho, that's clearly a homework problem. What have you tried? Have you written down the linear constraints and cost function? If you're not able to, you should get someone to tutor you in person.
The time you enjoy wasting is not wasted time. Bertrand Russell
It's a bit strange to post a .doc. Anywho, that's clearly a homework problem. What have you tried? Have you written down the linear constraints and cost function? If you're not able to, you should get someone to tutor you in person.
it is home work problem! and I will post soon what I did so far however I just want to make sure my answers right and thanks for respond!
1.51VX1+1.73CX2+1.62BX3+1.62PX4+1.4BBX5+1.4PKX6 <= 3000
2.29VX7+2.29CX8+2.29BX9+2.29PX10+2.34BBX11+2.34PKX12<=280
1.49VX13+2.09CX14+2.09BX15+2.09PX16+2.09BBX17+2.09PKX18<=500
2.37VX19+2.38CX20+2.35BX21+2.35PX22+2.35BBX23+2.37PKX24<=300
1.84CX25<=24
1.94BX26<=25
2.03PX27<=25
1.84BBX28<=25
1.95PKX29<=25
This what I did !
where x1 = VX, x2 = CX, x3 = BX, x4 = PX, x5 = BBX, and x6 = PKX in your notation. For instance, to create 1 gallon of Very Vanilla takes...
8 cups cream @ $0.11 / cup
1 cup sugar @ $0.10 / cup
3 table spoons vanilla extract @ $0.03 / table spoon
1 table spoon salt @ $0.02 / table spoon
for a total cost of 8*$0.11 + 1*$0.10 + 3*$0.03 + 1*$0.02 = $1.09 per gallon. The problem thinks this gallon can definitely be sold at $2.39, giving a profit of $2.39 - $1.09 = $1.3, which agrees with my objective function and disagrees with yours. These costs were taken from your .doc attachment. I have no idea where the ingredient numbers in your most recent post came from. Our objective functions also aren't multiples of each other. Your profits are also higher than $2.39 per gallon, which makes no sense.
My constraints also substantially disagree with yours. I don't really know what you mean by what you've written in that section--for instance, what is PKX29 referring to? In any case, remember not to forget the constraints that at least 10 gallons are made of each flavor and at most 1/4th of the total product contains nuts. There is another implicit set of constraints forcing the ingredients to appear in nonnegative amounts. These are implied by the xi >= 10 constraints, though, so can be omitted after being noted.
Edit: Added constraint.
Last edited by jemidiah; Apr 28th, 2011 at 06:22 PM.
The time you enjoy wasting is not wasted time. Bertrand Russell
You seem to have rounded your objective function slightly. For the x6 coefficient, I have 0.865 instead of 0.87. In this particular case it's important not to round if you can avoid it. Otherwise our objective functions now agree.
I'll assume you've forgotten to write the + signs between terms of the constraints. In that case, the ones you've listed all agree with my versions. However, you've forgotten several. You need to include the constraints given by the following sentence from your attachment: "We must make at least 10 gallons of each flavor and no more than 25 percent of all the ice cream produced can be flavors with nuts."
The time you enjoy wasting is not wasted time. Bertrand Russell
The x3 <= 25 isn't right. You've also again missed the constraint requiring at most 1/4th of the resulting ice cream have nuts. The rest are correct.
what do you mean by x3 <= 25 isn't right! and be hones with you I have no I idea what most 1/4th of the resulting ice cream have nuts mean! I been more than two hours trying to solve it but I could not figure it out! Please help me!
By "x3 <= 25 isn't right", I mean it's not generated by any of the constraints on the problem. The similar constraint, 0.45 x3 <= 25, is generated by limiting the number pounds of walnuts to 25.
Suppose for a moment that you produced 3 gallons of Very Vanilla, 1 gallon of Black Walnut, and 1 gallon of Pecan Crunch. In all you would have made 5 gallons of ice cream, of which 2 gallons contain nuts. That is, 2/5 = 40% of the resulting product have nuts. This case is disallowed, since the resulting fraction must be at most 25%.
The time you enjoy wasting is not wasted time. Bertrand Russell
By "x3 <= 25 isn't right", I mean it's not generated by any of the constraints on the problem. The similar constraint, 0.45 x3 <= 25, is generated by limiting the number pounds of walnuts to 25.
Suppose for a moment that you produced 3 gallons of Very Vanilla, 1 gallon of Black Walnut, and 1 gallon of Pecan Crunch. In all you would have made 5 gallons of ice cream, of which 2 gallons contain nuts. That is, 2/5 = 40% of the resulting product have nuts. This case is disallowed, since the resulting fraction must be at most 25%.
Nope, that's perhaps even more wrong. I have no idea why you might think it was right, either.... Could you give your reasoning, and explain your current understanding of the condition "and no more than 25 percent of all the ice cream produced can be flavors with nuts"?
The time you enjoy wasting is not wasted time. Bertrand Russell
"We must make at least 10 gallons of each flavor and no more than 25 percent of all the ice cream produced can be flavors with nuts."
I really did not get this part at all! even can not understand what is required in it! would you please explain it for me and not by giving me example confuse me more!
Thanks
Is English not your native language? If so, perhaps you should get a translation of that sentence. It's really quite clear (as is my example). In any case, I'll try once more.
Some of the flavors contain nuts. These flavors are Black Walnut and Pecan Crunch (walnuts and pecans are types of nuts). The remaining flavors do not contain nuts. Say the total amount of ice cream you make is T. Say the total amount of Black Walnut and Pecan Crunch is N. N must be no more than 25% of T.
The time you enjoy wasting is not wasted time. Bertrand Russell
Yes! English is my second language! so what I understand is that I have 60 Gallons of all the flavors and we need 25% from them! which means that 15 gallons nuts out of 60! is that right!
Last edited by ALYAMI01; Apr 29th, 2011 at 09:24 PM.
Yes, as I understand what you're saying you are correct. If you made 60 gallons of ice cream total, you need *at most* 25% of them to contain nuts. That is, you need <= 15 gallons of Black Walnut and Pecan Crunch together. Try to put your understanding into a constraint equation. That will be clearer than words.
The time you enjoy wasting is not wasted time. Bertrand Russell
No, you still don't understand. I'm sorry, there's not much more I can do. I've explained the constraint twice carefully and twice more less carefully. You are just not understanding my words. I don't think it would help to explain the constraint a fifth time. If we have this much trouble communicating on something so simple, I don't think I will be very helpful with the remaining parts of the problem.
The time you enjoy wasting is not wasted time. Bertrand Russell
No, you still don't understand. I'm sorry, there's not much more I can do. I've explained the constraint twice carefully and twice more less carefully. You are just not understanding my words. I don't think it would help to explain the constraint a fifth time. If we have this much trouble communicating on something so simple, I don't think I will be very helpful with the remaining parts of the problem.
well, thank you so much for helping me! you can imagine how hard to study this staff in different language!
It occurred to me that I can at least give you the result of running the linear system even if I'm not comfortable giving you the last constraint. Please only use it to check your own result. I ran the following through the linear programming solver at http://vinci.inesc.pt/lp/ using the Simplex method:
@jemidiah: I'm probably off-topic here, but I see that you are pretty comfortable around linear programming problems... I recently needed to learn the Simplex algorithm for a linear programming problem, but I couldn't find any good materials to study from -- trust me, I really tried. Would you by any chance be able to point me in the right direction?
Please rate helpful ppl's posts. It's the best 'thank you' you can give
It occurred to me that I can at least give you the result of running the linear system even if I'm not comfortable giving you the last constraint. Please only use it to check your own result. I ran the following through the linear programming solver at http://vinci.inesc.pt/lp/ using the Simplex method:
@obi1kenobi: I've never really studied linear programming. I've picked some up randomly and done a *very* small amount of my own study in the field (computing a condition for the volume of the feasible polytope to be finite/infinite). I've only ever been intuitively familiar with the Simplex method. But, I have some time and learning it would fill a hole in my mathematical knowledge. A brief search yielded two chapters of a book covering the topic: (1)(2). From the first few pages the explanation is leisurely and complete. I'll read the rest now, and if it turns out poorly I'll let you know.
The time you enjoy wasting is not wasted time. Bertrand Russell
thanks bro, not sure if we could solve this problem by excel I've tried many times last night to solve it by the solver by I did not get the final answers; it seems to be something is missing in this problem. Have you tried to solve it by excel!
Nope, I haven't tried solving it with Excel, only the random online Simplex solver I linked. To be honest I have no idea how to use Excel to do a problem like this. It certainly wouldn't be my first choice in any case. If you have access to Mathematica, Maple, or Matlab, I'd suggest using them instead, since it's much less awkward.
I was curious and used this guide to linear programming with Excel to enter my results (see the attached spreadsheet). It solved the system essentially instantly with
which differs from the above only rarely and in at worst the millionths place.
Edit: I doubt anyone but me cares, but it appears the exact solution is (120 + 5/6, 25, 10, 44 + 1/6, 25, 33 + 1/3). One could verify this result rigorously by applying Thm. 2.6 and Thm. 2.7 of my companion thread's main reference--that is, essentially manually running a final iteration of Simplex. A more elementary proof could be given by looking at the gradient of the objective function and considering the hyperplane with it as normal. Any vector lying on the gradient's side of the hyperplane could increase the function, but a proof by cases would show that such a direction must put you on the wrong side of the constraint hyperplanes on which the above solution lies.
Last edited by jemidiah; May 3rd, 2011 at 07:14 AM.
The time you enjoy wasting is not wasted time. Bertrand Russell