← Latest papers
💻 computer science

Classroom Assignment: A Two-Stage Constraint Formulation

This paper introduces a two-stage MiniZinc timetabling model that reveals the vast reduction in search space from structural constraints, demonstrates that solving time scales sub-exponentially with instance size, and audits real-world campus schedules to show that room double-bookings stem primarily from inefficient allocation rather than scarcity, thereby providing a data-driven framework for identifying which hard constraints should be softened.

Original authors: Jhojan Alexander Velasquez Erazo, Carlos Andres Delgado Saavedra

Published 2026-10-27
📖 5 min read🧠 Deep dive

Original authors: Jhojan Alexander Velasquez Erazo, Carlos Andres Delgado Saavedra

Original paper licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). ✨ This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Every semester, universities face a massive logistical puzzle: fitting hundreds of classes into a limited number of rooms and time slots without creating impossible conflicts. Teachers cannot be in two places at once, students cannot attend two lectures simultaneously, and a class of thirty people cannot fit into a room built for twenty. For decades, experts have known that solving this puzzle is incredibly difficult, often requiring computers to search through billions of possibilities. The standard approach has been to tell the computer to be flexible, allowing it to break some rules if it cannot find a perfect solution. However, no one knew exactly which rules were being broken in real life, how often, or whether those breaks happened because the university simply ran out of space or because of other reasons. Without this knowledge, administrators were guessing which constraints to relax, often making the schedule worse rather than better.

Researchers at Universidad del Valle in Colombia decided to stop guessing and start measuring. They built a digital model of their own campus, a place where a single administrator manually creates the entire semester schedule by hand in three or four days, without any software assistance. The team used this real-world history to test a new way of thinking about the problem. Instead of trying to solve the entire puzzle at once, they split it into two distinct stages. First, the computer figures out the best times for every class to happen, ignoring the rooms entirely. Once those times are set, a second stage assigns the actual rooms to those classes. This separation allowed them to see exactly where the system worked and where it failed. They then ran their model against eight consecutive semesters of actual schedules published by the university to see how the real-world plans held up against the strict rules of their digital model.

The results revealed a surprising truth about how universities manage their time. The researchers found that not a single one of the eight semesters they studied satisfied all the hard rules of the model. Teachers were scheduled to be in two different rooms at the same time, and rooms were double-booked, meaning two groups were assigned to the same space simultaneously. A common assumption is that these conflicts happen because the university is overcrowded and simply does not have enough classrooms. The data proved this wrong. In three out of every four cases where a room conflict occurred, a suitable room was sitting empty in the same area at that exact hour. The problem was not a lack of space; the campus was only using between 32% and 46% of its available room capacity. The conflicts were not caused by scarcity but by the difficulty of manually coordinating hundreds of moving parts.

The study also uncovered a flaw in how the data was collected. The model relied on teachers' declared availability, assuming they told the truth about when they could teach. However, the researchers found that the recorded availability was often just a copy of the final schedule, rather than a genuine declaration of free time made before the planning began. This meant the computer was being fed a version of reality that was already broken, making it impossible to find a perfect solution. When the researchers looked at what the model could actually achieve, they found that the first stage of planning—figuring out the times—was surprisingly fast and efficient, solving complex schedules in minutes. The second stage, assigning rooms, was the bottleneck. The computer struggled to find a perfect room assignment even for small groups, suggesting that the way the problem was written down for the computer needed to change, not that the computer was too slow.

Perhaps the most valuable finding was that the university was already failing its own goals without realizing it. The administration wanted to keep certain rooms free for emergencies or special events, but the manual schedules consistently used almost every room, leaving none available. Because the human scheduler could not see the entire week at once, they missed opportunities to leave rooms open. The computer model showed that freeing up these rooms was possible without creating new conflicts, simply by rearranging the existing classes. This suggests that the solution is not to ask for more classrooms or to hire more staff, but to use a tool that can see the whole picture at once.

The researchers released their code and the data from the eight semesters so that other institutions can test these ideas. They did not claim to have solved the problem of university scheduling forever, but they provided a clear way to diagnose it. By auditing their own schedules against a strict set of rules, universities can now see exactly which constraints are truly impossible to meet and which are just habits that need to change. The study concludes that the difficulty of scheduling is not in the sheer number of classes, but in the structure of the problem itself. With the right approach, the massive search space that once seemed impossible to navigate can be reduced to a manageable size, turning a chaotic manual process into a reliable, automated one. The path forward is not to guess which rules to break, but to measure them first.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →