Pulse Pattern Optimization Based on Brute Force Method for Medium-Voltage Three-Level NPC Converter with Active Front End

Nowadays, regulation standards regarding the injection of harmonics in the grid power supply are becoming stricter. These standards have a direct impact on the design and control of converters, especially in medium-voltage drives. To fulfil these standards, converters are designed to work with the power factor as close to unity as possible and to correct the harmonics spectrum in case of a grid power supply with multiple resonances. The preferred modulation technique for medium-voltage drives is usually selective harmonic elimination pulse width modulation. This approach requires a precise calculation of pulse patterns (switching angle vs. modulation index) with additional constraints. This research presents a new approach for the determination of optimal pulse patterns. The technique ensures the elimination of low-order harmonics and minimization of some high-order ones. The proposed technique incorporates the additional constraints regarding minimum on/off switching time (pulse duration) and ensures the continuity of pulse patterns. Optimal pulse patterns are determined with the brute force method which searches the feasible solution space by use of the Jacobian matrix null space. Determined pulse patterns are verified by the simulation and experimental measurements.


Introduction
Medium-voltage drives are used in various industrial applications such as wind power generation [1,2], traction supply systems [3,4] and in the metal industry where control of high-power machinery is needed in four-quadrant drive operation [5,6]. The leading idea in designing medium-voltage drives is the reduction in losses and grid interaction. This interaction of medium-voltage drives with the grid power supply can be reduced by adding a passive filter as in [6,7], but this approach increases the overall system cost and can produce additional losses as stated in [8]. Another approach is to deploy a hybrid front end which consists of the shunt Y-∆ transformer and an active filter as in [9]. By doing so, voltage drive reduces grid interaction by reducing the 5th, the 7th, the 11th and the 13th harmonics but increases the system complexity and size, especially in medium-voltage drives. As proposed in [10], for medium-voltage drives, often a three-level neutral point clamped converter with an active front end (3 LV NPC AFE) is used. The drawback of the 3 LV NPC AFE converter is that it suffers from high switching losses when operating with sinusoidal or space vector pulse width modulation (PWM), but these problems can be resolved by deploying fundamental switching frequency PWM, e.g., selective harmonic elimination (SHE-PWM) [10][11][12].
SHE-PWM is based on the determination of optimal pulse patterns which will provide the desired first harmonic, and elimination (or suppression) of selected low-order harmonics. The determination of Depending on the number of switching states (switching angles) in the first quarter of the fundamental harmonic period and considering the π/2 symmetry, the generalized expression of phase to neutral voltage for the first phase (phase a) can be written as where is the n-th harmonic component, is the DC link voltage and is the k-th switching angle. Based on Equation (2), the general problem to determine the required switching angles for achieving the desired first harmonic ( ) and for elimination of the selected low-order harmonic ( ) can be stated as where H is the highest harmonic order which will be eliminated, defined as and m is the modulation index defined as The system of nonlinear equations that describes the problem of the SHE-PWM modulation technique is stated as which are obtained based on Figure 1 and Equation (3). The solution of Equation (6) with additional constraints defined in Equation (7) will provide the desired first harmonic (to only be dependent on the modulation index (m) and the DC link voltage) and elimination of low-order harmonics. Depending on the number of switching states (switching angles) in the first quarter of the fundamental harmonic period and considering the π/2 symmetry, the generalized expression of phase to neutral voltage for the first phase V a0 (phase a) can be written as V a0 = ∞ n = 1,3,5,...

System Design and Problem Statement
where V n is the n-th harmonic component, V dc is the DC link voltage and θ k is the k-th switching angle. Based on Equation (2), the general problem to determine the required switching angles θ k for achieving the desired first harmonic (V 1 ) and for elimination of the selected low-order harmonic (V n ) can be stated as cos(θ 1 ) − cos(θ 2 ) + cos(θ 3 ) − . . . + cos(θ N ) − m π 4 cos(5θ 1 ) − cos(5θ 2 ) + cos(5θ 3 ) − . . . + cos(5θ N ) cos(7θ 1 ) − cos(7θ 2 ) + cos(7θ 3 ) − . . . + cos(7θ N ) . . . cos(Hθ 1 ) − cos(Hθ 2 ) + cos(Hθ 3 ) − . . . + cos(Hθ N ) where H is the highest harmonic order which will be eliminated, defined as and m is the modulation index defined as The system of nonlinear equations that describes the problem of the SHE-PWM modulation technique is stated as Electronics 2020, 9, 1685 4 of 20 which are obtained based on Figure 1 and Equation (3). The solution of Equation (6) with additional constraints defined in Equation (7) will provide the desired first harmonic (to only be dependent on the modulation index (m) and the DC link voltage) and elimination of low-order harmonics.

System Design and Problem Statement
The designed system is presented in Figure 2. The system consists of a three-level three-phase active front end connected to the three-phase voltage source, where RL is a model of a grid and step-down transformer impedance, C is the DC link capacitors and i load is the DC link current (load current). The active front end is based on five switching states in the first quarter of the fundamental harmonic period.
Electronics 2020, 9, x FOR PEER REVIEW 4 of 20 The designed system is presented in Figure 2. The system consists of a three-level three-phase active front end connected to the three-phase voltage source, where RL is a model of a grid and stepdown transformer impedance, C is the DC link capacitors and is the DC link current (load current). The active front end is based on five switching states in the first quarter of the fundamental harmonic period. The desired system requirements from Figure 2 are stated as complete elimination of the 5th and the 7th harmonics, with minimization of the 29th, the 31st, the 35th and the 37th harmonics. An additional constraint is that the difference between the two switching angles for a given modulation index (m) is large enough to obey the minimum on/off switching time. These requirements can be expressed as an optimization problem as  (7 ) − cos(7 ) + cos(7 ) − cos(7 ) + cos(7 ) = 0

Algorithm for the Brute Force Method
The BF search method is explained and demonstrated in this chapter on a particular example of a system described in Figure 2. However, this does not exclude the application of the proposed method to other systems or different constraints on higher-order harmonics contents. With elimination of only the 5th and the 7th harmonics, an additional degree of freedom is created for minimization of the 29th, the 31st, the 35th and the 37th harmonics which are defined with the norm. The problem of elimination of the 5th and the 7th harmonics has an infinite number of solutions (for the given modulation index (m)), wherein each of these solutions gives the desired first harmonic and elimination of the 5th and the 7th, but has a different L1 norm of the 29th, the 31st, the 35th and the 37th harmonics. The desired system requirements from Figure 2 are stated as complete elimination of the 5th and the 7th harmonics, with minimization of the 29th, the 31st, the 35th and the 37th harmonics. An additional constraint is that the difference between the two switching angles for a given modulation index (m) is large enough to obey the minimum on/off switching time. These requirements can be expressed as an optimization problem as

Algorithm for the Brute Force Method
The BF search method is explained and demonstrated in this chapter on a particular example of a system described in Figure 2. However, this does not exclude the application of the proposed method to other systems or different constraints on higher-order harmonics contents. With elimination of only the 5th and the 7th harmonics, an additional degree of freedom is created for minimization of the 29th, the 31st, the 35th and the 37th harmonics which are defined with the L 1 norm. The problem of elimination of the 5th and the 7th harmonics has an infinite number of solutions (for the given modulation index (m)), wherein each of these solutions gives the desired first harmonic and elimination of the 5th and the 7th, but has a different L1 norm of the 29th, the 31st, the 35th and the 37th harmonics.
The method starts by finding as many possible solutions for the given modulation index (m), where each of these solutions will give the desired first harmonic and elimination of the 5th and the 7th. These solutions are obtained by solving cos(θ 1 ) − cos(θ 2 ) + cos(θ 3 ) − cos(θ 4 ) + cos(θ 5 ) − m π 4 = 0 cos(5θ 1 ) − cos(5θ 2 ) + cos(5θ 3 ) − cos(5θ 4 ) + cos(5θ 5 ) = 0 cos(7θ 1 ) − cos(7θ 2 ) + cos(7θ 3 ) − cos(7θ 4 ) + cos(7θ 5 with the NR method by changing the initial solutions. When a sufficient number of solutions is acquired, the solution that has the lowest L1 norm of a higher-order harmonic (the 29th, the 31st, the 35th and the 37th) which obeys the minimum on/off switching time is chosen (feasible solution). This chosen solution represents the starting point for the BF method, and it is a five-dimensional vector described in general form as where index i represents the i-th solution of the BF method. The system of equations defined with Equation (9) can be written as cos(5θ 1 ) − cos(5θ 2 ) + cos(5θ 3 ) − cos(5θ 4 ) + cos(5θ 5 ) cos(7θ 1 ) − cos(7θ 2 ) + cos(7θ 3 ) − cos(7θ 4 ) + cos(7θ 5 ) where C(θ) is the vector valued function. The solution for the given modulation index (m) should satisfy the vector valued function in the Equation (11) as The basic concept of the BF method is to search the feasible solution space around the solution θ i in order to obtain the set of solutions (firing angles), where each of the obtained solutions will satisfy the vector valued function defined with Equation (12). The search of a feasible solution space around the solution θ i is done by linearization of the vector valued function defined in Equation (11) by developing it in Taylor series up to the first order as where δθ is a vector of small change in the vicinity of solution θ i and J(θ i ) is a Jacobian matrix of the vector valued function C(θ i ) in the i-th solution defined as Vector δθ which represents the small change in the five-dimensional space around solution θ i is defined as δθ = δθ 1 δθ 2 δθ 3 δθ 4 δθ 5 Electronics 2020, 9,1685 6 of 20 Linear approximation of the vector valued function C(θ i ) defined with Equation (13) is only accurate in the vicinity of solution θ i . To ensure that linear approximation remains accurate, the direction of small change needs to be calculated in such a way that the value of the first harmonic maintains the desired value, and that the fifth and the seventh harmonics remain eliminated. From a theoretical point of view, this can be expressed as Therefore, in order to determine the direction in which the linear approximation will be sufficiently accurate, it is necessary to solve the homogeneous linear system of equations described with Equation (16) for the unknown vector δθ, where δθ should be a non-zero vector. Clearly, solving this homogeneous linear system of equations described with Equation (16) results in a vector (or vectors) which defines the direction where the method can search without disturbing the desired first harmonic or elimination of the fifth and the seventh harmonics. This statement can be expressed as The homogeneous linear system of equations described with Equation (16) cannot be solved by inverting the Jacobian matrix, because it is not a square one. Further, solving this problem by determining the pseudo inverse of the system is not desirable, because this approach would result in only one solution. The answer to this problem lies in searching the null space of the Jacobian matrix as The term N(θ i ) in Equation (18) denotes a matrix whose columns are vectors that span the null space (solution space) of the Jacobian matrix. Since the Jacobian matrix has five columns and three rows, it follows that the null space matrix will have two columns. These two columns are two vectors that describe the null space of the Jacobian matrix. The null space matrix is defined as where v 1 (θ i ) and v 2 (θ i ) are vectors of the null space matrix, whose any linear combination will satisfy Equation (16) as where α and β are real value numbers which define the direction of the search. The search direction where the first harmonic will maintain the desired value, and the fifth and the seventh harmonics will be eliminated is now defined with only two vectors, v 1 (θ i ) and v 2 (θ i ). Vector δθ, which represents the small change, can now be defined as and a new solution, or more precisely a new point in the five-dimensional space, can be defined as Movement to the new point in the feasible solution space causes a certain error because of the linear function approximation of C(θ i ). This new point described with Equation (22) now applies Cleary, the smaller the value of α and β, the smaller the error will be at the end. For this reason, error compensation is added to reduce the error caused by linear approximation. Movement to the new point with error compensation is defined as where δθ c is a vector for error compensation. The calculation of error compensation vector δθ c is based on the linear approximation of vector valued function C(θ) at point θ i+1 as which assumes that the error compensation vector δθ c is sufficiently small. Error compensation vector δθ c is calculated by equalizing the right side of Equation (25) with the zero vector as The problem described with Equation (26) has no unique solution, since the Jacobian is not a square matrix and has no inverse. Furthermore, Equation (26) has an infinite number of solutions where some of these solutions could bring the method back to the starting point. The problem stated with Equation (26) is solved using a pseudo inverse of the system, which will provide the solution (vector) with the smallest possible length. The pseudo inverse of the system defined with Equation (26) is given as With the calculation of the error compensation vector δθ c , the method can now determine the new point of the solution according to Equation (24). By doing this, the method moves from the starting point θ i to a new point θ i+1 without disturbing the desired first harmonic or elimination of the fifth and the seventh harmonics. Since the movement from one point to another is small enough, the constraints on the minimum on/off switching time are obeyed.

Search Direction of the Brute Force Method
Section 3.1 described the basic concept of the devised BF, i.e., described how the method moves from one feasible solution point to another. The BF method is a global optimization method. Therefore, it requires additional information in which the direction it should go to satisfies the defined constraints. The direction of the search is determined by the solution of Equation (12), which represents a starting point for the BF method in five-dimensional space, from where the method starts to move in radial directions. These initial directions from the starting point are described as where ϕ represents the angle uniformly distributed in the interval from 0 to 2π. The cos(ϕ) and sin(ϕ) in Equation (28) are now actually α and β from Equation (20) and they define the radial search direction. The proposed algorithm after finding the solution points in radial directions from the starting point goes further from each of the radially distributed points. This radial search is presented in simplified form in Figure 3 (in this example, in reality, it should be represented by a five-dimensional figure), where θ 0 represents the starting point for the BF method for the given modulation index (m).  The general expression for determining the radial searching directions for the i-th solution is given as The goal for determining the searching directions is to keep it as much as possible in the direction of the initial direction described with Equation (28).
A stop criterion for the brute force method is when a maximum number of solutions is obtained. The BF method, during a radial search, automatically stops the search in one of the directions if the solution in that direction violates the minimum on/off switching time or if the solution deviates a lot from the solution of the previous modulation index (m). Criteria that stop the search in one of the radial directions if the solution deviates a lot are necessary to ensure the continuity of pulse patterns. The BF method, after reaching the maximum number of solutions, gives a solution at the end of the process with the lowest norm. The given solution is a final solution for the given modulation index which gives a desired first harmonic and elimination of the 5th and the 7th harmonics. This given solution has the lowest norm (the 29th, the 31st, the 35th and the 37th harmonics), obeys a minimum on/off switching time and ensures the continuity of pulse patterns. After finding the best solution for the given modulation index (m), the process is repeated for a different value of the modulation index (m). Figure 4 shows the flowchart of the BF method. The first step of the BF method is initialization, in which the method calculates the initial solution with the NR method for the given modulation index (m). This initial solution is the solution of Equation (9) which satisfies all the additional constraints (angles are in specified order and minimum on/off switching time is obeyed). After the initial solution is found, the method calculates the Jacobian matrix (Equation (14)) and null space of the Jacobian matrix (Equation (19)). The second step of the BF method is calculation of the initial radial direction (Equation (28)), in which the method will begin to search the feasible solutions. In the third step, the method moves in the radial directions and determines the new solutions. The method in the fourth step searches further in radial directions for new solutions, and this step is repeated until one of the stopping criteria is met. In the fifth step, all the determined solutions are analyzed, and the optimal solution is chosen (solution with the lowest norm). The general expression for determining the radial searching directions for the i-th solution is given as The goal for determining the searching directions is to keep it as much as possible in the direction of the initial direction described with Equation (28).
A stop criterion for the brute force method is when a maximum number of solutions is obtained. The BF method, during a radial search, automatically stops the search in one of the directions if the solution in that direction violates the minimum on/off switching time or if the solution deviates a lot from the solution of the previous modulation index (m). Criteria that stop the search in one of the radial directions if the solution deviates a lot are necessary to ensure the continuity of pulse patterns. The BF method, after reaching the maximum number of solutions, gives a solution at the end of the process with the lowest L 1 norm. The given solution is a final solution for the given modulation index which gives a desired first harmonic and elimination of the 5th and the 7th harmonics. This given solution has the lowest L 1 norm (the 29th, the 31st, the 35th and the 37th harmonics), obeys a minimum on/off switching time and ensures the continuity of pulse patterns. After finding the best solution for the given modulation index (m), the process is repeated for a different value of the modulation index (m). Figure 4 shows the flowchart of the BF method. The first step of the BF method is initialization, in which the method calculates the initial solution θ 0 with the NR method for the given modulation index (m). This initial solution is the solution of Equation (9) which satisfies all the additional constraints (angles are in specified order and minimum on/off switching time is obeyed). After the initial solution is found, the method calculates the Jacobian matrix (Equation (14)) and null space of the Jacobian matrix (Equation (19)). The second step of the BF method is calculation of the initial radial direction (Equation (28)), in which the method will begin to search the feasible solutions. In the third step, the method moves in the radial directions and determines the new solutions. The method in the fourth step searches further in radial directions for new solutions, and this step is repeated until one of the stopping criteria is met. In the fifth step, all the determined solutions are analyzed, and the optimal solution is chosen (solution with the lowest L 1 norm).

Determined Pulse Patterns and Comparison with Other Methods
The BF method described in Section 3 is implemented in GNU Octave. The calculation of the pulse patterns is done for the modulation index (m) in the interval 〈0.6, 1.14〉 with the resolution of 5 × 10 . The minimum on/off switching time is set to 100 μs, which corresponds to the 0.0314 rad for 50 Hz frequency of the fundamental harmonic. The maximum deviation of the switching angles between two neighboring modulation indexes (m) is set to 0.04 rad to ensure the continuity of pulse patterns. The BF method starts the search in 100 radial directions from the initial solution, where the maximum number of solutions is set to 10,000. The calculation is conducted for the grid voltage of 3.3 kV (line to line RMS value). To demonstrate the effectiveness of the BF method, the authors also present results for an optimization problem defined with Equation (8) obtained with the NR method and particle swarm optimization (PSO) method. Results obtained with the NR method are actually initial solutions for the BF method as stated in Section 3, i.e., they represent the starting point for the BF method from where the method starts to search for more optimal solutions considering the defined norm. The PSO method based on swarm intelligent algorithms is an optimization tool for unconstrained optimization problems. Due to this, constraints defined in the optimization problem

Determined Pulse Patterns and Comparison with Other Methods
The BF method described in Section 3 is implemented in GNU Octave. The calculation of the pulse patterns is done for the modulation index (m) in the interval 0.6, 1.14 with the resolution of 5 × 10 −4 . The minimum on/off switching time is set to 100 µs, which corresponds to the 0.0314 rad for 50 Hz frequency of the fundamental harmonic. The maximum deviation of the switching angles between two neighboring modulation indexes (m) is set to 0.04 rad to ensure the continuity of pulse patterns. The BF method starts the search in 100 radial directions from the initial solution, where the maximum number of solutions is set to 10,000. The calculation is conducted for the grid voltage of 3.3 kV (line to line RMS value). To demonstrate the effectiveness of the BF method, the authors also present results for an optimization problem defined with Equation (8) obtained with the NR method and particle swarm optimization (PSO) method. Results obtained with the NR method are actually initial solutions for the BF method as stated in Section 3, i.e., they represent the starting point for the BF method from where the method starts to search for more optimal solutions considering the defined L 1 norm. The PSO method based on swarm intelligent algorithms is an optimization tool for unconstrained optimization problems. Due to this, constraints defined in the optimization problem in Equation (8) are added to the cost function in the form of penalty functions. The PSO method is initialized with a population number of 100 particles with the maximum number of iterations set to 400. Constraints regarding the minimum on/off switching time and maximum deviation of the switching angles between two neighboring modulation indexes (m) are the same as for the BF method. Figure 5 shows pulse patterns obtained with the BF method (Figure 5a), NR method ( Figure 5b) and PSO method (Figure 5c). By comparing pulse patterns obtained with the BF method ( Figure 5a) and with the NR method (Figure 5b), a conclusion can be made that pulse patterns obtained with the BF method display more noisiness. These noisiness was expected because the BF method presented in this paper also minimizes higher-order harmonics (the 29th, the 31st, the 35th and the 37th harmonics) in regard to the NR method which only deals with elimination of low-order harmonics (the fifth and the seventh harmonics). A comparison can also be made between pulse patterns obtained with the BF method ( Figure 5a) and PSO method (Figure 5c). By comparing these two pulse patterns (Figure 5a,c), the conclusion can be made that the BF method provides more continuous (less noisiness) pulse patterns and that the on/off switching time is much higher for the whole range of the modulation index (m) than for the pulse patterns obtained with the PSO method.
Electronics 2020, 9, x FOR PEER REVIEW 10 of 20 in Equation (8) are added to the cost function in the form of penalty functions. The PSO method is initialized with a population number of 100 particles with the maximum number of iterations set to 400. Constraints regarding the minimum on/off switching time and maximum deviation of the switching angles between two neighboring modulation indexes (m) are the same as for the BF method. Figure 5 shows pulse patterns obtained with the BF method (Figure 5a), NR method ( Figure 5b) and PSO method (Figure 5c). By comparing pulse patterns obtained with the BF method ( Figure 5a) and with the NR method (Figure 5b), a conclusion can be made that pulse patterns obtained with the BF method display more noisiness. These noisiness was expected because the BF method presented in this paper also minimizes higher-order harmonics (the 29th, the 31st, the 35th and the 37th harmonics) in regard to the NR method which only deals with elimination of low-order harmonics (the fifth and the seventh harmonics). A comparison can also be made between pulse patterns obtained with the BF method ( Figure 5a) and PSO method (Figure 5c). By comparing these two pulse patterns (Figure 5a,c), the conclusion can be made that the BF method provides more continuous (less noisiness) pulse patterns and that the on/off switching time is much higher for the whole range of the modulation index (m) than for the pulse patterns obtained with the PSO method.  Figure 6 shows the calculated norms for the BF method (Figure 6a), NR method ( Figure 6b) and PSO method (Figure 6c). Comparing these three norms, a conclusion can be made that the  Figure 6 shows the calculated L 1 norms for the BF method (Figure 6a), NR method ( Figure 6b) and PSO method (Figure 6c). Comparing these three L 1 norms, a conclusion can be made that the NR method has the highest L 1 norm through the whole range of the modulation index (m) in regard to the BF and the PSO methods. Although the L 1 norm of the BF method ( Figure 6a) and the PSO method ( Figure 6c) seems to be similar, calculating the average value of L 1 norms of both methods reveals that the average value of the L 1 norm of the BF method is 214.26 V, and the average value of the L 1 norm of the PSO method is 298.62 V (in the given range of the modulation index (m)). The verification of the calculated results was done by calculating the first, the fifth and the seventh harmonics with the obtained pulse patterns. Figure 7 shows the obtained first harmonic for the BF method (Figure 7a), NR method ( Figure 7b) and PSO method (Figure 7c). Based on these results, it can be stated that the BF (Figure 7a) and NR (Figure 7b) methods give the desired first harmonic which has a linear dependence on the modulation index (m). The first harmonic of pulse patterns calculated with the PSO method reveals that for low and high values of the modulation index (m), the method fails to converge on the solution, which means that for some values of the modulation index (m), linear dependence on the modulation index (m) is not met. To resolve this problem of convergence with the PSO method, the authors increased the population size of particles and maximum number of iterations, but this did not significantly improve the results. The verification of the calculated results was done by calculating the first, the fifth and the seventh harmonics with the obtained pulse patterns. Figure 7 shows the obtained first harmonic for the BF method (Figure 7a), NR method ( Figure 7b) and PSO method (Figure 7c). Based on these results, it can be stated that the BF (Figure 7a) and NR (Figure 7b) methods give the desired first harmonic which has a linear dependence on the modulation index (m). The first harmonic of pulse patterns calculated with the PSO method reveals that for low and high values of the modulation index (m), the method fails to converge on the solution, which means that for some values of the modulation index (m), linear dependence on the modulation index (m) is not met. To resolve this problem of convergence with the PSO method, the authors increased the population size of particles and maximum number of iterations, but this did not significantly improve the results.   (Figure 8c). Based on these figures, it can be stated that the BF and NR methods have the smallest fifth and seventh harmonics and that their values never exceed 0.17 mV. When you consider that the first harmonic has much higher amplitude, these fifth and seventh harmonics have almost no influence. The fifth and the seventh harmonics of pulse patterns calculated with the PSO method (Figure 8c) have much higher amplitude than the harmonic whose pulse patterns are obtained with the BF or NR methods. The reason for this is that the PSO method did not converge on the optimal solution for some values of the modulation index (m).   (Figure 8c). Based on these figures, it can be stated that the BF and NR methods have the smallest fifth and seventh harmonics and that their values never exceed 0.17 mV. When you consider that the first harmonic has much higher amplitude, these fifth and seventh harmonics have almost no influence. The fifth and the seventh harmonics of pulse patterns calculated with the PSO method (Figure 8c) have much higher amplitude than the harmonic whose pulse patterns are obtained with the BF or NR methods. The reason for this is that the PSO method did not converge on the optimal solution for some values of the modulation index (m).
The results obtained from the BF method were presented in this subsection. For the sake of comparison, the authors also presented the results obtained with the NR and PSO methods. The presented results clearly show that the BF method, in addition to eliminating the lower-order harmonics (the fifth and the seventh), minimized the higher-order harmonics (the 29th, the 31st, the 35th and the 37th). Comparing the BF method with the NR and PSO methods, the conclusion can be made that all three methods have successfully eliminated the fifth and the seventh harmonics. However, the BF method has much better suppression of higher-order harmonics (the 29th, the 31st, the 35th and the 37th) while simultaneously obeying additional constraints on the minimum on/off switching time and continuity of pulse patterns. This additional feature of the BF method of the minimization of selected higher-order harmonics with simultaneous elimination of lower-order harmonics is a key advantage of the proposed method because SHE-PWM has only a limited number of harmonics that can be eliminated. The results obtained from the BF method were presented in this subsection. For the sake of comparison, the authors also presented the results obtained with the NR and PSO methods. The presented results clearly show that the BF method, in addition to eliminating the lower-order harmonics (the fifth and the seventh), minimized the higher-order harmonics (the 29th, the 31st, the 35th and the 37th). Comparing the BF method with the NR and PSO methods, the conclusion can be made that all three methods have successfully eliminated the fifth and the seventh harmonics. However, the BF method has much better suppression of higher-order harmonics (the 29th, the 31st, the 35th and the 37th) while simultaneously obeying additional constraints on the minimum on/off switching time and continuity of pulse patterns. This additional feature of the BF method of the minimization of selected higher-order harmonics with simultaneous elimination of lower-order harmonics is a key advantage of the proposed method because SHE-PWM has only a limited number of harmonics that can be eliminated.

Simulation of 3LV NPC AFE with SHE-PWM in Closed Loop with Determined Pulse Patterns
A dynamic simulation of the proposed system configuration in Figure 2 was conducted in the simulation tool PLECS to verify the pulse patterns calculated with the BF method. The control structure for the SHE-PWM in a closed loop was used for controlling the DC link voltage as it is described in the literature [2,22,23]. Figure 9 illustrates the simulation schematic in the simulation tool PLECS.

Simulation of 3LV NPC AFE with SHE-PWM in Closed Loop with Determined Pulse Patterns
A dynamic simulation of the proposed system configuration in Figure 2 was conducted in the simulation tool PLECS to verify the pulse patterns calculated with the BF method. The control structure for the SHE-PWM in a closed loop was used for controlling the DC link voltage as it is described in the literature [2,22,23]. Figure 9 illustrates the simulation schematic in the simulation tool PLECS.
The simulation schematic in Figure 9 consists of two parts, namely the power part and the control part. The power part consists of the 3 LV NPC AFE and corresponding DC link. The DC link is constructed from two capacitors and a current source for load simulation. The AC side of the 3 LV NPC AFE is connected to the grid power supply through grid impedance LR. The control part consists of an internal current and an external voltage loop. The internal current loop consists of two current PI regulators for regulating the currents in the d-q rotating reference frame synchronous with the grid voltage. The external voltage loop is a PI regulator for regulation of the DC link voltage. PI regulators are tuned by a trial and error method and by authors' experience. Signals V d_dec and V q_dec are decoupling signals between the d and q axes. The SHE Modulator block in Figure 8, based on voltages on the direct and quadrature axes and DC link voltage, calculates firing pulses for the 3 LV NPC AFE converter. Calculation of firing pulses is based on pulse patterns calculated with the BF method presented in Section 3. Block Filtering and transformations filters the measured values (grid voltage and current and DC link voltage) and transforms the grid voltage and currents into a d-q rotating reference frame. Block Decoupling calculates the decoupling signals based on the grid impedance. The simulation schematic in Figure 9 consists of two parts, namely the power part and the control part. The power part consists of the 3 LV NPC AFE and corresponding DC link. The DC link is constructed from two capacitors and a current source for load simulation. The AC side of the 3 LV NPC AFE is connected to the grid power supply through grid impedance LR. The control part consists of an internal current and an external voltage loop. The internal current loop consists of two current PI regulators for regulating the currents in the d-q rotating reference frame synchronous with the grid voltage. The external voltage loop is a PI regulator for regulation of the DC link voltage. PI regulators are tuned by a trial and error method and by authors' experience. Signals _ and _ are decoupling signals between the d and q axes. The SHE Modulator block in Figure 8, based on voltages on the direct and quadrature axes and DC link voltage, calculates firing pulses for the 3 LV NPC AFE converter. Calculation of firing pulses is based on pulse patterns calculated with the BF method presented in Section 3. Block Filtering and transformations filters the measured values (grid voltage and current and DC link voltage) and transforms the grid voltage and currents into a d-q rotating reference frame. Block Decoupling calculates the decoupling signals based on the grid impedance.
The simulation starts with the 3 LV NPC AFE in no load condition and then the load is gradually increased to the rated load. In the simulation time of 1.7 s, the load is reduced by 40% of the rated power and then in the simulation time of 2 s is increased back to 100% of the rated power. The load is simulated with the current source. Figure 10a shows a dynamic response of the DC link voltage, and Figure 10b shows active and reactive power. Simulation results clearly show that with the determined pulse patterns, the simulated system is stable during transients and in steady state, even if the load is suddenly reduced by 40% and then increased suddenly back to 100% of the rated power. The simulation starts with the 3 LV NPC AFE in no load condition and then the load is gradually increased to the rated load. In the simulation time of 1.7 s, the load is reduced by 40% of the rated power and then in the simulation time of 2 s is increased back to 100% of the rated power. The load is simulated with the current source. Figure 10a shows a dynamic response of the DC link voltage, and Figure 10b shows active and reactive power. Simulation results clearly show that with the determined pulse patterns, the simulated system is stable during transients and in steady state, even if the load is suddenly reduced by 40% and then increased suddenly back to 100% of the rated power.  Figure 11 shows a specter of line to neutral voltage for a modulation index equal to 1.085, from which it is clearly visible that the fifth and the seventh harmonics are eliminated. Moreover, the higher-order harmonics (the 29th, the 31st, the 35th and the 37th) have very low amplitude, which means that the proposed BF method has fulfilled its task of minimizing them.  Figure 11 shows a specter of line to neutral voltage for a modulation index equal to 1.085, from which it is clearly visible that the fifth and the seventh harmonics are eliminated. Moreover, the higher-order harmonics (the 29th, the 31st, the 35th and the 37th) have very low amplitude, which means that the proposed BF method has fulfilled its task of minimizing them.  Figure 11 shows a specter of line to neutral voltage for a modulation index equal to 1.085, from which it is clearly visible that the fifth and the seventh harmonics are eliminated. Moreover, the higher-order harmonics (the 29th, the 31st, the 35th and the 37th) have very low amplitude, which means that the proposed BF method has fulfilled its task of minimizing them. Figure 11. Specter of line to neutral voltage of the 3 LV AFE NPC for the modulation index 1.085.

Experimental Results for 3 LV NPC AFE with SHE-PWM in Closed Loop with Determined Pulse Patterns
Verification of pulse patterns obtained with the BF method was done on a low-voltage 3 LV NPC AFE converter. The modulation technique for the 3 LV NPC AFE converter is SHE-PWM based on five switching states in the first quarter of the fundamental harmonic. The rated power of the 3 LV NPC AFE converter is 55.4 kVA (Appendix B) and it is connected to the 400 V, 50 Hz grid. The DC link consists of two capacitors as in Figure 2, and it is connected to the inverter. The inverter modulation technique is space vector PWM with a switching frequency of 1.25 kHz. The inverter is connected to the synchronous motor (SM) of 18.5 kW of rated power. The shaft of the SM is connected to the DC motor to generate load torque. The experimental system is shown in Figure 12.

Experimental Results for 3 LV NPC AFE with SHE-PWM in Closed Loop with Determined Pulse Patterns
Verification of pulse patterns obtained with the BF method was done on a low-voltage 3 LV NPC AFE converter. The modulation technique for the 3 LV NPC AFE converter is SHE-PWM based on five switching states in the first quarter of the fundamental harmonic. The rated power of the 3 LV NPC AFE converter is 55.4 kVA (Appendix B) and it is connected to the 400 V, 50 Hz grid. The DC link consists of two capacitors as in Figure 2, and it is connected to the inverter. The inverter modulation technique is space vector PWM with a switching frequency of 1.25 kHz. The inverter is connected to the synchronous motor (SM) of 18.5 kW of rated power. The shaft of the SM is connected to the DC motor to generate load torque. The experimental system is shown in Figure 12. The experiment for the verification of the calculated pulse patterns was done for the case when the SM runs in no load condition with the rated speed (900 rpm), and then suddenly the load torque is increased to 50% of the rated load. Figure 13a shows the measured active power of the 3 LV NPC AFE converter during the experiment, where the active power is suddenly increased from 500 W to 8.5 kW. The DC link voltage during this experiment is shown in Figure 13b, from where it is clear that the voltage in the DC link drops only about 7 V after transient. The voltage of the 3 LV NPC AFE converter after motor torque is suddenly increased, as shown in Figure 13c. The presented The experiment for the verification of the calculated pulse patterns was done for the case when the SM runs in no load condition with the rated speed (900 rpm), and then suddenly the load torque is increased to 50% of the rated load. Figure 13a shows the measured active power of the 3 LV NPC AFE converter during the experiment, where the active power is suddenly increased from 500 W to 8.5 kW. The DC link voltage during this experiment is shown in Figure 13b, from where it is clear that the voltage in the DC link drops only about 7 V after transient. The voltage of the 3 LV NPC AFE converter after motor torque is suddenly increased, as shown in Figure 13c. The presented measurements clearly show that the 3 LV NPC AFE converter with the calculated patterns can work in closed loop, i.e., the system remains stable after a high dynamic response. The experiment for the verification of the calculated pulse patterns was done for the case when the SM runs in no load condition with the rated speed (900 rpm), and then suddenly the load torque is increased to 50% of the rated load. Figure 13a shows the measured active power of the 3 LV NPC AFE converter during the experiment, where the active power is suddenly increased from 500 W to 8.5 kW. The DC link voltage during this experiment is shown in Figure 13b, from where it is clear that the voltage in the DC link drops only about 7 V after transient. The voltage of the 3 LV NPC AFE converter after motor torque is suddenly increased, as shown in Figure 13c. The presented measurements clearly show that the 3 LV NPC AFE converter with the calculated patterns can work in closed loop, i.e., the system remains stable after a high dynamic response. The final verification of the proposed BF method was done by calculating the voltage specter of the 3 LV NPC AFE converter. The voltage specter is calculated for the voltage after the SM load is suddenly increased which corresponds to the modulation index (m) of 0.875. The specter was calculated for the 1st, the 5th, the 7th, the 29th, the 31st, the 35th and the 37th harmonics and it is compared with the specter calculated from pulse patterns obtained with the BF method in GNU Octave. These voltage specters are shown in Figure 14. Results clearly shows that the measured amplitude of the first harmonic is approximately the same as the amplitude of the first harmonic in the simulation (error is below 1%). The biggest deviations from the simulations results are for the 29th and the 35th harmonics. These deviations can be attributed to the dead time, which the BF method does not consider. Based on Figure 14, the conclusion can be made that the experimental results verify the presented BF method as a reliable technique for determining the pulse patterns which will provide the elimination of low-order harmonics and minimization of selected higherorder harmonics. The final verification of the proposed BF method was done by calculating the voltage specter of the 3 LV NPC AFE converter. The voltage specter is calculated for the voltage after the SM load is suddenly increased which corresponds to the modulation index (m) of 0.875. The specter was calculated for the 1st, the 5th, the 7th, the 29th, the 31st, the 35th and the 37th harmonics and it is compared with the specter calculated from pulse patterns obtained with the BF method in GNU Octave. These voltage specters are shown in Figure 14. Results clearly shows that the measured amplitude of the first harmonic is approximately the same as the amplitude of the first harmonic in the simulation (error is below 1%). The biggest deviations from the simulations results are for the 29th and the 35th harmonics. These deviations can be attributed to the dead time, which the BF method does not consider. Based on Figure 14, the conclusion can be made that the experimental results verify the presented BF method as a reliable technique for determining the pulse patterns which will provide the elimination of low-order harmonics and minimization of selected higher-order harmonics.
compared with the specter calculated from pulse patterns obtained with the BF method in GNU Octave. These voltage specters are shown in Figure 14. Results clearly shows that the measured amplitude of the first harmonic is approximately the same as the amplitude of the first harmonic in the simulation (error is below 1%). The biggest deviations from the simulations results are for the 29th and the 35th harmonics. These deviations can be attributed to the dead time, which the BF method does not consider. Based on Figure 14, the conclusion can be made that the experimental results verify the presented BF method as a reliable technique for determining the pulse patterns which will provide the elimination of low-order harmonics and minimization of selected higherorder harmonics.

Conclusions
This paper presents a new approach for determining the pulse patterns for SHE-PWM on a 3 LV NPC AFE converter. The presented method is based on a BF algorithm and demonstrated on an SHE-PWM with five switching states in the first quarter of the fundamental harmonic. Since SHE-PWM has a limited number of harmonics that can be eliminated, in this paper, a BF method is presented for calculation of pulse patterns that can, in addition to eliminating the lower-order harmonics, minimize (suppress) the selected higher-order harmonics. The BF method also considers the additional constraints on the pulse patterns as the minimum on/off switching time and continuity of pulse patterns.
The BF method in this paper is compared to the other methods, such as the NR and PSO methods. Based on this comparison, the BF method can minimize the selected higher-order harmonics more efficiently and simultaneously ensure that constraints on the minimum on/off switching time and continuity of pulse patterns are obeyed. Due to this, the BF method presented in this paper is a reliable technique for determining the pulse patterns for SHE-PWM.
The calculated pulse patterns were implemented in a laboratory setup of a low-voltage 3 LV NPC AFE converter, and tested during a high dynamic response. From the presented results, the obtained pulse patters provide a stable system during a high dynamic response without overcurrent and overvoltage trips. This paper also presents a specter of the 3 LV NPC AFE voltage for the verification of the BF method. Based on this specter, the main conclusion is that the BF method has fulfilled all the constraints on the pulse patterns defined in this paper, i.e., elimination of the 5th and the 7th harmonics, and minimization of higher-order harmonics (the 29th, the 31st, the 35th and the 37th).
The next step of this research will be the implementation of the obtained pulse patterns in a medium-voltage 3 LV NPC AFE converter. Acknowledgments: The authors would like to thank the Danieli Automation SpA (Italy) company for the support.

Conflicts of Interest:
The authors declare no conflict of interest.