<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE article PUBLIC "-//NLM//DTD Journal Publishing DTD v2.3 20070202//EN" "journalpublishing.dtd">
<article article-type="research-article" dtd-version="2.3" xml:lang="EN" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">
<front>
<journal-meta>
<journal-id journal-id-type="publisher-id">Front. Ind. Eng.</journal-id>
<journal-title>Frontiers in Industrial Engineering</journal-title>
<abbrev-journal-title abbrev-type="pubmed">Front. Ind. Eng.</abbrev-journal-title>
<issn pub-type="epub">2813-6047</issn>
<publisher>
<publisher-name>Frontiers Media S.A.</publisher-name>
</publisher>
</journal-meta>
<article-meta>
<article-id pub-id-type="publisher-id">1523203</article-id>
<article-id pub-id-type="doi">10.3389/fieng.2025.1523203</article-id>
<article-categories>
<subj-group subj-group-type="heading">
<subject>Industrial Engineering</subject>
<subj-group>
<subject>Original Research</subject>
</subj-group>
</subj-group>
</article-categories>
<title-group>
<article-title>Hybrid genetic algorithm and Q-learning-based solution for the time-variant berth and quay crane allocation problem</article-title>
<alt-title alt-title-type="left-running-head">Liang et al.</alt-title>
<alt-title alt-title-type="right-running-head">
<ext-link ext-link-type="uri" xlink:href="https://doi.org/10.3389/fieng.2025.1523203">10.3389/fieng.2025.1523203</ext-link>
</alt-title>
</title-group>
<contrib-group>
<contrib contrib-type="author">
<name>
<surname>Liang</surname>
<given-names>Chengji</given-names>
</name>
<uri xlink:href="https://loop.frontiersin.org/people/2748168/overview"/>
<role content-type="https://credit.niso.org/contributor-roles/conceptualization/"/>
<role content-type="https://credit.niso.org/contributor-roles/formal-analysis/"/>
<role content-type="https://credit.niso.org/contributor-roles/methodology/"/>
<role content-type="https://credit.niso.org/contributor-roles/writing-original-draft/"/>
</contrib>
<contrib contrib-type="author" corresp="yes">
<name>
<surname>Tang</surname>
<given-names>Dong</given-names>
</name>
<xref ref-type="corresp" rid="c001">&#x2a;</xref>
<uri xlink:href="https://loop.frontiersin.org/people/2974182/overview"/>
<role content-type="https://credit.niso.org/contributor-roles/investigation/"/>
<role content-type="https://credit.niso.org/contributor-roles/data-curation/"/>
<role content-type="https://credit.niso.org/contributor-roles/writing-original-draft/"/>
</contrib>
<contrib contrib-type="author">
<name>
<surname>Zhao</surname>
<given-names>Rui</given-names>
</name>
<uri xlink:href="https://loop.frontiersin.org/people/2974832/overview"/>
<role content-type="https://credit.niso.org/contributor-roles/investigation/"/>
<role content-type="https://credit.niso.org/contributor-roles/methodology/"/>
<role content-type="https://credit.niso.org/contributor-roles/Writing - review &#x26; editing/"/>
</contrib>
<contrib contrib-type="author">
<name>
<surname>Wang</surname>
<given-names>Yu</given-names>
</name>
<role content-type="https://credit.niso.org/contributor-roles/investigation/"/>
<role content-type="https://credit.niso.org/contributor-roles/methodology/"/>
<role content-type="https://credit.niso.org/contributor-roles/Writing - review &#x26; editing/"/>
</contrib>
</contrib-group>
<aff>
<institution>Institute of Logistics Science and Engineering of Shanghai Maritime University</institution>, <addr-line>Pudong</addr-line>, <country>China</country>
</aff>
<author-notes>
<fn fn-type="edited-by">
<p>
<bold>Edited by:</bold> <ext-link ext-link-type="uri" xlink:href="https://loop.frontiersin.org/people/2104850/overview">Mitsuo Gen</ext-link>, Fuzzy Logic Systems Institute, Japan</p>
</fn>
<fn fn-type="edited-by">
<p>
<bold>Reviewed by:</bold> <ext-link ext-link-type="uri" xlink:href="https://loop.frontiersin.org/people/2394949/overview">Wenqiang Zhang</ext-link>, Henan University of Technology, China</p>
<p>
<ext-link ext-link-type="uri" xlink:href="https://loop.frontiersin.org/people/2734537/overview">Jie Gao</ext-link>, Xi&#x2019;an Jiaotong University, China</p>
<p>
<ext-link ext-link-type="uri" xlink:href="https://loop.frontiersin.org/people/2894248/overview">Kaphwan Kim</ext-link>, Pusan National University, Republic of Korea</p>
</fn>
<corresp id="c001">&#x2a;Correspondence: Dong Tang, <email>tangdong0112@stu.shmtu.edu.cn</email>
</corresp>
</author-notes>
<pub-date pub-type="epub">
<day>05</day>
<month>03</month>
<year>2025</year>
</pub-date>
<pub-date pub-type="collection">
<year>2025</year>
</pub-date>
<volume>3</volume>
<elocation-id>1523203</elocation-id>
<history>
<date date-type="received">
<day>05</day>
<month>11</month>
<year>2024</year>
</date>
<date date-type="accepted">
<day>06</day>
<month>01</month>
<year>2025</year>
</date>
</history>
<permissions>
<copyright-statement>Copyright &#xa9; 2025 Liang, Tang, Zhao and Wang.</copyright-statement>
<copyright-year>2025</copyright-year>
<copyright-holder>Liang, Tang, Zhao and Wang</copyright-holder>
<license xlink:href="http://creativecommons.org/licenses/by/4.0/">
<p>This is an open-access article distributed under the terms of the Creative Commons Attribution License (CC BY). The use, distribution or reproduction in other forums is permitted, provided the original author(s) and the copyright owner(s) are credited and that the original publication in this journal is cited, in accordance with accepted academic practice. No use, distribution or reproduction is permitted which does not comply with these terms.</p>
</license>
</permissions>
<abstract>
<sec>
<title>Introduction</title>
<p>This study addresses the joint scheduling optimization of continuous berths and quay cranes by proposing a time-variant quay crane allocation method.</p>
</sec>
<sec>
<title>Methods</title>
<p>A coordinated optimization model is constructed that considers the temporal dimension of quay crane scheduling and equipment collision factors to reduce overall port operational costs. A hybrid intelligent algorithm integrating Q-learning is innovatively designed, using a genetic algorithm as the main framework while embedding a quay crane allocation module and dynamically selecting genetic operators through Q-learning to achieve adaptive optimization of the evolutionary mechanism.</p>
</sec>
<sec>
<title>Results</title>
<p>The module with Q-learning optimization is compared to the module without Q-learning optimization, demonstrating that the Q-learning module can accelerate the convergence of the algorithm and has a better ability to find the optimal solution in large-scale cases, proving the effectiveness of the module.</p>
</sec>
<sec>
<title>Discussion</title>
<p>The results show that the proposed algorithm and CPLEX perform similarly in small-scale cases, while the solution speed and capability are better than the genetic algorithm in large-scale problems and superior to the CPLEX algorithm with time constraints in some cases, proving the effectiveness and superiority of the proposed algorithm.</p>
</sec>
</abstract>
<kwd-group>
<kwd>continuous berth</kwd>
<kwd>integrated berth and quay crane allocation</kwd>
<kwd>time-variant quay crane allocation</kwd>
<kwd>Q-learning</kwd>
<kwd>genetic algorithm</kwd>
</kwd-group>
<custom-meta-wrap>
<custom-meta>
<meta-name>section-at-acceptance</meta-name>
<meta-value>Industrial Informatics</meta-value>
</custom-meta>
</custom-meta-wrap>
</article-meta>
</front>
<body>
<sec id="s1">
<title>1 Introduction</title>
<p>Maritime transportation accounts for 90% of global trade (<xref ref-type="bibr" rid="B9">Liang et al., 2011</xref>). As the key link between maritime trade and other modes of transportation, the operational efficiency of ports directly affects the speed and cost of trade flows (<xref ref-type="bibr" rid="B10">Liu, 2020</xref>). Berths and quay cranes are the main factors in port operation and management that enhance the core competitiveness of container ports.</p>
<p>In planning berthing schedules, terminal managers must solve the problem of allocating berths and quay cranes. The berth allocation problem (BAP) assigns ships to specific areas along the terminal, aiming to minimize both total service time and waiting time. This is essential for reducing vessel turnaround and increasing terminal throughput. After berths are allocated, the quay crane allocation problem (QCAP) follows, determining the number of quay cranes assigned to each ship, their location, and their working time. The goal of QCAP is to minimize the time needed to unload and load containers while considering crane operational limits.</p>
<p>In the actual operation process, the berth problem and the quay crane allocation problem have a high correlation (<xref ref-type="bibr" rid="B21">Zheng et al., 2020</xref>). On the one hand, the berth problem determines the berthing position and berthing time of a ship, which directly affect the number of quay cranes allocated and the working time of quay cranes. On the other hand, the departure time of the ship depends on the number of allocated quay cranes and the working efficiency (<xref ref-type="bibr" rid="B11">Lu et al., 2011</xref>). Therefore, the simultaneous planning of berth allocation and quay crane allocation can improve the operational efficiency of the terminal and the utilization rate of berths. The quay crane allocation problem can be categorized into the static quay crane allocation problem and the time-variant quay crane allocation problem by distinguishing whether the quay cranes are moving during the unloading and loading process of the ship (<xref ref-type="bibr" rid="B15">Ng and Mak, 2006</xref>). Static quay crane assignment means that the quay cranes assigned to the same ship start working at the same time, and even if the quay cranes complete their tasks in advance, they must wait for the other quay cranes to complete their work before they can be released together. Time-variant quay crane assignment means that a quay crane can be moved to service another ship before the designated ship completes all unloading and loading tasks. Compared with the static allocation problem, the time-variant allocation can better utilize the resources of the quay crane and improve the utilization rate of the terminal resources.</p>
<p>This study addresses the joint problem of berth allocation and time-variant quay crane allocation, aiming to minimize total port costs, which include vessel costs, crane movement costs, and service costs. Traditional metaheuristic algorithms often struggle with slow convergence and poor optimization, as they fail to adapt solution generation based on the current state. To resolve this, a Q-learning-based genetic algorithm is proposed. Q-learning is used to evaluate the current population state and guide the generation of new solutions, improving optimization performance. Specifically, a global search algorithm is proposed to solve the time-variant quay crane allocation problem by considering both quay crane allocation and berth allocation to improve the utilization of port resources. We store the quay crane allocation as a code in the chromosome, which is taken into consideration at the berth stage, and use the genetic algorithm to perform a global search and the quay crane allocation algorithm to perform the quay crane allocation. In order to improve the search ability of the algorithm, the Q-learning algorithm is introduced to select the appropriate genetic operation from ten genetic operators according to the current state of the population, and the feedback obtained from the execution results is passed into the Q-learning algorithm as a reward to train it and improve the search ability of the solution. It effectively overcomes the problem of high randomness and the tendency to fall into local optimization that plagues traditional genetic algorithms. The scheme in this article can achieve high utilization of berth and quay crane resources and also provide strong technical support for port operation optimization.</p>
<p>The remainder of this article is organized as follows. <xref ref-type="sec" rid="s2">Section 2</xref> is the literature review. <xref ref-type="sec" rid="s3">Section 3</xref> provides a detailed description of the research problem and model. <xref ref-type="sec" rid="s4">Section 4</xref> presents the algorithms used in this article. <xref ref-type="sec" rid="s5">Section 5</xref> discusses the experimental results. <xref ref-type="sec" rid="s6">Section 6</xref> offers conclusions and future directions.</p>
</sec>
<sec id="s2">
<title>2 Literature review</title>
<p>In this section, we summarize the current state of research on the joint allocation of berths and quay cranes and the methods for their solution.</p>
<p>
<xref ref-type="bibr" rid="B16">Park and Kim (2003)</xref> first proposed the problem of joint allocation of berths and quay cranes. They constructed an integer programming model and proposed a two-stage approach to solve the problem: the first stage determines the berth location, berthing time, and the number of required quay cranes for a ship; the second stage assigns specific quay cranes to the ship to provide services. <xref ref-type="bibr" rid="B14">Meisel and Bierwirth (2009)</xref> discussed the problem of continuous berthing and quay crane allocation. Based on this, they discussed the problem of reduced efficiency of individual quay cranes due to mutual influence on each other during the joint operation of multiple quay cranes. They used a mixed integer linear programming (MILP) method and two metaheuristic algorithms for the solution. The above scholars consider the berth problem and the quay crane allocation problem in two steps; that is, only the number of quay cranes required by the ship is decided when the berth is allocated, and the allocation of specific quay cranes is considered after the ship enters the berth. <xref ref-type="bibr" rid="B19">T&#xfc;rko&#x11f;ullar&#x131; et al. (2014)</xref> considered the quay cranes along with the berth allocation, and the quay crane resources were considered during the berth planning. They developed a cutting plane algorithm to solve the problem and achieved a joint berth and quay crane allocation by iteratively solving the berth allocation and quay crane assignment (number) problems (BACAP) with additional constraints added. <xref ref-type="bibr" rid="B4">Correcher et al. (2019)</xref> built on this foundation by proposing a new quay crane allocation model and solving the problem using a branch-and-bound approach. Most current studies focus on the static quay crane allocation problem, and there are few studies on the time-variant quay crane allocation problem. <xref ref-type="bibr" rid="B2">Chang et al. (2010)</xref> proposed a rolling time-domain strategy considering the working time of variable quay cranes and constructed a feasible solution heuristic algorithm and a parallel genetic algorithm to solve the time-variant quay crane allocation problem. <xref ref-type="bibr" rid="B8">Krimi et al. (2020)</xref> proposed a mathematical model for continuous berth and time-variant quay crane allocation considering realistic constraints. They evaluated the feasibility of the model using CPLEX. However, considering the issue of solution efficiency, they designed heuristics for a general variable neighborhood search to address the problem. The results indicate that the designed algorithm meets the need for providing high-quality solutions in a short period of time. <xref ref-type="bibr" rid="B13">Malekahmadi et al. (2020)</xref> applied a particle swarm algorithm to solve the time-variant quay crane allocation problem by considering tidal factors for comparison.</p>
<p>Most scholars currently use metaheuristic algorithms to solve the problem of joint allocation of berths and quay cranes. For the static quay crane allocation problem, <xref ref-type="bibr" rid="B6">Ji et al. (2022)</xref> solved the static joint berth and quay crane allocation problem by means of a rolling horizon program and the ALNS algorithm embedded in a time-variant consideration of unplanned vessel entries. <xref ref-type="bibr" rid="B3">Correcher and Alvarez-Valdes (2017)</xref> proposed a metaheuristic approach to solve the static BACASP problem by means of a biased stochastic key genetic algorithm with simulated features and multiple local search processes.</p>
<p>There are two main solution methods for the time-variant quay crane allocation problem in existing studies: 1) Calling the mixed integer programming (MIP) model for rolling solution within a certain time window. 2) A step-by-step solution using the MIP method to solve the problem within the time window. For example, <xref ref-type="bibr" rid="B1">Agra and Oliveira (2018)</xref> proposed an integer linear programming model and a rolling time window solution method for the time-variant quay cranes and berth joint scheduling problem, which is solved by using the MIP model within the time window. <xref ref-type="bibr" rid="B7">Karam and Eltawil (2016)</xref> decomposed the time-variant quay crane allocation problem into the berth allocation problem and the quay crane allocation problem, which are solved separately and integrated through the ship&#x2019;s demand for the number of quay cranes in a feedback loop. <xref ref-type="bibr" rid="B18">Thanos et al. (2021)</xref> divided the time-variant quay crane solution into three steps: first, determining the berthing position of the ship, then arranging the quay cranes within the range to serve the ship according to the berthing position of the ship, and finally deciding the time interval that the quay cranes serve the ship.</p>
<p>Through the above, it is not difficult to observe that there is no suitable joint allocation method to solve the global search solution in existing research. Instead, a step-by-step solution is used to address the problem, that is, determining the location of the quay cranes and then determining which quay cranes will provide the service.</p>
</sec>
<sec id="s3">
<title>3 Problem description and modeling</title>
<sec id="s3-1">
<title>3.1 Problem description and assumption</title>
<p>Before a ship berths at the destination port, it needs to report the ship type, expected arrival time, amount of cargo to be loaded and unloaded, and expected departure time. Based on this information, the port assigns berths and quay cranes to ships to minimize the total port cost. The berth-quay crane allocation process can be mapped to a two-dimensional space-time diagram. As shown in <xref ref-type="fig" rid="F1">Figure 1</xref>, the time-variant quay crane allocation allows the quay crane to leave to serve other vessels at any time during the execution of loading and unloading activities but not to cross other quay cranes while working. The solid line in the figure indicates a feasible allocation of quay cranes, and the dashed line indicates an infeasible allocation of quay cranes. The core of time-variant quay crane assignment is its flexibility, which allows the quay cranes to switch service between different vessels while ensuring safety and efficiency. For example, the No. 1 quay crane can provide service for the No. 4 vessel when the No. 3 vessel has not yet left the harbor; the No. 2 quay crane can connect to the unloading and loading operation of the No. 2 vessel after the completing its tasks at the No. 5 vessel. Such a time-variant scheduling program enables more flexible scheduling of quay crane resources and improves the loading and unloading efficiency of the terminal.</p>
<fig id="F1" position="float">
<label>FIGURE 1</label>
<caption>
<p>Illustrative diagram of time-variant quay crane allocation.</p>
</caption>
<graphic xlink:href="fieng-03-1523203-g001.tif"/>
</fig>
<p>To achieve time-variant scheduling of quay cranes, we must determine which quay cranes serve each ship in each time period. We construct an integer programming model with the objective of minimizing the total cost of ship delay cost, quay crane service cost, and quay crane movement cost by considering the quay crane working range and constraints on quay crane crossing. In the model, we take the ship berthing time, berthing position, and the serial number of the ship served by each time period of the quay crane as decision variables. In order to better study this problem, the following assumptions are made in the next discussion: 1) Ship berthing is not limited by tide, water depth, mechanical failure, etc<italic>.</italic>, 2) Ship unloading and loading services are continuous and cannot be stopped in the middle, and each ship has a range of the number of quay cranes that can be allocated; 3) Quay cranes cannot cross each other; 4) The movement time of the quay cranes is negligible.</p>
</sec>
<sec id="s3-2">
<title>3.2 Mathematical formulation</title>
<p>For better understanding, we provide an explanation of the notation used in the model in <xref ref-type="table" rid="T1">Table 1</xref>.</p>
<table-wrap id="T1" position="float">
<label>TABLE 1</label>
<caption>
<p>Sets, parameters, and decision variables of the proposed problem.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th align="left">Set</th>
<th align="left">Connotation</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="left">
<inline-formula id="inf1">
<mml:math id="m1">
<mml:mrow>
<mml:mi>S</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Set of ships arriving during the planning period. <inline-formula id="inf2">
<mml:math id="m2">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mrow>
<mml:mfenced open="{" close="}" separators="&#x7c;">
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo>.</mml:mo>
<mml:mo>.</mml:mo>
<mml:mo>.</mml:mo>
<mml:mi>s</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, indexed by <inline-formula id="inf3">
<mml:math id="m3">
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf4">
<mml:math id="m4">
<mml:mrow>
<mml:mi>T</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Set of planning periods. <inline-formula id="inf5">
<mml:math id="m5">
<mml:mrow>
<mml:mi>T</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mrow>
<mml:mfenced open="{" close="}" separators="&#x7c;">
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo>.</mml:mo>
<mml:mo>.</mml:mo>
<mml:mo>.</mml:mo>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf6">
<mml:math id="m6">
<mml:mrow>
<mml:mi>Q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Set of quay cranes in front of the terminal. <inline-formula id="inf7">
<mml:math id="m7">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mrow>
<mml:mfenced open="{" close="}" separators="&#x7c;">
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo>.</mml:mo>
<mml:mo>.</mml:mo>
<mml:mo>.</mml:mo>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
</tbody>
</table>
<table>
<thead valign="top">
<tr>
<th align="left">Parameter</th>
<th align="left">Connotation</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="left">
<inline-formula id="inf8">
<mml:math id="m8">
<mml:mrow>
<mml:mi>C</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Total cost of the berth allocation plan</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf9">
<mml:math id="m9">
<mml:mrow>
<mml:msubsup>
<mml:mi>c</mml:mi>
<mml:mi>t</mml:mi>
<mml:mrow>
<mml:mi>s</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mi>v</mml:mi>
<mml:mi>i</mml:mi>
<mml:mi>c</mml:mi>
<mml:mi>e</mml:mi>
</mml:mrow>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Average cost of service per unit of time for each quay crane</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf10">
<mml:math id="m10">
<mml:mrow>
<mml:msubsup>
<mml:mi>c</mml:mi>
<mml:mi>i</mml:mi>
<mml:mrow>
<mml:mi>d</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>l</mml:mi>
<mml:mi>a</mml:mi>
<mml:mi>y</mml:mi>
</mml:mrow>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Average cost of compensation per unit of time for ship delays</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf11">
<mml:math id="m11">
<mml:mrow>
<mml:msup>
<mml:mi>c</mml:mi>
<mml:mrow>
<mml:mi>m</mml:mi>
<mml:mi>o</mml:mi>
<mml:mi>v</mml:mi>
<mml:mi>e</mml:mi>
</mml:mrow>
</mml:msup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">The average cost of moving a quay crane</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf12">
<mml:math id="m12">
<mml:mrow>
<mml:msub>
<mml:mi>e</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Time when ship <inline-formula id="inf13">
<mml:math id="m13">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> finishes unloading and loading cargo</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf14">
<mml:math id="m14">
<mml:mrow>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Expected departure time of ship <inline-formula id="inf15">
<mml:math id="m15">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf16">
<mml:math id="m16">
<mml:mrow>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Expected arrival time of ship <inline-formula id="inf17">
<mml:math id="m17">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf18">
<mml:math id="m18">
<mml:mrow>
<mml:msub>
<mml:mi>f</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Time required for ship <inline-formula id="inf19">
<mml:math id="m19">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> to load and unload cargo</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf20">
<mml:math id="m20">
<mml:mrow>
<mml:msub>
<mml:mi>l</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Length of ship <inline-formula id="inf21">
<mml:math id="m21">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf22">
<mml:math id="m22">
<mml:mrow>
<mml:msup>
<mml:mi>T</mml:mi>
<mml:mi>max</mml:mi>
</mml:msup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">End of the planning period</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf23">
<mml:math id="m23">
<mml:mrow>
<mml:msup>
<mml:mi>Q</mml:mi>
<mml:mi>max</mml:mi>
</mml:msup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Total number of quay cranes</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf24">
<mml:math id="m24">
<mml:mrow>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>i</mml:mi>
<mml:mi>max</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Maximum number of quay cranes that can be assigned to a ship</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf25">
<mml:math id="m25">
<mml:mrow>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>i</mml:mi>
<mml:mi>min</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Minimum number of quay cranes that can be assigned to a ship</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf26">
<mml:math id="m26">
<mml:mrow>
<mml:msub>
<mml:mi>&#x3b7;</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Average handling efficiency of ship <inline-formula id="inf27">
<mml:math id="m27">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> in time period <inline-formula id="inf28">
<mml:math id="m28">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf29">
<mml:math id="m29">
<mml:mrow>
<mml:msub>
<mml:mi>w</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Amount of cargo to be loaded and unloaded by ship <inline-formula id="inf30">
<mml:math id="m30">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf31">
<mml:math id="m31">
<mml:mrow>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>k</mml:mi>
<mml:mi>l</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Leftmost position that can be served by quay crane <inline-formula id="inf32">
<mml:math id="m32">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf33">
<mml:math id="m33">
<mml:mrow>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>k</mml:mi>
<mml:mi>r</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Rightmost position that can be served by quay crane <inline-formula id="inf34">
<mml:math id="m34">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf35">
<mml:math id="m35">
<mml:mrow>
<mml:mi>r</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Safe distance between ships at berth</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf36">
<mml:math id="m36">
<mml:mrow>
<mml:mi>M</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Infinite number</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf37">
<mml:math id="m37">
<mml:mrow>
<mml:mi>L</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Length of the quay shoreline</td>
</tr>
</tbody>
</table>
<table>
<thead valign="top">
<tr>
<th align="left">Decision variables</th>
<th align="left">Connotation</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="left">
<inline-formula id="inf38">
<mml:math id="m38">
<mml:mrow>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Binary variable that takes the value of 1 if ship <inline-formula id="inf39">
<mml:math id="m39">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is served by quay crane <inline-formula id="inf40">
<mml:math id="m40">
<mml:mrow>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> in time slot <inline-formula id="inf41">
<mml:math id="m41">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and 0 otherwise</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf42">
<mml:math id="m42">
<mml:mrow>
<mml:msubsup>
<mml:mi>v</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Binary variable that takes the value of 1 if quay crane <inline-formula id="inf43">
<mml:math id="m43">
<mml:mrow>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> moves to ship <inline-formula id="inf44">
<mml:math id="m44">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> in time period <inline-formula id="inf45">
<mml:math id="m45">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and 0 otherwise</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf46">
<mml:math id="m46">
<mml:mrow>
<mml:msub>
<mml:mi>b</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Berthing time of ship <inline-formula id="inf47">
<mml:math id="m47">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf48">
<mml:math id="m48">
<mml:mrow>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Berthing position of ship <inline-formula id="inf49">
<mml:math id="m49">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf50">
<mml:math id="m50">
<mml:mrow>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Binary variable that takes the value of 1 if the berthing position of ship <inline-formula id="inf51">
<mml:math id="m51">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is to the left of ship <inline-formula id="inf52">
<mml:math id="m52">
<mml:mrow>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and 0 otherwise</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf53">
<mml:math id="m53">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Binary variable that takes the value of 1 if the berthing time of ship <inline-formula id="inf54">
<mml:math id="m54">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is earlier than that of ship <inline-formula id="inf55">
<mml:math id="m55">
<mml:mrow>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and 0 otherwise</td>
</tr>
<tr>
<td align="left">
<inline-formula id="inf56">
<mml:math id="m56">
<mml:mrow>
<mml:msub>
<mml:mi>m</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
<td align="left">Binary variable that takes the value of 1 if vessel <inline-formula id="inf57">
<mml:math id="m57">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is serviced in time period <inline-formula id="inf58">
<mml:math id="m58">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and 0 otherwise</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>We construct an integer programming model with the objective of minimizing the total ship delay cost, quay crane service costs, and quay crane movement costs by taking into account the quay crane working range, constraint limitations of quay crane crossings, and other elements as follows:<disp-formula id="e1">
<mml:math id="m59">
<mml:mrow>
<mml:mi>min</mml:mi>
<mml:mtext>&#xa0;</mml:mtext>
<mml:mi>C</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
</mml:mrow>
</mml:munder>
</mml:mstyle>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
</mml:mrow>
</mml:munder>
</mml:mstyle>
<mml:msup>
<mml:msub>
<mml:mi>c</mml:mi>
<mml:mi mathvariant="normal">t</mml:mi>
</mml:msub>
<mml:mtext>service</mml:mtext>
</mml:msup>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>q</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
</mml:mrow>
</mml:munder>
</mml:mstyle>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2b;</mml:mo>
<mml:msubsup>
<mml:mi>c</mml:mi>
<mml:mi>i</mml:mi>
<mml:mtext>delay</mml:mtext>
</mml:msubsup>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>e</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2b;</mml:mo>
<mml:msup>
<mml:mi>c</mml:mi>
<mml:mtext>move</mml:mtext>
</mml:msup>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
</mml:mrow>
</mml:munder>
</mml:mstyle>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>q</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
</mml:mrow>
</mml:munder>
</mml:mstyle>
<mml:msubsup>
<mml:mi>v</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(1)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e1">Equation 1</xref> addresses the objective function, that the total cost of the port is the lowest, and has three components: the first term is the cost of the quay cranes service, the length of time the quay cranes service the ship, and the cost of the quay cranes at different moments of the service. The second is the cost of the ship&#x2019;s delays; this item will only be established if the ship&#x2019;s departure time is later than the expected time of departure; otherwise, it will be zero. The third is the movement cost of the quay cranes, which comes from the personnel dispatch and resource consumption caused by the stopping and restarting of the quay cranes and is established when the quay cranes change the service ship or serve the ship for the first time.<disp-formula id="e2">
<mml:math id="m60">
<mml:mrow>
<mml:mi mathvariant="normal">s</mml:mi>
<mml:mo>.</mml:mo>
<mml:mi mathvariant="normal">t</mml:mi>
<mml:mo>.</mml:mo>
<mml:mtext>&#x2002;</mml:mtext>
<mml:msub>
<mml:mi>b</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2265;</mml:mo>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(2)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e2">Equation 2</xref> ensures that each ship berths later than its arrival time, avoiding impractical scheduling arrangements.<disp-formula id="e3">
<mml:math id="m61">
<mml:mrow>
<mml:msub>
<mml:mi>e</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>b</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:msub>
<mml:mi>f</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(3)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e3">Equation 3</xref> calculates the departure time of a ship based on the loading and unloading time of the ship.<disp-formula id="e4">
<mml:math id="m62">
<mml:mrow>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:msub>
<mml:mi>l</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:mi>r</mml:mi>
<mml:mo>&#x2264;</mml:mo>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>j</mml:mi>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:mi>M</mml:mi>
<mml:mo>&#x22c5;</mml:mo>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(4)</label>
</disp-formula>
<disp-formula id="e5">
<mml:math id="m63">
<mml:mrow>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mrow>
<mml:mi>j</mml:mi>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2264;</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(5)</label>
</disp-formula>
<disp-formula id="e6">
<mml:math id="m64">
<mml:mrow>
<mml:msub>
<mml:mi>e</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2264;</mml:mo>
<mml:msub>
<mml:mi>b</mml:mi>
<mml:mi>j</mml:mi>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:mi>M</mml:mi>
<mml:mo>&#x22c5;</mml:mo>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(6)</label>
</disp-formula>
<disp-formula id="e7">
<mml:math id="m65">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>j</mml:mi>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2264;</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(7)</label>
</disp-formula>
<disp-formula id="e8">
<mml:math id="m66">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>j</mml:mi>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mrow>
<mml:mi>j</mml:mi>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2265;</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(8)</label>
</disp-formula>
</p>
<p>A series of constraints from <xref ref-type="disp-formula" rid="e4">Equations 4</xref>&#x2013;<xref ref-type="disp-formula" rid="e8">8</xref> ensures that only one vessel can berth at the same location at any given time, avoiding scheduling conflicts in time or space.<disp-formula id="e9">
<mml:math id="m67">
<mml:mrow>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:msub>
<mml:mi>l</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>L</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(9)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e9">Equation 9</xref> requires that the berthing position of the ship be on the shoreline of the port and that the feasibility of the berthing position be ensured.<disp-formula id="e10">
<mml:math id="m68">
<mml:mrow>
<mml:msub>
<mml:mi>e</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2264;</mml:mo>
<mml:msup>
<mml:mi>T</mml:mi>
<mml:mi>max</mml:mi>
</mml:msup>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(10)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e10">Equation 10</xref> requires all ships to leave port during the berth planning period.<disp-formula id="e11">
<mml:math id="m69">
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mi>i</mml:mi>
</mml:munder>
</mml:mstyle>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mi>q</mml:mi>
</mml:munder>
</mml:mstyle>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2264;</mml:mo>
<mml:msup>
<mml:mi>Q</mml:mi>
<mml:mi>max</mml:mi>
</mml:msup>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(11)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e11">Equation 11</xref> ensures that the total number of quay cranes serving ships at any one time is less than the total number owned by the terminal.<disp-formula id="e12">
<mml:math id="m70">
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mi>q</mml:mi>
</mml:munder>
</mml:mstyle>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2265;</mml:mo>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>i</mml:mi>
<mml:mi>min</mml:mi>
</mml:msubsup>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>q</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(12)</label>
</disp-formula>
<disp-formula id="e13">
<mml:math id="m71">
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mi>q</mml:mi>
</mml:munder>
</mml:mstyle>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2264;</mml:mo>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>i</mml:mi>
<mml:mi>max</mml:mi>
</mml:msubsup>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(13)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e12">Equations 12</xref>, <xref ref-type="disp-formula" rid="e13">13</xref> require that the number of quay cranes on the service ship at each point in time be greater than the minimum required number of quay cranes and less than the maximum number of quay cranes that the ship can accommodate.<disp-formula id="e14">
<mml:math id="m72">
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mi>t</mml:mi>
</mml:munder>
</mml:mstyle>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mi>q</mml:mi>
</mml:munder>
</mml:mstyle>
<mml:msub>
<mml:mi>&#x3b7;</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:msub>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2265;</mml:mo>
<mml:msub>
<mml:mi>w</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(14)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e14">Equation 14</xref> ensures that the loading and unloading tasks of the ship can be accomplished.<disp-formula id="e15">
<mml:math id="m73">
<mml:mrow>
<mml:mi>M</mml:mi>
<mml:mo>&#x22c5;</mml:mo>
<mml:msub>
<mml:mi>m</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2265;</mml:mo>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mi>q</mml:mi>
</mml:munder>
</mml:mstyle>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(15)</label>
</disp-formula>
<disp-formula id="e16">
<mml:math id="m74">
<mml:mrow>
<mml:msub>
<mml:mi>m</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2264;</mml:mo>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mi>q</mml:mi>
</mml:munder>
</mml:mstyle>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(16)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e15">Equations 15</xref>, <xref ref-type="disp-formula" rid="e16">16</xref> indicate that if ship <inline-formula id="inf59">
<mml:math id="m75">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is serviced in time slot <inline-formula id="inf60">
<mml:math id="m76">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, then <inline-formula id="inf61">
<mml:math id="m77">
<mml:mrow>
<mml:msub>
<mml:mi>m</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> takes the value of 1 and otherwise 0.<disp-formula id="e17">
<mml:math id="m78">
<mml:mrow>
<mml:msub>
<mml:mi>f</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:mstyle displaystyle="true">
<mml:munder>
<mml:mo>&#x2211;</mml:mo>
<mml:mi>t</mml:mi>
</mml:munder>
</mml:mstyle>
<mml:msub>
<mml:mi>m</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(17)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e17">Equation 17</xref> calculates the total loading and unloading time for each ship.<disp-formula id="e18">
<mml:math id="m79">
<mml:mrow>
<mml:mrow>
<mml:mfenced open="" close="" separators="&#x7c;">
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
<mml:mrow>
<mml:msub>
<mml:mi>t</mml:mi>
<mml:mi>max</mml:mi>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:munderover>
</mml:mstyle>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mrow>
<mml:mo>&#x7c;</mml:mo>
</mml:mrow>
<mml:msub>
<mml:mi>m</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>m</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mrow>
<mml:mfenced open="|" close="" separators="&#x7c;">
<mml:mrow>
<mml:mo>&#x2264;</mml:mo>
<mml:mn>2</mml:mn>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>N</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(18)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e18">Equation 18</xref> ensures that the quay crane is available to serve the ship for each time period after it berths until the ship departs.<disp-formula id="e19">
<mml:math id="m80">
<mml:mrow>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>a</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>a</mml:mi>
<mml:mi>l</mml:mi>
</mml:msubsup>
<mml:mo>&#x2212;</mml:mo>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>j</mml:mi>
<mml:mi>b</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>b</mml:mi>
<mml:mi>l</mml:mi>
</mml:msubsup>
<mml:mo>&#x2b;</mml:mo>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>a</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2b;</mml:mo>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>j</mml:mi>
<mml:mi>b</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>2</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mi>M</mml:mi>
<mml:mo>&#x2264;</mml:mo>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mi>M</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>j</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>a</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>b</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(19)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e19">Equation 19</xref> ensures that the quay cranes do not cross. If ship <inline-formula id="inf62">
<mml:math id="m81">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is to the right of ship <inline-formula id="inf63">
<mml:math id="m82">
<mml:mrow>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf64">
<mml:math id="m83">
<mml:mrow>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> is 0, the equation is constant; if ship <inline-formula id="inf65">
<mml:math id="m84">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is to the left of ship <inline-formula id="inf66">
<mml:math id="m85">
<mml:mrow>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, the right-hand side of the equation is 0; and if both ships require quay crane service at the same time, the quay crane that serves ship <inline-formula id="inf67">
<mml:math id="m86">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> must be all the way to the left of the quay crane that serves ship <inline-formula id="inf68">
<mml:math id="m87">
<mml:mrow>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>. The equation also ensures that the quay crane that serves ship <inline-formula id="inf69">
<mml:math id="m88">
<mml:mrow>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> will not cross.<disp-formula id="e20">
<mml:math id="m89">
<mml:mrow>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>k</mml:mi>
<mml:mi>l</mml:mi>
</mml:msubsup>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>l</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>M</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>&#x2212;</mml:mo>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>k</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>k</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(20)</label>
</disp-formula>
<disp-formula id="e21">
<mml:math id="m90">
<mml:mrow>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msubsup>
<mml:mi>q</mml:mi>
<mml:mi>k</mml:mi>
<mml:mi>r</mml:mi>
</mml:msubsup>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>M</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>&#x2212;</mml:mo>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>k</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>k</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(21)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e20">Equations 20</xref>, <xref ref-type="disp-formula" rid="e21">21</xref> provide that a ship can only be serviced within the working limits of the quay crane.<disp-formula id="e22">
<mml:math id="m91">
<mml:mrow>
<mml:msubsup>
<mml:mi>v</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2264;</mml:mo>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>q</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(22)</label>
</disp-formula>
<disp-formula id="e23">
<mml:math id="m92">
<mml:mrow>
<mml:msubsup>
<mml:mi>v</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2264;</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo>&#x2212;</mml:mo>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msubsup>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>q</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(23)</label>
</disp-formula>
<disp-formula id="e24">
<mml:math id="m93">
<mml:mrow>
<mml:msubsup>
<mml:mi>v</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2265;</mml:mo>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2212;</mml:mo>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msubsup>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>q</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(24)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e22">Equation 22</xref> through <xref ref-type="disp-formula" rid="e24">Equation 24</xref> ensure that <inline-formula id="inf70">
<mml:math id="m94">
<mml:mrow>
<mml:msubsup>
<mml:mi>v</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula> records the first time at time t that a quay crane <inline-formula id="inf71">
<mml:math id="m95">
<mml:mrow>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> moves to a ship <inline-formula id="inf72">
<mml:math id="m96">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> to service it. <xref ref-type="disp-formula" rid="e22">Equation 22</xref> ensures that the quay crane only moves to a ship if it must service that ship. <xref ref-type="disp-formula" rid="e23">Equation 23</xref> states that when the quay crane <inline-formula id="inf73">
<mml:math id="m97">
<mml:mrow>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> has already serviced ship <inline-formula id="inf74">
<mml:math id="m98">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> at the previous time period <inline-formula id="inf75">
<mml:math id="m99">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:math>
</inline-formula>, the move is not recorded. <xref ref-type="disp-formula" rid="e24">Equation 24</xref> indicates that when quay crane <inline-formula id="inf76">
<mml:math id="m100">
<mml:mrow>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> did not serve ship <inline-formula id="inf77">
<mml:math id="m101">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> in the previous time period <inline-formula id="inf78">
<mml:math id="m102">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:math>
</inline-formula>, and quay crane <inline-formula id="inf79">
<mml:math id="m103">
<mml:mrow>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> serves ship <inline-formula id="inf80">
<mml:math id="m104">
<mml:mrow>
<mml:mi>i</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> in this time period <inline-formula id="inf81">
<mml:math id="m105">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, then a movement of the quay crane is recorded.<disp-formula id="e25">
<mml:math id="m106">
<mml:mrow>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2265;</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>b</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2265;</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(25)</label>
</disp-formula>
<disp-formula id="e26">
<mml:math id="m107">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2208;</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo>,</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(26)</label>
</disp-formula>
<disp-formula id="e27">
<mml:math id="m108">
<mml:mrow>
<mml:msub>
<mml:mi>m</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2208;</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo>,</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:math>
<label>(27)</label>
</disp-formula>
<disp-formula id="e28">
<mml:math id="m109">
<mml:mrow>
<mml:msubsup>
<mml:mi>z</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>q</mml:mi>
</mml:mrow>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>&#x2208;</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo>,</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>i</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>S</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>t</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>T</mml:mi>
<mml:mo>,</mml:mo>
<mml:mo>&#x2200;</mml:mo>
<mml:mi>q</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(28)</label>
</disp-formula>
</p>
<p>
<xref ref-type="disp-formula" rid="e25">Equation 25</xref> defines the non-negativity of berthing position and berthing time. <xref ref-type="disp-formula" rid="e26">Equations 26</xref>&#x2013;<xref ref-type="disp-formula" rid="e28">28</xref> define the 0&#x2013;1 variables.</p>
</sec>
</sec>
<sec id="s4">
<title>4 Solution methodology</title>
<p>Berth-quay crane scheduling is an NP-hard problem, and exact algorithms are difficult to solve in large-scale arithmetic cases (<xref ref-type="bibr" rid="B12">Lujan et al., 2021</xref>). Compared with traditional heuristic algorithms, genetic algorithms have higher global search capability (<xref ref-type="bibr" rid="B5">Hanagandi and Nikolaou, 1998</xref>). However, traditional genetic algorithms have a single genetic operation that easily falls into local optimization. To balance the diversity of the population and global search ability, we adopt the Q-learning algorithm to adaptively select the genetic operator (<xref ref-type="bibr" rid="B20">Wang et al., 2013</xref>). In the calculation process, we use the genetic algorithm to determine the berthing order, berthing position, and the number of quay cranes required for each time period. The quay crane allocation algorithm calculates the specific quay crane allocation scheme for each ship and evaluates the fitness of the solution. The Q-learning algorithm selects the genetic operator according to the state of the population in the genetic algorithm, which advances the iterative process of the genetic algorithm. The three algorithms continuously interact with each other and ultimately obtain the optimal solution that meets the requirements. The algorithm framework is shown in <xref ref-type="fig" rid="F2">Figure 2</xref>.</p>
<fig id="F2" position="float">
<label>FIGURE 2</label>
<caption>
<p>Algorithm framework diagram.</p>
</caption>
<graphic xlink:href="fieng-03-1523203-g002.tif"/>
</fig>
<sec id="s4-1">
<title>4.1 Genetic algorithm</title>
<sec id="s4-1-1">
<title>4.1.1 Chromosome and population initialization</title>
<p>We encode the solution into a three-layer structure: the first layer shows the order in which the ships berth, the second layer indicates the serial number of the first docking cluster pile where the ship docks, that is, where the ship berths, and the third layer is a number obtained from the list encoding, which contains the number of quay cranes needed in each time period after the ship berths. The structure of the solution is shown in <xref ref-type="fig" rid="F3">Figure 3</xref>, taking Ship 1 as an example. Ship 1 is the third in the berthing order, the berthing cluster pile serial number is 44, and the number of quay cranes required in the first time period after berthing is 5. The number of quay cranes required in the second time period is 4, and so on.</p>
<fig id="F3" position="float">
<label>FIGURE 3</label>
<caption>
<p>Structure of the solution.</p>
</caption>
<graphic xlink:href="fieng-03-1523203-g003.tif"/>
</fig>
<p>The third layer of the decoding consists of an array of an indeterminate number of quay cranes, which must be decoded to obtain the number of quay cranes required for each time period of the vessel after berthing. The logic of decoding is as follows: First, the encoded data are converted into binary numbers. Then, according to the number of quay cranes activated in the port, the number of binary bits corresponding to the number of quay cranes is obtained. Finally, according to the number of bits, it is decoded into the required number of quay cranes. Taking the third layer of encoding of Ship 1 as an example, the encoded number is 345,157, which is first converted into a binary number for storage. Assuming the port has eight available quay cranes, we convert the encoded number 345157 into a binary number (1010100010001000100010101). Reading four bits from back to front, we get 0101, which converts to the decimal number 5. By similar reasoning, we obtain the array: 54445, which means that over five time periods, the ship requires 5, 4, 4, 4, and 5 quay cranes, respectively. Then, using the quay crane allocation algorithm, we allocate the specific serial numbers of the quay cranes.</p>
</sec>
<sec id="s4-1-2">
<title>4.1.2 Fitness calculation and quay crane allocation algorithm</title>
<sec id="s4-1-2-1">
<title>4.1.2.1 Fitness calculation</title>
<p>We process individual chromosomes through a set of heuristic algorithms to compute the various costs of the port and to perform quay crane allocation. The berthing order of ships is first determined by the first layer of coding of the chromosome. Then, the second layer of the chromosome&#x2019;s coding is read to determine the berthing position. If the berthing position of the ship does not conflict with the berthing position of the previous ship, satisfies the safety distance constraint, and the quay cranes of the port can satisfy the minimum quay crane requirement of the ship, then the ship enters the port. Otherwise, the ship needs to wait for the previous ship to leave the port before entering the port. After the ship enters the port, the quay crane allocation algorithm is invoked to allocate a specific quay crane for the ship.When the unloading and loading of the ship&#x2019;s cargo is completed, the ship leaves the port, and the delay cost of all ships, the service cost of the quay cranes, and the movement cost of the quay cranes are calculated. The steps of the algorithm are as follows:<list list-type="simple">
<list-item>
<p>Step 1: input a chromosome, let <inline-formula id="inf82">
<mml:math id="m110">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>0</mml:mn>
</mml:mrow>
</mml:math>
</inline-formula>, read the first layer of the chromosome to obtain the berthing order of the ships <inline-formula id="inf83">
<mml:math id="m111">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, let <inline-formula id="inf84">
<mml:math id="m112">
<mml:mrow>
<mml:mi>k</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:math>
</inline-formula>, set the port state to empty, the quay crane service state to empty, and the expected number of ships to be accepted is <inline-formula id="inf85">
<mml:math id="m113">
<mml:mrow>
<mml:mi>N</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>.</p>
</list-item>
<list-item>
<p>Step 2: If <inline-formula id="inf86">
<mml:math id="m114">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x3e;</mml:mo>
<mml:msup>
<mml:mi>t</mml:mi>
<mml:mi>max</mml:mi>
</mml:msup>
</mml:mrow>
</mml:math>
</inline-formula> or <inline-formula id="inf87">
<mml:math id="m115">
<mml:mrow>
<mml:mi>k</mml:mi>
<mml:mo>&#x3e;</mml:mo>
<mml:mi>N</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, and the port state is empty, then jump to Step 7; otherwise, jump to Step&#xa0;3.</p>
</list-item>
<list-item>
<p>Step 3: If the arrival time of ship <inline-formula id="inf88">
<mml:math id="m116">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> is greater than <inline-formula id="inf89">
<mml:math id="m117">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, the berthing position of ship <inline-formula id="inf90">
<mml:math id="m118">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> is not in conflict with the berthing position of the ship in the port, and if it satisfies the safety distance constraint, and if the quay cranes in the port are able to meet the minimum demand of the ship, then record the berthing position of ship <inline-formula id="inf91">
<mml:math id="m119">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, so that <inline-formula id="inf92">
<mml:math id="m120">
<mml:mrow>
<mml:mi>k</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mi>k</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:math>
</inline-formula>.</p>
</list-item>
<list-item>
<p>Step 4: Input the original quay crane service status and the expected number of quay cranes for ships in port. Activate the quay crane allocation algorithm to minimize the changes and update the service status, considering the working range and continuous allocation of quay cranes.</p>
</list-item>
<list-item>
<p>Step 5: Calculate the total amount of cargo to be loaded and unloaded by the ships in port at this moment based on the updated service status of the quay cranes and the efficiency of the quay cranes at time <inline-formula id="inf93">
<mml:math id="m121">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, and update the total amount of cargo to be loaded and unloaded by the ships in port. Record the service status of the quay cranes and the movement of the quay cranes.</p>
</list-item>
<list-item>
<p>Step 6: Determine if any ship&#x2019;s unloading and tasks are completed. If so, update the port status, record the ship&#x2019;s departure time, and the quay cranes&#x2019; service and movement status during the unloading and loading processes. Return to Step 2.</p>
</list-item>
<list-item>
<p>Step 7: If <inline-formula id="inf94">
<mml:math id="m122">
<mml:mrow>
<mml:mi>k</mml:mi>
<mml:mo>&#x3e;</mml:mo>
<mml:mi>N</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, calculate the delay, service, and movement costs for the quay cranes based on each ship&#x2019;s departure time, the quay cranes&#x2019; service, and movement situations. If not, mark the solution as infeasible and set the costs to <inline-formula id="inf95">
<mml:math id="m123">
<mml:mrow>
<mml:mi mathvariant="italic">Inf</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>.</p>
</list-item>
<list-item>
<p>Step 8: Output the delay cost of the ship, the service cost of the quay cranes, and the movement cost of the quay cranes for this chromosome.</p>
</list-item>
</list>
</p>
<p>We set the fitness of the genetic algorithm to depend on the total cost of the port, and the fitness is defined by <xref ref-type="disp-formula" rid="e29">Equation 29</xref>, where <inline-formula id="inf96">
<mml:math id="m124">
<mml:mrow>
<mml:mi>x</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> represents the individual, <inline-formula id="inf97">
<mml:math id="m125">
<mml:mrow>
<mml:msubsup>
<mml:mi>C</mml:mi>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>d</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>l</mml:mi>
<mml:mi>a</mml:mi>
<mml:mi>y</mml:mi>
</mml:mrow>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula> represents the delay cost of the ship, <inline-formula id="inf98">
<mml:math id="m126">
<mml:mrow>
<mml:msubsup>
<mml:mi>C</mml:mi>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>s</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mi>v</mml:mi>
<mml:mi>i</mml:mi>
<mml:mi>c</mml:mi>
<mml:mi>e</mml:mi>
</mml:mrow>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula> represents the service cost of the quay crane, and <inline-formula id="inf99">
<mml:math id="m127">
<mml:mrow>
<mml:msubsup>
<mml:mi>C</mml:mi>
<mml:mi>x</mml:mi>
<mml:mrow>
<mml:mi>m</mml:mi>
<mml:mi>o</mml:mi>
<mml:mi>v</mml:mi>
<mml:mi>e</mml:mi>
</mml:mrow>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula> is denoted as the movement cost of the quay crane.<disp-formula id="e29">
<mml:math id="m128">
<mml:mrow>
<mml:mtext>fitness</mml:mtext>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>x</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3d;</mml:mo>
<mml:mfrac>
<mml:mn>1000</mml:mn>
<mml:mrow>
<mml:msubsup>
<mml:mi>C</mml:mi>
<mml:mi>x</mml:mi>
<mml:mtext>delay</mml:mtext>
</mml:msubsup>
<mml:mo>&#x2b;</mml:mo>
<mml:msubsup>
<mml:mi>C</mml:mi>
<mml:mi>x</mml:mi>
<mml:mtext>service</mml:mtext>
</mml:msubsup>
<mml:mo>&#x2b;</mml:mo>
<mml:msubsup>
<mml:mi>C</mml:mi>
<mml:mi>x</mml:mi>
<mml:mtext>move</mml:mtext>
</mml:msubsup>
</mml:mrow>
</mml:mfrac>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(29)</label>
</disp-formula>
</p>
</sec>
<sec id="s4-1-2-2">
<title>4.1.2.2 Quay crane allocation algorithm</title>
<p>We design a quay crane allocation algorithm to solve for ship-specific assigned quay crane numbers. The number of quay cranes required for each time period after berthing of the ship is recorded in the chromosome, and the quay crane allocation algorithm turns these requirements into assigned quay crane numbers. The steps are as follows:<list list-type="simple">
<list-item>
<p>Step 1: Input the current port status <inline-formula id="inf100">
<mml:math id="m129">
<mml:mrow>
<mml:mi>p</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, the last time period port status <inline-formula id="inf101">
<mml:math id="m130">
<mml:mrow>
<mml:mi>p</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, and the last time period quay crane status <inline-formula id="inf102">
<mml:math id="m131">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>. Judge whether the state of the port in the last time period <inline-formula id="inf103">
<mml:math id="m132">
<mml:mrow>
<mml:mi>p</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> and the state of the port in the current period are consistent. If they are consistent, it means that there is no new ship in the port, so proceed to Step 5; otherwise, go to Step 2.</p>
</list-item>
<list-item>
<p>Step 2: Identify the departing ship, mark the quay cranes that served it in the last period as unserved in the quay crane status <inline-formula id="inf104">
<mml:math id="m133">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, and update the status to <inline-formula id="inf105">
<mml:math id="m134">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2190;</mml:mo>
<mml:msup>
<mml:mi>Q</mml:mi>
<mml:mo>&#x2032;</mml:mo>
</mml:msup>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>. If there is no departing ship, no further processing is needed. Judge whether there is a new ship; if so, go to Step&#xa0;3; otherwise, go to Step&#xa0;5.</p>
</list-item>
<list-item>
<p>Step 3: Compare the last time period port state <inline-formula id="inf106">
<mml:math id="m135">
<mml:mrow>
<mml:mi>p</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> with the current port state <inline-formula id="inf107">
<mml:math id="m136">
<mml:mrow>
<mml:mi>p</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, find the new ship number <inline-formula id="inf108">
<mml:math id="m137">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, and query the set of quay crane numbers that can be invoked at the berthing location <inline-formula id="inf109">
<mml:math id="m138">
<mml:mrow>
<mml:mi>q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>.</p>
</list-item>
<list-item>
<p>Step 4: Retrieve the available quay crane number set <inline-formula id="inf110">
<mml:math id="m139">
<mml:mrow>
<mml:mi>q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> of ship <inline-formula id="inf111">
<mml:math id="m140">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>. Arrange the quay cranes for ship <inline-formula id="inf112">
<mml:math id="m141">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> without affecting the quay crane state <inline-formula id="inf113">
<mml:math id="m142">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> in the previous time period, set the quay crane state at this time to <inline-formula id="inf114">
<mml:math id="m143">
<mml:mrow>
<mml:msup>
<mml:mi>Q</mml:mi>
<mml:mo>&#x2032;</mml:mo>
</mml:msup>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, and make the state <inline-formula id="inf115">
<mml:math id="m144">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2190;</mml:mo>
<mml:msup>
<mml:mi>Q</mml:mi>
<mml:mo>&#x2032;</mml:mo>
</mml:msup>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>.</p>
</list-item>
<list-item>
<p>Step 5: Review the current port state, noting the expected number of shore bridges <inline-formula id="inf116">
<mml:math id="m145">
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msubsup>
<mml:mi>n</mml:mi>
<mml:mi>k</mml:mi>
<mml:mi>t</mml:mi>
</mml:msubsup>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
</inline-formula> and the set of available quay crane numbers of ships <inline-formula id="inf117">
<mml:math id="m146">
<mml:mrow>
<mml:mi>q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> during the berthing time of the ships in port. Examine the quay crane state <inline-formula id="inf118">
<mml:math id="m147">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> of the previous time period, marking the quay cranes assigned to ships as &#x2212;1 and those unassigned as &#x2212;2.</p>
</list-item>
<list-item>
<p>Step 6: Select quay cranes from the set of available quay cranes <inline-formula id="inf119">
<mml:math id="m148">
<mml:mrow>
<mml:mi>q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> for each ship <inline-formula id="inf120">
<mml:math id="m149">
<mml:mrow>
<mml:mi>k</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> to fulfill the minimum number of quay cranes required for each ship. Prioritize the selection of quay cranes marked with &#x2212;1 to ensure that their spacing aligns with the expected number required. Subsequently, select quay cranes that offer the largest spacing. Label quay cranes that have been allocated.</p>
</list-item>
<list-item>
<p>Step 7: Traverse through the ships in the port and prioritize the allocation of the quay cranes marked with &#x2212;1 to the ships so that the change in the quay crane allocation is less than the previous quay crane state <inline-formula id="inf121">
<mml:math id="m150">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>. Mark the quay cranes that have been assigned.</p>
</list-item>
<list-item>
<p>Step 8: Analyze the port state, considering the future demand for quay cranes from ships. Assign quay cranes marked as &#x2212;2 to ships, prioritize the ships with smaller changes in the expected number of quay cranes <inline-formula id="inf122">
<mml:math id="m151">
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msubsup>
<mml:mi>n</mml:mi>
<mml:mi>k</mml:mi>
<mml:mi>t</mml:mi>
</mml:msubsup>
<mml:mo>,</mml:mo>
<mml:msubsup>
<mml:mi>n</mml:mi>
<mml:mi>k</mml:mi>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msubsup>
<mml:mo>,</mml:mo>
<mml:msubsup>
<mml:mi>n</mml:mi>
<mml:mi>k</mml:mi>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>2</mml:mn>
</mml:mrow>
</mml:msubsup>
<mml:mo>.</mml:mo>
<mml:mo>.</mml:mo>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
</inline-formula>, and mark the completed allocation of the quay cranes.</p>
</list-item>
<list-item>
<p>Step 9: Record the quay crane allocation and output the quay crane status <inline-formula id="inf123">
<mml:math id="m152">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>.</p>
</list-item>
</list>
</p>
</sec>
</sec>
<sec id="s4-1-3">
<title>4.1.3 Genetic operations</title>
<p>We use roulette to select the operator and maintain the elite strategy (<xref ref-type="bibr" rid="B17">Pham et al., 2024</xref>). The three-layer encoding approach involves three distinct crossover and mutation operations. The crossover operations for the three chromosome layers include partial matching crossover, single-point crossover, and single-point crossover applied after decoding. Mutation operations for the three chromosome layers consist of exchange mutation, random mutation, and bit-flip mutation. Instead of simultaneously applying crossover and mutation to all three chromosome layers, we leverage a pre-trained Q-learning algorithm to select appropriate genetic operators for one or more layers. This approach enhances the algorithm&#x2019;s convergence speed and optimization capability.</p>
<p>Two types of infeasible solutions can occur when performing genetic operations. We need to fix the infeasible solutions.<list list-type="simple">
<list-item>
<p>1) The new individuals may not satisfy the condition where the ship&#x2019;s berthing position, combined with its length, exceeds the total length of the quay shoreline. We employ random regeneration of berthing positions to ensure the ship&#x2019;s stern does not extend beyond the quay shoreline&#x2019;s total length.</p>
</list-item>
<list-item>
<p>2) The third layer of coding in the new individual may not meet the requirements for ship loading and unloading. We randomly add quay cranes to the list after decoding the third layer until the number and efficiency of quay cranes meet the ship&#x2019;s loading and unloading needs.</p>
</list-item>
</list>
</p>
</sec>
</sec>
<sec id="s4-2">
<title>4.2 Q-learning algorithm</title>
<p>We utilize the Q-learning algorithm to determine the genetic operators during the population iteration process and set the agent of the Q-learning as populations. The two-dimensional states and actions form a three-dimensional Q-table. The agent calculates the current state of the population and selects the appropriate action (i.e., genetic operator) to enhance the genetic algorithm&#x2019;s convergence and optimization capabilities. The algorithm framework of the Q-learning part is shown in <xref ref-type="fig" rid="F4">Figure 4</xref>.</p>
<fig id="F4" position="float">
<label>FIGURE 4</label>
<caption>
<p>Q-learning algorithm framework.</p>
</caption>
<graphic xlink:href="fieng-03-1523203-g004.tif"/>
</fig>
<p>We define the state of the environment in which the agent is located to be determined by the diversity of individuals in the population and the number of repetitions of the optimal individual fitness in the population that have not been updated. The diversity of individuals in the population is defined by the information entropy (as shown in <xref ref-type="disp-formula" rid="e30">Equation 30</xref>), where <inline-formula id="inf124">
<mml:math id="m153">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> is the individual fitness in the population, <inline-formula id="inf125">
<mml:math id="m154">
<mml:mrow>
<mml:mi>p</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> is the probability of occurrence of the individual fitness, <inline-formula id="inf126">
<mml:math id="m155">
<mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
<mml:mi>n</mml:mi>
</mml:munderover>
</mml:mstyle>
<mml:mi>P</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:msub>
<mml:mi>log</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
<mml:mo>&#x2061;</mml:mo>
<mml:mi>P</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> is the information entropy of the population, which is <inline-formula id="inf127">
<mml:math id="m156">
<mml:mrow>
<mml:msub>
<mml:mi>log</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
<mml:mo>&#x2061;</mml:mo>
<mml:mi>n</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> when the population is completely disordered, and <inline-formula id="inf128">
<mml:math id="m157">
<mml:mrow>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>x</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> is defined as the complexity of the population. The number of repetitions without updating represents the number of times the current individual repeats the optimal state keeping.<disp-formula id="e30">
<mml:math id="m158">
<mml:mrow>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>X</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3d;</mml:mo>
<mml:mfrac>
<mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
<mml:mi>n</mml:mi>
</mml:munderover>
</mml:mstyle>
<mml:mi>P</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:msub>
<mml:mi>log</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
<mml:mo>&#x2061;</mml:mo>
<mml:mi>P</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
<mml:mrow>
<mml:msub>
<mml:mi>log</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
<mml:mo>&#x2061;</mml:mo>
<mml:mi>n</mml:mi>
</mml:mrow>
</mml:mfrac>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(30)</label>
</disp-formula>
</p>
<p>We define the state space as in <xref ref-type="table" rid="T2">Table 2</xref>, where <inline-formula id="inf129">
<mml:math id="m159">
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is the number of repeated non-updates, and <inline-formula id="inf130">
<mml:math id="m160">
<mml:mrow>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is the total number of iterations.</p>
<table-wrap id="T2" position="float">
<label>TABLE 2</label>
<caption>
<p>Q-learning state definitions.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th align="center">State</th>
<th align="center">Details</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="center">State 1</td>
<td align="center">
<inline-formula id="inf131">
<mml:math id="m161">
<mml:mrow>
<mml:mn>0</mml:mn>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>X</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>0.25</mml:mn>
<mml:mo>,</mml:mo>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>10</mml:mn>
<mml:mo>%</mml:mo>
<mml:mo>&#x22c5;</mml:mo>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="center">State 2</td>
<td align="center">
<inline-formula id="inf132">
<mml:math id="m162">
<mml:mrow>
<mml:mn>0.25</mml:mn>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>X</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>0.5</mml:mn>
<mml:mo>,</mml:mo>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>10</mml:mn>
<mml:mo>%</mml:mo>
<mml:mo>&#x22c5;</mml:mo>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="center">State 3</td>
<td align="center">
<inline-formula id="inf133">
<mml:math id="m163">
<mml:mrow>
<mml:mn>0.5</mml:mn>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>X</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>0.75</mml:mn>
<mml:mo>,</mml:mo>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>10</mml:mn>
<mml:mo>%</mml:mo>
<mml:mo>&#x22c5;</mml:mo>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="center">State 4</td>
<td align="center">
<inline-formula id="inf134">
<mml:math id="m164">
<mml:mrow>
<mml:mn>0.75</mml:mn>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>X</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>10</mml:mn>
<mml:mo>%</mml:mo>
<mml:mo>&#x22c5;</mml:mo>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="center">State 5</td>
<td align="center">
<inline-formula id="inf135">
<mml:math id="m165">
<mml:mrow>
<mml:mn>0</mml:mn>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>X</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>0.25</mml:mn>
<mml:mo>,</mml:mo>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mo>&#x2265;</mml:mo>
<mml:mn>10</mml:mn>
<mml:mo>%</mml:mo>
<mml:mo>&#x22c5;</mml:mo>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="center">State 6</td>
<td align="center">
<inline-formula id="inf136">
<mml:math id="m166">
<mml:mrow>
<mml:mn>0.25</mml:mn>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>X</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>0.5</mml:mn>
<mml:mo>,</mml:mo>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mo>&#x2265;</mml:mo>
<mml:mn>10</mml:mn>
<mml:mo>%</mml:mo>
<mml:mo>&#x22c5;</mml:mo>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="center">State 7</td>
<td align="center">
<inline-formula id="inf137">
<mml:math id="m167">
<mml:mrow>
<mml:mn>0.5</mml:mn>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>X</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>0.75</mml:mn>
<mml:mo>,</mml:mo>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mo>&#x2265;</mml:mo>
<mml:mn>10</mml:mn>
<mml:mo>%</mml:mo>
<mml:mo>&#x22c5;</mml:mo>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
<tr>
<td align="center">State 8</td>
<td align="center">
<inline-formula id="inf138">
<mml:math id="m168">
<mml:mrow>
<mml:mn>0.75</mml:mn>
<mml:mo>&#x2264;</mml:mo>
<mml:mi>H</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>X</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3c;</mml:mo>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:mi>i</mml:mi>
<mml:mi>t</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>r</mml:mi>
<mml:mo>&#x2265;</mml:mo>
<mml:mn>10</mml:mn>
<mml:mo>%</mml:mo>
<mml:mo>&#x22c5;</mml:mo>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>
</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>Traditional genetic algorithms often employ a single crossover and mutation method, which can easily lead to local optima. Moreover, these operations are applied to the entire chromosome, making local adjustments challenging for relatively fit individuals. We implement diverse crossover and mutation strategies at three coding levels: ship berthing order, ship berthing position, and the number of quay cranes required for ships during different time periods. The actions of the Q-learning algorithm in this study are defined in <xref ref-type="table" rid="T3">Table 3</xref>.</p>
<table-wrap id="T3" position="float">
<label>TABLE 3</label>
<caption>
<p>Q-learning action definitions.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th align="center">Scope</th>
<th align="center">Primitive operator</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td rowspan="3" align="center">Layer 1 encoding</td>
<td align="left">(1) Two nodes are randomly selected, and all elements within the two nodes are swapped in order</td>
</tr>
<tr>
<td align="left">(2) Randomly select two nodes to swap order</td>
</tr>
<tr>
<td align="left">(3) Coding crossover with global optimum layer 1</td>
</tr>
<tr>
<td rowspan="3" align="center">Layer 2 encoding</td>
<td align="left">(4) Randomly increase or decrease some random integer</td>
</tr>
<tr>
<td align="left">(5) Randomly select numbers within the full range of integers</td>
</tr>
<tr>
<td align="left">(6) Coding crossover with global optimum layer 2</td>
</tr>
<tr>
<td rowspan="3" align="center">Layer 3 encoding</td>
<td align="left">(7) Randomized selection list of two nodes swapping order</td>
</tr>
<tr>
<td align="left">(8) Randomly select nodes to increase or decrease by some random integer</td>
</tr>
<tr>
<td align="left">(9) Coding crossover with global optimum layer 3</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>We set two strategies in selecting the action: the first one is to use the Q-table for selection, and the other one is to select by greedy strategy. The greedy value is defined in <xref ref-type="disp-formula" rid="e31">Equation 31</xref>, where <inline-formula id="inf139">
<mml:math id="m169">
<mml:mrow>
<mml:msub>
<mml:mi>&#x3b5;</mml:mi>
<mml:mi>max</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> is the hyperparameter represents the maximum greedy rate, <inline-formula id="inf140">
<mml:math id="m170">
<mml:mrow>
<mml:mi>f</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is the current iteration number, and <inline-formula id="inf141">
<mml:math id="m171">
<mml:mrow>
<mml:mi>G</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is the total iteration number. We use random selection of actions when <inline-formula id="inf142">
<mml:math id="m172">
<mml:mrow>
<mml:mi>r</mml:mi>
<mml:mi>a</mml:mi>
<mml:mi>n</mml:mi>
<mml:mi>d</mml:mi>
<mml:mi>o</mml:mi>
<mml:mi>m</mml:mi>
<mml:mo>&#x3c;</mml:mo>
<mml:mi>&#x3b5;</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>; otherwise, one is randomly selected in the Q-table from the actions corresponding to the first three Q-values of the current state.<disp-formula id="e31">
<mml:math id="m173">
<mml:mrow>
<mml:mi>&#x3b5;</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mfrac>
<mml:msub>
<mml:mi>&#x3b5;</mml:mi>
<mml:mi>max</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>&#x2b;</mml:mo>
<mml:msup>
<mml:mi>e</mml:mi>
<mml:mrow>
<mml:mn>10</mml:mn>
<mml:mo>&#xd7;</mml:mo>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mfrac>
<mml:mrow>
<mml:mi>f</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>0.6</mml:mn>
<mml:mo>&#xd7;</mml:mo>
<mml:mi>G</mml:mi>
</mml:mrow>
<mml:mi>G</mml:mi>
</mml:mfrac>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:msup>
</mml:mrow>
</mml:mfrac>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(31)</label>
</disp-formula>
</p>
<p>After performing an action, the agent obtains a reward for that action, and we set the reward value as in <xref ref-type="disp-formula" rid="e32">Equation 32</xref>. The Q-table is updated as shown in <xref ref-type="disp-formula" rid="e33">Equation 33</xref>, where <inline-formula id="inf143">
<mml:math id="m174">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>s</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> denotes the Q-value for each generation of selecting action <inline-formula id="inf144">
<mml:math id="m175">
<mml:mrow>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> based on the state <inline-formula id="inf145">
<mml:math id="m176">
<mml:mrow>
<mml:msub>
<mml:mi>s</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>. <inline-formula id="inf146">
<mml:math id="m177">
<mml:mrow>
<mml:mi>&#x3b1;</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mrow>
<mml:mfenced open="[" close="]" separators="&#x7c;">
<mml:mrow>
<mml:mn>0</mml:mn>
<mml:mo>,</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, and <inline-formula id="inf147">
<mml:math id="m178">
<mml:mrow>
<mml:mi>&#x3b3;</mml:mi>
<mml:mo>&#x2208;</mml:mo>
<mml:mrow>
<mml:mfenced open="[" close="]" separators="&#x7c;">
<mml:mrow>
<mml:mn>0</mml:mn>
<mml:mo>,</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> denote the learning rate and discount factor. <inline-formula id="inf148">
<mml:math id="m179">
<mml:mrow>
<mml:mi>max</mml:mi>
<mml:mo>&#x2061;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>s</mml:mi>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> denotes the maximum Q-value at the next state <inline-formula id="inf149">
<mml:math id="m180">
<mml:mrow>
<mml:msub>
<mml:mi>s</mml:mi>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> when taking the next action <inline-formula id="inf150">
<mml:math id="m181">
<mml:mrow>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>.<disp-formula id="e32">
<mml:math id="m182">
<mml:mrow>
<mml:mi>r</mml:mi>
<mml:mi>e</mml:mi>
<mml:mi>w</mml:mi>
<mml:mi>a</mml:mi>
<mml:mi>r</mml:mi>
<mml:mi>d</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mrow>
<mml:mfenced open="{" close="" separators="&#x7c;">
<mml:mrow>
<mml:mtable columnalign="left">
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mtd>
<mml:mtd>
<mml:mrow>
<mml:mtext>if&#xa0;</mml:mtext>
<mml:msubsup>
<mml:mi>f</mml:mi>
<mml:mtext>gbest</mml:mtext>
<mml:mtext>new</mml:mtext>
</mml:msubsup>
<mml:mo>&#x2212;</mml:mo>
<mml:msubsup>
<mml:mi>f</mml:mi>
<mml:mtext>gbest</mml:mtext>
<mml:mtext>old</mml:mtext>
</mml:msubsup>
<mml:mo>&#x3e;</mml:mo>
<mml:mn>0</mml:mn>
<mml:mo>,</mml:mo>
</mml:mrow>
</mml:mtd>
</mml:mtr>
<mml:mtr>
<mml:mtd>
<mml:mn>0</mml:mn>
</mml:mtd>
<mml:mtd>
<mml:mrow>
<mml:mtext>otherwise</mml:mtext>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:mtd>
</mml:mtr>
</mml:mtable>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
<label>(32)</label>
</disp-formula>
<disp-formula id="e33">
<mml:math id="m183">
<mml:mrow>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>s</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3d;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>s</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2b;</mml:mo>
<mml:mi>&#x3b1;</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mtext>reward</mml:mtext>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:mi>&#x3b2;</mml:mi>
<mml:mo>&#x2061;</mml:mo>
<mml:mi>max</mml:mi>
<mml:mo>&#x2061;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>s</mml:mi>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mrow>
<mml:mi>t</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:mi>Q</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>s</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>a</mml:mi>
<mml:mi>t</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(33)</label>
</disp-formula>
</p>
</sec>
</sec>
<sec id="s5">
<title>5 Numerical experiments</title>
<sec id="s5-1">
<title>5.1 Instance description and results</title>
<p>We take the data from a port on 4 July 2023 as an example for our analysis. The quay shoreline extends for a total length of 800&#xa0;m and is equipped with eight quay cranes, each with a working distance of 300&#xa0;m. Fifteen ships arrive at the port successively, and their details, including the captain&#x2019;s information, arrival time, expected departure time, and the amount of cargo to be loaded and unloaded, are shown in <xref ref-type="table" rid="T4">Table 4</xref>. We wrote the code in Python 3.9 and executed it on a computer featuring a Core i9 2.50&#xa0;GHz CPU, 16.0&#xa0;GB of RAM, and a 64-bit Windows 11 operating system. The parameter settings are shown in <xref ref-type="table" rid="T5">Table 5</xref>.</p>
<table-wrap id="T4" position="float">
<label>TABLE 4</label>
<caption>
<p>Information on arriving ships.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th align="left">Ship name</th>
<th align="left">Arrival time</th>
<th align="left">Estimated time of departure</th>
<th align="left">Length of ship (m)</th>
<th align="left">Number of containers to be loaded and unloaded</th>
<th align="left">Min number of quay cranes</th>
<th align="left">Max number of quay cranes</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="left">V1</td>
<td align="left">2023&#x2013;07&#x2013;04 04:00:00</td>
<td align="left">2023&#x2013;07&#x2013;04 08:00:00</td>
<td align="left">90</td>
<td align="left">220</td>
<td align="left">1</td>
<td align="left">2</td>
</tr>
<tr>
<td align="left">V2</td>
<td align="left">2023&#x2013;07&#x2013;04 05:00:00</td>
<td align="left">2023&#x2013;07&#x2013;04 11:00:00</td>
<td align="left">150</td>
<td align="left">440</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V3</td>
<td align="left">2023&#x2013;07&#x2013;04 07:30:00</td>
<td align="left">2023&#x2013;07&#x2013;04 11:00:00</td>
<td align="left">100</td>
<td align="left">280</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V4</td>
<td align="left">2023&#x2013;07&#x2013;04 10:30:00</td>
<td align="left">2023&#x2013;07&#x2013;04 15:30:00</td>
<td align="left">120</td>
<td align="left">400</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V5</td>
<td align="left">2023&#x2013;07&#x2013;04 12:00:00</td>
<td align="left">2023&#x2013;07&#x2013;04 16:00:00</td>
<td align="left">180</td>
<td align="left">500</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V6</td>
<td align="left">2023&#x2013;07&#x2013;04 14:00:00</td>
<td align="left">2023&#x2013;07&#x2013;04 18:30:00</td>
<td align="left">150</td>
<td align="left">420</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V7</td>
<td align="left">2023&#x2013;07&#x2013;04 18:30:00</td>
<td align="left">2023&#x2013;07&#x2013;04 22:00:00</td>
<td align="left">200</td>
<td align="left">520</td>
<td align="left">1</td>
<td align="left">4</td>
</tr>
<tr>
<td align="left">V8</td>
<td align="left">2023&#x2013;07&#x2013;04 20:30:00</td>
<td align="left">2023&#x2013;07&#x2013;04 23:00:00</td>
<td align="left">89</td>
<td align="left">180</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V9</td>
<td align="left">2023&#x2013;07&#x2013;04 22:30:00</td>
<td align="left">2023&#x2013;07&#x2013;05 03:00:00</td>
<td align="left">110</td>
<td align="left">310</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V10</td>
<td align="left">2023&#x2013;07&#x2013;04 23:00:00</td>
<td align="left">2023&#x2013;07&#x2013;05 02:00:00</td>
<td align="left">98</td>
<td align="left">200</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V11</td>
<td align="left">2023&#x2013;07&#x2013;05 00:00:00</td>
<td align="left">2023&#x2013;07&#x2013;05 08:30:00</td>
<td align="left">120</td>
<td align="left">350</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V12</td>
<td align="left">2023&#x2013;07&#x2013;05 02:30:00</td>
<td align="left">2023&#x2013;07&#x2013;05 09:30:00</td>
<td align="left">190</td>
<td align="left">470</td>
<td align="left">1</td>
<td align="left">4</td>
</tr>
<tr>
<td align="left">V13</td>
<td align="left">2023&#x2013;07&#x2013;05 09:30:00</td>
<td align="left">2023&#x2013;07&#x2013;05 12:30:00</td>
<td align="left">120</td>
<td align="left">300</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V14</td>
<td align="left">2023&#x2013;07&#x2013;05 09:30:00</td>
<td align="left">2023&#x2013;07&#x2013;05 17:00:00</td>
<td align="left">180</td>
<td align="left">430</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
<tr>
<td align="left">V15</td>
<td align="left">2023&#x2013;07&#x2013;05 09:30:00</td>
<td align="left">2023&#x2013;07&#x2013;05 15:30:00</td>
<td align="left">130</td>
<td align="left">300</td>
<td align="left">1</td>
<td align="left">3</td>
</tr>
</tbody>
</table>
</table-wrap>
<table-wrap id="T5" position="float">
<label>TABLE 5</label>
<caption>
<p>Parameter settings.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th align="center">Parameter</th>
<th align="center">Value</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="center">Population</td>
<td align="center">50</td>
</tr>
<tr>
<td align="center">Maximum number of iterations</td>
<td align="center">1,000</td>
</tr>
<tr>
<td align="center">Work efficiency of quay cranes</td>
<td align="center">30 TEU/h</td>
</tr>
<tr>
<td align="center">Maximum greed rate</td>
<td align="center">0.6</td>
</tr>
<tr>
<td align="center">Q-learning algorithm discount rate</td>
<td align="center">0.3</td>
</tr>
<tr>
<td align="center">Q-learning algorithm learning rate</td>
<td align="center">0.1</td>
</tr>
<tr>
<td align="center">Cost of quay cranes movements</td>
<td align="center">1910 CNY/times</td>
</tr>
<tr>
<td align="center">Cost of quay cranes service from 8:00 to 17:00</td>
<td align="center">1330 CNY/hour</td>
</tr>
<tr>
<td align="center">Cost of quay cranes service at other times</td>
<td align="center">1110 CNY/hour</td>
</tr>
<tr>
<td align="center">Ship delay cost</td>
<td align="center">7000 CNY/hour</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>Based on the above relevant parameters, we calculate the results as follows: the cost of quay crane service is 235,320 CNY, the cost of quay crane movement is 70,670 CNY, the cost of ship delay is 35,000 CNY, and the final total cost is 340,990 CNY. The final allocation plan of the ship is shown in <xref ref-type="fig" rid="F5">Figure 5</xref>.</p>
<fig id="F5" position="float">
<label>FIGURE 5</label>
<caption>
<p>Ship allocation plan.</p>
</caption>
<graphic xlink:href="fieng-03-1523203-g005.tif"/>
</fig>
<p>The quay crane scheduling plan is shown in <xref ref-type="fig" rid="F6">Figure 6</xref>. We illustrate with the example of Quay Crane 1. Quay Crane 1 initially remains idle and then commences service for Ship 2 mid-way through its stay; subsequently, it transitions to serve Ship 4. After completing the service, the quay crane stops working. It resumes service at 00:00 the following day to assist Ship 11 and ceases operation upon completion of this service. Quay Cranes 5, 6, and 7 also implement time-variant allocation. To ensure that Ship 12 departs on schedule, they cease service after a designated period of unloading and loading for Ship 12, thereby reducing the operational costs associated with the quay cranes.</p>
<fig id="F6" position="float">
<label>FIGURE 6</label>
<caption>
<p>Quay crane allocation diagram.</p>
</caption>
<graphic xlink:href="fieng-03-1523203-g006.tif"/>
</fig>
</sec>
<sec id="s5-2">
<title>5.2 Q-learning algorithm for result optimization discussion</title>
<p>
<xref ref-type="sec" rid="s4">Section 4</xref> describes our use of the Q-learning algorithm to select genetic operators, which enhances the search speed of the algorithm. However, it is also possible to optimize the algorithm without using the Q-learning algorithm. To demonstrate the effectiveness of the Q-learning algorithm, we have designed two genetic operator selection methods for comparative analysis: random selection and selection using the Q-learning algorithm. We conducted five sets of experiments, with the number of quay cranes set at eight and a maximum of 3,000 iterations for the algorithm. Each operator&#x2019;s results were run five times. The experimental results are shown in <xref ref-type="table" rid="T6">Table 6</xref>.</p>
<table-wrap id="T6" position="float">
<label>TABLE 6</label>
<caption>
<p>Comparison of optimization with and without Q-learning.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th align="center"/>
<th colspan="2" align="center">No Q-learning optimization</th>
<th colspan="3" align="center">With Q-learning optimization</th>
</tr>
<tr>
<th align="center">Number of ships</th>
<th align="center">Target value (CNY)</th>
<th align="center">Running time (s)</th>
<th align="center">Target value (CNY)</th>
<th align="center">Running time (s)</th>
<th align="center">GAP</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="center">10</td>
<td align="center">23,311</td>
<td align="center">112</td>
<td align="center">23,392</td>
<td align="center">61</td>
<td align="center">&#x2212;0.35%</td>
</tr>
<tr>
<td align="center">20</td>
<td align="center">41,675</td>
<td align="center">168</td>
<td align="center">40,648</td>
<td align="center">82</td>
<td align="center">2.53%</td>
</tr>
<tr>
<td align="center">30</td>
<td align="center">73,428</td>
<td align="center">234</td>
<td align="center">71,379</td>
<td align="center">96</td>
<td align="center">2.87%</td>
</tr>
<tr>
<td align="center">40</td>
<td align="center">85,301</td>
<td align="center">312</td>
<td align="center">82,301</td>
<td align="center">116</td>
<td align="center">3.65%</td>
</tr>
<tr>
<td align="center">50</td>
<td align="center">11,081</td>
<td align="center">426</td>
<td align="center">10,653</td>
<td align="center">127</td>
<td align="center">4.02%</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>The comparison results indicate that the performance gap between the two algorithms is minimal when the number of ships is low. However, as the number of ships increases, the optimization capability of the Q-learning-assisted algorithm is significantly superior to that of the random selection method. This is attributed to the fact that with a smaller number of ships, the algorithm&#x2019;s complexity is manageable. In contrast, as the number of ships grows, the random selection method introduces uncertainty and a higher likelihood of becoming trapped in local optima. The algorithm optimized with Q-learning also exhibits a reduced running time, demonstrating its superior search capabilities.</p>
</sec>
<sec id="s5-3">
<title>5.3 Algorithm effectiveness analysis</title>
<p>To verify the effectiveness of the algorithm presented in this article, we compare it with the CPLEX solver and genetic algorithm. The genetic algorithm adopts the traditional crossover and mutation logic and simultaneously performs crossover and mutation operations on the three layers of codes. We calculate the average of five runs for each algorithm under various scenarios, with the final results presented in <xref ref-type="table" rid="T7">Table 7</xref>. Given the difficulty of solving large-scale problems with CPLEX, we impose a 3-hour time limit on the solver, terminating it after this duration. The gap calculationformula is defined as follows, taking the genetic algorithm shown in <xref ref-type="disp-formula" rid="e34">Equation 34</xref> as an example:<disp-formula id="e34">
<mml:math id="m184">
<mml:mrow>
<mml:mi>G</mml:mi>
<mml:mi>A</mml:mi>
<mml:mi>P</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mfrac>
<mml:mrow>
<mml:mi>O</mml:mi>
<mml:mi>b</mml:mi>
<mml:msub>
<mml:mi>j</mml:mi>
<mml:mtext>cplex</mml:mtext>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:mi>O</mml:mi>
<mml:mi>b</mml:mi>
<mml:msub>
<mml:mi>j</mml:mi>
<mml:mrow>
<mml:mi>G</mml:mi>
<mml:mi>A</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
<mml:mrow>
<mml:mi>O</mml:mi>
<mml:mi>b</mml:mi>
<mml:msub>
<mml:mi>j</mml:mi>
<mml:mrow>
<mml:mi>G</mml:mi>
<mml:mi>A</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfrac>
<mml:mo>&#xd7;</mml:mo>
<mml:mn>100</mml:mn>
<mml:mo>%</mml:mo>
<mml:mo>.</mml:mo>
</mml:mrow>
</mml:math>
<label>(34)</label>
</disp-formula>
</p>
<table-wrap id="T7" position="float">
<label>TABLE 7</label>
<caption>
<p>Performance of different algorithms in the examples.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th align="left"/>
<th colspan="2" align="center">CPLEX</th>
<th colspan="4" align="center">Genetic algorithm</th>
<th colspan="4" align="center">Algorithms in this article</th>
</tr>
<tr>
<th align="left">Number of ships &#xd7; Number of bridges</th>
<th align="left">Cost (CNY)</th>
<th align="left">Running times (s)</th>
<th align="left">Average cost (CNY)</th>
<th align="left">Optimal cost (CNY)</th>
<th align="left">GAP</th>
<th align="left">Running times (s)</th>
<th align="left">Average cost (CNY)</th>
<th align="left">Optimal cost (CNY)</th>
<th align="left">GAP</th>
<th align="left">Running times (s)</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="left">10 &#xd7; 5</td>
<td align="left">242,410</td>
<td align="left">6,760</td>
<td align="left">266,880</td>
<td align="left">264,230</td>
<td align="left">8.3%</td>
<td align="left">87</td>
<td align="left">248,180</td>
<td align="left">245,720</td>
<td align="left">1.3%</td>
<td align="left">61</td>
</tr>
<tr>
<td align="left">10 &#xd7; 10</td>
<td align="left">233,920</td>
<td align="left">10,780</td>
<td align="left">255,300</td>
<td align="left">252,770</td>
<td align="left">7.5%</td>
<td align="left">83</td>
<td align="left">238,690</td>
<td align="left">236,320</td>
<td align="left">1.0%</td>
<td align="left">57</td>
</tr>
<tr>
<td align="left">10 &#xd7; 15</td>
<td align="left">262,600</td>
<td align="left">15,300</td>
<td align="left">287,060</td>
<td align="left">284,210</td>
<td align="left">7.6%</td>
<td align="left">88</td>
<td align="left">268,410</td>
<td align="left">265,750</td>
<td align="left">1.2%</td>
<td align="left">68</td>
</tr>
<tr>
<td align="left">20 &#xd7; 8</td>
<td align="left">415,630</td>
<td align="left">18,000</td>
<td align="left">455,640</td>
<td align="left">451,120</td>
<td align="left">7.9%</td>
<td align="left">103</td>
<td align="left">421,910</td>
<td align="left">417,730</td>
<td align="left">0.5%</td>
<td align="left">72</td>
</tr>
<tr>
<td align="left">20 &#xd7; 10</td>
<td align="left">406,480</td>
<td align="left">18,000</td>
<td align="left">444,930</td>
<td align="left">440,520</td>
<td align="left">7.7%</td>
<td align="left">112</td>
<td align="left">413,820</td>
<td align="left">409,720</td>
<td align="left">0.8%</td>
<td align="left">84</td>
</tr>
<tr>
<td align="left">20 &#xd7; 15</td>
<td align="left">427,620</td>
<td align="left">18,000</td>
<td align="left">468,080</td>
<td align="left">464,440</td>
<td align="left">7.9%</td>
<td align="left">114</td>
<td align="left">433,810</td>
<td align="left">429,510</td>
<td align="left">0.4%</td>
<td align="left">84</td>
</tr>
<tr>
<td align="left">30 &#xd7; 7</td>
<td align="left">736,430</td>
<td align="left">18,000</td>
<td align="left">810,260</td>
<td align="left">802,230</td>
<td align="left">8.2%</td>
<td align="left">138</td>
<td align="left">739,800</td>
<td align="left">732,470</td>
<td align="left">&#x2212;0.5%</td>
<td align="left">106</td>
</tr>
<tr>
<td align="left">30 &#xd7; 10</td>
<td align="left">713,790</td>
<td align="left">18,000</td>
<td align="left">784,160</td>
<td align="left">776,390</td>
<td align="left">8.1%</td>
<td align="left">111</td>
<td align="left">716,810</td>
<td align="left">709,710</td>
<td align="left">&#x2212;0.6%</td>
<td align="left">92</td>
</tr>
<tr>
<td align="left">30 &#xd7; 15</td>
<td align="left">714,730</td>
<td align="left">18,000</td>
<td align="left">784,800</td>
<td align="left">777,020</td>
<td align="left">8.0%</td>
<td align="left">119</td>
<td align="left">715,800</td>
<td align="left">708,710</td>
<td align="left">&#x2212;0.8%</td>
<td align="left">117</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>From <xref ref-type="table" rid="T7">Table 7</xref>, it can be found that when the number of quay cranes is constant, as the number of ships increases, the overall cost and solution time of the ships will increase accordingly. This is because an increase in the number of ships leads to an increase in the complexity and workload of loading and unloading operations, which increases the overall cost and solution time. In terms of cost, our proposed algorithm demonstrates lower costs across all examples, with its optimal costs significantly lower than those of the genetic algorithm. In comparison with CPLEX, our algorithm has a significantly lower GAP value than the genetic algorithm, indicating that its cost is much closer to the optimal cost. In certain large-scale scenarios (for example, 30 &#xd7; 5 and 30 &#xd7; 10), our proposed algorithm&#x2019;s GAP is negative, indicating that its performance surpasses that of CPLEX, which is limited by time constraints. This further confirms the superior search capability of our algorithm in handling large-scale cases.</p>
<p>In <xref ref-type="table" rid="T7">Table 7</xref>, &#x201c;Running time/s&#x201d; refers to the computational time required to complete the optimization process, measured in seconds. This metric is used to evaluate the efficiency of the proposed method. The running time of our proposed algorithm is generally lower than that of the genetic algorithm and much lower than that of CPLEX, which reflects the high computational efficiency. Q-learning effectively reduces the running time by introducing a dynamic mechanism for operator selection. Q-learning leverages the performance of past iterations to dynamically adapt the selection of genetic operators. This ensures that only the most effective operators are utilized at each stage of the optimization process, thereby avoiding low-efficiency operations and reducing unnecessary computational effort. In summary, the algorithm proposed in this article offers significant advantages in terms of solution speed and accuracy.</p>
</sec>
</sec>
<sec id="s6">
<title>6 Conclusion and future work</title>
<p>In this article, the joint berth and time-variant quay crane allocation problem is addressed. This is a cooperative allocation problem where the allocation of quay cranes can vary over time, allowing cranes to serve other ships even if a ship&#x2019;s operation is not yet complete. To solve this problem, a new MIP model is constructed, with the objective of minimizing ship delay costs, quay crane movement costs, and quay crane service costs while considering constraints such as quay crane working range and collision avoidance. A joint berth and time-variant quay crane allocation algorithm based on Q-learning is proposed, with a genetic algorithm as the main framework. The quay crane allocation module is embedded, and genetic operators are selected using the Q-learning algorithm. Q-learning is employed to evaluate the current population state and guide the generation of new solutions, enhancing optimization performance. This approach addresses the time-variant quay crane allocation problem by considering both crane and berth allocations to improve port resource utilization.</p>
<p>The results of the data analysis indicate that: 1) The method presented in this article can simultaneously address the continuous berth and time-variant quay crane allocation problems, reducing the total port cost. 2) The Q-learning selection module in this article can both accelerate the algorithm&#x2019;s convergence and enhance its search capability. 3) The algorithm proposed in this article outperforms the traditional genetic algorithm in terms of convergence speed and optimization ability in different scale examples. In small-scale examples, the proposed algorithm&#x2019;s performance is close to the exact solutions provided by CPLEX, and in some cases, it even surpasses the CPLEX algorithm when time constraints are applied, demonstrating the feasibility and superiority of our approach.</p>
<p>Future research could consider the following directions: 1) Incorporating the movement time of quay cranes into the model. 2) Extending the algorithm proposed in this article to include time-variant scheduling planning for automated guided vehicles, quay cranes, and berths within ports. 3) Future research may also incorporate the considerations of import and export container flows, along with a broader range of intricate factors that could influence port operations.</p>
</sec>
</body>
<back>
<sec sec-type="data-availability" id="s7">
<title>Data availability statement</title>
<p>The original contributions presented in the study are included in the article/supplementary material; further inquiries can be directed to the corresponding author.</p>
</sec>
<sec sec-type="author-contributions" id="s8">
<title>Author contributions</title>
<p>CL: conceptualization, methodology, formal analysis, writing&#x2013;original draft. DT: investigation, data curation, writing&#x2013;original draft. RZ: investigation, methodology, writing&#x2013;review and editing. YW: writing-review and editing, methodology, investigation. </p>
</sec>
<sec sec-type="funding-information" id="s9">
<title>Funding</title>
<p>The author(s) declare that financial support was received for the research, authorship, and/or publication of this article. National Natural Science Foundation of China (72271125) Shanghai Sailing Program (21YF1416400) Shanghai Rising-Star Program (21QB1404800).</p>
</sec>
<sec sec-type="COI-statement" id="s10">
<title>Conflict of interest</title>
<p>The authors declare that the research was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.</p>
</sec>
<sec sec-type="ai-statement" id="s11">
<title>Generative AI statement</title>
<p>The author(s) declare that no Generative AI was used in the creation of this manuscript.</p>
</sec>
<sec sec-type="disclaimer" id="s12">
<title>Publisher&#x2019;s note</title>
<p>All claims expressed in this article are solely those of the authors and do not necessarily represent those of their affiliated organizations, or those of the publisher, the editors and the reviewers. Any product that may be evaluated in this article, or claim that may be made by its manufacturer, is not guaranteed or endorsed by the publisher.</p>
</sec>
<ref-list>
<title>References</title>
<ref id="B1">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Agra</surname>
<given-names>A.</given-names>
</name>
<name>
<surname>Oliveira</surname>
<given-names>M.</given-names>
</name>
</person-group> (<year>2018</year>). <article-title>MIP approaches for the integrated berth allocation and quay crane assignment and scheduling problem</article-title>. <source>Eur. J. Operational Res.</source> <volume>264</volume> (<issue>1</issue>), <fpage>138</fpage>&#x2013;<lpage>148</lpage>. <pub-id pub-id-type="doi">10.1016/j.ejor.2017.05.040</pub-id>
</citation>
</ref>
<ref id="B2">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Chang</surname>
<given-names>D.</given-names>
</name>
<name>
<surname>Jiang</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Yan</surname>
<given-names>W.</given-names>
</name>
<name>
<surname>He</surname>
<given-names>J.</given-names>
</name>
</person-group> (<year>2010</year>). <article-title>Integrating berth allocation and quay crane assignments</article-title>. <source>Transp. Res. Part E Logist. Transp. Rev.</source> <volume>46</volume> (<issue>6</issue>), <fpage>975</fpage>&#x2013;<lpage>990</lpage>. <pub-id pub-id-type="doi">10.1016/j.tre.2010.05.008</pub-id>
</citation>
</ref>
<ref id="B3">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Correcher</surname>
<given-names>J. F.</given-names>
</name>
<name>
<surname>Alvarez-Valdes</surname>
<given-names>R.</given-names>
</name>
</person-group> (<year>2017</year>). <article-title>A biased random-key genetic algorithm for the time-invariant berth allocation and quay crane assignment problem</article-title>. <source>Expert Syst. Appl.</source> <volume>89</volume>, <fpage>112</fpage>&#x2013;<lpage>128</lpage>. <pub-id pub-id-type="doi">10.1016/j.eswa.2017.07.028</pub-id>
</citation>
</ref>
<ref id="B4">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Correcher</surname>
<given-names>J. F.</given-names>
</name>
<name>
<surname>Alvarez-Valdes</surname>
<given-names>R.</given-names>
</name>
<name>
<surname>Tamarit</surname>
<given-names>J. M.</given-names>
</name>
</person-group> (<year>2019</year>). <article-title>New exact methods for the time-invariant berth allocation and quay crane assignment problem</article-title>. <source>Eur. J. Operational Res.</source> <volume>275</volume> (<issue>1</issue>), <fpage>80</fpage>&#x2013;<lpage>92</lpage>. <pub-id pub-id-type="doi">10.1016/j.ejor.2018.11.007</pub-id>
</citation>
</ref>
<ref id="B5">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Hanagandi</surname>
<given-names>V.</given-names>
</name>
<name>
<surname>Nikolaou</surname>
<given-names>M.</given-names>
</name>
</person-group> (<year>1998</year>). <article-title>A hybrid approach to global optimization using a clustering algorithm in a genetic search framework</article-title>. <source>Comput. and Chem. Eng.</source> <volume>22</volume> (<issue>12</issue>), <fpage>1913</fpage>&#x2013;<lpage>1925</lpage>. <pub-id pub-id-type="doi">10.1016/s0098-1354(98)00251-8</pub-id>
</citation>
</ref>
<ref id="B6">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Ji</surname>
<given-names>B.</given-names>
</name>
<name>
<surname>Tang</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Wu</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Yu</surname>
<given-names>S. S.</given-names>
</name>
<name>
<surname>Zhou</surname>
<given-names>S.</given-names>
</name>
<name>
<surname>Fang</surname>
<given-names>X.</given-names>
</name>
</person-group> (<year>2022</year>). <article-title>Hybrid rolling-horizon optimization for berth allocation and quay crane assignment with unscheduled vessels</article-title>. <source>Adv. Eng. Inf.</source> <volume>54</volume>, <fpage>101733</fpage>. <pub-id pub-id-type="doi">10.1016/j.aei.2022.101733</pub-id>
</citation>
</ref>
<ref id="B7">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Karam</surname>
<given-names>A.</given-names>
</name>
<name>
<surname>Eltawil</surname>
<given-names>A. B.</given-names>
</name>
</person-group> (<year>2016</year>). <article-title>Functional integration approach for the berth allocation, quay crane assignment and specific quay crane assignment problems</article-title>. <source>Comput. and Industrial Eng.</source> <volume>102</volume>, <fpage>458</fpage>&#x2013;<lpage>466</lpage>. <pub-id pub-id-type="doi">10.1016/j.cie.2016.04.006</pub-id>
</citation>
</ref>
<ref id="B8">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Krimi</surname>
<given-names>I.</given-names>
</name>
<name>
<surname>Todosijevi&#x107;</surname>
<given-names>R.</given-names>
</name>
<name>
<surname>Benmansour</surname>
<given-names>R.</given-names>
</name>
<name>
<surname>Ratli</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>El Cadi</surname>
<given-names>A. A.</given-names>
</name>
<name>
<surname>Aloullal</surname>
<given-names>A.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>Modelling and solving the multi-quays berth allocation and crane assignment problem with availability constraints</article-title>. <source>J. Glob. Optim.</source> <volume>78</volume>, <fpage>349</fpage>&#x2013;<lpage>373</lpage>. <pub-id pub-id-type="doi">10.1007/s10898-020-00884-1</pub-id>
</citation>
</ref>
<ref id="B9">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Liang</surname>
<given-names>C.</given-names>
</name>
<name>
<surname>Guo</surname>
<given-names>J.</given-names>
</name>
<name>
<surname>Yang</surname>
<given-names>Y.</given-names>
</name>
</person-group> (<year>2011</year>). <article-title>Multi-objective hybrid genetic algorithm for quay crane dynamic assignment in berth allocation planning</article-title>. <source>J. Intelligent Manuf.</source> <volume>22</volume>, <fpage>471</fpage>&#x2013;<lpage>479</lpage>. <pub-id pub-id-type="doi">10.1007/s10845-009-0304-8</pub-id>
</citation>
</ref>
<ref id="B10">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Liu</surname>
<given-names>M.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>Research on port infrastructure, port efficiency and urban trade development</article-title>. <source>J. Coast. Res.</source> <volume>115</volume> (<issue>SI</issue>), <fpage>220</fpage>&#x2013;<lpage>222</lpage>. <pub-id pub-id-type="doi">10.2112/jcr-si115-069.1</pub-id>
</citation>
</ref>
<ref id="B11">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Lu</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Han</surname>
<given-names>X.</given-names>
</name>
<name>
<surname>Xi</surname>
<given-names>L.</given-names>
</name>
</person-group> (<year>2011</year>). <article-title>Simultaneous berth and quay crane allocation problem in container terminal</article-title>. <source>Adv. Sci. Lett.</source> <volume>4</volume> (<issue>6-7</issue>), <fpage>2113</fpage>&#x2013;<lpage>2118</lpage>. <pub-id pub-id-type="doi">10.1166/asl.2011.1533</pub-id>
</citation>
</ref>
<ref id="B12">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Lujan</surname>
<given-names>E.</given-names>
</name>
<name>
<surname>Vergara</surname>
<given-names>E.</given-names>
</name>
<name>
<surname>Rodriguez-Melquiades</surname>
<given-names>J.</given-names>
</name>
<name>
<surname>Jim&#xe9;nez-Carri&#xf3;n</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Sabino-Escobar</surname>
<given-names>C.</given-names>
</name>
<name>
<surname>Gutierrez</surname>
<given-names>F.</given-names>
</name>
</person-group> (<year>2021</year>). <article-title>A fuzzy optimization model for the berth allocation problem and quay crane allocation problem (BAP&#x2b; QCAP) with n quays</article-title>. <source>J. Mar. Sci. Eng.</source> <volume>9</volume> (<issue>2</issue>), <fpage>152</fpage>. <pub-id pub-id-type="doi">10.3390/jmse9020152</pub-id>
</citation>
</ref>
<ref id="B13">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Malekahmadi</surname>
<given-names>A.</given-names>
</name>
<name>
<surname>Alinaghian</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Hejazi</surname>
<given-names>S. R.</given-names>
</name>
<name>
<surname>Assl Saidipour</surname>
<given-names>M. A.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>Integrated continuous berth allocation and quay crane assignment and scheduling problem with time-dependent physical constraints in container terminals</article-title>. <source>Comput. and Industrial Eng.</source> <volume>147</volume>, <fpage>106672</fpage>. <pub-id pub-id-type="doi">10.1016/j.cie.2020.106672</pub-id>
</citation>
</ref>
<ref id="B14">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Meisel</surname>
<given-names>F.</given-names>
</name>
<name>
<surname>Bierwirth</surname>
<given-names>C.</given-names>
</name>
</person-group> (<year>2009</year>). <article-title>Heuristics for the integration of crane productivity in the berth allocation problem</article-title>. <source>Transp. Res. Part E Logist. Transp. Rev.</source> <volume>45</volume> (<issue>1</issue>), <fpage>196</fpage>&#x2013;<lpage>209</lpage>. <pub-id pub-id-type="doi">10.1016/j.tre.2008.03.001</pub-id>
</citation>
</ref>
<ref id="B15">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Ng</surname>
<given-names>W. C.</given-names>
</name>
<name>
<surname>Mak</surname>
<given-names>K. L.</given-names>
</name>
</person-group> (<year>2006</year>). <article-title>Quay crane scheduling in container terminals</article-title>. <source>Eng. Optim.</source> <volume>38</volume> (<issue>6</issue>), <fpage>723</fpage>&#x2013;<lpage>737</lpage>. <pub-id pub-id-type="doi">10.1080/03052150600691038</pub-id>
</citation>
</ref>
<ref id="B16">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Park</surname>
<given-names>Y. M.</given-names>
</name>
<name>
<surname>Kim</surname>
<given-names>K. H.</given-names>
</name>
</person-group> (<year>2003</year>). <article-title>A scheduling method for berth and quay cranes</article-title>. <source>OR Spectr.</source> <volume>25</volume> (<issue>1</issue>), <fpage>1</fpage>&#x2013;<lpage>23</lpage>. <pub-id pub-id-type="doi">10.1007/s00291-002-0109-z</pub-id>
</citation>
</ref>
<ref id="B17">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Pham</surname>
<given-names>V. H. S.</given-names>
</name>
<name>
<surname>Nguyen Dang</surname>
<given-names>N. T.</given-names>
</name>
<name>
<surname>Nguyen</surname>
<given-names>V. N.</given-names>
</name>
</person-group> (<year>2024</year>). <article-title>Enhancing engineering optimization using hybrid sine cosine algorithm with Roulette wheel selection and opposition-based learning</article-title>. <source>Sci. Rep.</source> <volume>14</volume> (<issue>1</issue>), <fpage>694</fpage>. <pub-id pub-id-type="doi">10.1038/s41598-024-51343-w</pub-id>
</citation>
</ref>
<ref id="B18">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Thanos</surname>
<given-names>E.</given-names>
</name>
<name>
<surname>Toffolo</surname>
<given-names>T.</given-names>
</name>
<name>
<surname>Santos</surname>
<given-names>H. G.</given-names>
</name>
<name>
<surname>Vancroonenburg</surname>
<given-names>W.</given-names>
</name>
<name>
<surname>Vanden Berghe</surname>
<given-names>G.</given-names>
</name>
</person-group> (<year>2021</year>). <article-title>The tactical berth allocation problem with time-variant specific quay crane assignments</article-title>. <source>Comput. and Industrial Eng.</source> <volume>155</volume>, <fpage>107168</fpage>. <pub-id pub-id-type="doi">10.1016/j.cie.2021.107168</pub-id>
</citation>
</ref>
<ref id="B19">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>T&#xfc;rko&#x11f;ullar&#x131;</surname>
<given-names>Y. B.</given-names>
</name>
<name>
<surname>Ta&#x15f;k&#x131;n</surname>
<given-names>Z. C.</given-names>
</name>
<name>
<surname>Aras</surname>
<given-names>N.</given-names>
</name>
<name>
<surname>Alt&#x131;nel</surname>
<given-names>&#x130;. K.</given-names>
</name>
</person-group> (<year>2014</year>). <article-title>Optimal berth allocation and time-invariant quay crane assignment in container terminals</article-title>. <source>Eur. J. Operational Res.</source> <volume>235</volume> (<issue>1</issue>), <fpage>88</fpage>&#x2013;<lpage>101</lpage>. <pub-id pub-id-type="doi">10.1016/j.ejor.2013.10.015</pub-id>
</citation>
</ref>
<ref id="B20">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Wang</surname>
<given-names>Y. H.</given-names>
</name>
<name>
<surname>Li</surname>
<given-names>T. H. S.</given-names>
</name>
<name>
<surname>Lin</surname>
<given-names>C. J.</given-names>
</name>
</person-group> (<year>2013</year>). <article-title>Backward Q-learning: the combination of Sarsa algorithm and Q-learning</article-title>. <source>Eng. Appl. Artif. Intell.</source> <volume>26</volume> (<issue>9</issue>), <fpage>2184</fpage>&#x2013;<lpage>2193</lpage>. <pub-id pub-id-type="doi">10.1016/j.engappai.2013.06.016</pub-id>
</citation>
</ref>
<ref id="B21">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Zheng</surname>
<given-names>F.</given-names>
</name>
<name>
<surname>Pang</surname>
<given-names>Y.</given-names>
</name>
<name>
<surname>Liu</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Xu</surname>
<given-names>Y.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>Dynamic programming algorithms for the general quay crane double-cycling problem with internal-reshuffles</article-title>. <source>J. Comb. Optim.</source> <volume>39</volume>, <fpage>708</fpage>&#x2013;<lpage>724</lpage>. <pub-id pub-id-type="doi">10.1007/s10878-019-00508-9</pub-id>
</citation>
</ref>
</ref-list>
</back>
</article>