I'm going through several thousand iterations of my model each time it runs and due to the input data there are some infeasibilities and some "presolve: constraint cannot hold"/"all variables eliminated" errors that occur.
I currently note which iteration failed due to an actual infeasibility using this code in my script:
if match (solve_message, "infeasible") > 0 then {
print "start:end, year, Problem?" , Start, End, CurrentYear, "- infeasible -" > SolverErrorOut.out;
#break;
}
That works well. However I ALSO want to output some sort of note when the presolve has a fit. I tried the code below and it told me that "presolve_message" is not defined (which makes sense I guess...). Can anyone tell me what it is likely to output when this happens? Currently I'm thinking that at this point it throws caution to the wind and violates constraints at random so I want to filter these results out of my final dataset...
if match (presolve_message, "all variables eliminated") > 0 then {
print "start:end, year, Problem?" , Start, End, CurrentYear, "- infeasible -\n" > PreSolveErrorOut.out;
#break;
}
Thank you to anyone who knows more than I do! :)