Tracing infeasible constraint in linopy

35 views
Skip to first unread message

Peter Klein

unread,
Feb 28, 2023, 1:53:06 PM2/28/23
to pypsa
Dear Fabian

Is there a way to trace an infeasible constraint equation when using linopy in pypsa?

For example my solver Xpress tells me which row is infeasible, and it would be amazing if there is quick way to search in n.model.constraints to see which variables are involved in the infeasible equation.

For example I would get an output:
The problem is infeasible due to row c8068100

Previously I would look in the .lp file for the constraint label and then see which variables are in the equation for example X105 -X1182701 -X1182702=225

I would then look in n.vars to trace variable names., which can be time consuming to figure out.

Regards
Peter
Reply all
Reply to author
Forward
0 new messages