## 4 Algorithm Design
### Hybrid Ant Colony Optimization Algorithm
#### 4.2.2 Solution Construction  
1. Feasible access node set generation  
Given the close relationship between electric vehicles and CI, this paper enhances the initial solution construction method of the classical ant colony algorithm for traditional vehicle routing problems. We propose a feasible access node set that adheres to constraints such as battery capacity, vehicle load, and maximum route duration, storing potential target nodes for subsequent access. For ant \(k\), the feasible access node set is denoted as \(allow_{k}\), which dynamically updates based on the current path construction status. In the EVRP-HERI-CC, nodes are categorized into customer points and energy replenishment infrastructures. Thus, multiple transition scenarios arise between different types of nodes \(i\) and \(j\). Additionally, due to constraints such as limited battery capacity, cargo load, and maximum driver shift duration, the generation of \(allow_{k}\) must satisfy multiple conditions to ensure route feasibility. To address this, we systematically decompose the target nodes and transition scenarios by designing three node lists to store different categories of accessible nodes. The complete \(allow_{k}\) is then obtained through a concatenation approach. Define \(UC\) and \(D\) to represent unserved customer points and the depot, respectively. Let \(i\) be the last node in the currently constructed partial route \(r\), where \(z_{i}\), \(sumq_{i}\), and \(\tau_{i}\) represent the remaining battery level upon departure from \(i\), the total demand satisfied upon arrival at \(i\), and the arrival time at \(i\), respectively. The node inserted after \(i\) may be either a customer point \(c\) or a CI/BSI \(s\). The vehicle may return to the depot from \(c\) or \(s\), provided that all feasibility constraints are satisfied during subsequent route construction. We formally define the node lists as \(N_{UC}\), \(N_{CI}\), and \(N_{BSI}\), which collectively constitute the feasible access node set \(allow_{k}\). We take \(N_{UC}\) as an example to explain the meanings of its internal sub-node lists. A vehicle travels from the last point \(i\) of the current route to an unserved customer point, which is stored in \(N_{UC}\). The distinction lies in the following: for \(N_{UC1}\), the vehicle can return directly to the depot after servicing the customer point, whereas for \(N_{UC2}\) and \(N_{UC3}\), the vehicle can proceed to a CI or a BSI, respectively, for energy replenishment before  
Figure 6: Flowchart of the HACO algorithm. returning to the depot. Similar logic applies to \(N_{CI}\) and \(N_{BSI}\). The constraints to be satisfied under different conditions are shown in Equations (38)-(40). \[N_{UC}=\left\{\begin{array}{c}N_{UC1}=\left\{ \begin{array}{c}h*(d_{ic}+d_{c 0})\leq z_{i}\\ sumq_{i}+q_{c}\leq q_{v}\\ \tau_{i}+t_{ic}+s_{c}+t_{c0}\leq T_{max}\end{array} \right\},if\;UC\to D\; directly\\ N_{UC2}=\left\{ \begin{array}{c}h*(d_{ic}+d_{cs})\leq z_{i}\\ h*d_{s0}\leq z_{s}\\ sumq_{i}+q_{c}\leq q_{v}\\ \tau_{i}+t_{ic}+s_{c}+t_{cs}+s\
eq\theta_{s}+t_{s0}\leq T_{max}\end{array}  \right\},if\;UC\to CI\to D\\ N_{UC3}=\left\{ \begin{array}{c}h*(d_{ic}+d_{cs})\leq z_{i}\\ h*d_{s0}\leq z_{s}\\ sumq_{i}+q_{c}\leq q_{v}\\ \tau_{i}+t_{ic}+s_{c}+t_{cs}+t_{bs}+t_{s0}\leq T_{max}\end{array} \right\},if \;UC\to BSI\to D\\ \\ N_{CI}=\left\{\begin{array}{c}N_{CI1}=\left\{ \begin{array}{c}h*d_{is}\leq z_ {i}\\ h*d_{s0}\leq z_{s}\\ \tau_{i}+t_{is}+g*\theta_{s}+t_{s0}\leq T_{max}\end{array} \right\},if\;CI\to depot \;directly\\ N_{CI2}=\left\{ \begin{array}{c}h*d_{is}\leq z_{i}\\ h*(d_{sc}+d_{c0})\leq z_{s}\\ sumq_{i}+q_{c}\leq q_{v}\\ \tau_{i}+t_{is}+g*\theta_{s}+t_{sc}+s_{c}+t_{c0}\leq T_{max}\end{array} \right\},if\;CI\to UC\to D\\ \\ N_{BSI}=\left\{