The best route determination using nearest neighbor approach

One of the Environmental Services Department (ESD) duties of Yogyakarta City is freighting garbage. The sector of this research object is Malioboro-Kranggan, which constitutes a sector with the highest number of locations that are 34 garbage dump locations (TPS) and 2 depots with an average volume of total garbage is 197 m/day. At the moment, ESD is operating 6 vehicles of garbage hauler. In the operation of those six vehicles, there is an unequal workload that happened to those vehicles. There is a vehicle that must finish the job two hours slower than others. This situation emerges envy among the drivers. Table 1 shows the locations of 34 TPS and 2 depots which become the working area of Malioboro-Kranggan sector. Meanwhile, Figure 1 shows the matrix of the distance between TPS locations. The location and matrix were taken from Google Maps. ARTICLE INFO ABSTRACT


Introduction
One of the Environmental Services Department (ESD) duties of Yogyakarta City is freighting garbage. The sector of this research object is Malioboro-Kranggan, which constitutes a sector with the highest number of locations that are 34 garbage dump locations (TPS) and 2 depots with an average volume of total garbage is 197 m 3 /day. At the moment, ESD is operating 6 vehicles of garbage hauler. In the operation of those six vehicles, there is an unequal workload that happened to those vehicles. There is a vehicle that must finish the job two hours slower than others. This situation emerges envy among the drivers. Table 1 shows the locations of 34 TPS and 2 depots which become the working area of Malioboro-Kranggan sector. Meanwhile, Figure  1 shows the matrix of the distance between TPS locations. The location and matrix were taken from Google Maps.

Literature Review
Many types of research have been conducted to determine a route or vehicle track of goods distribution. The quantity of solution methods presented in the academic literature has become quickly over the previous decades (Braekers et al. 2015). Several route determinations that have been conducted before are by Fatharani et al. (2013), Muriani (2014), Kurniawati (2015), Cici and Hari (2015), Pan et al. (2020), and Luo et al. (2020). The approach used in those four papers is the nearest neighbor. The results gained to show significant results since they lead to better performance than before. The nearest neighbor method constitutes a heuristic optimization approach. The nearest neighbor is a method used to design a route based on the next closest distance. This method was also applied to classify a scholarship just like what has been conducted by Sumarlin (2015). Furthermore, Luo et al. (2020) applied two nearest neighbor classifiers for categorical data classification.
There were several steps conducted in the application of the nearest neighbor method. Those steps were adopted from Fatharani et al. (2013) by following these eleven steps: a.
Step 1 Determine the loads on the vehicle ( ) = 0 3. For the first route ( = 1) in the first trip ( = 1), starting location at depot (0). Set the chosen customers as the starting locations, then repeat step 2. g.
Step 7 Count . If ≤ ax, go on to step 9. If > ax, continue to step 10. h.
Step 8 Cancel the selection of the last customer, and then choose another unselected customer which is closest to the starting location and continue to step 3. If none of all customers deserve, go on to step 9. i.
Step 9 The vehicle is heading to an intermediate facility ( ) to load or unload the goods. Set a new trip ( = + 1) with as the starting location, and then repeat step 1. j.
Step 10 Cancel the selection of the last customer, and then go back to step 1 to set a next route ( = + 1). k.
Step 11 If all customers are already selected, so the route determination is also done.

Research Methodology
The stages of research are presented in a flowchart as seen in Figure 2. The data were taken from cases in ESD, meanwhile, the method used was the nearest neighbor. For the steps of the method, they were adopted from the steps conducted by Fatharani (2013)

Results and Discussion
The best route determination constitutes a route with the shortest total distance and the smallest total time. The shortest total distance will be closely related to the operational cost, especially fuel cost which oppresses ESD. The smallest total time will then be related to the working hours of ESD, so it is expected that the workload of all operating vehicles will be more balanced.
The completion using the nearest neighbor leads to a solution finding that is much faster. After applying an initial condition, selecting the closest TPS is conducted, and then calculating the remaining capacity of the vehicle. Selecting the closest TPS is conducted once again, if there is still a space of the remaining capacity, and keep going on and on until the remaining capacity of the vehicle is zero. The steps are reflected in Figure 3. In the process of searching the garbage freight cases in ESD of Yogyakarta City, there is actually a possibility for several TPS locations having the equivalent shortest distance. Table 2 shows the counting results of the nearest neighbor algorithm for the cases in ESD Yogyakarta. In Table 2, route row reflects the route of each vehicle in Malioboro-Kranggan area. For that area, ESD allocates 6 hauling vehicles, which are determined by I, II, III, IV, V, and VI. Several types of research that have become the references do not have any conditions as found in the ESD cases here. The load capacity at locations with the same distance is sometimes the same, or sometimes different in each iteration. This research tries to figure out the effects resulted from the locations with the same distance and have the same load capacity of garbage with those which have a different load capacity of garbage.
Reviewing vehicle 1 at TPS 32, there are two alternative decisions come up for the next TPS: TPS 26 and TPS 31. Therefore, making the scenario was needed to find the best decision. Two scenarios were set, the first scenario chose the TPS with the garbage volume reaching the remaining capacity of the vehicle, meanwhile, the second scenario chose the TPS which had the smallest volume of garbage. The results of those scenarios application are shown in column Alternative I and Alternative II.
Reviewing the vehicle IV as well, for the second scenario (choosing the TPS that had the smallest volume of garbage) when arriving at TPS 27, there are also two alternative decisions showing up; those are TPS 15 and TPS 18. TPS 15 has resulted from the first scenario decision, meanwhile, TPS 18 has resulted from the application of the second scenario. The results of the application can be seen in Table 2, column Alternative I and Alternative IV. The total alternative distance I is 13.5 km, meanwhile, on alternative distance II is 13.8 km. It means that the first scenario is better than the second scenario.
On the alternative I, the route I, in the fourth iteration from TPS 32 to the next TPS, it is found the same distance between TPS 26 and TPS 31. Therefore, it causes two alternative completions as well. Those alternatives are alternative I and alternative II. The total distance of alternative I is 13.59 km, meanwhile, the total time is 40.09 hours. On the other hand, the total distance of alternative II is 13.54 km and 40.31 hours as the total time. In the next iteration, on the alternative I, there are also found two alternative TPS locations that have the same distance. To be exact, on route IV, in the second iteration from TPS 27 to the next TPS, it is found the same distance between TPS 15 and TPS 18. So that, the utterance for an alternative that passes through TPS 15 is still called as alternative I. On the other hand, an alternative that passes through TPS 18 is called as alternative III. Besides, on alternative II it is also found the same distance which then resulted in alternative IV. To be exact, on route IV, in the third iteration from TPS 4 to the next TPS, it is found the same distance between TPS 8 and TPS 15.

Conclusion
The best decision in selecting the route of hauling garbage is by using the indicator of the shortest distance and the smallest total time. When it is found that several TPS locations have the same distance, then the first scenario is needed to apply. It is by choosing the TPS with the volume of garbage almost reaching the remaining capacity of the vehicle.