I want to get the constraints causing infeasibility and store it in a table for printing. SAS doesn't allow me to use IIS=on when using milp solver.
You can use the Output Delivery System to write the EXPAND / IIS output to a data set:
ods output expand=myexpand;
You can then use PROC PRINT if you want, but it will look very similar. Both ways display only the IIS (and not all the other variables and constraints) in the Results Viewer.
MILP IIS is available in SAS Optimization 8.5 (SAS Viya 3.5), released in November 2019:
For other releases, you might try using the RELAXINT option, in case the LP relaxation is infeasible:
solve with lp relaxint / iis=on;
I have base sas 9.4 and SAS EG 7.1. Looks like I don't have that yet.
I don't quite understand. Did you try the SOLVE statement that I recommended? If so, did you get an error message?
Tried it with that, unfortunately it was still infeasible. I managed to predefine certain conditions which would make the problem unfeasible, as sort of a message to my users.
OK, that result is a good thing when you want to figure out why a problem is infeasible. It means that even the linear programming relaxation is infeasible. The following statement will then show you the resulting IIS found by the solver to help you diagnose the infeasibility:
expand / iis;
You can use the Output Delivery System to write the EXPAND / IIS output to a data set:
ods output expand=myexpand;
You can then use PROC PRINT if you want, but it will look very similar. Both ways display only the IIS (and not all the other variables and constraints) in the Results Viewer.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
Learn how to run multiple linear regression models with and without interactions, presented by SAS user Alex Chaplin.
Find more tutorials on the SAS Users YouTube channel.