# Cross-Entropy Method in Application to the SIRC Model
## 4 Summary  
The study examined the possibility of using the CE method to determine the optimal control in the SIRC model. Similar models are being developed to model the propagation of malicious software in computer networks (v. [PERSON] et al. [40]). However, the number of works with this approach is still relatively small, although its universality should encourage checking its effectiveness. There are two control functions in the model, which, when properly selected, optimize the cost function. The CE method was used in two versions: considering the two functions separately and together. The results were then compared with those obtained by [PERSON] and [PERSON] [31] using routing of Matlab (Matlab is a paid environment with a number of functions. Unlike other environments and programming languages, additional features are created by developers in a closed environment and can only be obtained through purchase.). The Cross-Entropy method had little problems when considering two functions at the same time. Due to the large number of possibilities, it was necessary to simulate a large sample, which significantly extended the algorithm's time. The second way came out much \begin{table}
\begin{tabular}{l c c} \hline \hline
**Method** & **Cost Index** & **Time** \\ \hline \multirow{2}{*}{Results without control functions} & 0.00799 & - \\ \cline{2-3}  & 0.00789 & - \\ \hline \multirow{2}{*}{Sequential quadratic programming method} & 0.003308 & - \\ \cline{2-3}  & 0.006489 & - \\ \hline \multirow{2}{*}{Cross-entropy method version 1} & 0.003086 & 30 s \\ \cline{2-3}  & 0.006443 & \\ \hline \multirow{2}{*}{Cross-entropy method version 2} & 0.003044 & \multirow{2}{*}{4 min 54 s} \\ \cline{2-3}  & 0.006451 & \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Summary of cost indexes and times for all situations. Figure 9: Comparison of results obtained for group C among various methods. better. However, it only worked because the functions were not dependent on each other. In the opposite situation, there is also a possibility to get the result via CE results however, it will be necessary to change the algorithm and the dependence of how the functions depend on each other and add this to the algorithm when initiating optimization functions in the code. The same situation applies to changing the objective function and the density used for approximation. Changing the objective function gives the possibility to use other methods. If it stays quadratic and the constraints are linear, quadratic programming techniques like the sequential quadratic programming method can still be used. If the objective function and the constraints stay convex, we use general methods from convex optimization. The CE method is based on well-known and simply classical rules and is therefore quite problem-independent. There are no rigid formulas, and therefore it requires consideration for each problem separately. So it is very possible to reconsider it in another way, which can be interesting for further work. The CE method may also facilitate the analysis of modifications of epidemiological models related to virus mutation or delayed expression (v. [PERSON] et al. [41], [PERSON] et al. [42]). [PERSON] gave an idea of application of CE to SIRC model; [PERSON] realized implementation and simulation. All authors have read and agreed to the published version of the manuscript  
K.J.S. are thankful to Faculty of Pure and Applied Mathematics for research funding. The authors declare no conflict of interest. The following abbreviations are used in this article: