Direct matrix converter topologies with model predictive current control applied as power interfaces in AC, DC, and hybrid microgrids in islanded and grid-connected modes

: This paper presents an analysis of a new application of different direct matrix converter topologies used as power interfaces in AC, DC, and hybrid microgrids, with model predictive current control. Such a combination of a converter and control strategy leads to a high power quality microgrid voltage, even with a low power quality main grid voltage and even during the connection and disconnection of a variety of loads and generation sources to the microgrids. These robust systems are suitable for applications in which sensitive loads are to be supplied and these loads are connected close to distributed-generation sources with inherent intermittent behavior. The authors also propose the use of new direct matrix converter conﬁgurations with a reduced number of switches in order to achieve reduced cost, reduced failure rate, and higher reliability, which are very desirable in microgrids. Finally, the authors also introduce new hybrid direct matrix converter topologies that provide interesting options for the islanded operation of the microgrids with the use of a battery system. In other words, the proposed hybrid direct matrix converters result in ﬂexible hybrid microgrid conﬁgurations integrating DC and AC devices with high power quality and high power supply reliability.


Introduction
Over the years, many works related to microgrids have been developed aiming at improving the operation of modern electrical systems with high penetration of distributed generation [1][2][3][4][5][6].AC microgrids have their inherent operational drawbacks such as the presence of harmonic currents and voltages, frequency regulation, and reactive power issues [4][5][6].On the other hand, DC microgrids are able to overcome those mentioned operational issues and, thus, present less complexity and are more easily operated.Furthermore, DC microgrids allow for a more friendly integration with systems such as photovoltaic generation, batteries, and electronic loads [5,7,8].Hybrid microgrids are a great solution to integrate the AC and DC systems and devices, taking advantage of the benefits of AC and DC microgrids [9][10][11].
The concept of microgrid is many times related to electrical systems operating in remote regions feeding small villages [12], sometimes isolated from the main power system [13,14], or even related to applications in ships [15,16], airplanes, and other types of vehicles.Such applications usually require high reliability and low weight.Furthermore, a system with a low maintenance necessity is desired.
The Matrix Converter (MC) was proposed many years ago as a solution with a simple and compact power circuit and with high power density.Besides, the absence of the bulky and sensitive DC-link capacitors along with the reduced voltage stress applied to the switches could lead to a higher lifetime and higher reliability of the system [17][18][19][20][21], which are very desirable in microgrid applications.Some of the main drawbacks of the MCs are the high number of power semiconductors [17], besides the high complexity of their modulation techniques [19].
In order to overcome the high number of employed switches, some papers proposed the use of new topologies with a reduced number of switches such as the Sparse Matrix Converter (SMC), the Very Sparse Matrix Converter (VSMC), and the Ultra Sparse Matrix Converter (USMC) [22,23].In this paper, the authors present new converter topologies that offer a reduced number of overall semiconductor devices in comparison to the SMC, the VSMC, and the USMC.
Recently, many researchers have developed works related to Model Predictive Control (MPC), which is an excellent option to simplify the MC operation, since this control technique directly activates the converter switches, with no need for modulation, besides presenting many other advantages such as fast dynamic response [24,25].In other words, many works [17,18,21] reported the complexity of operating MCs with modulation techniques such as the Venturini method and the space-vector modulation.The MPC sends firing signals to the switches, bypassing the complex modulation.
Thus, with those topological and control advances, MC applications are coming back as a trending topic in recent research.The combination of MCs with MPC has been widely used in wind power applications [26][27][28][29][30].Other modern applications of MCs are in motor drives, electric vehicles, and energy storage [31][32][33][34][35][36][37].The use of MCs in AC, DC, and hybrid microgrids is particularly new, and only a few papers have developed some analysis of this application.In [33], the possibility of using the 3 × 3 Direct Matrix Converter (DMC) was explored in a wide range of possible connections such as AC-AC, AC-DC, DC-AC, and DC-DC.
In [37], the idea studied in the present paper was first introduced, which was to use a DMC as a power interface in microgrids using MPC.In other words, the converter is responsible for synthesizing a high power quality microgrid voltage, while absorbing/injecting power from/into the main grid.In [37], many different operation cases were studied, and experimental results were presented.However, only the AC-AC 3 × 3 DMC was analyzed in an AC microgrid.
The main contributions of this paper are summarized as follows: 1.The application of a DMC with MPC as a power interface is proposed not only for AC microgrids, but also for DC and hybrid microgrids; 2. Two new DMC topologies with a reduced number of switches, applied as power interfaces in AC and DC microgrids, are proposed.The first one (called AC-AC 2 × 3 DMC) allows synthesizing the AC-microgrid three-phase voltage using only two phases of the three-phase grid voltage.The second one (called AC-DC 2 × 2 DMC) allows synthesizing the DC-microgrid voltage using only two phases of the three-phase grid voltage.Since one of the grid voltage phases is not used, the number of semiconductors required in the converters is decreased, leading to the reduction of the systems' cost and to an overall failure rate reduction.Besides, the systems' reliability is increased since even with the eventual loss of one of the grid voltage phases, due to a fault, the microgrid power supply can be maintained using the other two available phases of the grid voltage.The authors acknowledge that many papers have been published proposing different MCs with different numbers of input and output terminals [38][39][40][41][42].However, the converters proposed in the present paper have an extra important feature, which is to use the contactors K 1 , K 2 , K 3 , and K 4 to improve the system's power supply reliability by alternating between different phases of the main grid voltage, in case of the occurrence of faults.This is an essential feature to create a high power quality microgrid topology with high reliability, capable of supplying power to critical loads; 3. Two novel DMC topologies (the hybrid DMC and the reduced hybrid DMC) that can be applied to hybrid microgrids are introduced.These new microgrid configurations can integrate DC and AC energy sources and loads, adding new options for islanded mode operation and increasing the power-supply reliability.
All the topologies are able to maintain a high power quality microgrid voltage, despite the grid voltage power quality and despite the types of loads and generation sources connected to this microgrid.This is a very interesting feature for systems with the presence of distributed generation, operating in remote areas connected to a low power quality grid.The authors intend to propose new converter topologies with low cost, low failure rate, high reliability, high efficiency and high lifespan.These goals are achieved due to the absence of the sensitive DC-link capacitors in DMCs, due to the reduction of the number of switches, and due to the possibility of operating disconnected from the main grid.It is important to emphasize that reducing the number of switches could potentially reduce the failure rates.However, current stress might be an observed issue, which could deteriorate the converter reliability.

AC-AC 3 × 3 DMC
The first topology analyzed in this paper was first used for the power interface application in [37], which is composed of an AC-AC 3 × 3 DMC, using nine bidirectional switches, as shown in Figure 1a.This converter uses the three-phase input voltage (v iabc ) in order to synthesize the desired high power quality output voltage (v oabc ), which supplies a given AC microgrid.

AC-DC 3 × 2 DMC
The second topology analyzed in this paper is the AC-DC 3 × 2 DMC, which uses six bidirectional switches in order to supply a DC microgrid, as shown in Figure 1b.This topology uses the three input voltages (v iabc ) to generate the DC output voltage (v odc ).The authors acknowledge the previous use of this topology in applications such as battery State Of Charge (SOC) control [31].To the authors' knowledge, the power interface between the AC main grid and a given DC microgrid is a new application of such a topology.

AC-AC 2 × 3 DMC
The authors propose a new DMC topology that is able to supply a three-phase AC microgrid using only two phases of the three-phase input voltage.This topology, along with the control used, can both reduce the system's overall cost and increase the system's reliability.
The cost reduction is due to the use of only six bidirectional switches instead of nine, as in the topology shown in Figure 1a, meaning a reduction of six IGBTs and of six diodes.
From the reliability point of view, if the three phases of the three-phase input voltage are available, one can synthesize the output voltage using, for example, phases A and C, as shown in Figure 1c.If, for instance, a fault occurs is phase C, the DMC can synthesize the output voltage using phases A and B. In other words, one can use the contactors K 1 , K 2 , K 3 , and K 4 to select any input-voltage phase combination, as long as any two different phases of the grid voltage are connected to the two DMC's input terminals.
It is important to notice that this topology has the same number of switches of a conventional three-phase, two-level back-to-back converter (twelve IGBTs plus twelve diodes) that could be used for this application.The proposed topology, however, might present lower cost and higher reliability due to the absence of the bulky and sensitive DC-link capacitors, besides the fact that the DMC switches suffer less voltage stress, as previously mentioned, reducing failure rates.
Furthermore, this topology also results in a smaller number of overall semiconductor devices (twelve IGBTs plus twelve diodes) in comparison to other AC-AC MCs with a reduced number of switches such as the SMC (fifteen IGBTs plus eighteen diodes), the VSMC (twelve IGBTs plus thirty diodes), and the USMC (nine IGBTs plus nineteen diodes).

AC-DC 2 × 2 DMC
Similarly to the previous case, it is also possible to synthesize a DC voltage, in order to supply a DC microgrid, using only two phases of the three-phase input voltage, as depicted in Figure 1d.This topology has only four bidirectional switches, resulting in a reduction of four IGBTs and of four diodes in comparison to the topology presented in Figure 1b.

Hybrid DMC
The authors also propose a new topology called hybrid DMC that can supply power to AC and DC microgrids, simultaneously.Besides, this topology allows for the system's islanded operation in case of the loss of the main grid.This configuration is depicted in Figure 1e.
The Hybrid DMC is simply the combination of the topologies shown in Figure 1a,b in the same structure.In normal operation mode, the AC-AC 3 × 3 DMC regulates the AC microgrid voltage.In this case, however, the AC-DC 3 × 2 DMC controls the SOC of a battery system present in the DC microgrid, instead of controlling a DC capacitor voltage.
When a fault is detected in the main grid, the system can start operating in islanded mode.Thus, the contactors K A , K B , and K C must open, keeping the system isolated from the main grid.At this moment, the switches S Aa , S Bb , and S Cc must be kept closed, and the AC-DC 3 × 2 DMC stops regulating the battery SOC and becomes a DC-AC 2 × 3 DMC, which is responsible for regulating the AC microgrid voltage (v oabc ), with the battery working as a DC voltage source that both serves as an input for the DMC and maintains the DC microgrid voltage regulated, while the battery SOC remains within its constant-voltage region.
Moreover, the contactor K dc must be closed in order to connect the capacitor C dc to the system, forming a current input filter that does not allow that the converter's switched current flows towards the DC microgrid, when in islanded operation mode.
Thus, the authors propose a new topology with the absence of DC capacitors in order to increase the system's reliability and lifespan.This topology does not have a DC link and only needs a small DC capacitor, as a current filter, that is not essential for the system operation.This capacitor is only connected in special cases and does not suffer much voltage stress.

Reduced Hybrid DMC
Finally, the authors propose the reduced hybrid DMC as depicted in Figure 1f.This system is able to operate in the exact same way as the hybrid DMC, shown in Figure 1e, but it is a more economical solution, with a reduced number of switches.In other words, this topology is composed of the DMCs shown in Figure 1c,d, and it results in a converter with ten bidirectional switches, which means a reduction of ten IGBTs and ten diodes in comparison to the hybrid DMC.
In the islanded operation mode, the switches S A+ and S C− must be kept closed, and the AC-AC 2 × 3 DMC keeps regulating the AC microgrid voltage (v oabc ), but with the positive (+) and negative (−) DC voltages as inputs (imposed by the battery), instead of the phases A and C of the grid voltage.This is the same as in the hybrid DMC operating in the islanded mode.

Control Diagrams
The control strategy adopted in this work is based on two control loops: an outer voltage control loop using PI controllers and an inner current control loop using MPC.The only exceptions are in the cases in which there is a battery system replacing the DC capacitor (hybrid DMC and reduced hybrid DMC).In such cases, instead of an outer voltage control loop, there is an outer SOC control loop.All the control strategies are depicted in Figure 2. In all cases, either the voltage control or the SOC control generates a current reference that is provided to the MPC.The MPC details are further discussed in Section 5.For the AC microgrid cases, the voltage control loop is executed in a dq-rotating reference frame aligned with the input-voltage angle (θ S ).In order to obtain this angle, the PLL circuit used is the positive-sequence detector presented in [43].The positive-sequence detector is able to extract the positive-sequence fundamental-component of a voltage along with its angle.
The feedforward term, which is common to almost every control strategy, is essential for the maintenance of high power quality output voltages.This term is responsible for rejecting disturbances related to the connection and disconnection of loads and generation sources in the microgrids.
An important fact known about the DMC operation is that some switching restrictions are required for its proper operation [17][18][19].In other words, in order to avoid short circuits, since the converter is fed by a voltage source, no two input terminals can be connected, simultaneously, to the same output terminal.Besides, there must always be a path for the load current to flow through, meaning that, in every sampling step, one of the input terminals must be connected to each of the output terminals.For example, in the case of the AC-AC 3 × 3 DMC (see Figure 1a), these switching restrictions can be summarized as: S Aj + S Bj + S Cj = 1, in which a given switch assumes State 0 if it is open and State 1 if it is closed.The mentioned restriction results in 27 possible switching states to be used in the MPC (N = 27), in which a switching state represents a given combination of the states of each switch.For this reason, in Figure 2a, the predictive model block provides 27 different values of predicted currents to be compared to the current references, through the cost function block.The cost function block outputs nine firing signals to activate each of the bidirectional switches.This process occurs in every control sampling step.
Since the mentioned restrictions are defined by the converter topology (number of input and output terminals), the number of possible switching states varies for each of the topologies.In Figure 2b, the control diagram applied to the AC-DC 3 × 2 DMC (see Figure 1b) is shown.In this case, nine switching states are allowed (N = 9) to trigger the six bidirectional switches.
In Figure 2c, the control diagram applied to the AC-AC 2 × 3 DMC (see Figure 1c) is shown.In this case, since there are only two input terminals available, the number of possible switching states is equal to eight (N = 8).
In Figure 2d, the control diagram applied to the AC-DC 2 × 2 DMC (see Figure 1d) is shown.In this case, the number of possible switching states is equal to four (N = 4) to trigger the four bidirectional switches.
In normal operation conditions, the AC part of the hybrid DMC, depicted in Figure 1e, operates with the control shown in Figure 2a, while its DC part operates with the control shown in Figure 2e, which is basically the same control as the one depicted in Figure 2b, but with the SOC loop substituting the voltage loop.The feedforward term is not required in the SOC loop for two reasons.First, the battery is designed with an energy-storage capacity much higher than the output capacitor.In other words, the battery must be capable of absorbing power variations, maintaining the power supply to the microgrid loads for a long period of time.Thus, load and generation variations that occur in the microgrid will only slightly affect the battery SOC.The second reason is that, even if considerable SOC variations occur, the battery voltage will only suffer small variations for a large range of the SOC.This way, transient issues will not be very critical to the DC-microgrid voltage power quality.In the islanded mode, the hybrid DMC operates with the control shown in Figure 2f.
In normal operation conditions, the AC part of the reduced hybrid DMC, depicted in Figure 1f, operates with the control shown in Figure 2c.Its DC part operates with the same control as the one depicted in Figure 2d, but with the SOC loop substituting the voltage loop.In islanded mode, the reduced hybrid DMC operates with the control shown in Figure 2f, the same way as the hybrid DMC.

System Modeling
The system model can be obtained through the single-phase equivalent circuit depicted in Figure 3.In this figure, the DMC is modeled as a voltage source (v c ), the output filter by its elements (L and C), and the microgrid load and generation sources by a current source (i L ).By applying Kirchhoff's laws to this circuit, the following equations are obtained:

Model Predictive Current Control
The predictive current model is obtained, through a discretization of (1), using the Euler method with sampling period τ s .In other words, the Euler method is a numerical integration technique that transforms the generic differential equation represented in (3) into its discrete form represented in (4). x The Euler method is used to transform the continuous differential Equation ( 1) into its discrete form as follows: Thus, the predictive current model is obtained simply by rearranging (5) as follows: In the AC microgrid case, three different currents are predicted using (6) as follows: In a DC microgrid, only one current is predicted as follows: The variables v cj (for j = a, b, c, +, −), which are the voltages synthesized by the DMCs, are the control actuation variables responsible for executing the predictive control.In other words, in each sampling step, the control predicts N (the number of possible switching states) different values of output currents (i oa , i ob , i oc , or i odc , depending on the topology) to be compared to the given current reference.The predicted currents are a function of the converter voltages (v cj ) that are calculated N times for each possible switching state using ( 11)- (15).Each of the matrix equations described in ( 11)-( 15) is used depending on the DMC topology utilized (see Figure 1).In Figure 2, which illustrates the control diagrams of each of the DMC topologies, one can observe the number of the matrix equation used in each case (see the predictive model blocks).
To sum up, the predictive control operates by predicting what would be the behavior of the output current in the next sampling step if a given voltage were synthesized by the converter.However, the possible instantaneous voltages that could be synthesized by the converter are limited by the possible switching states.In other words, the voltages synthesized by the converter (v cj ) are a function of the converter's switching state and the converter's input voltage (v ij ) (see ( 11)-( 15)).Therefore, if for instance, the microgrid topology shown in Figure 1a were to be used, the control diagram shown in Figure 2a would be utilized.In this case, (11) ) with the current reference provided by the outer control loop, the predictive control is able to decide which switching state will be applied to the DMC switches in order to obtain, in the next time step, the output current desired.
The cost function is the part of the predictive control responsible for indicating the best switching state to trigger the DMC.The best switching state is the one that results in a predicted current with the lowest error in relation to the current reference.In the AC microgrid cases, the cost function used is the one shown in (16) and in the DC microgrid cases is the one shown in (17).By analyzing ( 16) and (17), it is clear that the best switching state, the one used to trigger the DMC's switches in the next time step, is the one corresponding to the lowest value of g )

Controller Parameters' Design
By applying the Laplace transform in (2) and after some algebraic manipulation, the following equation is obtained: In order to execute the control design regarding the reference tracking functionality using the linear-control tools, a linear model must be obtained.The MPC is a high-bandwidth controller [24,25] that can be modeled as a unitary gain when the voltage-controller dynamics are analyzed, since the latter has a closed-loop bandwidth much lower than the current-control one.Thus, using this approximation along with (18), the system's linear model, used for the voltage-controller parameters' design, can be obtained as shown in Figure 4.This model can be used for designing the linear-voltage controllers for both the AC and DC microgrid cases.It can be used to represent DC signals (in the DC-microgrid case) or to represent the behavior of a single phase of a three-phase system (in the AC-microgrid case).
It is very desirable to analyze how a given disturbance (I L ) affects the microgrid output voltage (V o ).Thus, the block diagram depicted in Figure 4 can be adapted to analyze the disturbance rejection characteristic of the system , resulting in Figure 5.

Stability Analysis
In this section, the linear models shown in in Figures 4 and 5 are implemented in Simulink/MATLAB in order to analyze the time and frequency domain characteristics of the closed-loop systems, for four different sets of parameters of the linear-voltage controller (PI 1 (s), PI 2 (s), PI 3 (s), and PI 4 (s)).These sets of parameters are shown in Table 1.The following gains were applied to the linear models: C = 0.0001, which corresponds to the capacitance of the output filter (0.1 mF); V base = 179.6,which is the output-voltage reference (phase-to-ground peak value of the output voltage corresponding to a 220-V line-to-line rms value); I base = 48 (48 A), which corresponds to the output-current-rated value.The software Simulink/MATLAB provides linear-control tools that allow one to interactively visualize the time domain and frequency domain characteristics of a given closed-loop system as a function of the proportional and integral gains of a PI controller.Thus, the authors visually selected the four different sets of parameters shown in Table 1, in such a way as to obtain different reference-tracking and disturbance-rejection dynamic behaviors, in order to validate the proposed linear model, as will be deeply analyzed and discussed both in this section and in Section 8.The validation was executed by comparing the output-voltage behavior obtained with the linear models, analyzed in this section, with the output-voltage behavior obtained with the real systems simulated in PSCAD/EMTDC, whose results are presented in Section 8.
By applying the four different sets of parameters to the block diagrams shown in Figures 4 and 5, four different reference-tracking open-loop transfer functions (G n (s)), four different reference-tracking closed-loop transfer functions (F n (s)), and four different disturbance-rejection closed-loop transfer functions were obtained (H n (s)), for n = 1, 2, 3, and 4.
In this article, the DMC control had two main objectives: the reference tracking functionality (to follow a voltage reference in order to keep the microgrid output voltage (v o ) regulated) and the even more important objective of being able to reject load disturbances.The reference tracking dynamics were secondary, since the voltage reference was a constant signal, and once the system reached its operational voltage, not much control effort must be applied for this functionality.The disturbance rejection, on the other hand, was very important since the microgrid load and generation were constantly changing.
In Figure 6, the system's responses to an unit-step signal are shown for the four different transfer functions F n (s) previously described.Then, if one uses the set of parameters corresponding to the controller PI 1 (s), they will obtain a highly damped system as shown in Figure 6 (F 1 (s)) and as confirmed by its corresponding Bode plot shown in Figure 7 (G 1 (s)), which has a high phase margin equal to 89 • .However, this controller leads to a poor disturbance rejection characteristic since it presented considerably low negative magnitudes for low frequencies, as illustrated in Figure 8 (H 1 (s)), and noticing that the fundamental component was a DC signal (0 Hz) in the dq-rotating reference frame, in which the control was executed.
In order to improve the system disturbance rejection characteristic, one can increase its bandwidth using the controller PI 3 (s), for example.By analyzing Figure 9, one can see that F 3 (s) had higher bandwidth (24,341 rad/s) in comparison to F 1 (s) (8,439 rad/s).This bandwidth increase was reflected in the faster time response, as illustrated in Figure 6.The usage of PI 3 (s) still resulted in a highly-damped dynamic response, with the phase margin equal to 89 • , as shown in Figure 7 (G 3 (s)).There was a limit to which the system bandwidth could be increased related to the limitations of the digital implementation of the control.
Another solution to increase the system's disturbance rejection characteristic was to decrease its phase margin, leading to a less damped dynamic response.F 2 (s) and F 4 (s) had poorly-damped responses (see Figure 6), related to their low phase margins (68 • and 35 • , respectively).However, the usage of PI 2 (s) and PI 4 (s) resulted in high disturbance rejection characteristics, as depicted in Figure 8 (H 2 (s) and H 4 (s), respectively), since they presented higher negative amplitudes (meaning smaller gains and higher attenuation), and thus, the output voltage (V o ) suffered smaller variations for a given input load current (I L ).By analyzing Figure 9, one can notice that for the transfer function F 4 (s), a resonance peak appeared, which indicated the poorly-damped characteristic.

Simulation Results
In this section, simulation results are presented for each of the DMC topologies illustrated in Figure 1.These simulations were carried out on PSCAD/EMTDC, with all the devices shown in Figure 1 represented.The predictive control was executed through a C code, using the software compiler.The DMCs' bidirectional switches were composed of IGBTs, and the microgrids were connected to a grid with voltage equal to 4 kV (phase-to-ground, peak value).This voltage was selected in such a way that the highest instantaneous voltage that the IGBTs must be capable of withstanding was equal to 6 kV, which corresponded to the voltage between two phases at a given instant in which one of them was in its peak.This is a voltage level compatible with modern IGBTs available in the industry.In every microgrid topology analyzed, the LC output filters presented equal parameters: L = 5 mH and C = 0.1 mF.The DMCs' input filters were disregarded since the focus of this work was to analyze the operation of the microgrids and not the effect of such systems in their connection to the main grid.

AC-AC 3 × 3 DMC
In Figure 10, one can analyze the operation of the AC-AC 3 × 3 DMC (see Figure 1a) using the voltage controller PI 1 .In Figure 10a, one can notice that the system behaved according to what was analyzed in Figure 6, when the output-voltage reference changed from 0.5 pu to 1 pu, in which the voltage base was equal to 220 V (line-to-line rms value).In other words, the system was able to track the voltage reference properly with a smooth and damped dynamic behavior (see the v od signal).At t = 0.2 s, a load step was imposed on the AC microgrid (connection of an RL load with L = 7 mH and R = 0.4 Ω), and the output voltage suffered a sag of about 25% when no feedforward was used, as shown in Figure 10a and as confirmed by the variation of the output-voltage signals in the abc reference frame (v oabc ), depicted in Figure 10b.When the feedforward term was added to the control, the signal v od remained constant (see Figure 10c), without oscillations, when the same load step was imposed at t = 0.2 s.This showed the high disturbance rejection characteristic obtained using the feedforward term.This fact is further illustrated in Figure 10d, in which the output-voltage signals in the abc reference frame are shown.These signals did not oscillate and did not deviate from their corresponding references when the load step occurred.
In Figure 11, one can analyze the operation of the AC-AC 3 × 3 DMC using the voltage controller PI 4 .By analyzing Figure 11a, it is possible to notice that the system had a reference-tracking dynamic behavior according to that expected from Figure 6, in which the system responded in a poorly-damped fashion to the step input signal.However, one can notice the high disturbance rejection characteristic obtained with this controller (as expected from Figure 8).Even without the feedforward term, the v od signal was barely affected (in comparison to Figure 10a) by the load connection that occurred at t = 0.2 s.Of course, with the feedforward term (see Figure 11c), the disturbance rejection characteristic improved even further.
The selection of the voltage controller PI 4 might be a good choice for this application, since the disturbance rejection functionality was more important than the reference tracking one.However, it is important to emphasize that the aim of this analysis was not to propose an ideal controller; it was rather to show some different tuning possibilities for the voltage controllers, depending on the specific requirements.
At t = 0.3 s, the non-linear load was connected to the AC microgrid as one can observe in Figure 12a, in which the microgrid current is shown.The non-linear load corresponded to a three-phase diode-based rectifier supplying power to a resistive load with a value equal to R = 10 Ω.In this figure, the system operated using the voltage controller PI 1 and no feedforward.By analyzing Figure 12b, it is possible to realize that the output voltage (v oabc ) became considerably distorted due to the circulation of the harmonic currents, drawn by the non-linear load.This voltage profile presented a Total Harmonic Distortion (THD) of over 10% (see Figure 12c).
In order to understand the voltage distortion, one must consider Figure 8 and observe the gains of H 1 (s) (1 dB) and of H 4 (s) (−10 dB) at 2262 rad/s.Since the control was executed in the dq rotating reference frame with the synchronous angular speed ω s , both the negative sequence fifth and the positive sequence seventh harmonics became a sixth harmonic in the rotating reference frame.In other words, | − 5ω s − ω s | = 6ω s =2262 rad/s and |7ω s − ω s | = 6ω s = 2262 rad/s.The positive gain (1 dB) for H 1 (s) meant that not only this transfer function did not attenuate the harmonic components, but it even provided a small increase for those frequencies.The non-linear load connection represented a model disturbance with different frequencies in comparison to the fundamental one.Thus, the analysis of this disturbance can be made through the Bode diagram represented in Figure 8.The connection of a non-linear load (represented by I L in the model) will distort more or less the output voltage (represented by V o in the model), depending on the magnitudes of the transfer functions represented in Figure 8.The transfer function H 4 (s), on the other hand, had a −10-dB gain that resulted in the filtering of those harmonic components, resulting in the voltage profile depicted in Figure 12e, which had a THD of less than 0.5%, as shown in Figure 12f.
One can notice that the DMC with MPC was able to synthesize a high power quality output voltage (see Figure 13a) even when the DMC input voltage (see Figure 13b) was distorted and unbalanced.This meant that a microgrid using this combination of converter and control could, for example, be connected to a "weak" grid situated in remote locations with the presence of distributed generation and non-linear loads and still provide a high power quality voltage to sensitive loads.In this simulation, the input voltage presented 14% of the fifth harmonic component, 10% of the seventh harmonic component, and 50% of voltage sag in phase A.
In Figure 14, it is possible to observe the operation of the AC microgrid when a power flow reversion occurred (see Figure 14c).That is to say, at t = 0.6 s, both the linear and non-linear loads were disconnected, and the generator was connected to the microgrid as it started to provide power to the main grid.This was a 15-kW permanent-magnet synchronous generator.By analyzing Figure 14a, it is clear that the output voltage was not affected at all by this severe disturbance, illustrating the high disturbance rejection characteristic obtained.

AC-DC 3 × 2 DMC
In Figure 15, one can analyze the operation of the AC-DC 3 × 2 DMC supplying power to a DC microgrid using the controller PI 1 (s).
As previously mentioned, the linear model presented in this work, and shown in Figure 4, can be used for designing the voltage controllers in both cases: AC and DC microgrids.Thus, the results depicted in Figure 15 were obtained using the controller PI 1 (s) previously presented.In Figure 15a, one can observe the DC microgrid output voltage (v o ) in two different cases: with and without the feedforward term.At t = 0.05 s, the voltage reference changed from 200 V to 400 V, and it was clear that the output voltage reached its steady-state point with a smooth and damped dynamic behavior, similar to the behavior obtained in Figure 10a, which corresponds to the AC microgrid operating using the same controller.Moreover, one can observe the high disturbance rejection characteristic obtained with the feedforward term when responding to a 16-kW load connection that occurred at t = 0.2 s.In Figure 15b,c, it is possible to see the output currents (i o ) for the cases with feedforward and without feedforward, respectively.Finally, in Figure 15d, one can observe the DMC input voltage (v i ), which was distorted and unbalanced, and the converter was able to synthesize a high power quality voltage despite the low power quality grid voltage.In Figure 16, one can analyze the operation of the AC-DC 3 × 2 DMC supplying power to a DC microgrid using the controller PI 4 (s).Once again, it is possible to notice that the dynamic behavior of the DC-microgrid voltage (see Figure 16a) was similar to the one obtained in the AC microgrid (see Figure 11a) regarding the reference-tracking functionality.In other words, in both cases, the output voltage followed the reference with poorly-damped dynamics when the PI 4 (s) controller was used.Besides, the disturbance-rejection characteristic was improved with PI 4 (s) when responding to the load connection that occurred at t = 0.2 s (the voltage sag was smaller in Figure 16a than in Figure 15a when no feedforward was used), which also occurred in the AC microgrid using the same controller.In Figure 16b,c, one can observe the output current (i o ) along with its reference for the cases with and without the feedforward term, respectively.These results proved the effectiveness of the MPC, which was able to track the reference quickly.Finally, Figure 16d shows the DMC input voltage (v i ), which was distorted and unbalanced.

AC-AC 2 × 3 DMC
In Figure 17, one can analyze the operation of the AC-AC 2 × 3 DMC supplying power to an AC microgrid, using PI 1 (s) and using the feedforward term, with the grid voltage (v iabc ) balanced and sinusoidal.These results proved that it was possible to synthesize a three-phase output voltage properly using only two phases of the input voltage.In Figure 17a, it is possible to observe the DMC switched voltage (v sabc ), which was the output voltage measured before the filter, along with the converter's input voltage (v iabc ).One can notice that the output voltage only switched between two phases of the three-phase input voltage, as expected from this topology.This fact led to a reduction of the output voltage (v oabc ) power quality, as can be seen by carefully analyzing its waveform (see Figure 17b) and by observing its corresponding THD (see Figure 17c) with a value of approximately 1%, which is still a considerably low value.This voltage profile led to the output currents depicted in Figure 17d.It is important to notice that at t = 0.5 s, the non-linear load was connected and the DMC was still able to synthesize an adequate output voltage with a THD with a value equal to approximately 1%.In Figure 18, one can analyze the operation of the AC-AC 2 × 3 DMC supplying power to an AC microgrid, using PI 1 (s) and using the feedforward term, with the grid voltage (v iabc ) unbalanced and distorted.In Figure 18a, it is possible to observe the switched voltage (v sabc ), which switched between two phases of the input voltage (v iabc ), including the sagged phase A (v ia ).Still, the DMC was able to synthesize a proper three-phase-output voltage (v oabc ), as shown in Figure 18b, with a THD lower than 5%, even when the non-linear load was connected at t = 0.5 s. (a)

Hybrid DMC
In Figure 20, the results of the operation of the hybrid DMC (see Figure 1e) in the transition moments, from normal operation mode to islanded operation mode and from islanded operation mode back to normal operation mode, are shown.In Figure 20a, the SOC of the battery system is shown during the entire simulation period.At t = 0.5 s, the AC loads were connected, and at t = 1 s, the system was islanded.In order to emulate an islanding detection system, the grid contactors (K A , K B and K C ) opened at t = 0.995 s, and at t = 1 s, the DC-AC 2 × 3 DMC assumed the regulation of the AC-microgrid voltage.When the system became islanded, the SOC started to decrease as the battery was feeding the power required by the AC loads, which must be kept supplied.At t = 1.8 s, the AC generator was connected and started to generate an amount of power higher than that required by the AC loads, in such a way that the battery SOC began to increase.At = 2.7 s, a large DC load was connected, so that the SOC started to decrease with a higher rate.At t = 3 s, the system was connected back to the grid and the AC-DC 3 × 2 DMC returned to its function of regulating the battery SOC at the nominal operational value equal to 82%.
The DC voltage was kept constant, but it suffered an overshoot when the main grid was reconnected to the system (see Figure 20b), because the SOC control was designed to be fast (to fit in the simulation period), and thus, a current peak flowed to the battery (see Figure 20c) in order to recover its nominal value of SOC.
Moreover, by analyzing Figure 20d, one can observe the AC microgrid output voltage (v oabc ) when the system became islanded.This voltage slightly deviated from its reference, but the system was able to quickly go back to properly tracking the reference, as the AC microgrid voltage regulation responsibility migrated from the AC-AC 3 × 3 DMC to the DC-AC 2 × 3 DMC.

Conclusions
In this paper, different DMC topologies were employed in a new application of power interface of microgrids.Some of the topologies were new and have the potential of reducing costs, increasing the efficiency and reliability of the systems, due to the reduced number of switches, which is very desirable in microgrid applications.The combination of linear control and MPC proved to be a robust control solution that was able to maintain a high power quality output voltage, despite the generation and loads connected to the microgrid.Besides, the analyzed systems were able to feed power with high power quality to a microgrid despite the voltage profile of the main grid to which it was connected.Thus, these systems were very suited to feed critical loads located in remote regions, connected to "weak" grids with the presence of distributed generation, for example.In Section 8, simulation results demonstrated that the microgrids' output voltages were very robust to power variations that occurred due to load connection and generation fluctuations.In other words, the combination of DMC with MPC, along with an outer voltage control with a feedforward term, proved to be effective at rejecting disturbances, maintaining the output voltage with a high power quality.Besides, the DMC with MPC could synthesize a proper output voltage despite the input-voltage profile that contained a considerable amount of harmonic distortion and unbalance.The authors proposed a modeling that was suited to represent both AC and DC microgrid topologies when composed of a DMC operating with MPC.The proposed modeling proved to be suitable to design the parameters of the linear voltage controller that composed the outer control loop.A stability analysis was executed showing stability margins, bandwidths, and disturbance-rejection characteristics in a comparison between four different parameters of the voltage controller.The behavior predicted by the stability analysis, using the proposed linear model, matched the actual behavior of the real systems simulated on PSCAD/EMTDC, as the systems behaved satisfactorily with proper dynamics and proper disturbance rejection behavior, validating the linear model.
Simulation results demonstrated that the DMC topologies with a reduced number of switches were capable of properly synthesizing the microgrids' output voltages, even though some reduction on the output-voltage power quality was noticed.The DMC topologies with a reduced number of switches utilized only two phases of the three-phase-input voltage in order to synthesize either an AC-microgrid three-phase voltage or a DC-microgrid voltage.The authors introduced the hybrid DMC that offered the possibility of islanded operation by integrating the DC microgrid and its battery with the AC microgrid, maintaining a constant power supply to the loads.Simulation results demonstrated that the hybrid DMC was able to maintain a proper AC microgrid output voltage in the transitions from grid-connected mode to islanded mode and back to grid-connected mode.In other words, the AC microgrid output voltage retained a high power quality when the responsibility of synthesizing it migrated from the AC-AC 3 × 3 DMC (with the main grid voltage as an input) to the DC-AC 2 × 3 DMC (with the DC-microgrid-battery voltage as an input) and vice versa.Finally, the authors proposed the reduced hybrid DMC that operated similarly to the hybrid DMC, but with a reduced number of switches, resulting in a solution with possibly low cost, high reliability, high efficiency, low failure rate, and high lifespan.As future works, the authors intend to execute analysis regarding the effect of the connection of the proposed topologies to the main grid.In other words, besides issues related to harmonic distortion caused by the typical harmonic currents reflected to the main grid by the DMC, other serious issues might occur.For example, the connection of the topologies with a reduced number of switches to the main grid might be harmful since these converters are connected to only two phases of the grid.In order to execute this analysis, a deeper modeling of the grid to which the system is connected will be required.In the present work, the grid was modeled as a voltage source.

Figure 10 .
Figure 10.AC-AC 3 × 3 DMC operation with PI 1 (s).(a) Output voltage in the dq reference frame without feedforward, (b) output voltage without feedforward, (c) output voltage in the dq reference frame with feedforward, and (d) output voltage with feedforward.

Figure 11 .
Figure 11.AC-AC 3 × 3 DMC operation with PI 4 (s).(a) Output voltage in the dq reference frame without feedforward, (b) output voltage without feedforward, (c) output voltage in the dq reference frame with feedforward, and (d) output voltage with feedforward.

Figure 12 .
Figure 12.AC-AC 3 × 3 DMC operating with PI 1 (s) and no feedforward.(a) Output current, (b) output voltage, and (c) Total Harmonic Distortion (THD) of the output voltage.AC-AC 3 × 3 DMC operating with PI 4 (s) and no feedforward.(d) Output current, (e) output voltage, and (f) THD of the output voltage.

Figure 15 .
Figure 15.AC-DC 3 × 2 DMC operation with PI 1 (s).(a) Output voltage with and without feedforward, (b) output current with feedforward, (c) output current without feedforward, and (d) distorted and unbalanced input voltage.

Figure 17 .
Figure 17.AC-AC 2 × 3 DMC operation with the grid voltage (v iabc ) balanced and sinusoidal.(a) Output switched voltage along with input voltage, (b) output voltage, (c) output voltage THD, and (d) output current.
would be required.Then, at a given time step (k), the converter's input voltages would be measured (v ia [k], v ib [k], and v ic [k]) and, by applying the N different possible switching states into (11) (27 possible switching states in this case as previously mentioned), N different values of converter voltages (v ca [k], v cb [k] and v cc [k]) would be obtained.By substituting the N different values of converter voltages into (7)-(9), N different values of output currents (i oa [k + 1], i ob [k + 1], and i oc [k + 1]) would be obtained.By comparing the N different values of output currents calculated (i oa