Efficient Graphical Algorithm of Sensor Distribution and Air Volume Reconstruction for a Smart Mine Ventilation Network

The accurate and reliable monitoring of ventilation parameters is key to intelligent ventilation systems. In order to realize the visualization of airflow, it is essential to solve the airflow reconstruction problem using few sensors. In this study, a new concept called independent cut set that depends on the structure of the underlying graph is presented to determine the minimum number and location of sensors. We evaluated its effectiveness in a coal mine owned by Jinmei Corporation Limited (Jinmei Co., Ltd., Shanghai, China). Our results indicated that fewer than 30% of tunnels needed to have wind speed sensors set up to reconstruct the well-posed airflow of all the tunnels (>200 in some mines). The results showed that the algorithm was feasible. The reconstructed air volume of the ventilation network using this algorithm was the same as the actual air volume. The algorithm provides theoretical support for flow reconstruction.


Introduction
Coal is a primary energy source and plays a key role in economic development in many countries. In China, coal accounts for 40-45% of total carbon emissions [1]. Meanwhile, due to the unique working environment in coal mines, the requirements for safe operations are very high. The working environment affects the safety of those working in coal mines. Mining accidents could cause significant loss of life, as well as economic losses to a country. In 2020 alone, 573 Chinese miners died in 434 mining accidents such as leaks of poisonous gases, explosions of natural gases, and the collapsing of mine stopes, especially from underground coal mining [2]. An efficient and reliable ventilation system is essential for safe and efficient production of coal [3].
Intelligent ventilation is a development trend for coal mines and other types of mines. The Chinese National Development and Reform Commission and eight other ministries jointly issued Guiding Opinions on Accelerating the Intelligent Development of Coal Mines to improve the intelligence level of coal mines. A set of systems, including development design, geological guarantee, mining, transportation, and ventilation, are needed to achieve the goal of intelligent decision-making and automation systems operating collaboratively by 2025 [4,5]. Intelligent coal mining is to be fully realized by 2035 [6]. The reliable operation of mine ventilation systems is the basis for safe production in intelligent coal and noncoal mines. Intelligent mine ventilation is a new ventilation system that can be adjusted automatically on demand, which is the development trend of mine ventilation technology in China [7]. Proper monitoring of airflows for all tunnels plays a key role in the development of intelligent mine ventilation systems [8,9]. Airflow monitoring depends A fully visual environment of ventilation parameters is very important to realize intelligent ventilation of mines. In order to visualize the air volume, an air volume reconstruction algorithm is proposed in this paper. In past studies, optimization and reconstruction technologies of sensor networks were widely used in flow monitoring [12], for the development of intelligent systems [13], and for leak location diagnosis for water [14][15][16], oil [17,18], and gas [19][20][21] pipeline networks. Singh et al. [22] proposed a method to identify ideal monitoring sites for water quality. Huang et al. [23] established a PSO-LSTM model to realize the identification of sources with abnormal radon exhalation rates. Castillo et al. [24] proposed a method of flow reconstruction by constructing a matrix of constraints to give bounds on the number of sensors required. In this method, the construction of a constraint matrix depends on all possible paths of the network. For complex networks, the measurement process in this method will also be very complex. The method was optimized to reduce the impact of network complexity [25]. However, the construction of a constraint matrix depends on the network path; although it has been optimized, the construction process is still very complex. Rinaudo et al. [26] proposed a minimum number of sensors arrangement method to determine the temperature. Although this method reduces the cost of monitoring, the measurement process is too complex. Balaji et al. [27] proposed a method to maximize sensor lifetime by activating sensor covers one at a time to monitor the whole network. This method mainly depends on the effective usage of available resources. Li et al. [28] put forward a novel method based on deep learning techniques and transfer learning to deal with large-scale missing data problems. Ng [29]  A fully visual environment of ventilation parameters is very important to realize intelligent ventilation of mines. In order to visualize the air volume, an air volume reconstruction algorithm is proposed in this paper. In past studies, optimization and reconstruction technologies of sensor networks were widely used in flow monitoring [12], for the development of intelligent systems [13], and for leak location diagnosis for water [14][15][16], oil [17,18], and gas [19][20][21] pipeline networks. Singh et al. [22] proposed a method to identify ideal monitoring sites for water quality. Huang et al. [23] established a PSO-LSTM model to realize the identification of sources with abnormal radon exhalation rates. Castillo et al. [24] proposed a method of flow reconstruction by constructing a matrix of constraints to give bounds on the number of sensors required. In this method, the construction of a constraint matrix depends on all possible paths of the network. For complex networks, the measurement process in this method will also be very complex. The method was optimized to reduce the impact of network complexity [25]. However, the construction of a constraint matrix depends on the network path; although it has been optimized, the construction process is still very complex. Rinaudo et al. [26] proposed a minimum number of sensors arrangement method to determine the temperature. Although this method reduces the cost of monitoring, the measurement process is too complex. Balaji et al. [27] proposed a method to maximize sensor lifetime by activating sensor covers one at a time to monitor the whole network. This method mainly depends on the effective usage of available resources. Li et al. [28] put forward a novel method based on deep learning techniques and transfer learning to deal with large-scale missing data problems. Ng [29] proposed a method to calculate the number of sensors without depending on the path. He [30] developed an efficient algorithm to determine the smallest subset of links in a traffic network for sensor installation. Muduli et al. [31] proposed a novel wireless sensor network deployment scheme for environmental monitoring in longwall coal mines, which provided the best area coverage and was very cost-effective. Automated ventilation system adjustment software has been developed by monitoring the air volume of the minimum remainder branch in the network, and all air volumes of the branches in the network can be obtained by inverse calculation of associated branches [32]. Song et al. [33] proposed a method for determining the changing trend of gas concentration in the goaf. Lyu et al. [34] proposed a gas concentration prediction method based on the ARMA model, the CHAOS model, and the encoder-decoder model (single-sensor and multisensor). Foorginezhad et al. [35] proposed advanced sensing systems utilized for relevant monitoring and recommendations for improving sensing accuracy.
Mine ventilation networks are similar to traffic networks on topology. Mine ventilation networks are high-order nonlinear systems [36]. In the literature, different approaches have been used for determining the minimum number of sensors needed to identify the location of a ventilation system's faults [37], such as the coverage of node flowrate method [38], the least full-coverage distribution method [39], minimum tree principle [40], tabu search (TS), Pareto ant colony algorithm (HPACA) [41], and the GA-DBPSO algorithm [42,43]. Changing the airflow in any one of the tunnels leads to changes in other associated tunnels. The sensitivity is used for measuring the airflow relationship between all the tunnels [44].
However, a mine ventilation system is a complex network, with different complexity levels in different areas. There are some problems with considering the accuracy to determine the minimum sensors' location and reconstruct the air volume of all tunnels in the mines. In this study, we aimed to solve the problems of sensor optimization and air flow reconstruction, and realize the air volume monitoring of the whole air network economically and effectively. In this paper, we propose an algorithm for the well-posed reconstruction of the airflow in a mine ventilation network. The algorithm is based on the structure of the underlying graph, and makes it possible to have a unique, optimized solution to the air volume of tunnels. Compared with other methods, this algorithm involves lower costs and a simpler process.
The rest of this paper is organized as follows. We state the problems we aimed to study, provide a theoretical analysis of our research, and explain some concepts that need to be used in Section 2. In Section 3, we introduce the methods of sensor location optimization and flow reconstruction. The above-mentioned methods are transformed into algorithms, and the specific calculation process is expressed by matrices and formulas, which are verified by taking a single-source and single-sink network as an example in Sections 4 and 5. In Section 6, we verify the algorithm by taking multisource and multisink network by the ventilation data of a coal mine. The main conclusions of this paper are given in Section 7.

Problem Statement
Our goal was to locate wind speed sensors so that the airflow of a ventilation network could be inferred from the measurements while minimizing the number of sensors used. We propose a well-posed flow reconstruction algorithm, which uses the flow conservation equations and breadth-first search algorithm to search the whole ventilation network, establish the equations, and then solve the airflow reconstruction problem.

Possibility Analysis on Well-Posed Flow Reconstruction
The correlation between the junction number and tunnel number was obtained, as shown in Figure 2. The junction number increases linearly with the tunnel number. This means that there is more mass conservation at the junctions as the tunnel number increases. For a mine ventilation network with a single sink and a single source, m − 1 mass conservation equations can be established for m junctions with a connecting sink and source as a virtual junction. There are n tunnels in the mine, and n unknown parameters, so n − m + 1 wind speed sensors are needed for the well-posed flow reconstruction if the sensors are set up accurately. Similarly, n − m + k − 1 wind speed sensors are used for multisinks and a multisource network (k denotes the total number of the sinks and sources). The above analysis indicates that the minimum number of sensors needed for a well-posed solution may be under 100 when the tunnel number is less than 380, while more than 300 sensors need to be installed when the tunnel number is over 1500; 100-300 sensors are needed if the range of tunnel numbers is 380-1500, as shown in Figure 3. This shows that the calculation complexity is also affected by the network structure.
shown in Figure 2. The junction number increases linearly with the tunnel number. This means that there is more mass conservation at the junctions as the tunnel number increases. For a mine ventilation network with a single sink and a single source, m − 1 mass conservation equations can be established for m junctions with a connecting sink and source as a virtual junction. There are n tunnels in the mine, and n unknown parameters, so n − m + 1 wind speed sensors are needed for the well-posed flow reconstruction if the sensors are set up accurately. Similarly, n − m + k − 1 wind speed sensors are used for multisinks and a multisource network (k denotes the total number of the sinks and sources). The above analysis indicates that the minimum number of sensors needed for a well-posed solution may be under 100 when the tunnel number is less than 380, while more than 300 sensors need to be installed when the tunnel number is over 1500; 100-300 sensors are needed if the range of tunnel numbers is 380-1500, as shown in Figure 3. This shows that the calculation complexity is also affected by the network structure.     The correlation between the junction number and tunnel number was obtained, as shown in Figure 2. The junction number increases linearly with the tunnel number. This means that there is more mass conservation at the junctions as the tunnel number increases. For a mine ventilation network with a single sink and a single source, m − 1 mass conservation equations can be established for m junctions with a connecting sink and source as a virtual junction. There are n tunnels in the mine, and n unknown parameters, so n − m + 1 wind speed sensors are needed for the well-posed flow reconstruction if the sensors are set up accurately. Similarly, n − m + k − 1 wind speed sensors are used for multisinks and a multisource network (k denotes the total number of the sinks and sources). The above analysis indicates that the minimum number of sensors needed for a well-posed solution may be under 100 when the tunnel number is less than 380, while more than 300 sensors need to be installed when the tunnel number is over 1500; 100-300 sensors are needed if the range of tunnel numbers is 380-1500, as shown in Figure 3. This shows that the calculation complexity is also affected by the network structure.      Figure 4 shows that the ratio of sensor to tunnel number (RST) for well-posed reconstruction is over 30% and even up to 63% when there are fewer than 150 tunnels in the mine, while the RST is below 30% when the tunnels number more than 150. The above data demonstrated that sensors in some mines can be set up for well-posed flow reconstruction where the RST is less than 30% or there are few tunnels. However, there will be no solution or multiple solutions for the reconstruction if the locations of sensors are inaccurate. Therefore, the installation locations of sensors are critical for flow reconstruction. Figure 4 shows that the ratio of sensor to tunnel number (RST) for well-posed reconstruction is over 30% and even up to 63% when there are fewer than 150 tunnels in the mine, while the RST is below 30% when the tunnels number more than 150. The above data demonstrated that sensors in some mines can be set up for well-posed flow reconstruction where the RST is less than 30% or there are few tunnels. However, there will be no solution or multiple solutions for the reconstruction if the locations of sensors are inaccurate. Therefore, the installation locations of sensors are critical for flow reconstruction.

Flow Conservation Equation
Ventilation networks are represented by means of a directed graph: A generalized equation of mass can be derived from Equation (2) and the algebraic sum of the tunnels' flow mass is in any directed cut set of the network with sinks and sources: where = × represents the directed cut set; is the cut set number; is the total mass of the network.

Flow Conservation Equation
Ventilation networks are represented by means of a directed graph: where m is the junction number, E = {e 1 , e 2 , · · · , e n } represents the set of tunnels, and n is the tunnel number. The out branches set is denoted as A generalized equation of mass can be derived from Equation (2) and the algebraic sum of the tunnels' flow mass is Q t in any directed cut set of the network with sinks and sources: where S = s ij s×n represents the directed cut set; s is the cut set number; Q t is the total mass of the network.

Improved Breadth-First Search
An exact mathematical model (i.e., a direct solution) may not be found for some problems. In this case, search methods are generally used to solve the issues, among which a breadth-first search (BFS) is the simplest method.
A BFS is one of the graph algorithms. The process is to search for every possible edge by traditional BFS; each junction can only be visited once. The basic idea is to start from a junction v in the graph. In turn, the graph is traversed in breadth first from the unreachable adjacent junctions of v until the junctions in the graph are connected with the paths of v visited. If any junctions in the graph are not visited at this time, the breadth-first traversal is performed again from a junction that has not been visited until all the junctions in the graph have been accessed. Figure 5 is a ventilation network diagram of single source and single sink. It shows a schematic diagram of an independent cut set. If we launch a BFS from junction v 2 (the following access order is not unique, and the second point can be either v 3 or v 4 ), we may get an access process as follows: We then go back to v 3 . We can get the access process as follows: For the same reason, we can go back to v 2 . We can then continue to breadth-first search (BFS) is the simplest method.
A BFS is one of the graph algorithms. The process is to search for every possible edge by traditional BFS; each junction can only be visited once. The basic idea is to start from a junction v in the graph. In turn, the graph is traversed in breadth first from the unreachable adjacent junctions of v until the junctions in the graph are connected with the paths of v visited. If any junctions in the graph are not visited at this time, the breadth-first traversal is performed again from a junction that has not been visited until all the junctions in the graph have been accessed. Figure 5 is a ventilation network diagram of single source and single sink. It shows a schematic diagram of an independent cut set. If we launch a BFS from junction (the following access order is not unique, and the second point can be either or ), we may get an access process as follows: − − − . We then go back to . We can get the access process as follows: − − − − − . For the same reason, we can go back to . We can then continue to search − − − − . The search is finished when all junctions are visited. The result of each BFS must be a connected component of the graph. According to the analysis in Section 2.1, the spanning tree structure meets the requirements of well-posed reconstruction. Therefore, an improved breadth-first search According to the analysis in Section 2.1, the spanning tree structure meets the requirements of well-posed reconstruction. Therefore, an improved breadth-first search (IBFS) method is proposed, based on the spanning tree structure instead of the whole network.
An IBFS is a search algorithm based on the spanning tree structure. The first step of an IBFS is to determine the spanning tree and sort the junctions and tunnels of the spanning tree. Then, all source and sink junctions of the spanning tree must be determined. The source junction is taken as the starting junction to start the search, and the incidence branches of the junction are searched. After searching all incidence branches, the search must be continued according to the previous step with the end junction of the incidence branch as the starting junction until the sink junction is searched. The previous junction must then be considered as the starting junction, and other branches are searched for. If there are no other branches, the retreat is continued until the starting junction with other branches is found and the search is maintained. When all branches of the spanning tree are searched, the search ends.
Take Figure 5 as an example; e 1 , e 2 , e 3 , e 4 , e 6 , e 9 , e 10 form a spanning tree. If we launch an IBFS from junction v 1 , we may get an access process as follows: Because v 4 is a sink of the spanning tree, we need to go back to v 2 . The adjacent junction v 3 of junction v 2 has an incidence branch. The next search starts from v 3 . The process is as When all branches of the spanning tree have been searched, the search ends. The IBFS is the basis of our research on sensor optimization and air volume reconstruction. The following algorithms need to use IBFS.

Definition of Single Junction Cut Sets
In the directed graph G = (V, E), v i ∈ v, after deleting junction v i , all tunnels associated with v i from the graph cannot be connected. This is called a single junction cut set (S = D v i ).
In Figure 5, In other words, there are eight single junction cut sets in the directed graph:

Definition of Independent Cut Set
A new concept called independent cut set is proposed. The source-sink matrix describes the ventilation flow in the mine. The source junction set is I, and the sink junction set is O. In the mine ventilation network G = (V, E), I ⊂ V, O ⊂ V, a cut C = (S, T) partitions V into two subsets, S and T. The cut set A of a cut C = (S, T) is the set {(u, v) E|u S, v T, I ⊂ S, O ⊂ T}, which is called the independent cut set. The independent cut set can divide the input and output junctions into two disjointed parts, which means that the removal of all edges disconnects all paths from the input to output junctions, as shown in Figure 5.

Algorithm of Independent Cut Set
An independent cut set search algorithm for a single-source, single-sink ventilation network was studied. The graph is described as: were obtained, such as D v 2 = {e 1 , e 2 , e 3 } for the junction v 2 . A spanning tree that connects all junctions in the mine network without forming a cycle was created, including some tunnels on demand. The spanning tree was then changed to an undirected graph. The breadth-first search starts from the source junction S = D v 1 . When it comes to junction v b in the spanning tree, the independent cut set is calculated by It was followed until the searching of all the junctions of the spanning tree was completed (see Figure 6). obtained, such as = { , , } for the junction . A spanning tree that co junctions in the mine network without forming a cycle was created, including nels on demand. The spanning tree was then changed to an undirected g breadth-first search starts from the source junction = . When it comes to ju in the spanning tree, the independent cut set is calculated by = ∪ − It was followed until the searching of all the junctions of the spanning tree was c (see Figure 6).  Take the network shown in Figure 5, for example; the network graph is: e 3 , e 4 , e 5 , e 6 , e 7 , e 8 , e 9 , e 10 }, n = 10, The spanning tree is: T = {e 1 , e 2 , e 3 , e 4 , e 6 , e 9 , e 10 }. The single junction cut sets for every junction are: According to the flow diagram, the process of obtaining the independent cut set is as shown in Table 1. Table 1. The independent cut set of the graph in Figure 5.

Location Optimization of Wind Speed Sensors
In order to study the minimum number and location of sensors that can completely recover the airflow in a mine network, an algorithm based on the topological structure of the network and the information was developed. The algorithm creates spanning trees and uses the IBFS, a well-known graph traversal algorithm, to search. The inputs of the algorithm on the location of wind speed sensors are the directed graph G = (V, E) and single junction cut set, while the output is the independent cut set. The procedures of the algorithm are as follows: 1.
Change all junctions in V with a single junction and find the single-junction cut set of all junctions.

2.
Initialize V a = V f rom .

3.
Use IBFS over spanning tree starting at v a . Denote e k and v b as the visited edges and junctions, respectively.

4.
Obtain the independent cut set S while e k T: end if T θ; otherwise, search the next spanning tree. To avoid repeated searches, the edges and junctions passing by should be recorded for every independent cut set obtained.

5.
If any junctions in the graph are not visited at this time, the breadth-first traversal must be performed again from a junction that has not been visited until all the junctions in the graph have been accessed. 6.
Put the known air volume into Equation (3) to solve for the unknown air volume.

Flow Reconstruction Method by the Wind Speed Sensors
According to the Chinese industry standards GB/T51272-2018 and AQ2031-2011, it is compulsory to install wind speed sensors in main return tunnels, the return tunnels of all mining areas, and the return tunnels of all sublevels. These tunnels are seen as cotrees for the spanning tree, which can be generated according to the cotrees by the Kruskal algorithm.
As shown in Figure 6, the independent cut sets can be searched by the spanning tree. There is a flow equation, Equation (3), for every independent cut set. Taking Table 1 as an example, seven flow equations can be set. Q t is the air volume of the main fan that must be monitored. It is assumed that Q t = 15, Q 5 = 4, Q 7 = 5, and Q 8 = 2.

Algorithm Optimization of Sensor Location Problem
In this paper, we propose an independent cut set algorithm for well-posed reconstruction of the airflow in a mine ventilation network; however, its process is too complex. For a large-scale ventilation network, the calculation amount and complexity are very large. In order to simplify the calculation process, the independent cut set algorithm can be optimized by matrixing the calculation process, i.e., all equations in the calculation process can be expressed by matrix. With the help of matrix characteristics, the sensor location problem can be calculated more quickly and intuitively. In addition, there is a mature calculation program for the matrix problem. It is more convenient to solve the matrix problem by computer than to directly solve the newly defined algorithm. Especially for large-scale network problems, faster and more accurate calculations can be made.

Optimization of Single Junction Cut Set
In order to more clearly represent the single junction cut sets, we can use the complete incidence matrix to express the single junction cut sets of each junction. The complete incidence matrix is a 0-1-(−1) matrix that describes the mine ventilation network structure through the spatial relationships between the tunnels and junctions of the network. Each column element of the matrix represents each tunnel of the mine ventilation network. Each row element denotes the junction. The matrix can be expressed as follows:

Algorithm Optimization of Sensor Location Problem
In this paper, we propose an independent cut set algorithm for well-posed reconstruction of the airflow in a mine ventilation network; however, its process is too complex. For a large-scale ventilation network, the calculation amount and complexity are very large. In order to simplify the calculation process, the independent cut set algorithm can be optimized by matrixing the calculation process, i.e., all equations in the calculation process can be expressed by matrix. With the help of matrix characteristics, the sensor location problem can be calculated more quickly and intuitively. In addition, there is a mature calculation program for the matrix problem. It is more convenient to solve the matrix problem by computer than to directly solve the newly defined algorithm. Especially for large-scale network problems, faster and more accurate calculations can be made.

Optimization of Single Junction Cut Set
In order to more clearly represent the single junction cut sets, we can use the complete incidence matrix to express the single junction cut sets of each junction. The complete incidence matrix is a 0-1-(−1) matrix that describes the mine ventilation network structure through the spatial relationships between the tunnels and junctions of the network. Each column element of the matrix represents each tunnel of the mine ventilation network. Each row element denotes the junction. The matrix can be expressed as follows: where × is the complete incidence matrix of the network of dimension ( × ) and is 0, 1, or −1.
= 1 indicates that and junction are associated, and is the out branch of .
= −1 indicates that is the in branch of . Through the definition of single junction cut sets, if branch and junction are associated, then belongs to . Therefore, is an element of when = 1. On the contrary, = 0 indicates that and junction are not related. The matrix can be represented through a set of column vectors.
× denotes the complete incidence matrix with junctions and tunnels, and can be expressed as follows: where is the row vector of dimension (1 × ). = = , i.e., = ≠ 0 ( = 1,2, ⋯ , ; = 1,2, ⋯ , ). , corresponding to all nonzero entries in , is the single-junction cut set corresponding to junction ; that is, is all the elements of .

Algorithm Optimization of Sensor Location Problem
In this paper, we propose an independent cut set algorithm for well-posed reconstruction of the airflow in a mine ventilation network; however, its process is too complex. For a large-scale ventilation network, the calculation amount and complexity are very large. In order to simplify the calculation process, the independent cut set algorithm can be optimized by matrixing the calculation process, i.e., all equations in the calculation process can be expressed by matrix. With the help of matrix characteristics, the sensor location problem can be calculated more quickly and intuitively. In addition, there is a mature calculation program for the matrix problem. It is more convenient to solve the matrix problem by computer than to directly solve the newly defined algorithm. Especially for large-scale network problems, faster and more accurate calculations can be made.

Optimization of Single Junction Cut Set
In order to more clearly represent the single junction cut sets, we can use the complete incidence matrix to express the single junction cut sets of each junction. The complete incidence matrix is a 0-1-(−1) matrix that describes the mine ventilation network structure through the spatial relationships between the tunnels and junctions of the network. Each column element of the matrix represents each tunnel of the mine ventilation network. Each row element denotes the junction. The matrix can be expressed as follows: where × is the complete incidence matrix of the network of dimension ( × ) and is 0, 1, or −1.
= 1 indicates that and junction are associated, and is the out branch of .
= −1 indicates that is the in branch of . Through the definition of single junction cut sets, if branch and junction are associated, then belongs to . Therefore, is an element of when = 1. On the contrary, = 0 indicates that and junction are not related. The matrix can be represented through a set of column vectors.
× denotes the complete incidence matrix with junctions and tunnels, and can be expressed as follows: where is the row vector of dimension (1 × ). = = , i.e., = ≠ 0 ( = 1,2, ⋯ , ; = 1,2, ⋯ , ). , corresponding to all nonzero entries in , is the single-junction cut set corresponding to junction ; that is, is all the elements of .
where L m×n is the complete incidence matrix of the network of dimension (m × n) and l ij is 0, 1, or −1. l ij = 1 indicates that e j and junction v i are associated, and e j is the out branch of v i . l ij = −1 indicates that e j is the in branch of v i . Through the definition of single junction cut sets, if branch e j and junction v i are associated, then e j belongs to D v i . Therefore, e j is an element of D v i when l ij = 1. On the contrary, l ij = 0 indicates that e j and junction v i are not related.
The matrix can be represented through a set of column vectors. L m×n denotes the complete incidence matrix with m junctions and n tunnels, and can be expressed as follows: where L j is the j th row vector of dimension (1 × n). D v j = e k e k = E v j , i.e., D v j = e k l jk = 0 (j = 1, 2, · · · , m; k = 1, 2, · · · , n). e k , corresponding to all nonzero entries l jk in L j , is the single-junction cut set corresponding to junction v j ; that is, e k is all the elements of D v j .

Optimization of Independent Cut Set Algorithm
In Section 2.6, it is revealed that the independent cut set is calculated by which is a equation related to the single junction cut set and independent cut set. From Section 4.1, we know the matrix form of the single junction cut sets D v j , i.e., complete incidence matrix (see Equations (5) and (6)). Therefore, we can convert the solution process of the independent cut set into matrix form. An independent cut set-branch incidence matrix can be established to obtain the independent cut set of the ventilation network. The matrix can be expressed as follows: large. In order to simplify the calculation process, the independent cut set algorithm can be optimized by matrixing the calculation process, i.e., all equations in the calculation process can be expressed by matrix. With the help of matrix characteristics, the sensor location problem can be calculated more quickly and intuitively. In addition, there is a mature calculation program for the matrix problem. It is more convenient to solve the matrix problem by computer than to directly solve the newly defined algorithm. Especially for large-scale network problems, faster and more accurate calculations can be made.

Optimization of Single Junction Cut Set
In order to more clearly represent the single junction cut sets, we can use the complete incidence matrix to express the single junction cut sets of each junction. The complete incidence matrix is a 0-1-(−1) matrix that describes the mine ventilation network structure through the spatial relationships between the tunnels and junctions of the network. Each column element of the matrix represents each tunnel of the mine ventilation network. Each row element denotes the junction. The matrix can be expressed as follows: where × is the complete incidence matrix of the network of dimension ( × ) and is 0, 1, or −1.
= 1 indicates that and junction are associated, and is the out branch of .
= −1 indicates that is the in branch of . Through the definition of single junction cut sets, if branch and junction are associated, then belongs to . Therefore, is an element of when = 1. On the contrary, = 0 indicates that and junction are not related. The matrix can be represented through a set of column vectors.
× denotes the complete incidence matrix with junctions and tunnels, and can be expressed as follows: where is the row vector of dimension (1 × ). = = , i.e., = ≠ 0 ( = 1,2, ⋯ , ; = 1,2, ⋯ , ). , corresponding to all nonzero entries in , is the single-junction cut set corresponding to junction ; that is, is all the elements of .
. . . s j1 · · · s jk · · · s jn . . . struction of the airflow in a mine ventilation network; however, its process is too complex. For a large-scale ventilation network, the calculation amount and complexity are very large. In order to simplify the calculation process, the independent cut set algorithm can be optimized by matrixing the calculation process, i.e., all equations in the calculation process can be expressed by matrix. With the help of matrix characteristics, the sensor location problem can be calculated more quickly and intuitively. In addition, there is a mature calculation program for the matrix problem. It is more convenient to solve the matrix problem by computer than to directly solve the newly defined algorithm. Especially for large-scale network problems, faster and more accurate calculations can be made.

Optimization of Single Junction Cut Set
In order to more clearly represent the single junction cut sets, we can use the complete incidence matrix to express the single junction cut sets of each junction. The complete incidence matrix is a 0-1-(−1) matrix that describes the mine ventilation network structure through the spatial relationships between the tunnels and junctions of the network. Each column element of the matrix represents each tunnel of the mine ventilation network. Each row element denotes the junction. The matrix can be expressed as follows: where × is the complete incidence matrix of the network of dimension ( × ) and is 0, 1, or −1.
= 1 indicates that and junction are associated, and is the out branch of .
= −1 indicates that is the in branch of . Through the definition of single junction cut sets, if branch and junction are associated, then belongs to . Therefore, is an element of when = 1. On the contrary, = 0 indicates that and junction are not related. The matrix can be represented through a set of column vectors.
× denotes the complete incidence matrix with junctions and tunnels, and can be expressed as follows: where is the row vector of dimension (1 × ). = = , i.e., = ≠ 0 ( = 1,2, ⋯ , ; = 1,2, ⋯ , ). , corresponding to all nonzero entries in , is the single-junction cut set corresponding to junction ; that is, is all the elements of .
where S m×n is the independent cut set-branch incidence matrix of the network of dimension (m × n) and s ij is 0 or 1. s ij = 1 indicates that e j is a subset of the independent cut set S i at junction v i . s ij = 0 denotes that e j does not belong to the independent cut set S i at junction v i . Compared with the complete incidence matrix, each column element of the new matrix still represents each branch of the ventilation network. However, row elements are expressed by independent cut sets S. In Section 4.1, the complete incidence matrix (see Equation (6)) is expressed as follows: Through the calculation formula of independent cut sets S = S ∪ D v b − S ∩ D v b , we can obtain the matrix expression: where e k corresponds to all nonzero entries and s jk in S j is the independent cut sets. According to Equation (8), we can obtain the matrix form of the independent cut set.

Sensor Location Based on Algorithm Optimization
Take the network shown in Figure 5 as an example; according to Equation (1), the network graph is: e 3 , e 4 , e 5 , e 6 , e 7 , e 8 , e 9 , e 10 }, n = 10; The junctions and tunnels have been sorted in Figure 5. The whole calculation process is carried out according to the IBFS. According to Equations (5) and (6), we can obtain the single junction cut set expressed by the matrix, that is, the complete incidence matrix of ventilation network G = (V, E). In order to facilitate the presentation of the row vector and column vector corresponding to each element of the complete incidence matrix, we show the complete incidence matrix corresponding to Figure 5 in the form of Table 2. Table 2. The complete incidence matrix (corresponding to Figure 5).

Link
e 1 e 2 e 3 e 4 e 5 e 6 e 7 e 8 e 9 e 10 Junction v 1 1 The matrix can be expressed as L 8×10 . According to Equation (6), the form of its column vector is L 8×10 = L 1 L 2 · · · L j · · · L 8 T . All nonzero entries in L 1 are the result Similarly, all nonzero entries in L 2 are the result of D v 2 , that is, L 2 = {−1 1 1 0 0 0 0 0 0 0}, and the second single junction cut set is D v 2 = {e 1 , e 2 , e 3 }, etc. Through the matrix, we can easily obtain the single-junction cut sets of each junction, and the result conforms to the definition of single-junction cut sets. In order to obtain the independent cut set, L 8×10 is substituted into Equation (8). The results are shown in Table 3. Table 3. Independent cut set-branch incidence matrix (corresponding to Figure 5). The matrix can be expressed as S 8×10 . The form of its column vector is S 8×10 = s 1 s 2 · · · s j · · · s 8 T . All nonzero entries in s j are the results of the independent cut set. For example, s 1 = {1 0 0 0 0 0 0 0 0 0} and the first independent cut set is S 1 = {e 1 }; s 2 = {0 1 1 0 0 0 0 0 0 0} and the second independent cut set is S 2 = {e 2 , e 3 }; s 3 = {0 0 1 1 0 0 1 0 0 0} and the first independent cut set is S 1 = {e 3 , e 4 , e 7 }, etc. Through comparison, it can be seen that the results obtained through the matrix in Table 3 are consistent with those in Table 1.

Flow Reconstruction Based on Algorithm Optimization
In order to simplify the calculation process, the solution of the independent cut set is obtained by a matrix. Therefore, we can also express the calculation of Equation (3) by a matrix. According to Equation (3), the air volume in each tunnel can be denoted by air volume set Q, and its expression is as follows: where n denotes the tunnel number and Q n represents the air volume of the nth tunnel. According to Equation (3), the following equation can be obtained: where Q t m×1 is the column vector of dimension (m × 1), Q t m×1 = {Q t Q t · · · Q t } T . In Figure 5, S = S 8×10 = [s 1 s 2 · · · s 8 ] T and Q = {Q 1 Q 2 · · · Q 8 } T . It is assumed that Q t = 15, Q 5 = 4, Q 7 = 5, and Q 8 = 2. From Equation (10), After simplifying the above formula, the following equation can be obtained: The air volume of the tunnels in the spanning tree is Q 1 = 15, Q 2 = 9, Q 3 = 6, Q 4 = 4, Q 6 = 8, Q 9 = 10, and Q 10 = 15.

Case Study
According to the standards AQ1028-2006 and GB/T 10178, the ventilation network is a fluid network formed by conveying air flow pipelines; various regulating facilities, power facilities, and air flow pipelines are connected. Figure 7 is the ventilation network of a coal mine run by Jinmei Co., Ltd. G = (V, E), where the tunnel number is |E| = 100, and the junction number is |V| = 71. Table 4 shows the whole tunnel's reconstructed air volume and simulated air volume. The test air volume [45] is obtained by a mine ventilation simulation system (MVSS) [46]. The principle of solving the network by MVSS is to establish the mathematical equations for the ventilation resistance law, the air volume balance law, the air pressure balance law, the known total air volume of the fans, and the ventilation resistance coefficient, and then solve them. The main fans are installed in e 9 , e 39 , and e 78 , and their characteristic equations are shown in Equation (11). For a multisource and multisink ventilation network, all sources and sinks should be connected to become a single-source and single-sink network. In a ventilation network, if the spanning tree is removed, the remaining part is called the cotree. As shown in Figure 8, 33 wind speed sensors are used for the network, including 30 cotrees and 3 wind shafts with fans. The tunnels that must be set up with wind speed sensors are e 3 , e 9 , e 22 , e 28 , e 33 , e 39 , e 55 , e 68 , e 72 , e 76 , e 78 , e 84 , e 92 , and e 94 . A spanning tree is generated that does not include the above tunnels (the magenta in Figure 8). Considering the difficulty of testing the lower wind speed, most of the cotrees should not contain the tunnels with structures such as throttles and confined walls. Based on the flow diagram in Figure 5, the air volume of the spanning trees can be calculated by the linear flow equation system of the independent cut sets.    The reconstructed air volume in Table 4 was obtained by the independent cut set algorithm. Similarly, the results obtained by the independent cut set algorithm followed the three basic laws of air volume distribution. Their basic principles are similar. We also used part of the test air volume as a known quantity for the calculation. Therefore, their calculation results should be the same; otherwise, they will prove that the independent cut set algorithm is incorrect. It can be seen from Table 4 that their results were exactly the same. It is feasible to use the independent cut set algorithm to determine the minimum number and location of sensors through the case study. By placing sensors on the cotrees, the air volume of the spanning trees can be obtained. Due to the uniqueness of the well-posed solution, the error of flow reconstruction is zero (see Table 4). There will be no errors or other solutions.   Figure 5 is an example of a simple network with a single source and single sink, and Figure 8 is an example of a complex ventilation network with multiple sources and multiple sinks. Through the calculation of these two examples, it was found that the independent cut-set algorithm was suitable for both of the examples. Therefore, the independent cut set algorithm can be used to solve the sensor optimization and air volume reconstruction problems of all types of ventilation networks. In line with previous research, the calculation complexity was also affected by the network structure. Due to the uniqueness of the wellposed solution, the error of the result can only come from the measurement accuracy of the sensor and will not be affected by other factors. Moreover, the existing solution is unique and has no errors.

Conclusions
In this research, the wind speed sensor location problem of the mine ventilation network was solved by using the independent cut set algorithm, which is a new concept based on the structure of the underlying graph. Firstly, we found the problems: the sensor number was n − m + k − 1, and we located flow sensors in the cotrees that must be set up with sensors according to the Chinese standards. The calculation complexity was affected by the network structure. Secondly, we discussed the possibility of well-posed reconstruction based on the mine ventilation networks. Fewer than 30% of tunnels need to be set up with wind speed sensors to achieve a well-posed reconstruction of the airflow in all the tunnels if the mines have over 200 tunnels. For mines with fewer than 200 tunnels, more than 30% of tunnels should be installed with sensors. Due to the uniqueness of the well-posed solution, there is no error in the results unless the sensor accuracy does not meet the standard. Lastly, the algorithm of independent cut sets was presented for the well-posed reconstructions. The flow reconstructions were shown to be computationally efficient for the coal mine ventilation system used by Jinmei Co., Ltd. This algorithm works on velocity sensor distribution rather than sensors of hazardous and combustible gas. This algorithm is a well-posed reconstruction algorithm. It can only be used to determine the minimum number and location of sensors and cannot solve the underdetermined reconstruction of a given number of sensors. Therefore, the premise of using this algorithm is that the number of sensors will be sufficient. This study provides researchers with a sensor optimization scheme when the number of sensors is insufficient and provides the possibility for air volume reconstruction. At the same time, it reduces the cost for the air volume monitoring of the whole air network and provides some theoretical support for the realization of intelligent ventilation. In the following research, we will discuss the sensor location under the condition of underdetermined reconstruction.