Direct Phase Angle and Voltage Amplitude Model Predictive Control of a Power Converter for Microgrid Applications

: Several control strategies of the ﬁnite control set model predictive controls (FCS-MPC) have been proposed for power converters, such as predictive current control (PCC), direct predictive power control (DPPC), and predictive voltage control (PVC). However, for microgrid (MG) applications, the control strategy of the FCS-MPC for a power converter might be changed according to the operation mode of the MG system, which results in a transient response in the system voltage or current during the mode transition. This study proposes a new control strategy of FCS-MPC for use in both islanded and grid-connected operation modes of an MG system. Considering the characteristic of a synchronous generator, a direct phase angle and voltage amplitude model predictive control (PAC) of a power converter is proposed in this study for MG applications. In the islanded mode, the system frequency is directly controlled through the phase angle of the output voltage. In the grid-connected mode, a proportional-integral (PI) regulator is used to compensate for the phase angle and voltage amplitude of the power converter for constant power control. The phase angle of the system voltage can be easily adjusted for the synchronization process of an MG system. A comparison study on the proposed PAC method and existing predictive methods is carried out to show the effectiveness of the proposed method. The feasibility of the proposed PAC strategy is evaluated in a simulation-based system by using the MATLAB/Simulink environment.


Introduction
In recent years, the penetration of distributed generations (DGs), such as renewable energy resources (RESs) and energy storage systems (ESSs), in a microgrid (MG) system has increased rapidly [1]. Unlike conventional generations, such as gas or diesel generators, RESs and ESSs interconnect with an MG system by using power converters that can offer the benefit of higher controllability than conventional generations [2,3]. Since an MG system can operate in either islanded or grid-connected mode, power converters of such DGs should be designed appropriately to operate an MG system in both operation modes.
Generally, there are three types of power converters for MG systems, namely grid-forming, grid-feeding, and grid-supporting converters [4]. Grid-forming converters form the voltage amplitude and frequency of an MG system and are used in the islanded operation mode. They also can be used in a hybrid alternating current (AC)/direct current (DC) MG system to link the AC and DC subgrids system. By combining the DPPC and PVC techniques, reference [42] has proposed FCS-MPC-based MG control for both operation modes. In the grid-connected mode, the DPPC technique is used as the primary controller for regulation of the output power and the PVC technique is used to control the system frequency and voltage in the islanded mode. Hence, the power converter changes its control strategy according to the operation mode of the MG system. Since there is a significant difference between the cost function of DPPC/PCC and PVC, a large transient voltage and current might occur in the MG system.
To overcome these problems, this study proposes a new FCS-MPC that has a similar cost function in both operation modes. Taking the characteristic of the synchronous generator in which the phase angle and voltage amplitude are directly regulated, this study proposes a direct phase angle and voltage amplitude model predictive control (PAC) of the power converter for use in both islanded and grid-connected modes. The phase angle of the output voltage is responsible for the system frequency and voltage. As a result, the proposed PAC directly regulates the system frequency and voltage in the islanded mode. In the grid-connected mode, the proposed PAC can regulate power by using a PI regulator to compensate for the phase angle and voltage amplitude. For the transition mode of an MG system from the islanded mode to the grid-connected mode, the synchronization function can be easily added in the cost function of the PAC due to the ability of direct phase angle control. To show the effectiveness of the proposed PAC method, a comparison study with the existing predictive methods is considered in this study. In the conventional predictive methods, predictive voltage control is used in islanded operation while direct predictive power control is used in the grid-connected mode.
This study is organized as follows. Section 2 introduces the operation mode of an MG system and the power converter for the MG application. Section 3 summarizes the conventional approach to predictive voltage control of the power converter. Section 4 presents the proposed PAC for an MG application. Simulation results are shown in Section 5 and the main conclusions are summarized in Section 6.

Operation Mode of a Microgrid System
The typical configuration of an MG system is shown in Figure 1. It comprises multiple DGs and ESSs that are interfaced to the MG distribution line by the power converters. Proper coordination control of DGs and ESSs allows the MG system to provide a broad scope of ancillary services in the grid-connected mode and improves the reliability of the power supply. A static transfer switch (STS) is used to connect/disconnect the MG system to/from the utility grid. FCS-MPC-based MG control for both operation modes. In the grid-connected mode, the DPPC technique is used as the primary controller for regulation of the output power and the PVC technique is used to control the system frequency and voltage in the islanded mode. Hence, the power converter changes its control strategy according to the operation mode of the MG system. Since there is a significant difference between the cost function of DPPC/PCC and PVC, a large transient voltage and current might occur in the MG system.
To overcome these problems, this study proposes a new FCS-MPC that has a similar cost function in both operation modes. Taking the characteristic of the synchronous generator in which the phase angle and voltage amplitude are directly regulated, this study proposes a direct phase angle and voltage amplitude model predictive control (PAC) of the power converter for use in both islanded and grid-connected modes. The phase angle of the output voltage is responsible for the system frequency and voltage. As a result, the proposed PAC directly regulates the system frequency and voltage in the islanded mode. In the grid-connected mode, the proposed PAC can regulate power by using a PI regulator to compensate for the phase angle and voltage amplitude. For the transition mode of an MG system from the islanded mode to the grid-connected mode, the synchronization function can be easily added in the cost function of the PAC due to the ability of direct phase angle control. To show the effectiveness of the proposed PAC method, a comparison study with the existing predictive methods is considered in this study. In the conventional predictive methods, predictive voltage control is used in islanded operation while direct predictive power control is used in the gridconnected mode.
This study is organized as follows. Section 2 introduces the operation mode of an MG system and the power converter for the MG application. Section 3 summarizes the conventional approach to predictive voltage control of the power converter. Section 4 presents the proposed PAC for an MG application. Simulation results are shown in Section 5 and the main conclusions are summarized in Section 6.

Operation Mode of a Microgrid System
The typical configuration of an MG system is shown in Figure 1. It comprises multiple DGs and ESSs that are interfaced to the MG distribution line by the power converters. Proper coordination control of DGs and ESSs allows the MG system to provide a broad scope of ancillary services in the grid-connected mode and improves the reliability of the power supply. A static transfer switch (STS) is used to connect/disconnect the MG system to/from the utility grid. In the islanded operation mode of the MG system with no synchronous generator, at least one grid-forming converter is required to form the system frequency and voltage. The other grid-feeding converters can be designed to follow the grid-forming converter. In the grid-connected mode, because the MG frequency and voltage are formed by the utility grid, all converters can be gridfeeding converters to supply or absorb power to/from the MG and the utility grid as well. Since the MG system can operate in both grid-connected and islanded modes, the functionality of the power converter might be changed according to the operation modes. In addition, a synchronization scheme In the islanded operation mode of the MG system with no synchronous generator, at least one grid-forming converter is required to form the system frequency and voltage. The other grid-feeding converters can be designed to follow the grid-forming converter. In the grid-connected mode, because the MG frequency and voltage are formed by the utility grid, all converters can be grid-feeding converters to supply or absorb power to/from the MG and the utility grid as well. Since the MG system can operate in both grid-connected and islanded modes, the functionality of the power converter might be changed according to the operation modes. In addition, a synchronization scheme is essential for a smooth transition from the islanded mode to the grid-connected mode. Although the synchronization scheme can be integrated into the conventional PVC technique, the complexity of the converter control system might be increased. However, with the proposed direct phase angle and voltage amplitude MPC, the synchronization scheme can be added easily in the cost function to achieve a smooth transition mode for the MG system.

Predictive Voltage Control
The proposed PAC of a power converter with an output LC filter is presented in this study. The concept of a direct phase angle and voltage amplitude MPC is based on the conventional PVC technique that was presented in [42]. To easily understand the proposed PAC technique, this section summarizes the discrete converter model and the conventional PVC for a power converter with an output LC filter in the MG system.

Converter Model
The two-level, three-phase converter with an output LC filter shown in Figure 2 is considered in this study. To avoid short-circuiting the DC source, the two switches in each converter phase are operated in a complementary mode. The switching states of the power switches can be expressed by the switching signals S a , S b , and S c as follows.
if S 3 is on and S 6 is off 0, if S 3 is off and S 6 is on (2) S c = 1, if S 5 is on and S 2 is off 0, if S 5 is off and S 2 is on (3) Therefore, the combination of three switching signals provides eight possibilities of switching states and consequently eight voltage vectors can be obtained according to Equation (4). Figure 3 shows the eight voltage vectors (v i ) obtained from the combination of switching states. v i = 2 3 V dc e j(i−1) π 3 when i = 1, 2, . . . , 6 0 wheni = 0, 7 where V dc is the DC-link voltage. is essential for a smooth transition from the islanded mode to the grid-connected mode. Although the synchronization scheme can be integrated into the conventional PVC technique, the complexity of the converter control system might be increased. However, with the proposed direct phase angle and voltage amplitude MPC, the synchronization scheme can be added easily in the cost function to achieve a smooth transition mode for the MG system.

Predictive Voltage Control
The proposed PAC of a power converter with an output LC filter is presented in this study. The concept of a direct phase angle and voltage amplitude MPC is based on the conventional PVC technique that was presented in [42]. To easily understand the proposed PAC technique, this section summarizes the discrete converter model and the conventional PVC for a power converter with an output LC filter in the MG system.

Converter Model
The two-level, three-phase converter with an output LC filter shown in Figure 2 is considered in this study. To avoid short-circuiting the DC source, the two switches in each converter phase are operated in a complementary mode. The switching states of the power switches can be expressed by the switching signals Sa, Sb, and Sc as follows. S c = 1, if S 5 is on and S 2 is off 0, if S 5 is off and S 2 is on (3) Therefore, the combination of three switching signals provides eight possibilities of switching states and consequently eight voltage vectors can be obtained according to Equation (4). Figure 3 shows the eight voltage vectors ( ) obtained from the combination of switching states.
where Vdc is the DC-link voltage.   The mathematical equations of the converter system can be represented as a state-space system as in Equation (5).
where is the filter inductance; is the filter capacitance; is the filter current; is the output current; and is the output voltage.

Conventional Predictive Voltage Control
The discrete time model of the converter system is used to predict future behavior of the converter according to the possibilities of the voltage vectors as shown in Equation (7).
The predicted output capacitor voltage, which is represented in the αβ orthogonal reference frame (  ( + 1) and  ( + 1)), can be found by using Equations (7) and (8). Figure 4 shows the block diagram of the PVC for the converter with the output LC filter. By optimizing the cost function Equation (9), the optimal switching state that minimizes the error between the reference and predicted voltage vectors is obtained.
where * and * are the real and imaginary components of the voltage reference vector, respectively.

Re
Im The mathematical equations of the converter system can be represented as a state-space system as in Equation (5).
where L f is the filter inductance; C f is the filter capacitance; i f is the filter current; i o is the output current; and v c is the output voltage.

Conventional Predictive Voltage Control
The discrete time model of the converter system is used to predict future behavior of the converter according to the possibilities of the voltage vectors as shown in Equation (7). where The predicted output capacitor voltage, which is represented in the αβ orthogonal reference frame (v cα (k + 1) and v cβ (k + 1)), can be found by using Equations (7) and (8). Figure 4 shows the block diagram of the PVC for the converter with the output LC filter. By optimizing the cost function Equation (9), the optimal switching state that minimizes the error between the reference and predicted voltage vectors is obtained.
where v * cα and v * cβ are the real and imaginary components of the voltage reference vector, respectively.

Proposed PAC and Its Application in the MG System
Considering the stand-alone operation mode of the MG system, the main functionality of the power converter is to control the system frequency and voltage. Conventional PVC indirectly controls the system frequency and voltage through the αβ frame of the output filter voltage, in which the system frequency is represented by the phase angle of the output filter voltage as shown in Figure 4. Unlike conventional PVC, the proposed PAC in this study directly maintains the system frequency and voltage by predicting the phase angle and the voltage amplitude of the predicted output voltage vectors.

Proposed PAC Strategy
The principle of phase angle prediction is shown in Figure 5. Based on the real and imaginary components of the predicted output voltage vectors, the phase angle is calculated by using the inverse cosine function as in Equation (10). The eight possibilities of the predicted output voltage vectors ( ) provide eight possibilities of the phase angle.
where and are the real and imaginary components, respectively, of the predicted output voltage vectors ( + 1).
The predicted amplitude of the output voltage vector is given in Equation (11).
Once the phase angle and voltage amplitude are predicted, the optimal switching state that minimizes the error between the predicted and reference variables can be found by using the cost function gc in Equation (12).
Minimize the cost function g

Proposed PAC and Its Application in the MG System
Considering the stand-alone operation mode of the MG system, the main functionality of the power converter is to control the system frequency and voltage. Conventional PVC indirectly controls the system frequency and voltage through the αβ frame of the output filter voltage, in which the system frequency is represented by the phase angle of the output filter voltage as shown in Figure 4. Unlike conventional PVC, the proposed PAC in this study directly maintains the system frequency and voltage by predicting the phase angle and the voltage amplitude of the predicted output voltage vectors.

Proposed PAC Strategy
The principle of phase angle prediction is shown in Figure 5. Based on the real and imaginary components of the predicted output voltage vectors, the phase angle is calculated by using the inverse cosine function as in Equation (10). The eight possibilities of the predicted output voltage vectors (v ci ) provide eight possibilities of the phase angle.
where v cα are v cβ the real and imaginary components, respectively, of the predicted output voltage vectors v c (k + 1). The predicted amplitude of the output voltage vector is given in Equation (11).
Once the phase angle and voltage amplitude are predicted, the optimal switching state that minimizes the error between the predicted and reference variables can be found by using the cost function g c in Equation (12). where θ * p is the reference phase angle that corresponds to the reference frequency, E* is the reference voltage amplitude, and λ is the weighting factor. Since the phase angle and voltage amplitude should be controlled simultaneously with equal importance, the weighting factor λ is chosen as 1/E base in which E base is the base voltage of the MG system.
The flowchart of the proposed PAC algorithm is shown in Figure 6. The switching state that is expected to minimize the cost function Equation (12) is applied to the converter system. where * is the reference phase angle that corresponds to the reference frequency, * is the reference voltage amplitude, and  is the weighting factor. Since the phase angle and voltage amplitude should be controlled simultaneously with equal importance, the weighting factor  is chosen as 1/Ebase in which Ebase is the base voltage of the MG system. The flowchart of the proposed PAC algorithm is shown in Figure 6. The switching state that is expected to minimize the cost function Equation (12) is applied to the converter system.
g op = g c n op = n end n > 7 ?
Apply optimal vector Yes No Optimize the cost function gc Predict θ p and E p according to (10) and (11) Wait for next sampling instant where * is the reference phase angle that corresponds to the reference frequency, * is the reference voltage amplitude, and  is the weighting factor. Since the phase angle and voltage amplitude should be controlled simultaneously with equal importance, the weighting factor  is chosen as 1/Ebase in which Ebase is the base voltage of the MG system. The flowchart of the proposed PAC algorithm is shown in Figure 6. The switching state that is expected to minimize the cost function Equation (12) is applied to the converter system.
g op = g c n op = n end n > 7 ?
Apply optimal vector Yes No Optimize the cost function gc Predict θ p and E p according to (10) and (11) Wait for next sampling instant

Proposed PAC for an MG Application
Since the phase angle of the output voltage is directly controlled, the cost function of the PAC can be modified to operate the converter system in both the islanded and grid-connected modes. The flowchart of the proposed PAC algorithm for different operation modes of the MG system is shown in Figure 7.
In the islanded mode, the PAC for the grid-forming converter presented in Figure 6 is used to form the system frequency and voltage. The cost function g c can be used to find the optimal switching state. However, the cost function g c causes a steady-state error of the system voltage because the system performance between samples is not considered [33]. To solve the problem, the integral action is used in the cost function to reduce the steady-state error of voltage as given in Equation (13).
where E m is the measured voltage amplitude. The weighting factor λ is the same as in Equation (12). When the operation mode of the MG system changes from the islanded to the grid-connected mode, the synchronization process is active. The phase angle of the grid voltage is calculated according to (10); then, it is compared with the phase angle of the MG system. The error between the two phase angles is estimated subsequently. If the error is in the allowable range, the STS is closed to connect the MG system to the grid. The process of synchronization is shown in Figure 7, in which the cost function g 2 is used to minimize the phase angle error of the grid voltage and MG voltage whereas the cost function g 3 is used to control constantly the power of the converter in the grid-connected mode. The cost functions g 2 and g 3 are given as follows.
where the θ comp. = θ p − θ g dt is used to reduce the difference between the phase angle of the grid and the converter for the synchronization process.
where ∆θ and ∆E are the compensated phase angle and voltage amplitude for power control, respectively. When the MG system connects to the utility grid, the measured grid phase angle θ g is used for the phase angle reference of the PAC. By compensating for the phase angle and voltage amplitude, the real and reactive powers can be controlled. The real and reactive power transfer (P and Q) from the converter to the MG bus is given in (16) and (17).
where V c and V are the voltage amplitudes of the converter and bus voltage, respectively; R and X are the distribution line resistance and inductance, respectively; and δ is the different phase angle of the converter and bus voltages.
Since the impedance of the distribution line is mainly resistive (R >> X), the real power transfer mainly depends on the voltage amplitude while the reactive power transfer mainly depends on the phase angle. Based on this observation, the compensated phase angle and voltage amplitude for the  (18) and (19). The overall control diagram of the converter is shown in Figure 8.
where P* and Q* are the reference real and reactive powers, respectively; P m and Q m are the measured real and reactive powers; and k p and k i are the parameters of the proportional-integral controller, respectively. where P* and Q* are the reference real and reactive powers, respectively; Pm and Qm are the measured real and reactive powers; and kp and ki are the parameters of the proportional-integral controller, respectively.  where P* and Q* are the reference real and reactive powers, respectively; Pm and Qm are the measured real and reactive powers; and kp and ki are the parameters of the proportional-integral controller, respectively.

Simulation Results
A simple MG system shown in Figure 8 is considered to evaluate the performance of the proposed PAC, which consists of a converter-based distributed generation and a local load. The MG system connects to the utility grid by an STS. The system parameters are adopted from [40] as shown in Table 1.

Islanded Operation Mode
In the islanded operation mode, the functionality of the converter is the grid-forming converter that forms the system frequency and voltage. The performance of the proposed PAC in the islanded mode is shown in Figures 9-11. Energies 2018, 11, x FOR PEER REVIEW 10 of 21

Simulation Results
A simple MG system shown in Figure 8 is considered to evaluate the performance of the proposed PAC, which consists of a converter-based distributed generation and a local load. The MG system connects to the utility grid by an STS. The system parameters are adopted from [40] as shown in Table 1.

Islanded Operation Mode
In the islanded operation mode, the functionality of the converter is the grid-forming converter that forms the system frequency and voltage. The performance of the proposed PAC in the islanded mode is shown in Figures 9-11.
The real and reactive power supplied to the load from the converter is shown in Figure 9. The converter starts on the no load condition and the load connects to the MG system at 0.2 s. Additional load connects to the MG system at 1 s and disconnects at 1.5 s. It can be observed that the converter stably supplies power for the load change in the islanded operation mode. The output voltage and current of the converter in the case of load change are shown in Figures  10 and 11. The reference voltage amplitude is set to about 180 V and the system reference frequency is 60 Hz. It is shown that the output voltage and current are sinusoidal.   The behavior of the proposed PAC is shown in Figures 12 and 13, in which the phase angle and voltage amplitude are shown. It is shown that the measured phase angle of the output voltage follows the reference phase angle closely. The transient exists in the voltage amplitude when the load is changed whereas it does not in the phase angle of the output voltage. Owing to the integral action in the cost function, there is no steady-state error in the output voltage amplitude. The output voltage changes rapidly after changing load; consequently, it gradually recovers to the reference value. The real and reactive power supplied to the load from the converter is shown in Figure 9. The converter starts on the no load condition and the load connects to the MG system at 0.2 s. Additional load connects to the MG system at 1 s and disconnects at 1.5 s. It can be observed that the converter stably supplies power for the load change in the islanded operation mode.
The output voltage and current of the converter in the case of load change are shown in Figures 10  and 11. The reference voltage amplitude is set to about 180 V and the system reference frequency is 60 Hz. It is shown that the output voltage and current are sinusoidal.
The behavior of the proposed PAC is shown in Figures 12 and 13, in which the phase angle and voltage amplitude are shown. It is shown that the measured phase angle of the output voltage follows the reference phase angle closely. The transient exists in the voltage amplitude when the load is changed whereas it does not in the phase angle of the output voltage. Owing to the integral action in the cost function, there is no steady-state error in the output voltage amplitude. The output voltage changes rapidly after changing load; consequently, it gradually recovers to the reference value.

Synchronization Mode
The synchronization process is active when the converter receives the synchronization signal. The phase angle of the MG voltage is adjusted to be similar to the phase angle of the grid voltage. The performance of the proposed PAC in the grid synchronization mode is shown in Figures 14-16.
The converter receives the synchronization signal at 2 s and starts to adjust the phase angle of the output filter voltage. The MG voltage and grid voltage in one phase are shown in Figure 14. The phase angle of the MG voltage and the grid voltage is shown in Figure 15. It is shown that the PAC gradually changes the phase angle of the MG voltage to reduce the phase angle error between the MG voltage and the grid voltage. When the phase angle error is in the allowable range for synchronization, the closing signal is sent to the STS and the MG system connects to the grid at around 2.18 s. Once the MG system connects to the grid, the measured phase angle of the grid voltage is used as the reference for the converter. It is observed that the measured phase angle of the converter is tracked closely to the phase angle of the grid voltage after connecting to the grid and there is no transience in the phase angle in this operation mode.

Synchronization Mode
The synchronization process is active when the converter receives the synchronization signal. The phase angle of the MG voltage is adjusted to be similar to the phase angle of the grid voltage. The performance of the proposed PAC in the grid synchronization mode is shown in Figures 14-16.  The three-phase current and voltage of the converter during the transition mode from the islanded to the grid-connected mode are shown in Figure 16. It can be seen that a seamless transition is achieved with the proposed PAC. There is no transience in either the voltage or the current of the converter when the MG system connects to the grid. Under the steady-state condition, the voltage   The three-phase current and voltage of the converter during the transition mode from the islanded to the grid-connected mode are shown in Figure 16. It can be seen that a seamless transition is achieved with the proposed PAC. There is no transience in either the voltage or the current of the converter when the MG system connects to the grid. Under the steady-state condition, the voltage

Grid-Connected Operation Mode
When the STS is closed, the MG system is operated in the grid-connected operation mode where the converter plays the role of suppling constant power. The reference phase angle for the PAC is changed to the measured phase angle of the grid. Owing to the relationship of the real and reactive power with the phase angle and voltage amplitude, the PI regulator is used to control the power output by compensating for the phase angle and voltage amplitude.
The control performance of PAC for power regulation in the grid-connected mode is shown in Figure 18. Several step changes of real and reactive power are carried out to test the control performance of the proposed PAC. At 4 s, the real power reference is set to −5 kW. It is shown that although the coupling of real and reactive power exists, the output power of the converter is wellcontrolled. The converter receives the synchronization signal at 2 s and starts to adjust the phase angle of the output filter voltage. The MG voltage and grid voltage in one phase are shown in Figure 14. The phase angle of the MG voltage and the grid voltage is shown in Figure 15. It is shown that the PAC gradually changes the phase angle of the MG voltage to reduce the phase angle error between the MG voltage and the grid voltage. When the phase angle error is in the allowable range for synchronization, the closing signal is sent to the STS and the MG system connects to the grid at around 2.18 s. Once the MG system connects to the grid, the measured phase angle of the grid voltage is used as the reference for the converter. It is observed that the measured phase angle of the converter is tracked closely to the phase angle of the grid voltage after connecting to the grid and there is no transience in the phase angle in this operation mode.
The three-phase current and voltage of the converter during the transition mode from the islanded to the grid-connected mode are shown in Figure 16. It can be seen that a seamless transition is achieved with the proposed PAC. There is no transience in either the voltage or the current of the converter when the MG system connects to the grid. Under the steady-state condition, the voltage and current amplitudes are varied slightly because the functionality of the converter is changed to the grid-feeding converter. The real and reactive power of the converter during the transition mode is shown in Figure 17. When the MG system completely connects to the grid, the converter constantly supplies power in the amount of 5 kW and 0 kVAr.

Grid-Connected Operation Mode
When the STS is closed, the MG system is operated in the grid-connected operation mode where the converter plays the role of suppling constant power. The reference phase angle for the PAC is changed to the measured phase angle of the grid. Owing to the relationship of the real and reactive power with the phase angle and voltage amplitude, the PI regulator is used to control the power output by compensating for the phase angle and voltage amplitude.
The control performance of PAC for power regulation in the grid-connected mode is shown in Figure 18. Several step changes of real and reactive power are carried out to test the control

Grid-Connected Operation Mode
When the STS is closed, the MG system is operated in the grid-connected operation mode where the converter plays the role of suppling constant power. The reference phase angle for the PAC is changed to the measured phase angle of the grid. Owing to the relationship of the real and reactive power with the phase angle and voltage amplitude, the PI regulator is used to control the power output by compensating for the phase angle and voltage amplitude.
The control performance of PAC for power regulation in the grid-connected mode is shown in Figure 18. Several step changes of real and reactive power are carried out to test the control performance of the proposed PAC. At 4 s, the real power reference is set to −5 kW. It is shown that although the coupling of real and reactive power exists, the output power of the converter is well-controlled.

Grid-Connected Operation Mode
When the STS is closed, the MG system is operated in the grid-connected operation mode where the converter plays the role of suppling constant power. The reference phase angle for the PAC is changed to the measured phase angle of the grid. Owing to the relationship of the real and reactive power with the phase angle and voltage amplitude, the PI regulator is used to control the power output by compensating for the phase angle and voltage amplitude.
The control performance of PAC for power regulation in the grid-connected mode is shown in Figure 18. Several step changes of real and reactive power are carried out to test the control performance of the proposed PAC. At 4 s, the real power reference is set to −5 kW. It is shown that although the coupling of real and reactive power exists, the output power of the converter is wellcontrolled. The phase angle and amplitude of output voltage of the converter when the real power is changed from +2.5 kW to 0 kW and the reactive power is changed from 0 kVAr to 1 kVAr are shown in Figures 19  and 20, respectively. Negative real and reactive powers represent the charging of the ESSs in the MG system. Owing to the PI regulator of the power control loop, the voltage amplitude is changed to control the real power output of the converter and the phase angle is adjusted to control the reactive power output. Since the power converter constantly supplies or absorbs power, additional power is supplied from the utility grid as shown in Figure 21. The phase angle and amplitude of output voltage of the converter when the real power is changed from +2.5 kW to 0 kW and the reactive power is changed from 0 kVAr to 1 kVAr are shown in Figures 19 and 20, respectively. Negative real and reactive powers represent the charging of the ESSs in the MG system. Owing to the PI regulator of the power control loop, the voltage amplitude is changed to control the real power output of the converter and the phase angle is adjusted to control the reactive power output. Since the power converter constantly supplies or absorbs power, additional power is supplied from the utility grid as shown in Figure 21.

Comparison Study
In order to show the effectiveness of the proposed PAC method, a comparison study on the proposed method and the existing predictive control methods is carried out in this section. In the islanded operation mode, the proposed method is compared to the conventional predictive voltage control method presented in [42], whereas in the grid-connected mode, the proposed PAC is compared to the direct predictive power control method presented in [32].
With conventional predictive control, the controller of the converter changes according to the operation mode of the MG system. The predictive voltage control is used for islanded operation while predictive current or direct predictive power control is used for grid-connected operation. Figure 22 shows the waveforms of the output voltage and current with conventional predictive control when the operation mode is changed from islanded mode to grid-connected mode. Compared to Figure 16 where the proposed method is used, the waveforms of the output voltage and current in the case of the proposed method are better than the case of the conventional method. The change of inverter controller from predictive voltage control to direct predictive power control causes transience in the voltage and current as shown in Figure 22. In addition, the output power of the converter with conventional predictive control in the grid-connected mode is shown in Figure 23. The real and reactive power references are the same as that of the proposed PAC method (Figure 18). Although the real power is controlled well, there is steady-state error in the reactive power control. Since conventional direct predictive power control neglects the reactive power from the filter capacitor, the reactive power control is not correct. The direct predictive power control should be improved for the converter with an output LC filter. reactive power references are the same as that of the proposed PAC method (Figure 18). Although the real power is controlled well, there is steady-state error in the reactive power control. Since conventional direct predictive power control neglects the reactive power from the filter capacitor, the reactive power control is not correct. The direct predictive power control should be improved for the converter with an output LC filter.   reactive power references are the same as that of the proposed PAC method (Figure 18). Although the real power is controlled well, there is steady-state error in the reactive power control. Since conventional direct predictive power control neglects the reactive power from the filter capacitor, the reactive power control is not correct. The direct predictive power control should be improved for the converter with an output LC filter.   In the islanded operation mode, it is important to maintain accurate power sharing among multiple converters. An MG system with two converters is tested to show the effectiveness of the proposed method. Two converters with the same power rating are connected in parallel through a distribution line and supply to a common load. Figures 24 and 25 show the real and reactive power sharing in the cases of conventional predictive voltage control and the proposed predictive method, respectively. In the case of conventional predictive control, initially, the real and reactive power are unequally shared and there is an overshoot of the real and reactive power of DG 2 . By comparison, the proposed predictive control method shows superior performance to the conventional method as shown in Figure 25. The real and reactive power are shared accurately and there is no significant overshoot in output power. The current and voltage waveforms of the two converters with the conventional and proposed predictive methods are shown in Figures 26 and 27. It can be observed that the proposed predictive control method performs better than the conventional method.
unequally shared and there is an overshoot of the real and reactive power of DG2. By comparison, the proposed predictive control method shows superior performance to the conventional method as shown in Figure 25. The real and reactive power are shared accurately and there is no significant overshoot in output power. The current and voltage waveforms of the two converters with the conventional and proposed predictive methods are shown in Figures 26 and 27. It can be observed that the proposed predictive control method performs better than the conventional method.  the proposed predictive control method shows superior performance to the conventional method as shown in Figure 25. The real and reactive power are shared accurately and there is no significant overshoot in output power. The current and voltage waveforms of the two converters with the conventional and proposed predictive methods are shown in Figures 26 and 27. It can be observed that the proposed predictive control method performs better than the conventional method.

Conclusions
This study proposed a new PAC for a power converter for use in both islanded and gridconnected operation modes, which directly regulates the phase angle and voltage amplitude of the output voltage. With the proposed PAC, the converter behavior was similar to the conventional synchronous generator in which the system frequency and voltage were controlled through the phase angle and the amplitude of output voltage. Additionally, the synchronization process could be easier due to the direct regulation of the phase angle. In both islanded and grid-connected operation modes, the main cost function did not change significantly, which results in a seamless transition between the MG's operation modes. A comparison study on the proposed PAC method and existing predictive methods, namely predictive voltage control and direct predictive power control, was presented to show the effectiveness of the proposed method. It was observed that the proposed method could reduce the transience in the current when the operation mode is changed, maintain accurate real and reactive power sharing in islanded mode, and control the reactive power correctly in the grid-connected mode. With the ability of direct phase angle regulation, flexible constraints of system frequency could be considered in the cost function of the proposed PAC to improve the control performance of the MG system. In addition, the proposed PAC for power converters could be adopted easily for the virtual synchronous generator technique that mimics the transient characteristic of the synchronous generator, which is considered to be our future work.

Conclusions
This study proposed a new PAC for a power converter for use in both islanded and grid-connected operation modes, which directly regulates the phase angle and voltage amplitude of the output voltage. With the proposed PAC, the converter behavior was similar to the conventional synchronous generator in which the system frequency and voltage were controlled through the phase angle and the amplitude of output voltage. Additionally, the synchronization process could be easier due to the direct regulation of the phase angle. In both islanded and grid-connected operation modes, the main cost function did not change significantly, which results in a seamless transition between the MG's operation modes. A comparison study on the proposed PAC method and existing predictive methods, namely predictive voltage control and direct predictive power control, was presented to show the effectiveness of the proposed method. It was observed that the proposed method could reduce the transience in the current when the operation mode is changed, maintain accurate real and reactive power sharing in islanded mode, and control the reactive power correctly in the grid-connected mode. With the ability of direct phase angle regulation, flexible constraints of system frequency could be considered in the cost function of the proposed PAC to improve the control performance of the MG system. In addition, the proposed PAC for power converters could be adopted easily for the virtual synchronous generator technique that mimics the transient characteristic of the synchronous generator, which is considered to be our future work.

Conflicts of Interest:
The authors declare no conflict of interest. Cost function for synchronization g 3 Cost function for power control in grid-connected mode