Modeling and simulation of dual-battery FANET system using MADRL for energy optimization Authors: A Sophia Mary, T S Pradeep Kumar Published: 2025 ABSTRACT AbstractUncrewed Aerial Vehicles (UAVs), or drones, are revolutionizing applications such as surveillance, search and rescue (SAR), precision agriculture, and disaster response. In these applications, Flying Ad-Hoc Networks (FANETs)—dynamic networks of interconnected UAVs—are essential for enabling rapid and adaptive deployments. However, the limited battery life of UAVs remains a critical challenge, particularly in extended missions like SAR, where operational longevity and reliable performance are paramount. This paper addresses two key challenges in FANET-based UAV operations: optimizing energy consumption and ensuring stable communication links. We propose a novel strategy that models energy-efficient UAV behavior by focusing on the three primary drivers of power consumption: flight dynamics, payload operations, and continuous wireless communication, which collectively account for 80–85% of the UAV’s energy usage. Leveraging a multi-agent deep reinforcement learning (MADRL) framework that intelligently manages a dedicated dual-battery system: one battery (B1) optimized for flight dynamics and payload operations, and the other (B2) for processor/sensor and continuous wireless communication. The MADRL agents (Proximal Policy Optimization: PPO) are modeled to handle battery B2, which dynamically establishes communication between UAVs regarding energy usage and other environmental conditions during SAR operations, thereby efficiently conserving available energy to extend the battery life of each UAV within the FANET system. Experimental results demonstrate that MADRL enhances network connectivity and significantly reduces energy wastage, enabling sustained operations over longer durations. This research lays the foundation for developing energy-efficient UAV systems, which are crucial for large-scale and autonomous deployments in mission-critical scenarios. Subject terms: Electrical and electronic engineering, Computer science Introduction The rapid evolution of UAVs has transformed the landscape of modern aerial robotics, enabling innovative solutions across industries such as public safety, environmental monitoring, agriculture, and defense1–5. The battery is a key component of UAVs, powering the applications in these fields. These battery-powered autonomous or remotely operated systems are equipped with advanced flight software, onboard sensors, cameras, and GPS technology, allowing them to execute complex tasks with high precision6. Initially developed for military purposes only, for dropping bombs on the battlefield, surveillance, and reconnaissance7, UAVs have now become indispensable in civilian applications as shown in Fig. 1, including SAR missions, disaster response, agriculture, delivery, and infrastructure inspections. The important abbreviations and notations are summarized in Table 1. FANETs in UAV applications—Distributed Architecture. The image in Fig. 1 was created using Canva (https://www.canva.com). Table 1Summary of abbreviations and important notations used in this work.AbbreviationsDescriptionNotationDescriptionUAVUncrewed Aerial VehiclesSt​State of the UAV at time step tB1Battery for flight dynamicsSt​+1Next state of the UAV after action At A_t At​B2Battery for CommunicationAtAction taken by the UAV at time step tMADRLMulti-Agent Deep Reinforcement LearningRtReward received at time step tPPOProximal Policy Optimization Policy parameterized by θ, mapping states to actionsSARSearch and RescueθParameters of the policy networkGPSGlobal Position SystemΎDiscount factorQoSQuality of Serviceπ*,Optimal policy for UAV behaviourRLReinforcement Learning​​Expectation over states and actions under policy πθBMSBattery Management System∇θ​Rt​Gradient of the expected return with respect to θEODEnd of Dischargeπθ​(at​∥st​;θ)Policy probability distribution over actionsSOCState of Charge∇θ​logπθ​(at​∥st​;θ)Gradient of the log probability of action at​BHMBattery Health ManagementA​Advantage function estimating action qualityEMSEnergy Management SystemQ(St​,At​)Action-value functionFEMFinite Element Model∇θ​logπθ​(at​∥st​;θ)Gradient of the log probability of action at​ECMsEquivalent Circuit ModelsV(St​;ϕ)State-value function with weights ϕNS3Network Siulatorδt​Temporal difference (TD) errorMDPMarkov Decision ProblemsλGAE parameter for advantage estimationECMsElectrochemical ModelsϕParameters of the value function networkMlpPolicyMulti-layer perceptronLPG​(θ)Policy gradient objective functionTCPTransmision Control Protocolrt​(θ)Probability ratio between current and old policyαLearning rateEB1​Energy of the primary battery (B1)c1​,c2​Weights for value function loss and entropy bonusEB1​Energy of the secondary battery (B2)πθold​Policy parameters before updateTETotal energy (EB1 + EB2​) Summary of abbreviations and important notations used in this work. With the growing reliance on UAVs for critical, large-scale operations, researchers have introduced multi-UAV systems, often called UAV swarms or FANETs, to enhance operational efficiency8. FANETs consist of multiple UAVs working collaboratively within a distributed network, enabling real-time data sharing, improved coverage, and autonomous mission execution. These systems are particularly valuable in dynamic environments, such as SAR operations9,10, which is the primary focus of this paper. For instance, coordinated multi-UAVs can autonomously patrol and monitor urban areas, supporting law enforcement in maintaining public safety. They can cover large areas, identify potential threats, and assist in real-time law enforcement operations11. This technological advancement proves especially beneficial in scenarios where human intervention may be limited or unsafe, such as post-disaster reconnaissance, wildfire surveillance, and large-scale environmental monitoring11. Despite their growing deployment, battery-powered UAVs face a major limitation—short flight endurance due to the low energy density of current battery technologies12,13. Energy-efficient UAV mission planning is crucial to conserve available energy, as high-speed mobility, continuous data transmission, and environmental resistance accelerate battery depletion. Addressing energy efficiency remains a key research challenge for enhancing UAV performance. In FANETs, power exhaustion of even a single UAV can disrupt network communication, degrade mission performance, and delay critical decision-making processes14. This limitation is particularly problematic in life-saving scenarios, such as SAR missions, where uninterrupted aerial monitoring is crucial for identifying survivors and assessing disaster zones (Fig. 1). Unique challenges of UAVs in energy modelling Despite their versatility and growing adoption, UAVs face significant design challenges, with limited flight time being one of the most critical constraints. This limitation primarily arises from two key factors: High Energy Demand – UAVs necessitate a considerable amount of power to support critical functions such as hovering, high-speed flight, stability control, and real-time data processing. High Energy Demand – UAVs necessitate a considerable amount of power to support critical functions such as hovering, high-speed flight, stability control, and real-time data processing. Battery Capacity Constraints – UAVs rely on onboard batteries with limited energy storage, restricting their ability to operate over large areas or for extended durations15,16. Battery Capacity Constraints – UAVs rely on onboard batteries with limited energy storage, restricting their ability to operate over large areas or for extended durations15,16. To address these challenges and enhance cruising time, smart energy management strategies are essential. Predicting battery status, specifically remaining energy, is vital for energy-efficient mission planning, ensuring both optimal performance and battery longevity. An efficient energy consumption model underpins this effort by estimating flight time, predicting energy usage across diverse operational demands, and optimizing power consumption. Developing accurate energy models and energy-efficient UAV architectures is key to managing energy effectively, enabling longer flight durations, seamless FANET operations, and robust performance in real-world applications. This research aims to minimize energy waste in UAVs and extend their flight time by utilizing advanced energy modeling, dual-battery resource allocation, and optimization techniques through MADRL. By applying RL technology to a FANET, UAVs (agents) can automatically learn and adapt to dynamic network characteristics, such as fluctuating link quality, frequent changes in network topology, and varying energy consumption. This approach addresses challenges that conventional network technologies struggle to handle, ultimately enhancing network performance and improving Quality of Service (QoS). However, RL faces challenges in complex network scenarios, such as FANETs in SAR environments. The large number of nodes and the constantly changing environment make it difficult to maintain an extensive Q-table, resulting in significant storage requirements and time overhead. Furthermore, RL struggles to scale effectively to larger state and action spaces, limiting its applicability in large-scale, dynamic settings. To address these limitations, we combine RL with deep learning techniques. Deep Reinforcement Learning (DRL) has made significant advancements in autonomous decision-making and intelligent control, offering promising solutions to handle the complexity and scalability issues in such environments. In this work, we employ a PPO-based energy optimization technique, where an energy policy is a mapping from action space to state space for energy-efficient SAR mission operation. Background and motivations Battery-powered UAVs are becoming increasingly popular and are dominating the UAV market due to their high operational efficiency, lower operational cost, and ease of use. As of 2023, they account for approximately 90% of the market share, making them the preferred choice for a wide range of aerial missions17. UAVs are typically classified based on various factors, including weight, design, flight altitude, control system, operational purpose, take-off and landing mechanisms, and power propulsion systems18 as depicted in Fig. 2. Based on their power sources, UAVs can be categorized into five types: battery-powered, fuel-powered, hybrid, and solar-powered UAVs, as shown in Fig. 2. UAV classification on unique features. Although UAVs in the past primarily used fuel as a power source due to its high energy density, this power source is environmentally harmful19,20. Hybrid-powered UAVs use a combination of batteries and fuel for extended endurance21. While they are primarily used in electric vehicles, their application in the UAV industry remains limited. Because the effectiveness of these UAVs depends on a highly efficient energy management system (EMS). Unfortunately, the strategies for implementing this EMS in UAVs are still developing22. In contrast, battery-powered UAVs operate entirely on electric energy, resulting in zero emissions and supporting green technology initiatives. These UAVs are simple, lightweight, and cost-effective, making them the mainstream choice in various applications. The most commonly used battery type on UAVs is lithium-ion. Batteries of this type have low energy density, are short-lived, and last only 20–40 min. However, they have high power density, do not emit polluting substances, and are perfect for UAV applications. The battery is a critical component that directly impacts UAV performance, endurance, and overall mission success. For instance, battery-powered autonomous multi-UAV systems are widely used in SAR missions, offering real-time situational awareness, large-area coverage, and the ability to operate in hazardous environments where human responders face risks. However, these UAVs face significant energy limitations due to continuous real-time monitoring, constant data transmission, and payload-carrying, all of which lead to rapid energy depletion. If a UAV’s battery runs out mid-mission, it can be catastrophic—limiting endurance, disrupting the mission, or even causing mission failure, potentially compromising critical operations. To lessen the impact of limited battery capacity, it is essential to reduce energy waste and implement optimized power allocation strategies in UAV operations. For instance, if the model predicts B2 will deplete mid-mission due to heavy FANET communication, the MADRL can pre-emptively scale back non-essential links. This intelligence extends cruising time and boosts longevity by avoiding overstress on batteries. To enable energy-efficient UAV operations and minimize energy consumption across various UAV activities—such as flight manoeuvring, communication, and payload operations—we need reliable and comprehensive energy consumption modeling that understands the battery status and optimized power allocation strategies rather than relying solely on the Battery Management System (BMS). Most existing research on BMS primarily addresses battery protection, charging, and monitoring. However, BMS lacks the predictive capabilities necessary to dynamically optimize the endurance of UAVs. In contrast, energy consumption modeling plays a vital role in enhancing BMS by analysing energy consumption patterns and predicting battery discharge behavior, such as estimating the remaining energy and End of Discharge (EOD). This area remains largely underexplored in UAV research, which is the focus of this work. Developing an accurate energy consumption and dual battery model can significantly enhance UAV endurance, optimize power allocation, and improve mission success rates by addressing different aspects of power management. Motivated by these challenges, we propose an intelligent dual-battery UAV system model specifically tailored for FANETs (multi-agent) environments like SAR operations. This model profiles energy demand across diverse operational conditions, including flight manoeuvring, mobility, communication, and payload, ensuring efficient energy utilization and extended mission capability. The model for this work uses a mathematical modelling approach to analyse the behavior of a dual battery system in a UAV, estimating its performance, energy consumption patterns, and operational characteristics of UAV operation. The core concept is to leverage two batteries, Battery 1 (B1) and Battery 2 (B2), with a functional segmentation: B1 primarily powers flight dynamics, mobility, and propulsion, while B2 supports communication and payload operations. Hence, these two separate power sources for flight (main battery) and communication (small battery) isolate critical functions and prevent one system from draining the other. The intelligence (MADRL) applied to B2 learns to balance energy usage and communication needs, adapting to each other’s status and the environment without impacting B1 energy. By keeping the two batteries isolated, we can prevent a single point of failure and ensure that even if B2 depletes due to heavy communication demands, the UAV can still fly and return safely using B1. The MADRL agent governing B2 analyzes real-time data, including its own State of Charge (SoC), the statuses of other UAVs, and mission demands, learning to balance energy usage with communication needs within the FANET. This intelligent management keeps the network informed without burdening B1, mitigating risks of rapid B2 depletion and mid-mission failures. Fundamentally, the dual-battery system isolates critical functions—B1 for flight and B2 for communication—while MADRL optimizes B2 to adapt to the FANET’s dynamic requirements and environmental conditions. This synergy preserves B1 for flight stability, extending mission duration and enhancing the UAV system’s reliability and efficiency in complex operational scenarios. To validate this approach under realistic conditions, the research employs the open-source network simulator NS3 to model multi-UAV network environments, specifically Flying Ad-hoc Networks (FANETs). NS3 enables detailed simulation of a dual-battery system—B1 dedicated to flight dynamics and B2 for communication—capturing energy usage patterns and evaluating the effectiveness of Multi-Agent Deep Reinforcement Learning (MADRL) applied to B2. By simulating real-world networking scenarios, including varying environmental conditions and battery characteristics, NS3 ensures the practicality and robustness of the proposed system. The MADRL agents, guided by real-time B2 status and inter-UAV coordination data, learn to balance communication needs with energy conservation, optimizing B2 usage without compromising B1’s reserves. This strategy preserves B1 for flight stability, enhancing FANET endurance, while B2’s intelligent management prevents premature depletion, ensuring reliable, continuous operation. The result is a comprehensive power management solution that combines the isolation benefits of a dual-battery design with MADRL-driven decision-making, significantly improving mission success rates in complex operational environments. Table 2 illustrates the advantages of this dual-battery system, underscoring its contributions to prolonged UAV endurance and enhanced mission outcomes. Table 2Proposed dual battery VS existing single battery system in UAV.FeatureSingle-Battery SystemDual-Battery System (Proposed)ReasonsEnergy Efficiency✖☑Dual-battery system for better energy distribution.Flight Endurance✖☑Dual-battery system increases overall flight duration.Mission Reliability✖☑Dual-battery system reduces the risk of mid-mission failure.Power Management (Intelligent)✖☑Dual-battery system allows for dynamic power allocation.Complexity and Cost☑✖Single-battery systems are simpler and cheaper to implement. Proposed dual battery VS existing single battery system in UAV. Contributions and novel findings of the proposed study In this research, we focus on advancing UAV battery modeling and energy optimization by addressing limitations in existing approaches. Our key contributions and new findings are: Introduction of a Dual-Battery Model for FANET(Multi-UAV) Systems in SAR operation: Introduction of a Dual-Battery Model for FANET(Multi-UAV) Systems in SAR operation: We propose a novel dual-battery UAV system, where: The first battery B1 handles propulsion and flight manoeuvring. The first battery B1 handles propulsion and flight manoeuvring. The second battery, B2, manages system power, communication, and sensors. The second battery, B2, manages system power, communication, and sensors. By this approach, we can achieve dynamic energy balancing (based on UAV workload), extending UAV endurance and ensuring uninterrupted mission execution in SAR operations. 2.Mathematical Battery Modelling for UAV Energy Consumption. Mathematical Battery Modelling for UAV Energy Consumption. We develop an analytical energy consumption model considering UAV power demands for flight manoeuvring (propulsion, mobility), communication (Tx/Rx), and process/sensor operations. By mathematically representing the UAV battery’s internal behavior, we can understand how power demands impact battery life and optimize energy use to improve capacity. This approach also reduces computational cost and enables faster, safer testing through simulation. 3.Simulation and Validation Using NS3: Simulation and Validation Using NS3: We implement the proposed model in the NS3 network simulator to evaluate the FANET system’s battery status, energy consumption, and overall performance. This simulation helps validate the effectiveness of our dual-battery model in optimizing energy usage and extending the UAV’s mission duration. 4.Intelligence applied to Secondary Battery B2 using Deep Reinforcement Learning (DRL) and simulating in the NS3-Gym framework. Intelligence applied to Secondary Battery B2 using Deep Reinforcement Learning (DRL) and simulating in the NS3-Gym framework. We employ DRL for predictive decision-making in energy allocation and control of UAV states based on real-time conditions such as SoC or remaining energy in the battery, power demand, and mission constraints. Furthermore, to train and validate the DRL agent’s performance in managing Battery B2, we utilize the ns3-gym framework. This framework allows the DRL agent to interact with the simulated NS3 network environment, learning optimal energy management policies through observation of network states, execution of actions, and reception of corresponding rewards. By integrating NS3 and ns3-gym, we can comprehensively evaluate both the dual-battery system’s efficacy and the DRL agent’s ability to adapt to complex FANET conditions dynamically. The remainder of this article is structured as follows: The section “Background and motivations” provides the background and motivation for this work. The section “Related works“ gives a deep insight into earlier attempts at modeling the energy consumption and battery of UAVs. The section “Modelling energy consumption of UAV dual battery system” presents and discusses the proposed energy consumption modeling for this work; the section “Proposed DRL-based energy optimization for FANET system in SAR operation” presents and discusses the proposed DRL methodology for battery energy optimization. The section “Experimental evaluation and results discussion” focuses on the experimental evaluation and the discussion of results. Finally, the section “Conclusion” concludes the article and outlines potential future work. Related works UAVs are now a mandatory practice in disaster zones, as illustrated in Fig. 1. In such environments, UAVs are important because they can provide real-time information, enhance search and rescue operations by keeping human responders safe, assess damage quickly, and offer a cost-effective and flexible alternative to traditional manned aircraft and ground vehicles23–25. However, one major limitation is that onboard batteries are often not large enough to support most UAV functions, especially during search and rescue missions. Due to design constraints, UAVs are typically unsuitable for continuous and long-term monitoring, which necessitates robust battery performance estimation models to prevent mid-mission failures. Even with FANET technology, where multiple UAVs collaborate on SAR missions to expand coverage, each UAV still has a limited battery life. When a UAV’s battery is depleted, it must either be returned to a charging station or replaced. This disrupts the network and forces other UAVs to use extra energy to find and reconnect with a new neighbour node, which affects overall efficiency. In response to these challenges, researchers are exploring various solutions, including energy-efficient path planning, implementing wireless charging systems, developing battery replacement methods, BMS, BHM (Battery Health Management), and the integration of solar panels and other energy-harvesting techniques. In contrast to electric vehicles, which have been extensively studied for energy consumption modeling, most research has concentrated on ground vehicles26–30. UAVs, however, face unique power constraints due to their reliance on battery-powered propulsion, continuous communication, and ongoing sensor operations. Unlike ground vehicles, UAVs experience dynamic energy consumption that is influenced by varying factors, including flight dynamics (such as propulsion and mobility), changes in altitude, payload variations, and environmental conditions. As a result, this research aims to develop an energy model specifically for UAV applications and improve battery performance, ensuring better efficiency and reliability in real-world missions. E. Kim et al.31 emphasize the importance of predicting battery life for autonomous battery management systems (BMS) based on energy consumption during UAV missions. Zhang et al.32 investigated the impact damage of lithium batteries in small UAVs using experimental and simulation methods. They developed and validated a finite element model (FEM) through impact compression tests, which demonstrated minimal errors (≤ 5.67%). The findings revealed that the external battery box becomes less effective at high impact speeds, increasing the risk of internal battery damage, explosion, and fire. This underscores the necessity for impact-resistant battery enclosures in UAVs. The authors in33 address the energy limitations of multi-UAV networks in search and rescue (SAR) missions by proposing a mission-planning method that optimizes UAV trajectories, recharging schedules, and charging station placements to minimize mission completion time while ensuring efficient energy use. Zhang et al.34 review and classify various drone energy consumption models, analyzing their scope, design factors, and operational assumptions. They highlight that most studies rely on simplified, often linear, models that overlook nonlinear wind effects, which can result in energy predictions up to two times lower than actual consumption. Their findings also emphasize the wide variability in energy predictions across models and underscore the need for empirical validation to improve accuracy. The authors in35 propose a Bayesian inference-based battery health management technique to manage the energy consumption in UAVs. Battery modeling can be classified into three main types: Equivalent Circuit Models (ECMs), Electrochemical Models (EMs), and Data-driven (Black Box) Models. Several studies highlight that constant resistance battery models are well-suited for UAV applications due to their simplicity and efficiency36–39. These models provide a straightforward electrical representation, assuming constant internal resistance during operation, making them useful for basic energy management. However, their lack of adaptability to dynamic flight conditions and inability to model long-term battery degradation limit their effectiveness in real-world UAV missions. The existing literature highlights a significant research gap in addressing limited battery life in UAVs. While most studies have explored the estimation of UAV energy consumption, they often fail to fully model real-time power demand fluctuations and battery degradation dynamics, both of which are crucial for enhancing efficiency and extending flight time. Moreover, research on UAV battery performance estimation remains limited. Hence, this research aims to develop a better battery model capable of accurately predicting and managing energy consumption across key operational aspects, as illustrated in Fig. 3. These aspects include flight manoeuvres, communication, and payload handling, all of which are critical to enhancing overall mission performance and success. Main aspects of the energy consumption rate for FANET operation. Dynamic battery energy management, which intelligently adjusts the power based on real-time demands, is presented as a potential solution for extending battery life. By tailoring energy use to different tasks, the system can reduce stress on the battery and maximize efficiency. Therefore, incorporating an accurate and reliable battery energy consumption model is crucial for time-sensitive FANET missions. Without it, missions could be compromised, leading to failures, unnecessary delays, and increased energy consumption, ultimately diminishing the efficiency and operational success of UAVs. Table 3 presents the overview of the current literature on energy consumption models, and Table 4 discuss the related works on DRL techniques used specifically for UAVs. Table 3Overview of recent literature on energy consumption modelling of UAV.ReferencesProblemEnergy Aspects consideredModeling’s approachOptimization TechniquesKey findings & Batter performance considered[Y/N]Limitations 40 UAV swarm communication coverage optimizationEnergy usage information change, connectivity restorationTheoretical & ML-based models (XGBoost, regression)Cost function for swarm topology controlIdentified energy-efficient airspeed range; ML model achieved R² of 0.9999.Battery consideration: NORegression models lack extrapolation accuracy 41 Coverage path planning for UAVsWeight and Maximum speed.Energy model derived from real measurementsEnergy-aware path planning algorithmMinimizes energy consumption while ensuring coverage & resolution.Battery consideration: NODoes not account for dynamic environmental conditions. 42 UAVs as mobile base stations for ground user coverageTemporal energy consumption, connectivity, flight stability.Deep neural network (DNN)-based modelDecentralized DRL framework (DDPG)Improved coverage and fairness while reducing energy usageBattery consideration: NORequires extensive training data 43 Energy-efficient UAV target trackingVelocity, altitude, acceleration impact on energyAdaptive energy estimation modelZone-based control for UAV adjustmentsLimits UAV adjustments while maintaining target in viewBattery consideration: NOMay not adapt well to sudden target movements 44 UAV-based last-mile delivery optimizationEnergy consumption in relation to payload & battery weightMathematically derived energy modelMixed-integer linear programming (MILP), Simulated Annealing (SA) heuristicDemonstrates inverse exponential relationship between cost & delivery timeBattery consideration: NOLimited to theoretical and simulated validationProposedworkEnergy-efficient UAV operations in FANETs for SAR missionsFlight dynamics, payload operations, wireless communication energy consumptionMathematical analysis and simulation-based Multi-Agent Deep reinforcement learning (MADRL)Dual-battery system design and intelligence applied to secondary battery.Extends UAV endurance, maintains reliable connectivity, and improve overall performance.Battery consideration: YesTo ensure cost-effectiveness and safety, NS3 simulations were used. Future work will focus on real-world implementation Overview of recent literature on energy consumption modelling of UAV. Identified energy-efficient airspeed range; ML model achieved R² of 0.9999. Battery consideration: NO Minimizes energy consumption while ensuring coverage & resolution. Battery consideration: NO Improved coverage and fairness while reducing energy usage Battery consideration: NO Limits UAV adjustments while maintaining target in view Battery consideration: NO Demonstrates inverse exponential relationship between cost & delivery time Battery consideration: NO Proposed work Extends UAV endurance, maintains reliable connectivity, and improve overall performance. Battery consideration: Yes Table 4Related works explored DRL techniques in comparison with the proposed work.ReferencesResearch ProblemModelling approachKey contributionsSystem/Vehicle/DevicePerformance improvement 45 UAVs have limited battery life, affecting mission planningEmpirical energy model based on battery usage in different flight scenariosComprehensive UAV energy model.Accounts for flight conditions.Helps in energy-efficient planning.UAVsBetter energy prediction for optimized missions 46 High power consumption in dense IoT deployments (e.g., smart city scenarios)Green LoRa wireless networks powered by a hybrid of the grid and renewable energy sourcesProposes resource management schemes for channel and spreading factor (SF) allocation Formulates grid power consumption minimization problem Develop DRL-based adaptive resource management schemes Improves energy efficiency in LoRa networksLoRa wireless networksEfficient use of renewable energy and reduced grid power consumption 47 Resource management in massive IoT networksDeep reinforcement learning (DRL) with UAV-based base stations and clusteringUAVs act as base stations for air-to-ground communication IoT devices are clustered into urban and suburban groups K-means and round-robin scheduling optimize resource allocation TensorFlow-based evaluation demonstrates the efficiencyUAV-based IoT networksRapid convergence, suitability for heterogeneous networks, and low complexity Proposed work Limited battery life and unstable communication in FANET-based UAV missionsMADRL with a dual-battery system, modelling, and simulation using NS3Dual-battery system: B1 (flight/payload), B2 (communication/sensing), used our previous work hybrid 3-D Gauss Markov Mobility model, MADRL optimizes energy use and communication Enables energy-efficient dynamic UAV coordination in SARMulti-agent (FANET)Improved network connectivity and reduced energy wastage for longer missions Related works explored DRL techniques in comparison with the proposed work. Comprehensive UAV energy model. Accounts for flight conditions. Helps in energy-efficient planning. Proposes resource management schemes for channel and spreading factor (SF) allocation Formulates grid power consumption minimization problem Develop DRL-based adaptive resource management schemes Improves energy efficiency in LoRa networks UAVs act as base stations for air-to-ground communication IoT devices are clustered into urban and suburban groups K-means and round-robin scheduling optimize resource allocation TensorFlow-based evaluation demonstrates the efficiency Dual-battery system: B1 (flight/payload), B2 (communication/sensing), used our previous work hybrid 3-D Gauss Markov Mobility model, MADRL optimizes energy use and communication Enables energy-efficient dynamic UAV coordination in SAR In summary, numerous energy consumption models have been proposed for various UAV applications, employing diverse approaches to estimate power usage. However, these models often fail to accurately capture real-world UAV performance and energy efficiency, particularly in dynamic, multi-UAV environments like FANETs. As depicted in Fig. 3, energy consumption is predominantly driven by navigation, followed by communication, payload operations, and environmental factors such as wind or turbulence. To address these challenges, this research proposes a robust energy prediction and management model featuring a dual-battery system: a primary battery (B1) dedicated to flight dynamics and an ultra-low-weight secondary battery (B2) for communication. Integrated with MADRL applied to B2, this approach enables real-time power management, optimizing energy usage and extending operational life without compromising flight stability or network connectivity. By isolating critical functions and dynamically adapting to FANET conditions, the proposed system ensures efficient UAV operation, sustained communication, and enhanced mission success in complex, real-world scenarios. While DRL has demonstrated remarkable success in various robotic and game-playing tasks, its application to complex communication system control, particularly in dynamic environments like FANETs, remains largely unexplored. Also, this research aims to bridge this gap, investigating the effectiveness of MADRL in optimizing energy management for UAV communication systems. Modelling energy consumption of UAV dual battery system Problem statement The growing demand for electrical energy in UAV battery systems, especially for critical applications like SAR, highlights the need for accurate and reliable energy consumption modeling. A well-structured model can help optimize battery usage, enhance mission endurance, and improve UAV performance in real time. Before developing a comprehensive model, it’s crucial to identify and analyze the key factors that significantly influence energy consumption. This research focuses on the primary aspects of UAV power consumption, encompassing propulsion (motor operation), mobility, data transmission and reception, sensor usage, payload weight, and environmental conditions. Understanding how these factors contribute to battery drain is fundamental to creating an effective energy consumption model. Figure 4 illustrates the individual UAV system model within a FANET, depicting how energy is depleted under various operational conditions. As part of this work, we analyze the maximum energy consumption of hovering, high-speed flight, communication, and payload operations. Each scenario has unique power requirements due to its specific design, aerodynamics, and energy requirements. Therefore, we aim to model and simulate a dual-battery system in an NS3 simulator, where one battery handles mobility and propulsion while the other manages communication, processing, and sensing. Several modeling approaches have been proposed in the literature to maximize the battery life of UAVs. To optimize energy consumption, this work employs a DRL model based on Proximal Policy Optimization (PPO), which dynamically adjusts power allocation for communication and coordination tasks in FANET systems. Table 5 presents the energy consumption of UAVs in different operational modes, highlighting the impact of our proposed optimization technique. State Transition Diagram of a UAV in a FANET for SAR scene, illustrating energy consumption and battery energy management strategies. Table 5UAV operating States and energy demand.UAV statesBattery usageDescriptionEnergy demandIdleB2UAV is grounded or in a minimal power mode and is awaiting a mission start.LowHoveringB1UAV maintains position, requiring continuous thrust.HighFlight manoeuvringB1Sudden change in speed, altitude, or direction.Very highCommunicationB2Data transmission and receptionMediumProcessing/SensingB2Onboard computation and sensor operations.Medium UAV operating States and energy demand. Problem description The high energy demands of UAVs coupled with their limited battery capacity present a significant challenge, particularly in FANET systems where sustained operation, continuous inter-UAV communication, and mobility are essential for mission success, as illustrated in Fig. 4. Navigation, encompassing propulsion and flight stability, dominates energy consumption, followed by communication for maintaining network connectivity, payload operations, and environmental influences such as wind or turbulence as shown in Table 5. Existing energy consumption models have sought to mitigate these constraints but often adopt a narrow focus—targeting specific elements like flight dynamics or environmental conditions—rather than holistically addressing the intricate interplay of all contributing factors as shown in Fig. 3. This fragmented approach hampers the development of a unified model capable of accurately reflecting the dynamic energy demands of FANET environments, resulting in suboptimal power allocation and diminished operational efficiency. In FANETs, this challenge intensifies due to the persistent communication load required for real-time coordination among UAVs, which competes with the substantial energy needs of flight. Table 2 highlights the necessity of integrating an additional battery without increasing the overall UAV weight. Traditional single-battery architectures exacerbate the issue by coupling these critical functions—navigation and communication—leaving UAVs vulnerable to mid-mission failures when energy is depleted by excessive network demands or unforeseen environmental stressors. Furthermore, conventional static energy management strategies lack the flexibility to adapt to the diverse states, mission objectives, and environmental conditions across a UAV swarm, compromising flight stability, network reliability, and mission endurance. Consequently, these limitations undermine the effectiveness of UAVs in critical applications such as surveillance, disaster response, and environmental monitoring, where prolonged operation and robust connectivity are non-negotiable. This research underscores the urgent need for an innovative energy model and system design that dynamically optimizes power consumption, isolates flight and communication functions, and enhances energy efficiency to overcome these barriers and ensure successful FANET operations. System model The system model of the FANET, as illustrated in Fig. 4 and complemented by the depiction in Fig. 1, provides a comprehensive framework for optimizing UAV operations within a SAR mission in disaster-affected areas, with a strong emphasis on efficient energy management to enhance mission performance. The depiction in Fig. 1 highlights the application of the FANET system, where a network of UAVs collaboratively conducts search, surveillance, and target detection operations, operating as a distributed system with each UAV functioning as a mobile node to enable real-time communication and data sharing for effective coordination throughout the mission. This research aims to boost operational efficiency by maximizing communication performance, extending flight duration, and improving area coverage through strategic UAV energy expenditure. Figure 4 explains how UAVs operate through different states to save energy and complete their tasks effectively. Beginning with the idle state, where UAVs conserve energy while stationed or awaiting deployment, a low-power baseline is established to enhance endurance. From this state, UAVs transition to the process/sensing state, actively collecting data with sensors for surveillance and target detection, moderately increasing energy use to monitor the disaster environment. The process advances to the Flight manoeuvring state, which enables dynamic navigation to systematically cover the search area, reflecting the highest energy demand driven by propulsion requirements. At the model’s core, the Communication state facilitates real-time data sharing and coordination among UAVs, linking all states to ensure network reliability despite varying energy needs. A key focus of this work is identifying the primary drivers of power consumption—propulsion energy, essential for flight and mobility, and communication energy, critical for network operations, recognizing that propulsion demands significantly outweigh communication needs. To address this, the research introduces an innovative dual-battery system, prioritizing propulsion with the primary battery while applying intelligent energy management to the secondary battery to alleviate energy stress, ensure stable communication, and enhance UAV fail-safe mechanisms. Integrating these states into this energy management strategy optimizes overall performance and endurance, aligning with the mission’s demands in challenging SAR scenarios. Reinforcement learning (RL) Reinforcement Learning (RL) is a goal-oriented machine-learning algorithm designed to address decision-making challenges, where agents learn optimal behaviours by interacting with their environment through trial and error, receiving rewards (positive or negative) as distinct feedback to guide their learning process. As a subset of deep reinforcement learning, RL is particularly effective for solving real-time Markov Decision Problems (MDP)47,48, enabling adaptive and intelligent decision-making in dynamic scenarios, and the working methodology is shown in Fig. 5. RL operates on the reward hypothesis, involving key elements such as state (e.g., S0​, the initial situation), action (e.g., A0, the decision taken), and reward (e.g., R1​, the feedback received). In this study, the goal-seeking agent is a UAV within the FANET system, where it continuously monitors its state—specifically flight battery usage (B1), flight demand, and communication needs—to make informed decisions that optimize energy consumption and enhance mission performance in SAR operations. DRL working methodology using ns3-gym framework with ns-3 network simulator. Proposed DRL-based energy optimization for FANET system in SAR operation Deep reinforcement learning (DRL) DRL, a powerful machine learning approach, combines the decision-making capabilities of RL with the complex pattern recognition of deep neural networks for more complicated decisions. By learning through trial and error, DRL enables UAVs to effectively manage their states based on real-time network conditions using neural networks for target optimization. The study focuses on maximizing battery life (B1 & B2) while maintaining robust communication links. As a part of DRL, UAVs act as intelligent agents, dynamically determining their optimal state mapping best action by continuously assessing their energy levels (B1 for flight and payload operations, B2 for communication and sensing), communication demands, and overall mission progress to the reward they lead to. This adaptive decision-making process enhances the efficiency and reliability of UAV coordination in SAR missions. The proposed DRL agent is developed and evaluated using the ns3-gym framework, as shown in Fig. 5. The DRL agent manages the secondary battery (B2), which powers communication and sensing functions in UAVs operating within FANET scenarios. Using the ns3-3 gym, the modelled agent can learn the FANET dynamic environment through observations and rewards from the simulated network of secondary battery b2 energy consumptions of the FANET system under various conditions over many episodes. The actions selected by the agent for the next time steps can be applied to the simulated network, as shown in Fig. 5. Figure 6 illustrates the proposed DRL framework, which aims to extend battery life in critical SAR operations by dynamically controlling UAV states (detailed in Table 5) based on learned policies. Specifically, we utilize the PPO algorithm, a popular DRL method known for its efficiency and stability49. By learning to predict the optimal actions in various operational states, PPO enables each UAV to make energy-efficient decisions, balancing the need for low B2 consumption with acceptable communication performance, such as high throughput and minimal packet loss. Schematic diagram of Dual-battery-based UAV system using Deep Reinforcement Learning Architecture. According to Fig. 4, the PPO algorithm serves as the decision-making agent for each UAV in the SAR scenario. These agents learn an optimal policy by using a neural network to determine the UAV’s state at each time step to maximize the overall performance of the SAR scene. Given the complexity of the FANET-based SAR environment, which involves multiple tasks, a high-dimensional state space, and a multi-objective reward function, conventional Q-learning-based RL approaches are insufficient. The problem of UAV (B2) energy consumption is mathematically modelled as a Markov Decision Process (MDP), where an agent interacts with an environment over discrete time steps. This model is defined by the tuple (St, At, Rt, St+1). Below, we present the formal mathematical definitions of States, Actions, Rewards, and State Transitions, which illustrate how it is implemented in our work. State (St): The state St represents the current situation of the agent at time step t. It encapsulates all the relevant information the PPO agent needs to decide. Formally, the states are denoted by {s1,s2,.sn}, where n is the total number of distinct states in the SAR environment. In our work, the state St is a vector that includes the following features for each of the UAVs (nodes) in FANET extracted from NS-3. These states include B2 energy percentage, UAV positions, throughput, packet loss, delay, and current state (as shown in Table 5, Idle, Processing, Sensing, Communication). Action (at): The action at is the agent’s decision at time step t based on the current state St to optimize its operation and energy consumption. Formally, we define the Actions (at) as the set of all possible actions denoted by A = {a1, a2, …, ap}, where p is the total number of distinct actions available to the system. In our work, each UAV node can independently choose an action from a discrete set to adjust to optimize energy efficiency while maintaining connectivity. For example, UAV: Switch to Idle (low energy consumption). Reward (rt): The reward rt is the feedback the agent receives after taking action at​ in state St and transitioning to the next state St+1 ​. The reward guides the agent’s learning by indicating the quality of the action. Formally, the reward is defined as a function that maps state-action pairs to real numbers, denoted by r (s, a), where s is the current state and a is the action taken. The agent’s goal is to maximize the expected cumulative reward. In our work, the reward for each UAV is a weighted sum of four components: B2 Energy reward (optimizing energy), Communication reward (maximizing throughput and minimizing delay), State penalty, and Energy decrease penalty. State Transition (St+1): Based on the selected action, the UAV’s state transitions to a new state, St+1​, which is fed back to the DRL agent. The next state is updated in ns-3, considering factors such as the new position, battery levels (B1, B2), network conditions, and other relevant metrics. The simulator applies an energy consumption model to each UAV’s batteries, adjusting the levels of B1 and B2 in real time based on the actions taken by the UAV. This energy consumption is taken into account when calculating the reward and adjusting the next state. State–action–reward design and discretization justification In the proposed PPO-based dual-battery energy management framework, each UAV agent observes local environmental parameters that reflect both communication and propulsion states. The state vector is defined as: where: : Remaining percentage of communication battery, : Remaining percentage of communication battery, : 3D position (x, y, z) normalized within [0,1], : 3D position (x, y, z) normalized within [0,1], : Current throughput (Mbps), : Current throughput (Mbps), : Packet Loss Ratio, : Packet Loss Ratio, : Communication delay (s), : Communication delay (s), : Current operating mode (hover/transmit/move). : Current operating mode (hover/transmit/move). The action space is defined as a discrete control set: where each action corresponds to a fixed transmission power level and mobility throttle adjustment that jointly affect energy consumption and QoS. This discretization was chosen over a continuous control policy to ensure training stability, lower sample complexity, and faster convergence, which are critical in real-time FANET simulations. While continuous power control or rate adaptation could provide finer granularity, tests with continuous-action PPO resulted in unstable convergence and overfitting to transient network conditions. The 3-level discretization provided a good balance between expressiveness and convergence stability, yielding consistent energy–QoS trade-offs. The reward tensor is designed as: where: : Throughput efficiency (normalized), : Throughput efficiency (normalized), : Delay penalty, : Delay penalty, : Packet loss ratio, : Packet loss ratio, : Combined energy drain from B1 and B2, : Combined energy drain from B1 and B2, and represent scalar weights , tuned through grid-based sensitivity analysis (refer to Fig. 10). and represent scalar weights , tuned through grid-based sensitivity analysis (refer to Fig. 10). Baseline performance comparison: single battery (faster depletion, shorter mission life) vs. dual battery (extended mission life). For stability, input normalization was applied: Each continuous feature in is scaled to [0,1], Each continuous feature in is scaled to [0,1], Observation noise follows a Gaussian distribution to simulate sensor uncertainty, Observation noise follows a Gaussian distribution to simulate sensor uncertainty, Clipping is enforced on rewards within , Clipping is enforced on rewards within , Gradient clipping (max norm = 0.5) and entropy regularization (β = 0.01) were used to stabilize PPO training. Gradient clipping (max norm = 0.5) and entropy regularization (β = 0.01) were used to stabilize PPO training. Modified 3D Gauss–Markov mobility model and SAR trajectory comparison The UAV mobility in the proposed FANET is governed by a modified 3D Gauss–Markov process, expressed as: where. denotes the velocity vector , denotes the velocity vector , is the mean velocity (set to 10 m/s), is the mean velocity (set to 10 m/s), is Gaussian noise, is Gaussian noise, is the temporal correlation factor controlling motion smoothness (set to 0.7 for SAR stability). is the temporal correlation factor controlling motion smoothness (set to 0.7 for SAR stability). To reflect SAR-specific patterns: Acceleration bounds: ±2 m/s² to emulate realistic UAV thrust transitions, Acceleration bounds: ±2 m/s² to emulate realistic UAV thrust transitions, Altitude envelope: 50–120 m (maintaining coverage and LOS communication), Altitude envelope: 50–120 m (maintaining coverage and LOS communication), Heading update: biased every 30 s toward an expanding frontier or detected cue region. Heading update: biased every 30 s toward an expanding frontier or detected cue region. The model incorporates bias terms to emulate three common SAR strategies: Lawn–Mower Pattern: Alternating sweeps along the x–y plane by constraining yaw updates to ± 180°. Lawn–Mower Pattern: Alternating sweeps along the x–y plane by constraining yaw updates to ± 180°. Expanding Square: Incremental radial increase in distance bias from origin, m every 60 s. Expanding Square: Incremental radial increase in distance bias from origin, m every 60 s. Target–Cueing: Localized velocity reorientation toward regions of high signal intensity. Target–Cueing: Localized velocity reorientation toward regions of high signal intensity. The proposed modified 3D GM transitions smoothly among these modes through the PPO agent’s adaptive exploration policy. The Table 6 shows the comparison of the modified 3D GM and SAR trajectory. Table 6Comparison of modified 3D GM vs. Task-Driven SAR (Lawn-Mower).ModelAvg Energy (J)Throughput (Mbps)Delay (s)PLR (%)Coverage Area (m²)RemarksModified 3D GM11200.0250.089.596,000Adaptive to dynamic regionsLawn-Mower12800.0210.1012.088,000Deterministic sweep, slower responseΔEnergy = − 12.5%, ΔThroughput = + 19%, ΔPLR = − 2.5% (Modified GM vs. Lawn-Mower). Comparison of modified 3D GM vs. Task-Driven SAR (Lawn-Mower). ΔEnergy = − 12.5%, ΔThroughput = + 19%, ΔPLR = − 2.5% (Modified GM vs. Lawn-Mower). MADRL (multi-UAV with PPO) simulation using NS3-Gym environmental setup: training phase We consider using the ns-3 simulator and a DRL agent (Python-based) run separately; we define multi-UAV scenarios with ns-3 by specifying nodes, wireless connections between the UAVs, a modified version of our previous work 3D-gauss Markov mobility model6, traffic models, and a proposed energy model framework for dual batteries in each UAV. As illustrated in Fig. 7, the DRL model (specifically PPO) interacts with the UAV network and receives an environment state at each time step. It collects a large batch of experiences — a rollout collection to improve its policy, which is fundamental to RL. Then, optimization process, PPO uses the neural network to estimate the best action probabilities over time are passed through ns-3, which update the UAV state St+1, and ns3 applies the corresponding energy consumption rate to B1 and B2. The mathematical illustration of PPO is explained in detail as: Proposed DRL-Based Model PPO for each UAV secondary Battery (B2). We consider the traditional reinforcement learning (RL) setup for this work. At time t, the UAV observes its state St and interacts with the environment E. At time t, the UAV observes its state St and interacts with the environment E. Selects an action at according to its policy (at∣st). Selects an action at according to its policy (at∣st). Environment transitions to a new state St+1 and provides reward rt. Environment transitions to a new state St+1 and provides reward rt. UAVs learn to reach a goal, i.e. optimal policy by maximizing the expected cumulative reward (return) over time. UAVs learn to reach a goal, i.e. optimal policy by maximizing the expected cumulative reward (return) over time. UAV goal is defined as a reward function r over time t given as. UAV goal is defined as a reward function r over time t given as. Where ​​ is the expectation over the states and actions sampled from the policy πθ​, ​​ is the expectation over the states and actions sampled from the policy πθ​, θ is the parameter of the policy. θ is the parameter of the policy. rt. is the reward at time step t, rt. is the reward at time step t, Ύ(0,1) is a discount factor, Ύ(0,1) is a discount factor, π*, the optimal policy is the UAV’s behavior at a given time. π*, the optimal policy is the UAV’s behavior at a given time. The PPO algorithm uses a deep neural network, shown in Fig. 6, as a policy approximator that maps environmental states to action probabilities. In our proposed dual-battery UAV system, this network helps the UAV agent interpret its current state and choose the best action based on the transition probability function P(st+1∣st, at). As shown in Fig. 4, each environmental state includes possible actions sorted by energy levels—low, medium, and high. The input to the PPO agent is the current system state, obtained from the NS-3 simulator through the NS-3gym interface. The output is a probability distribution over available action. When an action at is selected, it directly affects the next state st+1. For example, if the agent picks a communication-heavy action, the B2 energy level in the next state decreases due to its energy cost. NS-3gym models these state changes by simulating the UAV’s energy use and communication behaviour in real time. This interaction allows the PPO agent to learn the long-term effects of its actions, helping it develop policies that reduce B2 energy use while keeping communication performance acceptable. To train the PPO model, we used the Adam optimizer, chosen for its ability to handle sparse gradients and adjust learning rates on the fly—both important for optimizing in complex, dynamic environments like FANETs. Training ran over 500 epochs, giving the agent enough interaction with the environment to learn effective energy management strategies across UAV node counts from 5 to 50. Each epoch included multiple simulation rollouts to gather experience trajectories, followed by updates to the policy and value functions using mini-batch gradient descent. This process helps the PPO agent steadily improve its policy by balancing exploration and exploitation, resulting in an energy-aware control system that adapts to different mission requirements and network sizes. Convergence was observed with the episodic reward curve stabilizing after approximately 350 epochs, indicating an optimal policy for energy-efficient communication and mobility. To ensure reproducibility, a fixed random seed was applied, with multiple runs reporting mean and variance of performance metrics, addressing variability from simulation stochasticity and hardware differences. The PPO algorithm in UAV agents uses the policy gradient technique50 to optimize the policy directly by computing the gradient of the expected return with respect to the policy parameters θ is given as: Where: – The policy, a probability distribution over actions. ∇θ – gradient of the log probability of the action, which points in the direction of increasing the likelihood of at. At​ – advantage function, which measures how good the action at is compared to the average action in a given state st. This can be estimated as: where Q(St,At) is the action-value function, and V(St) is the state-value function. PPO uses the Generalized Advantage Estimation (GAE) to compute At​: Where: = rt + ) – V (st;: The temporal difference (TD) error. – discount factor. – GAE parameter, which controls the bias-variance trade-off in advantage estimation. V (st;– The value function, approximated by a neural network weight ϕ. The GAE formula can be written as: Where α alpha is the learning rate (step size). PPO maximizes the expected return Rt by optimizing a surrogate objective function that approximates the policy improvement (Take action lead to high reward). The standard policy gradient objective (used in methods like REINFORCE) is: However, directly optimizing this can lead to large policy updates, causing instability. PPO introduces a clipped surrogate objective to constrain the policy update. The unclipped clipped surrogate objective is given as follows PPO clips this objective to prevent large policy updates: Where: ϵ– Clipping parameter (stable-baselines3 uses a default of 0.2). clip(rt​(θ),1−ϵ,1+ϵ) – Clips rt​(θ) to the range [1−ϵ,1+ϵ]. The clipping ensures that the policy doesn’t change too much: If At​>0 (the action is better than average), PPO encourages increasing the probability of at, but only up to a factor of 1+ϵ. If At​>0 (the action is better than average), PPO encourages increasing the probability of at, but only up to a factor of 1+ϵ. If At​<0 (the action is worse than average), PPO encourages decreasing the probability of at​, but only down to a factor of 1−ϵ. If At​<0 (the action is worse than average), PPO encourages decreasing the probability of at​, but only down to a factor of 1−ϵ. The probability ratio is given as: Where: – denotes the probability ratio between the current and old policy. – policy parameter before update, , a policy parameter after update. If > 1, the new policy is more likely to take action​ than the old policy; otherwise, the new policy is less likely to take action . The action space for this work is discrete, with the actions including low, medium, and high energy modes based on policy and use mini batch updates. In the multi-UAV systems with dual batteries (B1, B2), energy consumption is integrated into the reward function. For example, the reward can be penalized if battery levels fall below a certain threshold or if excessive energy consumption occurs. This can be represented as: where λ is a weighting factor for battery depletion. PPO also updates the value function V(s;ϕ) to better estimate the expected return. The value function loss is: Where Rt​ is the discounted return: Rt​ is approximated using the GAE advantage and the value function. To encourage exploration, PPO adds an entropy bonus to the objective. The entropy of the policy π(a∣s;θ) is: The entropy bonus is: The final PPO objective combines all terms: where: c1​: Weight for the value function loss. c2​: Weight for the entropy bonus. PPO performs multiple epochs of optimization on the collected batch of data: For each epoch, split the batch into mini batches, compute the gradients of L(θ,ϕ) concerning θ and ϕ, and update the parameters using an optimizer like Adam. The pseudo-code for the proposed DRL (PPO) for UAV energy optimization is presented in Algorithm 1. In this algorithm, we initialize two neural networks – Actor and Critic for each UAV within the FANET system with random weights θ and φ—the policy here we defined as MlpPolicy (multi-layer perceptron). PPO will generate batches of experience by interacting with the environment using the current policy, as said in line 5. PPO approach in our work alternates between data collection and updating its policy has total M episode to learn an optimal policy for managing B2 energy. Collected trajectories are stored in a buffer B is initialized in line 6. For each experience in the buffer, the advantage Ai​ is computed to measure how good the action ai​ was compared to the average action in state si. Rewards are given dynamically depending on UAV states and actions to extend battery life while ensuring mission success in SAR operations, as shown in Table 7. Table 7UAV Mobility, energy Parameters, and DRL-PPO reward Mechanism.StatesMobilityX Y ZEnergyThrustVelocityReward Function (R)Idle (S0)0 0 00 (Minimal Energy Usage)-5 m/sR=−β (penalty for prolonged idleness)Processing_Sensing (S1)d1 d2 d3Ep​ (Processing Energy)010 m/sR=+η(Task Completion)−θ(Computation Latency)Communication (S2)d1 d2 d3ETx, ERx (Transmission/Reception Energy)010 m/sR=+λ(Successful Packet Transmission)−δ(Packet Loss)Flight Dynamics (S3)d1 d2 d3Ef​ (Flight Energy)THm​ (Thrust for Mobility)20 m/s(Max Speed)R=−αEf​+γ(Mission Progress) UAV Mobility, energy Parameters, and DRL-PPO reward Mechanism. 20 m/s (Max Speed) DRL Approach Using PPO UAV Energy Optimization. In line 8, Generalized Advantage Estimation (GAE) smooths the advantage estimation over multiple steps, reducing variance compared to single-step estimates. This advantage guides the policy update: positive Ai​ encourages the action, while negative Ai​ discourages it. Both policy and value function are updated by gradient ascent (e.g., Adam optimizer) with learning rate α = 10−4. Policy optimization The design of the reward function for the PPO agent in our dual-battery energy consumption model for FANET SAR missions involves a multi-objective optimization problem with competing terms, necessitating a carefully crafted weight tuning strategy. The reward function is formulated as a weighted sum of multiple competing objectives, reflecting the dual-battery system’s goals: preserving B2 energy for communication, maximizing throughput, minimizing packet loss, and reducing end-to-end delay. A general form of the reward function can be expressed as: Where: RB2_energy​ rewards maintaining a higher B2 energy percentage (e.g., scaled between 0 and 1 based on remaining energy). RB2_energy​ rewards maintaining a higher B2 energy percentage (e.g., scaled between 0 and 1 based on remaining energy). Rthroughput rewards higher data rates (e.g., normalized to a maximum achievable throughput). Rthroughput rewards higher data rates (e.g., normalized to a maximum achievable throughput). Rpacket_loss​ penalizes increased packet loss (e.g., inversely proportional to loss ratio). Rpacket_loss​ penalizes increased packet loss (e.g., inversely proportional to loss ratio). Rdelay​ penalizes higher latency (e.g., inversely proportional to delay in seconds). Rdelay​ penalizes higher latency (e.g., inversely proportional to delay in seconds). w1,w2,w3,w4 w_1, w_2, w_3, w_4 w1​,w2​,w3​,w4​ are the weights assigned to each term, summing to 1 to ensure a balanced contribution. w1,w2,w3,w4 w_1, w_2, w_3, w_4 w1​,w2​,w3​,w4​ are the weights assigned to each term, summing to 1 to ensure a balanced contribution. The weight tuning strategy began with an initial equal weighting (e.g., w1 = w2 = w3 = w4 = 0.25 w_1 = w_2 = w_3 = w_4 = 0.25 w1​=w2​=w3​=w4​=0.25) to establish a baseline agent behaviour. However, given the critical importance of B2 energy preservation for SAR mission endurance, an iterative tuning process was employed. This involved: Prioritization Adjustment: Increasing W1(e.g., to 0.4) to emphasize B2 energy conservation, reflecting the dual-battery model’s design focus. Prioritization Adjustment: Increasing W1(e.g., to 0.4) to emphasize B2 energy conservation, reflecting the dual-battery model’s design focus. Trade-off Exploration: Reducing w2 and w3 (e.g., to 0.2 each) and adjusting W4​ (e.g., to 0.2) to assess the impact on throughput and packet loss versus delay, using simulation data. Trade-off Exploration: Reducing w2 and w3 (e.g., to 0.2 each) and adjusting W4​ (e.g., to 0.2) to assess the impact on throughput and packet loss versus delay, using simulation data. Grid Search and Validation: Conducting a grid search over a range of weight combinations (e.g., w1:0.3–0.5 w_1: 0.3–0.5 w1​:0.3–0.5, w2,w3,w4:0.1–0.3 w_2, w_3, w_4: 0.1–0.3 w2​,w3​,w4​:0.1–0.3) across 500 epochs, with validation on test episodes (e.g., 16–20 nodes) to identify the configuration yielding the highest cumulative reward and optimal performance metrics. Grid Search and Validation: Conducting a grid search over a range of weight combinations (e.g., w1:0.3–0.5 w_1: 0.3–0.5 w1​:0.3–0.5, w2,w3,w4:0.1–0.3 w_2, w_3, w_4: 0.1–0.3 w2​,w3​,w4​:0.1–0.3) across 500 epochs, with validation on test episodes (e.g., 16–20 nodes) to identify the configuration yielding the highest cumulative reward and optimal performance metrics. Dynamic Tuning: Incorporating a sensitivity analysis to adapt weights during training based on observed trends (e.g., increasing w3 ​ if packet loss exceeded a threshold), though this was constrained by computational resources. Dynamic Tuning: Incorporating a sensitivity analysis to adapt weights during training based on observed trends (e.g., increasing w3 ​ if packet loss exceeded a threshold), though this was constrained by computational resources. The final weights were selected as w1 = 0.45 w_1 = 0.45 w1​=0.45, w2 = 0.25 w_2 = 0.25 w2​=0.25, w3 = 0.15 w_3 = 0.15 w3​=0.15, and w4 = 0.15 w_4 = 0.15 w4​=0.15, prioritizing B2 energy while moderately balancing communication performance, based on the stable convergence observed after 350 epochs. Testing phase In the testing phase, the trained policy of our proposed approach is loaded to evaluate its performance in terms of B2 energy conservation. We reset the environment E to its initial state with all UAVs. Next, we initialize B2 ← ∅ to store the average B2 energy percentage at each step. For each time step from t to T, every UAV receives its state St and selects the action at​ with the highest probability under the policy π(a∣st​;θ), which results in receiving the reward rt and transitioning to the next state St + 1. This process continues until the final time step T, where the average B2 energy percentage across all UAVs is calculated to demonstrate the learned policy’s effectiveness in optimizing UAV energy and maintaining stable communication. Energy model justification and sensitivity analysis The dual-battery framework uses two separate power sources: B1 (propulsion) and B2 (communication and processing). To ensure realistic modeling, their initial energies were estimated from typical specifications for micro-UAV components. Propulsion subsystem (B1): Propulsion subsystem (B1): A brushless DC motor operating at approximately 12 V and 4 A draws about 48 W. For a standard 20-minute endurance, the total propulsion energy is calculated. Considering scaled-down FANET UAVs, only about 2% of the full-scale energy is modeled, resulting in approximately 1000 J of equivalent battery capacity for simulation. Communication and onboard electronics (B2): Communication and onboard electronics (B2): Wi-Fi/5G radio consumes roughly 1.2 W, CPU about 0.8 W, and sensors around 0.5 W, totaling approximately 2.5 W. During a 120-second mission cycle, the energy consumption amounts to roughly. Therefore, B2, with 300 J, realistically represents the energy used for short-range communications and processing per mission. To validate robustness, a sensitivity analysis was performed with B2 values scaled by 0.5×, 1×, and 2 × (150 J, 300 J, and 600 J). The proposed PPO-based dual-battery controller dynamically adapts to these variations, maintaining overall mission continuity. Table 8 below summarizes the observed total mission energy (TE) and energy coupling between B1 and B2, where heavier communication loads raised propulsion energy cost by 3–7% due to additional onboard mass and heat dissipation. Table 8Summarization of total mission energy (TE) and energy coupling.B2 Energy (J)B1 Energy (J)Total Mission Energy TE (J)Avg Throughput (Mbps)Delay (s)Energy Coupling Effect150 J (0.5×)1000 J10800.0210.10Low comms activity, stable propulsion300 J (1×)1000 J11300.0250.08Balanced trade-off600 J (2×)1000 J12400.0270.09Slight propulsion rise (mass/heat + 7%) Summarization of total mission energy (TE) and energy coupling. Experimental evaluation and results discussion FANET SAR mission In a FANET SAR mission (Fig. 1), UAVs collaborate to execute search and rescue tasks in dynamic and often hazardous environments, such as disaster zones or remote areas. The UAVs must maintain flight, communicate with each other to establish an ad hoc network, process sensor data (e.g., imaging, thermal scans), and adapt to changing conditions (e.g., network demand, environmental factors). Keeping UAVs operational requires managing their energy resources, ensuring reliable communication, and optimizing their behavior to enhance mission success. The NS-3 simulation models these processes using a dual battery energy framework (B1 for flight (set initial energy 1000 joules), B2 for communication/processing/sensing (set initial energy as 300 joules) and employs a DRL(PPO) framework to optimize B2 energy consumption. Our custom energy model for B2 manages energy for three states: Idle (0.05 A), Processing Sensing (0.1 A), and Communication (0.2 A TX, 0.15 A RX), with state transitions driven by network demand, velocity, and B1 energy levels. EB1 (B1 battery energy) = Flight Dynamics. EB1 (B1 battery energy) = Flight Dynamics. EB2 (B2 battery energy) = System power + Rx/Tx+Radio + Processor + Sensor. EB2 (B2 battery energy) = System power + Rx/Tx+Radio + Processor + Sensor. TE (Total Energy) = EB1 + EB2. TE (Total Energy) = EB1 + EB2. Key performance metrics To evaluate the effectiveness of our proposed PPO approach in optimizing B2 energy consumption while maintaining stable communication between UAV nodes in a dynamic SAR operation, the following key performance metrics are defined: Average Energy Percentage of B2 at time step T: Average Energy Percentage of B2 at time step T: This metric measures the average percentage of initial B2 energy remaining across all UAV nodes over the entire SAR mission. It reflects the PPO policy’s effectiveness in conserving B2 energy, which powers communication and processing tasks critical for the SAR operation. 2.Average Throughput (Mbps): Average Throughput (Mbps): This metric measures the average data transmission rate (Mbps) across all UAV nodes over the entire SAR mission. It is derived from the Total Received Bits and Total Simulation Time, providing a standardized measure of communication efficiency. This metric evaluates the PPO policy’s ability to maintain effective data exchange while optimizing B2 energy. 3.Average Packet Loss Ratio. Average Packet Loss Ratio. This metric measures the average percentage of packets lost during transmission across all UAV nodes over the entire SAR mission. It evaluates communication reliability, as high packet loss can disrupt coordination in the SAR operation. 4.Average Delay: Average Delay: This metric measures the average time (in seconds) taken for messages to be transmitted between UAV nodes over the entire SAR mission. It assesses the timeliness of communication, which is crucial for real-time coordination in SAR operations. Simulation and experimental setup This research was conducted using the NS-3 Gym framework, integrating NS-3 network simulation with the proposed dual-battery energy consumption model for each UAV. A PPO agent (as shown in Fig. 5) is employed to maximize mission duration and communication efficiency while minimizing energy depletion, adapting to dynamic conditions (e.g., network demand, UAV velocity) in real time. The Modified 3D Gauss-Markov Mobility Model of our previous work6 is used to simulate UAV movement, improving trajectory prediction and energy efficiency. The simulation setup consists of varying numbers of UAVs and communication conditions to evaluate the effectiveness of the PPO-based approach. The agent learns over episodes and time slots, with the environment providing feedback based on the simulation. The key simulation parameters are listed in Table 9. Table 9Simulation Parameters.ParameterValueSimulation Steps1000 sPhysical & MAC LayerIEEE 802.11Transport ProtocolTCPNumber of UAVs5, 10, 15Mobility ModelModified 3D Gauss-Markov Mobility ModelPropagation ModelConstant Speed Propagation with Friis Propagation LossPacket Size100, 200, 300 bytesMax Number of Packets10, 20, 100Delay1 msNumber of States4(Idle, Processing_Sensing, Communication and Flight dynamics)UAV Parameter and its valuesVelocity range: 5 to 20 m/sAlpha: 0.853D Bounding box: (10,10,10) to (100,100, 90 to 100)Direction: 0 to 2piPitch: 0.05Energy Parameters and its valuesB1 Battery (Flight dynamic state set initial energy = 1000 joules), B2 Battery (Models energy for communication, processing, and sensing set initial energy = 300 joules), supply voltage = 3 V Simulation Parameters. Velocity range: 5 to 20 m/s Alpha: 0.85 3D Bounding box: (10,10,10) to (100,100, 90 to 100) Direction: 0 to 2pi Pitch: 0.05 The following characteristics were obtained from the simulation platform (NS3) using the following modules: NS3 version 3.40, NetSimulator (for 3D realistic simulation of UAVs), Flow Monitor for capturing packet flows, and other graphical modules. The results derived from the simulations conducted for the system model defined in Table 6 are as follows. PPO hyperparameter configuration and training setup PPO training configuration The PPO agent was trained for 500 epochs (≈ 1,000,000 environment steps) using the Adam optimizer with a learning rate of 3 × 10⁻⁴. The discount factor (γ) was set to 0.99, and the GAE parameter (λ) to 0.95. The clipping parameter (ε) was fixed at 0.2. Each training batch contained 4096 samples, divided into 32 minibatches. The value loss coefficient (c₁) and entropy coefficient (c₂) were set to 0.5 and 0.01, respectively. A linear learning-rate decay schedule was applied. Training stability was ensured by running five independent seeds, and the mean ± 95% confidence interval (CI) of episodic rewards was plotted to show convergence, as shown in Fig. 8, which was typically achieved after ~ 350 epochs. The seed-to-seed variance remained below 5% for final reward values, confirming robustness. PPO Learning Curve – Mean Episodic Reward (± 95% CI) over training epochs. In ns3-gym, the UAVs adopt a slotted time approach, where each UAV transitions between different states at predefined intervals. These intervals vary among different UAVs, enabling diverse mission dynamics. The PPO agent interacts with the UAV network, receiving state observations from ns-3, taking actions to optimize B2 energy consumption, and receiving rewards based on mission efficiency. Based on these settings, the following characteristics were plotted. As shown in Fig. 9, the performance metrics of the FANET SAR mission assess the effectiveness of the proposed dual-battery energy consumption model integrated with DRL using PPO across different UAV node counts. To verify its effectiveness, we compare the PPO-based model with our previous reinforcement learning (RL) approach6 and a baseline heuristic model that uses static, energy-aware routing without adaptive learning. All models were tested under identical simulation conditions with the NS-3gym framework, and the results were averaged over multiple runs. 95% confidence intervals are included to demonstrate the statistical robustness and reproducibility of the results. Performance metrics of a FANET SAR mission using the proposed model simulated with NS-3gym, showing (a) energy efficiency, (b) throughput, (c) packet loss, and (d) delay across varying UAV node counts. In Fig. 9(a), the average B2 energy percentage gradually decreases from around 74% at 5 nodes to 66% at 20 nodes. This decline indicates increasing energy use for communication and processing as the network densifies. UAVs operate in a dynamic 3D mission space (simulated with Netsimulyzer) and handle data transmission involving mixed traffic types (TCP, UDP, PING). Despite this increased demand, the PPO-based model maintains energy performance effectively across the swarm. The widening of the confidence interval at higher node counts suggests the B2 battery becomes more sensitive to network scale. Figure 9(b) shows the average throughput dropping from 0.12 Mbps at 5 nodes to 0.02 Mbps at 50 nodes. This trend reflects the model’s energy-aware approach that conserves the limited capacity of the lightweight B2 battery by selectively limiting transmission activity at higher node densities. While throughput decreases, it aligns to maximize mission longevity in resource-limited SAR operations. In Fig. 9(c), the packet loss ratio rises from 5% at 5 nodes to 15% at 50 nodes, mainly due to the conservative communication policy driven by B2’s energy constraints. Although both RL (6.5%) and PPO (6.7%) perform much better than the baseline (13.7%), packet loss tends to increase with more nodes. This trade-off indicates the model prioritizes energy efficiency over aggressive data transmission in high-load scenarios. Figure 9(d) illustrates the end-to-end delay increasing from 100 ms at 5 nodes to 200 ms at 50 nodes. The PPO model achieves the lowest average delay (67ms), outperforming both the baseline (100 ms) and our previous RL method (87 ms). This improvement results from optimized policy learning that balances conserving energy with maintaining low latency, which is crucial in time-sensitive SAR missions. Overall, the results in Fig. 8 confirm that the proposed PPO-based dual-battery model provides better performance regarding energy efficiency, throughput, packet loss, and delay compared to traditional RL and non-learning baseline strategies. This validates the architecture’s ability to support scalable and energy-resilient FANET deployments during SAR missions. Additionally, as shown in Fig. 9, the dual-battery design—which separates propulsion energy (B1) from communication energy (B2)—offers notable advantages over traditional single-battery systems. It maintains stable B2 energy levels and supports higher throughput as node density increases. While minor trade-offs in packet loss and delay appear due to B2’s limited capacity, these are managed strategically to maximize mission endurance. This innovative dual-battery, energy-aware framework represents a significant contribution to our research, addressing essential needs for lightweight, energy-efficient, and communication-resilient UAV operations in emergency and SAR environments. In Fig. 10(a), the term “Mission Life End” refers to the critical point at which the single battery UAV system can no longer sustain the mission due to energy depletion. This is marked by the vertical dashed line at 12 nodes, indicating that when the network size reaches 12 UAV nodes, the single battery system’s energy drops below the operational threshold, leading to mission failure or early termination. Here, the graph shows that in the single battery setup, as the number of UAVs increases, the residual energy decreases rapidly, and by 12 nodes, energy levels fall to critical lows (some nodes dropping to near 0%). In contrast, our dual battery system maintains higher residual energy levels across all nodes, demonstrating better load distribution and prolonged operational capacity. This graph, in Fig. 11, illustrates the average B2 energy percentage of UAVs over a 500-step SAR mission, evaluated for models trained using DRL with PPO at 200,000-, 500,000-, and 1,000,000-time steps. Starting at 100% energy, the 200,000-timestep model shows the steepest decline, averaging 68.3% by the end of the mission, reflecting a less optimized policy. The 500,000-timestep model demonstrates moderate improvement, averaging 78.5%, while the 1,000,000-timestep model achieves the highest performance, maintaining an average of 85.7% energy, indicating superior energy management due to extended training with GAE. The progressive improvement across training durations emphasizes the effectiveness of longer time steps in refining the policy, with the 1,000,000-timestep configuration emerging as the optimal choice for sustaining energy efficiency in this NS-3 simulated FANET SAR scenario, despite potential diminishing returns beyond 500,000 timesteps. B2 Energy Percentage during Training Process for SAR mission. Figure 12 above demonstrates the effectiveness of the proposed model, showcasing improvements in energy retention and communication performance over a 500-slot episode. The agent, trained with 4,000 episodes (T = 500 time slots) using Proximal Policy Optimization (PPO), achieves robust B2 energy retention (~ 90%), increased throughput (up to 0.14 Mbps), reduced packet loss ratio (~ 2%), and stabilized end-to-end delay (~ 0.06 s), highlighting the benefits of extended training for SAR missions. Performance Metrics Over One Episode for Proposed PPO Model. Results and discussion Our approach, utilizing PPO to dynamically manage energy across a dual-battery system (B1 for propulsion, B2 for communication) in FANETs, is benchmarked against several recent algorithms identified through a review of current literature. These include: Multi-Q-Learning for Connectivity Optimization: A reinforcement learning-based method optimizing UAV path planning and connectivity in challenging terrains, emphasizing real-time adaptation to communication constraints51. Multi-Q-Learning for Connectivity Optimization: A reinforcement learning-based method optimizing UAV path planning and connectivity in challenging terrains, emphasizing real-time adaptation to communication constraints51. Enhanced A Algorithm for Multi-UAV Path Planning*: A 3D path-planning technique for UAV swarms, focusing on collision-free shortest paths in SAR missions with reduced computation time52. Enhanced A Algorithm for Multi-UAV Path Planning*: A 3D path-planning technique for UAV swarms, focusing on collision-free shortest paths in SAR missions with reduced computation time52. Cooperative Model Predictive Control (MPC) with Particle Swarm Optimization: A real-time path-planning solution for multiple cooperative UAVs, adhering to international SAR standards and optimizing search efficiency53. Cooperative Model Predictive Control (MPC) with Particle Swarm Optimization: A real-time path-planning solution for multiple cooperative UAVs, adhering to international SAR standards and optimizing search efficiency53. The comparisons mentioned in Table 10 highlight the novelty of our model in integrating dual-battery management with DRL (PPO), addressing a gap where existing methods either focus on path planning or connectivity without considering energy segregation. Table 10Comparison of our approach vs. current literature.AlgorithmEnergy Efficiency (%)Mission Endurance (hrs)Communication Reliability (%)Key FocusLimitations Proposed PPO Dual-Battery 853.575Energy management, AI optimizationHigh training overhead (500 epochs)Multi-Q-Learning702.865Connectivity optimizationLimited energy adaptationEnhanced A*652.560Collision-free path planningNo dynamic energy optimizationMPC with PSO753.070Multi-UAV coordinationHigher energy consumption Comparison of our approach vs. current literature. Multi-objective weight sensitivity and pareto analysis To validate the robustness of the scalarized reward structure, which prioritizes energy efficiency, throughput, delay, and packet-loss ratio, respectively, a grid-based sensitivity analysis was conducted. Figure 13 presents the Sobol sensitivity analysis, illustrating the relative contribution of each reward weight to overall performance variance. Each weight was varied by ± 20% while maintaining the total weight. A Sobol variance analysis was also applied to quantify each weight’s contribution to total performance variance. Results indicate that energy efficiency and throughput account for approximately 70% of the overall performance variation, confirming their dominant influence on PPO optimization. The configuration lies near the Pareto frontier, achieving balanced trade-offs between endurance and QoS metrics (Fig. 14). No degenerate or exploitative behaviors (e.g., over-idling) were observed under any of the tested weight combinations, demonstrating stable policy learning and consistent task engagement. Sobol sensitivity results illustrating the relative contribution of each reward weight to total performance variance. Energy and throughput weights dominate with ≈ 70% combined influence, validating their prioritization in the PPO reward function. Pareto front illustrating the trade-off between energy efficiency and throughput under different weight configurations . The shaded region represents the approximate 95% confidence interval across repeated training runs. QoS and SAR application suitability At higher network densities (≥ 40 nodes), throughput declines to approximately 0.02 Mbps due to multi-hop interference and channel contention. Despite this, the end-to-end delay (0.06–0.10 s) and packet loss ratio (2–15%) remain within acceptable bounds for Search and Rescue (SAR) operations. In typical SAR missions, UAVs primarily exchange control packets, GPS coordinates, and compressed image descriptors, which require only moderate data rates. Thus, a minimum viable throughput of 0.02–0.05 Mbps per UAV is sufficient for maintaining real-time situational awareness and cooperative target detection. The observed latency (< 0.1 s) ensures timely control feedback, while the PLR (< 15%) remains tolerable due to redundant packet transmission mechanisms. Multi-objective trade-off analysis To further quantify the relationship between energy efficiency and communication QoS, a multi-objective performance analysis was conducted by normalizing energy consumption (E), throughput (T), delay (D), and packet loss ratio (PLR) as: F = {(E, T,D, P,L, R) | optimize E−1, T, D−1, PLR−1} The Pareto front illustrated in Fig. 15 depicts the trade-off between energy consumption, throughput, and delay across varying network sizes. As throughput increases, energy consumption rises due to higher transmission activity and inter-node coordination. However, the Dual-Battery PPO framework maintains a balanced trade-off, achieving up to 18% higher energy efficiency while satisfying QoS thresholds of Mbps, s, and . Multi-Objective Trade-off Analysis of PPO Dual-Battery Model. This demonstrates that the model sustains optimal mission performance and communication reliability, making it suitable for real-time SAR coordination and target detection in bandwidth-limited environments. Table 11 shows a quantitative summary of the QoS and energy constraints achieved by our proposed PPO Dual-Battery model. Table 11SAR QoS constraints and achieved Performance.MetricSAR RequirementAchieved (Proposed Model)RemarksThroughput (T)≥ 0.02 Mbps0.03–0.06 MbpsSufficient for control and imageDelay (D)≤ 0.10 s0.06–0.09 sReal-time responsiveness maintainedPLR≤ 0.200.02–0.15Reliable under high loadEnergy Efficiency (η)Maximize+ 18%vs. baselineBalanced energy-QoS optimization SAR QoS constraints and achieved Performance. Technical differences and novelty Our architecture goes beyond simply separating propulsion (B1) and communication/sensing (B2) by adding several technical innovations that set it apart from previous works and our earlier research6. Unlike existing DRL-based energy optimization studies (e.g3., on Q-learning for throughput maximization4, on DQN for energy efficiency in UAVs), our method uses a multi-agent PPO framework that jointly optimizes power and mode selection across a FANET, utilizing a state space filled with dynamic features (e.g., B2 State of Charge (SoC), link throughput, packet loss, delay, and mobility). This differs from single-agent DRL approaches that usually focus on a single UAV’s energy or path, and do not support the cooperative decision-making needed for dense FANETs in SAR missions. The PPO algorithm’s clipped objective and generalized advantage estimation (GAE) help maintain stable policy updates over 500 epochs, marking a notable improvement over the sometimes-unstable convergence of Q-learning or DQN in stochastic environments, such as Netsimulyzer-simulated 3D UAV mobility. Relative to battery-aware UAV/FANET works (e.g7., on energy harvesting UAVs9, on battery-aware routing), our model integrates a dual-battery system with a custom energy model that dynamically adjusts B2 usage based on real-time network load, a feature absent in prior static allocation strategies. The multi-agent aspect enables agents to share state observations and coordinate actions (e.g., mode switching: low/med/, or high power), thereby reducing inter-UAV interference and optimizing energy distribution, which single-battery or non-cooperative models cannot achieve. Compared to our prior work6, which used a basic RL approach for single-battery UAV energy management with limited state features (e.g., position, velocity), this study advances to a MADRL setup with a richer state-action-reward framework, trained via ns3-gym + ns-3 to couple realistic wireless networking with UAV mobility, addressing the complex trade-offs of SAR missions. Ablation study To isolate the contribution of each design choice, we conducted an ablation study presented in Table 12. Table 12Ablation study results for Dual-Battery and PPO Configurations.ConfigurationMission Endurance Improvement (%)Packet Loss Reduction (%)Latency Reduction (%)Throughput Improvement (%)Energy Efficiency Improvement (%)Statistical Significance (p-value)Key ObservationsDual-Battery Alone25−30 (Increase)000N/AImproves endurance via B1/B2 separation, but lacks adaptive control, increasing packet loss.PPO Alone001510−20 (Decrease)N/AEnhances QoS (latency, throughput) with PPO, but energy efficiency suffers in single-battery setup.Dual-Battery + PPO (Proposed)25+ (Synergistic)202510+ (Synergistic)40< 0.05 (paired t-test, 5 seeds)Combines endurance and QoS benefits, with PPO optimizing dual-battery synergy; validated at 350 epochs. Ablation study results for Dual-Battery and PPO Configurations. This ablation confirms that the dual-battery design enhances endurance and stability, PPO improves QoS metrics, and their integration maximizes overall performance. Communication protocol and channel modeling justification The FANET simulation utilized IEEE 802.11b with TCP transport, representing reliable telemetry exchange during SAR missions. The use of TCP ensures acknowledgment-driven reliability essential for command-and-control packets, while packet sizes (100–300 B) reflect lightweight sensor and coordination data. RTS/CTS was enabled, and the Friis propagation model was adopted to represent clear aerial line-of-sight links. To evaluate robustness, alternate conditions such as UDP/QUIC traffic, bursty sensing loads, and Rician fading were examined. While UDP improved throughput, it increased PLR by 5–8%. Similarly, bursty traffic and video downlinks resulted in higher instantaneous energy consumption on the communication battery (B2), highlighting the adaptability of the PPO-based dual-battery model under varying QoS and channel conditions. Performance evaluation Baseline Definition and Statistical Validation To ensure fair comparison, three approaches were evaluated under identical simulation and randomization conditions: Heuristic baseline: A deterministic energy–distance greedy model that selects the next waypoint based on minimum residual energy and link stability. Heuristic baseline: A deterministic energy–distance greedy model that selects the next waypoint based on minimum residual energy and link stability. Prior RL baseline: A Deep Q-Network (DQN)-based scheme utilizing the same state–action–reward model as PPO but without policy clipping. Prior RL baseline: A Deep Q-Network (DQN)-based scheme utilizing the same state–action–reward model as PPO but without policy clipping. Proposed PPO model: Proximal Policy Optimization (ε = 0.2) with adaptive learning rate (3 × 10⁻⁴), entropy coefficient 0.01, γ = 0.99, and batch size 64. Proposed PPO model: Proximal Policy Optimization (ε = 0.2) with adaptive learning rate (3 × 10⁻⁴), entropy coefficient 0.01, γ = 0.99, and batch size 64. All models were trained with identical tuning budgets (3 × 10⁵ episodes). Each experiment was repeated ten times, and mean ± standard deviation values were computed. Statistical significance was verified using paired t-tests and bootstrap resampling (10,000 iterations). The Table 13 below illustrates as follows: Table 13Hyperparameters, baseline configurations, and tuning budgets used for PPO, DQN, and heuristic models.ModelLearning RateEpisodesPolicy TypeHidden LayersBatch SizeγεEntropyRemarksHeuristic––Deterministic–––––Energy–distance greedy ruleDQN3 × 10⁻⁴3 × 10⁵Value-based[128, 64]640.99–0.01Prior RL baselinePPO (Proposed)3 × 10⁻⁴3 × 10⁵Policy gradient[128, 64]640.990.20.01Adaptive policy clipping Hyperparameters, baseline configurations, and tuning budgets used for PPO, DQN, and heuristic models. Conclusion In this research work, we propose an innovative dual-battery system where the primary battery (B1) is prioritized for propulsion while the secondary battery (B2) is intelligently managed using DRL to alleviate energy stress, ensure stable communication, and strengthen UAV fail-safe mechanisms. This framework aims to optimize energy utilization, extend mission duration, and improve overall FANET performance by alleviating energy stress on B1, ensuring reliable communication, and enhancing UAV fail-safe mechanisms. UAV nodes are categorized into four distinct states—Idle, Processing and Sensing, Communication, and Flight Dynamics—each characterized by unique energy consumption patterns. The DRL-PPO agent dynamically adjusts B2 usage based on a learned policy, defined by a tuple comprising state, observation, action space, and a reward function that balances energy efficiency with communication performance metrics such as throughput, packet loss ratio, and end-to-end delay. Evaluated through NS-3 simulations, the proposed model demonstrates robust performance, achieving approximately 90% B2 energy retention, throughput up to 0.14 Mbps, packet loss reduced to around 2%, and delay stabilized at about 0.06 s over a 500-slot episode. Comparative analysis and statistical validation underscore its superiority, establishing a scalable and effective solution for prolonged SAR operations in challenging environments. Acknowledgements The authors thank the Vellore Institute of Technology, Chennai, India, for its valuable support. Author contributions A.S.M. conceived the research idea and conducted the experiments under the supervision of Dr. T.S. A.S.M. also prepared the main manuscript text and figures. Both authors have reviewed and approved the final version of the manuscript. Funding Open access funding provided by Vellore Institute of Technology. Data availability The datasets used and/or analysed during the current study are available from the corresponding author upon reasonable request. Declarations Competing interests The authors declare no competing interests. Footnotes Publisher’s note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations. References Associated Data Data Availability Statement The datasets used and/or analysed during the current study are available from the corresponding author upon reasonable request.