## 4 Proposed Grid Current Closed-Loop Control
### Parameter Constraints of Proposed Compound Controller  
Next, the parameter constraint of this proposed PR + OMRC control strategy is analyzed in this section, in order to build the theoretical reference for the controller parameter design.  
The stability constraint is analyzed first. Figure 10 shows the simplified block diagram of the PR + OMRC, where the grid voltage is regarded as the disturbance. From Figure 10, the function expression of the grid current control error is  
\[i_{Er}(z)=\frac{1+Q(z)z^{-N_{Sa}/2}}{1+z^{-N_{Sa}/2}[Q(z)-S(z)P^{\prime}(z)]} \cdot\left[1-P^{\prime}(z)\right]\cdot\left[i_{g}^{*}(z)-G_{u_{g}2i_{g}^{2}}(z )u_{g}(z)\right] \tag{19}\]  
Figure 8: Block diagram of OMRC.  
Figure 7: Block diagram of closed-loop control configuration in discrete domain.  
Figure 9: Bode diagram of OMRC.  
where \(P^{\prime}(z)=PR(z)\cdot G_{i_{2e}2i_{g}}(z)/\left[1+PR(z)G_{i_{2e}2i_{g}}(z)\right]\) is the system closed-loop transfer function only under PR controller. Then the block diagram of the grid current control error is obtained from (19) and shown in Figure 11, where \(H(z)=Q(z)-S(z)P^{\prime}(z)\).  
According to Figure 11, the grid current control error contains two parts, namely, it can be regarded as the sum of the two current control errors under only one controller, which are defined as \(e_{PR}\) and \(i_{Er}\), respectively. In order to realize the global stability of the closed-loop system with the proposed compound controller, it is necessary to ensure \(e_{PR}\) and \(i_{Er}\) both converge. Therefore, the characteristic roots of the equivalent two closed-loop systems only under the PR controller and only under the OMRC should all be located within the unit circle of \(z\) plane:  
\[|H(z)|=\left|Q(z)-S(z)P^{\prime}(z)\right|<1 \tag{20}\]  
Next, the convergence constraints of the controller are analyzed. The major goal of this compound controller is to eliminate odd grid current's harmonics of caused by grid harmonics. From Figure 11, it yields  
\[i_{Er}(z)=\frac{1+Q(z)z^{-N_{\text{Sa}}/2}}{1+z^{-N_{\text{Sa}}/2}H(z)}e_{PR} (z) \tag{21}\]  
Furthermore, (21) can be organized as  
\[i_{Er}(z)=-z^{-N_{\text{Sa}}/2}i_{Er}(z)H(z)+\left[1+Q(z)z^{-N_{\text{Sa}}/2} \right]e_{PR}(z) \tag{22}\]  
Angular frequency of grid current odd harmonics is  
\[\omega_{odd}=2\pi/\left(N_{\text{Sa}}T_{\text{Sa}}\right)\cdot(2k_{odd}+1), \ \ k_{odd}=1,2,3\ldots \tag{23}\]  
From (23), at the odd harmonics frequencies, \(z^{-N_{\text{Sa}}/2}\) is  
\[z^{-N_{\text{Sa}}/2}=\left(e^{i\omega_{e}T_{\text{Sa}}}\right)^{-N_{\text{Sa} }/2}=e^{-j(2k_{odd}+1)\pi}=-1 \tag{24}\]  
By substituting (24) into (22) and considering that \(Q\) is closed to 1 in the low frequency bands, there is  
\[i_{Er}(z)=-z^{-N_{\text{Sa}}/2}i_{Er}(z)H(z) \tag{25}\]  
According to (25), the update cycle of this proposed controller is \(1/2T_{1}\). As a result, the control error convergence rate is twice that of the standard repetitive controller.  
Last, the zero steady-state error constraint is derived. By substituting (24) into (21), there is  
\[i_{Er}\left(e^{i\omega_{e}T_{\text{Sa}}}\right)=\left[1-Q\left(e^{i\omega_{e} T_{\text{Sa}}}\right)\right]/\left[1-H\left(e^{i\omega_{e}T_{\text{Sa}}} \right)\right]\cdot e_{PR}\left(e^{i\omega_{e}T_{\text{Sa}}}\right) \tag{26}\]  
Figure 11: Block diagram of PR+OMRC.  
Figure 10: Block diagram of proposed grid-current closed-loop control system.  
From (26), the control error of the current odd harmonics is reduced by \(\left|1-Q\left(e^{i\omega_{o}T_{Sa}}\right)\right|/\left|1-H\left(e^{i\omega_{o}T _{Sa}}\right)\right|\) times. Therefore, in order to eliminate the odd harmonic currents, namely, to ensure \(i_{Er}\left(e^{i\omega_{o}T_{Sa}}\right)\to 0\), it is necessary to set \(Q(z)\to 1\), \(H(z)\to 0\).