A container ship that arrives at a port needs a berth, a stretch of quay with cranes where it can load and unload. If the berth is occupied, the ship waits, its engines keep burning fuel and producing emissions, and the port's plan for the following ships slips. Deciding which ship goes to which berth, and when, is the berth allocation problem, one of the most studied planning problems of container terminals. Since the fuel price rises of the late 2000s, many carriers also sail more slowly, which makes arrival times more flexible and more uncertain. This essay explains the problem, a 2009 idea that turned the arrival time into something to optimize, and how recent data-driven models improve the inputs of the schedule.
What a berth schedule is
The quay of a container terminal is divided into berths, and in the basic model each berth serves one ship at a time. Ships arrive over time and ask to be served and to leave within a time window, usually fixed in a contract between the terminal operator and the carrier. The terminal wants to assign every ship to a berth and a start time so that waiting and delayed departures are as small as possible while its customers stay satisfied. Earlier formulations reduced the time window to a single point in time, and a 2007 study by Golias, Boile and Theofanis showed how to penalize late departures and reward early and timely ones. In the discrete version, researchers sometimes treat the problem like machine scheduling, with each ship as a job and each berth as a machine.
Four flavors of the problem
In the discrete problem the quay is a finite set of berths, and in the continuous problem a ship can berth anywhere along the quay. In the static problem all the ships to be served are already in the port when the scheduling begins, while in the dynamic problem some have not arrived yet, so the schedule has to rely on estimated arrival times. The dynamic case is the realistic one, because ships arrive over time. The field is large: the 2015 follow-up survey of Bierwirth and Meisel counted more than 120 new publications on berth allocation and quay crane scheduling since their first survey, which covered research up to 2009.
Arrival time as a decision, not a given
Most formulations assumed either that the ships are already in port or that their arrival times are fixed in advance. Golias and colleagues proposed in 2009 to treat the arrival time as a variable that the schedule can optimize. Slow steaming, the practice of sailing at a lower speed to save fuel, has been in use since 2008 and made this natural: a ship that does not need to arrive early can sail more slowly. Their policy aims to minimize delayed departures and, indirectly, the fuel burned and the emissions produced by ships idling in port, and it gives the carrier an optimized speed. On example problems with real data, the authors report lower emissions from idle vessels, better fuel use and port waiting time, and fewer effects of late arrivals on the carrier's schedule.
Putting fuel and emissions in the model
Later work made fuel and emissions explicit. Du and colleagues (2011) built a berth allocation model in which fuel consumption depends on the sailing speed. This relation is nonlinear, so they recast the model as a mixed-integer second-order cone program that solvers can handle. Emissions are estimated for the sailing period with common emission factors, and emissions during mooring are assessed in a step after the optimization, based on the waiting time. Their results show that the strategy cuts fuel use and emissions while keeping the terminal's service level. Environmental criteria are therefore part of the berth scheduling literature, not an open gap.
Better inputs: predicting service time
A schedule is only as good as the times it assumes. The service time of a vessel, from its arrival at the berth to its departure, is a key measure of port efficiency, and the departure time that vessels report often differs substantially from what happens. Yan and colleagues (2024) built a tree-based stacking model on port call records from 2020 to 2023 and, compared with the vessel-reported times, reduced the mean absolute error by 29.7%, from 4.54 to 3.19 hours, and the root mean square error by 31.9%, from 6.58 to 4.48 hours, with an R-squared of 0.8.
A second study, by Chu and colleagues (2024), predicted the turnaround time of vessels at the port of Hong Kong with XGBoost, a gradient boosting method, trained on arrival and departure records from 2022 and the first quarter of 2023. Compared with the departure times reported by the vessels, it cut the mean absolute error by 23%, from 5.1 to 3.9 hours, and the root mean square error by 24%, from 8.0 to 6.1 hours. The arrival side of the problem is the subject of
our post on vessel ETA prediction: together, predicted arrival times and predicted service times are the inputs a berth schedule needs.
What can go wrong
Learning models depend on their data. Position data from the Automatic Identification System can contain invalid messages, impossible tracks and wrong time stamps, as
our post on AIS data cleaning describes, and small or noisy datasets lead to overfitting, where a model learns the quirks of its training data and fails on new cases. A model trained on the records of one port or one period may also not transfer to another. On the optimization side, the number of possible schedules grows very fast with the number of ships and berths, and search methods can get stuck in local optima. For large instances researchers therefore use heuristics such as genetic algorithms, which have been applied to berth allocation since at least 2007, but these need careful tuning and give no guarantee of the global optimum.
A berth schedule is a chain: predictions of arrival and service times feed an optimization that also decides how fast ships should come, and each link can be improved with data. Fuel, emissions and punctuality are no longer separate topics for the terminal and the carrier, they are parts of one plan.
References
-
The berth allocation problem: Optimizing vessel arrival time
Mihalis M. Golias, Georgios K. Saharidis, Maria Boile, Sotirios Theofanis, Marianthi G. Ierapetritou
Maritime Economics & Logistics 11(4), 358-377 (2009)
-
The Berth Allocation Problem: A Formulation Reflecting Time Window Service Deadlines
Mihalis M. Golias, Maria Boile, Sotirios Theofanis
48th Annual Transportation Research Forum (2007)
-
Berth allocation considering fuel consumption and vessel emissions
Yuquan Du, Qiushuang Chen, Xiongwen Quan, Lei Long, Richard Y.K. Fung
Transportation Research Part E: Logistics and Transportation Review 47(6), 1021-1037 (2011)
-
A follow-up survey of berth allocation and quay crane scheduling problems in container terminals
Christian Bierwirth, Frank Meisel
European Journal of Operational Research 244(3), 675-689 (2015)
-
Slow steaming in container liner shipping: is there any impact on fuel surcharge practices?
Theo Notteboom, Pierre Cariou
The International Journal of Logistics Management 24(1), 73-86 (2013)
-
Predicting vessel service time: A data-driven approach
Ran Yan, Zhong Chu, Lingxiao Wu, Shuaian Wang
Advanced Engineering Informatics 62, 102718 (2024)
-
Vessel turnaround time prediction: A machine learning approach
Zhong Chu, Ran Yan, Shuaian Wang
Ocean & Coastal Management 249, 107021 (2024)
-
An optimization based genetic algorithm heuristic for the berth allocation problem
Sotirios Theofanis, Maria Boile, Mihalis Golias
2007 IEEE Congress on Evolutionary Computation, 4439-4445 (2007)