## 4 Solution Method
### A White-Box Neural Network Approach for Travel Time Estimation  
The proposed neural network does not estimate the total trajectory time directly. Instead, it calculates the travel time for each segment, summing them to obtain the total time. This modular approach efficiently handles dynamic conditions and nonlinear interactions. The network takes six input features describing the arc and UAV conditions: UAV speed \(v_{\text{drone}}\), segment distance \(d\), segment direction angle \(\theta_{\text{dist}}\), wind speed \(v_{\text{wind}}\), wind direction \(\theta_{\text{wind}}\), payload weight \(w_{\text{payload}}\).  
The network consists of three fully connected hidden layers (Figure 7): layer 1 with 64 neurons, layer 2 with 64 neurons, and layer 3 with 32 neurons. Each layer uses the ReLU activation function to introduce nonlinearity. The final layer produces a single value representing the estimated travel time for the segment. The network contains approximately \(64,000\) parameters, balancing learning capacity and computational efficiency. For each segment in an A*-generated path, the actual travel time is computed using the physical model. The dataset includes UAV speed, segment distance, angles, wind conditions, and payload weight.  
The neural network was trained using a carefully designed process to ensure a balance between accuracy and efficiency. Data preprocessing involved standard normalization and an 80/20 train-test split, with no additional feature engineering. The model was trained using the Adam optimizer with a learning rate of 0.001, a batch size of 10, and early stopping based on validation loss. The training was conducted on a PyTorch ([[https://pytorch.org/](https://pytorch.org/)]([https://pytorch.org/](https://pytorch.org/))) setup with an Intel Core i7-1280P processor, requiring under 1 GB of RAM and taking about 2 to 3 min per full training cycle for larger datasets. An iterative refinement strategy was applied, where the model was initially trained on synthetic data, then progressively retrained with added examples based on discrepancies between predicted and simulated travel times. For a 21-node problem instance, stable performance was typically reachedafter 20 to 30 iterations, with RMSE improving from 0.70 to 0.40 or lower, and in some cases as low as 0.22. Even after 5 to 10 iterations, the model achieved sufficient accuracy for practical route planning. The average computational time per iteration--including path generation, simulation, and training--was approximately 65 s on the test hardware.  
The neural network is progressively refined using an iterative approach combining simulation, real-time comparisons, and retraining. The iterative process is described as follows: (i) generate deterministic and stochastic solutions (OBD and OBS) using the trained neural network; (ii) simulate real travel times using the physical model; (iii) compare estimated and real travel times to identify discrepancies; (iv) use discrepancies to generate new training data; (v) retrain the network to minimize RMSE; and (vi) update solutions with refined travel time estimates. As it will be discussed in the experimental section, the proposed model handles dynamically generated trajectories. It learns complex patterns and applies them to new conditions. Once trained, the model rapidly predicts segment travel times, improving overall system performance.