## 5 Conclusions  
Aiming at the frequency control issues of the aggregated distributed energy grids under DoS attacks, in this paper, we proposed a data-driven frequency control strategy. The actor-critic reinforcement-learning algorithm was used to suppress the load change disturbances and the frequency deviation of the aggregated distributed energy grids under DoS attacks, which overcame the issues of aggregated distributed energy grid modeling. Convex neural networks were used to establish actor-critic networks. Convex neural networks can transform the optimization process of evaluating the long-term future cost of the networks into the convex optimization process, ensuring that the long-term future cost has a global optimum, thus, speeding up the optimization speed and improving the control efficiency. The Lyapunov function was constructed to analyze the stability of the system and verify the convergence of the weights of convex neural networks and to find the sufficient conditions for the stability of the system and the convergence of the weights. Finally, the IEEE14 bus testing system, IEEE57 bus testing system, and IEEE118 bus testing system, respectively, were used to verify the effectiveness of the proposed method under a variety of DoS attack intensities in a complex power grid operating environment by comparing with other methods. Conceptualization, F.Z. and Z.Z. ; methodology, G.Q. and J.S. ; software, F.Z. and J.S. ; validation, G.Q., G.H. and M.H. ; formal analysis, F.Z. and J.S. ; investigation, G.Q. and Z.Z. ; resources, Z.Z. ; data curation, J.S. ; writing--original draft preparation, F.Z., G.Q., Z.Z. and J.S. ; writing--review and editing, F.Z., G.Q., Z.Z. and J.S. ; visualization, G.H. ; supervision, J.S. ; project administration, G.H. and M.H. ; funding acquisition, Z.Z. All authors have read and agreed to the published version of the manuscript. This work was jointly supported by the National Natural Science Foundation of China under Grant No. 61803061, 61906026; Fundamental Research Funds for the Central Universities (Grant No. XDJK2020B010); National Natural Science Foundation of China under Grant No. 61771081, 61703347; Innovation research group of universities in Chongqing; the Chongqing Natural Science Foundation under Grant cstc2020 jcyj-msxmX0577, cstc2020 jcyj-msxmX0634, cstc2019 jcyj-msxmX0110, cstc2021 jcyj-msxmX0416; \"Chengdu-Chongqing Economic Circle\" innovation funding of Chongqing Municipal Education Commission KJCXZD2020028; the Science and Technology Research Program of Chongqing Municipal Education Commission grants KJQN202000602; Ministry of Education China Mobile Research Fund (MCM 20180404); Special key project of Chongqing technology innovation and application development: cstc2019 jsc-zdztzx0068; the Innovation Project of Chongqing Overseas Students Entrepreneur Innovation Support program (Grant No. cx2018074). Not applicable. The authors declare no conflict of interest. Proof. : Assuming that the expected control output \(u_{d,i}\) and the long-term future cost \(Q_{i}(k)\) can also be expressed by convex neural networks as follows. \[g_{i}^{*}(.)=Con(\mathbf{W}_{c,i}^{*},\mathbf{x}_{i}^{\prime})+\varepsilon_{a,i}, \varphi_{i}^{*}(.)=u_{lim}\tanh\bigl{(}Con(\mathbf{W}_{a,i}^{*},\mathbf{x}_{i}^{ \prime})\bigr{)}+\varepsilon_{c,i} \tag{11}\]  
where \(g_{i}^{*}(. )\) and \(\varphi_{i}^{*}(. )\) are the best estimates of \(Q_{i}(k)\) and \(u_{d,i}(k)\); \(\mathbf{W}_{a,i}^{*}\) and \(\mathbf{W}_{c,i}^{*}\) are the optimal weight sets approximating \(u_{d,i}(k)\) and \(Q_{i}(k)\), respectively; and \(\varepsilon_{a,i}\) and \(\varepsilon_{c,i}\) are the minimum approximation errors of convex neural networks approximating \(u_{d,i}(k)\) and \(Q_{i}(k)\). Equation (12) is defined as follows. \[\tilde{\mathbf{W}}_{a,i}(k){=}\mathbf{W}_{a,i}(k)-\mathbf{W}_{a,i}^{*}(k), \tilde{\mathbf{W}}_{c,i}(k){=}\mathbf{W}_{c,i}(k)-\mathbf{W}_{c,i}^{*}(k) \tag{12}\]  
As defined in Equation (13), the positive definite Lyapunov function \(V_{i}(k)\) is chosen.