## 3 Multi-Energy Coordination and Optimization Dispatching Strategy of Urban Power Grid
### The Solution of the Model Based on ADMM  
ADMM is a kind of algorithm for solving complex optimization problems. It can be applied to solve the multi-agent decision of a convex optimization problem. This method decomposes a relatively complex optimization decision problem into several small and easy-to-solve different sub-problems through the decomposition-coordination process, and through the iterative solution between sub-problems until the global convergence, so as to obtain the global optimal solution of the original problem. The ADMM method is used to solve the optimal scheduling model. The optimization problem of the IES of power-heat interconnection based on the ADMM is divided into two sub-problems: power network optimization and heating system optimization. After decomposition, the optimization goal is to minimize the total operating cost of the Internet system. The IES can be regarded as the operation under the condition of a limited number of information exchanges, while the power grid dispatching agency and heating network dispatching agency can be regarded as two separate decision-making bodies to form the collaborative optimization of power supply energy flow and heating energy flow through the communication of a limited number of times. In the power network optimization sub-problem, the coupling constraint conditions of electrothermal should be considered. Hence, the electric-gas coupling relation based on the gas turbine is selected and substituted into the objective function. The objective function of the grid optimization sub-problem can be expressed as:  
\[\min f(Q_{\text{PB}}^{t},Q_{\text{PG}}^{t})=C_{\text{PB}}+C_{\text{PG}} \tag{18}\]  
In the natural gas network optimization sub-problem, the electric-gas coupling relation based on the gas turbine is also selected and substituted into the objective function. Then, the objective function of the natural gas optimization sub-problem can be expressed as:  
\[\min g(Q_{\text{HB}}^{t},Q_{\text{HG}}^{t})=C_{\text{HB}}+C_{\text{HG}} \tag{19}\]  
The above optimization problem can be converted into an ADMM optimization problem in the form of:  
\[ \begin{array}{l}\min f(x)+g(y)\\ s.t.\ Ax+By=C\end{array}  \tag{20}\]  
where for any time period, \(x=(Q_{\text{PB}}^{t},Q_{\text{PG}}^{t})\) and \(y=(Q_{\text{HB}}^{t},Q_{\text{HG}}^{t})\) is the optimization variable. The ADMM algorithm can be solved by Gauss-Seidel iteration method. In the solving process, only one of the two sub-problems is in the calculation state. When the value of the coupling variable is obtained, it will be substituted back into the other sub-problem for solving. Wait for another sub-problem to update the value of the coupling variable, and then substitute it back into the previous sub-problem for the next round of iterative calculation. At the end of each iteration and the moment into the next iteration, the multiplier must be updated. The flow chart of solving a multi-energy coordination problem based on ADMM is shown in Figure 2. The solution method can be expressed as follows:  
\[\left\{ \begin{array}{l}x^{k+1}=\arg\min_{x}L_{\lambda}(x,\ y^{k},\ z^{k})\\ y^{k+1}=\arg\min_{y}L_{\lambda}(x^{k+1},\ y,\ z^{k})\\ z^{k+1}=y^{k}+\lambda(Ax^{k+1}+By^{k+1}-C)\end{array} \right. \tag{21}\]In each iteration, there are three steps in total: namely, solve the minimization problem related to \(x\) and update \(x\); solve the minimization problem related to \(y\) and update \(y\); update the multiplier \(z\). The convergence standard of ADMM is:  
\[\left\{ \begin{array}{l}\|r^{(r+1)}\|_{2}^{2}=\|Ax^{k+1}+By^{k+1}-C\|_{2}^{2} \leq\varepsilon_{pri}\\ \|s^{(r+1)}\|_{2}^{2}=\|AA^{\intercal}B(y^{k+1}+y^{k})\|_{2}^{2}\leq \varepsilon_{dual}\end{array} \right. \tag{22}\]  
where \(\|r^{(r+1)}\|_{2}^{2}\) and \(\|s^{(r+1)}\|_{2}^{2}\) is the original residual and dual residual after the k + 1 th iteration calculation; \(\varepsilon_{pri}\) and \(\varepsilon_{dual}\) are the tolerance upper limit of the original residual error and dual residual error, respectively.