coin-or / Cbc

COIN-OR Branch-and-Cut solver
Other
814 stars 115 forks source link

Feature Request -- Retrieving multiple optimal solutions #629

Open d-saikrishna opened 10 months ago

d-saikrishna commented 10 months ago

Here is my problem

Lp_prob = p.LpProblem('Problem', sense = p.LpMinimize)  

x = p.LpVariable("x1", lowBound = 0)   # Create a variable x 
y = p.LpVariable("x2", lowBound = 0)

# Objective Function 
Lp_prob += x+y
# Constraints: 
Lp_prob += x+y==3

The solver gave me an answer of (3,0), whcich is true.

But since this problem has multiple optimal solutions, I have following requests:

  1. Status: A new status instead of Optimal to show the presence of multiple optimal solutions.
  2. A way to retrieve all multiple optimal solutions (in steps, which can be user defined)