Troubleshooting with the Infeasibility Diagnostic Engine

What is Infeasibility?

When a scenario run is infeasible, it means that the solver cannot find any solutions that satisfy all the specified constraints simultaneously. In other words, the defined constraints are too restrictive or they contradict each other, making it impossible to satisfy all of them at once. Examples are:

  • Total initial inventory + production capacity over a model's horizon are 12.5M units and the total demand is for 13M units
  • Total flow using Mode = Rail is restricted to 150,000 lbs, but the destinations which only have Mode = Rail available to them need to receive at least 250,000 lbs in order to be able to satisfy all the demand in the model

Identifying an Infeasible Neo Scenario

If a Neo (network optimization) scenario run is infeasible, a user can tell from within Cosmic Frog and also by looking at the run's logs in the Run Manager application. Within Cosmic Frog, the Optimization Network Summary output table will show Solve Status = Infeasible and many other output columns, such as Solve Type and Solve Time, will be blank:

In the Run Manager application, also on the Optilogic Platform, users can select the scenario run, which will have Status = Error, and look at the run's logs on the right-hand side:

  1. Click on the Run Manager button in the list of applications on the left-hand side while logged into the Optilogic platform (optilogic.app) to open the Run Manager application. If the Run Manager button is not visible, you may need to scroll or click on the button with 3 horizontal dots to show all applications.
  2. Select the run for which you want to view the logs by clicking on the round checkbox. Here the user has selected the scenario run that was infeasible.
  3. On the right-hand side multiple logs of the run are available. Clicking on the second icon will bring up the Job Records log.
  4. The second entry in the Job Records log indicates that this run was infeasible.

Check Infeasibility Tool

Running the check infeasibility tool is a great first step in identifying why a scenario is infeasible. It can allow the scenario to optimize even if the current constraints cause infeasibility. Generally, the tool will loosen constraints in the scenario, which allow it to solve. This means that the check infeasibility tool is solving an optimization problem focused on feasibility, not cost. The goal of this augmented model is to minimize how much the constraints are loosened, and therefore the tool can often find:​

  1. Which constraints are violated, and​…
  2. By how much

Running the Tool

The Check Infeasibility tool is accessed via the model run options on the Run Settings screen:

  1. After clicking on the green Run button at the right top in Cosmic Frog, the Run Settings screen comes up.
  2. Select the scenario you want to run the "Check Infeasibility" tool on.
  3. On the right-hand side in Technology Parameters > Optimization (Neo), check the box of the Check Infeasibility tool to use it. Then click on the green Run button to kick off the infeasibility check.

When running the Check Infeasibility tool in this default manner, all constraints will be relaxed. Additional run parameters can be used to selectively choose which constraints can be relaxed during a Check Infeasibility run and which need to be enforced, see the "Infeasibility Parameters" section in the "Running Models & Scenarios" help center article. Especially in models where many different types of constraints are applied, this can help in determining which constraint(s) cause the infeasibility and how constraints interact with each other. An approach can be to run the Check Infeasibility tool a few times with different constraints enforced and then compare the results. It also lets users indicate to the solver which constraints are most important to satisfy by keeping those enforced, while others are allowed to be relaxed.

  1. Print Full Solution During Infeasibility Diagnosis - when this option is turned on, the full solution of the model during an infeasibility diagnosis run will be printed. This includes standard output tables (i.e. Optimization Network Summary, Optimization Flow Summary, Optimization Constraint Summary, etc.). This option only works when running the Check Infeasibility tool, which needs to be turned on. When this option is not turned on (the default), only the Optimization Constraint Summary output table is populated when running the Check Feasibility tool.
  2. Relax … Constraints – when these options are turned on (by default they all are), the type of constraint described by the option's name will be allowed to be relaxed during a Check Infeasibility run. When turned off, the constraints of that type still need to be satisfied during a Check Infeasibility run.

Tool Output

Once a Check Infeasibility run completes successfully, the results that are likely most helpful for identifying the infeasibility are found in the Optimization Constraint Summary output table. Users may need to filter for the scenario name in case this table contains results of multiple check infeasibility scenario runs. The following 2 screenshots show the 1 record in this table for the scenario called "Flow Constraint El Bajio 2M" scenario that returns infeasible as shown above. This first screenshot shows that the constraint in question is a Flow constraint that is applied on the lanes from the El Bajio Factory to a group of DCs named DCs Con:

Scrolling right in the table, we can see additional fields which indicate why this constraint leads to infeasibility in the scenario:

  1. The Constraint Type and Constraint Value fields repeat the type and value set for this constraint on the Flow Constraints input table, in this case a maximum flow of 2,000,000 was allowed.
  2. The Constraint Violation and Suggested Constraint Value fields tell us by how much the original constraint (2M) needed to be violated (1,497,480) for the model to become feasible. Therefore, the suggested value for the constraint is 3,497,480 (2,000,000 original constraint + 1,497,480 constraint violation).

In this example, the check infeasibility tool can pinpoint the infeasibility exactly. At other times, the outcomes will be more general, see for example the following screenshots of results of a check infeasibility run on a different scenario:

Here the constraint that cannot be fulfilled is the demand for 1,000 units of Product_2 in Period_6. The output in the Constraint Summary output table is telling us that a way to make this feasible is to change the demand quantity to be 0. We will need to investigate the model inputs further to understand why this is. On further inspection, the infeasibility cause is found to be that the maturation time of Product_2 is set to 50 days. This is longer than the model horizon of 42 days (6 weekly periods). So, if no or not enough initial inventory is present in the model, Product_ 2 cannot be made and mature in time to fulfill demand in Period_ 6.

If the user has turned on the "Print Full Solution During Infeasibility Diagnosis" option, see above, the outputs in the other output tables can possibly also help to determine the cause of the infeasibility.

Final Notes

  • Under certain circumstances, running the Check Infeasibility tool can still return infeasible, for example:
    • The tool was run with still enforcing a subset of the constraints and those by themselves cause the infeasibility
    • The model has numerical stability problems and the returned infeasibility is a false negative, it should have returned a feasible solution. A sign this could be the case is if the Constraint Summary output table does not contain concrete pointers to what causes the infeasibility. As a next step users could try separate runs where they change one of the following run parameters (one at a time).
      • Increase the MIP Relative Gap Percentage
      • Turn on Logical Constraints
      • Turn on Scale Input Data
  • Sometimes, the cause of infeasibility is not immediately clear. Especially for more complex models with multiple constraints, infeasibility can be due to a combination of multiple different constraints.​
  • In general, infeasibility is a complex topic. The check infeasibility tool cannot always catch or relax all potential infeasibility causes, but it is a very useful place to start.
  • As always and especially if you cannot resolve an infeasible model yourself in a reasonable amount of time, please do not hesitate to contact the Optilogic support team at support@optilogic.com.

What is Infeasibility?

When a scenario run is infeasible, it means that the solver cannot find any solutions that satisfy all the specified constraints simultaneously. In other words, the defined constraints are too restrictive or they contradict each other, making it impossible to satisfy all of them at once. Examples are:

  • Total initial inventory + production capacity over a model's horizon are 12.5M units and the total demand is for 13M units
  • Total flow using Mode = Rail is restricted to 150,000 lbs, but the destinations which only have Mode = Rail available to them need to receive at least 250,000 lbs in order to be able to satisfy all the demand in the model

Identifying an Infeasible Neo Scenario

If a Neo (network optimization) scenario run is infeasible, a user can tell from within Cosmic Frog and also by looking at the run's logs in the Run Manager application. Within Cosmic Frog, the Optimization Network Summary output table will show Solve Status = Infeasible and many other output columns, such as Solve Type and Solve Time, will be blank:

In the Run Manager application, also on the Optilogic Platform, users can select the scenario run, which will have Status = Error, and look at the run's logs on the right-hand side:

  1. Click on the Run Manager button in the list of applications on the left-hand side while logged into the Optilogic platform (optilogic.app) to open the Run Manager application. If the Run Manager button is not visible, you may need to scroll or click on the button with 3 horizontal dots to show all applications.
  2. Select the run for which you want to view the logs by clicking on the round checkbox. Here the user has selected the scenario run that was infeasible.
  3. On the right-hand side multiple logs of the run are available. Clicking on the second icon will bring up the Job Records log.
  4. The second entry in the Job Records log indicates that this run was infeasible.

Check Infeasibility Tool

Running the check infeasibility tool is a great first step in identifying why a scenario is infeasible. It can allow the scenario to optimize even if the current constraints cause infeasibility. Generally, the tool will loosen constraints in the scenario, which allow it to solve. This means that the check infeasibility tool is solving an optimization problem focused on feasibility, not cost. The goal of this augmented model is to minimize how much the constraints are loosened, and therefore the tool can often find:​

  1. Which constraints are violated, and​…
  2. By how much

Running the Tool

The Check Infeasibility tool is accessed via the model run options on the Run Settings screen:

  1. After clicking on the green Run button at the right top in Cosmic Frog, the Run Settings screen comes up.
  2. Select the scenario you want to run the "Check Infeasibility" tool on.
  3. On the right-hand side in Technology Parameters > Optimization (Neo), check the box of the Check Infeasibility tool to use it. Then click on the green Run button to kick off the infeasibility check.

When running the Check Infeasibility tool in this default manner, all constraints will be relaxed. Additional run parameters can be used to selectively choose which constraints can be relaxed during a Check Infeasibility run and which need to be enforced, see the "Infeasibility Parameters" section in the "Running Models & Scenarios" help center article. Especially in models where many different types of constraints are applied, this can help in determining which constraint(s) cause the infeasibility and how constraints interact with each other. An approach can be to run the Check Infeasibility tool a few times with different constraints enforced and then compare the results. It also lets users indicate to the solver which constraints are most important to satisfy by keeping those enforced, while others are allowed to be relaxed.

  1. Print Full Solution During Infeasibility Diagnosis - when this option is turned on, the full solution of the model during an infeasibility diagnosis run will be printed. This includes standard output tables (i.e. Optimization Network Summary, Optimization Flow Summary, Optimization Constraint Summary, etc.). This option only works when running the Check Infeasibility tool, which needs to be turned on. When this option is not turned on (the default), only the Optimization Constraint Summary output table is populated when running the Check Feasibility tool.
  2. Relax … Constraints – when these options are turned on (by default they all are), the type of constraint described by the option's name will be allowed to be relaxed during a Check Infeasibility run. When turned off, the constraints of that type still need to be satisfied during a Check Infeasibility run.

Tool Output

Once a Check Infeasibility run completes successfully, the results that are likely most helpful for identifying the infeasibility are found in the Optimization Constraint Summary output table. Users may need to filter for the scenario name in case this table contains results of multiple check infeasibility scenario runs. The following 2 screenshots show the 1 record in this table for the scenario called "Flow Constraint El Bajio 2M" scenario that returns infeasible as shown above. This first screenshot shows that the constraint in question is a Flow constraint that is applied on the lanes from the El Bajio Factory to a group of DCs named DCs Con:

Scrolling right in the table, we can see additional fields which indicate why this constraint leads to infeasibility in the scenario:

  1. The Constraint Type and Constraint Value fields repeat the type and value set for this constraint on the Flow Constraints input table, in this case a maximum flow of 2,000,000 was allowed.
  2. The Constraint Violation and Suggested Constraint Value fields tell us by how much the original constraint (2M) needed to be violated (1,497,480) for the model to become feasible. Therefore, the suggested value for the constraint is 3,497,480 (2,000,000 original constraint + 1,497,480 constraint violation).

In this example, the check infeasibility tool can pinpoint the infeasibility exactly. At other times, the outcomes will be more general, see for example the following screenshots of results of a check infeasibility run on a different scenario:

Here the constraint that cannot be fulfilled is the demand for 1,000 units of Product_2 in Period_6. The output in the Constraint Summary output table is telling us that a way to make this feasible is to change the demand quantity to be 0. We will need to investigate the model inputs further to understand why this is. On further inspection, the infeasibility cause is found to be that the maturation time of Product_2 is set to 50 days. This is longer than the model horizon of 42 days (6 weekly periods). So, if no or not enough initial inventory is present in the model, Product_ 2 cannot be made and mature in time to fulfill demand in Period_ 6.

If the user has turned on the "Print Full Solution During Infeasibility Diagnosis" option, see above, the outputs in the other output tables can possibly also help to determine the cause of the infeasibility.

Final Notes

  • Under certain circumstances, running the Check Infeasibility tool can still return infeasible, for example:
    • The tool was run with still enforcing a subset of the constraints and those by themselves cause the infeasibility
    • The model has numerical stability problems and the returned infeasibility is a false negative, it should have returned a feasible solution. A sign this could be the case is if the Constraint Summary output table does not contain concrete pointers to what causes the infeasibility. As a next step users could try separate runs where they change one of the following run parameters (one at a time).
      • Increase the MIP Relative Gap Percentage
      • Turn on Logical Constraints
      • Turn on Scale Input Data
  • Sometimes, the cause of infeasibility is not immediately clear. Especially for more complex models with multiple constraints, infeasibility can be due to a combination of multiple different constraints.​
  • In general, infeasibility is a complex topic. The check infeasibility tool cannot always catch or relax all potential infeasibility causes, but it is a very useful place to start.
  • As always and especially if you cannot resolve an infeasible model yourself in a reasonable amount of time, please do not hesitate to contact the Optilogic support team at support@optilogic.com.

Have More Questions?

Contact Support

Get in touch

Contact Sales

Get in touch

Visit Frogger Pond Community

Visit our Community