Originally posted by: Hosssein
I posted a question last week and did not receive any reply. So I am restating my question here. Hope that CPLEX experts in this forum can help me.
My question is about mapping of variables between the original and the presolved models. I am using Callable Library and I need to extract some information of the model using CPXgetcallbacknodelp. Since the information in CPXgetcallbacknodelp are associated with the presolved variables, I need to map presolved variables to the original variables myself (note that setting CPX_PARAM_MIPCBREDLP to CPX_OFF does not work for CPXgetcallbacknodelp).
As I know in order to map the presolved variables to the original variables I have to use CPXgetprestat. So I have included the following line in my code:
"status = CPXgetprestat (env, lp, &presolvestat,precstat, NULL,NULL, NULL);"
The problem is that sometime the mapping from the presolved variables to the original variables is not one to one because of variable aggregation, etc. To be more clear, when pcstat[i]>=0 I know that variable pcstat[i] in the presolved model maps to variable i in the original model (that is OK with me) but if pcstat[i]<0 I do not have any idea about the mapping. For example pcstat[i]=-4 means that the original variable i is aggregated, but we do not know which presolved variable includes the original variable i and what is the coefficient of this original variable in the corresponding presolved variable. I have also similar problems for the cases of pcstat[i]= -3 and -5.
Could anyone help me?
P.S.
For details of CPXgetprestat see
http://www-01.ibm.com/support/knowledgecenter/SS9UKU_12.4.0/com.ibm.cplex.zos.help/refcallablelibrary/html/functions/CPXgetprestat.html?lang=en
#CPLEXOptimizers#DecisionOptimization