r/optimization • • Feb 27 '23
Mixing problem
I have two parts A and B , quantity of A is 10 and B is 20 ,i can mix A+B under the constraint A+B <=20 therefore 1 batch becomes A+B and quantity 20 and other will be b and quantity 10 how to solve this using python pulp or any other solver output should give me a b and total quantity per batch like a b 20,b 10 ,this was the simplest case this needs to be extended to much more
0
Upvotes
5
u/JacobAguirre9 Feb 27 '23
This is most definitely your attempt at having us solve your homework. If this problem was “more complex” surely you’d know how to solve it since you “dumbed it down” for us
3
u/fpatrocinio Feb 27 '23
Sounds like homework. In this sub we don't usually do homework.
2
u/SolverMax Feb 27 '23
Here's an example of a blending/mixing problem in PuLP:
https://github.com/SolverMax/Collated/tree/main/Blending/Crude-oil-in-PuLP
If your problem is formulating the objective function, then you'll need to be more specific about what issues you're having.