简体   繁体   中英

In CPLEX, how to find a variable in the model is in the basis or not?

I am looking for a simple way to obtain the list of base variables a LP problem with CPLEX, or a way to indicate a variable is in basis or not?

Actually, I am working on a column generation algorithm. After solving the Restricted Master Problem, the new column becomes 0. How can check the new variable is 0 but in basis, ie, degeneracy, or it is not in basis and there is an error in my implementation?

you could use getBasisStatuses in C++

This method puts the basis status of each variable in var into the corresponding element of the array cstat, and it puts the status of each row in con (an array of ranges or constraints)into the corresponding element of the array rstat.Arrays rstat and cstat are resizedaccordingly.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM