Optimizing Power Control in Generation Units: LSTM-Based Machine Learning for Enhanced Stability in Virtual Synchronous Generators
Abstract
1. Introduction
1.1. Literature Review
- Traditional Control: Limited in handling nonlinearities and adaptability to rapid changes [26].
1.2. Shortcomings of Previous Researchs
- Underutilization of LSTM in Control: Existing machine learning applications focus more on forecasting rather than direct control, and the potential of LSTM networks for real-time VSG control is not fully exploited [33,34]. The paper presents a pre-synchronization control strategy for the VSGs in microgrids, eliminating PLL dependency and ensuring smooth transitions between grid-connected and off-grid modes. It also introduces a variable integration coefficient strategy for enhanced frequency recovery, improving system stability, and reducing power fluctuations [51]. This paper analyzes the impact of active power loops (APLs) on transient voltage stability in a paralleled SG-VSG system with IM loads, using Critical Clearance Time (CCT) for evaluation. A new control method is proposed and validated through simulations and hardware-in-the-loop experiments, effectively mitigating APL interactions and improving system stability [52].
1.3. The Research Contributions
- Development of an LSTM-Based Real-Time Controller: An LSTM neural network is designed to directly control the power output of VSGs, providing fast and accurate responses to system disturbances and varying operational conditions.
- Enhanced Handling of Nonlinearities and Uncertainties: The proposed method effectively manages the complex nonlinear dynamics and uncertainties associated with inverter-based units, improving system stability.
- Balancing Technical and Economic Objectives: By minimizing power oscillations and optimizing resource utilization, the controller ensures both technical performance and economic efficiency.
- Comprehensive Benchmarking: Extensive simulations and comparisons with traditional control methods demonstrate the superior performance of the LSTM-based controller.
- Addressing Economic Implications: The study examines the economic benefits, highlighting the potential for cost-effective integration into modern power systems.
2. Theoretical Concept of the Problem
3. Proposed LSTM-Based Control Method
3.1. Formulation of the Problem
3.2. Objective Function
3.3. Dynamic Model of Generation Unit
- : Rotor angle of generator i.
- : Rotor speed generator i.
- : Mechanical power generator i.
- : Electrical power generator i.
- : Exciter voltage generator i.
- : Inertia constant and damping factor generator i.
- : Time constants of governor and exciter generator i.
- : Active and reactive power of the VSG, i.
- : dd-qq axis voltages.
- : dd-qq axis currents.
- : Resistance and inductance.
- : Time constant of the VSG.
3.4. Probabilistic Behavior of V2G Systems
- : Probability of being in charging or discharging mode.
- : Charging and discharging power profiles.
3.5. LSTM Training and Control
| Algorithm 1. LSTM-Based optimal power control framework VSG enabled microgrids |
|
4. Discussion of Results and Validation
4.1. Case Study and Input Data

- Diesel Generator: Acting as the base generator, the diesel unit provides the necessary inertia and stability to balance power supply and demand. By monitoring the rotor speed of its synchronous machine, the system detects frequency deviations and adjusts the generator output accordingly. This generator is a critical backup during renewable generation deficits and forms a key part of the control system’s dynamic response strategy.
- Renewable Energy Sources: The PV farm’s power output depends on the area of the farm, the efficiency of the solar panels, and solar irradiance, as illustrated in the 24 h irradiance profile in Figure 4. The control system ensures optimal utilization of solar energy while managing the intermittency associated with photovoltaic generation. The wind farm’s power generation follows a linear relationship with wind speed and adjusts dynamically based on operational thresholds. When wind speeds are too high, the farm disconnects to prevent overloading the grid. The wind speed profile in Figure 5 reflects these operational characteristics, which the LSTM controller leverages to maintain stability.
- Vehicle-to-Grid System (V2G): The V2G system enables bidirectional power flow, with electric vehicles (EVs) either charging their batteries or discharging stored energy into the grid. The system incorporates 100 EVs and models five user profiles to reflect real-world variability in charging behaviors and availability. The LSTM-based control system coordinates the V2G operations to address frequency fluctuations dynamically, ensuring grid stability and minimizing costs. The profile of the total power of 24 by the V2G is shown in Figure 6.
- Load Profile: The microgrid load consists of residential load and industrial load. Residential load follows a time-dependent consumption profile with a specific power factor, as shown in Figure 6. Industrial Load: Represented by an asynchronous machine, simulating an inductive load with a quadratic torque-speed relationship. The combination of residential and industrial loads offers a realistic basis for testing the proposed control strategies.



- Global Frequency Regulation: The LSTM controller continuously monitors system parameters, such as frequency deviations, renewable energy output, and load demand. By analyzing temporal dependencies in these inputs, the LSTM dynamically adjusts the output of generation units, such as the diesel generator, PV farm, wind farm, and V2G systems, to stabilize grid frequency. Unlike conventional controllers, the LSTM’s ability to model nonlinear relationships allows it to predict and mitigate frequency deviations proactively.
- Cost-Effective Power Distribution: The controller considers the operational costs associated with each generation unit. For example, the diesel generator incurs fuel costs, while the PV and wind farms are cost-free but variable. The LSTM optimally dispatches power from available sources to minimize overall costs while meeting demand. This includes prioritizing renewable sources and utilizing the V2G system during peak demand periods to avoid excessive reliance on the diesel generator.
- Dynamic Adaptability: The LSTM controller adapts to changing system conditions, such as fluctuating wind speeds or variations in solar irradiance, by learning from historical data. It ensures that the generation and storage units operate within their optimal ranges, thereby enhancing system reliability and efficiency.
- Integrated Decision-Making: The controller balances technical objectives (frequency stability, renewable integration) with economic considerations (operational cost minimization). By integrating these objectives into a unified framework, the LSTM enables a scalable and practical solution for modern microgrids with high renewable penetration.
4.2. Discussion of the Results
4.2.1. Temporal Patterns and Baseline Operations
- Solar Intensity: Solar intensity follows a normal distribution, peaking at midday, as shown in the irradiance profile. This results in significant renewable energy contribution during the central hours but introduces variability that requires active management by the controller.
- Wind Speed: Wind speed varies significantly, with multiple peaks and troughs throughout the day. The high variability challenges the stability of the grid, particularly during periods when the wind farm disconnects due to excessive speeds.
- Residential Load: The residential load follows a typical household consumption pattern, with lower demand during daylight hours and a pronounced evening peak. This dynamic creates operational challenges, particularly when renewable generation decreases.
4.2.2. Event Analysis and System Response
- Kick-Off of the Asynchronous Machine (3rd Hour): The activation of the asynchronous machine introduces a sudden inductive load, causing a transient dip in both system frequency and voltage at the Point of Common Coupling (PCC). As shown in Figure 7 and Figure 8, the LSTM controller stabilizes these parameters more quickly than the linear MPC method, demonstrating superior responsiveness and accuracy.
- Partial Shading at Noon: Partial shading reduces solar power generation, leading to a temporary mismatch between supply and demand. The LSTM-based controller dynamically reallocates generation resources, ramping up the diesel generator and leveraging V2G systems to stabilize the grid. Figure 7 and Figure 8 show minimal frequency and voltage deviations respectively during this event, with the LSTM method outperforming the linear MPC approach in maintaining stability.
- Wind Farm Trip (22nd Hour): At the 22nd hour, the wind farm disconnects due to excessive wind speeds, causing a significant gap in renewable generation. The LSTM controller promptly compensates by increasing diesel generation and deploying stored energy from V2G systems. As illustrated in Figure 7 and Figure 8, the LSTM approach exhibits faster stabilization and smaller deviations compared to the MPC method.


4.2.3. Cost Optimization
- Prioritize the use of low-cost renewable energy sources.
- Optimize the timing and extent of diesel generator usage.
- Efficiently manage V2G system resources to reduce reliance on expensive generation.
4.2.4. Comparison of Performance (LSTM-Based Method vs. Linear MPC)
- Frequency and Voltage Stability: As shown in Figure 7 and Figure 8, the LSTM-based method outperforms the linear MPC approach in stabilizing system frequency and voltage at the PCC bus. The LSTM controller’s ability to model nonlinear relationships and capture temporal dependencies allows for faster and more precise adjustments during disturbances.
- Cost Efficiency: Figure 10 highlights the cost-effectiveness of the LSTM-based controller, which achieves lower total generation costs than the MPC method. The LSTM controller’s adaptive optimization ensures that resources are utilized efficiently without compromising grid stability.
- Adaptability and Scalability: The LSTM controller adapts more effectively to renewable energy variability and unplanned events, such as the wind farm trip. Its scalability makes it a practical solution for microgrids with high renewable penetration and complex dynamics.
- The proposed method consistently demonstrates superior performance across scenarios, particularly during critical events like the activation of the asynchronous machine and the wind farm trip.
- Under normal operation, PM achieves the lowest operation cost and smallest deviations, highlighting its efficiency and precision.
- During challenging events, proposed method’s predictive LSTM-based adjustments provide better stability and faster response times than the Fuzzy and MPC methods.
- The results validate the proposed method as a robust, scalable, and cost-efficient solution for microgrid management, outperforming traditional approaches.
5. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Conflicts of Interest
References
- Kober, T.; Schiffer, H.-W.; Densing, M.; Panos, E. Global energy perspectives to 2060–WEC’s World Energy Scenarios 2019. Energy Strateg. Rev. 2020, 31, 100523. [Google Scholar] [CrossRef]
- Rasoulnia, M.; Yaghoubi, E.; Yaghoubi, E.; Hussain, A.; Kamwa, I. A comprehensive systematic and bibliometric review of technologies and measurement tools for power quality events detection, classification, and fault location in smart grids. Renew. Sustain. Energy Rev. 2026, 226, 116302. [Google Scholar] [CrossRef]
- Allan, R.P.; Arias, P.A.; Berger, S.; Canadell, J.G.; Cassou, C.; Chen, D.; Cherchi, A.; Connors, S.L.; Coppola, E.; Abigail, F.; et al. Intergovernmental panel on climate change (IPCC). Summary for policymakers. In Climate Change 2021: The Physical Science Basis. Contribution of Working Group I to the Sixth Assessment Report of the Intergovernmental Panel on Climate Change; Cambridge University Press: Cambridge, UK, 2023; pp. 3–32. [Google Scholar]
- Ahmed, Y.E.; Maghami, M.R.; Pasupuleti, J.; Danook, S.H.; Ismail, F.B. Overview of recent solar photovoltaic cooling system approach. Technologies 2024, 12, 171. [Google Scholar] [CrossRef]
- Espín-Sarzosa, D.; Palma-Behnke, R.; Cañizares, C.A.; Annakkage, U.; Elizondo, M.; Espina, E.; Du, W.; Kabalan, M.; Meegahapola, L.; Mendoza-Araya, P.A.; et al. Microgrid modeling for stability analysis. IEEE Trans. Smart Grid 2023, 15, 2459–2479. [Google Scholar] [CrossRef]
- Wang, Z.; Yu, Y.; Gao, W.; Davari, M.; Deng, C. Adaptive, optimal, virtual synchronous generator control of three-phase grid-connected inverters under different grid conditions—An adaptive dynamic programming approach. IEEE Trans. Ind. Inform. 2021, 18, 7388–7399. [Google Scholar] [CrossRef]
- Naderi, M.; Khayat, Y.; Shafiee, Q.; Blaabjerg, F.; Bevrani, H. Dynamic modeling, stability analysis and control of interconnected microgrids: A review. Appl. Energy 2023, 334, 120647. [Google Scholar] [CrossRef]
- Shahrbejari, A.N.; Sani, M.H.E.; Jahromi, M.Z.; Yaghoubi, E.; Yaghoubi, E.; Maghami, M.R. Optimal multi-objective energy management of decentralized demand response incorporating uncertainties. PLoS ONE 2025, 20, e0328838. [Google Scholar] [CrossRef]
- Xu, H.; Yu, C.; Liu, C.; Wang, Q.; Zhang, X. An improved virtual inertia algorithm of virtual synchronous generator. J. Mod. Power Syst. Clean Energy 2019, 8, 377–386. [Google Scholar] [CrossRef]
- Surinkaew, T.; Emami, K.; Shah, R.; Islam, S.; Mithulananthan, N. Forced oscillation in power systems with converter controlled-based resources–A survey with case studies. IEEE Access 2021, 9, 150911–150924. [Google Scholar] [CrossRef]
- Mehrzad, A.; Darmiani, M.; Rouhani, S.H.; Su, C.-L.; Sepestanaki, M.A.; Mofidipour, E.; Monti, A.; Anvari-Moghaddam, A. Inertia in renewable power systems: A review of estimation methods and practical implementation. Renew. Sustain. Energy Rev. 2026, 226, 116246. [Google Scholar] [CrossRef]
- Ufa, R.A.; Malkova, Y.Y.; Rudnik, V.E.; Andreev, M.V.; Borisov, V.A. A review on distributed generation impacts on electric power system. Int. J. Hydrogen Energy 2022, 47, 20347–20361. [Google Scholar] [CrossRef]
- Zhang, H.; Xiang, W.; Lin, W.; Wen, J. Grid forming converters in renewable energy sources dominated power grid: Control strategy, stability, application, and challenges. J. Mod. Power Syst. Clean Energy 2021, 9, 1239–1256. [Google Scholar] [CrossRef]
- Chang, J.; Du, Y.; Lim, E.G.; Wen, H.; Li, X.; Jiang, L. Coordinated frequency regulation using solar forecasting based virtual inertia control for islanded microgrids. IEEE Trans. Sustain. Energy 2021, 12, 2393–2403. [Google Scholar] [CrossRef]
- Li, C.; Yang, Y.; Cao, Y.; Aleshina, A.; Xu, J.; Blaabjerg, F. Grid inertia and damping support enabled by proposed virtual inductance control for grid-forming virtual synchronous generator. IEEE Trans. Power Electron. 2022, 38, 294–303. [Google Scholar] [CrossRef]
- Ren, M.; Li, T.; Shi, K.; Xu, P.; Sun, Y. Coordinated control strategy of virtual synchronous generator based on adaptive moment of inertia and virtual impedance. IEEE J. Emerg. Sel. Top. Circuits Syst. 2021, 11, 99–110. [Google Scholar] [CrossRef]
- Yaghoubi, E.; Yaghoubi, E.; Jahromi, M.Z.; Maghami, M.R.; Paşaoğlu, A.; Chamorro, H.R. A novel data-driven NLMPC strategy for techno-economic microgrid management with battery energy storage under uncertainty. Sci. Rep. 2025, 15, 28096. [Google Scholar] [CrossRef]
- Ranjan, M.; Shankar, R. A literature survey on load frequency control considering renewable energy integration in power system: Recent trends and future prospects. J. Energy Storage 2022, 45, 103717. [Google Scholar] [CrossRef]
- Santhoshkumar, T.; Senthilkumar, V. Transient and small signal stability improvement in microgrid using AWOALO with virtual synchronous generator control scheme. ISA Trans. 2020, 104, 233–244. [Google Scholar] [CrossRef] [PubMed]
- Van Houdt, G.; Mosquera, C.; Nápoles, G. A review on the long short-term memory model. Artif. Intell. Rev. 2020, 53, 5929–5955. [Google Scholar] [CrossRef]
- Wang, H.; Yang, C.; Liao, X.; Wang, J.; Zhou, W.; Ji, X. Artificial neural network-based virtual synchronous generator dual droop control for microgrid systems. Comput. Electr. Eng. 2023, 111, 108930. [Google Scholar] [CrossRef]
- Pham, X.H.T. Power sharing strategy in islanded microgrids using improved droop control. Electr. Power Syst. Res. 2020, 180, 106164. [Google Scholar] [CrossRef]
- Cheng, H.; Li, C.; Ghias, A.M.Y.M.; Blaabjerg, F. Dynamic coupling mechanism analysis between voltage and frequency in virtual synchronous generator system. IEEE Trans. Power Syst. 2023, 39, 2365–2368. [Google Scholar] [CrossRef]
- Montalvo, E.T.; Sanchez, V.M.; Ramirez, J.M. Synchronverter assessment for the frequency regulation of control areas encompassing Renewable Distributed Generation. Int. J. Hydrogen Energy 2021, 46, 26138–26151. [Google Scholar] [CrossRef]
- Meng, Q.; Ren, Y.; Liu, H. Frequency stability analysis of grid-forming PMSG based on virtual synchronous control. IEEE Access 2024, 12, 84134–84148. [Google Scholar] [CrossRef]
- Sindi, H.F.; Alghamdi, S.; Rawa, M.; Omar, A.I.; Elmetwaly, A.H. Robust control of adaptive power quality compensator in Multi-Microgrids for power quality enhancement using puzzle optimization algorithm. Ain Shams Eng. J. 2023, 14, 102047. [Google Scholar] [CrossRef]
- Abou-Hussein, W.M.; Dabour, S.M.; Hamad, M.S.; Rashad, E.M. Model predictive control based virtual synchronous generator for parallel-connected three-phase split-source converters in islanded AC Microgrids. Energy Rep. 2023, 9, 1696–1706. [Google Scholar] [CrossRef]
- Yap, K.Y.; Lim, J.M.-Y.; Sarimuthu, C.R. A novel adaptive virtual inertia control strategy under varying irradiance and temperature in grid-connected solar power system. Int. J. Electr. Power Energy Syst. 2021, 132, 107180. [Google Scholar] [CrossRef]
- Zhang, W.; Sun, C.; Alharbi, M.; Hasanien, H.M.; Song, K. A voltage-power self-coordinated control system on the load-side of storage and distributed generation inverters in distribution grid. Ain Shams Eng. J. 2025, 16, 103480. [Google Scholar] [CrossRef]
- Singh, A.K.; Seethalekshmi, K. Comparative analysis of primary microgrid control through adaptive VSG based multi-loop and single loop configuration. In 2023 IEEE 3rd International Conference on Sustainable Energy and Future Electric Transportation (SEFET); IEEE: New York, NY, USA, 2023; pp. 1–6. [Google Scholar]
- Liang, Y.; He, Y.; Niu, Y. Microgrid frequency fluctuation attenuation using improved fuzzy adaptive damping-based VSG considering dynamics and allowable deviation. Energies 2020, 13, 4885. [Google Scholar] [CrossRef]
- Alimi, O.A.; Ouahada, K.; Abu-Mahfouz, A.M. A review of machine learning approaches to power system security and stability. IEEE Access 2020, 8, 113512–113531. [Google Scholar] [CrossRef]
- Muneer, A.; Ali, R.F.; Almaghthawi, A.; Taib, S.M.; Alghamdi, A.; Ghaleb, E.A.A. Short term residential load forecasting using long short-term memory recurrent neural network. Int. J. Electr. Comput. Eng. 2022, 12, 5589–5599. [Google Scholar] [CrossRef]
- Hossain, M.S.; Mahmood, H. Short-term photovoltaic power forecasting using an LSTM neural network and synthetic weather forecast. IEEE Access 2020, 8, 172524–172533. [Google Scholar] [CrossRef]
- Han, Y.; Ding, N.; Geng, Z.; Wang, Z.; Chu, C. An optimized long short-term memory network based fault diagnosis model for chemical processes. J. Process Control 2020, 92, 161–168. [Google Scholar] [CrossRef]
- Norouzi, M.H.; Oshnoei, A.; Mohammadi-Ivatloo, B.; Abapour, M. Learning-based virtual inertia control of an islanded microgrid with high participation of renewable energy resources. IEEE Syst. J. 2024, 18, 786–795. [Google Scholar] [CrossRef]
- Xu, Y.; Dong, Z.; Li, Z.; Liu, Y.; Ding, Z. Distributed optimization for integrated frequency regulation and economic dispatch in microgrids. IEEE Trans. Smart Grid 2021, 12, 4595–4606. [Google Scholar] [CrossRef]
- Zhou, D.; Niu, X.; Xie, Y.; Li, P.; Fang, J.; Guo, F. An economic dispatch method of microgrid based on fully distributed ADMM considering demand response. Sustainability 2022, 14, 3751. [Google Scholar] [CrossRef]
- Wang, Z.; Jiang, H.; He, H.; Sun, Y.L. Distributed finite-time economic dispatch for islanded microgrids. In 2020 IEEE Power & Energy Society General Meeting (PESGM); IEEE: New York, NY, USA, 2020; pp. 1–5. [Google Scholar]
- Tu, H.; Du, Y.; Yu, H.; Meena, S.; Lu, X.; Lukic, S. Distributed economic dispatch for microgrids tracking ramp power commands. IEEE Trans. Smart Grid 2022, 14, 94–111. [Google Scholar] [CrossRef]
- Meng, X.; Mei, J.; Tang, X.; Jiang, J.; Sun, C.; Song, K. The degradation prediction of proton exchange membrane fuel cell performance based on a transformer model. Energies 2024, 17, 3050. [Google Scholar] [CrossRef]
- Waheed, W.; Xu, Q. A Data-Driven Long-Short Term Load Forecasting with LSTM-RNN Networks. 2023. Available online: https://www.researchgate.net/publication/371325654_A_Data-driven_Long-Short_Term_Load_Forecasting_with_LSTM-RNN_Networks (accessed on 8 February 2026).
- Yadav, D.; Sahoo, L.; Mandal, S.K.; Ravivarman, G.; Vijayaraghavan, P. Using long short-term memory units for time series forecasting. In 2023 2nd International Conference on Futuristic Technologies (INCOFT); IEEE: New York, NY, USA, 2023; pp. 1–6. [Google Scholar]
- Jenson, A.J.; Sowkarthika, S. Electricity Demand Forecasting using LSTMs. J. Electr. Eng. Autom. 2023, 5, 228–237. [Google Scholar] [CrossRef]
- Nie, R.; Li, H. Application and Improvement of LSTM in Power System Prediction. In 2023 IEEE 3rd International Conference on Data Science and Computer Application (ICDSCA); IEEE: New York, NY, USA, 2023; pp. 975–980. [Google Scholar]
- Oboreh-Snapps, O.; She, B.; Fahad, S.; Chen, H.; Kimball, J.; Li, F.; Cui, H.; Bo, R. Virtual synchronous generator control using twin delayed deep deterministic policy gradient method. IEEE Trans. Energy Convers. 2023, 39, 214–228. [Google Scholar] [CrossRef]
- Yao, F.; Zhao, J.; Li, X.; Mao, L.; Qu, K. RBF neural network based virtual synchronous generator control with improved frequency stability. IEEE Trans. Ind. Inform. 2020, 17, 4014–4024. [Google Scholar] [CrossRef]
- Rasool, A.; Fahad, S.; Yan, X.; Rasool, H.; Jamil, M.; Padmanaban, S. Reactive power matching through virtual variable impedance for parallel virtual synchronous generator control scheme. IEEE Syst. J. 2022, 17, 1453–1464. [Google Scholar] [CrossRef]
- Li, Z.; Li, H.; Zheng, X.; Gao, M. Virtual model predictive control for virtual synchronous generators to achieve coordinated voltage unbalance compensation in islanded micro grids. Int. J. Electr. Power Energy Syst. 2023, 146, 108756. [Google Scholar] [CrossRef]
- Cheema, K.M. A comprehensive review of virtual synchronous generator. Int. J. Electr. Power Energy Syst. 2020, 120, 106006. [Google Scholar] [CrossRef]
- Wang, J.; Ramli, N.; Aziz, N.H.A. Pre synchronization control strategy of virtual synchronous generator (VSG) in micro-grid. IEEE Access 2023, 11, 139004–139016. [Google Scholar] [CrossRef]
- Cheng, H.; Huang, W.; Shen, C.; Peng, Y.; Shuai, Z.; Shen, Z.J. Transient voltage stability of paralleled synchronous and virtual synchronous generators with induction motor loads. IEEE Trans. Smart Grid 2021, 12, 4983–4999. [Google Scholar] [CrossRef]
- Rauniyar, M.; Bhujel, N.; Hansen, T.M.; Fourney, R.; Rekabdarkolaee, H.M.; Tonkoski, R. Diesel generator model development and validation using moving horizon estimation. In IECON 2021–47th Annual Conference of the IEEE Industrial Electronics Society; IEEE: New York, NY, USA, 2021; pp. 1–6. [Google Scholar]
- Eidiani, M.; Kargar, M.; Zeynal, H. Interactive Use of D-STATCOM and Storage Resource to Maintain Microgrid Stability for Commercial Systems. In Microgrids for Commercial Systems; WILEY: Hoboken, NJ, USA, 2024; pp. 241–270. [Google Scholar]
- Nema, S.; Prakash, V.; Bhakar, R.; Pandžić, H. Coordinated synthetic inertia control provision from distributed energy resources and energy storage systems. In 2022 International Conference on Intelligent Controller and Computing for Smart Power (ICICCSP); IEEE: New York, NY, USA, 2022; pp. 1–5. [Google Scholar]
- Kerdphol, T.; Surinkaew, T.; Ngamroo, I. Synthetic Inertia-Power Sharing in High Renewable Power Grids Through Vehicle-to-Grid Topology. In 2024 IEEE/IAS Industrial and Commercial Power System Asia (I&CPS Asia); IEEE: New York, NY, USA, 2024; pp. 247–252. [Google Scholar]
- Zhang, Y.; Melin, A.M.; Djouadi, S.M.; Olama, M.M.; Tomsovic, K. Provision for guaranteed inertial response in diesel-wind systems via model reference control. IEEE Trans. Power Syst. 2018, 33, 6557–6568. [Google Scholar] [CrossRef]
- Nurkanovic, A.; Mesanovic, A.; Zanelli, A.; Frison, G.; Frey, J.; Albrecht, S.; Diehl, M. Real-time nonlinear model predictive control for microgrid operation. In 2020 American Control Conference (ACC); IEEE: New York, NY, USA, 2020; pp. 4989–4995. [Google Scholar]
- Rahmani-Andebili, M. Grid-connected and off-grid operation of a microgrid applying fuzzy mixed-integer linear programming. In 2022 IEEE Power and Energy Conference at Illinois (PECI); IEEE: New York, NY, USA, 2022; pp. 1–5. [Google Scholar]




| Control Method | Nonlinearity Handling | Real-Time Capability | Adaptability | Computational Complexity | References |
|---|---|---|---|---|---|
| Traditional Control | Low | High | Low | Low | [22,24,26] |
| Model Predictive Control | Medium | Medium | Medium | High | [27] |
| Adaptive Control | Medium | High | High | Medium | [28] |
| Robust Control | High | Medium | Medium | High | [30] |
| Machine Learning (Existing) | High | Medium | High | Medium | [36,46] |
| Proposed LSTM-Based Control | High | High | High | Medium | Proposed Work |
| Component | Parameter | Value | Unit | Source/Justification |
|---|---|---|---|---|
| Diesel Generator | Inertia constant (H) | 5 | s | [53] |
| Damping coefficient (D) | 1 | pu | [55] | |
| Wind Farm | Rated capacity | 300 | kW | [56] |
| V2G System | Number of EVs | 100 | – | [54] |
| Bidirectional power per EV | ±10 | kW | [54] | |
| LV Lines | Resistance (R) | 0.1 | Ω/km | [55] |
| Reactance (X) | 0.3 | Ω/km | [55] |
| Feature/Scenario | Proposed Method | Fuzzy Method [31] | MPC Method [27] | Notes |
|---|---|---|---|---|
| Operation Cost (Normal Operation) | 1.7565 × 107 | 2.0150 × 107 | 1.9800 × 107 | Proposed method minimizes cost through efficient resource allocation and optimal V2G utilization. |
| Operation Cost (Partial Shading) | 1.8200 × 107 | 2.1000 × 107 | 1.9900 × 107 | Proposed method adapts dynamically to reduced PV output, minimizing diesel reliance better than other methods. |
| Frequency Deviations (Kick-Off of Asynchronous Machine) | ±0.02 Hz | ±0.12 Hz | ±0.06 Hz | Proposed method rapidly stabilizes frequency using real-time adjustments, outperforming traditional methods. |
| Frequency Deviations (Wind Farm Trip) | ±0.03 Hz | ±0.15 Hz | ±0.08 Hz | Proposed method handles sudden generation loss with smaller deviations due to predictive control. |
| Voltage Deviations (Normal Operation) | ±0.015 p.u. | ±0.080 p.u. | ±0.040 p.u. | Proposed method ensures voltage stability by dynamically managing reactive power. |
| Voltage Deviations (Partial Shading) | ±0.020 p.u. | ±0.100 p.u. | ±0.045 p.u. | Proposed method maintains voltage within permissible limits during reduced solar generation. |
| Response Time (Kick-Off of Asynchronous Machine) | 0.001 s | 0.015 s | 0.010 s | Proposed method responds 10 times faster than MPC and 15 times faster than Fuzzy. |
| Response Time (Wind Farm Trip) | 0.001 s | 0.020 s | 0.012 s | Proposed method’s rapid corrective action prevents cascading instability. |
| Controller | Platform/Implementation | Execution/Inference Time per Step | Notes/Ref |
|---|---|---|---|
| Proposed LSTM-based | GPU/FPGA (preliminary tests/embedded estimates) | 1 ms | This study (preliminary embedded GPU/FPGA tests or literature-aligned) |
| Proposed LSTM-based | Sensitivity (64 → 256 neurons) | ~+15% increase | This study |
| Linear MPC | MATLAB 2024a/CVXGEN (simulation) | ~0.4 ms per trial (but up to 20–50 ms in embedded/real-time with constraints) | [54]—simulation time; real-time higher due to constraints |
| Linearized-Trajectory MPC | Real-time implementation (HIL) | Suitable for real-time (enhanced for short sampling intervals; typically 5–50 ms reported in similar HIL setups) | [54] |
| Fuzzy Logic Controller | Real-time EMS/HIL | ~5 ms (or 2–20 ms depending on rule base) | [55,56,57]—literature-reported values in HIL/embedded setups |
| Linear/MILP-MPC | Typical microgrid real-time | 5–50 ms | [58]—real-time nonlinear MPC benchmarks |
| Fuzzy MILP Hybrid | Grid-connected/off-grid microgrid | Literature-typical (depends on complexity; 5–30 ms range) | [59] |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2026 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license.
Share and Cite
Khamees, A.; Altınkaya, H. Optimizing Power Control in Generation Units: LSTM-Based Machine Learning for Enhanced Stability in Virtual Synchronous Generators. Electronics 2026, 15, 791. https://doi.org/10.3390/electronics15040791
Khamees A, Altınkaya H. Optimizing Power Control in Generation Units: LSTM-Based Machine Learning for Enhanced Stability in Virtual Synchronous Generators. Electronics. 2026; 15(4):791. https://doi.org/10.3390/electronics15040791
Chicago/Turabian StyleKhamees, Ahmed, and Hüseyin Altınkaya. 2026. "Optimizing Power Control in Generation Units: LSTM-Based Machine Learning for Enhanced Stability in Virtual Synchronous Generators" Electronics 15, no. 4: 791. https://doi.org/10.3390/electronics15040791
APA StyleKhamees, A., & Altınkaya, H. (2026). Optimizing Power Control in Generation Units: LSTM-Based Machine Learning for Enhanced Stability in Virtual Synchronous Generators. Electronics, 15(4), 791. https://doi.org/10.3390/electronics15040791

