LP Mining with LP2Graph: A Use Case for Railway Rescheduling

Discover how LP2Graph extracts and structures MILP formulations from railway rescheduling literature to create a reproducible taxonomy, validated with Gurobi.

martes, 28 de julio de 2026 • 4 min read • Q2BSTUDIO Team

Extracción de formulaciones MILP con LP2Graph

Railway rescheduling is a top-tier technical and operational challenge. When an incident occurs —a breakdown, a weather delay, or a track conflict— operators need to recalculate timetables, allocate resources, and minimize impact within minutes. Traditionally, this problem is modeled using Mixed-Integer Linear Programming (MILP), an optimization technique combining continuous and discrete variables. However, the scientific community has hundreds of formulations scattered across incompatible notations, and narrative surveys often classify them by vocabulary rather than by structure. That is where LP2Graph comes in: a method that extracts, homogenizes, and catalogues the structure of these models in a reproducible way. In this article we explore how LP Mining with LP2Graph can revolutionize railway rescheduling and, moreover, how companies like Q2BSTUDIO can apply this logic in high-value software solutions.

The core of LP2Graph is its canonical grammar: each LP or MILP formulation is represented as a typed graph of variables and equations, derived from a single model. Once a source paper is parsed into that model, the entire downstream flow —homologation, bottom-up clustering (variables, constraints, objective, global structure) and classification by domain and approach— is deterministic. The resulting groups are labeled with a self-updating classifier based on seed rules. The outcome is an objective, repeatable taxonomy of variable types, constraints, and model types. This allows railway engineers to reuse proven knowledge instead of reinventing the wheel every time.

Imagine a real scenario: a railway operator needs to reschedule after a storm damages a track segment. With LP2Graph, the system can search a mined repository of thousands of MILP models for those that solved similar problems —for instance, station capacity constraints or maintenance windows— and extract the most efficient structures. Then an optimization engine like CBC, HiGHS, or Gurobi re-runs the candidates against current data and compares results with historical optima. This speeds up decision-making and reduces the risk of suboptimal solutions.

But model mining is not just for researchers. Software development companies like Q2BSTUDIO, specialized in artificial intelligence, can capitalize on this technique to build custom applications that integrate LP2Graph into railway platforms. For example, a custom software system could include a dynamic planning module that, upon detecting an incident, automatically triggers a search in the model graph and generates a new timetable in seconds. This kind of solution requires robust cloud infrastructure, and here services like cloud AWS/Azure come into play. Hosting the model repository and the optimization engine in elastic environments guarantees scalability and low latency, even when processing hundreds of formulations simultaneously.

Furthermore, security is critical in critical infrastructure such as railways. A cybersecurity team must protect both the model repository (to prevent malicious tampering) and the communication between field sensors and the rescheduling system. Q2BSTUDIO has experts in pentesting and secure architectures who can audit these solutions, complying with regulations such as NIS2 or ISO 27001.

Another relevant angle is integration with business intelligence tools. The data generated by LP2Graph —which models are used, which fail, which are faster— can be visualized with BI / Power BI so managers make informed decisions about network evolution. For instance, a dashboard could show that, at certain stations, the capacity constraint formulation recommended by LP2Graph reduces calculation time by 30%, pointing out where to invest in model improvement.

The current trend moves toward autonomous AI agents. An AI agent trained on the LP2Graph taxonomy could not only search for models but also propose modifications to existing formulations based on historical patterns. For example, if a rescheduling model uses binary variables to represent occupied tracks, the agent could suggest a reformulation with more compact big-M constraints, improving efficiency. Q2BSTUDIO is already developing prototypes of agents that interact with optimized model repositories, and its experience in custom software development allows adapting these capabilities to specific railway clients.

Of course, LP mining is not a panacea: it still requires fine-tuning of clustering algorithms and validation of regenerated optima. But the direction is clear. By objectifying model classification, LP2Graph offers a reproducible foundation for the railway industry to standardize its optimization practices. And companies like Q2BSTUDIO are uniquely positioned to bring this academic knowledge into production, combining AI, cloud, cybersecurity, and BI into robust, custom platforms. The railway of the future will not only be faster and more punctual, but it will achieve this by learning from the best available research, thanks to LP Mining with LP2Graph.

A BREAK?

Play for a moment before you go

OUR SERVICES

How we can help you

Do you have a project in mind?

Tell us your vision and we'll turn it into a software solution. Whatever the scope, we make your idea real.