Hello OR-Tools / GLOP team,
I’m reaching out for guidance regarding feasibility tolerances in the GLOP solver and how to correctly relax them.
We have a linear feasibility model for which GLOP is able to find a solution reliably using the default parameters. With the defaults (notably primal_feasibility_tolerance = 1e-8), the solver converges in ~ 740-750 iterations and returns a valid solution.
For our use case, we would like to be more lenient on feasibility - specifically allowing slightly larger bound or constraint violations. To do this, we attempted to relax the tolerance by setting:
primal_feasibility_tolerance = 1e-7
(using the C# API via SetSolverSpecificParametersAsString).
Unexpectedly with this change, the solver no longer converges as expected. While the default settings consistently find a solution, the run with the relaxed tolerance does not.
To rule out mismatched feasibility criteria, we also tried explicitly setting:
dual_feasibility_tolerance = 1e-7
However, this did not change the behavior.
Given that numerically 1e-7 is a looser tolerance than the default 1e-8, we were expecting feasibility to be easier to satisfy, not harder.
Our questions are:
Is relaxing feasibility tolerances in GLOP (e.g., to 1e-7 or 1e-6) a supported and recommended use case?
Are there additional parameters that should be adjusted in conjunction with primal_feasibility_tolerance when relaxing feasibility requirements?
Is there known solver behavior where loosening feasibility tolerances can lead to non-convergence or solver stalling due to changes in pivot selection or numerical stability?
Are there best-practice guidelines for using GLOP when a looser feasibility acceptance is desired, particularly when using the C# API?
For context:
We are using the C# API of OR-Tools.
The model is continuous (no integer variables).
The objective is zero; this is effectively a feasibility problem.
Default parameter settings solve the model reliably.
Any guidance on the correct parameter combinations or recommended approach would be greatly appreciated.
Thank you for your time and for maintaining OR-Tools.
Regards,
Alfred
--
You received this message because you are subscribed to the Google Groups "or-tools-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to or-tools-discu...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/or-tools-discuss/ef493490-3696-4891-90de-2e764ac592bfn%40googlegroups.com.
Hi Team,
Thank you for the response, and apologies for the delay in getting back.
As suggested, I am attaching the solver logs for two runs of the same model so you can compare the behavior:
Run with default parameters
Default primal_feasibility_tolerance = 1e-8
Solver converges successfully in ~730 iterations and returns a feasible solution.
Run with relaxed feasibility tolerance
primal_feasibility_tolerance = 1e-7
(We also tried setting dual_feasibility_tolerance = 1e-7, with no observable change.)
In this case, the solver does not converge; it continues iterating indefinitely.
We terminated the run manually after ~18,983 iterations.
Both runs use the same model, solver backend (GLOP), and C# API, with the only difference being the feasibility tolerance settings.
Please let me know if reviewing these logs gives you an indication of where we should focus next and if you need any further info.
Thanks again for your time and help.
Regards,
Alfred
To view this discussion visit https://groups.google.com/d/msgid/or-tools-discuss/a244514d-6ad8-4615-9c9d-2adae93d3b41n%40googlegroups.com.
Hi Frederic,
Thank you for the detailed explanation - that helps a lot. I tried the suggestions you mentioned and wanted to share the updated results (logs attached for all runs).
Summary of what I tested
Baseline (default parameters)
primal_feasibility_tolerance: 1e-08 (defaults)With dropping tiny coefficients
Drop tiny coefficients + relaxed primal tolerance
dual_feasibility_tolerance: 1e-7)In this stalled run, the solver appears to enter a loop where
sum_primal_infeasibilitiesoscillates between nearly identical values repeatedly. For example:
Primal feasibility phase, iteration # 289533, sum_primal_infeasibilities = 1.076508386077535E-05
Primal feasibility phase, iteration # 289598, sum_primal_infeasibilities = 1.204802026277818E-05
Primal feasibility phase, iteration # 289663, sum_primal_infeasibilities = 1.076508409481036E-05
Primal feasibility phase, iteration # 289728, sum_primal_infeasibilities = 1.204802049148412E-05
… (continues alternating similarly)
This looks like a limit-cycle / degeneracy behavior rather than gradual convergence.
Dual simplex
To view this discussion visit https://groups.google.com/d/msgid/or-tools-discuss/CABqCn%3DdV4u0XP0Sc4vyV81A5domUi27mmfU-8KWnjw5s2by3Sw%40mail.gmail.com.