Optimal Control Virtual Inertia of Optical Storage Microgrid Based on Improved Sailfish Algorithm

: The optical storage microgrid system composed of power electronic converters is a small inertia system. Load switch‐ ing and power supply intermittent will affect the stability of the di‐ rect current (DC) bus voltage. Aiming at this problem, a virtual in‐ ertia optimal control strategy applied to optical storage microgrid is proposed. Firstly, a small signal model of the system is estab‐ lished to theoretically analyze the influence of virtual inertia and damping coefficient on DC bus voltage and to obtain the con‐ straint range of virtual inertia and damping coefficient; Secondly, aiming at the defect that the Sailfish optimization algorithm is easy to premature maturity, a Sailfish optimization algorithm based on the leak-proof net and the cross-mutation propagation mechanism is proposed; Finally, the virtual inertia and damping coefficient of the system are optimized by the improved Sailfish algorithm to obtain the best control parameters. The simulation re‐ sults in Matlab/Simulink show that the virtual inertia control opti‐ mized by the improved Sailfish algorithm improves the system in‐ ertia as well as the dynamic response and robustness of the DC bus voltage.


Introduction
Digital technology is leading the development and evolution of the Fourth Industrial Revolution and promoting industrial digital transformation. Promoting the deep integration of advanced digital technologies and power grids is an important way for the digital transformation of power grids [1,2] . The shortage of fossil energy and environmental problems have accelerated the development of new power technologies for distributed generation based on renewable energy [3] . The rapid development of microgrids has laid the physical foundation for the digital transformation of energy, interconnectivity, and mesh coverage [4,5] . At present, on the power generation side, the output of mainstream photovoltaic units and energy storage units are all direct current (DC); on the power consumption side, the high-frequency devices in the market, such as electric vehicles, mobile phones, and LEDs, are all DC loads. In the optical storage microgrid, there is no need to consider issues such as phase and reactive power, and the high-frequency DC-DC converter greatly reduces the space. The construction of the optical storage microgrid can effectively reduce the conversion loss of electric energy in the converter, and provide a great physical help for the development of the digital microgrid. The optical storage microgrid system composed of power electronic converters is a small inertial system. The load switching in the system and the intermittent power output will lead to violent fluctuations in the DC bus voltage, which in turn affects the safe and stable operation of the microgrid system [6] . The energy Article ID 1007-1202(2022)03-0218-13 DOI https://doi.org/10.1051/wujns/2022273218 storage unit in the microgrid plays an important role in stabilizing the bus voltage of the DC microgrid [7] . Appropriate control improvements on the basis of the droop control can effectively enhance the inertial support of the DC microgrid system. Virtual synchronous generator control (VSG) provides inertial support for the system by simulating the rotor characteristics of traditional synchronous motors. At present, the application research of this control in the alternating current (AC) system has been relatively mature.
Wu et al [8] proposed a virtual inertia control strategy for bidirectional grid-connected converters of DC microgrid by analogy with the virtual inertia of AC microgrid. This strategy can effectively solve the stability problem caused by constant power load, but its control parameters are not adaptive. In the process of digitalization of the power grid, intelligent control is an important part. In order to realize the intelligent control of the control parameters, Ren et al [9] used the voltage fluctuation rate as a function variable, and carried out an adaptive function design for the virtual inertia and damping coefficient; Yang et al [10] added the voltage deviation to the adaptive function variable; Karimi et al [11] used fuzzy control to adaptively design the virtual inertia and damping coefficient. The above self-adaptive design is obtained from the analysis of the voltage fluctuation curve of the system disturbance. This method has fuzzy characteristics. It can only be adjusted by experience in the simulation project, and it is difficult to achieve digital accuracy.
Swarm intelligence optimization algorithm is a powerful tool to provide solutions to complex problems by simulating the behavior of some special groups in nature, and it has been widely used in many fields [12][13][14][15] . Injecting intelligent algorithms into VSG control can inject vitality into the development of digital power grids. Li et al [16] used the multi-objective particle swarm optimization algorithm to obtain the optimal inertia and damping coefficient of VSG control in AC system; Cheng et al [17] added the elimination mechanism to optimize the particle swarm optimization, which further improved the accuracy of particle swarm optimization; Yao et al [18] proposed a virtual inertial control based on neural network. Different from the engineering experience dependence of fuzzy control, the virtual inertial parameter design is realized by means of intelligent algorithm, which makes the virtual inertial control more accurate. However, the intelligent virtual inertial control of the above intelligent algorithm is applied to the AC system. This paper takes the bidirectional DC/DC converter with the energy storage unit connected to the optical storage microgrid as the research subject, obtains the virtual inertial control suitable for the bidirectional DC/DC converter through the analogy of the virtual inertial control of the AC system, then uses the improved AC sailfish optimization algorithm (ACSFO) to optimize virtual inertia and damping coefficients. Firstly, a small-signal model is established, and the stability constraints of the virtual inertia and damping coefficient are analyzed by means of the transfer function Bode diagram; Secondly, the sailfish algorithm is improved by integrating the anti-leakage net strategy and the vertical and horizontal crossover variation propagation mechanism, and the validity of the algorithm is verified and analyzed by using the highdimensional test function. After verification, the improved sailfish optimization algorithm is used to obtain the optimal solution of virtual inertia and damping coefficient. Finally, the optimal control strategy of virtual inertia and damping coefficient based on the improved sailfish algorithm proposed in this paper is simulated by Matlab/Simulink, then the simulation results are used to verify its effectiveness and the correctness of theoretical analysis. Figure 1 shows the topology of the optical storage microgrid studied in this paper, which is mainly composed of photovoltaics, energy storage units, AC loads, DC loads and corresponding power electronic converters. The whole system uses the DC bus as the medium to exchange energy through the corresponding power electronic converters. The inverter connected to the photovoltaic unit uses maximum power point tracking to make full use of the new energy. The AC and DC loads are connected to the DC bus through a one-way voltage reducer. The energy storage unit is connected to the DC bus through a bidirectional DC/DC converter. The equivalent circuit diagram of the converter is shown in Fig. 2. The converter adopts VSG control and uses the improved sailfish algorithm to improve the virtual inertia and damping coefficient to achieve optimal control, which can improve system inertia as well as the dynamic response of DC bus voltage.

The Principle of VSG Control
The active power-frequency control of the VSG in the inverter in the AC system is to improve the inertia of the system by simulating the rotor motion characteristics of the synchronous generator. The specific expression obtained from the simulation is where P ref , P 0 are the reference active power and output power, ω , ω n are the angular frequency and rated angular frequency, and D, J are the damping coefficient and virtual inertia, respectively. According to the control analogy analysis of the AC system and the DC system in Ref. [13], the corresponding relationship of the parameters can be obtained, as shown in Table 1.
According to the parameter correspondence in Table 1, the virtual inertia control of the bidirectional DC/DC converter applied to the optical storage microgrid can be obtained, and its expression is where i ref is the reference output current, C v and D v are the virtual inertia and damping coefficient respectively, u * DC is the reference value of the DC bus voltage, and u ref is the rated value of the DC bus voltage. The bidirectional DC/DC converter connected to the energy storage unit adopts the control method of formula (2), which can increase the inertia and damping characteristics on the basis of the droop control. When the DC bus voltage changes suddenly, the virtual inertia C v can quickly simulate the output current and enhance the inertial support of the system. When the DC bus voltage unit is changed, D v describes the active power change of the control output, and the damping coefficient can speed up the recovery of the DC bus voltage.
The bidirectional DC/DC virtual inertial control block diagram of the optical storage microgrid established according to the VSG control is shown in Fig. 3. Its control consists of three parts: droop control, virtual inertia control and voltage and current double closedloop control to stabilize the DC bus voltage.

Small Signal Modeling
In order to obtain the optimal configuration of virtual inertia and damping parameters through the ACSFO algorithm, a small-signal model is established for the scenario where VSG control is applied to a bidirectional DC/DC converter. Constraints of relevant control parameters are obtained by small signal analysis.
According to Fig. 2, the small signal model of the bidirectional DC/DC converter is where ûd c , ib, d, id c , ûb are the disturbance of the DC bus voltage u dc , the output current of the energy storage unit i b , the duty cycle d, the output current of the converter i dc , and the output voltage of the energy storage unit u b , respectively; and U dc , I b , D are the steady-state values of u dc , i b , d, respectively. From formula (3), after substituting the steady-state operating point, its system transfer function is ì where R L is the load resistance value.

PI Parameter Setting
In order to eliminate the influence of the proportional-integral (PI) parameters of the controller on the stability, it is necessary to design the PI parameters of the voltage and current double closed-loop control. The proportional and integral parameters of the current inner loop are k ip , k ii , and the current inner loop compensation function is G i = k ip + k ii /s.The proportional and integral parameters of the voltage outer loop are k vp , k vi , and the voltage outer loop compensation function is G v = k vp + k vi /s. The switching frequency of the converter is 50 kHz, and the cut-off frequency of the current loop is set to 20% of the switching frequency. The obtained Bode diagram of the current inner loop correction is shown in Fig. 4.
The designed current inner loop PI values are 0.068 02 and 2 467.4, respectively. It can be seen from Fig. 4 that the crossover frequency after system correction is 10 kHz, and the phase angle margin is 60°, which meets the requirements of the system stability.
The cut-off frequency of the voltage loop is set to 4% of the switching frequency, and the resulting Bode diagram of the voltage outer loop correction is shown in Fig. 5.
The designed voltage outer loop PI values are 32.881 8 and 22 431.8, respectively. It can be seen from Fig. 5 that the crossover frequency after system correction is 2 kHz, and the phase angle margin is 60°, which meets the requirements of the system stability.

Virtual Inertia and Damping Coefficient Stability Constraints
From Eq. (4), we can know that the small signal model of the VSG equation is: From Fig. 3, the transfer function of the output voltage deviation to the output current deviation after adding VSG control can be obtained as: Substituting Table 4 and the designed double closed-loop PI value into the transfer function can obtain the Bode diagram when the virtual inertia and damping coefficient change, as shown in Fig. 6 and Fig. 7.
From Fig. 6, when D v increases within a certain interval, its phase margin decreases and the system cut-off frequency decreases, so the increase of the damping coefficient will reduce the system stability. When D v =30,

Fig. 4 Bode diagram of current inner loop correction
G i : the current inner loop compensation function; G id : Bode diagram before compensation; G l : Bode diagram after compensation

Fig. 5 Bode diagram of voltage outer loop correction
G v : the voltage outer loop compensation function; G 3 : Bode diagram before compensation; G 4 : Bode diagram after compensation the phase margin is 39.6°. In engineering, the phase margin is generally 40°to 60°as the system stability criterion. From Fig. 7, when C v increases within a certain interval, its phase margin remains unchanged, and the system cut-off frequency remains unchanged, which does not affect the system stability. Therefore, the increase of virtual inertia within a certain range will not reduce the system stability. However, if the virtual inertia exceeds a certain value, the phase margin will decrease rapidly and the system will become unstable.
For the virtual inertia and damping coefficient, the limit range of the phase margin of 40°to 60°in engineering can be used as a constraint for the subsequent optimization of the algorithm to ensure its stability.

Droop Coefficient Stability Constraint
It can be seen from Fig. 3 that the transfer function of output voltage deviation to output current deviation under simultaneous droop control is where k d is the droop coefficient. It can be seen from the above formula that as k d increases, both the virtual inertia and the damping coefficient are reduced. It can be seen from Fig. 5 that if the damping coefficient is too low, the phase margin will be reduced, and the system will become unstable. Considering the need to improve the inertial support and stable operation of the system, a smaller droop coefficient should be selected. Considering the current power limit of the converter and the fluctuation range of the DC bus voltage, the design formula of the droop coefficient is where i max is output maximum current for the converter, and Du dc_m is the maximum value of DC bus voltage fluctuation. The output current of the converter is limited by its capacity, and a better droop coefficient can be designed by using formula (8).

Basic Sailfish Optimization Algorithm
The sailfish algorithm simulates the alternate hunting of sailfish in groups of sardines [19] . First, the sardine and sailfish populations are randomly initialized; Second, the sailfish uses the attack alternately to break the collective defense of the sardines; Finally, the sailfish catches suitable sardines through hunting to complete the position optimization.
1) Sailfish location update Sailfish adopts the method of attack substitution in the hunting process, and learns in coordination with each other during the attack process. The position update formula is as follows: where X i oldSF is the current position of the sailfish, X i newSF is updated position for sailfish, and X i eliteSF is elite sailfish that the closest to the prey with the best fitness, X i injuredS is injured sardine with optimal fitness, rand(01) is a random number from 0 to 1, and λ i is the iteration coefficient of the i-th iteration as in formula (10) where PD is the prey density, and its variation formula is where N SF , N S are the numbers of sailfish and sardines, respectively. The number of sailfish is expressed as: N SF = N*Percent (12) where N is the total number of sailfish and sardine populations, and Percent is the proportion of sailfish in the total population.
2) Sardine location update When the sardine is attacked, its position update formula is: where X i oldS , X i newS are the current and updated positions of the sardines, respectively, r is a random number from 0 to 1, and AP is the best attack power for sailfish. The attack power of the sailfish will decrease with the number of iterations, which is expressed as: where t is the current number of iterations, and A and e control the conversion of attack power. The attack strength changes linearly from A to 0, and the reduction of the sailfish attack strength can speed up the convergence. When AP > 0.5, we should update all the positions of the sardines with formula (5); when AP < 0.5 , we should update the sardine section location. Locations are represented as: where α is the number of sardines to update, β is the number of dimensions to update, and d i is the number of variables.

3) Predation stage
During the final phase of the hunt, sardines injured by a sailfish attack during an iteration are quickly caught by the sailfish, in which the sailfish will update to the sardine's location as soon as it kills the sardine. Its position update formula is as follows: where X i SF , X i S are the current positions of sailfish and sardines, and f (SF i ), f (S i ) are the fitness of sailfish and sardines, respectively.

Improvement of Sailfish Optimization Algorithm
Compared with other swarm intelligence algorithms, the sailfish algorithm has good convergence speed and optimization accuracy, but it is easy to lag and fall into a local optimal state during the convergence process. In order to speed up the convergence, improve optimization accuracy, and enhance the optimal configura-tion effect for virtual inertia and damping coefficient, the following three improvement methods are proposed.
1) Cubic mapping initializing the population Population initialization affects the convergence speed and accuracy of the algorithm. Using random numbers to generate the initialized population does not have good ergodicity, and the population will appear local aggregation, which will affect the performance of the algorithm. Cubic mapping is conducted with excellent maximum Lyapunov exponent and excellent ergodic performance. Its expression is as follows: where ρ is the control parameter. In mapping, x 0 takes a random number between 0 and 1. Experimental analysis shows that the best condition is ρ= 2.95. The simulation is performed according to formula (18), and the simulation results are shown in Fig. 8. Compared with random distribution, the sequence distribution generated based on Cubic mapping is more uniform.
2) Anti-leakage net strategy based on selftriggering mechanism Sailfish keeps approaching the injured individual sardines during the iterative process and attacks them in a single way during the hunting process. During predation, some fast-moving sardines could not avoid escaping, which leads to the premature maturity of the algorithm; and as the number of iterations of the algorithm increases, sailfish populations will gather around the current optimal solution, causing the algorithm s falling into a local optimum.
In order to improve the predation efficiency of sailfish and avoid getting stuck in local optima, this paper proposes a self-triggering mechanism of the anti-leakage net strategy. After the sailfish is updated according to formula (9), the anti-leakage net strategy is used to perturb the position of the sailfish. The expression of the anti-leakage net strategy is as follows: where r 1 , r 2 is a random number from 0 to 1, ub, lb are the upper and lower bounds of the search space, respectively, p is a scaling factor that decreases linearly from 1 to 0 with the number of iterations, and β is the expansion factor. In formula (19), when r 2 < β, we reinitialize the current individual, expand the search range of the sailfish population in the global space, prevent sardines from escaping the encirclement, and prevent the algorithm from falling into local optimum. When r 2 > β, the individual sailfish will move to the vicinity of the current position in the proportion of p, get rid of the attraction of some sardines in a small range, and jump out of the local extreme value. The linearly decreasing p combines the characteristics that the sailfish algorithm needs a largescale search in the early stage of iteration and a smallscale fine-scale search in the later stage of the iteration, which enhances the algorithm s optimization ability.
In the anti-leakage net strategy, it will reinitialize the current individual when r 2 < β. The larger the value of β, the greater the probability of re-initialization, and it is difficult to avoid the decrease of the algorithm solving efficiency at this time. In order to solve the problem that the fixed β value leads to the decrease of algorithm solving efficiency, this paper adopts a dynamically changing β, and the formula is as follows: where β will increase with the increase of the number of iterations, so the anti-leakage net strategy will move proportionally with a greater probability in the early stage of the iteration, and the anti-leakage net will increase the probability of re-initialization accordingly in the later stage of the iteration so as to avoid the decline of population diversity.
Considering that adopting the anti-leakage net strategy in each iteration will increase the running burden of the algorithm, a self-triggering mechanism is embedded to improve the burden of running the algorithm. Its expression is: where γ max , γ min are the maximum value and the minimum value of the trigger factor γ, respectively (The preset maximum is 0.8 and the minimum is 0.2). When the random number is rand(01)< γ, the anti-leakage net strat-egy is triggered; otherwise, the anti-leakage net strategy is not used. δ(δ ≥ 1) is the adjustment factor. The self-triggering curve is shown in Fig. 9. Compared with the linear increment (δ = 1), the nonlinear increment method (δ > 1) has a slow growth of the γ value and a lower trigger probability in the initial stage of the algorithm iteration, which ensures the convergence speed in the early stage of the iteration. In the later stage of the iteration, γ becomes larger and grows rapidly, and the trigger probability increases. At this time, the sailfish will escape from the local extreme value space through the anti-leakage net strategy so as to avoid falling into the premature algorithm in the later stage of the iteration. The degree of concaveness of the nonlinear increasing function can be adjusted by δ. If the algorithm appears premature, δ can be appropriately reduced to improve the trigger probability in the early stage of iteration and avoid the algorithm from falling into local optimum.

3) Cross mutation propagation mechanism
To further adapt the algorithm to complex environments and to fully improve its global development ability and local exploration ability, this paper proposes a cross-mutation propagation mechanism to improve the sailfish search method through the horizontal crossinformation propagation mechanism to allow sufficient information dissemination among individuals, and at the same time refers to elite individual information to avoid blind learning among individuals, which ensures the optimization efficiency while improving the optimization accuracy. The vertical cross-variation is to carry out cross-variation in different dimensions of the individual so as to prevent the individual from falling into the local optimum due to a stagnant dimension, and to improve The horizontal cross information dissemination mechanism can effectively allow two individuals(i and j) to learn from each other and produce high-quality offspring. The specific improved crossover operation is as follows: where MSX id oldSF , MSX jd oldSF are the d-dimension individuals generated by the sailfish individual X jd oldSF , X id eliteSF and the reference sailfish elite individual, r 3 , r 4 are random numbers from 0 to 1, and c 1 , c 2 are random numbers of [-1,1]. The individuals generated by the horizontal crossover operation need to be preserved with the parent.
The vertical crossover operation mainly mutates one of the dimensions, allowing the dimensions to learn from each other so as to avoid the parental individual from falling into a local optimum due to the stagnation of a certain dimension. The specific mutation methods are as follows: MSX id oldSF = r 5 *X id 1 oldSF + (1r 5 )*X jd 2 oldSF (24) where MSX id oldSF is the offspring individual generated by d 1 and d 2 of the individual through longitudinal variation; r 5 is a random number between 0 and 1. The progeny and parent of the longitudinal variation are preferentially preserved. Through the preferential mechanism, the optimal dimension information in the individual sailfish can be retained and the stagnant dimension information can be removed to improve the population diversity.
The excellent individual information generated by the vertical mutation will be spread to other individuals through the horizontal crossover operation, and the activity of the whole population will be improved. The crossoptimization of the population through the crossmutation propagation mechanism improves the activity of the population, enhances the ability to jump out of the local optimum, and further improves the convergence speed and the performance of solving complex optimization problems.

ACSFO Algorithm Optimization Test
In order to test the effect of ACSFO algorithm on function optimization, this paper compares ACSFO algorithm with 4 classical intelligent algorithms (Particle Swarm Optimization (PSO) algorithm, Multi-Verse Optimizer (MVO) algorithm, Grey Wolf Optimizer (GWO) algorithm, Moth-flame optimization (MFO) algorithm) and the original sailfish optimization algorithm SFO in 4 typical test functions. The optimization is carried out in the test function. The four groups of test functions are shown in Table 2. The F 1 and F 3 test functions are shown in Fig. 10. The population size is 30, the dimension is set to 30, and the maximum number of iterations is set to 500 times. In order to avoid randomness, each algorithm is optimized 30 times. Taking the average fitness value of 30 calculations as the ordinate, and the number of iterations as the abscissa, the function convergence curve is shown in Fig. 11.  It can be seen from Fig. 10 that F 1 is a multidimensional single-peak test function, which can test the global optimization ability of the algorithm, and F 3 is a multi-dimensional multi-peak test function, which can test the algorithm s ability to jump out of the local optimum.
From the convergence curves of F 1 , F 2 , F 3 and F 4 , it can be seen that, ACSFO has a great improvement in convergence speed and optimization accuracy compared with SFO. From F 2 , F 3 , and F 4 , it can be clearly seen that the initialization of the population based on the Cubic map makes the generated initial value closer to the optimal solution and improves the diversity of the search space. F 1 , F 2 , F 3 , and F 4 found the optimal solution, indicating that after introducing the anti-leakage net strategy based on the self-triggering mechanism, the sailfish can expand the hunting range during the alternate hunting process, enhance the sailfish search ability, and avoid falling into the local optimum. It can be seen from F 1 , F 2 and F 4 that in the later stage of the iteration, there is a tendency to fall into the local optimum. The addition of the horizontal cross-propagation mechanism makes the convergence speed faster, and the addition of the vertical cross-mutation makes the stagnant dimension jump out of the local area. It can be clearly seen from F 3 and F 4 that the algorithm stagnates at 300 and 290 iterations respectively, and vertical cross-mutation avoids the defect of dimensional iteration stagnation, and then quickly finds the optimal solution.
It can be seen that the ACSFO algorithm has a great improvement in the SFO algorithm, and its convergence speed and optimization accuracy are improved. Compared with other classical intelligent algorithms, it also has very superior optimization performance.

Fitness Function Design
The fitness function used to evaluate the position of the particle can guide the search direction of the algorithm, and plays a key role in the optimization algorithm to meet the convergence accuracy and convergence speed of the system.
In this paper, the integral of time multiplied by absolute value of error (ITAE) is adopted as the performance optimization objective of microgrid system. Its expression is: where e(t) is the output error. Taking ITAE as the fitness function can make the transient response oscillation of the system smoother and the voltage followability strong. In order to improve the inertial support of the microgrid system, obtain the optimal virtual inertia and damping coefficient, enhance the smoothness of the transient response of the system, and follow the voltage, the designed fitness function is: where fitness is the fitness function value of the population, and Du dc (t) is the deviation of the DC bus voltage.

ACSFO Algorithm Flow Design
The main logic and flow of the ACSFO algorithm to improve virtual inertial control are shown as follows.

Simulation Results
In order to verify the effectiveness of the improved sailfish algorithm proposed in this paper for the virtual inertia optimal control strategy and the correctness of the theory, the optical storage microgrid model shown in Fig. 1 is built in Matlab/Simulink, and the photovoltaic adopts the Maximum Power Point Tracking (MPPT) control. The bidirectional DC/DC converter connected to the battery grid adopts different control strategies according to the needs. The corresponding system parameters are shown in Table 3. Figure 12 describes the effect of virtual inertia on the optical storage microgrid. The blue curve only adopts droop control, and the droop control means that we should set virtual inertia C v =0. For the rest of the curves, the damping coefficient is set to 20, and the virtual inertia is a variable. Figure 12(a) describes the voltage dynamic response. When the reference voltage changes, the voltage rapidly changes to the voltage reference value in the droop control case; in the VSG control case, the voltage changes slowly to the voltage reference value, and the system inertial support is significantly improved. As the virtual inertia increases, the voltage changes more slowly, the inertial support is stronger, and the voltage quality improves. Figure 12(b) shows the influence of load power mutation on the DC bus voltage. Similarly, as the virtual inertia increases, the inertial support is stronger and the fluctuation is weakened. When t= 1 s, the load power suddenly increases by 5 kW, at this time, the VSG control will reduce the power delivered to the microgrid; when t=1.5 s, the load power will sud- denly drop by 5 kW, and the VSG control will increase the power delivered to the microgrid and enhance the inertial support of the microgrid. Figure 13 describes the effect of the damping coefficient on the optical storage microgrid, setting the virtual inertia C v =0 and the damping coefficient D v as a variable. Figure 13(a) depicts the voltage dynamic response. In the case of VSG control, as the damping coefficient increases, the voltage response is faster and the deviation from the reference voltage is smaller, but it also reduces a certain inertia. In Fig. 13(b), when t=1 s, the load power suddenly increases by 5 kW, and when t= 1.5 s, the load power suddenly drops by 5 kW. In the two cases of sudden change, with the increase of the damping coefficient, the deviation is smaller and the recovery of stable values is faster.
Through theoretical and simulation analysis, we can know that the larger the virtual inertia, the stronger the inertial support of the system, which avoids the violent fluctuation of the DC bus voltage, but at the same time the voltage recovery speed becomes slower. The larger the damping coefficient, the higher the voltage response speed, but the damping coefficient will have a certain weakening effect on the inertia. At the same time, it can be seen from the theoretical analysis in Fig. 6 that the damping coefficient is too large which will af-fect its stability. In order to realize the optimal solution of virtual inertia and damping coefficient of VSG control, formula (26) is used as the fitness function, and the ACSFO algorithm is used to find the optimal solution of parameters. The value ranges of the virtual inertia and damping coefficient are set to [0, 2.5] and [0, 30], respectively, the number of algorithm population is 20, and the number of iterations is 50. The iteration curve is obtained as shown in Fig. 14.
It can be seen from Fig. 14 that the ACSFO algorithm has a great improvement over the original SFO algorithm, showing great advantages in finding the opticient, and its convergence speed and convergence accu- When the load power changes, the simulation comparison diagram of the optimal configuration of virtual inertial control using the ACSFO algorithm is shown in Fig. 15.
It can be seen from Fig. 15 that the ACSFO algorithm has better dynamic response ability, shorter recovery time and smaller fluctuation than the SFO algorithm.

Conclusion
In order to promote the digitization process of the power grid, this paper uses an intelligent method to solve the voltage quality problem caused by the low inertia of the DC microgrid. Firstly, by analogy with the DC/ AC inverter with VSG, the VSG control is applied to the DC bidirectional DC/DC converter of the optical storage microgrid. After that, the anti-leakage net strategy and the cross-mutation propagation mechanism are integrated into the Sailfish optimization algorithm to improve the global optimization ability. Finally, an intelligent optimization control strategy of virtual inertia and damping coefficient is proposed.
Through theoretical analysis and experimental verification, the following conclusions are drawn: 1) The low inertia problem of the DC microgrid is effectively solved by constructing a VSG control strategy, and the voltage following performance is enhanced. Using ACSFO algorithm to realize the configuration of VSG control parameters can effectively improve its system adaptability and intelligence. Effectively using ITAE as a fitness function can take into account its error accuracy and convergence speed at the same time in parameter configuration, which can improve the following performance while enhancing the inertial support of the system, and provide ideas for the acquisition of electrical data in digital power grids.
2) The ACSFO algorithm integrates the antileakage network strategy and the vertical and horizontal crossover mutation propagation mechanism, which enhances the global development ability and local exploration ability of the SFO algorithm, greatly improves the algorithm optimization accuracy and convergence speed. By using the ACSFO algorithm, the optimal configuration of the VSG control parameters can be achieved.
3) This paper only aims to add VSG control based on ACSFO algorithm to the bidirectional DC/DC converter in a single optical storage microgrid, and does not consider the coordinated control of the intelligent microgrid system with mesh interconnection of the optical storage microgrid. The insufficiency of this paper is also the future research direction.