Mathematical Programming Formulations for the Berth Allocation Problems in Container Seaport Terminals

: Background: Improving the performance of marine terminals is one of the major concerns of both researchers and decision-makers in the maritime transportation sector. The problem of container storage planning and the berth allocation problem (BAP) are the two mainstays of optimizing port operations. Methods: In this work, we address these two issues, proposing two mathematical models that operate sequentially and are applicable to both static and dynamic cases. The first developed model is a mixed-integer linear problem model aimed at minimizing vessel traffic time in the port. The second model developed is a multi-objective optimization model based on goal programming (GP) to minimize both container transfer time and the number of storage areas (minimizing container dispersion). Results: The robustness of the proposed models has been proven through a benchmark with tests using data from the literature and real port data, based on the IBM ILOG CPLEX 12.5 solver. Conclusions: The two developed mathematical models allowed the both minimization of the transfer time and the number of used storage areas, whatever the number of operations handling companies (OHCs) operating in the seaport and for both static and dynamic cases. We propose, as prospects for this work, the development of a heuristic model to deal with the major instances relating to the case of large ports.


Introduction
The development of logistics chains and the internalization of companies have brought about major changes in management, as well as growth in certain sectors.The freight transport sector, with its various modes of transport, has seen the most significant growth.The mainstay is maritime transport, which accounts for 80% of the volume of goods transported [1].
Among the various types of maritime transport, container transport is a very vital component because the number of global container shipments is continuously increasing [2].For instance, seaport congestion implies a loss of time and money for all actors in the supply chain and therefore undermines the competitive position of seaports and the ecosystem of companies in seaport communities [3].Container terminals are very important to the economies of countries.This importance explains the impact of seaport performance on its economic growth.In this context, a significant number of works targeting the seaport system optimization by addressing as an example the assignment of dockworkers [4], the the seaport system optimization by addressing as an example the assignment of dockworkers [4], the allocation of handling equipment [5], quay-court planning, and the transfer and storage of containers [6] are addressed in the literature.

Berth Allocation Problem
In most container port terminals, dockside planning issues are considered the primary concerns of container terminal operators.The aim of this research work is addressing the berth allocation problem (BAP) considered by [7] as one of the important decisionmaking tasks faced by operators during operations planning.A literature review of relevant research works that describe the different approaches to solve this problem is presented.First, a presentation of the work related to the BAP is presented.Then, the focus shifts to research works related to the problem of berth allocation for container storage.After that, the main objectives and the contributions of this research work are detailed.
The berth allocation problem (BAP) concerns how to allocate berths (i.e., sections of the quayside) to ships arriving in a container port in order to minimize the sum of their waiting and cargo handling times.In the static case, ships are assumed to arrive before the berths become available; in the dynamic case, they can arrive before or afterward.
In a container terminal, the number of berths is known in advance.The role of port operators is to assign incoming ships to available berths to ensure they are served properly (loaded or unloaded).The allocation of berths is considered the most critical operation in a terminal, influencing the turnaround time of inbound vessels, as well as container flows in the port (See Figure 1).The BAP can be classified into static and dynamic categories; a static berth allocation problem (SBAP) can be modeled as a static problem if all ships are already in the harbor before the plan is established.The dynamic berth allocation problem (DBAP) refers to when the SBAP assumption is relaxed, which means that some vessels may arrive during the planned period.Several research works and approaches have been presented to address the problem of the allocation of berths at the harbor.Some research works in the literature are noted Several research works and approaches have been presented to address the problem of the allocation of berths at the harbor.Some research works in the literature are noted as follows.Nishimura et al. [8] addressed the issue of determining the assignment of a dynamic berth to vessels in the public berth system in Japanese ports according to the principle of first come, first serve (FCFS).
Guan and Cheung [9] dealt with the continuous berth allocation problem, which allows several vessels to be moored per berth, taking into account the arrival times of the vessels, in the port of Hong Kong.
Zhen and Chang [10] have dealt with the BAP on the wharf to develop an effective schedule for the allocation of vessels on the wharves, taking into account the time of arrival of the vessels and the time of operation.Zoubeir [11] developed a decision support system called Ship-Dock-Storage Area for the BAP issue for both static and dynamic vessel arrivals, which seeks to optimally plan the allocation of incoming vessels on the docks by simultaneously optimizing the time spent by vessels and the flow of containers into the port space.
Venturini et al. [12] addressed the multi-port berth allocation issue (Hong Kong, Kaohsiung, Rotterdam, Long Beach), which aims to minimize the docking time of ships at various terminals as well as the total delivery time.
Grubisic et al. [13] addressed the optimization of seaside operations in small and medium container terminals with different quay designs or different terminal layouts.
They proposed an integrated model that can be applied to medium-sized terminals with a multi-quay layout, aiming to find the shortest vessel stay at the port and providing a high-reliability service with ship operators.
Liu et al. [14] studied issues regarding the integrated planning of berth allocation and vessel sequencing while incorporating many realistic navigation considerations such as the vessel's mooring position, the limitation of a one-way navigation channel, heterogeneous shipping speeds of ships, and tidal effects at China's Jingtang Port.
Awah et al. [15] explore key port performance indicators associated with port operations with the aim of modeling the optimal engineering throughput of a port and offering valuable knowledge that helps a port optimize its bottlenecks.
Xu et al. [16] propose a novel berth scheduling problem that considers traffic limitations in port navigation channels.To optimally utilize the berth and improve the quality for customers, an MILP model is formulated under the one-way traffic rule in the navigation channel.
Golias et al. [17] present a mathematical model and a solution for the discrete berth scheduling problem.Their proposed model provides a robust schedule by minimizing the average and the range of total service times required to serve all vessels at a marine container terminal.Simulation is used to evaluate the proposed berth scheduling policy and compare it with three service policies.
Golias et al. [18] deal with the discrete and DBAPs, formulated as a multi-objective combinatorial optimization problem.A genetic algorithm-based heuristic is developed to solve the resulting problem.The heuristic provided a complete set of solutions that allow terminal operators to evaluate various berth scheduling policies.
Golias et al. [19] study the problem of discrete space and dynamic berth scheduling where vessels' arrival times are optimized to minimize port-related emissions, waiting time of the vessels, and delayed departures.The problem was formulated as a mixedinteger optimization problem, and a genetic algorithm-based heuristic was used to solve the resulting problem.
Martin-Iradi et al. [20] deal with collaboration between liner carriers and Marine container terminal operators especially in multiport case.Authors aim to optimize sailing speed between each port in order to minimize fuel consumption.The problem was resolved using branch and cut and-price algorithm and cooperative game theory methods.
Guo et al. [21] deal with a multi-port berth allocation problem under a cooperative environment.The authors precisely targeted the optimization of the grouping of neighboring ports into different groups of stable ports.Indeed, they based their solution on a mixedinteger programming model (which was solved by a column generation approach), and cooperative game theory was used to obtain stable port groups.Numerical experiments were carried out to illustrate the robustness of the proposed approach.

Container Stowage
The problem of planning container stowage is also considered among the problems of planning docks, which consists of determining the storage position of each container on the ship.In most cases, a ship goes through a number of stops at various terminals to load or unload containers.However, the choice and task of positioning each container must take into account certain criteria and limitations, such as maintaining the stability of the vessel, reducing the number of unnecessary handling movements (e.g., cases where the containers are stored above other containers and which must be unloaded and reloaded on the ship again at the port in question.Containers of different sizes should not be stacked on top of each other (heavy containers should generally be stored at the bottom of the ship and light containers stacked above), and refrigerators should be placed in specific places on the ship next to the existing power supply.Containers carrying hazardous materials require clearly defined storage conditions that differ from others.Although this container safety issue on the ship is one of the most important planning issues in container terminals, there are few studies that address this issue.
Wilson and Roach [22] dealt with the problem of strategic and tactical planning of the precision of storage blocks for containers on a single vessel within the Port of London.Kim and Park [23] suggested a storage space allocation method for outgoing containers on arrival for maximum efficiency in the loading operation to obtain an efficient loading sequence; the objective here is to minimize the travel distance of the handling equipment (e.g., dock crane, truck, straddle, yard crane).
Liu et al. [24] were interested in developing a stability adjustment module to check the overall stability of the ships in the stowage plan and to determine the location of each container's storage.They aimed to maximize the stability of the ships and minimize the execution time.The researchers used a heuristic method, which is a local search algorithm.
According to Abourraja [25], the storage area is a temporary area made up of several blocks.It is used to store containers that pass through the terminal.Most terminals aim to better manage the limited capacities of their territory.Therefore, it is imperative to make better use of resources and properly manage storage space.This problem consists of allocating locations for the storage of containers in a block at the port of Le Havre.
Ting and Wu [26] dealt with the container storage problem, and more specifically, the problem of relocating containers in the storage area.The goal of their paper is to remove containers from the container yard in the minimum number of relocations.An integrated beam search algorithm was proposed to solve this problem where it is tested on larges instances.
Tao et al. [27] focused on the problem of internal truck traffic congestion in very frequent trans-shipment container terminals, one of the problems that causes the majority of pollutant emissions in terminals.To minimize these negative externalities, the authors proposed a bi-objective optimization model addressing both the integrated truck operation planning problem and the storage allocation problem.To demonstrate the performance of the solution approach, the authors used an NSGA II-based method and extensive experiments to deal with real test instances.The tests showed the robustness of the proposed approach.

Works That Deal with Two Problems at Once
In the literature, research that deals with both the storage space allocation problem and the BAP are very rare.In 2003, Zhang et al. [28] published the first research work that attempted to solve these two problems simultaneously.They formulated the storage space allocation problem for a container terminal in Hong Kong and solved it using a rollinghorizon approach.For each planning horizon, they decomposed the problem into two levels and formulated each level as a mathematical programming model.Likewise, Safaei et al. [29] proposed a two-level approach to solve these two problems.The storage space allocation problem and the BAP are formulated as mathematical programming models in two consecutive levels.
Zoubeir, in [11], address the BAP in a container terminal by integrating the container stowage problem.In this context, the researchers propose two mathematical models.The first model deals with the static case and the second with the dynamic case.Note that the researchers used approximate methods to test large instances (randomly generated in a systematic way).
In order to reduce the complexity of the models proposed in [11], Kallel et al. [30] proposed a mathematical model which is valid for both static and dynamic cases.Note that Kallel et al. [30] focused on minimizing time in a model intended for the port of Rades.Indeed, only one handling company operates in the port of Rades.Consequently, the modelling proposed by Kallel et al. is not valid for ports with multiple OHCs.

Objective of the Study
The problems of berth allocation (ship-quay) and the transfer and storage of containers share a single objective, which is the minimization of the ship's total length of stay.Of course, it is necessary to take into account the containers' dispersion when they are assigned to the storage areas.Although the problem of planning berths is widely studied in the literature, there is a limited number of works addressing the problem of the transfer and allocation of containers in a storage area.
How can the BAP be solved in container seaport terminals in various situations?The solutions include the following: the case of both static and dynamic arrivals, the case of multiple operation handling companies (OHCs) operating at the same time in the seaport, and the case of multiple performance measures.
The present work has two main contributions as response to the research questions.The first contribution is about the number of objectives studied at the same time.The majority of the previous research deals with only one objective, which is the minimizing of the flow time.In this research, two objectives are considered at the same time, which are the minimization of the transfer time and the number of storage areas.In fact, minimizing the number of storages areas results in a reduction in container dispersion, and consequently reduces the time taken to unload shipments and the collection time for dispatch.
The second contribution is about the number of OHCs for both static and dynamic cases.In fact, previous research, such as in [11,30], focusses on the cases of seaports operating with only one OHC.The models developed take into account multiple OHCs.
The main objective of this work is to propose two models that address both static and dynamic cases, as well as the problem of allocation, transfer, and storage at the same time (ship-dock-storage area) and with multiple OHCs.The first model developed is a mixed-integer linear problem (MILP) model which minimizes the flow time of ships in the port.The second developed model is a multi-objective optimization model, which is based on goal programming (GP), and which minimizes both the container transfer time and the number of storage areas.The two developed models are implemented with the IBM ILOG CPLEX 12.5 solver.To validate the effectiveness and efficiency of the developed models, a benchmarking study is applied based on previous research applied to Tunisian seaports (Rades and Sfax) and with the consultation of experts.

Materials and Methods
In this work, we propose a methodology consisting of the following three steps (as detailed in more depth in Figure 2): • A decision support tool is proposed for quay-court planning through two mathematical models that work sequentially for the berth allocation problem and the problem of containers' transfer and storage.In this context, this work will be based on the models that appear in [30] (these models are valid only for ports that work with a single handling company).
• The proposed models are tested using IBM CPLEX 12.5 solver, performing the tests necessary for the validation process.It should be noted that the validation was carried out in two phases.In the first phase, the case of ports that operate with a single handling company (this is the particular case discussed in [30]) is addressed.Certainly, the models proposed in our work and in [30] should provide the same results.In the second phase, the models are tested with real data from the Sfax seaport, which is another seaport of Tunisia that work with multiple OHCs.• The results are validated in consultation with experts in the case that no previous results are available.
Logistics 2024, 8, x FOR PEER REVIEW 6 of 17 models that appear in [30] (these models are valid only for ports that work with a single handling company).


The proposed models are tested using IBM CPLEX 12.5 solver, performing the tests necessary for the validation process.It should be noted that the validation was carried out in two phases.In the first phase, the case of ports that operate with a single handling company (this is the particular case discussed in [30]) is addressed.Certainly, the models proposed in our work and in [30] should provide the same results.
In the second phase, the models are tested with real data from the Sfax seaport, which is another seaport of Tunisia that work with multiple OHCs.


The results are validated in consultation with experts in the case that no previous results are available.

The First Model: Minimization of the Length of Ships' Stay in Port
This section illustrates a mixed-integer linear problem (MILP) model with the objective of minimizing the flow time of ships in the port.Note that the proposed model is valid for the static and dynamic cases and valid for ports accommodating more than one operations handling company (OHC).

The First Model's Assumptions
When developing a mathematical model, the assumptions that will be incorporated into the developed models must be considered:  The planning process is either static or dynamic.


Each berth can accommodate only one vessel at a time.


Each vessel may be assigned to more than one wharf.


The processing time (loading/unloading) of a ship remains unchanged on any wharf and is defined by the OHC according to its equipment and their working methods.


Once a vessel is moored on a berth, it remains there until the end of its stay in port.


Physical constraints such as water depth and safe distances between vessels will be considered.

The First Model: Minimization of the Length of Ships' Stay in Port
This section illustrates a mixed-integer linear problem (MILP) model with the objective of minimizing the flow time of ships in the port.Note that the proposed model is valid for the static and dynamic cases and valid for ports accommodating more than one operations handling company (OHC).

The First Model's Assumptions
When developing a mathematical model, the assumptions that will be incorporated into the developed models must be considered: • The planning process is either static or dynamic.

•
Each berth can accommodate only one vessel at a time.

•
Each vessel may be assigned to more than one wharf.• The processing time (loading/unloading) of a ship remains unchanged on any wharf and is defined by the OHC according to its equipment and their working methods.

•
Once a vessel is moored on a berth, it remains there until the end of its stay in port.

•
Physical constraints such as water depth and safe distances between vessels will be considered.

The First Model's Parameters
The indices used in the model are as follows: i: Index of available berths, i (=1, . .., I) ∈ B; j: Index of entering ships, j (=1, . .., T) ∈ V; k: Index of the service order, where, in each berth, the number of the service orders is equal to the number of ships, k (= 1,. .., T) ∈ O; l: Index relating to the stevedoring and handling company.
The sets and parameters used in the model are as follows: B: Set of available berths; V: Set of entering ships; O: Set of service orders; P jl : Processing time 'j' for the stevedoring and handling company 'l'; r j : Ready time, which corresponds to the date of availability for the treatment of ship j; S i : 'Setup/availability', which corresponds to the date of availability of berth i with S i < 0; W i : Depth of the water in berth i; E j : Draft of the ship j's water; Q i : Length of berth i; L j : Length of ship j; F jmax : Maximum flow time, where the flow time of each ship shall not exceed this upper limit; M: A very large value; Z ijkl ∈ {0,1}.

The First Model's Decision Variables
F ijk : The flow time of the ship 'j' (flow time or the time needed to complete a job = flow duration) assigned to berth 'i' in order 'k'.The flow time represents the time spent by the vessel 'j' being processed on the dock 'i' according to the order 'k' and according to Equation (1): X ijkl : Equal to 1 if the ship 'j' is assigned to the berth 'i' in order 'k' and 0 otherwise.C ijk : 'completion time', which corresponds to the end date of processing of ship 'j' on berth 'i' in the order 'k' according to Equation (2): 2.1.4.The First Model's Formulation The objective function (3) aims to minimize the processing and waiting times for all ships in the port, which leads to minimizing the ships stay time in the port: Subjecting each ship to Constraint (4) ensures that each ship 'j' will be served by a berth 'i' in a given service order 'k' and processed by a handling company 'l': Constraint (5) ensures that each berth 'i' can accommodate only one ship 'i' and can only deal with the handling company 'l': Constraint (6) gives the value of the flow time of ship j on berth i according to the order k, where C i(j − 1)k is greater than r j , which means that the end date of processing of ship j exceeds the availability date of ship j: Constraint (7) gives the value of the flow time of ship 'j' at berth 'i' according to the order 'k', when r j is greater than C i(j−1)k , which means that the start date of the processing of ship 'j' exceeds the completion time of ship 'j' ordered in position (j − 1): Constraint (8) gives the value of the flow time: Constraint ( 9) imposes an upper bound on the flow time of ship 'j': Constraint (10) ensures compatibility between the depth of the water of the berth 'i' and the draft of ship 'j': Constraint (11) ensures compatibility between the lengths of the berth 'i' and that of ship 'j': Constraint (12) gives the initial value of the completion time C it0 , which is equal to S i : Constraints ( 13)-( 16) ensure that a single handling and stevedoring company will handle the treatment of ship 'j': Equations ( 17) and ( 18) define the types of decision variables:

The Second Model: Minimization of Container Transfer Time and the Number of Storage Areas
This section presents a mathematical model based on the weighted goal programming technique.This model aims to optimize two objectives with different units of measurement:

•
Container transfer time: The model aims to minimize the total transfer time.

•
Number of storage areas occupied by each handling company: In order to avoid the problem of overlapping operations, the proposed model also seeks to reserve areas for each handling company.In this regard, the threshold judged to be optimal is the one whose average number of storage areas is equivalent to dividing the total number of zones by the total number of handling companies.
Note that the two objectives do not have the same degree of importance (which prompted us to use the weighted programming goal).In this context, [31] mentions that the analytic hierarchy process, or 'AHP' (invented by Saaty, 1990), aims to define the levels of importance based on two steps: First, the decider makes a comparison between the pair of objectives.The evaluation can be conducted on a scale from 1 to 9.An estimation with the value of 9 indicates that a constraint is significantly more important than others.In the same way, the values 7, 5, and 3 indicate, respectively, that a constraint is very significantly more important, significantly more important, and more important than the others.Intermediate judgments receive values 8, 6, 4, and 2, respectively.Table 1 indicates the importance of each objective.• The decision variable X ijkl of the first generalized model for the allocation of berths is considered as an input in the second model.• The distance between the berth and the storage area is given by the port authorities.

•
In this case, only import operations are considered (i.e., container unloading operations).• The traveling time of a container is presented by the time required to transfer a single container from the berth to the collection area.

The Second Model's Parameters
The indices used in the model are as follows: i: Index relating to the berth, i (=1,. .., I) ∈ B; j: Index relating to the incoming ship, j (=1,. .., T) ∈ V; z: Index relating to the collection area mentioned in each storage area, z (= 1,. ..., A) ∈ D.
The sets and parameters used in the model: B: Set of available berths; V: Set of incoming ships; D: Set of pickup areas listed in each storage area; d iz : Distance between berth 'i' and storage area 'z'; C j : The number of containers of ship 'j' coming from different terminals (the import case); X* ijl : Equal to 1 if ship 'j' is assigned to berth 'i', and 0 otherwise, and processed by a company 'l' (optimal solution of the mathematical model G); Q z : Total capacity of each storage area 'z'; M: A very large value; R zl : Equal 1 if the company 'l' uses the zone 'z' to store the containers and 0 otherwise; OPT_ZN: Number of optimal areas.

The Second Model's Decision Variables
C iz : The number of containers associated with vessel 'j' that will be unloaded in the storage area 'z'; Y jzl : Equal to 1 if the containers associated with ship 'j' will be unloaded in the storage area 'z', and 0 otherwise; AS zl : Equal to 1 if the company has used the zone 'z' for storage and 0 otherwise; ZA zl , ZB zl , Yj zl ∈ {0,1}; DPA, DNBL, DPBL, C jzl ∈ R.

The Second Model Formulation
The objective function (19) aims to minimize both the transfer time of the containers and the number of occupied storage areas: Constraints ( 20) and ( 21) ensure that all containers C j are allocated in a single storage zone 'z' and processed by a single handling company, when Y jz is equal to 1: Constraint (22) ensures that each vessel 'j' handled by a single handling company 'l' is assigned to a single storage area 'z' or to two consecutive storage areas 'z': Constraint (23) ensures that all containers unloaded from all ships 'j' that have been handled by a single handling company 'l' are assigned to a single storage area 'z' or two areas (z − 1) and 'z' must not exceed the storage capacity of that zone (for any even number of z): Constraints ( 24) and ( 25) verify whether the storage area 'z' is used by the company 'l' for container storage: Constraints ( 26) and ( 27) determine whether the area is used as the storage area of the ship container 'j' for the handling company 'l': Constraint (28) measures the positive deviation of the first objective (note that the threshold considered optimal is equal to 0): Constraint ( 29) measures the negative and positive deviations related to the second objective compared to the optimal threshold considered 'OPT_ZN': Equations ( 30) and ( 31) define the types of variables:

Port Experimental Data for the First Model
To ensure the robustness of the generalized model, a two-stage test is proposed; the first stage aims to ensure that the generalization has no effects on the robustness of the base model, whereas the second stage aims to compare the results of the generalized model with the planning proposed by the decision maker (in the case of several operations handling companies).

Verification Test of the First Model
To ensure the robustness of the proposed model, the same tests as those performed by Kallel et al. [30] are performed.The two models should provide the same solution.In this regard, three tests are performed.A benchmarking of the results obtained by the base model proposed by [30], which targets the minimization of the ships length of stay in the port, along with the generalized model is conducted.Tables S1-S3 show the results of tests 1, 2, and 3, respectively.For the three plans, the same results of the objective function and the decision variables can be observed with a slightly longer resolution time compared to the model proposed by Kallel et al. [30].

Validation Test of the First Model
An additional test is performed with data obtained from the Sfax seaport (Tunisia).Tables 2 and 3 show the data used for this test.The arrival dates of the ship in the port are between 1 January 21 and 5 January 21.Note that the dump containers in the examples are 20 feet by 40 feet and are either empty (noted as 20'V or 40'V in the tables according to the type of container) or contain goods (noted as 20'P or 40'P in the tables according to the type of container).
It should be noted that the draught of the berth (Wi) is 10.5 m (whatever i).Assignment results are obtained in 0.084 s, and the objective function is equal to 354 h.This test shows the efficiency of the generalization since the results obtained using the generalized model are identical to the plan created by the expert.In this study, the experts from the merchant navy and the ports officers are the two supportive experts.Table 4 detail the assignment results obtained the first developed model.Table 5 presents the results according to the expert.Note that both results are the same, which verify effectiveness of the first developed model.In this part, the results of our modeling are used to allocate and assign ships to the berths of the port of Rades (Tunisia).To ensure the robustness of the second model, three tests are performed in the following periods: from 1 December 2016 to 10 December 2016, from 11 December 2016 to 20 December 2016, and from 21 December 2016 to 31 December 2016.A comparison of the assignments is made between those proposed by Kallel et al. [30] and those obtained from the developed model.The comparison results of each of the three periods are shown in Tables S4, S5 and S6, respectively.
The results of performed tests showed the same results of the decision variables except, for a lag in response time and in the objective function compared to the model of Kallel et al. [30].For example, the result of the third test concerning the objective function was equal to 14,637 compared to 19,516, and the response time was that of 0.871 s compared to 0.043 s.

Validation Test of the Second Model
The second test is based on data from another port, which is the Sfax seaport (Tunisia).Table 6 presents the capacity of each storage area Q z in the EVP and the distance between each berth and storage area in the Sfax port from 1 January 2021 to 1 May 2021.For the port of Sfax (Tunisia), it should be noted that in the scheduling process, the storage areas are distributed between the two OHCs; the first holding company occupies zone 1 (reserved for import operations) and zone 2 (reserved for export operations), whereas the second operations company occupies zone 3 (reserved for import operations) and zone 4 (reserved for export operations).Table 7 presents the transfer time from the berth and the storage areas.The data are obtained from each OHC according to their assigned zones.Table 8 contains the final results of the number of unloaded containers in each area obtained using the second developed model.The results of assigning containers to storage areas are obtained in 7.89 s, and the objective function is equal to 5718.18 h.Table 9 presents the results according to the expert.For example, containers from ship 3 are assigned to storage area 1 and containers from ship 4 are assigned to storage area 3. The final results are the same, validating the second developed model.In summary, the two mathematical models were verified and then validated.Verification is based on benchmarking results, which are used to compare the previous results with those obtained in the current study.The details of this comparative study are presented in Supplementary Tables S2-S6.Validation is based on comparative results between the experts' views with those obtained using the developed models.Tables 4 and 5 present the results for the first model, and Tables 8 and 9 present the results for the second model.All the final results are the same, validating the two developed models.
Beyond the exposed tests and in order to ensure the robustness of the proposed models, other tests were carried out based on real data as well as on other data generated randomly and systematically.Table 10 presents a benchmark of the two main indicators for evaluating an assignment, namely the total dwell time and the maximum number of used zones, to ensure the unloading of ships.These two indicators are considered by experts as the most important.Table 11 shows data that illustrate the size of these instances (period of assignment, number of ships, berths, and containers to be unloaded).This table also illustrates whether the CPLEX solver has identified the optimal solution (in this case, the resolution time is shown in the table; note that during these different tests, the maximum resolution time is two hours).Based on Table 10, two main results can be observed: The robustness of the proposed mathematical models have been shown.In the first four tests, the assignments using the mathematical models are similar to the assignments proposed by the experts.In the other tests (larger instances than the first four tests), the two indicators show that the assignments using the mathematical models are more efficient than the assignments proposed by the experts (despite the optimality not being approved in the majority of the tests).

Discussion
To validate the proposed mathematical formulations relating to the issues addressed, these programs were solved using the CPLEX solver.Indeed, the tests were performed in two stages: In the first stage, the proposed models were proven to be valid for the port of Radès (Tunisia).In this sense, benchmarking with the results obtained using the model proposed by Kallel et al. [30] shows the effectiveness of the proposed model in a specific case with a single operation handling company (OHC).In the second stage, the models were tested in the case of several OHCs in the port and using data generated randomly and systematically.As indicated in Table 10, the benchmark compared to the results of the experts shows that the model obtained similar results; consequently, this model demonstrated its efficiency.To highlight the contribution of this work, it is illustrated and compared to two previous studies that addressed a similar issue as mentioned in Table 11.The comparative results with the previous research are applied according to the following criteria: field of study, cases, objective function, container allocation strategy used in storage areas, and experimental data.

Conclusions
This work deals with two problems.The first is related to the minimization of the length of stay of ships, and the second aims to optimize the time taken to transfer containers and the number of storage areas used.In this context, two mathematical models are proposed: a mixed-integer linear problem (MILP) model for the first problem and a model based on the weighted goal programming technique for the second.
The present work has two main contributions.The first contribution is about the number of objectives studied at the same time.Most of the previous research dealt with only one objective, which is minimizing the flow time.In this research, two objectives are considered at same time, which are the minimization of the transfer time and minimizing the number of storage areas used.In fact, minimizing the number of storage areas provides a reduction in container dispersion and consequently reduces the unloading shipments time and the collection time for dispatch.The second contribution is about the number of operations handling companies (OHCs) for both static and dynamic cases.Indeed, previous research has focused on the cases of seaports that operate with only one OHC.The models developed take into account multiple OHCs.The proposed models have shown their robustness and efficiency through benchmarking with the tests by data from literature and using real data from Tunisian ports.This research may provide some reasonable insight into the current container stowage problem and the berth allocation problem simultaneously.Some future research perspectives should be addressed:

•
In this study, some instances that are used during January 2021 (a period characterized by a disruption in shipping due to the COVID-19 pandemic) do not seem very meaningful.Extending the current research in other periods is the first of our interesting perspective.

•
In this study, we selected small seaports to test the mathematical models on real instances.The use of approximate methods such as hyper-heuristics that have shown good performance as underlined [1] and the integration of environmental aspects seems important to improve results.In fact, environmental aspects are one of the major concerns of decision makers in the transport sector and can even affect the choice of ship capacity, as indicated by [32,33].

Supplementary Materials:
The following are available online at https://www.mdpi.com/article/10.3390/logistics8020050/s1, Table S1: Verification results of the first planning using the first proposed model, Table S2: Verification results of the second planning using the first proposed model, Table S3: Verification results of the third planning from 20 December 2016 to 31 December 2016 using the first proposed model, Table S4: Verification results of the first planning from 1 December 2016 to 10 December 2016 using the second proposed model, Table S5: Verification

Figure 1 .
Figure 1.Berth allocation and scheduling of container storage.

Figure 1 .
Figure 1.Berth allocation and scheduling of container storage.

Figure 2 .
Figure 2. Flowchart of the proposed methodology.

Figure 2 .
Figure 2. Flowchart of the proposed methodology.

Table 1 .
Pairwise comparison and relative importance values of each objective.

Table 3 .
Characteristics of inbound container ships (period of 5 days).

Table 4 .
Assignment results obtained using the first developed model.

Table 5 .
Expert assignment for validation of the first developed model.
3.2.Experimental Port Data for the Second Model 3.2.1.Verification Test of the Second Model

Table 6 .
Storage capacity of storage area in the Sfax seaport.

Table 7 .
The transfer time (minutes) from the berth to the storage areas in the port of Sfax.

Table 8 .
The number of unloaded containers in each zone according to the second proposed model.

Table 9 .
The number of unloaded containers in each area according to the experts.

Table 10 .
Benchmark of results provided by experts and the proposed model.