## 3 Materials and Methods
### Proposed Adaptive Large Neighborhood Search
```
Input:\(S^{initial}\), \(\Omega^{-}\), \(\Omega^{+}\), \(\Omega^{LS}\), \(N\), \(K\), \(Z\), \(T_{0}\), \(a\) Initialize \(i\), \(j\), \(w^{+}\), \(w^{-}\), \(w^{LS}\), \(p^{-}\), \(p^{+}\), \(p^{LS}\) \(S^{best}\leftarrow\)\(S^{initial}\), \(S^{new}\gets S^{initial}\), \(S^{current}\gets S^{initial}\) \(T\gets T_{0}\), \(i\gets 1\), \(j\gets 0\) repeat if\(i==0\) (mod \(K\)) then Select route _removal_ operator \(\Omega^{-}\) using Roulette Wheel Selection Select customer _insertion_ operator \(\Omega^{+}\) using Roulette Wheel Selection \(S^{new}\gets insert\big{(}remove\big{(}S^{current}\big{)}\big{)}\) else if\(j==0\) (mod \(N\)) then Select station _removal_ operator \(\Omega^{-}\) using Roulette Wheel Selection Select station _insertion_ operator \(\Omega^{+}\) using Roulette Wheel Selection \(S^{new}\gets insert\big{(}remove\big{(}S^{current}\big{)}\big{)}\) else Select customer _removal_ operator \(\Omega^{-}\) using Roulette Wheel Selection  Select customer _insertion_ operator \(\Omega^{+}\) using Roulette Wheel Selection \(S^{new}\gets insert\big{(}remove\big{(}S^{current}\big{)}\big{)}\) endif endif acceptance rate \(\gets e^{(-(f(S^{new})-f(S^{current}))/T)}\) if\(f(S^{new})<\)\(f(S^{current})\) or acceptance rate > _random_(0,1) then \(S^{current}\gets S^{new}\) if\(f(S^{current})<\)\(f(S^{best})\)then \(S^{best}\gets S^{current}\) endif \(j\gets 0\) else \(j\gets j+1\) endif if\(i==0\) (mod \(\beta\)) then \(S^{current}\leftarrow\) Apply VNS-Based Local Search Procedure endif if\(i==0\) (mod \(Z\)) then Update \(w^{+}\), \(w^{-}\), \(w^{LS}\) with scores \(p^{-}\), \(p^{+}\), \(p^{LS}\) endif \(T\gets T\) * \(a\) \(i\gets i+1\) untilstopping criteria is met; return\(S^{best}\)
```  
**Algorithm 1** Proposed hybrid ALNS algorithm  
The calculation of tardiness for customer nodes is as follows:  
\[\min\sum_{j=1}^{n}T_{j}\;j\in C \tag{1}\]  
\[T_{j}=\max\big{\{}0,a_{j}-1_{j}\big{\}}\;j\in C \tag{2}\]  
\[a_{j+1}=a_{j}+s_{j}+t_{j}+t_{j+1}\;j\in C \tag{3}\]  
\[a_{j+1}=a_{j}+tch_{j}+t_{j+1}\;j\in CS \tag{4}\]  
The objective function is given in Equation (1), minimizing the total tardiness while considering customers' time windows. \(T_{j}\) represents the tardiness of customer node \(j\). If the vehicle arrives at the customer within the time window, tardiness will be zero. Otherwise, tardiness occurs up to \(T_{j}\) (Equation (2)). Equations (3) and (4) define the calculation of arrival time based on whether the previous node is a customer or a charging station. In Equation (3), \(a_{j}\) is the arrival time at node \(j\), \(s_{j}\) is the service time at node \(j\), \(l_{j}\) is the latest start time to service value, and \(tt_{j,\,j+1}\) is the travel time between node \(j\) and node \(j+1\) (\(j\in C\); \(C\) denotes the set of customers). In Equation (4), \(tch_{j}\) represents the charging time at node \(j\) (\(j\in CS\); \(CS\) denotes the set of charging stations). According to the obtained cost value, new solutions are accepted using the temperature-dependent Simulated Annealing (SA) acceptance criterion. The new solutions must respect the constraint in Equation (5) regarding battery capacity. \[\text{SoC}_{\text{j}}>0 \tag{5}\]  
If Equation (5) is not satisfied, the new solution is rejected. \(SoC_{j}\) represents the state of charge at node \(j\). The updated charge level at the next node \(j+1\) is calculated as shown in Equation (6), where \(ecr\) represents the energy consumption rate and \(d_{j,\,j+1}\) represents the distance between nodes \(j\) and \(j+1\). \[\text{SoC}_{\text{j+1}}=\text{SoC}_{\text{j}}-\left(\text{ecr}\times\text{d}_ {\text{j+1}}\right) \tag{6}\]  
Then, the algorithm expands the solution space with local search (LS) methods. It continues these operations until the stopping criterion is met. In order to use the operator structures efficiently, the algorithm updates the weights \(w^{-}\), \(w^{+}\), \(w^{Ls}\) using the \(p^{-}\), \(p^{+}\), \(p^{LS}\) scores obtained every \(Z\) iteration.