Patent Publication Number: US-2020293703-A1

Title: Microgrid delay margin calculation method based on critical characteristic root tracking

Description:
CROSS REFERENCE TO THE RELATED APPLICATIONS 
     This application is the national phase entry of International Application No. PCT/CN2018/084937, filed on Apr. 27, 2018, which is based upon and claims priority to Chinese Patent Application No. 201710456420.4, filed on Jun. 16, 2017, the entire contents of which are incorporated herein by reference. 
    
    
     TECHNICAL FIELD 
     The present invention discloses a microgrid delay margin calculation method based on critical characteristic root tracking, and in particular to a calculation method for the delay margin of secondary voltage control in a microgrid, which belongs to the technical field of microgrid operation control. 
     BACKGROUND 
     With the gradual depletion of earth resources and the concern of people about environmental issues, the access of renewable energy is receiving more and more attention from all the countries in the world. 
     As an emerging energy transmission mode that increases the penetration of renewable energies and distributed energy resources in an energy supply system, a microgrid comprises different types of distributed energy resources (DER), such as microturbines, wind-driven generators, photovoltaics, fuel cells, energy storage equipments, and the user terminals of various electrical loads and/or thermal loads and related monitoring and protection devices. 
     The power in the microgrid mainly depends on power electronic devices to convert energy and to provide necessary control. Relative to the main grid, the microgrid appears as a single controlled unit, which can simultaneously meet the requirements of users on the quality of electrical energy, the safety of power supply, etc. The microgrid exchanges energy with the main grid via a point of common coupling, and the two parts are standbys for each other, thus increasing the stability of power supply. As a small-scale decentralized system with a short distance from loads, the microgrid reduces power loss while increasing the reliability of local power supplies, which greatly increases the efficiency of energy utilization, so that microgrid is a novel power supply mode that meets the development requirement of intelligent power grids in the future. 
     Droop control has drawn attention due to the capability of realizing power sharing without communication. However, as the steady-state deviation of the output voltage of each distributed generation may occur and due to the difference of output impedances of all the distributed generations, accurate reactive power sharing can hardly be satisfactory, so that the secondary voltage control of the microgrid needs to be adopted to improve the reactive power sharing effect and voltage performance. At present, designed coordinated voltage control is of a centralized control structure in which a centralized voltage controller of the microgrid generates and sends a control signal to the local controller of each distributed generation. The centralized control structure depends on the centralized communication technology, however, the communication process is usually affected by information delay and packet loss, and the influence of information delay, packet loss and so on lead to the poor dynamic performance of the microgrid and even endanger system stability. For the aforementioned reasons, it is necessary to research a calculation method for the secondary voltage control delay margin of microgrid to analyze a maximum communication delay time in a stable microgrid, it is necessary to analyze the relationship between the centralized controller parameters of the microgrid and delay margins, consequently, the design of control parameters can be guided, and the stability and dynamic performance of the microgrid can be effectively improved. 
     SUMMARY 
     Aimed at the phenomenon that the influence of communication delays on dynamic performance is usually neglected in the reactive power sharing and voltage recovery control of a microgrid, the present invention is directed to provide a microgrid delay margin calculation method based on critical characteristic root tracking in full consideration of the actual situation that the influence of communication delays on the system stability cannot be neglected due to the small inertia of power electronic-interfaced microgrid. By the method, all possible pure virtual characteristic roots of the microgrid characteristic equation are obtained, then the maximum delay time in a stable microgrid is calculated, and by researching the relationship between controller parameters and delay margins for stability, a guidance is provided for the design of controller parameters, solving the technical problem that the stability of existing microgrid system is affected by the communication technology. 
     In order to achieve the foregoing objectives, the present invention uses the following technical solutions: 
     Provided is a microgrid delay margin calculation method based on critical characteristic root tracking, comprising: establishing an inverter closed-loop small-signal model and a distributed generation closed-loop small-signal model with voltage feedback control amount including communication delays according to the static feedback output method, establishing a microgrid small-signal model consisting of the connection network model, the dynamic equation of load impedance and the distributed generation closed-loop small-signal model, obtaining a characteristic equation with a transcendental term from the microgrid small-signal model, performing critical characteristic root locus tracking for the transcendental term, and then determining the delay margin for the system stability. 
     Further, in the microgrid delay margin calculation method based on critical characteristic root tracking, the inverter closed-loop small-signal model with voltage feedback control amount including communication delay established according to the static feedback output is: 
     
       
         
           
             { 
             
               
                 
                   
                     
                       
                         
                           Δ 
                            
                           
                               
                           
                            
                           
                             
                               x 
                               . 
                             
                             inv 
                           
                         
                         = 
                         
                           
                             
                               A 
                               inv 
                             
                              
                             Δ 
                              
                             
                                 
                             
                              
                             
                               x 
                               inv 
                             
                           
                           + 
                           
                             
                               B 
                               inv 
                             
                              
                             Δ 
                              
                             
                                 
                             
                              
                             
                               V 
                               iDQ 
                             
                           
                           + 
                           
                             
                               B 
                               u 
                             
                              
                             Δ 
                              
                             
                                 
                             
                              
                             u 
                           
                         
                       
                        
                       
                           
                       
                     
                   
                 
                 
                   
                     
                       
                         
                           Δ 
                            
                           
                               
                           
                            
                           
                             y 
                             invQ 
                           
                         
                         = 
                         
                           
                             C 
                             invQ 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             x 
                             inv 
                           
                         
                       
                       , 
                       
                         
                           Δ 
                            
                           
                               
                           
                            
                           
                             y 
                             invV 
                           
                         
                         = 
                         
                           
                             C 
                             invV 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             x 
                             inv 
                           
                         
                       
                     
                   
                 
               
               , 
             
           
         
       
     
     Δx inv  and Δ{dot over (x)} inv  respectively represent the state variables and the change rate of the closed-loop small signal model of the inverter, Δx inv =[Δx inv1 , Δx inv2 , . . . , Δx invi , . . . , Δx invn , Δφ 1 , Δφ 2 , . . . , Δφ i , . . . , Δφ n , Δγ] T , Δx inv1 , Δx inv2 , Δx invi  and Δx invn  respectively represent small-signal state variables of the first, second, ith and nth distributed generations, Δφ 1 , Δφ 2 , Δφ i  and Δφ n  respectively represent small-signal state variables for reactive power ancillaries of the first, second, ith and nth distributed generations, the small-signal state variable for the reactive power ancillary Δφ i  of the ith distributed generation is determined by an expression: 
     
       
         
           
             
               
                 
                   ϕ 
                   . 
                 
                 i 
               
               = 
               
                 
                   
                     
                       1 
                        
                       
                         / 
                       
                        
                       
                         n 
                         Qi 
                       
                     
                     
                       
                         ∑ 
                         
                           i 
                           = 
                           1 
                         
                         n 
                       
                        
                       
                           
                       
                        
                       
                         1 
                          
                         
                           / 
                         
                          
                         
                           n 
                           Qi 
                         
                       
                     
                   
                    
                   
                     
                       ∑ 
                       
                         i 
                         = 
                         1 
                       
                       n 
                     
                      
                     
                         
                     
                      
                     
                       Q 
                       i 
                     
                   
                 
                 - 
                 
                   Q 
                   i 
                 
               
             
             , 
           
         
       
     
     φ i  represents the change rate of the small-signal state variable for the reactive power ancillary of the ith distributed generation, Q i  represents the actually output reactive power of the ith distributed generation, n Qi  represents the voltage droop characteristic coefficient of the ith distributed generation, n represents the number of the distributed generations, Δγ represents the small-signal state variable for voltage ancillary of the distributed generations, the small-signal state variable Δγ for the voltage ancillaries of the distributed generations is determined by an expression: 
     
       
         
           
             
               
                 γ 
                 . 
               
               = 
               
                 
                   V 
                   i 
                   * 
                 
                 - 
                 
                   
                     1 
                     n 
                   
                    
                   
                     
                       ∑ 
                       
                         i 
                         = 
                         1 
                       
                       n 
                     
                      
                     
                         
                     
                      
                     
                       V 
                       odi 
                     
                   
                 
               
             
             , 
           
         
       
     
     {dot over (γ)} represents the change rate of the small-signal state variable for the voltage ancillary of the distributed generations, V* i  represents an expected value of the average voltage of the ith distributed generation, V odi  represents the d-axis component of the output voltage of the ith distributed generation under its own reference coordinate system dq, A inv  represents the state matrix of the distributed generation, ΔV bDQ  represents the small-signal state variables of bus voltages in the common reference coordinate system DQ, ΔV bDQ =[ΔV bDQ1 , ΔV bDQ2 , . . . , ΔV bDQ1 , . . . , ΔV bDQm ] T , ΔV bDQ1 , ΔV bDQ2 , ΔV bDQ1  and ΔV bDQm  respectively represent the small-signal state variables of voltages of first, second, lth and mth buses in the common reference coordinate system DQ, m represents the number of the buses, B inv  represents the input matrix of the distributed generations to the bus voltages, Δu represents the small-signal control amounts of the secondary voltages of the distributed generations, Δu=[Δu 1 , Δu 2 , . . . , Δu i , . . . , Δu n )] T , Δu 1 , Δu 2 , Δu i  and Δu n  respectively represent the small-signal control amounts of the secondary voltages of the first, second, ith and nth distributed generations, B u  represents the input matrix of the distributed generation to the small-signal control amount of the secondary voltage Δu i =K Qi Δy invQi (t−τ i )+K Vi Δy invV (t−τ i ), t represents the current time, τ i  represents the communication delay between the local controller of the ith distributed generation and the centralized secondary voltage controller of microgrid, K Qi  and K Vi  respectively represent the control coefficients of the reactive power and voltage of the ith distributed generation, Δy invQi  represents the small-signal state variable of reactive power of the ith distributed generation, Δy invQ  and Δy invV  respectively represent the small-signal state variables of the reactive power and voltages of the distributed generations, and C invQ  and C invV  respectively represent the output matrices of reactive power and voltage of the distributed generations. 
     Further, in the microgrid delay margin calculation method based on critical characteristic root tracking, the distributed generation closed-loop small-signal model with voltage feedback control amount including communication delay established according to the static feedback output is: 
     
       
         
           
             { 
             
               
                 
                   
                     
                       
                         Δ 
                          
                         
                             
                         
                          
                         
                           
                             x 
                             . 
                           
                           inv 
                         
                       
                       = 
                       
                         
                           
                             A 
                             inv 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             x 
                             inv 
                           
                         
                         + 
                         
                           
                             ∑ 
                             
                               i 
                               - 
                               1 
                             
                             n 
                           
                            
                           
                               
                           
                            
                           
                             
                               
                                 A 
                                 _ 
                               
                               di 
                             
                              
                             Δ 
                              
                             
                                 
                             
                              
                             
                               
                                 x 
                                 inv 
                               
                                
                               
                                 ( 
                                 
                                   t 
                                   - 
                                   
                                     τ 
                                     i 
                                   
                                 
                                 ) 
                               
                             
                           
                         
                         + 
                         
                           
                             B 
                             inv 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             V 
                             bDQ 
                           
                         
                       
                     
                   
                 
                 
                   
                     
                       
                         
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             oDQ 
                           
                         
                         = 
                         
                           
                             C 
                             invc 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             x 
                             inv 
                           
                         
                       
                        
                       
                           
                       
                     
                   
                 
               
               , 
             
           
         
       
     
     Ā di  represents the delayed state matrix of the ith distributed generation, Ā di =[ 0  . . . B ui K Qi C invQi +B ui K Vi C invV  . . . 0], B ui  represents the input matrix of the ith distributed generation to the small-signal control amount of the secondary voltage, C invQi  represents the output matrix of reactive power of the ith distributed generation, Δi oDQ  represents the small-signal state variables of the output currents of the distributed generations in the common reference coordinate system, and C invc  represents the output matrix of currents of the distributed generations. 
     Further, in the microgrid delay margin calculation method based on critical characteristic root tracking, the microgrid small-signal model is 
     
       
         
           
             
               
                 x 
                 . 
               
               = 
               
                 Ax 
                 + 
                 
                   
                     ∑ 
                     
                       i 
                       - 
                       1 
                     
                     n 
                   
                    
                   
                       
                   
                    
                   
                     
                       A 
                       di 
                     
                      
                     
                       x 
                        
                       
                         ( 
                         
                           t 
                           - 
                           
                             τ 
                             i 
                           
                         
                         ) 
                       
                     
                   
                 
               
             
             , 
           
         
       
     
     x and {dot over (x)} respectively represent the small-signal state variables and the change rate of microgrid, x=[Δx inv Δi lineDQ Δi loadDQ ] T , Δi lineDQ  represents the small-signal state variables of the currents of connection lines between buses connected to the distributed generations in the common reference coordinate system, the small-signal state variable of the current of the connection line between the bus connected to the ith distributed generation and the bus connected to the jth distributed generation in the common reference coordinate system DQ is: 
     
       
         
           
             { 
             
               
                 
                   
                     
                       
                         Δ 
                          
                         
                             
                         
                          
                         
                           
                             i 
                             . 
                           
                           lineDij 
                         
                       
                       = 
                       
                         
                           
                             - 
                             
                               
                                 r 
                                 lineij 
                               
                               
                                 L 
                                 lineij 
                               
                             
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             lineDij 
                           
                         
                         + 
                         
                           
                             ω 
                             0 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             lineQij 
                           
                         
                         + 
                         
                           
                             1 
                             
                               L 
                               lineij 
                             
                           
                            
                           
                             ( 
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busDi 
                                 
                               
                               - 
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busDj 
                                 
                               
                             
                             ) 
                           
                         
                       
                     
                   
                 
                 
                   
                     
                       
                         Δ 
                          
                         
                             
                         
                          
                         
                           
                             i 
                             . 
                           
                           lineQij 
                         
                       
                       = 
                       
                         
                           
                             - 
                             
                               
                                 r 
                                 lineij 
                               
                               
                                 L 
                                 lineij 
                               
                             
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             lineQij 
                           
                         
                         - 
                         
                           
                             ω 
                             0 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             lineDij 
                           
                         
                         + 
                         
                           
                             1 
                             
                               L 
                               lineij 
                             
                           
                            
                           
                             ( 
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busQi 
                                 
                               
                               - 
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busQj 
                                 
                               
                             
                             ) 
                           
                         
                       
                     
                   
                 
               
               , 
             
           
         
       
     
     Δi lineDij  and Δ{dot over (i)} lineDij  respectively represent the D-axis component of small-signal variable of the current of the connection line ij and its change rate in the common reference coordinate system, Δi lineQij  and Δi lineQij  respectively represent the Q-axis component of small-signal variable of the current of the connection line ij and its change rate in the common reference coordinate system DQ, r lineij  and L lineij  respectively represent the line resistance and the line inductance of the connection line, ω 0  represents the rated angular frequency of the microgrid, ΔV busDi  and ΔV busQi  respectively represent the D-axis component and the Q-axis component of the voltage of the bus connected to the ith distributed generation in the common reference coordinate system DQ, ΔV busDj  and ΔV busQj  respectively represent the D-axis component and Q-axis component of the voltage of the bus connected to the jth distributed generation in the common reference coordinate system, Δi loadDQ  represents the small-signal state variables of the currents of loads connected to the buses in the common reference coordinate system DQ, the small-signal state variable of the current of the load connected to the lth bus in the common reference coordinate system DQ is: 
     
       
         
           
             { 
             
               
                 
                   
                     
                       
                         Δ 
                          
                         
                             
                         
                          
                         
                           
                             i 
                             . 
                           
                           loadDl 
                         
                       
                       = 
                       
                         
                           
                             - 
                             
                               
                                 R 
                                 loadl 
                               
                               
                                 L 
                                 loadl 
                               
                             
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             loadDl 
                           
                         
                         + 
                         
                           
                             ω 
                             0 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             loadQl 
                           
                         
                         + 
                         
                           
                             1 
                             
                               L 
                               loadl 
                             
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             V 
                             busDl 
                           
                         
                       
                     
                   
                 
                 
                   
                     
                       
                         Δ 
                          
                         
                             
                         
                          
                         
                           
                             i 
                             . 
                           
                           loadQl 
                         
                       
                       = 
                       
                         
                           
                             - 
                             
                               
                                 R 
                                 loadl 
                               
                               
                                 L 
                                 loadl 
                               
                             
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             loadQl 
                           
                         
                         - 
                         
                           
                             ω 
                             0 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             loadDl 
                           
                         
                         + 
                         
                           
                             1 
                             
                               L 
                               loadl 
                             
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             V 
                             busQl 
                           
                         
                       
                     
                   
                 
               
               , 
             
           
         
       
     
     Δi loadD1  and Δ{dot over (i)} loadD1  respectively represent the D-axis component of the current of load connected to the lth bus and the change rate of the current of the load in the common reference coordinate system DQ, Δi loadQl  and Δi loadQl  respectively represent the Q-axis component of the current of the load connected to the lth bus and its change rate in the common reference coordinate system DQ, R loadl  and L loadl  respectively represent the load resistance and the load inductance of the load connected to the lth bus, ΔV busDl  and ΔV busQl  respectively represent the D-axis component and Q-axis component of the voltage of the lth bus in the common reference coordinate system DQ, and A di  and τ i  respectively represent the delayed state matrix and delay of the ith distributed generation. 
     As a further optimized solution of the microgrid delay margin calculation method based on critical characteristic root tracking, the method for obtaining the characteristic equation with the transcendental term from the microgrid small-signal model is as follows: when the delays of the distributed generations are consistent, the characteristic equation of the microgrid small-signal model is obtained: CE τ (s,τ)=det(sI−A−A d e −τs ), s represents the parameter of the time domain complex plane, T represents the consistent delay time of each distributed generation, CE τ (⋅) represents a characteristic equation of the microgrid small-signal model obtained according to the consistent delay T of each distributed generation, det(⋅) represents the matrix determinant, I represents a unit matrix, A d  represents the delayed state matrix of the distributed generations, 
     
       
         
           
             
               
                 A 
                 d 
               
               = 
               
                 
                   ∑ 
                   
                     i 
                     - 
                     1 
                   
                   n 
                 
                  
                 
                     
                 
                  
                 
                   A 
                   di 
                 
               
             
             , 
           
         
       
     
     and e −τs  represents the transcendent term. 
     As a more further optimized solution of the microgrid delay margin calculation method based on critical characteristic root tracking, critical characteristic root locus tracking is performed for the transcendent term, then a delay margin meeting the requirement of system stability is determined, and the specific method is as follows: with a delay time ancillary variable as the variable of the characteristic equation, all pure virtual characteristic roots of the characteristic equation within the change cycle of the delay time ancillary variable are solved, a minimum value is chosen as the delay margin meeting the requirement of system stability from the critical delays corresponding to all the pure virtual characteristic roots, and the delay time ancillary variable is the product of the delay of distributed generation and the amplitude of the virtual characteristic root. 
     The technical solutions used in the present invention have the following beneficial effects: 
     (1) According to the calculation method for the secondary voltage control delay margin of the microgrid provided by the present invention, a microgrid closed-loop small-signal model with voltage feedback control amount including communication delay is established based on static output feedback, thus obtaining a characteristic equation with a transcendental term, critical characteristic root locus tracking is performed for the transcendental term of the system characteristic equation, possible pure virtual characteristic roots are searched, then a maximum delay time for a stable microgrid is calculated; the method can effectively alleviate the influence of communication delay on the dynamic performance of the microgrid, effectively improving the stability and dynamic performance of the microgrid. 
     (2) By solving system stability margins under different controller parameters, and researching the relationship between the controller parameters and the delay margins, the design of the controller parameters can be guided, effectively improving the stability and dynamic performance of the microgrid. 
    
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         FIG. 1  shows the flow chart according to an embodiment of the present invention; 
         FIG. 2  shows the primary and secondary control block diagrams of a microgrid according to embodiment of the present invention; 
         FIG. 3  shows the microgrid simulation system diagram adopted in an embodiment of the present invention; 
         FIG. 4  shows the schematic diagram of critical characteristic root locus tracking under a certain set of controller parameters (k IQ =0.02, k IV =20); 
         FIG. 5  shows the relationship between the controller parameters and system delay margins according to an embodiment of the present invention; 
         FIG. 6A  shows the influence of three different communication delays on the dynamic performance of average voltage under a certain set of controller parameters (k IQ =0.02, k IV =20) according to an embodiment of the present invention; 
         FIG. 6B  shows the influence of three different communication delays on the dynamic performance of the reactive power of a distributed generation 1 under a certain set of controller parameters (k IQ =0.02, k IV =20) according to an embodiment of the present invention; 
         FIG. 6C  shows the influence of three different communication delays on the dynamic performance of the reactive power of a distributed generation 2 under a certain set of controller parameters (k IQ =0.02, k IV =20) according to an embodiment of the present invention; 
         FIG. 7A  shows the influence of three different communication delays on the dynamic performance of average voltage under a certain set of controller parameters (k IQ =0.04, k IV =40) according to an embodiment of the present invention; 
         FIG. 7B  shows the influence of three different communication delays on the dynamic performance of the reactive power of the distributed generation 1 under a certain set of controller parameters (k IQ =0.04, k IV =40) according to an embodiment of the present invention; and 
         FIG. 7C  shows the influence of three different communication delays on the dynamic performance of the reactive power of the distributed generation 2 under a certain set of controller parameters (k IQ =0.04, k IV =40) according to an embodiment of the present invention. 
     
    
    
     DETAILED DESCRIPTION OF THE EMBODIMENTS 
     The following describes the technical solutions of the present invention in detail with reference to accompanying drawings. 
     As shown in  FIG. 1 , the present invention discloses a microgrid delay margin calculation method based on critical characteristic root tracking, which comprises the following steps: 
     Step (10): Establish the inverter closed-loop small-signal model with voltage feedback control amount including communication delay based on static output feedback Each distributed generation utilizes the droop control loop in the local controller to set the references of inverter output voltage and frequency, as shown in formula (1): 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               ω 
                               i 
                             
                             = 
                             
                               
                                 ω 
                                 n 
                               
                               - 
                               
                                 
                                   m 
                                   Pi 
                                 
                                  
                                 
                                   P 
                                   i 
                                 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               
                                 k 
                                 Vi 
                               
                                
                               
                                 
                                   V 
                                   . 
                                 
                                 
                                   o 
                                   , 
                                   mogi 
                                 
                               
                             
                             = 
                             
                               
                                 V 
                                 n 
                               
                               - 
                               
                                 V 
                                 
                                   o 
                                   , 
                                   mogi 
                                 
                               
                               - 
                               
                                 
                                   n 
                                   Qi 
                                 
                                  
                                 
                                   Q 
                                   i 
                                 
                               
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     1 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (1), ω i  represents the local angular frequency of the ith distributed generation; ω n  represents the reference value of the local angular frequency of the distributed generation, unit: rad/s; m Pi  represents the frequency droop characteristic coefficient of the ith distributed generation, unit: rad/s·W; P represents the output active power of the ith distributed generation, unit: W; k Vi  represents the droop control gain of the ith distributed generation; {dot over (V)} o,magi  represents the change rate of the output voltage of the ith distributed generation, unit: V/s; V n  represents the reference value of the output voltage of the distributed generation, unit: V; V o,magi  represents the output voltage of the ith distributed generation, unit: V; n Qi  represents the voltage droop characteristic coefficient of the ith distributed generation, unit: V/Var; and Q i  represents the output reactive power of the ith distributed generation, unit: Var. 
     The output active power P i  and the output reactive power Q i  of the ith distributed generation are obtained by a low-pass filter, as shown in formula (2): 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               
                                 P 
                                 . 
                               
                               i 
                             
                             = 
                             
                               
                                 
                                   - 
                                   
                                     ω 
                                     ci 
                                   
                                 
                                  
                                 
                                   P 
                                   i 
                                 
                               
                               + 
                               
                                 
                                   ω 
                                   ci 
                                 
                                  
                                 
                                   ( 
                                   
                                     
                                       
                                         V 
                                         odi 
                                       
                                        
                                       
                                         i 
                                         odi 
                                       
                                     
                                     + 
                                     
                                       
                                         V 
                                         oqi 
                                       
                                        
                                       
                                         i 
                                         oqi 
                                       
                                     
                                   
                                   ) 
                                 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               
                                 Q 
                                 . 
                               
                               i 
                             
                             = 
                             
                               
                                 
                                   - 
                                   
                                     ω 
                                     ci 
                                   
                                 
                                  
                                 
                                   Q 
                                   i 
                                 
                               
                               + 
                               
                                 
                                   ω 
                                   ci 
                                 
                                  
                                 
                                   ( 
                                   
                                     
                                       
                                         V 
                                         oqi 
                                       
                                        
                                       
                                         i 
                                         odi 
                                       
                                     
                                     - 
                                     
                                       
                                         V 
                                         odi 
                                       
                                        
                                       
                                         i 
                                         oqi 
                                       
                                     
                                   
                                   ) 
                                 
                               
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     2 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (2), {dot over (P)} i  represents the change rate of the output active power of the ith distributed generation, unit: W/s; ω ci  represents the cutoff frequency of the low-pass filter of the ith distributed generation, unit: rad/s; V odi  represents the d-axis component of the output voltage of the ith distributed generation in the reference coordinate system dq of the ith distributed generation, unit: V; V oqi  represents the q-axis component of the output voltage of the ith distributed generation in the reference coordinate system dq of the ith distributed generation, unit: V; i odi  represents the d-axis component of the output current of the ith distributed generation in the reference coordinate system dq of the ith distributed generation, unit: A; i oqi  represents the q-axis component of the output voltage of the ith distributed generation in the reference coordinate system dq of the ith distributed generation, unit: A; and {dot over (Q)} i  represents the change rate of the output reactive power of the ith distributed generation, unit: Var/s. 
     The primary and secondary control block diagrams of the microgrid are shown as  FIG. 2 , the primary control of each distributed generation makes the q-axis component of the output voltage be 0 by phase-locked loop control, and formula (3) is obtained based on the secondary voltage control of the distributed generation: 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               
                                 k 
                                 Vi 
                               
                                
                               
                                 
                                   V 
                                   . 
                                 
                                 odi 
                               
                             
                             = 
                             
                               
                                 V 
                                 ni 
                               
                               - 
                               
                                 V 
                                 odi 
                               
                               - 
                               
                                 
                                   n 
                                   Qi 
                                 
                                  
                                 
                                   Q 
                                   i 
                                 
                               
                               + 
                               
                                 u 
                                 i 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               
                                 V 
                                 oqi 
                               
                               = 
                               0 
                             
                              
                             
                                 
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     3 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (3), {dot over (V)} odi  represents the change rate of the d-axis component of the output voltage of the ith distributed generation in the reference coordinate system dq of the ith distributed generation, unit: V/s; V ni  represents the reference value of the output voltage of the ith distributed generation, and u i  represents the secondary voltage control amount, unit: V. 
     A dynamic equation for the output current of the distributed generation is shown as formula (4): 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               
                                 i 
                                 . 
                               
                               odi 
                             
                             = 
                             
                               
                                 
                                   - 
                                   
                                     
                                       R 
                                       ci 
                                     
                                     
                                       L 
                                       ci 
                                     
                                   
                                 
                                  
                                 
                                   i 
                                   odi 
                                 
                               
                               + 
                               
                                 
                                   ω 
                                   i 
                                 
                                  
                                 
                                   i 
                                   oqi 
                                 
                               
                               + 
                               
                                 
                                   1 
                                   
                                     L 
                                     ci 
                                   
                                 
                                  
                                 
                                   ( 
                                   
                                     
                                       V 
                                       odi 
                                     
                                     - 
                                     
                                       V 
                                       busdi 
                                     
                                   
                                   ) 
                                 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               
                                 i 
                                 . 
                               
                               oqi 
                             
                             = 
                             
                               
                                 
                                   - 
                                   
                                     
                                       R 
                                       ci 
                                     
                                     
                                       L 
                                       ci 
                                     
                                   
                                 
                                  
                                 
                                   i 
                                   oqi 
                                 
                               
                               - 
                               
                                 
                                   ω 
                                   i 
                                 
                                  
                                 
                                   i 
                                   odi 
                                 
                               
                               + 
                               
                                 
                                   1 
                                   
                                     L 
                                     ci 
                                   
                                 
                                  
                                 
                                   ( 
                                   
                                     
                                       V 
                                       oqi 
                                     
                                     - 
                                     
                                       V 
                                       busqi 
                                     
                                   
                                   ) 
                                 
                               
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     4 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (4), i odi  represents the change rate of the d-axis component of the output current of the ith distributed generation in the reference coordinate system dq of the ith distributed generation, unit: A/s; R ci  represents the connection resistance from the ith distributed generation to its connected bus, unit: Ω; L ci  represents the connection inductance from the ith distributed generation to the connected bus, unit: H; V busdi  represents the d-axis component of the voltage of the bus connected to the ith distributed generation in the reference coordinate system dq of the ith distributed generation; i oqi  represents the change rate of the q-axis component of the output current of the ith distributed generation in the reference coordinate system dq of the ith distributed generation, unit: A/s; and V busqi  represents the q-axis component of the voltage of the bus connected to the ith distributed generation in the reference coordinate system dq of the ith distributed generation, unit: V. 
     A model is established for each distributed generation on the basis of the local reference coordinate system dq. In order to establish an integrated microgrid model including a plurality of distributed generations, the reference coordinate system dq of one distributed generation is set as the common reference coordinate system DQ, the output currents of the other distributed generations in their reference coordinate systems dq need to be transformed into the common reference coordinate system, and the transformation equation is shown as formula (5): 
     
       
         
           
             
               
                 
                   
                     [ 
                     
                       
                         
                           
                             i 
                             oDi 
                           
                         
                       
                       
                         
                           
                             i 
                             oQi 
                           
                         
                       
                     
                     ] 
                   
                   = 
                   
                     
                       
                         T 
                         i 
                       
                        
                       
                         [ 
                         
                           
                             
                               
                                 i 
                                 odi 
                               
                             
                           
                           
                             
                               
                                 i 
                                 oqi 
                               
                             
                           
                         
                         ] 
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     5 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (5), i oDi  represents the D-axis component of the output current of the ith distributed generation in the common reference coordinate system DQ, and i oQi  represents the Q-axis component of the output current of the ith distributed generation in the common reference coordinate system, unit: A; T i  represents the transformation matrix of the output current of the ith distributed generation from the reference coordinate system dq of the ith distributed generation to the common reference coordinate system DQ, 
     
       
         
           
             
               
                 T 
                 i 
               
               = 
               
                 [ 
                 
                   
                     
                       
                         cos 
                          
                         
                             
                         
                          
                         
                           δ 
                           i 
                         
                       
                     
                     
                       
                         
                           - 
                           sin 
                         
                          
                         
                             
                         
                          
                         
                           δ 
                           i 
                         
                       
                     
                   
                   
                     
                       
                         sin 
                          
                         
                             
                         
                          
                         
                           δ 
                           i 
                         
                       
                     
                     
                       
                         cos 
                          
                         
                             
                         
                          
                         
                           δ 
                           i 
                         
                       
                     
                   
                 
                 ] 
               
             
             , 
           
         
       
     
     δ i  represents the difference between the rotation angle of the reference coordinate system dq of the ith distributed generation and the rotation angle of the common reference coordinate system DQ, unit: degree, and δ i  can be obtained by formula (6): 
       {dot over (δ)} i =ω i −ω com   Formula (6).
 
     In formula (6), ω com  represents the angular frequency of the common reference coordinate system DQ; and {dot over (δ)} i  represents the change rate of δ i . 
     Formulas (1)-(6) are linearized to obtain an open-loop small-signal model of the ith distributed generation shown as formula (7): 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               Δ 
                                
                               
                                   
                               
                                
                               
                                 
                                   x 
                                   . 
                                 
                                 invi 
                               
                             
                             = 
                             
                               
                                 
                                   A 
                                   invi 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   x 
                                   invi 
                                 
                               
                               + 
                               
                                 
                                   B 
                                   invi 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   bDQi 
                                 
                               
                               + 
                               
                                 
                                   B 
                                   iwcom 
                                 
                                  
                                 
                                   Δω 
                                   com 
                                 
                               
                               + 
                               
                                 
                                   B 
                                   ui 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   u 
                                   i 
                                 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   i 
                                   oDQi 
                                 
                               
                               = 
                               
                                 
                                   C 
                                   invci 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   x 
                                   invi 
                                 
                               
                             
                              
                             
                                 
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     7 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (7), Δ{dot over (x)} invi  represents the change rate of the small-signal state variables of the ith distributed generation, Δ{dot over (x)} invi =[Δ{dot over (δ)} i , Δ{dot over (P)} i , Δ{dot over (Q)} i , Δ{dot over (V)} odi , Δ{dot over (i)} odi , Δ{dot over (i)} oqi ] T ; Δx invi  represents the small-signal state variables of the ith distributed generation, Δx invi =[Δδ i , ΔP i , ΔQ i , ΔV odi , Δi odi , Δi oqi ] T ; ΔV bDQi  represents the small-signal state variables of the voltage of the bus connected to the ith distributed generation in the common reference coordinate system DQ; ΔV bDQi =[ΔV bDi , ΔV bQi ] T , ΔV bDi  represents the D-axis small-signal component of the voltage of the bus connected to the ith distributed generation in the common reference coordinate system DQ, and ΔV bQi  represents the Q-axis small-signal component of the voltage of the bus connected to the ith distributed generation in the common reference coordinate system DQ, unit: V; Δω com  represents the small-signal state variable of the angular frequency of the common reference coordinate system DQ, unit: rad/s; Δu i  represents the small-signal control amount of the secondary voltage of the ith distributed generation, unit: V; A invi  represents the state matrix of the ith distributed generation; B invi  represents the input matrix of the ith distributed generation to the voltage of the connected bus; B iwcom  represents the input matrix of the ith distributed generation to the angular frequency of the common reference coordinate system; B ui  represents the input matrix of the ith distributed generation to the small-signal control amount of the secondary voltage; Δi oDQi  represents the small-signal state variables of the output current of the ith distributed generation in the common reference coordinate system DQ, ΔΔi oDQi =[Δi oDi , Δi oQi ] T , unit: A; and C invci  represents the output current matrix of the ith distributed generation. 
     According to formula (7), ΔV busDQi  and Δω com  serve as disturbance variables of the ith distributed generation, where the reference coordinate system of the first distributed generation is generally selected as the common reference coordinate system DQ, then 
       Δω com =[0− m   P1  0 0 0 0]Δ x   inv1   Formula (8).
 
     In formula (8), m P1  represents the frequency droop characteristic coefficient of the first distributed generation, unit: rad/s·W; Δx inv1  represents the small-signal state variables of the first distributed generation, Δx inv1 =[Δδ 1 , ΔP i , Δ Q1 , ΔV od1 , Δi od1 , Δi oq1 ] T . 
     According to formula (7) and formula (8), the small-signal model of the system consisting of n distributed generations can be obtained: 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               Δ 
                                
                               
                                   
                               
                                
                               
                                 
                                   
                                     x 
                                     _ 
                                   
                                   . 
                                 
                                 inv 
                               
                             
                             = 
                             
                               
                                 
                                   
                                     A 
                                     _ 
                                   
                                   inv 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   
                                     x 
                                     _ 
                                   
                                   inv 
                                 
                               
                               + 
                               
                                 
                                   
                                     B 
                                     _ 
                                   
                                   inv 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   bDQ 
                                 
                               
                               + 
                               
                                 
                                   
                                     B 
                                     _ 
                                   
                                   u 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 u 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   i 
                                   oDQ 
                                 
                               
                               = 
                               
                                 
                                   
                                     C 
                                     _ 
                                   
                                   invc 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   
                                     x 
                                     _ 
                                   
                                   inv 
                                 
                               
                             
                              
                             
                                 
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     9 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (9), Δ x   inv =[Δx inv1 Δx inv2  . . . Δ invn ], Δx inv1  represents the small-signal state variables of the first distributed generation, Δx inv2  represents the small-signal state variables of the second distributed generation, and Δx invn  represents the small-signal state variables of the nth distributed generation; ΔV bDQ =[ΔV bDQ1  ΔV bDQ2  . . . ΔV busDQm ] T , ΔV bDQ1 =[ΔV bD1 ΔV bQ1 ] T , ΔV BD1  represents the D-axis component of small-signal variable of the voltage of bus  1  in the common reference coordinate system DQ, ΔV bQ1  represents the Q-axis component of small-signal variable of the voltage of bus  1  in the common reference coordinate system DQ, ΔV bDQ2 =[ΔV bD2  ΔV bQ2 ] T , ΔV bD2  represents the D-axis component of small-signal variable of the voltage of bus  2  in the common reference coordinate system DQ, ΔV bQ2  represents the Q-axis component of small-signal variable of the voltage of bus  2  in the common reference coordinate system DQ, ΔV bDQm =[ΔV bDm  ΔV bQm ] T , ΔV bDm  represents the D-axis component of small-signal variable of the voltage of bus m in the common reference coordinate system DQ, and ΔV bQm  represents the Q-axis component of small-signal variable of the voltage of bus m in the common reference coordinate system DQ; Δu=[Δu 1 Δu 2  . . . Δu n ] T , Δi oD1  represents the small-signal control amount of the secondary voltage of the distributed generation 1, Δu 2  represents the small-signal control amount of the secondary voltage of the distributed generation 2, and Δu n  represents the small-signal control amount of the secondary voltage of the distributed generation n; Δi oDQ =[Δi oDQl Δi oDQ2  . . . Δi oDQn ] T , Δi oDQ1 =[Δi oD1 , Δi oQ1 ] T , Δi oD1  represents the D-axis component of small-signal variable of the output current of the first distributed generation in the common reference coordinate system DQ, Δi oQ1  represents the Q-axis component of small-signal variable of the output current of the ith distributed generation in the common reference coordinate system DQ, Δi oDQ2 =[Δi oD2 , Δi oQ2 ] T , Δi oD2  represents the D-axis component of small-signal variable of the output current of the second distributed generation in the common reference coordinate system DQ, and Δi oQ2  represents the Q-axis component of small-signal variable of the output current of the second distributed generation in the common reference coordinate system DQ; Δi oDQn =[Δi oDn , Δi oQn ] T , Δi oDn  represents the D-axis component of small-signal variable of the output current of the nth distributed generation in the common reference coordinate system DQ, Δi oQn  represents the Q-axis component of small-signal variable of the output current of the nth distributed generation in the common reference coordinate system DQ, and Ā inv  represents the state matrix of n distributed generations;  B   inv  represents the input matrix of n distributed generations to bus voltages; {circumflex over (B)} n  represents the input matrix of the n distributed generations to the small-signal control amount of the secondary voltage; and  C   invc  represents the current output matrix of the n distributed generations. 
     Based on the control requirements of reactive power sharing and voltage recovery, the present invention realizes microgrid voltage control. Reactive power sharing refers to that the output reactive power of each distributed generation is allocated according to the power capacity, voltage recovery refers to that the average output voltage of all the distributed generations is recovered to a rated value, and the following dynamic equation is first defined: 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               
                                 ϕ 
                                 . 
                               
                               i 
                             
                             = 
                             
                               
                                 
                                   Q 
                                   i 
                                   * 
                                 
                                 - 
                                 
                                   Q 
                                   i 
                                 
                               
                               = 
                               
                                 
                                   
                                     
                                       1 
                                        
                                       
                                         / 
                                       
                                        
                                       
                                         n 
                                         Qi 
                                       
                                     
                                     
                                       
                                         ∑ 
                                         
                                           i 
                                           = 
                                           1 
                                         
                                         n 
                                       
                                        
                                       
                                           
                                       
                                        
                                       
                                         1 
                                          
                                         
                                           / 
                                         
                                          
                                         
                                           n 
                                           Qi 
                                         
                                       
                                     
                                   
                                    
                                   
                                     
                                       ∑ 
                                       
                                         i 
                                         = 
                                         1 
                                       
                                       n 
                                     
                                      
                                     
                                         
                                     
                                      
                                     
                                       Q 
                                       i 
                                     
                                   
                                 
                                 - 
                                 
                                   Q 
                                   i 
                                 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               γ 
                               . 
                             
                             = 
                             
                               
                                 
                                   V 
                                   i 
                                   * 
                                 
                                 - 
                                 
                                   
                                     V 
                                     _ 
                                   
                                   od 
                                 
                               
                               = 
                               
                                 
                                   V 
                                   i 
                                   * 
                                 
                                 - 
                                 
                                   
                                     1 
                                     n 
                                   
                                    
                                   
                                     
                                       ∑ 
                                       
                                         i 
                                         = 
                                         1 
                                       
                                       n 
                                     
                                      
                                     
                                         
                                     
                                      
                                     
                                       V 
                                       odi 
                                     
                                   
                                 
                               
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     10 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (10), {dot over (φ)} i  represents the change rate of the small-signal state variable of reactive power ancillary of the ith distributed generation, unit: Var; Q i : represents the expected output reactive power of the ith distributed generation, unit: Var; n Qi  represents the voltage droop characteristic coefficient of the ith distributed generation, unit: V/Var;  γ  represents the change rate of the small-signal state variable for the voltage ancillary of the distributed generation, unit: V;  V   od  represents the average output voltage of all distributed generations, and V* i  represents the expected average voltage of the ith distributed generation, unit: V. 
     Therefore, an inverter closed-loop small-signal model based on output feedback is: 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   
                                     x 
                                     . 
                                   
                                   inv 
                                 
                               
                               = 
                               
                                 
                                   
                                     A 
                                     inv 
                                   
                                    
                                   Δ 
                                    
                                   
                                       
                                   
                                    
                                   
                                     x 
                                     inv 
                                   
                                 
                                 + 
                                 
                                   
                                     B 
                                     inv 
                                   
                                    
                                   Δ 
                                    
                                   
                                       
                                   
                                    
                                   
                                     V 
                                     bDQ 
                                   
                                 
                                 + 
                                 
                                   
                                     B 
                                     u 
                                   
                                    
                                   Δ 
                                    
                                   
                                       
                                   
                                    
                                   u 
                                 
                               
                             
                              
                             
                                 
                             
                           
                         
                       
                       
                         
                           
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   y 
                                   invQ 
                                 
                               
                               = 
                               
                                 
                                   C 
                                   invQ 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   x 
                                   inv 
                                 
                               
                             
                             , 
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   y 
                                   invV 
                                 
                               
                               = 
                               
                                 
                                   C 
                                   invV 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   x 
                                   inv 
                                 
                               
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     11 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (11), Δx inv  represents the closed-loop small-signal state variables of n inverters, Δx inv =[Δx invi , Δx inv2 , . . . , Δx invi , . . . , Δx invn , Δφ 1 , Δφ 2 , . . . , Δφ i , . . . , Δφ n , Δγ] T , Δφ 1  small-signal state variable of a reactive power ancillary of the first distributed generation, Δφ 2  represents the small-signal state variable of a reactive power ancillary of the second distributed Δφ 2  generation, Δφ i  represents the small-signal state variable of the reactive power ancillary of the ith distributed generation, Δφ n  represents the small-signal state variable of the reactive power ancillary of the nth distributed generation, and Δγ represents the small-signal state variable for voltage ancillary of distributed generations; Δy invQ  represents small-signal state variables of output reactive powers Δy invQ =[Δ{dot over (φ)} 1  Δφ 1  Δ{dot over (φ)} 2  Δφ 2  . . . Δφ n  Δφ n ], Δ{dot over (φ)} 1  represents the change rate of the small-signal state variable of the reactive power ancillary of the first distributed generation, Δ{dot over (φ)} 2  represents the change rate of small-signal state variable of the reactive power ancillary of the second distributed generation, and Δ{dot over (φ)} n  represents the change rate of small-signal state variable of the reactive power ancillary of the nth distributed generation; Δy invV  represents the small-signal state variables of the output voltage of the distributed generations, Δy invV =[Δ{dot over (γ)}, Δγ] T , and Δ{dot over (γ)} represents the change rate of small-signal state variable for the voltage ancillary of each distributed generation; C invQ  represents the output matrix of reactive power of distributed generations; and C invV  represents the output matrix of the voltages of distributed generations. 
     The control amount of the distributed generation is defined as: 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               
                                 δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   Q 
                                   i 
                                 
                               
                               = 
                               
                                 
                                   
                                     k 
                                     PQ 
                                   
                                    
                                   
                                     ( 
                                     
                                       
                                         Q 
                                         i 
                                         * 
                                       
                                       - 
                                       
                                         Q 
                                         i 
                                       
                                     
                                     ) 
                                   
                                 
                                 + 
                                 
                                   
                                     k 
                                     IQ 
                                   
                                    
                                   ϕ 
                                 
                               
                             
                              
                             
                                 
                             
                           
                         
                       
                       
                         
                           
                             
                               δ 
                                
                               
                                   
                               
                                
                               
                                 V 
                                 i 
                               
                             
                             = 
                             
                               
                                 
                                   k 
                                   PV 
                                 
                                  
                                 
                                   ( 
                                   
                                     
                                       V 
                                       * 
                                     
                                     - 
                                     
                                       
                                         V 
                                         _ 
                                       
                                       od 
                                     
                                   
                                   ) 
                                 
                               
                               + 
                               
                                 
                                   k 
                                   IV 
                                 
                                  
                                 γ 
                               
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     12 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (12), δQ i  represents the reactive power control signal of the ith distributed generation; k PQ  represents the proportional term coefficient in a reactive power proportional-integral controller; k IQ  represents the integral term coefficient in the reactive power proportional-integral controller; δV i  represents the average voltage recovery control signal of the ith distributed generation; k PV  represents the proportional term coefficient in the average voltage proportional-integral controller; and k IV  represents the integral term coefficient in the average voltage proportional-integral controller. 
     When a communication delay exists between a centralized voltage controller of the microgrid and each distributed generation, a voltage control amount is: 
       Δ ui =Δδ Qi ( t−τ   i )+Δδ Vi ( t−τ   i )= K   Qi   Δy   invQi ( t−τ   i )+ K   Vi   Δy   invV ( t−τ   i )  Formula (13).
 
     In formula (13), τ i  represents the communication delay between the local controller of the ith distributed generation and the centralized secondary voltage controller of the microgrid, unit: s; K Qi  represents the reactive power controller of the ith distributed generation, K Qi =[k PQi  k IQi ]; and K Vi  represents the voltage controller of the ith distributed generation, K Vi =[k PVi  k IVi ]. 
     By reference to formulas (11)-(13), the close-loop small-signal model of n distributed generations are obtained: 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               Δ 
                                
                               
                                   
                               
                                
                               
                                 
                                   x 
                                   . 
                                 
                                 inv 
                               
                             
                             = 
                             
                               
                                 
                                   A 
                                   inv 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   x 
                                   inv 
                                 
                               
                               + 
                               
                                 
                                   ∑ 
                                   
                                     i 
                                     = 
                                     1 
                                   
                                   n 
                                 
                                  
                                 
                                     
                                 
                                  
                                 
                                   
                                     
                                       A 
                                       _ 
                                     
                                     di 
                                   
                                    
                                   Δ 
                                    
                                   
                                       
                                   
                                    
                                   
                                     
                                       x 
                                       inv 
                                     
                                      
                                     
                                       ( 
                                       
                                         t 
                                         - 
                                         
                                           τ 
                                           i 
                                         
                                       
                                       ) 
                                     
                                   
                                 
                               
                               + 
                               
                                 
                                   B 
                                   inv 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   bDQ 
                                 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   i 
                                   oDQ 
                                 
                               
                               = 
                               
                                 
                                   C 
                                   invc 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   x 
                                   inv 
                                 
                               
                             
                              
                             
                                 
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     14 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (14), Ā dx  represents the delayed state matrix of the ith distributed generation, 
     Ā di =[0 . . . B ui K Qi C invQi +B ui K Vi C invV  . . . 0], B ui  represents the input matrix of the ith distributed generation to the small-signal control amount of the secondary voltage, C invQi  represents the output matrix of reactive power of the ith distributed generation, and C invc  represents the output matrix of the current of the distributed generation. 
     Step (20) Establish a microgrid small-signal model according to a connection network and a dynamic equation of load impedance 
     A current small-signal dynamic equation of a connection line ij between the bus connected to the ith distributed generation and the bus connected to the jth distributed generation in the common reference coordinate system DQ is shown as formula (15): 
     
       
         
           
             
                 
             
              
             
               Formula 
                
               
                   
               
                
               
                 ( 
                 15 
                 ) 
               
             
           
         
       
       
         
           
             { 
             
               
                 
                   
                     
                       
                         Δ 
                          
                         
                             
                         
                          
                         
                           
                             i 
                             . 
                           
                           lineDij 
                         
                       
                       = 
                       
                         
                           
                             - 
                             
                               
                                 r 
                                 lineij 
                               
                               
                                 L 
                                 lineij 
                               
                             
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             lineDij 
                           
                         
                         + 
                         
                           
                             ω 
                             0 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             lineQij 
                           
                         
                         + 
                         
                           
                             1 
                             
                               L 
                               lineij 
                             
                           
                            
                           
                             ( 
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busDi 
                                 
                               
                               - 
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busDj 
                                 
                               
                             
                             ) 
                           
                         
                       
                     
                   
                 
                 
                   
                     
                       
                         Δ 
                          
                         
                             
                         
                          
                         
                           
                             i 
                             . 
                           
                           lineQij 
                         
                       
                       = 
                       
                         
                           
                             - 
                             
                               
                                 r 
                                 lineij 
                               
                               
                                 L 
                                 lineij 
                               
                             
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             lineQij 
                           
                         
                         - 
                         
                           
                             ω 
                             0 
                           
                            
                           Δ 
                            
                           
                               
                           
                            
                           
                             i 
                             lineDij 
                           
                         
                         + 
                         
                           
                             1 
                             
                               L 
                               lineij 
                             
                           
                            
                           
                             ( 
                             
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busQi 
                                 
                               
                               - 
                               
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busQj 
                                 
                               
                             
                             ) 
                           
                         
                       
                     
                   
                 
               
               . 
             
           
         
       
     
     In formula (15), Δi lineDij  represents the change rate of a D-axis component of small-signal variable of the current of the ijth connection line in the common reference coordinate system DQ, unit: A/s; r lineij  represents the line resistance of the ijth connection line, unit: Ω; L lineij  represents the line inductance of the ijth connection line, unit: H; Δi lineDij  represents the D-axis component of small-signal variable of the current of the ijth connection line in the common reference coordinate system DQ, and Δi lineQij  represents the Q-axis component of small-signal variable of the current of the ijth connection line in the common reference coordinate system DQ, unit: A; ω 0  represents the rated angular frequency of the microgrid, unit: rad/s; ΔV busDi  represents the D-axis component of small-signal variable of the voltage of the bus connected to the ith distributed generation in the common reference coordinate system DQ; ΔV busDj  represents the D-axis component of small-signal variable of the voltage of the bus connected to the jth distributed generation in the common reference coordinate system DQ; Δi lineQij  represents the change rate of the Q-axis component of small-signal variable of the current of the ijth connection line in the common reference coordinate system DQ, unit: A/s; ΔV busQi  represents the Q-axis component of small-signal variable of the voltage of the bus connected to the ith distributed generation in the common reference coordinate system DQ, and ΔV busQj  represents the Q-axis component of small-signal variable of the voltage of the bus connected to the jth distributed generation in the common reference coordinate system DQ, unit: V. 
     A current dynamic equation of a load connected to the lth bus in the common reference coordinate system DQ is shown as formula (16): 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               Δ 
                                
                               
                                   
                               
                                
                               
                                 
                                   i 
                                   . 
                                 
                                 loadDt 
                               
                             
                             = 
                             
                               
                                 
                                   - 
                                   
                                     
                                       R 
                                       loadl 
                                     
                                     
                                       L 
                                       loadl 
                                     
                                   
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   i 
                                   loadDl 
                                 
                               
                               + 
                               
                                 
                                   ω 
                                   0 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   i 
                                   loadQl 
                                 
                               
                               + 
                               
                                 
                                   1 
                                   
                                     L 
                                     loadl 
                                   
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busDl 
                                 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               Δ 
                                
                               
                                   
                               
                                
                               
                                 
                                   i 
                                   . 
                                 
                                 loadQt 
                               
                             
                             = 
                             
                               
                                 
                                   - 
                                   
                                     
                                       R 
                                       loadl 
                                     
                                     
                                       L 
                                       loadl 
                                     
                                   
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   i 
                                   loadQl 
                                 
                               
                               - 
                               
                                 
                                   ω 
                                   0 
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   i 
                                   loadDl 
                                 
                               
                               + 
                               
                                 
                                   1 
                                   
                                     L 
                                     loadl 
                                   
                                 
                                  
                                 Δ 
                                  
                                 
                                     
                                 
                                  
                                 
                                   V 
                                   busQl 
                                 
                               
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     16 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (16), Δi loadD1  represents the change rate of D-axis component of small-signal variable of the current of the load connected to the lth bus in the common reference coordinate system DQ, unit: A/s; R load1  represents the load resistance of the load connected to the lth bus, unit: Ω; L load1  represents the load inductance of the load connected to the lth bus, unit: H; Δi loadDl  represents the D-axis component of small-signal variable of the current of the load connected to the lth bus in the common reference coordinate system DQ, and Δi loadQl  represents the Q-axis component of small-signal variable of the current of the load connected to the lth bus in the common reference coordinate system DQ, unit: A; and Δi loadQl  represents the change rate of Q-axis component of small-signal variable of the current of the load connected to the lth bus in the common reference coordinate system DQ, unit: A/s. 
     A small-signal equation of the connection line between the bus connected to the ith distributed generation and the bus connected to the jth distributed generation is set as formula (17): 
     
       
         
           
             
               
                 
                   { 
                   
                     
                       
                         
                           
                             
                               Δ 
                                
                               
                                   
                               
                                
                               
                                 V 
                                 busDj 
                               
                             
                             = 
                             
                               
                                 
                                   R 
                                   loadj 
                                 
                                  
                                 
                                   ( 
                                   
                                     
                                       Δ 
                                        
                                       
                                           
                                       
                                        
                                       
                                         i 
                                         oDj 
                                       
                                     
                                     + 
                                     
                                       Δ 
                                        
                                       
                                           
                                       
                                        
                                       
                                         i 
                                         lineDij 
                                       
                                     
                                     - 
                                     
                                       Δ 
                                        
                                       
                                           
                                       
                                        
                                       
                                         i 
                                         lineDij 
                                       
                                     
                                   
                                   ) 
                                 
                               
                               + 
                               
                                 
                                   L 
                                   loadj 
                                 
                                  
                                 
                                   [ 
                                   
                                     
                                       ( 
                                       
                                         
                                           Δ 
                                            
                                           
                                               
                                           
                                            
                                           
                                             i 
                                             oDj 
                                           
                                         
                                         + 
                                         
                                           Δ 
                                            
                                           
                                               
                                           
                                            
                                           
                                             i 
                                             lineDij 
                                           
                                         
                                         - 
                                         
                                           Δ 
                                            
                                           
                                               
                                           
                                            
                                           
                                             i 
                                             lineDij 
                                           
                                         
                                       
                                       ) 
                                     
                                     - 
                                     
                                       
                                         ω 
                                         0 
                                       
                                        
                                       
                                         ( 
                                         
                                           
                                             Δ 
                                              
                                             
                                                 
                                             
                                              
                                             
                                               i 
                                               oQj 
                                             
                                           
                                           + 
                                           
                                             Δ 
                                              
                                             
                                                 
                                             
                                              
                                             
                                               i 
                                               lineQij 
                                             
                                           
                                           - 
                                           
                                             Δ 
                                              
                                             
                                                 
                                             
                                              
                                             
                                               i 
                                               lineQij 
                                             
                                           
                                         
                                         ) 
                                       
                                     
                                   
                                   ] 
                                 
                               
                             
                           
                         
                       
                       
                         
                           
                             
                               Δ 
                                
                               
                                   
                               
                                
                               
                                 V 
                                 busQj 
                               
                             
                             = 
                             
                               
                                 
                                   R 
                                   loadj 
                                 
                                  
                                 
                                   ( 
                                   
                                     
                                       Δ 
                                        
                                       
                                           
                                       
                                        
                                       
                                         i 
                                         oQj 
                                       
                                     
                                     + 
                                     
                                       Δ 
                                        
                                       
                                           
                                       
                                        
                                       
                                         i 
                                         lineQij 
                                       
                                     
                                     - 
                                     
                                       Δ 
                                        
                                       
                                           
                                       
                                        
                                       
                                         i 
                                         lineQij 
                                       
                                     
                                   
                                   ) 
                                 
                               
                               + 
                               
                                 
                                   L 
                                   loadj 
                                 
                                  
                                 
                                   [ 
                                   
                                     
                                       ( 
                                       
                                         
                                           Δ 
                                            
                                           
                                               
                                           
                                            
                                           
                                             i 
                                             oQj 
                                           
                                         
                                         + 
                                         
                                           Δ 
                                            
                                           
                                               
                                           
                                            
                                           
                                             i 
                                             lineQij 
                                           
                                         
                                         - 
                                         
                                           Δ 
                                            
                                           
                                               
                                           
                                            
                                           
                                             i 
                                             lineQij 
                                           
                                         
                                       
                                       ) 
                                     
                                     + 
                                     
                                       
                                         ω 
                                         0 
                                       
                                        
                                       
                                         ( 
                                         
                                           
                                             Δ 
                                              
                                             
                                                 
                                             
                                              
                                             
                                               i 
                                               oDj 
                                             
                                           
                                           + 
                                           
                                             Δ 
                                              
                                             
                                                 
                                             
                                              
                                             
                                               i 
                                               lineDij 
                                             
                                           
                                           - 
                                           
                                             Δ 
                                              
                                             
                                                 
                                             
                                              
                                             
                                               i 
                                               lineDij 
                                             
                                           
                                         
                                         ) 
                                       
                                     
                                   
                                   ] 
                                 
                               
                             
                           
                         
                       
                     
                     . 
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     17 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (17), R loadj  and L loadj  respectively represent the resistance value and the inductance value of a load on the bus connected the jth distributed generation; and Δi oDj  and Δi oQj  respectively represent the D-axis component small-signal variable and Q-axis component of small-signal variable of the output current of the jth distributed generation in the common reference coordinate system DQ. 
     Formula (17) is substituted into formulas (14)-(16) to obtain the microgrid small-signal model comprising n distributed generations, s branches and p loads: 
     
       
         
           
             
               
                 
                   
                     x 
                     . 
                   
                   = 
                   
                     Ax 
                     + 
                     
                       
                         ∑ 
                         
                           i 
                           = 
                           1 
                         
                         n 
                       
                        
                       
                           
                       
                        
                       
                         
                           A 
                           di 
                         
                          
                         
                           
                             x 
                              
                             
                               ( 
                               
                                 t 
                                 - 
                                 
                                   τ 
                                   i 
                                 
                               
                               ) 
                             
                           
                           . 
                         
                       
                     
                   
                 
               
               
                 
                   Formula 
                    
                   
                       
                   
                    
                   
                     ( 
                     18 
                     ) 
                   
                 
               
             
           
         
       
     
     In formula (18), x represents the microgrid small-signal state variables, x=[Δx inv  Δi lineDQ  Δi loadDQ ] T , Δi lineDQ  represent the small-signal state variables of the current of the connection lines between the buses connected to the distributed generations in the common reference coordinate system DQ, and Δi loadDQ  represent the small-signal state variables of the current of the loads connected to the buses in the common reference coordinate system DQ; {dot over (x)} represents the change rate of the microgrid small-signal state variables; A represents the microgrid state matrix; A di  represents the delayed state matrix of the ith distributed generation; and τ i  represents the delay of the ith distributed generation. 
     Step (30) Obtain a characteristic equation with a transcendental term of a microgrid closed-loop small-signal model 
     When the delays of all the distributed generations are consistent, a characteristic equation of formula (18) is formula (19): 
         CE   τ ( s ,τ)=det( sI−A−A   d   e   −τs )  Formula (19).
 
     In formula (19), s represents the parameter of the time domain complex plane; r represents the consistent delay time of each distributed generation, τ 1 =τ 2 = . . . =τ n , unit: s; det(⋅) represents the matrix determinant; I represents the unit matrix; A d  represents the delayed state matrix of the distributed generation, A d =Σ i=1   n A di ; and e −τs  represents the transcendental term. 
     Step (40) Carry out critical characteristic root locus tracking for the transcendental term of the system characteristic equation to calculate the system stability margin For formula (19), if all system characteristic roots are on the left half of a complex plane, the system is stable; if there are characteristic roots on the right half of the complex plane, the system is unstable; and if there are characteristic roots on the left half of the complex plane or the imaginary axis, the system is critically stable. Because the system characteristic roots continuously change along with the delay time τ, in order to determine the system stability margin Td, that is, the system is stable if r is less than Td, and is unstable if r is greater than Td, the possible pure virtual characteristic roots and the corresponding delay margin need to be determined. 
     ξ=τω is defined and substituted into formula (19), and then, 
         CE   ξ ( s ,ξ)=det( sI−A−A   d   e   −iξ )  Formula (20).
 
     Where, ξ represents the delay time ancillary variable, and ω represents the virtual characteristic root amplitude; here, i represents the imaginary unit, and i 2 =−1. ξ changes within the cycle of [0, 2π], so that corresponding characteristic roots of formula (20) are obtained. If there are pure virtual characteristic roots corresponding to certain ξ then a critical delay time is: 
       τ c =ξ c /abs(ω C )  Formula (21).
 
     In the formula, ξ c  represents the delay time ancillary variable for the existence of pure virtual characteristic roots in the system, abs(ωc) represents the amplitude of the corresponding pure virtual characteristic root, and τ c  represents the critical delay time. 
     When ξ changes within the cycle of [0, 2π], there may be a plurality of critical delay times in the system, i.e. τ c1 , τ c2  . . . τ cL , and the minimum value τ d  is selected as the delay margin: 
       τ d =min(τ c1  τ c2  . . . τ cL )  Formula (22).
 
     In the aforementioned embodiment, the common reference coordinate system DQ refers to the reference coordinate system dq of the first distributed generation, and the state variables of the other distributed generations, branch currents and load currents are transformed into the common reference coordinate system DQ by the transformation of coordinates. In step (10), because the proportional term coefficients in the proportional-integral controller of reactive power and the proportional-integral controller of the voltage are small, in practice, the proportional-integral controller of reactive power and the proportional-integral controller of the voltage can be respectively simplified into an integral controller of reactive power and an integral controller of voltage. In step (20), the loads are impedance type loads. 
     In the present embodiment, by introducing the microgrid closed-loop small-signal model of signal communication delay time, a system characteristic equation with a transcendental term is established, and thereby the microgrid delay margin calculation method based on critical characteristic root tracking is implemented. Aimed at the conventional microgrid secondary control method which neglects the influence of the communication delay on the dynamic performance of the system, the present embodiment works out a maximum delay time for maintaining the system stable in full consideration of the actual situation that the influence of the communication delay on system stability cannot be neglected due to the low inertia of power electronic interfaced microgrid. By analyzing the relationship between different controller parameters and delay margins, the delay margin calculation method of the present embodiment guides the design of the controllers, thus improving the stability and dynamic performance of the system. 
     The block diagram of the microgrid control system in the embodiment of the present invention is shown as  FIG. 2 . The control block diagram mainly comprises two layers: the first layer is the local controller of each distributed generation, which consists of power calculation, droop control, and a voltage and current double loop; and the second layer is the secondary voltage control layer, which realizes reactive power sharing and average voltage recovery. The centralized secondary voltage controller acquires the output voltage and output reactive power of each distributed generation, works out the secondary voltage control amount of each distributed generation, then sends a control instruction into each local controller. In the process of sending the control instruction, a communication delay exists between the centralized secondary voltage controller and the local controller of each distributed generation, and this delay affects the dynamic performance of the system. 
     The following exemplifies an embodiment. 
     A simulation system is shown as  FIG. 3 , a microgrid consists of two distributed generations, two connection lines, and three loads, the load  1  is connected to bus  1 , the load  2  is connected to bus  2 , and the load  3  is connected to bus  3 . In the system, impedance type loads are adopted as the loads. If the capacity ratio of the distributed generation 1 and the distributed generation 2 is 1:1, then corresponding frequency droop coefficient and voltage droop coefficient are designed to make the ratio of the expected output active power and reactive power of two distributed generations be equal to 1:1. Theoretical delay margins of the microgrid under different controller parameters are studied, and a microgrid simulation model is established based on an MATLAB/Simulink platform to simulate and verify the theoretical delay margins. 
       FIG. 4  is the schematic diagram of critical characteristic root locus tracking associated with system stability under controller parameters (k IQ =0.02, k IV =20). A communication delay ancillary variable ξ change within [0, 2π], two pairs of conjugate characteristic roots are closely related to system stability, four critical characteristic roots A(jω c1 ), A′(−jω c1 ), B(jω c2 ) and B′(jω c2 ) passing through the imaginary axis of a complex plane and corresponding ξ are recorded, and a delay margin τd=0.05888 s is worked out according to formula (21) and formula (22). 
       FIG. 5  is the relationship between the microgrid delay margin calculated based on critical characteristic root tracking and the controller parameters under the controller parameters (0.005≤k IQ ≤0.06, 5≤k IV ≤60) in the embodiment of the present invention. It can be known from the drawing that with an increase in the integral coefficient k IQ  of the reactive power controller and the integral coefficient k IV  of the voltage controller, the delay margin of the system decreases. That is, the robust stability of the system reduced. Therefore, when different combinations of controller parameters achieve similar dynamic performance, the delay margin will serve as an additional robust stability index to guide the design of the controller parameters, providing the system with stability and dynamic performance. 
       FIG. 6  is the simulation result of a decentralized control method for the influence of three different communication delays on the dynamic performance of the system under a certain set of controller parameters (k IQ =0.02, k IV =20) of the microgrid according to the embodiment of the present invention. When the system is started, each distributed generation operates under a droop control mode, and at 0.5 s, secondary voltage control is put into operation. A simulation result is shown as  FIG. 6 ,  FIG. 6A  is an average voltage curve graph of the distributed generation in the microgrid, the X axis represents time, unit: s, and the Y axis represents average voltage, unit: V. W. As shown in  FIG. 6A , at the beginning, under the effect of droop control, a steady-state deviation exists in the average voltage of the distributed generations, and after 0.5 s, under the effect of secondary control, the voltage amplitude increases. It can be known from  FIG. 6A  that when no communication delay exists in the system, the average voltage is so smooth as to reach a rated value; when the delay time is 53 ms, the voltage curve experiences decreased oscillation and restores; when the delay time is 61 ms, the curve experiences increasing oscillation, and the system is unstable.  FIG. 6B  is a reactive power output curve graph of the distributed generation 1, unit: s, and the Y axis represents reactive power, unit: Var. It can be known from  FIG. 6B  that at the beginning, under the effect of droop control, the reactive power sharing effect is not satisfactory (less than the expected output reactive power value of the distributed generation 1), and after 0.5 s, under the effect of secondary control, reactive power output is increased. It can be known from  FIG. 6B  that when no communication delay exists in the system, the reactive power is so smooth as to reach an expected value; when the delay time is 53 ms, the power curve experiences decreased oscillation and reaches the control target; when the delay time is 61 ms, the curve experiences increasing oscillation, and the system is unstable. Under the effect of secondary control, the reactive power sharing effect of the microgrid is significantly improved.  FIG. 6C  is a reactive power output curve graph of the distributed generation 2, unit: s, and the Y axis represents reactive power, unit: Var. It can be known from  FIG. 6C  that at the beginning, under the effect of droop control, the reactive power sharing effect is not satisfactory (higher than an expected output reactive power value of the distributed generation 2), and after 0.5 s, under the effect of secondary control, reactive power output is decreased. It can be known from  FIG. 6C  that when no communication delay exists in the system, reactive power is so smooth as to reach an expected value; when the delay time is 53 ms, the power curve experiences decreased oscillation and reaches a control target; when the delay time is 61 ms, the curve experiences increasing oscillation, and the system is unstable. It can be known from  FIG. 6  that the delay margin of the system under the controller parameters is between 53 ms and 61 ms, and is consistent with a theoretical calculated value. 
       FIG. 7  is the simulation result of a decentralized control method for the influence of three communication delays on the dynamic performance of the system under a certain set of controller parameters (k IQ =0.04, k IV =40) of the microgrid according to the embodiment of the present invention. When operation is started, each distributed generation operates under a droop control mode, and at 0.5 s, secondary voltage control is put into operation. A simulation result is shown as  FIG. 7 ,  FIG. 7A  is the average voltage curve graph of the distributed generations in the microgrid, the X axis represents time, unit: s, and the Y axis represents average voltage, unit: V. W. As shown in  FIG. 7A , at the beginning, under the effect of droop control, a steady-state deviation exists in the average voltage of the distributed generations, and after 0.5 s, under the effect of secondary control, the voltage amplitude increases. It can be known from  FIG. 7A  that when no communication delay exists in the system, the average voltage is so smooth as to reach a rated value; when the delay time is 25 ms, the voltage curve experiences decreased oscillation and restores; when the delay time is 33 ms, the oscillation of the curve experiences increasing oscillation, and the system is unstable.  FIG. 7B  is the reactive power output curve graph of the distributed generation 1, unit: s, and the Y axis represents reactive power, unit: Var. It can be known from  FIG. 7B  that at the beginning, under the effect of droop control, the reactive power sharing effect is not satisfactory (less than an expected output reactive power value of the distributed generation 1), and after 0.5 s, under the effect of secondary control, reactive power output is increased. It can be known from  FIG. 6B  that when no communication delay exists in the system, reactive power is so smooth as to reach an expected value; when the delay time is 25 ms, the power curve reaches a control objective due to decreased oscillation; when the delay time is 33 ms, the oscillation of the curve is increased, and the system is unstable. Under the effect of secondary control, the reactive power sharing effect of the microgrid is significantly improved.  FIG. 7C  is the reactive power output curve graph of the distributed generation 2, unit: s, and the Y axis represents reactive power, unit: Var. It can be known from  FIG. 7C  that at the beginning, under the effect of droop control, the reactive power sharing effect is not satisfactory (higher than an expected reactive power output value of the distributed generation 2), and after 0.5 s, under the effect of secondary control, reactive power output is decreased. It can be known from  FIG. 7C  that when no communication delay exists in the system, reactive power is so smooth as to reach an expected value; when the delay time is 25 ms, the power curve experiences decreased oscillation and reaches the control target; when the delay time is 33 ms, the curve experiences increasing oscillation, and the system is unstable. It can be known from  FIG. 6  that the delay margin of the system under the controller parameters is between 25 ms and 33 ms, and is consistent with a theoretical calculated value. 
     The method of the embodiment of the present invention is a microgrid delay margin calculation method based on critical characteristic root tracking, by which the microgrid closed-loop small-signal model including communication delay is established based on the output feedback method, and the maximum delay time for a stable system, i.e. the delay margin is analyzed. Aimed at the conventional microgrid secondary control method which neglects the influence of communication delay on the dynamic performance of the system, the present embodiment takes the influence of communication delay on system stability into full consideration, and in addition, by studying the relationship between different controller parameters and delay margins, the design of the controllers is guided, thus improving the robust stability and dynamic performance of the microgrid.