A Generalized Analytical Tuning Approach for Model Predictive Controlled Grid-Tied Converters Under Wide Range of Grid Inductance Variation

In medium-high power applications, the LCL is the preferred filter topology to attain efficient power conversion. The filter provides a high damping attenuation of -60 dB/decade above the resonance frequency at the cost of a higher order plant, complex parameter design, and, increased vulnerability to un-modeled disturbances. Recently, model predictive control applied to power electronic converters has experienced great interest from researchers. The technique is tailored to the control of complex MIMO systems such as the LCL filter as it allows simultaneous regulation of several state-variables via a user defined cost function. However, the tuning of weighting factors (WFs) within the cost function is not trivial, and in most cases employs an empirical procedure. This paper presents an analytical procedure for tuning of WFs for indirect model predictive current controlled grid-tied converters. The method is based on using analytical closed-form expressions, that relate closed-loop poles of the filter with WFs via physical plant parameters. The presented expressions generalize the tuning of WFs to any arbitrary LCL design. The proposed method is validated by hardware-in-the-loop simulations conducted on PLECS RTBOX 3. Through experimental testing, it is shown that the controller is robust against a wide range of grid impedance variation.


I. INTRODUCTION
Pulse-width-modulated (PWM) power electronic converters are an essential intermediary enabling efficient power flow between renewable energy resources, e.g., solar panels, wind turbines etc. and the main electrical grid [1], [2]. Grid codes such as IEEE-519 dictate the allowable voltage and current harmonic content injected by the converter into the grid at the The associate editor coordinating the review of this manuscript and approving it for publication was Jiefeng Hu . point of common coupling (PCC) [3]. Grid standards are met by proper selection of interlinking passive components such as the inductive (L) filter or an LCL filter. For applications in the kilowatt range, the choice of employing an LCL filter takes preference over a simple L filter as the former allows stronger harmonic attenuation at increased power density, reduced power losses and reduced capital cost [4]. The LCL being a higher third order filter introduces additional control challenges: 1) Simultaneous regulation of grid-side currents, filter capacitor voltages, and converter-side currents; VOLUME 10, 2022 This work is licensed under a Creative Commons Attribution 4.0 License. For more information, see https://creativecommons.org/licenses/by/4.0/ 2) Resonance damping to mitigate harmonic current amplification at resonance frequencies which in worst case could lead to instability [5].
To satisfy the aforementioned objectives, traditionally cascaded control structures designed using linear control principles are employed using voltage oriented control (VOC) schemes [6]. For mass-produced low power systems, resonance damping could then be provided passively through, for example, introduction of a series resistor in filter capacitor branch at the expense of additional filter loss [7]. For high power systems, capacitor current feedback based active damping methods designed to emulate a ''virtual resistance'' have also been widely researched [8], [9], [10]. If full state-feedback information is available, dominant and resonant dynamics of the system can be controlled simultaneously, thus providing inherent active damping to the system [11], [12], [13].
In the past decade, researchers have focused on utilizing model predictive control (MPC) techniques for control of power converters as a result of significant advantages over traditional linear control schemes [14], [15], [16], [17]. By exploiting the ever increasing computational power in commercial DSPs, benefits such as decoupled control of variables, controllability of MIMO systems, and ease of inclusion of soft and hard system constraints make MPC well suited for control of non-linear switched power electronic converters [16], [18]. MPC can be classified into two forms: 1) Direct MPC -also known as finite control set model predictive control (FCSMPC); 2) Indirect MPC -also known as continuous control set model predictive control (CCSMPC). A distinguishing characteristic of direct MPC is the ability to incorporate both the control and modulation into a single stage, i.e., the switching signals are applied to the converter without the use of a modulator [19]. Consequently, the harmonic spectra of converter voltage and current is non-deterministic resulting in a variable switching frequency control. In grid-tied applications this is undesirable because of the following reasons: 1) Variable harmonic spectrum could excite resonance frequencies in higher order filters leading to instability; 2) It complicates the filter design as an overly conservative filter is required to cover the entire switching frequency range. To alleviate the issue of variable switching frequency in direct MPC, researchers in [20] opted to use a band-stop filter to shape the harmonic spectrum of the current controller. Works such as [21], [22] opted to improve upon the voltage resolution of the FCSMPC scheme through the concept of virtual voltage vectors (VVVs). These methods aim to provide a larger pool of candidate voltage vectors (VVs) for evaluation, thus assuring a fixed switching frequency. The performance of these methods depend on the discretization of the available voltage vector space. If the number is too small, the ''coarse'' VVs space will adversely affect the controlled variable. If the number is too high, the computational burden is increased. From a different point of view, researchers have proposed works such as in [23], [24], and [25] that modify conventional direct MPC scheme to permit the application of multiple VVs, thus allowing controller to change switch positions at any time within the sampling period. In addition to the calculation of optimal VVs, MPC computes the time instants for the application of those VVs within the sampling period as well, thus enabling a fixed frequency operation.
Another solution to the aforementioned problem of variable frequency operation is to use indirect MPC, which incorporates control with a dedicated modulation stage (either carrier based PWM or SVM), thus resulting in a fixed harmonic spectrum [26], [27], [28], [29], [30], [31], [32]. Authors in [26] presented a methodology for control of an LCL filter in which the MPC problem is explicitly solved offline. The solution in the form of duty cycles was implemented through a lookup table. Karamanakos et al. in [27], presented a direct MPC scheme for a 2L-VSC with an LCL filter in which the controller imitates the pattern of traditional SVM by forcing each leg of the converter to switch once per sampling period in a specific order. This was achieved by consolidating two optimization steps, namely, optimal switching sequence determination and ''duty cycle'' calculation step into a single stage. It is worth mentioning that system constraints (either on states or output) for protection of the converter were not taken into account in either of the works, while only simulation results were provided for the latter scheme. These issues were addressed by Rossi et al. in [28], where an indirect MPC scheme for control of medium voltage 3L NPC with an LCL filter was presented, taking into account constraints during formulation of the MPC problem. To meet grid standards at PCC with low switching frequencies (< 500 Hz), a longer prediction horizon (N p > 2) was used, which aided in active damping as well as decoupled control of state variables during transient conditions [33].
A major challenge in the adoption of MPC controllers for power electronic applications, is the proper selection of WFs to achieve the desired control objectives. The WFs within a cost function (CF) express the relative importance of one control objective over the other. As such, proper tuning is especially critical in multi-input multi-output (MIMO) applications in which several control objectives (possessing different physical natures, e.g., currents, voltages etc.) require simultaneous regulation. The most trivial procedure is the time consuming trial-and-error approach in which the WFs are tuned heuristically until the desired system response is obtained [18], [34]. One of the earliest advancements in this topic was made by Cortes et al. in [35], in which a branchand-bound algorithm was incorporated to reduce the search time for WF determination. Zancehetta in [36] used multiobjective Genetic Algorithm (MOGA) optimization approach to identify the optimal WFs based on the defined metrics (e.g., supply current THD etc.) for a shunt active power filter. The technique fully automates the tuning of WFs, although it is time-consuming due to the considerable number of simulations required for each design objective. Authors in [37] presented an online WF tuning procedure for predictive torque and flux control of an induction machine (IM).
The approach is based on determining closed-form expressions of torque ripple in terms of controlled variable errors, motor parameters, and weighting factors. Zhang et al. in [38] modified the conventional definition of predictive torque control of IM to control stator flux instead. This led to a reduction in degree of freedom of the controlled variables and thereby eliminated the need to tune multiple WFs. Apart from the MOGA approaches [36], [39], researchers have also leveraged deep learning tools such as artificial neural networks (ANNs) [40], [41], [42], and fuzzy optimization [43] methods. In ANN approaches, first, the converter is tested using a wide range of WFs. Then performance metrics such as current THD or average switching frequency are extracted during each iteration. This data is then used to train ANNs which post-training act as a fast surrogate model to the actual power converter. Finally, a fitness function is defined using performance metrics to back-calculate WFs according to the desired control performance. In literature, ANN-based online [40], [41] and offline tuning approaches have been researched [42]. It is worth mentioning that the majority of aforementioned tuning methods presented aim to optimize some form of performance metrics, and target direct MPC controllers [44]. Furthermore, methods based on training data sets are equally as time-consuming as empirical tuning procedures, because they require multiple iterations to extract required metrics over a wide operating range.
To tackle these issues, this article presents a fast analytical WF tuning procedure for an indirect model predictive controlled converters. The application is of a grid-tied 2L-VSC with an LCL filter widely used as an active front end in renewable energy resources, and motor drives [5], [45]. Indirect controllers such as the one presented by [30] are formulated by deadbeat approach in which a control law can be found by taking the derivative of CF with respect to converter voltage and setting it equal to 0. The resulting control law allows to close the control loop through which desired system response (in the form of closed-loop poles) can be obtained by proper selection of WFs acting as gains, similar to a conventional state-space controller [46]. If direct pole-placement is employed, the closed-loop poles can be placed to obtain system response according to desired control requirements (such as control bandwidth and resonance damping). The gains of the controller in the form of WFs can then be back-calculated as a function of system parameters, and desired closed-loop poles locations using the presented analytical closed-form expressions. As a result, the cumbersome iterative training procedure associated with tuning of direct MPC can be avoided and fast tuning can be accomplished either online or offline.
The article is organized as follows 1 : The continuous-time and discrete-time model of the LCL filter is presented in Section II. In Section III, the hybrid voltage and current indirect predictive controller is discussed. In Section IV, the analytical closed-form expression of WFs as a function of closed-loop system poles and system parameters are presented. In Section V, hardware-in-the-loop (HIL) simulation results are presented to verify the validity of the closed-form expression. Finally, Section VI concludes the findings in this paper.

II. SYSTEM MODELING
The control scheme of a 2L-VSC with an output LCL filter tied to a 3φ grid is shown in Fig. 1. In natural abc frame, the converter-side currents, filter capacitor voltages, gridside currents and grid voltages at the point of common coupling (PCC) are denoted by i c,abc , v f,abc , i g,abc , and v g,abc , respectively. The latter two variables are measured for control purposes. The control is performed in orthogonal αβ frame, in which the complex space vectors are indicated with boldface symbols with an overhead bar (e.g., the converter-side currentī c = i cα +ji cβ ). Additionally, matrices incorporating complex space vectors are indicated with bold symbols (e.g., the continuous-time state space vector x c ). The grid angle information θ g , and the grid frequency ω g required for grid synchronization is extracted via a PLL using the grid voltages v g,abc [48].

A. CONTINUOUS-TIME MODELING
In this section, the continuous-time state space model of the system is derived via differential equations of the LCL filter. The converter-side currentī c , filter capacitor voltagev f and the grid-side currentī g are chosen as the state variables. Note that for simplification of closed-form expressions, the resistance of the filter components are not taken into account, which also describes the worst-case condition in terms of resonance damping. The continuous-time state space equations describing the dynamics of the filter are, The variable L fc is the converter-side filter inductance, C f is the filter capacitance, L fg is the grid-side filter inductance, and L g denotes the variable grid inductance, respectively. Note that during the continuous-time modeling, a stiff grid is assumed (L g = 0).

B. DISCRETE-TIME MODELING
Now, the discrete-time model of the LCL filter is developed using the exact discretization approach. The sampling of the grid-side currents, and grid voltages is synchronized with the VOLUME 10, 2022 switching of the converter, i.e., the sampling frequency f s equals the switching frequency f sw . The filter parameters, grid voltage, and the converter voltagev c (t) is assumed to be held constant within the sampling interval T s = 1/f s . Under these assumptions the discrete-time model of the system is given as, where k is the discrete-time index and The definition of discrete-time system matrices are given as,

III. MULTIOBJECTIVE MODEL PREDICTIVE CONTROLLER
Higher order filters such as the LCL filter are inherently prone to resonance, as a result of coupling dynamics among filter components. The current harmonics at the resonance frequency could be excited, e.g., by step changes in current references and/or external disturbances, which in extreme cases could result in instability. It has been shown that model predictive controllers can inherently provide active damping to the system if the following conditions are satisfied: 1) Full state-feedback information is available through either measurements or observer; 2) Proper selection of weighting factors; 3) A large enough prediction horizon [33].

A. COST FUNCTION DEFINITION
The primary control objective is reference tracking of grid currentī g , which directly translates to a higher level control objective of regulating active/reactive power absorbed or delivered to the grid. The CF component that quadratically penalizes the error between reference and measured system output can be considered as, where w ig is the weighting factor associated with the tracking ofī g . To ensure stability, the CF allows capacitor voltages and converter-side currents to be tracked as well. Their respective CFs components are given as, where w v f and w ic are the WFs associated with tracking of v f andī c respectively. The WFs penalize the tracking error of the controlled variables. Equations (6), (7) and (8) can be combined as, is a positive semi-definite matrix containing WFs as its diagonal entries.

B. CONTROL LAW GENERATION
An indirect deadbeat MPC controller can be formulated by substituting (3) in (9) and taking the derivative of (9) with respect tov c and setting it equal to 0. The unconstrained control law is given as, (10) If the maximum permissible voltage limit generated by the modulator is given by V lim , the unconstrained control law given above can be scaled as,

C. DELAY COMPENSATION
The computational delay inherent to the controller can be compensated by extrapolating the references, and controlled variables one step ahead in time [49]. Under this premise, the CF and control law is modified to following, According to (4), since the only measured state-variables is the grid-side currentī g (k ), using a full order observer will provide the information of the remaining controlled variables while also predicting the state vectorx d (k + 1). Information regarding the tuning of observer gains can be found in [30].

D. REFERENCE GENERATION
The references for grid current can be determined from the active and reactive power references as, where P * and Q * are the desired active and reactive power references. In a typical active front end (AFE) application, Q * = 0 to achieve unity power factor. The references forv f (k ) andī c (k ) can be obtained from the model of the LCL filter as,v * The computational delay inherent to the controller can easily be compensated using two-step ahead extrapolation as, where N p is the required prediction horizon. For two-step ahead predictions, N p = 2.

E. CLOSED-LOOP STATE SPACE FORMULATION
The closed-loop dynamics of the system can be evaluated by replacing (10) in (3), (15) and (16) in terms ofī * g .

IV. WEIGHTING FACTOR CALCULATION BY DIRECT POLE-PLACEMENT APPROACH
Assuming the grid disturbancev g (k ) = 0, the transfer function from reference grid currentī * g (k ) to measured grid currentī g (k ) can be obtained from (18) as, The closed-loop poles of system that determine the system stability, and transient response are obtained from the characteristic polynomial of the aforementioned equations as, Let the desired closed-loop characteristic polynomial be, where β i (i = 1, 2, 3) are the desired closed-loop pole locations in z -domain. The coefficients as function of pole locations are given as, Now, the analytical expressions of WFs in terms of discrete-time plant parameters and desired pole locations β i will be derived by expanding (23) as, where the coefficients are, Equating (26a)-(26c) with (28a)-(28b) respectively we obtain, where the coefficients are,  Equations (34a)-(34c) form a system of three linear equations which can be written in matrix form as,

A. GUIDELINES FOR POLE-PLACEMENT
Direct pole-placement approach grants the designer freedom to place the poles arbitrarily in the z -domain. However, following the presented guidelines will ensure that the control effort is within the acceptable limits. It is typical to first define the desired pole locations in the continuous-time domain and then map them to discrete-time domain via the transformation z = e sT s . To that end, the polynomials defining the delay and resonant dynamics of the system are given in continuous-time domain as, In order to ease the calculations and remove one degree of freedom from the problem at hand, either the WF associated with regulation of converter-side current (w ic ) or WF associated with regulation of grid-side current (w ig ) can be set to 1. Under this condition, the delay pole in discrete-time domain (β 1 ) is mapped to the origin or 0. The magnitude of resonance damping is dependent on damping ratio ζ r , while the frequency of resonant poles is set by ω r . The natural frequency ω r should be kept between 2πf s /10 -2π f s /5. Higher bandwidths will result in the controller being more susceptible to measurement noise and external disturbances. The damping ratio is set between ζ r = 0.707,..,1, in order to provide large enough damping to avoid resonance. The discrete-time pole locations are then given by, Once the pole locations have been specified in discrete-time domain, the WFs can be determined by modifying (38) to one of the following two forms depending on if whether w ic or w ig is set to 1 as, A flowchart to determine the optimal WFs for either of the aforementioned cases is shown in Fig. 2. It is to be noted that the choice of setting either w ic or w ig to 1 is entirely user dependent. Two sets of WFs obtained by either (41b) or (42b), result in the identical control performance for a given value of ω r and ζ r .

B. EVOLUTION OF WEIGHTING FACTORS AGAINST RESONANT BANDWIDTH
This section examines the variation of WFs against the resonant bandwidth ω r of the controller. The parameters of the LCL plant used to calculate the WFs are listed in Table 1. The resonant bandwidth ω r is varied from 0 to f s /2 (Nyquist limit), for four values of damping ratios ζ r = [0.7,0.8, 0.9, 1]. The WFs can be calculated according to two cases as mentioned in the prior subsection. For Case I, w ig is set to 1, the variation  of remaining two WFs (w ic , w v f ) for four damping ratios are shown in Fig. 3. It can be seen that, for bandwidths below the resonance frequency (ω p ) of the LCL filter, both w ic and w v f have negative values and become increasingly negative as the bandwidth approaches ω p . Conversely, for bandwidths higher than the resonance frequency of filter, these WFs attain positive values. A magnitude reversal of WFs from negative to positive can be seen around the vicinity of ω p , which can be attributed to resonance phenomenon of LCL filter. Next, we consider Case II in which w ic = 1. The variation of remaining two WFs (w v f , w ig ) against ω r for four damping ratios are shown in Fig. 4. For ω r below ω p , w ig is negative for all values of ζ r , while w v f remains positive. For ω r higher than ω p , w ig is positive and increases as controller bandwidth approaches the upper maximum limit of f s /2 as dictated by the Nyquist criteria. It can be seen that it is preferable to use Case II, since the WFs exhibit a logarithmic increase with ω r , and do not suffer from the phenomenon of magnitude reversal as in Case I.

C. EVOLUTION OF WEIGHTING FACTORS AGAINST SAMPLING TIME
The evolution of WFs with the controller bandwidth is dependent on the sampling time T s as well. Only Case II VOLUME 10, 2022  (w ic = 1), is considered since the variation of WFs with ω r is more prominent than Case I. In the first analysis, the sampling frequency is decreased from its rated value to half the rated value (f s = 5 kHz), the results for which are shown in Fig. 5. It can be seen that compared to Fig. 4, envelope of evolution for both w v f and w ig remains unchanged, while the magnitude of WFs is decreased. Next, the sampling frequency is increased to f s = 15 kHz from the rated value of f s = 10 kHz, the results for which are shown in Fig. 6. Similar to the first case, the envelope of evolution remains the same, however, the magnitude of the WFs is now increased. Note that the Nyquist limit of controller bandwidth being dependent on the sampling time, is varied both in Fig. 5 and Fig. 6.

V. HARDWARE IN THE LOOP VALIDATION
In order to verify the validity of the closed-form expressions, HIL simulations are conducted by deploying the plant model (consisting of 2L-VSC, LCL filter and the 3φ electrical grid) on PLECS RTBOX 3 with a discretization step size of T P s = 6 µs, while the controller is implemented on TI TMS320F28379D DSP (Clock frequency: 200 MHz) with a T s = 100 µs as shown in Fig. 7. A 1 GHz/6.25 GS/s Tektronix MSO58 oscilloscope is used to measure experimental waveforms from the RTBOX 3 with Tektronix 1 GHz  TPP1000 voltage probes. The LCL filter parameters are listed in Table 1, with the bode plot for open loop response of the LCL filter shown in Fig. 8. A resonance peak can be observed at the filter resonance frequency ω p . The open loop poles of the LCL filter in z -domain are shown in blue in Fig. 9. In order to test the efficacy of the current controller individually, the dc-link is modeled as a stiff voltage source. The control parameters used to tune the observer gains are listed in Table 2.

A. STEADY-STATE RESULTS
To test the steady-state performance of the controller under rated load conditions, initially the WFs are calculated by trial and error approach. In order to achieve unity power factor operation, the references for reactive power transfer is set to 0 (Q * = 0). According to Case I defined in Section IV-A, the WF to regulate the grid-side current is set to 1. The selected WFs W 1 = diag[0.09, 0.002, 1] lead to a bandwidth of ω r = 2π1485 rad/s (24.7 p.u.) with a non-ideal damping ratio of ζ r = 0.6. The poles obtained from selection of these WF are shown in black in Fig. 9. The steady-state simulation results obtained by the selection of these WFs are shown in Fig. 10. The figure shows in natural (abc) frame the grid voltages, grid-side currents, active and reactive power delivered to the grid. The THD of the grid-side currents is 1.5% at rated power. It can be seen that the grid currents are in phase in with grid voltages leading to unity power factor operation.
The placement of the closed-loop poles can be optimized by moving the poles towards region of increased damping. The bandwidth of the resonant pole pair is kept unchanged at ω r = 2π1485 rad/s, while the damping ratio is now set to ζ r = 1. If Case I is considered, the WFs can be calculated according to the procedure presented in Fig. 2. The optimal WFs are found to be W opt = diag[0.13438, 0.00420, 1]. Since, the effect of increased damping ratio will be visible during the transient conditions, the steady-state results of the system will remain unchanged, and look identical to Fig. 10. The poles obtained from selection of W opt are shown in red with a double pole pair on the real-axis in Fig. 9. It is intuitive to understand that a resonant double pole pair on the real axis should provide increased damping, and consequently, increased stability of the control loop. It can also be seen that, it is not straightforward to arrive at W opt via trial and error procedure. Additionally, W opt being a function of plant parameters, will vary from one LCL design to another. Since the plant parameter tend to change over time due to, e.g., ageing and degradation, W opt will require re-tuning in order to maintain the desired closed-loop response. It is evident that using the presented closed-form expressions and guidelines, desired closed-loop response can be obtained independent of the LCL design, and variation in plant parameters.

B. TRANSIENT RESULTS
In this section, the dynamic behavior of the controller is analyzed using non-optimal W 1 and W opt . Initially, W opt are used and a step in P * is applied from 0.5 p.u. to 1 p.u. at time t = 0 s, as shown in Fig. 11. The plot on the top shows the measured grid voltages in abc frame, grid-side currents in abc frame, along with instantaneous active and reactive powers at the bottom.
In order to compare the differences in transient performance using non-optimal W 1 and optimal W opt WFs, HIL simulations are conducted considering four different scenarios: 1) Step in P * from 0.5 p.u. to 1 p.u. with Q * = 0; 2) Step in P * from 1 p.u. to 0.5 p.u. with Q * = 0; 3) Step in Q * from 0.5 p.u. to 1 p.u. with P * = 0; 4) Step in Q * from 1 p.u. to 0.5 p.u. with P * = 0. The results for four cases under consideration are shown in Fig. 12, with P /Q resulting from W 1 shown in red, and P /Q determined from W opt shown in black. It can be seen that for all cases, the bandwidth of the step response remains unchanged, regardless if W 1 or W opt is used. However, the oscillations in active and reactive powers during the transients are clearly more damped in the case where WFs were calculated using ζ r = 1 or W opt , thus, proving the efficacy of the proposed method. Since, the FIGURE 12. Transient performance comparison of optimal W opt against non optimal W 1 under four scenarios: (a) Step in P * from 0.5 p.u. to 1 p.u. with Q * = 0; (b) Step in P * from 1 p.u. to 0.5 p.u. with Q * = 0; (c) Step in Q * from 0.5 p.u. to 1 p.u. with P * = 0; (d) Step in Q * from 1 p.u. to 0.5 p.u. with P * = 0.
presented approach limits the overvoltages and/or overcurrents during transients, hardware damage to the components can be avoided (limited), thus, increasing the lifetime of the system.

C. PERFORMANCE UNDER GRID INDUCTANCE VARIATION
Stability and performance of grid-connected converters interfaced via an LCL filter is subject to degradation under weak grid condition and background harmonics [50]. A sliding discrete Fourier transform (SDFT) approach was proposed in [30], to mitigate the effects of distorted and unbalanced grid conditions, however, the effect of external grid inductance variation was not studied. In this section, the performance of the predictive controller is evaluated under the influence of varying grid impedance as shown in Fig 13. Assuming a purely stiff grid (L g = 0), the controller is tuned using W opt . Steady-state results at rated active power (in AFE mode) for the grid-side currents under stiff (L g = 100 µH), and weak grid (L g = 3.2 mH) conditions are shown in Fig. 13a and Fig. 13b, respectively. Additionally, the FFT analysis conducted on aforementioned waveforms is shown in Fig. 13c. It can be seen that even under severely weak grid conditions, the controller maintains stability, at the cost of increased current THD. Additionally, Table 3 exhibits the grid current THD for a range of L g values. It can be seen that for a wide range of L g variation, grid-side currents THD remain within the acceptable limits.
The root loci plots of the closed-loop system under the aforementioned grid impedance variation values are shown in Fig. 14. Fig. 14a is obtained using W 1 (non-optimal WFs), while Fig. 14b exhibits root loci obtained using W opt (optimal WFs). The poles resulting from using L g = 100 µH are shown in blue, while the poles obtained from using L g = 3.2 mH are shown in orange. The movement of the poles as a result of L g variation are indicated with arrows. From  Fig. 14a it can be seen that as L g is increased, the resonant poles move towards the real axis indicating increased damping of the closed-loop system. Comparatively in Fig. 14b,  FIGURE 14. (a) Root locus plot using non-optimal W 1 . Poles shown in blue are resulting from L g = 100 µH, while the poles in orange are resultant of using L g = 3.2 mH. (b) Root locus plot using optimal W opt . Poles shown in blue are resulting from L g = 100 µH, while the poles in orange are resultant of using L g = 3.2 mH. The trajectory of poles as L g is varied is indicated with arrows. Zeros lying outside of unit circle on negative real axis are not shown.
the resonant poles are already well damped, lying on the real axis. However, due to grid-side inductance mismatch, a double pole pair is no longer formed, and the poles are seen split apart on the real axis. As L g is increased, the resonant pole pair move further away from each other while keeping the maximum damping ratio ζ r of 1. The root loci plots confirm the aforementioned steady-state results that as L g is TABLE 3. Grid current THD variation against L g . varied, the system remains stable, however the steady-state performance suffers from an increased THD.
In the aforementioned analysis, the continuous-time modeling of the filter is performed by assuming a purely stiff grid or equivalently L g = 0. This represents the worst case condition in terms of WF determination as the grid inductance is assumed unknown. Even under this scenario, the controller exhibits strong robustness to grid mismatch as the THD of the grid-side currents remain within acceptable limits (< 2%) up until L g = 2.4 mH as shown in Table 3. If L g is estimated via an embedded estimation algorithm such as the one presented in [51], the grid-side inductance can be modified to include the effect of estimated inductance as L ′ fg = L fg +L g wherê L g is the estimated grid inductance. AssumingL g = 1 mH, the modified grid-side inductance L ′ fg = 3.3 mH is used to recalculate the WFs considering ω r = 2π1485 rad/s and ζ r = 1 using Case I resulting in W * = diag[0.04138, 0.00129, 1]. The controller uses modified grid-side inductance L ′ fg for reference generation and observer implementation as well. The following cases can be formulated: 1) Case 1: Plant grid inductance is equal to estimated controller grid inductance, i.e., L g = 1 mH; 2) Case 2: Plant grid inductance is 50% less than its nominal value, i.e., L g = 0.5 mH; 3) Case 3: Plant grid inductance is 50% more than its nominal value, i.e., L g = 1.5 mH; 4) Case 4: The WFs are modified back to W opt thus neglecting the effect of external grid inductance whereas the plant grid inductance is set equal to 1 mH. HIL simulations are conducted by applying a step change in power reference from P * = 0.5 p.u. to 1 p.u. for the aforementioned cases, the results for which are shown in Fig. 15. Additionally, the THD of the grid-side currents are measured in steady-state at rated power reference (in AFE mode) which are shown in Table 4.
The following statements can be inferred from these results: First, variation in L g has an negligible impact on the transient performance of the controller as shown in Fig. 15. Second, comparison of cases 1-3 in Table 4 indicates that the variation in external grid inductance from its nominal value of L g = 1 mH does not significantly impact the grid-side current THD indicating robustness. Third, in case 4 where the external grid inductance is not incorporated in the controller, the THD of the grid-side currents is increased in comparison to cases 1-3.

D. PERFORMANCE UNDER VARIATION IN RESONANT BANDWIDTH
To test the effects of variation in resonant bandwidth, HIL simulations were performed by tuning the WFs with four VOLUME 10, 2022 TABLE 4. Grid current THD variation against L g for various cases discussed in Section V-C.

FIGURE 15.
Transient performance under step change in active power from P * = 0.5 p.u. to P * = 1 p.u. for cases discussed in Section V-C. different values of ω r = 2πf s [1/5, 1/10, 1/15, 1/20] assuming ζ r = 1 for all cases. During re-tuning of the controller, the bandwidth of the observer was held constant at ω or = 2 × 2πf s /5 and ζ or = 0.707. Performance of the controller was evaluated under both the steady-state and transient conditions. From the steady-state tests conducted at rated test conditions, it is found that the THD of the grid-side current increases as the resonant bandwidth is decreased as shown in Fig. 16. It is evident that THD is minimized if the resonant bandwidth is kept between ω r = 2πf s /10 -2πf s /5, therefore, providing guidelines for tuning of this controller.
In order to check the transient performance under varying ω r , a step change in active power is applied from P * = 0.5 p.u. to P * = 1 p.u., the results for which are shown in Fig. 17. Two observations can be made from the results: 1) As indicated in earlier, a decrease in resonant bandwidth leads to increased harmonics in the grid-side currents. Despite the fact, no overshoot can be seen during the step change when the controller is tuned with ω r = 2πf s [1/15, 1/20] because the gains were calculated using maximum damping ratio of ζ r = 1, indicating the usefulness of the presented closedform expressions; 2) As it can be seen in Fig. 17, variation in resonant bandwidth does not significantly effect the control  bandwidth of the controller itself, primarily because the control law is generated by deadbeat approach, thus, leading to a fixed maximum permissible bandwidth.

E. PERFORMANCE UNDER WEIGHTING FACTORS MISMATCH
This section evaluates the effects of weighting factor mismatch in the controller. Optimal WFs W opt calculated in subsection V-A are used as a benchmark. The WFs are increased and decreased by 20 % from the optimal values thus providing the over-estimated case of W 2 = diag[0.16125, 0.00504, 1] and under-estimated case of W 3 = diag[0.10750, 0.00336, 1]. The transient results for step change in active power reference from 0.5 p.u. to 1 p.u. are shown in Fig. 18 for all the aforementioned cases. The figure depicts i gα , i gβ along with the instantaneous active power delivered to the grid. It can be seen that mismatch in the WFs has a negligible effect on the steady-state performance of the controller. However, the transient performance is slightly affected as the non-optimal placement of closed-loop poles can impact the damping of the closed-loop system.

VI. CONCLUSION
This paper has presented a fast analytical procedure to determine WFs for continuous control set model predictive controlled grid-tied VSC with an LCL filter. Compared to existing weighting factor tuning techniques in literature, the presented approach does not require time consuming iterative simulations to extract performance metrics of the system, and generalizes the tuning procedure to any LCL design. The method is based on model based pole-placement that relate the WFs of the cost function to closed-loop system poles via LCL plant parameters through analytical closed-form expressions. The technique can thus provide automatic tuning (real time gain adaptation) of WFs, if plant parameters are known or estimated. The presented method is verified through hardware-in-the-loop simulations by deploying the plant on RTBOX 3, and the controller on TMS320F28379D DSP. If the controller is tuned according to the presented guidelines, better resonance damping is achieved during dynamic conditions, as overcurrent/overvoltages transients are well damped, leading to increased reliability of the components. Experimental results also show that the controller is robust against wide range of grid impedance variation.

ACKNOWLEDGMENT
The views and opinions of authors expressed herein do not necessarily state or reflect those of the U.S. Government or any agency thereof. He is currently a Principal Power Electronics Architect & Research Manager at SmartD Technologies, Montreal, QC, Canada. He has more than ten years professional experience in modeling, design, and implementation of power electronic converters with more than 20 successfully implemented industrial and research projects in the field on industrial electronics for various applications, such as EV fast battery charging systems, variable frequency motor drive systems, aircrafts, and integration of renewable energy conversion systems to grid. He has been a principal investigator (PI) and a co-PI of various industrial and research grants in the field of industrial electronics. He has authored or coauthored over 50 journals and conference papers and book chapters, and he holds four granted or pending U.S. patents. His professional experiences and current research interests include high-power density and high-efficiency wide-band-gap (WBG)-based converters, proposing new architecture of multilevel converters, advanced modulation and control of power electronic converters, PCB layout optimization and optimization of WBG-based converters, and EMI reduction techniques for power electronics converters, including passive and active methods. Since 1990, he has been a Professor with the Electrical Engineering Department, École de Technologie supérieure (ÉTS), Montreal, QC, where he has been the holder of the Senior Canada Research Chair in Electric Energy Conversion and Power Electronics, since 2002. He has supervised more than 180 Ph.D. and M.Sc.A. students working in the field of power electronics. He is a consultant and has established very solid link with many Canadian industries working in the field of power electronics, electric transportation, aeronautics, and telecommunications. He has coauthored more than 600 transactions and conference papers. His research interests include high-efficient static power converters, harmonics and reactive power control using hybrid filters, switch mode, resonant and multilevel converters, including the modeling, control, and development of prototypes for various industrial applications in electric traction, renewable energy, power supplies for drives, and telecommunication. Dr