## 1 Introduction  
There have been numerous applications of unmanned aerial vehicles(UAVs) in the last decade in the fields of wireless ad hoc and sensor networks, vehicular networks, and the internet of thing (IoT) devices [1; 2; 3; 4]. The applications encapsulated various fields including civilian purposes, military, disaster management, surveillance, source localization, task execution, products delivery, agriculture, etc. [5; 6; 7; 8; 9]. The reason is that UAVs are fast, lightweight, and cheap. If their trajectories are planned properly then a lot of tasks can be completed through energy-efficient UAVs and less energy consumption means a lot of money is saved [10; 11; 12; 13; 14]. This is entirely necessary from the perspective of the scarcity of energy resources and the sustainability of mother earth [15; 16; 17; 18; 19].  
The target in this context is energy optimization in UAV-controlled IoT-monitored big agricultural fields, surveillance areas, etc., through energy efficient trajectory planning and properly suggesting the IoT devices about the timestamp of submitting the next task to the clusterhead (CH). Although many UAV trajectory deciding algorithms exist in the literature as discussed in Section 2, to the best of the authors' knowledge, the issue of arrival of the UAV over a CH when its task queue is approximately full, has been inadequately addressed in UAV-IoT systems. But it is extremely important for efficient task execution and resource utilization. It is always better and energy-saving for the UAV to come to a CH and execute the set of tasks in the completely full task queue than coming to the same CH twice and executing the set of tasks in its half-filled task queue. This saves propulsion energy in the UAVs. Energy in non-CH ordinary devices is saved by the CH IoT device as it prescribes the next timestamp of submitting the next task by this particular ordinary IoT device so that the chance of this task being dropped, becomes much less. The job of the CH is to collect the tasks of the individual IoT devices and under it and arrange them in a suitable sequence. This is extremely important because each retransmission of a task from the source IoT device to CH doubles the consumption of energy by ordinary members. The scheduling process has been made energy efficient because tasks are executed in order of priority and starving tasks, especially those that have short lengths are assigned a higher priority. This is an optimization problem where the optimal trajectory to be followed by UAV changes dynamically with a number of tasks that are generated at each individual IoT device, their length, the starvation status, predecessor, etc., until the history is developed, we rely on the initial solution which is the trajectories suggested by the [PERSON]'s shortest path algorithm [20]. Iterative improvements take place on existing solutions based on the history that gradually develops in CH IoT devices. This matches with the nature of genetic algorithm (GA) [21; 22] and so we have used it in the proposed technique.  
In this paper, we propose a GA-based trajectory optimization strategy that will optimize the objectives including the number of distinct IoT devices served, the number of tasks that are successfully completed, and the amount of energy consumed which includes propulsion energy as well as the energy required to execute the task submitted by several different IoT devices. Energy is saved not only in the UAVs but also in the IoT devices by avoiding the resubmission of tasks as much as possible. Here we have considered the constraints like time of use, tariff, etc., because the system has been implemented here using a simulator.