Research on the Scheduling of Tractors in the Major Epidemic to Ensure Spring Ploughing

When the outbreak of COVID-19 began, people could not go out. It was not allowed to provide agricultural machinery services in different places across regions to reduce the flow and gathering of people. Improvement of utilization efficiency of agricultural machinery resources is required through scientific scheduling of agricultural machinery. With seizing the farming season and stabilizing production as the goal, this paper studied the scientific scheduling of tractors within the scope of town and established agricultural machinery operation scheduling model with the minimization of total scheduling cost as the optimization objective. Factors such as farmland area, agricultural machinery, and farmland location information and operating time window are considered in this model to improve the accuracy of the agricultural machinery operation scheduling model. The characteristics of multiple scheduling algorithms are analyzed comprehensively. The scheduling requirements of agricultural machinery operation to ensure spring ploughing are combined to design the agricultural machinery scheduling algorithm based on the SA algorithm. With Hushu Street, Jiangning District, Nanjing City, as an example, a comparative experiment is conducted on the simulated annealing algorithm (SA) designed in this paper and the empirical algorithm and genetic algorithm (GA). The results suggest that the total cost of the scheduling scheme generated by the SA algorithm is 19,042.07 yuan lower than that by the empirical scheduling algorithm and 779.19 yuan lower than that by the genetic algorithm on average. Compared with the GA algorithm, the transfer distance, waiting cost, and delay cost of the SA algorithm are reduced by 11.6%, 100%, and 98.1% on average, indicating that the transfer distance of agricultural machinery in the scheduling scheme generated by the SA algorithm is shorter, so is the waiting and delay time. Meanwhile, it can effectively obtain the near-optimal solution that meets the time window constraint, with good convergence, stability, and adaptability.


Introduction
China's agriculture has a small average household operation scale, high agricultural multiple cropping index, tight farming time, and other problems. e operation capacity of agricultural machinery cannot meet production needs during busy periods. e regional shortage of agricultural machinery can be solved by cross-regional operation of agricultural machinery in regular years. e cross-regional operation area of agricultural machinery for three major food crops in China reached 20,478 thousand hectares, accounting for 21% of the sown area in 2019 [1].
Due to the outbreak of COVID-19, global production and life in 2020 paused; companies suspended production and businesses shut down for a while. According to the epidemic development level, epidemic prevention measures such as shutting down countries, cities, and villages have been continuously introduced. People have to stay at home to protect themselves and avoid adding burdens to society. As a result, cross-regional operations of agricultural machinery were suspended, adding fuel to the fire of insufficient regional agricultural machinery operation. However, as the foundation of the national economy, agriculture is different from the secondary and tertiary industries. It is characterized by strong seasonality, and missing the production season will lead to huge losses. erefore, governments of various countries have carried out massive measures to seize the farming season and stabilize production while fighting against the epidemic at the same time. Agricultural machinery management departments at all levels in China vigorously carry out agricultural machinery scheduling according to the impact of the epidemic to ensure spring ploughing.
For major catastrophic accidents, scholars have conducted extensive studies, mainly focusing on the distribution of supplies. In large-scale emergencies, the problems and challenges that arise in the management of emergency resource supply chains are significantly different from those in ordinary commercial applications [2][3][4][5]. To respond to such disasters effectively, governments and management organizations must consider multiple and unique aspects of emergency operations, such as resource scarcity and disaster uncertainty [6][7][8]. In addition, reducing the number of casualties and deaths in disaster-stricken areas depends, to a large extent, on the early arrival and rapid deployment of resources for emergency operations. Failure to allocate sufficient resources in time has always been the root cause of adverse effects in case of disaster [9][10][11][12][13][14][15].
In addition, unexpected events must be considered in emergencies because there can be multiple uncertain and unpredictable factors [16,17]. Due to the lack of historical data and possible dissemination ways, it is difficult to set the exact parameters for this problem. e variables that must be considered to obtain a better response rate include key requirements, competition priority, time urgency, and availability of necessary resource allocation. However, potential transportation and condition restrictions have hindered the provision of emergency services [13,[18][19][20]. Emergency dispatch coordinators and decision-makers often make wrong decisions during natural disasters. e reason is that they rely excessively on their previous experience, are overconfident in their ability to make helpless decisions, and use simple decision heuristics [21,22]. No relevant literature reports have been found regarding emergency scheduling in agricultural production.
Given that farmers could not organize agricultural production effectively at home in areas with COVID-19 outbreaks, an agricultural machinery operation scheduling model with the minimization of total scheduling cost as the optimization objective was established in this paper. With seizing the farming season and stabilizing production as the goal and the scheduling of tractors within the scope of town as the research object, influencing factors such as farmland area, agricultural machinery, farmland location information, and operating time window time were fully considered based on in-depth analysis of various agricultural machinery operation costs. e model solving method was designed through the improved SA algorithm. e tractor production scheme and scheduling path within the town are obtained to meet the requirements of the farmland operating time window, achieve the objective of total cost minimization, and accomplish the task of ensuring spring ploughing with high efficiency and cost-effectiveness.

Problem Description
In areas with the outbreak of COVID-19, it is not allowed to provide agricultural machinery services in different places across regions to reduce the flow and gathering of people. In areas with relatively less agricultural machinery, they can only try to improve the utilization efficiency of agricultural machinery resources through scientific scheduling so as not to miss any or fewer farming hours. All villages uniformly report production demand information to the town's agricultural station. e agricultural station organizes farmers who own agricultural machinery within the town to carry out production service operations. e service fee is settled by the town's agricultural station with each village in a unified manner. Agricultural machinery service households (AMSH) and farmers do not need to meet or do deals. e specific process is shown in Figure 1.
Farmers report the location, area, and operating time window of the farmland run by them to their village committee. Agricultural machinery service households report all tractor models, locations, and operating efficiency to their village committee. e village committee collects the order information based on the farmland location and time window and reports it to the town (township) agricultural station. e town's agricultural station uniformly formulates a scheduling scheme and sends it to the agricultural machinery service household. e tractors depart from their locations to the responsible areas according to the established scheme and route, providing farming services in turn.

Tractor Scheduling Model
e tractor scheduling issue can be expressed as follows: there are m individual entrepreneurs owning agricultural machinery. To avoid the gathering of machinery operators and farmers, the township government divides the whole township into n small operation areas according to the working needs. e farmland area of the i-th area is s i , i � 1, 2, . . ., n. e tractors should arrive within a certain time range [ET i , LT i ], that is, arrive no earlier than ET i and leave no later than LT i . When the tractor arrives earlier than ET i , the waiting cost of agricultural machinery is caused by personnel wages and the profit loss of idle machinery. When the tractor arrives later than LT i , it causes timely loss of crops. e route arrangement is made by solving the tractor operation with the lowest cost that meets the demand for spring ploughing within the township scope. e costs of spring ploughing operation include the cost of tillage and that of field transfer; the fixed cost of tractors is not considered yet. e specific model is as follows. e operation area number is 1, 2, ..., N, and the parking yard number of farmers that own agricultural machinery is If so, xijk is 1; otherwise, its value is 0 yik: decision variable for tractor operation, indicating that if tractor k operates in operation area i, its value is 1; otherwise, its value is 0 si: area of the farmland in the i-th operation area sik: operation area completed by tractor k in the i-th operation area tijk: time taken by the k-th tractor to travel from point i to point j, equal to distance (dij) divided by speed (vk) tik: time taken by tractor k to complete the tillage in the operation area i, equal to the operation area (sik) divided by the efficiency (wk) � t ik : moment when tractor k arrives at the operation area i t ik : moment when tractor k completes the task of tillage and soil preparation in the operation area i PEk: waiting cost to be paid due to tractor k arriving earlier than ETi PLk: penalty for timeliness loss to be paid due to tractor k completing work later than LTi ρk: cost per kilometer traveled by tractor k for the field transfer φk: operating cost per unit area of tractor k

Mathematical Problems in Engineering
In the model, equation (1) is the objective function, which indicates the minimal total cost required to complete all spring ploughing tasks in the township area, including field transfer costs, operating costs, and penalties for timeliness loss. Inequality (2) constrains the tractor traveling sequence; that is, when transferring from point i to point j, the time of arrival at point j must be later than that at point i. Equation (3) shows the relationship between the tractor arrival time and the operation completion time. Inequality (4) stipulates that the number of tractors dispatched from the parking yard of individual entrepreneurs owning agricultural machinery cannot exceed the total number of tractors. Equation (5) stipulates that all plots in the operation area must be tilled. Equation (6) shows the relationship between tractor operation time and efficiency. Equation (7) indicates that if tractor k works at point j, then tractor k must move from point i to point j. Equation (8) indicates that if tractor k works at point i, tractor k must move to other points j after finishing work at point i.

Design of Scheduling Algorithm Based on Simulated Annealing (SA)
Agricultural machinery scheduling to ensure spring ploughing during an epidemic is a typical NP-hard problem.
As the operation space size ((n−1)!) shows a factorial increase, the exact solution cannot be obtained through the exhaustive method [23], dynamic programming [24,25], linear programming [26], branch and bound [27,28], and other precise algorithms for large-scale problems. With the development of computers, many intelligent optimization algorithms have emerged in the field of artificial intelligence, such as the genetic algorithm [29][30][31], tabu search algorithm [32], ant colony algorithm [33], particle swarm optimization algorithm [34], simulated annealing algorithm [35,36], online-learning algorithm [37], adaptive polyploid memetic algorithm [38], many-objective evolutionary algorithm [39], and salp swarm algorithm [40]. Among them, the idea of simulated annealing algorithm (SA) is derived from simulating the cooling process of solid annealing, that is, heating the solid to a sufficiently high temperature, then allowing it to cool down slowly to balance the internal energy, avoid falling into local minimum effectively, and eventually tend to a global optimum.

Solution Coding.
Based on the characteristics of the agricultural machinery job scheduling problem and related research, the solution coding can adopt a two-layer coding method, as shown in Figure 2. e first-level code is the sorting of farmland, and the order of farmland in the entire coding is the service order of farmland orders. As shown in Figure 2, F1∼Fn are farmland operation orders, and the operation areas are sorted according to the starting work time ET i to study the serial and parallel issues between the operation areas. e operation is executed sequentially in the serial operation areas and in a parallel way in the parallel operation areas. e second-level code is the order of tractors in the farmland. For example, the tractor operating in the F1 farmland is M11, M12, and M13, and the tractor operations in the same farmland are in no particular order. e number of tractors required for the farmland operating site is the local code length of the farmland operating site. Assuming that F i in the i-th area is coded, the maximum quantity of agricultural machinery required for F i is K i � s i /min w k (LT i − ET i ), and M iKi represents the K i -th tractor in the i-th area. Now, partial coding is performed on F i .

Initial Solution Settings.
e initial solution is the starting point of algorithm iteration. e selection quality of the initial solution can improve the computational efficiency of the algorithm and enhance the reliability of the final solution. In this paper, the following three directions are mainly considered in setting the initial solution of the algorithm: (1) priority is given to the operation area with an early harvest time window; (2) the minimum number of tractors that can meet the production capacity requirements are arranged in each area; (3) when tractors are allocated to the operation area, idle tractors or those that can reach the target area faster are arranged first.
According to the above coding strategy, the initial solution of the SA algorithm is generated. e specific steps are as follows: Step 1: establish the task set of the operation area and schedule the work sequence according to the direction I to build the operating agricultural machinery depot set Step 2: determine whether the task set of the operation area is empty. If so, go to step 5; otherwise, go to step 3 Step 3: allocate tractors to area tasks according to directions II and III Step 4: go to Step 2 Step 5: the initial scheduling scheme matching is completed

Domain Generation Rules.
e neighborhood generation rule in the SA algorithm is crucial. When the initial solution is generated, what rules are used to generate a new solution is related to whether the whole algorithm can be effectively performed to achieve the goal. For this issue, it is about how to generate a new scheme based on an existing scheduling scheme for further judgment. e commonly used neighborhood generation strategy of 2-opt mapping is used in this paper to generate a new scheduling scheme. Two vertices p and q are randomly selected. Assuming p < q, tractor code (p, p+1,. . ., q−1, q) is reversed. e details are shown in Figure 3.

Acceptance Probability of New Solutions.
Acceptance probability is the probability of accepting a new feasible solution P new (another state) to replace the current feasible solution P old (current state). It is not fixed but decreases as the temperature parameter T drops. Metropolis criterion is generally adopted: 4.5. Temperature Attenuation Function. e temperature attenuation function is also known as the cooling strategy. e common exponential cooling strategy selected in this paper is T m+1 � αT m . In the formula, α is the temperature attenuation index, 0 > α < 1, and m is the number of temperature drops.

Stop Criterion.
A reasonable stop criterion can not only ensure that the algorithm converges to an approximate solution but also make the final solution global to some extent. e SA algorithm includes inner-and outer-loop stops. In this paper, the fixed iteration step size is adopted for the inner loop, and the temperature reaching the termination threshold is adopted for the outer loop to exit the iteration.

Algorithm Flow.
According to the tractor production scheduling model and solution coding, the simulated annealing algorithm process is designed as shown in Figure 4.
(1) Randomly generate an initial solution X 0 , let X best � X 0 , and calculate the objective function value Z (X 0 ); set the initial temperature T(0) � T 0 and the number of iterations i � l. (2) Do while T > T min .
For i � 1 to m (m is the number of cycles, which is related to the township scale). For the current optimal solution P best neighborhood function, generate a new solution P new , calculate the new objective function value Z(P new ), and calculate the increment ΔZ � Z(P best )-Z(P new ) of the objective function value. If ΔZ < 0, then Z best � Z new ; if ΔZ > 0, then p � exp(−ΔZ/T). If c � random [0, 1] < p, Pbest � Pnew; otherwise, Pbest remains unchanged. end for. i � i + 1. End Do.

Example Verification
In this paper, Hushu Street, Jiangning District, Nanjing City, is taken as an example. Located at the junction of Jiangning, Jurong, and Lishui, Hushu Street is a typical suburban town, where mainly grains, vegetables, and fruits are planted, with a relatively complicated planting structure. In the season for spring ploughing before the epidemic, Hushu will attract agricultural machinery from the surrounding counties and cities to carry out operation services. However, due to the impact of the epidemic this year, agricultural machinery from other places cannot enter Hushu Street, and spring ploughing production can only be ensured through scientific scheduling of local agricultural machinery. We divided the farmland in Hushu Street into 13 operation areas on Google Earth (blue markers in Figure 5) and marked four agricultural machinery cooperatives in Hushu Street (red markers in Figure 5); distribution and area of farming sites are shown in Supplementary Table 1, distribution and machine information of agricultural machinery cooperatives is shown in Supplementary Table 2; distance matrix between     Table 3. e tractors of the cooperatives were all 80 horsepower. e average operating efficiency is 0.5 hm 2 /h, the operating cost is 300 yuan/hm 2 , the average transfer speed is 35 km/h, the transfer cost is 2 yuan/km, the waiting cost is 42 yuan/h, and the timely loss cost coefficient 5.4 yuan/h.

Example Calculation Results.
In the actual production scheduling, farm management personnel usually adopt the three strategies mentioned in Section 4.2 for agricultural machinery and farmland matching and generate empirical scheduling solutions, which can be further optimized using the optimization algorithm in this paper. To further illustrate the superiority of the algorithm designed in this paper, the GA algorithm commonly used in the research of similar agricultural machinery scheduling issues is applied to comparison experiments. On a personal computer with Intel Core i5 CPU 3.0 GHz, 8.0 GB memory, and Windows 10 operating system, Matlab R. 2018a software programming is used to implement three algorithms to solve real cases 20 times, respectively. e calculation results are shown in Table 1. Table 1 shows that compared with the empirical scheduling algorithm, GA and SA algorithms can reduce the total cost of agricultural machinery significantly. e total cost of the scheduling scheme generated by SA designed in this paper is 19,042.07 yuan lower than that by the empirical scheduling algorithm and 779.19 yuan lower than that by GA on average. Compared with GA, the transfer distance, waiting cost, and delay cost of SA are reduced by 11.6%, 100%, and 98.1% on average, indicating that the transfer distance of agricultural machinery in the scheduling scheme generated by SA is shorter, so is the waiting and delay time. Figure 6 shows the total cost of solving real cases 20 times by GA and SA, respectively. It can be seen that the total cost of the scheduling scheme obtained by SA is generally lower than that by GA.
e standard deviation of the 20 scheduling schemes obtained by SA is 35.78, while that of various scheduling schemes obtained by GA is 1424.08, indicating that the solution obtained by SA has superior quality and higher stability.
is is because SA uses the initial solution generation algorithm, with a good start for the optimization process. Moreover, based on the Metropolis criterion, the SA algorithm can avoid being trapped in local minima and implement full optimization, whereas the GA algorithm is prone to get stuck in local minima when handling such complex scheduling problems. e experimental results suggest that the agricultural machinery operation scheduling model based on the SA algorithm in this paper can satisfy the time window constraints with the lowest total cost and meet the spring ploughing scheduling demand in practice. e scheduling algorithm based on SA designed in this paper can be used to solve the agricultural machinery transfer paths of various agricultural machinery cooperatives, as shown in Figure 7. Among them, the transfer paths of some agricultural machinery in the same cooperative are overlapped, such as agricultural machinery No. 1, 2, and 3 in the cooperative N1, and agricultural machinery No. 10 and 11 in the cooperative N2. In addition, the cooperation of different cooperatives in agricultural machinery to complete orders is observed. For example, order 13 is jointly completed by agricultural machinery No. 4 and 15, which suggests that the algorithm designed in this paper can implement unified scheduling of agricultural machinery in the same cooperative and collaboration among different cooperatives to meet the needs of multimachinery coordinated scheduling of multiple cooperatives in reality. Meanwhile, it can be seen intuitively from the transfer path diagram 6 that the order tasks assigned to each agricultural machinery have spatial proximity, indicating the rationality of the experimental results. e scheduling Gantt chart of the tractor is shown in Figure 8. e bars in the chart represent the operation scheme of each fleet, including the operation order number, operation start time, and operation ending time, which can be used for specific guidance of actual production scheduling.

Algorithm Convergence.
e change in the optimal value of each cost in the operation process is shown in Figure 9. e total cost, the total length of transfer path, waiting time, and delay time decrease as the number of iterations increases. e total cost can converge to a stable value when the number of iterations is increased to about 350; the delay and waiting time can converge to 0 within 50 iterations.
e calculation results suggest that the algorithm can achieve stable convergence with relatively search performance.

Algorithm Stability and Adaptability.
e stability of the algorithm is an important index for evaluating whether the scheduling algorithm can stably obtain a scheduling scheme with relatively good quality. It is usually measured by parameters such as mean, standard deviation, and coefficient of standard deviation [41]. At the same time, a case set containing 13,26,39,52, and 65 orders is constructed based on the case data of Hushu Street to test the adaptability of the SA algorithm designed in this paper to the application scenarios with relatively larger order scales. e algorithm is run 10 times for each case set. Statistical comparison is performed on the mean, standard deviation, and standard deviation coefficient of the computing time and total cost of different cases to test the stability and adaptability of the algorithm. e experimental results are shown in Table 2.   Table 2 shows that when the number of orders in the case increases, the standard deviation is not multiplied, and the coefficients of standard deviation are all less than 10 −5 .
e experimental results suggest that the algorithm designed in this paper has relatively good stability. When the number of orders increases to 52, the computing time is not significantly increased but still remains within 30 seconds. e results suggest that the algorithm designed in this paper can adapt to larger-scale case operations. However, when the number of orders increases, the computing time is not significantly increased. e main reason is that when the number of orders increases, the operation area per order will decrease, and the quantity of agricultural machinery allocated to each order will decrease, which objectively reduces the complexity of the problem.

Conclusions
(1) e agricultural machinery scheduling in the major epidemic to ensure spring ploughing is taken as the research object to analyze various costs of agricultural machinery scheduling and establish agricultural machinery operation scheduling model with the minimum total scheduling cost as the optimization objective. Factors such as farmland area, agricultural machinery, and farmland location information and operating time window are considered in this model to improve the accuracy of the agricultural machinery operation scheduling model. (2) Agricultural machinery scheduling to ensure spring ploughing during an epidemic is a typical NP-hard problem. rough the comprehensive analysis of the characteristics of multiple scheduling algorithms, combined with the scheduling requirements of agricultural machinery operation to ensure spring ploughing, agricultural machinery scheduling algorithm based on the SA algorithm is designed. e farmland and tractor coding method is determined by two-level multilayer coding. e neighborhood generation strategy of 2-opt mapping is used to generate a new scheduling scheme, and the new solution acceptance mechanism is determined based on the Metropolis criterion. e fixed compensation is used for the inner loop of the algorithm, and the iteration ends when the threshold temperature is reached. (3) With Hushu Street, Jiangning District, Nanjing City, as an example, a comparative experiment is conducted on the SA algorithm designed in this paper and the empirical and GA algorithms. e results suggest that the total cost of the scheduling scheme generated by the SA algorithm designed in this paper is 19,042.07 yuan lower than that by the empirical scheduling algorithm and 779.19 yuan lower than that by the genetic algorithm on average. Compared with the GA algorithm, the transfer distance, waiting cost, and delay cost of the SA algorithm are reduced by 11.6%, 100%, and 98.1% on average, indicating that the transfer distance of agricultural machinery in the scheduling scheme generated by the SA algorithm is shorter, so is the waiting and delay time. Meanwhile, it can effectively obtain the near-optimal solution that meets the time window constraint, with good convergence, stability, and adaptability. (4) is paper does not consider unexpected situations such as infection of tractor drivers and road blockades that may occur during the epidemic. In future research, we will focus on the impact of unexpected conditions on agricultural machinery scheduling and carry out research on agricultural machinery dynamic scheduling.

Data Availability
e example data used to support the findings of this study are included within Supplementary Tables 1-3, mainly including the location of farmland in the case area, the location of cooperatives, and the parameters of agricultural machinery.

Conflicts of Interest
e authors declare that they have no conflicts of interest.