I want to get the lagrange multipliers for an LP problem solution calculated using CPLEX. I am using it via Python.
The problem is an LP problem with continuous variables with a linear objective function and elements of solution vector $x$ are linearly constrained to be in the interval $[0,1]$. Here are the main cplex calls.
my_prob = cplex.Cplex() my_prob.objective.set_sense(my_prob.objective.sense.minimize) my_prob.variables.add(obj=my_obj, lb=my_lb, ub=my_ub, names=my_colNames) my_prob.linear_constraints.add(lin_expr=my_rows, senses=my_sense, rhs=my_rhs) my_prob.solve() x = my_prob.solution.get_values()
$x$ contains the solution. I want to know what function returns the Lagrange multipliers of the solution. I now think the answer is
l = my_prob.solution.get_dual_values()
Can someone please confirm.