# Research on Risk Identification of Coal and Gas Outburst Based on PSO-CSA

Authors: Ji Peng; Shi Shiliang; Lu Yi; Li He
Journal: Mathematical Problems in Engineering
 (2023)

---

## Abstract

Aiming at the identification of coal and gas outburst risk, using the advantages of the clone selection algorithm (CSA), such as self-adaptation and robustness, and the characteristics of fast convergence of particle swarm optimization (PSO) algorithm, the complex decoding problem, and mutation process brought by CSA binary coding are used. It is difficult to control the problem. Using PSO optimization, the problem of abnormal detection and identification in coal and gas outburst monitoring is developed and studied, and a CSA coal and gas outburst risk anomaly detection and identification model based on PSO optimization variation is established. The model uses the coal and gas outburst index data as a collection of antigen-stimulated antibodies to achieve abnormal detection and identification of measured data. With the help of the measured data, the verification results show that the model can effectively detect and identify the risk of coal and gas outburst, and the identification results are consistent with the risk of coal and gas outburst in the field. It can be used as an effective risk identification model to guide coal mining work.


---

## Body

## 1. Introduction

China is a large coal energy consumption country, and the shallow coal resource consumption is serious [1]. The mining of deep coal mines is advancing in an orderly manner in response to the coal supply. With the increase of mining depth, the in situ stress and gas pressure are getting bigger and bigger, and the resulting disasters such as coal and gas outburst bring huge pressure and challenges to the safety of coal mines [2], resulting in tragic casualties and huge economic losses. In order to solve the problem of coal and gas outburst disasters and reduce losses, Chinese coal mine safety researchers and workers have carried out in-depth research and practice, and have made great progress in recent years, and detailed prevention and control rules and some technical measures and methods with significant effects have been researched and formulated [3]. However, with the increase of mining depth, the impact of coal and rock mechanical factors such as in situ stress on coal and gas outburst is still unclear, and the impact on coal and gas outburst is still unclear. The research on the mechanism of gas prominence is still in the hypothesis stage [4]. Coal and gas outburst is still the primary threat factor for coal mine production due to their suddenness and extremely high damage, and a disaster problem that coal mine safety researchers need to solve urgently.In the process of coal and gas outburst prevention, monitoring and prediction are the most important links. Only with timely perception, timely identification, and prediction can timely preventive measures be taken to eliminate coal and gas outbursts in the germination stage. The current research on recognition methods has been carried out in depth, and more intelligent prediction methods have been developed, such as the application of algorithms such as machine learning and deep learning, machine learning based diagnosis methods such as LSTM [5], PF [6], and GPR and BLS [7], but like the artificial immune system in deep learning algorithms, cloning selection algorithms and other algorithms in the risk identification of coal and gas outburst application research is still less. Therefore, it is valuable to carry out relevant research to provide new ideas for coal and gas outburst risk identification. Coal and gas outbursts faced by the coal production environment are uncertain and coupled with multiple factors. The forms of coal and gas outbursts also vary with different mining environments, and when, where, and the size of the outbursts cannot be predicted in advance. It is known that this is very similar to the biological immune system, but biological immunity can recognize and resist both known and unknown antigens. This defense mechanism of the immune system meets the requirements of coal and gas outburst risk identification and simulates biological immunity. The clone selection algorithm established by the system can therefore be used for risk identification and early warning of coal and gas outbursts. The CSA is a kind of artificial immune algorithm, only focuses on the influence of the affinity of antibodies and antigens on the differentiation of B lymphocytes and is not affected by the affinity between antibodies [8]. The algorithm is only for the selection of the most stimulated individuals and cloning, as well as the advantages of autonomous learning, recognition, and memory, meet the needs of coal and gas outburst dangerous abnormal detection and recognition [9]. However, it also has problems such as oscillation, insufficient convergence, and easily falling into local optimum. To improve the CSA’s requirements for coal and gas outburst identification [10], speed up its convergence speed, improve its global search ability, eliminate its late-stage oscillation, and improve the success of identification rate, and then effectively identify prominent anomalies. Many scholars have done in-depth research on optimization selection, including the self-optimization of immune algorithms, the use of distribution estimation algorithms, ant colony algorithms, and optimization of particle swarm optimization algorithms. Among these algorithms, the PSO is currently widely used in industry, its stable characteristics have been effectively verified, and the technology is becoming mature. It has the advantages of fast convergence speed and no need for repeated encoding and decoding [11], which can meet the above requirements for the optimization of the CSA mutation process and improve the shortcomings of the clonal mutation process of CSA [12]. Therefore, based on the combination of the two, a model for the detection and identification of coal and gas outburst risk based on PSO and CSA is established, and the particle swarm algorithm is introduced into the mutation process of the cloning algorithm so that the mutation no longer depends on a large number of calculations. Binary encoding and decoding can also achieve the purpose of showing a high affinity for antibodies generated during the mutation process.In this paper, the functions of PSO and CSA are combined to build a PSO-CSA-based coal and gas outburst risk identification model. It is found that the PSO-CSA model has a fast calculation speed and can achieve the effect of identifying abnormal data in coal and gas outbursts. Compared with the model using only CSA, PSO has a significant effect on the optimization of CSA, and CSA can be used for coal and gas outbursts. For the identification of outburst risk, the PSO-CSA model can be used as a new and effective method for identifying coal and gas outburst risk and can be used to guide engineering practice.


## 2. Establishment of a Risk Identification Model Based on PSO-CSA

### 2.1. CSA Principle and Process

In 1986, Farmer proposed clonal selection. He believed that each B lymphocyte can produce more than 100,000 antibodies on the surface [13]. These huge numbers of antibodies can be used as the unique antibody determinants of the detector to detect whether there is a matching antibody epitope. Once a B cell detects a matching epitope, the immune system replicates that type of B cell and produces more antibodies [14]. In the immune system, this process of replicating B lymphocytes, which stimulates only useful antibodies, is immune clonal selection [14]. The basic principle of biological immune clone selection is shown in Figure 1.Figure 1
Principle of biological immune clonal selection.Figure1 briefly shows the principle of clonal selection. The phenotypic string of the epitope of the antigen is 1110010, which is a perfect match with No. 2 in the antibody, so the spinal cord stimulates the No. 2 antibody to multiply [15]. Partially matched with antibody 7, reproduced in small amounts, while other antibodies did not match it, did not divide, and waited for apoptosis and phagocytosis.With the help of this biological mechanism, Castro proposed a clonal selection algorithm (CSA), which is based on only focusing on the impact of antibody and antigen affinity on B lymphocytes, without considering the affinity between antibodies. At the same time, Castro optimized the algorithm flow of CSA on this basis [16]. The basic steps are as follows:The algorithm is assumed to be performed in the immune space, with strings representing antibody and antigen genotypes of lengthL, and S representing the appropriate axes of the immune space. First, define the required variables in the CSA:(i)
Ag: antigen(ii)
Ab: available antibody table (Ab ∈ SN×L, Ab = Ab(r) ∪ Ab(m))(iii)
Ab(m): memory antibody table (Ab(m) ∈ Sm×L, m ≤ N)(iv)
Ab(r): remaining antibody table (Ab(r) ∈ Sm×L, r = N − m)(v)
Ag(M): antigen group successfully recognized (Ag(M) ∈ SM×L)(vi)
fj: affinity vector associated with antigen Agj(vii)
Ab(H): the n antibodies in Ab that have the highest affinity with Agj (Ab(H) ∈ Sn×L, n<N)(viii)
Cj: population of Nc clones in Ab(H) (Cj ∈ SNc×L)(ix)
Cj∗: Cj is transformed into a population after affinity maturation (high-frequency mutation).Cj transforms into after affinity maturation(x)
Ab(d): the d low-affinity antibodies in Ab(r) are replaced with d molecules in Cj∗ (Ab(d) ∈ Sd×L, d<r)(xi)
Ab(G): prepare the antibody from Cj∗ into the memory antibodyThen, the specific steps are as follows:Step 1: we randomly select an antigen Agj (Agj ∈ Ag), let it stimulate all antibodies in the Ab set (Ab = Ab(r) ∪ Ab(m), r + m = N). By setting the optimized function gx, the affinity of the antibody to the antigen can be regarded as the solution of the objective function, and each antibody Abi represents an element of the input space;Step 2: we calculate the affinity vectorfj of n antibodies in Ab;Step 3: we select Ab neutralizing antigen Agj; the n antibodies with the highest affinity form a new set (Ab(H) ∈ Sn×L, n ≤ N);Step 4: the antibodies of the Ab(H) collection will generate new clones according to their respective affinities according to a certain ratio, and the affinity of the n antibodies of Ab(H) to the antigens that make up the collection of clones Cj, the higher the affinity of these n antibodies of Ab(H) to the antigen, the more clones generated of their own;Step 5: all antibodies in the setCj undergo a mutation process related to affinity to generate a mature clone set Cj∗, the higher the affinity, the lower the antibody mutation rate;Step 6: we calculate the affinityfj∗ of the mature clone set Cj∗ and antigen Agj;Step 7: we reselect an antibody with the highest affinity for Agj in the clones of the set Cj∗ and put it into the memory cell set Ab(m), if the affinity of this antibody for the antigen Agj is higher than that of the original memory cells, replace it. If a population of antibodies is used to determine multiple optimal solutions to a problem, two more variables need to be determined: (1)
Setn = N, that is, all antibodies in Ab were selected for clone in step 3.(2)
Determining the number of clones of antibodies in Ab(n):(1)Nc=∑i=1nroundβ×N.In equation (1), Nc is the total number of antibodies in the clone set Cj, b is an influencing parameter, round(x) is the rounding function, and the antibody with the highest affinity is, if 100, then this antibody.Step 8: Thed antibodies of Cj∗ replace the Ab(r) set to neutralize the antigen Agj, and the d antibodies with the lowest affinity.When allM antigens have performed the abovementioned process once, then the algorithm will perform one generation [17]. Figure 2 shows the process of the abovementioned steps, and after step 3, the n antibodies with the highest affinity will be sorted according to their affinity. Sort from high to low so that their specific number of clones can be calculated using the following equation:(2)Nc=∑i=1nroundβ×Ni.Figure 2
The basic process of CSA.However, since CSA uses binary algorithms for data identification, output, and calculation in the data set, the algorithm needs to redecode every time the affinity of the antigen and antibody is calculated, and the calculation amount increases sharply, which requires a lot of calculation time [18]. At the same time, the mutation of the algorithm is realized by randomly changing the feature vector of the originally cloned antibody [19]. Although it has the effect of increasing the diversity of antibodies, it will also have the side effect of destroying antibodies with high affinity, and the mutation process will also increase the amount of calculation. In the iterative calculation process of the algorithm, the antibodies with high affinity produced by each generation may not be preserved, and some of them will die [20]. However, the mutation in CSA is the only way to generate high-potential antibodies, so it is necessary to ensure a high mutation rate of the algorithm to ensure the number of effective antibodies.


### 2.2. CSA Optimization

In Castro’s CSA algorithm, a high-probability mutation has been adopted for antibodies with high affinity, and a global search is performed on the problem space to maintain the diversity of the population. However, adopting this method will cause the algorithm to oscillate in the later stage of convergence, making it difficult to converge [21]. Therefore, the convergence optimization of the algorithm makes the algorithm adaptive to the high probability mutation, that is, as the number of iterations increases, the β in the algorithm decreases, and the decreasing equation is as follows:(3)βik+1=μ×βik,where I represents the rank of the antibody in the array, k represents the number of iterations, and the parameter μ satisfies 0 < μ < 1.At the same time, the affinity of the cloned new antibody is calculated to limit the update of the antibody clone [22], and the newly generated antibody replaces the original low-affinity antibody so that the algorithm converges upward in the cloning process, and the newly generated affinity antibody should be above the average affinity of the current population [23]. If it is lower than the average value, the cloned antibody is discarded, and a new antibody is randomly generated:(4)fd¯=∑i=1dfdd,(5)fj¯=∑i=1jfjj,(6)fd¯−fj¯≥0.Antibodies conforming to equation (6) can be saved. If the antibodies generated by continuous cycles do not meet the requirements, or the number of iterations exceeds the set threshold, the cloning will be stopped, and the original affinity antibody will be used.To prevent the “premature” mutation of the algorithm during the operation, they index is used for detection, and the value l = 1 is set as the critical value. When y ≤ l, the algorithm is judged to enter the “premature” state [24], and the use of the β-assigned antibody is suspended. Cloning, while using the method of suddenly amplifying the mutation probability to k times, the original probability introduces a new population to increase the algorithm to jump out of the local optimum and converge [25]. And when y returns to y > l, the algorithm continues to perform according to b an assignment:(7)y=fmax−fminfj¯,where fmax is the maximum affinity of the antibody in this iteration and fmin is the minimum affinity.


## 2.1. CSA Principle and Process

In 1986, Farmer proposed clonal selection. He believed that each B lymphocyte can produce more than 100,000 antibodies on the surface [13]. These huge numbers of antibodies can be used as the unique antibody determinants of the detector to detect whether there is a matching antibody epitope. Once a B cell detects a matching epitope, the immune system replicates that type of B cell and produces more antibodies [14]. In the immune system, this process of replicating B lymphocytes, which stimulates only useful antibodies, is immune clonal selection [14]. The basic principle of biological immune clone selection is shown in Figure 1.Figure 1
Principle of biological immune clonal selection.Figure1 briefly shows the principle of clonal selection. The phenotypic string of the epitope of the antigen is 1110010, which is a perfect match with No. 2 in the antibody, so the spinal cord stimulates the No. 2 antibody to multiply [15]. Partially matched with antibody 7, reproduced in small amounts, while other antibodies did not match it, did not divide, and waited for apoptosis and phagocytosis.With the help of this biological mechanism, Castro proposed a clonal selection algorithm (CSA), which is based on only focusing on the impact of antibody and antigen affinity on B lymphocytes, without considering the affinity between antibodies. At the same time, Castro optimized the algorithm flow of CSA on this basis [16]. The basic steps are as follows:The algorithm is assumed to be performed in the immune space, with strings representing antibody and antigen genotypes of lengthL, and S representing the appropriate axes of the immune space. First, define the required variables in the CSA:(i)
Ag: antigen(ii)
Ab: available antibody table (Ab ∈ SN×L, Ab = Ab(r) ∪ Ab(m))(iii)
Ab(m): memory antibody table (Ab(m) ∈ Sm×L, m ≤ N)(iv)
Ab(r): remaining antibody table (Ab(r) ∈ Sm×L, r = N − m)(v)
Ag(M): antigen group successfully recognized (Ag(M) ∈ SM×L)(vi)
fj: affinity vector associated with antigen Agj(vii)
Ab(H): the n antibodies in Ab that have the highest affinity with Agj (Ab(H) ∈ Sn×L, n<N)(viii)
Cj: population of Nc clones in Ab(H) (Cj ∈ SNc×L)(ix)
Cj∗: Cj is transformed into a population after affinity maturation (high-frequency mutation).Cj transforms into after affinity maturation(x)
Ab(d): the d low-affinity antibodies in Ab(r) are replaced with d molecules in Cj∗ (Ab(d) ∈ Sd×L, d<r)(xi)
Ab(G): prepare the antibody from Cj∗ into the memory antibodyThen, the specific steps are as follows:Step 1: we randomly select an antigen Agj (Agj ∈ Ag), let it stimulate all antibodies in the Ab set (Ab = Ab(r) ∪ Ab(m), r + m = N). By setting the optimized function gx, the affinity of the antibody to the antigen can be regarded as the solution of the objective function, and each antibody Abi represents an element of the input space;Step 2: we calculate the affinity vectorfj of n antibodies in Ab;Step 3: we select Ab neutralizing antigen Agj; the n antibodies with the highest affinity form a new set (Ab(H) ∈ Sn×L, n ≤ N);Step 4: the antibodies of the Ab(H) collection will generate new clones according to their respective affinities according to a certain ratio, and the affinity of the n antibodies of Ab(H) to the antigens that make up the collection of clones Cj, the higher the affinity of these n antibodies of Ab(H) to the antigen, the more clones generated of their own;Step 5: all antibodies in the setCj undergo a mutation process related to affinity to generate a mature clone set Cj∗, the higher the affinity, the lower the antibody mutation rate;Step 6: we calculate the affinityfj∗ of the mature clone set Cj∗ and antigen Agj;Step 7: we reselect an antibody with the highest affinity for Agj in the clones of the set Cj∗ and put it into the memory cell set Ab(m), if the affinity of this antibody for the antigen Agj is higher than that of the original memory cells, replace it. If a population of antibodies is used to determine multiple optimal solutions to a problem, two more variables need to be determined: (1)
Setn = N, that is, all antibodies in Ab were selected for clone in step 3.(2)
Determining the number of clones of antibodies in Ab(n):(1)Nc=∑i=1nroundβ×N.In equation (1), Nc is the total number of antibodies in the clone set Cj, b is an influencing parameter, round(x) is the rounding function, and the antibody with the highest affinity is, if 100, then this antibody.Step 8: Thed antibodies of Cj∗ replace the Ab(r) set to neutralize the antigen Agj, and the d antibodies with the lowest affinity.When allM antigens have performed the abovementioned process once, then the algorithm will perform one generation [17]. Figure 2 shows the process of the abovementioned steps, and after step 3, the n antibodies with the highest affinity will be sorted according to their affinity. Sort from high to low so that their specific number of clones can be calculated using the following equation:(2)Nc=∑i=1nroundβ×Ni.Figure 2
The basic process of CSA.However, since CSA uses binary algorithms for data identification, output, and calculation in the data set, the algorithm needs to redecode every time the affinity of the antigen and antibody is calculated, and the calculation amount increases sharply, which requires a lot of calculation time [18]. At the same time, the mutation of the algorithm is realized by randomly changing the feature vector of the originally cloned antibody [19]. Although it has the effect of increasing the diversity of antibodies, it will also have the side effect of destroying antibodies with high affinity, and the mutation process will also increase the amount of calculation. In the iterative calculation process of the algorithm, the antibodies with high affinity produced by each generation may not be preserved, and some of them will die [20]. However, the mutation in CSA is the only way to generate high-potential antibodies, so it is necessary to ensure a high mutation rate of the algorithm to ensure the number of effective antibodies.


## 2.2. CSA Optimization

In Castro’s CSA algorithm, a high-probability mutation has been adopted for antibodies with high affinity, and a global search is performed on the problem space to maintain the diversity of the population. However, adopting this method will cause the algorithm to oscillate in the later stage of convergence, making it difficult to converge [21]. Therefore, the convergence optimization of the algorithm makes the algorithm adaptive to the high probability mutation, that is, as the number of iterations increases, the β in the algorithm decreases, and the decreasing equation is as follows:(3)βik+1=μ×βik,where I represents the rank of the antibody in the array, k represents the number of iterations, and the parameter μ satisfies 0 < μ < 1.At the same time, the affinity of the cloned new antibody is calculated to limit the update of the antibody clone [22], and the newly generated antibody replaces the original low-affinity antibody so that the algorithm converges upward in the cloning process, and the newly generated affinity antibody should be above the average affinity of the current population [23]. If it is lower than the average value, the cloned antibody is discarded, and a new antibody is randomly generated:(4)fd¯=∑i=1dfdd,(5)fj¯=∑i=1jfjj,(6)fd¯−fj¯≥0.Antibodies conforming to equation (6) can be saved. If the antibodies generated by continuous cycles do not meet the requirements, or the number of iterations exceeds the set threshold, the cloning will be stopped, and the original affinity antibody will be used.To prevent the “premature” mutation of the algorithm during the operation, they index is used for detection, and the value l = 1 is set as the critical value. When y ≤ l, the algorithm is judged to enter the “premature” state [24], and the use of the β-assigned antibody is suspended. Cloning, while using the method of suddenly amplifying the mutation probability to k times, the original probability introduces a new population to increase the algorithm to jump out of the local optimum and converge [25]. And when y returns to y > l, the algorithm continues to perform according to b an assignment:(7)y=fmax−fminfj¯,where fmax is the maximum affinity of the antibody in this iteration and fmin is the minimum affinity.


## 3. PSO to CSA Optimization

### 3.1. Principles of PSO

The PSO algorithm is a random search algorithm that simulates natural biological activities and swarms’ intelligence. It generates particles of a certain size randomly as an effective solution to the problem search space and then performs an iterative search to obtain optimized results in a global-based search [26]. In the algorithm, each antibody in the antibody population is called a “particle” [27], and by randomly generating particles of a certain size as an efficient solution to the problem search space. Each particle has a speed and a position. The fitness value of the particle can be determined by the fitness function defined by the problem, and then iteratively iterates continuously. The speed and position of the particle are affected by the historical optimal solution of the particle itself and the global optimal solution of the group [28]. Let the particles explore and develop in the search space, and finally find the global optimal solution, as shown in Figure 3(a). Individual particles are affected by their own current speed effect, self-memory effect, and group effect, and move closer to the global optimal solution, and finally achieve the global optimal solution, as shown in Figure 3(b).Figure 3
PSO principle.


### 3.2. Optimization of CSA by PSO

The PSO algorithm randomly generates particles of a certain size as an effective solution to the search space of the problem and then performs an iterative search to obtain the optimization result [29]. The solution process of particles is affected by the historical optimal solution of the particle and the optimal solution of the group so that the particle can search and develop in the search space, and finally find the global optimal solution, which is a kind of global search. Therefore, PSO is used to optimize the local precociousness, late oscillation [30], and long calculation process of CSA in the process of mutation, which affects the friendliness of the model.In the optimization process, each antibody setCj with high affinity is used as a particle in the space, and the initial velocity v0 of each particle is randomly generated, then the initial velocity of the i-th antibody is vi0, and the velocity of each particle is v0. The feature vector Hvi0 = (hv1, hv2, …, hvn)T, the greater the affinity between the antigen Ag(M) and the Ab, the better the position of the antibody. At the same time, the number of iterations of each antibody mutation is set to Q, each particle is iterated to the q-th generation position, and the searched optimal position is recorded as P(q), then P(q) = fmax, where q = {1, 2, …, Q}; under this algorithm, the entire particle swarm is updated to the end of the Q-th generation, and the optimal position searched is Pi(q), Pi(q) = fmax, PSO is based on P0(q), and Pi(q) update its speed vin and position until q = Q and realize its optimal variation of CSA. The process is described as follows:(8)viq+1=ωviq+r1t1P1q−Ab1q+⋯+r2t2Piq−Abmq,Abmq+1=Abmq+vmq,where v is the inertia weight, the learning factors r1 and r2 are nonnegative constants, the number of random changes of r1, r2 (r1 ∈ [0, 1], r2 ∈ [0, 1]), the PSO-optimized variant antibody constitutes the antibody set Cj∗, and the total number of mutated set antibodies remains the same as n [31].


### 3.3. The Basic Process of the Model

After the data collected by the downhole sensor is normalized, it will be identified by the PSO-CSA model to determine whether there is a danger of coal and gas outburst. According to the need for recognition, this model has been realized through the training learning process and the verification application process in turn:(1)
Model training and learning: we set the recognition mode of the model to three categories, serious outburst risk, general outburst risk, and no outburst risk, identified as a significant risk. The collected index data of underground coal and gas outbursts are divided into a training set and a recognition set. The training set is used as an antigen to stimulate the antibody set. The antibody set undergoes algorithmic processes such as cloning and the PSO optimization and mutation to generate memory cells that can recognize abnormal antigens gathered.(2)
Verification application: we use the trained model, that is, the set of memory cells in the model, to identify the recognition set to determine whether it has outburst danger. As shown in Figure4.Figure 4
Model training process.Assuming that the recognition of coal and gas outburst has obtained the corresponding memory cell set through the training process, then both coal and gas outburst and no coal and gas outburst can be recognized by the model, and the application process is to use the memory generated by the training process. Cell collection is used to identify and judge whether the measured data have outburst risk. Figure5 shows the identification process.Figure 5
Model application process.The data of the recognition set is normalized and input as an antigen, and whether there is an abnormality is judged by calculating the affinity between the antigen and the memory cell set.Starting from no protrusion, if the highest affinity between the memory cells in the set Ab(m) and Ab is greater than w (w ∈ (0, 1)), it is recognized as normal, that is, fmaxw, and it is judged that there is no risk of protrusion. Then, calculate the affinity of all memory cells in the Ab set, and whether the memory cell with the highest affinity with Ab has an outburst risk is the Ab set data with outburst risk, to achieve the purpose of identification.The data of the recognition set is normalized and input as an antigen, and whether there is an abnormality is judged by calculating the affinity between the antigen and the memory cell set.Starting from no protrusion, if the highest affinity between the memory cells in the set Ab(m) and Ab is greater than w (w ∈ (0, 1)), it is recognized as normal, that is fmax, and it is judged that there is no risk of protrusion. Then, calculate the affinity of all memory cells in the Ab set, and whether the memory cell with the highest affinity with Ab having an outburst risk is the Ab set data with outburst risk to achieve the purpose of identification.At the same time, set up the model. If more than 10 or more abnormal data entered in the model appear one after another, or the abnormal data are continuously input in a short period, the model will stop computing and give alarm feedback immediately. However, if the model occasionally has individual abnormal data, the model will be automatically eliminated and not used as identification data, reducing the possibility of extreme abnormalities in the model.


## 3.1. Principles of PSO

The PSO algorithm is a random search algorithm that simulates natural biological activities and swarms’ intelligence. It generates particles of a certain size randomly as an effective solution to the problem search space and then performs an iterative search to obtain optimized results in a global-based search [26]. In the algorithm, each antibody in the antibody population is called a “particle” [27], and by randomly generating particles of a certain size as an efficient solution to the problem search space. Each particle has a speed and a position. The fitness value of the particle can be determined by the fitness function defined by the problem, and then iteratively iterates continuously. The speed and position of the particle are affected by the historical optimal solution of the particle itself and the global optimal solution of the group [28]. Let the particles explore and develop in the search space, and finally find the global optimal solution, as shown in Figure 3(a). Individual particles are affected by their own current speed effect, self-memory effect, and group effect, and move closer to the global optimal solution, and finally achieve the global optimal solution, as shown in Figure 3(b).Figure 3
PSO principle.


## 3.2. Optimization of CSA by PSO

The PSO algorithm randomly generates particles of a certain size as an effective solution to the search space of the problem and then performs an iterative search to obtain the optimization result [29]. The solution process of particles is affected by the historical optimal solution of the particle and the optimal solution of the group so that the particle can search and develop in the search space, and finally find the global optimal solution, which is a kind of global search. Therefore, PSO is used to optimize the local precociousness, late oscillation [30], and long calculation process of CSA in the process of mutation, which affects the friendliness of the model.In the optimization process, each antibody setCj with high affinity is used as a particle in the space, and the initial velocity v0 of each particle is randomly generated, then the initial velocity of the i-th antibody is vi0, and the velocity of each particle is v0. The feature vector Hvi0 = (hv1, hv2, …, hvn)T, the greater the affinity between the antigen Ag(M) and the Ab, the better the position of the antibody. At the same time, the number of iterations of each antibody mutation is set to Q, each particle is iterated to the q-th generation position, and the searched optimal position is recorded as P(q), then P(q) = fmax, where q = {1, 2, …, Q}; under this algorithm, the entire particle swarm is updated to the end of the Q-th generation, and the optimal position searched is Pi(q), Pi(q) = fmax, PSO is based on P0(q), and Pi(q) update its speed vin and position until q = Q and realize its optimal variation of CSA. The process is described as follows:(8)viq+1=ωviq+r1t1P1q−Ab1q+⋯+r2t2Piq−Abmq,Abmq+1=Abmq+vmq,where v is the inertia weight, the learning factors r1 and r2 are nonnegative constants, the number of random changes of r1, r2 (r1 ∈ [0, 1], r2 ∈ [0, 1]), the PSO-optimized variant antibody constitutes the antibody set Cj∗, and the total number of mutated set antibodies remains the same as n [31].


## 3.3. The Basic Process of the Model

After the data collected by the downhole sensor is normalized, it will be identified by the PSO-CSA model to determine whether there is a danger of coal and gas outburst. According to the need for recognition, this model has been realized through the training learning process and the verification application process in turn:(1)
Model training and learning: we set the recognition mode of the model to three categories, serious outburst risk, general outburst risk, and no outburst risk, identified as a significant risk. The collected index data of underground coal and gas outbursts are divided into a training set and a recognition set. The training set is used as an antigen to stimulate the antibody set. The antibody set undergoes algorithmic processes such as cloning and the PSO optimization and mutation to generate memory cells that can recognize abnormal antigens gathered.(2)
Verification application: we use the trained model, that is, the set of memory cells in the model, to identify the recognition set to determine whether it has outburst danger. As shown in Figure4.Figure 4
Model training process.Assuming that the recognition of coal and gas outburst has obtained the corresponding memory cell set through the training process, then both coal and gas outburst and no coal and gas outburst can be recognized by the model, and the application process is to use the memory generated by the training process. Cell collection is used to identify and judge whether the measured data have outburst risk. Figure5 shows the identification process.Figure 5
Model application process.The data of the recognition set is normalized and input as an antigen, and whether there is an abnormality is judged by calculating the affinity between the antigen and the memory cell set.Starting from no protrusion, if the highest affinity between the memory cells in the set Ab(m) and Ab is greater than w (w ∈ (0, 1)), it is recognized as normal, that is, fmaxw, and it is judged that there is no risk of protrusion. Then, calculate the affinity of all memory cells in the Ab set, and whether the memory cell with the highest affinity with Ab has an outburst risk is the Ab set data with outburst risk, to achieve the purpose of identification.The data of the recognition set is normalized and input as an antigen, and whether there is an abnormality is judged by calculating the affinity between the antigen and the memory cell set.Starting from no protrusion, if the highest affinity between the memory cells in the set Ab(m) and Ab is greater than w (w ∈ (0, 1)), it is recognized as normal, that is fmax, and it is judged that there is no risk of protrusion. Then, calculate the affinity of all memory cells in the Ab set, and whether the memory cell with the highest affinity with Ab having an outburst risk is the Ab set data with outburst risk to achieve the purpose of identification.At the same time, set up the model. If more than 10 or more abnormal data entered in the model appear one after another, or the abnormal data are continuously input in a short period, the model will stop computing and give alarm feedback immediately. However, if the model occasionally has individual abnormal data, the model will be automatically eliminated and not used as identification data, reducing the possibility of extreme abnormalities in the model.


## 4. Applications

### 4.1. Data Selection

The extraction of coal and gas outburst risk characteristics is based on the selection of gas outburst risk index factors. Due to the dynamic movement of coal mining operations and the continuous increase of mining depth, factors affecting gas outburst, the pressure of coal seam gas, adsorption and desorption of coal seam gas, and other factors are constantly changing [32]. The degree of correlation of prominent risk indicators is also changing in real time. According to the 2019 edition of the “ Detailed Rules for the Prevention and Control of Coal and Gas Outburst ” of the China National Mine Safety Administration, the prediction indicators for local outbursts mainly include the drilling cuttings weight S and the cuttings gas desorption index K1. Table 1 lists the critical value provisions for several indicators in the “Detailed Rules for the Prevention and Control of Coal and Gas Outburst” of the China National Mine Safety Administration. This paper adopts the index method combining the comprehensive index method, the drilling cuttings gas desorption index method, and the drilling cuttings method.Table 1
Prediction index and critical value of coal seam outburst risk.
Drilling cuttings weight (S)Cuttings gas desorption indexK1Initial velocity gas emission index ΔpThe danger of coal and gas outburstkg/mL/mmL/(g·min1/2)mmHg≥6≥5.4≥0.5≥10With<6<5.4<0.5<10WithoutIn this paper, the initial velocity gas emission index Δp, the drilling cuttings weight S, and the cuttings gas desorption index K1 are three characteristic indicators of the risk of coal and gas outburst. And there is a prominent danger to the setting that exceeds the critical value. The data required for verification comes from the 3# coal seam of a coal mine from Shanxi Province in China. Since many structures are near the coal seam, coal and gas outbursts have occurred frequently. It is possible for coal and gas outburst to occur again, and the selected data show the following characteristics. Due to the large measurement time span, this data can effectively reflect the change law of coal and gas outburst in a long period of time. The data in the period exceeds the critical value, showing the possibility of outburst, and then the data can be used to predict the coal and gas outburst of the coal seam. The used cuttings gas desorption index K1 and the drilling cuttings weight S are all measured by the WTC gas outburst parameter instrument and the initial velocity gas emission index Δp by using the WT − 1 gas diffusion velocity measuring instrument of the CCTEG China Coal Research Institute. The above data are measured in accordance with China’s GB/T-212 Coal Industrial Analysis Method, MT38 Coal and Rock Physical and Mechanical Properties Sampling General Regulations, and AQ/T1065-2008 Drilling Cuttings Gas Desorption Index Measurement Method. Therefore, the identification and evaluation of the outburst risk of this coal seam can verify the feasibility and value of the model.The selected data are shown in Table2:Table 2
3# coal seam to collect raw data.
iΔp (mmHg)K1 (mL/(g·min1/2))S (kg/m)116.690.363.2216.480.113.0318.210.313.8417.630.163.6┇┇┇┇39916.020.273.440016.530.373.8Homogenize the raw data collected in Table2 and obtain the membership value in Table 3. The interval is between 0 and 1. According to the standard of homogenization, 0.1 is used for the data without outburst risk. It is represented by 0.6 if there is a general outburst risk; if the outburst risk is more serious or shows obvious outburst risk, and the collected data exceeds the critical value, it is represented by 1. In response to this normalization principle, the model recognizes the salient risk on the scene according to the following rules: if the recognition result is less than 0.35, it is regarded as no outburst risk; if the recognition result is between 0.35 and 0.8, output the result of the general salient risk; and the result greater than 0.8 is considered to have serious salient danger.Table 3
3# coal seam original data normalization.
iΔp (mmHg)K1 (mL/(g·min1/2))S (kg/m)10.420.790.2520.350.030.0030.880.641.0040.700.180.75┇┇┇┇3990.210.520.504000.370.821.00Since each index has different effects on coal and gas outburst, according to the calculation and analysis of different index data of this coal mine, different weights are used for the three indicators used, and the identification correlation degree is used to improve the success rate of identification of the outburst risk, as shown in Table4. According to the research content of the paper [33] and the assignment of the three indicators according to the identified object coal mines are shown in Table 4. The same indicator weights will be used to control the same variables in the CSA and PSO-CSA algorithms. Firstly, observe whether the two algorithms can be used to identify the risk of coal and gas outburst, and secondly, only consider the measurement of the operation results of the two algorithms, such as the operation time and the number of iterations required to achieve the recognition accuracy. Compare whether PSO has an optimal effect on CSA.Table 4
Weights associated with each indicator.
IndicatorΔp(mmHg)K1(mL/(g·min1/2))S(kg/m)Identify relevance ranking0.720.680.65123


### 4.2. Algorithm Running and Analysis

#### 4.2.1. CSA Identification

Normalize the selected data and use the first 300 data as the training set to train the model, then use the last 100 data as the identification set, use CSA for identification, and identify the data that exceed the critical value of the outburst indicators, as there are exceptions to data processing that lead to prominence [34]. The identification thresholds of the algorithm without outburst risk are divided into 0.35 and 0.80. The recognition success rate is calculated.


#### 4.2.2. PSO-CSA Identification

Under the same data and setting conditions, using PSO to optimize the CSA algorithm, the result is shown in the red dot-line diagram in Figures6–9, where the recognition success rate is calculated as follows:(9)t=TsucT×100%,where Tsuc(0 ≤ Tsuc ≤ 100) is the number of antigens successfully recognized in the antigen set, and T is the total number of antigens in the recognition set.


#### 4.2.3. Identification Results and Analysis

The CSA and PSO-CSA algorithms are used for calculation, respectively, and the calculation results are as follows. In Figure6, the recognition success rate of the two algorithms increases with the increase of the cloning rate. After the cloning rate u > 5, the recognition success rate t begins to stabilize, and the range of change decreases. In the process of increasing the cloning rate of 1 ≤ u ≤ 5, the recognition success rate t of CSA increased from 61% to 80%, while the recognition success rate after PSO optimization increased from 62% to 85%. With the continuous increase of u, the recognition success rate t of CSA remains around 81%, and the success rate t after PSO optimization fluctuates at 85%. The comparison shows that after PSO optimization, the recognition success rate of abnormality in coal and gas outburst index data is improved, and when the cloning rate is low, that is, when the number of antibodies is small, PSO can avoid high-affinity antibodies from being detected. Destruction ensures that the mutated antibody population can have a higher affinity, and the recognition rate is significantly higher than that before optimization. Under the influence of different cloning rates, the optimization effect of the CSA algorithm is achieved, the effect is good, and the success rate of identifying abnormal data in the coal and gas outburst index data is improved Figure 6.Figure 6
The curve of the identification success ratet versus the cloning rate u.Based on the above algorithm settings and calculation results, the cloning rate is set to 10. As shown in Figure7, the recognition success rate t of the two algorithms increases with the number of iterations. When the number of iterations is 10 ≤ d ≤ 50, the recognition success rate t increased from 62% to 80%, and after PSO optimization, at 10 ≤ d ≤ 30, the recognition success rate t increased from 74% to 85%, achieving higher recognition in fewer iteration rates. After that, as the number of iterations d increases, both stabilize, and the recognition rate is 5% higher after optimization. This is because, in the process of each iterative mutation, each antibody particle approaches the optimal particle with the closest distance, and the antibody with higher affinity is rapidly generated, which speeds up the convergence speed. However, due to the uncertainty of the direction of antibody mutation in CSA, as the number of iterations increases, the scale of the operation becomes larger, and the operation becomes slower. It shows that PSO reduces the number of iterations, improves the convergence speed of CSA, and improves the success rate of identification Figure 7.Figure 7
The curve of the recognition success ratet versus the number of iterations d.As shown in Figure8, with the increase of the memory cell replacement threshold, when the threshold value is 0.8, the recognition success rate t of the algorithm after PSO optimization is 65%, and when the threshold value is close to 1, the recognition success rate t reaches the maximum value and reaches 88%. At this time, the candidate memory cells are injected into the memory cell set, but the candidate memory cells will not replace the matching memory cells, and the quality of the cells in the memory cell set is thus improved, thereby improving the success rate of identification, indicating that the PSO optimization mutation is effective. The antibody collection evolves in the direction of high affinity, and the recognition success rate is increased by an average of 5%, and the optimization effect is obvious.Figure 8
Change curve of recognition success ratet with memory cell replacement threshold e.The highest affinityfmax is set as Φ (Φ ∈ (0, 1)) as the normal threshold mode, that is the input data are identified as a normal mode, otherwise it is a failure mode. As shown in the dot-line diagram in Figure 9, with the increase of Φ, the abnormal identification success rate t of the two algorithms increases. After t reaches the maximum, it decreases with the increase of Φ, and at 0.5 < Φ < 0.65, the recognition success rate of CSA was greater than that of PSO-CSA, while at 0.65 < Φ < 1, the opposite result occurred, which was because when Φ was small, the affinity between abnormal antigens and normal pattern memory cells was increased. After t reaches the maximum, it decreases with the increase of Φ, and at 0.5 < Φ < 0.65, the recognition success rate of CSA was greater than that of PSO-CSA, while at 0.65 < Φ < 1, the opposite result occurred, which was because when Φ was small, the affinity between abnormal antigens and normal pattern memory cells was increased. The degree of harmony is low, and it is judged to be a normal situation, and there is no danger of coal and gas outburst. At this time, some abnormal samples will be judged as normal and do not have outburst risk; on the contrary, when the Φ is larger, the affinity between the abnormal antigen and the normal pattern of memory cells will be judged as normal. At this time, samples without outburst risk will be identified as patterns with outburst risk, which will lead to a decrease in the success rate of abnormal identification.Figure 9
Relationship between threshold Φ and recognition rate.


#### 4.2.4. Comparison of Identified Salient Risk with Actual Salient Risk

10 groups of data were randomly selected from the identification set to verify the model identification results. The comparison between the actual coal and gas outburst and the model identification results is shown in Table5.Table 5
Comparison of PSO-CSA identification results and actual outburst risk.
iΔpK1SActual outburst riskOutburst risk identified by PSO-CSA31815.360.233.2GeneralGeneral32915.760.163.0WithoutWithout33116.320.282.9GeneralGeneral34716.750.322.8GeneralGeneral35517.340.223.6GeneralGeneral35717.280.343.5GeneralGeneral37117.890.434.0SevereSevere38916.790.263.8GeneralGeneral39016.560.344.2SevereSevere39415.080.313.6GeneralGeneralFrom the comparison in Table5, it can be seen that through the verification of 10 groups of random sample data, it can be seen that the identification results of the coal and gas outburst identification model based on PSO-CSA are consistent with the actual coal and gas outburst situation, which shows that the identification model is suitable for coal and gas outburst. The prevention and control of coal and gas outburst in the process of coal mining have certain reference and use value.


## 4.1. Data Selection

The extraction of coal and gas outburst risk characteristics is based on the selection of gas outburst risk index factors. Due to the dynamic movement of coal mining operations and the continuous increase of mining depth, factors affecting gas outburst, the pressure of coal seam gas, adsorption and desorption of coal seam gas, and other factors are constantly changing [32]. The degree of correlation of prominent risk indicators is also changing in real time. According to the 2019 edition of the “ Detailed Rules for the Prevention and Control of Coal and Gas Outburst ” of the China National Mine Safety Administration, the prediction indicators for local outbursts mainly include the drilling cuttings weight S and the cuttings gas desorption index K1. Table 1 lists the critical value provisions for several indicators in the “Detailed Rules for the Prevention and Control of Coal and Gas Outburst” of the China National Mine Safety Administration. This paper adopts the index method combining the comprehensive index method, the drilling cuttings gas desorption index method, and the drilling cuttings method.Table 1
Prediction index and critical value of coal seam outburst risk.
Drilling cuttings weight (S)Cuttings gas desorption indexK1Initial velocity gas emission index ΔpThe danger of coal and gas outburstkg/mL/mmL/(g·min1/2)mmHg≥6≥5.4≥0.5≥10With<6<5.4<0.5<10WithoutIn this paper, the initial velocity gas emission index Δp, the drilling cuttings weight S, and the cuttings gas desorption index K1 are three characteristic indicators of the risk of coal and gas outburst. And there is a prominent danger to the setting that exceeds the critical value. The data required for verification comes from the 3# coal seam of a coal mine from Shanxi Province in China. Since many structures are near the coal seam, coal and gas outbursts have occurred frequently. It is possible for coal and gas outburst to occur again, and the selected data show the following characteristics. Due to the large measurement time span, this data can effectively reflect the change law of coal and gas outburst in a long period of time. The data in the period exceeds the critical value, showing the possibility of outburst, and then the data can be used to predict the coal and gas outburst of the coal seam. The used cuttings gas desorption index K1 and the drilling cuttings weight S are all measured by the WTC gas outburst parameter instrument and the initial velocity gas emission index Δp by using the WT − 1 gas diffusion velocity measuring instrument of the CCTEG China Coal Research Institute. The above data are measured in accordance with China’s GB/T-212 Coal Industrial Analysis Method, MT38 Coal and Rock Physical and Mechanical Properties Sampling General Regulations, and AQ/T1065-2008 Drilling Cuttings Gas Desorption Index Measurement Method. Therefore, the identification and evaluation of the outburst risk of this coal seam can verify the feasibility and value of the model.The selected data are shown in Table2:Table 2
3# coal seam to collect raw data.
iΔp (mmHg)K1 (mL/(g·min1/2))S (kg/m)116.690.363.2216.480.113.0318.210.313.8417.630.163.6┇┇┇┇39916.020.273.440016.530.373.8Homogenize the raw data collected in Table2 and obtain the membership value in Table 3. The interval is between 0 and 1. According to the standard of homogenization, 0.1 is used for the data without outburst risk. It is represented by 0.6 if there is a general outburst risk; if the outburst risk is more serious or shows obvious outburst risk, and the collected data exceeds the critical value, it is represented by 1. In response to this normalization principle, the model recognizes the salient risk on the scene according to the following rules: if the recognition result is less than 0.35, it is regarded as no outburst risk; if the recognition result is between 0.35 and 0.8, output the result of the general salient risk; and the result greater than 0.8 is considered to have serious salient danger.Table 3
3# coal seam original data normalization.
iΔp (mmHg)K1 (mL/(g·min1/2))S (kg/m)10.420.790.2520.350.030.0030.880.641.0040.700.180.75┇┇┇┇3990.210.520.504000.370.821.00Since each index has different effects on coal and gas outburst, according to the calculation and analysis of different index data of this coal mine, different weights are used for the three indicators used, and the identification correlation degree is used to improve the success rate of identification of the outburst risk, as shown in Table4. According to the research content of the paper [33] and the assignment of the three indicators according to the identified object coal mines are shown in Table 4. The same indicator weights will be used to control the same variables in the CSA and PSO-CSA algorithms. Firstly, observe whether the two algorithms can be used to identify the risk of coal and gas outburst, and secondly, only consider the measurement of the operation results of the two algorithms, such as the operation time and the number of iterations required to achieve the recognition accuracy. Compare whether PSO has an optimal effect on CSA.Table 4
Weights associated with each indicator.
IndicatorΔp(mmHg)K1(mL/(g·min1/2))S(kg/m)Identify relevance ranking0.720.680.65123


## 4.2. Algorithm Running and Analysis

### 4.2.1. CSA Identification

Normalize the selected data and use the first 300 data as the training set to train the model, then use the last 100 data as the identification set, use CSA for identification, and identify the data that exceed the critical value of the outburst indicators, as there are exceptions to data processing that lead to prominence [34]. The identification thresholds of the algorithm without outburst risk are divided into 0.35 and 0.80. The recognition success rate is calculated.


### 4.2.2. PSO-CSA Identification

Under the same data and setting conditions, using PSO to optimize the CSA algorithm, the result is shown in the red dot-line diagram in Figures6–9, where the recognition success rate is calculated as follows:(9)t=TsucT×100%,where Tsuc(0 ≤ Tsuc ≤ 100) is the number of antigens successfully recognized in the antigen set, and T is the total number of antigens in the recognition set.


### 4.2.3. Identification Results and Analysis

The CSA and PSO-CSA algorithms are used for calculation, respectively, and the calculation results are as follows. In Figure6, the recognition success rate of the two algorithms increases with the increase of the cloning rate. After the cloning rate u > 5, the recognition success rate t begins to stabilize, and the range of change decreases. In the process of increasing the cloning rate of 1 ≤ u ≤ 5, the recognition success rate t of CSA increased from 61% to 80%, while the recognition success rate after PSO optimization increased from 62% to 85%. With the continuous increase of u, the recognition success rate t of CSA remains around 81%, and the success rate t after PSO optimization fluctuates at 85%. The comparison shows that after PSO optimization, the recognition success rate of abnormality in coal and gas outburst index data is improved, and when the cloning rate is low, that is, when the number of antibodies is small, PSO can avoid high-affinity antibodies from being detected. Destruction ensures that the mutated antibody population can have a higher affinity, and the recognition rate is significantly higher than that before optimization. Under the influence of different cloning rates, the optimization effect of the CSA algorithm is achieved, the effect is good, and the success rate of identifying abnormal data in the coal and gas outburst index data is improved Figure 6.Figure 6
The curve of the identification success ratet versus the cloning rate u.Based on the above algorithm settings and calculation results, the cloning rate is set to 10. As shown in Figure7, the recognition success rate t of the two algorithms increases with the number of iterations. When the number of iterations is 10 ≤ d ≤ 50, the recognition success rate t increased from 62% to 80%, and after PSO optimization, at 10 ≤ d ≤ 30, the recognition success rate t increased from 74% to 85%, achieving higher recognition in fewer iteration rates. After that, as the number of iterations d increases, both stabilize, and the recognition rate is 5% higher after optimization. This is because, in the process of each iterative mutation, each antibody particle approaches the optimal particle with the closest distance, and the antibody with higher affinity is rapidly generated, which speeds up the convergence speed. However, due to the uncertainty of the direction of antibody mutation in CSA, as the number of iterations increases, the scale of the operation becomes larger, and the operation becomes slower. It shows that PSO reduces the number of iterations, improves the convergence speed of CSA, and improves the success rate of identification Figure 7.Figure 7
The curve of the recognition success ratet versus the number of iterations d.As shown in Figure8, with the increase of the memory cell replacement threshold, when the threshold value is 0.8, the recognition success rate t of the algorithm after PSO optimization is 65%, and when the threshold value is close to 1, the recognition success rate t reaches the maximum value and reaches 88%. At this time, the candidate memory cells are injected into the memory cell set, but the candidate memory cells will not replace the matching memory cells, and the quality of the cells in the memory cell set is thus improved, thereby improving the success rate of identification, indicating that the PSO optimization mutation is effective. The antibody collection evolves in the direction of high affinity, and the recognition success rate is increased by an average of 5%, and the optimization effect is obvious.Figure 8
Change curve of recognition success ratet with memory cell replacement threshold e.The highest affinityfmax is set as Φ (Φ ∈ (0, 1)) as the normal threshold mode, that is the input data are identified as a normal mode, otherwise it is a failure mode. As shown in the dot-line diagram in Figure 9, with the increase of Φ, the abnormal identification success rate t of the two algorithms increases. After t reaches the maximum, it decreases with the increase of Φ, and at 0.5 < Φ < 0.65, the recognition success rate of CSA was greater than that of PSO-CSA, while at 0.65 < Φ < 1, the opposite result occurred, which was because when Φ was small, the affinity between abnormal antigens and normal pattern memory cells was increased. After t reaches the maximum, it decreases with the increase of Φ, and at 0.5 < Φ < 0.65, the recognition success rate of CSA was greater than that of PSO-CSA, while at 0.65 < Φ < 1, the opposite result occurred, which was because when Φ was small, the affinity between abnormal antigens and normal pattern memory cells was increased. The degree of harmony is low, and it is judged to be a normal situation, and there is no danger of coal and gas outburst. At this time, some abnormal samples will be judged as normal and do not have outburst risk; on the contrary, when the Φ is larger, the affinity between the abnormal antigen and the normal pattern of memory cells will be judged as normal. At this time, samples without outburst risk will be identified as patterns with outburst risk, which will lead to a decrease in the success rate of abnormal identification.Figure 9
Relationship between threshold Φ and recognition rate.


### 4.2.4. Comparison of Identified Salient Risk with Actual Salient Risk

10 groups of data were randomly selected from the identification set to verify the model identification results. The comparison between the actual coal and gas outburst and the model identification results is shown in Table5.Table 5
Comparison of PSO-CSA identification results and actual outburst risk.
iΔpK1SActual outburst riskOutburst risk identified by PSO-CSA31815.360.233.2GeneralGeneral32915.760.163.0WithoutWithout33116.320.282.9GeneralGeneral34716.750.322.8GeneralGeneral35517.340.223.6GeneralGeneral35717.280.343.5GeneralGeneral37117.890.434.0SevereSevere38916.790.263.8GeneralGeneral39016.560.344.2SevereSevere39415.080.313.6GeneralGeneralFrom the comparison in Table5, it can be seen that through the verification of 10 groups of random sample data, it can be seen that the identification results of the coal and gas outburst identification model based on PSO-CSA are consistent with the actual coal and gas outburst situation, which shows that the identification model is suitable for coal and gas outburst. The prevention and control of coal and gas outburst in the process of coal mining have certain reference and use value.


## 4.2.1. CSA Identification

Normalize the selected data and use the first 300 data as the training set to train the model, then use the last 100 data as the identification set, use CSA for identification, and identify the data that exceed the critical value of the outburst indicators, as there are exceptions to data processing that lead to prominence [34]. The identification thresholds of the algorithm without outburst risk are divided into 0.35 and 0.80. The recognition success rate is calculated.


## 4.2.2. PSO-CSA Identification

Under the same data and setting conditions, using PSO to optimize the CSA algorithm, the result is shown in the red dot-line diagram in Figures6–9, where the recognition success rate is calculated as follows:(9)t=TsucT×100%,where Tsuc(0 ≤ Tsuc ≤ 100) is the number of antigens successfully recognized in the antigen set, and T is the total number of antigens in the recognition set.


## 4.2.3. Identification Results and Analysis

The CSA and PSO-CSA algorithms are used for calculation, respectively, and the calculation results are as follows. In Figure6, the recognition success rate of the two algorithms increases with the increase of the cloning rate. After the cloning rate u > 5, the recognition success rate t begins to stabilize, and the range of change decreases. In the process of increasing the cloning rate of 1 ≤ u ≤ 5, the recognition success rate t of CSA increased from 61% to 80%, while the recognition success rate after PSO optimization increased from 62% to 85%. With the continuous increase of u, the recognition success rate t of CSA remains around 81%, and the success rate t after PSO optimization fluctuates at 85%. The comparison shows that after PSO optimization, the recognition success rate of abnormality in coal and gas outburst index data is improved, and when the cloning rate is low, that is, when the number of antibodies is small, PSO can avoid high-affinity antibodies from being detected. Destruction ensures that the mutated antibody population can have a higher affinity, and the recognition rate is significantly higher than that before optimization. Under the influence of different cloning rates, the optimization effect of the CSA algorithm is achieved, the effect is good, and the success rate of identifying abnormal data in the coal and gas outburst index data is improved Figure 6.Figure 6
The curve of the identification success ratet versus the cloning rate u.Based on the above algorithm settings and calculation results, the cloning rate is set to 10. As shown in Figure7, the recognition success rate t of the two algorithms increases with the number of iterations. When the number of iterations is 10 ≤ d ≤ 50, the recognition success rate t increased from 62% to 80%, and after PSO optimization, at 10 ≤ d ≤ 30, the recognition success rate t increased from 74% to 85%, achieving higher recognition in fewer iteration rates. After that, as the number of iterations d increases, both stabilize, and the recognition rate is 5% higher after optimization. This is because, in the process of each iterative mutation, each antibody particle approaches the optimal particle with the closest distance, and the antibody with higher affinity is rapidly generated, which speeds up the convergence speed. However, due to the uncertainty of the direction of antibody mutation in CSA, as the number of iterations increases, the scale of the operation becomes larger, and the operation becomes slower. It shows that PSO reduces the number of iterations, improves the convergence speed of CSA, and improves the success rate of identification Figure 7.Figure 7
The curve of the recognition success ratet versus the number of iterations d.As shown in Figure8, with the increase of the memory cell replacement threshold, when the threshold value is 0.8, the recognition success rate t of the algorithm after PSO optimization is 65%, and when the threshold value is close to 1, the recognition success rate t reaches the maximum value and reaches 88%. At this time, the candidate memory cells are injected into the memory cell set, but the candidate memory cells will not replace the matching memory cells, and the quality of the cells in the memory cell set is thus improved, thereby improving the success rate of identification, indicating that the PSO optimization mutation is effective. The antibody collection evolves in the direction of high affinity, and the recognition success rate is increased by an average of 5%, and the optimization effect is obvious.Figure 8
Change curve of recognition success ratet with memory cell replacement threshold e.The highest affinityfmax is set as Φ (Φ ∈ (0, 1)) as the normal threshold mode, that is the input data are identified as a normal mode, otherwise it is a failure mode. As shown in the dot-line diagram in Figure 9, with the increase of Φ, the abnormal identification success rate t of the two algorithms increases. After t reaches the maximum, it decreases with the increase of Φ, and at 0.5 < Φ < 0.65, the recognition success rate of CSA was greater than that of PSO-CSA, while at 0.65 < Φ < 1, the opposite result occurred, which was because when Φ was small, the affinity between abnormal antigens and normal pattern memory cells was increased. After t reaches the maximum, it decreases with the increase of Φ, and at 0.5 < Φ < 0.65, the recognition success rate of CSA was greater than that of PSO-CSA, while at 0.65 < Φ < 1, the opposite result occurred, which was because when Φ was small, the affinity between abnormal antigens and normal pattern memory cells was increased. The degree of harmony is low, and it is judged to be a normal situation, and there is no danger of coal and gas outburst. At this time, some abnormal samples will be judged as normal and do not have outburst risk; on the contrary, when the Φ is larger, the affinity between the abnormal antigen and the normal pattern of memory cells will be judged as normal. At this time, samples without outburst risk will be identified as patterns with outburst risk, which will lead to a decrease in the success rate of abnormal identification.Figure 9
Relationship between threshold Φ and recognition rate.


## 4.2.4. Comparison of Identified Salient Risk with Actual Salient Risk

10 groups of data were randomly selected from the identification set to verify the model identification results. The comparison between the actual coal and gas outburst and the model identification results is shown in Table5.Table 5
Comparison of PSO-CSA identification results and actual outburst risk.
iΔpK1SActual outburst riskOutburst risk identified by PSO-CSA31815.360.233.2GeneralGeneral32915.760.163.0WithoutWithout33116.320.282.9GeneralGeneral34716.750.322.8GeneralGeneral35517.340.223.6GeneralGeneral35717.280.343.5GeneralGeneral37117.890.434.0SevereSevere38916.790.263.8GeneralGeneral39016.560.344.2SevereSevere39415.080.313.6GeneralGeneralFrom the comparison in Table5, it can be seen that through the verification of 10 groups of random sample data, it can be seen that the identification results of the coal and gas outburst identification model based on PSO-CSA are consistent with the actual coal and gas outburst situation, which shows that the identification model is suitable for coal and gas outburst. The prevention and control of coal and gas outburst in the process of coal mining have certain reference and use value.


## 5. Conclusion

(1)
The CSA is used to identify data anomalies in coal and gas outburst indicators, and it is found that this method can effectively identify anomalies, and the method is feasible, but there are also problems of local early maturity and later shocks, which lead to the decline of the recognition rate.(2)
The PSO was used to optimize the variation of CSA. By comparing before and after optimization, under the conditions of different cloning rates, iteration times, and matching memory cell replacement thresholds, the success rates of coal and gas outburst risk anomaly identification were improved to varying degrees, and the highest rate was the highest of all. There is an increase of 10%. It is found that the PSO method can optimize the uncertainty of the variation direction of CSA so that excellent antibodies can be preserved, and the problems of slow calculation caused by repetitive coding in CSA and replacement of excellent antibodies by new antibodies are solved.(3)
A PSO-CSA-based coal and gas outburst risk identification model was established, and by using the measured data, it was verified that the identification results of this method were consistent with the field measured outburst risk, which proved that the model was practical for the prevention and control of coal and gas outbursts value, which can be used to guide engineering practice.



---

*Source: 5299986-2023-01-10.xml*