Low-Cost Multisensor Gas Detection System with Fuzzy Algorithm

we This to transport, expensive, and possesses we eight different types of easily obtained gas sensors. They and can detect different gases. While some sensors can only detect a certain gas, can detect a variety of gases. In the one the detected gas, certain different gases may produce the same output signal. How can one determine the type of gas detected through the of a multigas sensor? key of a gas detection system. In study, we a fuzzy to analyze the detected signal to distinguish the gas type, and combine the data to calculate the concentration of the gas. We used multisensors, a fuzzy and a single-chip circuit to design a gas detection system. This system is on a design; to the need to replace any module or sensor in the system if


Introduction
Detecting both the type and concentration of a gas is considerably difficult. Consequently, developing a sensor system for gas detection remains a prevalent research field.
Previously, Snopok and Kruglenko, (1) and Freund and Lewis, (2) used forward multiple media (multicomponent chemical media, MCM) chemical images, pattern classification methods, and functionally diverse conductive polymers to develop new sensors and identification technologies. Schaller et al. (3) and Dutta et al. (4) presented multiple sensors, tin oxide sensors, and other methods used in the food industry. As seen from our previous studies, (1)(2)(3)(4) accurately distinguishing one gas from among several detected gases is very difficult and often requires the use of complex detection systems, sensors, or complex proprietary algorithms. Consequently, the system is generally large and very expensive. In this study, we use easily obtained gas sensors and single-chip systems along with fuzzy algorithms to design a movable, lower priced gas detection system. In this system, we used eight types of easily obtained gas sensors (5)(6)(7)(8)(9)(10)(11)(12) for gas detection, as listed in Table  1. These sensors are ceramic, and each sensor has a different gas-detection ability. Some of them can detect only a specific gas, while others can detect several gases. The detected gas may not be distinguishable, as different gases can produce the same output signal. Hence, distinguishing different gases on the basis of the output signal of the sensor has become the key aspect in designing gas detection systems. In this study, we use fuzzy algorithms to distinguish the possible gases and data fusion theory to combine data from multiple sensors in order to identify the gas type and the concentration of the detected gas.
In this system, we adopted multimodule, multisensor architecture. Each module can employ two to eight sensors and has a microprocessor and communication interface. Therefore, the sensor signals can be used for preliminary calculations and can be stored in real time; the data or results of these calculations can be transmitted to a host computer via a communication interface. With this architecture, a sensing module can be used for sentinel surveillance, or multiple sensing modules consisting of sensor networks can be used to monitor an area. The host computer makes use of this information and uses fuzzy algorithms to update the information and learn. The entire gas detection system can be built and used very flexibly for very efficient detection and enhance the detection accuracy of detection systems. This system architecture is shown in Fig. 1. Table 1 Sensor characteristics.

Sensor
Gas detection Alcohol Ammonia CH 4 CO CO 2 Ethanol H 2 Hydrogen i-C 4 H 10 Iso-butane LPG Methane Smoke 1 HS129 •

System Architecture
The module used herein is an 8051 series single chip with a sensor signal processing circuit, a communication interface, and other peripheral circuits. A block diagram of the module is shown in Fig. 2.
Up to eight gas sensors can be connected in this module. Each sensor output goes through a signal processing circuit for signal amplification, zeroing and filtering, and other processes, and then the data is sent to a single-chip A/D converter to be digitized.
In the communication section, the module can send sensor data or the results of calculations back to the host computer or receive from the host computer the characteristic patterns and other parameters for a variety of gases. In the communication section, we design a universal asynchronous receiver/transmitter (UART), and a wireless communication interface to allow more flexible usage of the entire module.
Each module can be used alone, or grouped with multiple modules through a communication interface to form a sensor network. In the latter case, the number and type of sensors used in each module can be adjusted as needed, allowing the monitoring system to obtain more accurate results.
In this study, we used the sensor characteristic curves, shown in Figs. 3(a)-3(h). From these characteristic curves of the sensors, we can see that many sensors have the same output signal for a variety of gases; thus, we cannot directly determine the type of gas detected or its concentration. We used fuzzy algorithms and the analytic hierarchy process (AHP) to determine the relationships between the output signals of all gases and to determine the detected gas. After confirming the gas type, we can calculate the gas concentration using the sensor characteristic curve.

Algorithms
Because some sensors can detect a wide variety of gases, the response output of a sensor can be mapped to different gases of different concentrations. Consider the sensor HS-129 with the characteristic curves shown in Fig. 3(a) as an example. On the basis of the curves shown in Fig.  3(a), we have the results shown in Table 2. The output response voltages of alcohol at 4000 ppm, methane at 10000 ppm, and H 2 at 2000 ppm are almost the same; there are many such cases. Therefore, we cannot directly identify the gas from the output value of a sensor. Hence the output values of all sensors must be fused, including processing and analysis, to identify the type of detected gas.
In the following, a module with eight sensors is used for illustration. First, we must find o i , the maximum output value of each sensor; the results are shown in Table 3. Then, we can use these data to find ω i , the correction weighting of each sensor with the maximum of o i , o max .
A greater weighting of a sensor means the sensor has higher sensitivity for measuring a certain gas. Multiplying the weightings to the corresponding sensor outputs can reduce the impact of the insensitive sensors and noise. To establish the normalized data model for all gases detected, the weighted output values are added together, and the proportion of each weighted value, which corresponds to each gas model, is then calculated. When two gases give the same or similar output signal at the same time, we can use the models for comparison. Since the comparison is relatively simple, it can decrease the required computational effort. Consequently, modules do not necessarily need a host computer.
Thought the following computation, we can know which sensor reacts to the test and obtain the relative sensitivity for each sensor. Then we can use the fuzzy-AHP (FAHP) method (13) to identify the gas type and the concentration of the test gas. All the sensors shown in Table 1 can detect certain gas types; the results are shown in Table 4. Define an indicator S i for each sensor, which indicates how effectively the test gas can be measured, using Eq. (4), applying Eq. (7).
Then, a fuzzy judgment vector can be obtained: We repeatedly sample data and finish Table 5 by the above process. Then we can identify the type of test gas. The j in Table 5 is the number of times of sample testing. After completing Table 5, Select all 1's in the matrix. This makes identification of the detected gas type possible. Therefore, we have Thus, we can rewrite the original FAHP matrix as Consider a practical example for illustration. Here, the target gas is alcohol and five tests are carried out with the gas detection module. Table 6 shows the sampled data and results of calculation using Eqs.
(1) to (6). From Table 6, we see that the outputs of TGS 825 and TGS 826 are both above 3 V. Figures 3(g) and 3(h) imply that air and gas are not detected, which can be regarded as no output. The other four times, the sampling data is obtained in the same manner, and Eqs. (7) to (11) are used for the calculation. We obtained the results shown in Tables 7 and 8.    -butane  0  0  0  0  0  LPG  3  3  3  3  3  Methane  1  1  1  1  1  Smoke  3  3  3  3  3 From the majority-decision point of view, the test gas can be judged to be alcohol. However, after checking the sensor characteristic curves shown in Fig. 3, we find that there is more than one possible gas that matches the measured results. For example, CO 2 in HS-129 and methane in HS-135 are also possible candidates because no other sensor can detect them. Therefore, we cannot confirm which gas it is from the detection results of HS129 and HS135. To confirm the gas type and concentration, we use third-order polynomials obtained by the leastsquares method to match all characteristic curves of the eight sensors shown in Fig. 3. Then the sampling results shown in Table 6 are converted to concentrations of possible gases in accordance with the matched polynomials. The results are shown in Table 9. Then, we select all data of the same gas type from Table 9 and use the redundant management method calculation to determine the gas type and the concentration. To achieve this objective, define n j as 1 if the jth sensor detects the gas, and 0 if it does not detect the gas. Define the following terms: where m i is the measured value. Next, data in Table 9 are used to obtain the results shown in Table 10 using Eqs. (12) to (14). The "Redundant" data in Table 10 is obtained using Eq. (12). The "R. Result" data is obtained by comparing the "Redundant" value to the output in Table 9 one by one and summing the values that are nonnegative and with a difference less than 25%, i.e., summation with false values excluded. Hence the effective concentration of the gas should be After completing the above procedures, there are still three possible gas types. Then the results are compared with the values in Table 4. We find that in addition to alcohol, the other two possible gases, CO 2 and methane, can only be detected by HS-135 and HS-129, respectively. Furthermore, both these sensors can detect alcohol. Thus, through this calculation and comparison, we can confirm that the test gas is alcohol. Once we confirm the test gas to be ethanol, the output values whose difference from the average is less than 15% are summed, and the result is then divided by the number of correct sensors to obtain the gas concentration of 4030.719 ppm.
By this method, the type of gas and its concentration were confirmed by only simple calculation. Hence, a low-cost gas detection system can be constructed using a low-cost single chip (such as 8051).

Practical System and Experimental Results
After completing the entire sensing module design and algorithm derivation, we completed the actual sensing system, as shown in Fig. 4. This module is constructed of an 8051 single-chip-based controller with mobility in mind in the design. The gas sensor or communication module can be replaced in accordance with the demand. This design makes future maintenance easy. The housing shown in Fig. 4(b), makes the gas detection module easily portable. It can also be grouped into a multi-module gas detection system to monitor the environment. The gas detection system is composed of a host system and at least one gas detection module. One can monitor multiple gas detection modules, as well as the data and calculation results for each gas detection module through the main control system by using a database system for management. This can make the whole system more intelligent. Figure 5 shows a gas detection module and monitoring of the system integration test results.   Figure 6 shows the results of the actual tests, where Fig. 6(a) shows the results of the real-time calculation of the gas detection module. The result is stored in a single-chip memory and can be retrieved for later use, and is transmitted through the communication line to the master for display as well as recording. Figure 6(b) shows the result of the monitoring system.

Conclusions
We used a variety of sensors, and a single-chip circuit to design a low-cost gas detection system. This system is based on the modular design approach. It can satisfy the demand to replace all modules, including the sensors in the system. Using a plurality of sensing modules for detecting different gases can form a network of gas detection systems.
In our system, we used the FAHP method to identify the type and the concentration of the detected gas from the corresponding characteristic curves of the sensors. Using this method, the gas types could be accurately distinguished in our experiments. However, it is still limited to the specifications of the sensors used. We hope that in the future, we can overcome the limitations of the sensors and detect and identify more types of gases.