## 2 Microgrid Topology and Modes of Operation  
Figure 1 presents a schematic diagram of the PV-wind-ESS hybrid AC/DC microgrid. The photovoltaic panels, lithium-ion battery, and PMSG-based wind system are connected to the microgrid DC bus via DC/DC converters. A bidirectional inverter is used to control the energy flow between the DC and AC microgrid buses. AC loads are connected to the microgrid at 220 V, 60 Hz AC bus, through which the microgrid is connected to the central power system. The capacity of the microgrid simulated for a PV system is 500 Wp, wind turbine capacity is 2 kW, and lithium storage capacity is 5 kWh. A simple boost converter has been chosen as the PV system interface, and a low-cost two-switch bidirectional converter topology was used for the proper control of the ESS.  
The DG and ESS interface converters must allow different control modes, depending on whether the microgrid is connected to the central power system or not. Furthermore, with respect to island mode, the converters' control strategies depend on the batteries' state of charge (SoC) and the total DG units' instantaneous injected power versus total load demand. Thus, some quantities necessary for the decision about the microgrid mode of operation must be sent to a central control unit, which decides the DG unit's operation mode (under MPPT or with reduced generation) and ESS operation (charging or supplying the instantaneous power deficit).  
For long-term operation, climatology information obtained for the project's location in the university was used (18\({}^{\circ}\)29\({}^{\prime}\)15.9\({}^{\prime\prime}\) N 69\({}^{\circ}\)57\({}^{\prime}\)48.5\({}^{\prime\prime}\) W).  
When the microgrid is connected to the primary grid, the PMSG wind and PV systems must be controlled to maximize the use of available primary energy, i.e., MPPT is adopted. Furthermore, if the battery is not fully charged, its converter controller should determine the instantaneous power to be absorbed. Therefore, for operation in under-connected mode, the inverter between the DC and AC buses must transfer to (or absorb from) the AC microgrid bus the difference between the power generated and consumed by the battery and DC loads.  
On the other hand, loads should preferably be fed by the DG sources when the microgrid is islanded. In case of insufficient generation, the batteries should complement  
Figure 1: Topology of the PV–wind–ESS hybrid microgrid.  
the power to meet the load's demand. However, if the generation exceeds the power required by the loads there are two possible situations that might result: (i) the battery is fully charged, in which case the DG systems can no longer operate at the maximum power point MPP and must share the total power consumed by the loads proportionally to their nominal powers; or (ii) the battery can be charged, allowing the DG systems to operate at the MPP, and the excess of generated power is used for battery charging.  
It is essential to mention that the topology and control strategies must ensure proper operation under the different conditions described above and provide smooth transitions between operating modes. The energy management strategy described is represented in the flow diagram of Figure 2.