Using information from the presolve phase to improve the model

Greetings everyone.
Could someone direct me to some documentation where I can learn how to use information from the presolve phase (both from Cplex and Gurobi) to improve model execution?
I am particularly interested in detecting and removing redundant constraints and, in general, increasing the efficiency of the solve phase.

To see Gurobi’s presolved problem in .lp file format, set the following options:

option solver gurobi;
option gurobi_options 'writepresolved=gurobipre.lp';
option gurobi_auxfiles rc;
solve;

The resulting file will show you all the constraints that were in the problem after presolving. This might be of use in studying some problems, especially if they are not too large or complicated. Gurobi won’t tell you what presolve steps it applied, however, so you’ll have to puzzle that out for yourself. You might want to also look at the problem before presolving, which you can get by specifying writemodel instead of writepresolved in gurobi_options.

  • If you are already specifying a gurobi_options string, add writepresolved=gurobipre.lp to it. (All gurobi options need to be in the same gurobi_options string.)
  • You can specify any file instead of gurobipre.
  • You can set option presolve 0; in AMPL to force all the presolving to be done in Gurobi.

CPLEX does not have an option like this.