Metal Roof Fault Diagnosis Method Based on RBF-SVM

Metal roof enclosure system is an important part of steel structure construction. In recent years, it has beenwidely used in large-scale public or industrial buildings such as stadiums, airport terminals, and convention centers. Affected by bad weather, various types of accidents on metal roofs frequently occurred, causing huge property losses and adverse effects. Because of wide span, long service life and hidden fault of metal roof, the manual inspection of metal roof has low efficiency, poor real-time performance, and it is difficult to find hidden faults. On the basis of summarizing the working principle of metal roof and cause of accidents, this paper classifies the fault types of metal roofs in detail and establishes a metal roof monitoring and fault diagnosis system using distributed multisource heterogeneous sensors and Zigbee wireless sensor networks. Monitoring data from strain gauge, laser ranging sensor, and ultrasonic ranging sensor is utilized comprehensively. By extracting time domain feature, the data trend characteristics and correlation characteristics are analyzed and fused to eliminate erroneous data and find superficial faults such as sensor drift and network interruption. Aiming to the hidden faults including plastic deformation and bolt looseness, an SVM fault diagnosis algorithmbased onRBF kernel function is designed and applied to diagnose metal roof faults. .e experimental results show that the RBF-SVM algorithm can achieve high classification accuracy.


Introduction
Metal roof enclosure system has been rapidly developed in public buildings and industrial buildings due to its excellent structural performance, beautiful appearance, and environmental protection [1,2]; its typical applications are shown in Figure 1. Metal roof enclosure system in service period just in major cities of China covers no less than 1 billion square meters since 2008 and grows at a rate of no less than 50,000 square meters per year; therefore, its safety and reliability have drawn extensive attention.
Metal roofs are susceptible to extreme weather and other factors during usage. In recent years, accidents of metal roof have occurred occasionally. In 2010, 2011, and 2013, the metal roof of Beijing Airport T3 terminal was lifted up by wind three times; these accidents caused more than a thousand flights to delay, which seriously affected the normal operation of Beijing Airport. In 2016, metal roof of the Guangzhou Baiyun Airport terminal building was rippled off by a weak wind, and the speed of the wind did not exceed the design safety threshold of the metal roof. e No.3 typhoon "Tian Ge" in 2017 caused a large number of metal roofs in Zhuhai to be destroyed [3]. By far, the solutions of these problems are mainly to reinforce the safety check calculation in the design phase to improve the roof bearing capacity threshold or increase the wind-proof clamp and other reinforcement measures at local negative highpressure area, but these methods mainly focus on the theoretical model and general regularity analysis; they do not have the support of real-time monitoring data, there is few research on the real-time monitoring system of metal roof during service period, and this is the bottleneck that needs to be broken in wind-resistance and disaster prevention engineering of large-span building metal roof [4]. e metal roof of airport rippled off by wind can be shown in Figure 2.
In view of the damage of metal roof enclosure system, this paper used structural health monitoring technology (SHM) [5]to replace traditional manual inspection; the real-time monitoring of metal roof can reduce the occurrence of accidents effectively. is kind of technology has become a global research hotspot and is widely used in large-scale civil infrastructure [6], such as airports, high-rise buildings [7], large-span buildings, stadiums, railways [8], and pipelines [9].
At present, the automatic monitoring methods of civil structures are mainly divided into two categories: intelligent robot monitoring and sensor network monitoring. Robot monitoring is often used in harsh environments, and the monitoring area is limited. Because of the wide span, stable working environment and long period of performance changing of metal roof, distributed sensor network monitoring method should be considered in priority in metal roofs.
Sensor network monitoring obtains monitoring data of building structure by embedding or pasting sensors on the surface of the monitored structure, and based on this, fault   2 Complexity diagnosis and health evaluation of the building structure are carried out [10]. e construction of sensor network monitoring system is mainly divided into three parts, which are sensor selection, monitoring network construction, and data storage and analysis. In the sensor selection part, Yan et al. [11] in Southwest Jiaotong University designed a bridge structure health monitoring system for Hutong Yangtze River Bridge. In this paper, not only the large amount of data and wide coverage of sensor features were considered, the correlation between the collected data was also used. In this way, the accuracy of fault diagnosis was increased and, at the same time, some hidden faults can be discovered by data fusion algorithm [12]. In data transmission part, wireless sensors are widely used in the project, for example, in order to monitored the health of bridge structure, Alampalli et al. [13] realized the monitoring system using wireless network; they also used big data cloud computing technology to evaluate the health of the bridge. In Poland, SALA [14] in Polish Academy of Sciences established a health monitoring system for a 40-meter long steel truss bridge using wireless sensor network, and they also used solar energy to power the piezoelectric ceramic strain gauges in order to save the energy consumption. In this paper, we use Zigbee [15] wireless network combined with Profibus and Internet to form a star topology for data transmission; the master and slave PLC communicate structure can improve the data processing capacity significantly. In data analysis and fault diagnosis algorithm part, there are mainly three ways to process the data, the method based on modern signal processing technology [16][17][18], the method based on statistics [19], and the method based on machine learning and data mining techniques. In recent years, machine learning [20] and data mining techniques are widely used in SHM technology, such as Bayesian neural networks [21], wavelet packet analysis, posterior probability SVM, DS evidence theory, and OLSVM [22] algorithm. In this paper, in order to comprehensively consider the trend characteristics and correlation characteristics of large amount of monitoring data, the support vector machine (SVM) algorithm based on RBF kernel function is used for fault diagnosis of mental roof. is algorithm can multiclassify the monitoring data by using multidimensional feature value input, and it can also improve the classification accuracy through grid search method, so as to achieve accurate fault diagnosis of the metal roof.
is paper is divided into three sections. e first section analyzes the damage mechanism of metal roof failure and selects the appropriate sensors and transmission scheme to build the metal roof health management system. e second section summarizes the types of faults that need to be distinguished by algorithms and introduces the preprocesses of monitoring data. In the third section, the RBF-SVM algorithm to classify the monitoring data is realized, and we use grid search method to optimize the parameters of RBF-SVF. Finally, the classification results are evaluated in the last section of the paper.

Metal Roof Failure Causes Analysis and Fault Monitoring System Composition
Metal roofs are exposed to the natural environment for a long period; therefore, they are easily affected by external weather conditions. Wind destroying is the main cause of metal roof damage [23]. is section will first analyze the types and causes of metal roof failures, and then based on the failures, a metal roof online monitoring and health management system will be established.

Summary of Failure Reasons of Metal
Roof. e research object of this paper is standing seam metal roof enclosure system, which is widely used on the roof of industry buildings. Standing seam metal roof is a metal roof enclosure system formed by roofing panels, fixed supports, purlins, and pressed bottom plates. When the roof is subjected to the upward wind suction, the wind force is transmitted to the fixed support through the interboard nip connection structure and then transmitted to the purlins by the selftapping screw and finally transmitted to the main structure safely. e metal panel is fixed on the purlins by a T-shaped bracket, and the board rib of the roof panel is clamped on the plum head of the T-shaped support so that the panel is fixed on the purlin of the roof. e structure of the system is shown in Figure 3. e main damage form of metal roof is excessive deformation and displacement perpendicular to the longitudinal direction of the roof panel, which causes the metal roof panel to be plastically deformed or even rippled off. Since the metal roof is not fixed in the lateral direction, the main monitoring object is the longitudinal stress and displacement of the metal roof. e lateral displacement is only used as a reference factor for monitoring the fatigue damage of the roof panel without excessive analysis.
Combined with the research and analysis of metal roof accidents in recent years, the types and causes of metal roof failures are summarized as follows: (1) Plastic deformation: during the long-term service of metal panels, due to the influence of alternating loads, especially the wind load, metal panels are plastically deformed, resulting in a decrease in the wind-resistant performance of the metal panels, affecting the safety of the metal roof. (2) Lateral slip: standing seam metal roof is connected with the purlins by the T-shaped bracket. When the ambient temperature changes, the metal roof will deform due to the thermal expansion and contraction, resulting in the internal stress of the metal roof becoming larger. Repeated stress changes can cause fatigue damage to the metal roof, so attention should be paid to the lateral slip of the metal roof due to temperature. (3) Longitudinal deformation: under weather load such as wind and snow, longitudinal deformation will Complexity occur, which is the main reason affecting the health of metal roofing. Excessive longitudinal deformation easily leads to plastic deformation of metal roof and affects fatigue life and makes the roof more easily to be lifted up by wind. (4) Bolt looseness: standing seam metal roof is fixed on the purlins by bolts. e bolts may tend to loosen during long-term service, which leads to the safety hazard of the metal roof being damaged by the wind. erefore, the bolt looseness also affects the metal roof, and this kind of fault is difficult to be monitored by one kind of sensor; we use two types of monitoring data to diagnose this fault. e main fault forms and causes of standing seam metal roof are summarized in the following Table 1:

Real-Time Monitoring and Health Management System of Metal Roof Enclosure System.
On the basis of summarizing the fault types and causes of metal roof, a distributed multisource heterogeneous sensors' scheme was selected to establish a wireless transmission network and a data backup storage system to monitor the health of metal roof in real time.
In this system, three kinds of sensors are used to implement distributed multisource heterogeneous monitoring on metal roof; distributed monitoring can obtain monitoring data in different areas of the roof, making the data more comprehensive. Multisource heterogeneous sensors can take advantage of the correlation of different types of data, which can not only ensure the accuracy of the data but also diagnose the hidden faults through data fusion. e sensors include a stress sensor, a laser ranging sensor, and an ultrasonic ranging sensor. e terminal node sensor is shown in Figure 4. e type and function of the sensor are shown in Table 2: e metal roof real-time monitoring and health management system includes three subsystem modules: data acquisition module, wireless network transmission module, data backup and interface module. e function and relationship among different modules are shown in Figure 5.
e data acquisition module consists of distributed sensors which layout in different areas of the roof. e data transfer to the STM32 SCM was combined by ADS1256 high-precision A\D acquisition chip. en, the measurement data is transmitted to Zigbee wireless network transmission module; the transmission module uses Zigbee protocol to transfer data to the PLC master and slave station for data processing by wireless mode. PLC S7-1500 CPU is used for master station of the system; meanwhile, PLC S7-1200 CPU is used for slave station, and finally, the collected data is converted into decimal readable data by calculation in PLC and transfer to upper computer. e data is stored in database of the upper computer.
e interface of the system is developed in upper computer by WinCC, and it realizes the real-time monitoring and fault diagnosis of the metal roof by analyzing the data stored in its database. Since mature solutions are mostly used in this monitoring system, its economic cost can be disregarded compared with metal roofing system. Meanwhile, it is more valuable to reduce the hidden danger caused by metal roof failure through real-time data analysis.

Metal Roof Fault Classification and Data
Preprocessing Based on Monitoring Data e data collected by the metal roof real-time monitoring system is saved in the database of the upper computer, and the fault of metal roof can be diagnosed by getting data from the database. Because of the large number of distributed sensors, it will be difficult to analyze all sensor data. erefore, the stress and displacement thresholds should be set according to the physical properties of the metal roof. en, we calculate the proportion of the sensors where the stress and displacement reach the threshold in the region   Table 3. e metal roof fault diagnosis process is divided into two levels. In the first level, the faults can be diagnosed by the real-time monitoring system, they are easy to be distinguished. However, some faults are difficult to distinguish or     they need two kinds of data to diagnosis, so in the second level, machine learning algorithm is used to classify complex or hidden faults of metal roof enclosure system. e specific diagnosis process is shown in Figure 6.
In the second level, the support vector machine (SVM) algorithm based on RBF kernel function is used to classify the fault type. is part mainly focuses on the faults that are complex or hidden and diagnosed the fault by correlation of data measured by multisource heterogeneous sensors. Based on the built-up metal-roof real-time monitoring system, the monitoring data of metal roof in different fault states are obtained from experimental system, and the monitoring data are preprocessed by time domain analysis to extract the characteristic quantity under different conditions of metal roof, and then the training set of RBF-SVM is established by corresponding the characteristic quantity and fault. Finally, the training set is used for training the RBF-SVM model and realizing the fault diagnosis of the metal roof.

Data Preprocessing Method.
In the data preprocessing process, the correlation characteristics of different kinds of data collected by the heterogeneous sensors can effectively avoid the error data from faulty sensor and ensure the accuracy of fault diagnosis and fault early warning. e SVM algorithm's training needs to select representative data to include various situations from a large number of detection and experimental data, thus these groups of data may come from different dates. e typical data selected are shown partly in Figure 7, in which the types of data are denoted. e red curve in Figure 7 is the strain data from strain gage, the blue curve is the displacement data collected by the laser ranging sensor, the state of the metal roof is judged by the trend information of the data collected by these two sensors, and the correlation information of the data collected by two heterogeneous sensors avoids the error data and makes fault diagnosis more accurate.
For convenience in comparing, the data shown in the abovementioned figure ignores the impact of the numerical dimension on result. e monitoring data are normalized to be distributed between 0 and 1, and the formula is as follows: Different causes of roof deformation will lead to different trends of detection data of different sensors, which is the advantage and necessity of using a variety of sensors for data acquisition. e dataset shown above contains four types of data, which are the monitoring data under normal roof condition, the monitoring data when the roof is longitudinally deformed, the monitoring data when the sensor fault occurs, and the monitoring data when the bolts are loosen. It can be seen from Figure 7 that under normal condition, the stress and displacement data of roof panel only have little changes and there is no obvious fluctuation. Two types of data from heterogeneous sensor have high correlation. In this condition, the states of sensor and roof are both normal. When the roof is longitudinally deformed, monitoring data from laser ranging sensor and strain gage have same trend changes, which means they have high correlation. In this condition, it can be judged that the roof has undergone longitudinal deformation. When in the sensor fault condition, one of the sensors experiences a zero drift fault, the data from two sensors are less of correlation and the data of one sensor is in rise trend. As for the bolt loosen fault, it is difficult to find by manual inspection; however, it can be diagnosed by heterogeneous sensor system. When the bolts fixed on purlins are loosen, the panel will be displaced in the longitudinal direction in a large extent but, at the same time, the strain value of the panel is less and it changes slower than the displacement, just like the dataset shown in Figure 7; the displacement data change in a large range, while the strain value changes less. In this situation, we can assume that the bolt of metal roof has loosened.
Considering the above information, five kinds of statistics are selected as input characteristics: average and standard deviation of metal roof longitudinal displacement data and roof panel strain data are selected to reflect trend information, and difference between displacement and the strain data variance and correlation coefficients of these two types of data are selected to reflect correlation information. e statistic calculation formula is shown in Table 4. In order to avoid the influence of data value range on the fault diagnosis result, the input characteristics quantity needs to be normalized, and the formula is as follows:  Complexity where μ is the average of characteristics, σ(μ) is the stand deviation of the characteristics, and y in is the normalized characteristics.
Finally, 593 sets of characteristics quantities are selected for training and testing including 70% of training set and 30% of testing set. e input characteristics quantity and labels are shown in Table 5; labels 0-4 respectively express the normal data of the metal roof, the strain sensor fault data, the laser ranging sensor fault data, the roof large longitudinal deformation data, and the bolt looseness data.

Metal Roof Fault Diagnosis Algorithm Based on RBF-SVM and Parameter Optimization Method
rough data preprocessing, the trend information and correlation information of monitoring data are obtained. By using these two types of information, multiclassification of monitoring data can be realized, and in this way, fault diagnosis of metal roof can be achieved. In the classification algorithm, SVM has automatic model selection, which can transform training into quadratic programming problem and it also has good learning ability of small sample. RBF kernel function SVM algorithm can meet the distinction of different fault types of metal roof and reduce computational complexity to ensure the efficiency of the fault diagnosis algorithm.

SVM Algorithm.
SVM is an efficient data classification algorithm. By finding support vectors in dataset, it establishes a hyperplane and classifies the data. For a simple twodimensional linear separable problem, a straight line can be established to separate the data; while in fault diagnosis of metal roof, the monitoring data needs to be classified into multiple categories. erefore, it is necessary to map the characteristic quantity of the monitoring data to a highdimensional feature space H and then construct the (generalized) optimal hyperplane in H to realize multiclassification of monitoring data. e simple SVM classifier is used in binary classification. Assume that input points set x i ∈ R d consists of two types of points. If the points x i belong to the first class, then y i � 1, or if they belong to the second class, then y i � −1. Assuming that training sample set is Table 4: Statistics and formulas.

Statistics Formulas
Trend information Average of strain μ � n t�1 y t /n Average of displacement Standard deviation of strain  Complexity y 2 ), ... , (x m , y m ) , y i ∈ −1, +1 { }, the goal of the support vector machine is to find a hyperplane that satisfies the classification requirements according to the principle of minimum structural risk and linearly divide the dataset.
In the sample space, the divided hyperplanes can be described by the following linear equation: where ω � (ω 1 ; ω 2 ; . . . ; ω d ) is the normal vector, which determines the direction of the hyperplane; b is the displacement term, which determines the distance between the hyperplane and the origin. e distance from any point in the sample space to the hyperplane can be written as follows: Assuming that hyperplane (ω, b) can classify training samples correctly, for (x i , y i ) ∈ D, if y i � +1, then ω T x i + b > 0, or if y i � −1, then ω T x i + b < 0. In this way, the formula can be expressed as follows: e training sample pointing closest to the hyperplane makes the equal sign true.
ey are called as "support vectors," and the sum of distances of two different classes of support vectors to the hyperplane can be expressed as follows: It is called gap. e optimal hyperplane can not only separate the samples of the two classes without error but also maximize the gap of two classes. e classification problem can be transformed into a minimum value problem with constraints, and it can be expressed as follows: is is the basic formula of SVM algorithm. In the basic principles, most are ideal hypotheses. However, in the process of using SVM for fault diagnosis, fault data cannot be linearly divided. It is necessary to allow the SVM algorithm to make errors in dividing certain monitoring data to avoid overfitting. In this situation, soft margin is used, and nonnegative slack vector ξ i is added to the formula, so the target function of problem has changed as follows: where C n i�1 ξ i is the penalty term; C is the penalty factor, which controls the degree of penalty for wrong samples. e higher the C value, the higher the penalty for the error, and the stricter the linear classification. It is important to choose the optimal C in SVM, and the optimization algorithm will be mentioned in the following part of the paper.
Meanwhile, the fault diagnosis of metal roof is a nonlinear multiclassification problem. In order to realize the nonlinear multiclassification, Kernel function can be used to map the original nonlinear multiclassification sample into the high-dimension space H, transform the nonlinear classification problem into the linear classification problem, and, at the same time, use penalty term to ensure the accuracy of classification. Kernel function K(x, x i ) can be expressed as follows: According to the classification sample, by selecting the appropriate kernel function K(x, x i ) instead of the inner product operation in the high-dimensional space, the linear classification after a linear transformation can be realized, and the computational complexity is not increased. Similar to the optimization method without linear transformation, in order to solve the dual problem, the Lagrangian multiplier is used to construct the Lagrangian function. e final optimal classification function is as follows: In this paper, we use RBF kernel function to optimize the SVM algorithm called RBF-SVM, the formula is as follows:

Grid Search (GS) Method Parameter Optimization and
Result Analysis. In RBF-SVM algorithm, in order to solve the nonlinear multiclassification problem, the penalty factor and RBF kernel function are used to reduce overfitting and computational complexity. e value of the penalty factor C and kernel parameter c determines the classification accuracy. e smaller parameter C and c make the decision surface smooth and the model simple, thus the accuracy is reduced. On the contrary, the larger parameter C and c increase the accuracy of the model and make the model more complex. e common methods of parameter optimization in SVM are grid search method, genetic algorithm, and particle swarm optimization algorithm, the latter two of which are heuristic algorithms. e grid search method can find the optimal solution of a given range of parameters, but the speed is slow.
e heuristic algorithm has too many parameters, and different parameters have a great impact on the results, which increases the difficulty of using the algorithm, and it may fall into the local optimal solution. Grid search method [24] provides different combinations of Cand c values for RBF-SVM in an exhaustive way and calculates the classification accuracy of each combination by crossvalidation method. Finally, it selects the combination with the highest accuracy to ensure RBF-SVM has the highest accuracy. In the division of the grid, the parameter interval can be enlarged to make a tradeoff between the local optimization and the computational efficiency.
As Figure 8 shows, 5-fold cross-validation is used to find the best combination of values C and c. e classification accuracy of each combination is shown in the figure by different colors, color red expresses the high accuracy and color blue expresses the low accuracy. e abscissa of the figure represents the value of c and the ordinate represents the value of C. Finally, the combination with the highest classification accuracy is selected, the value of C is 10 6 , and the value of c is 10 − 4 .
According to the classification result and confusion matrix, the RBF-SVM algorithms have a good accuracy and recall rate, and it can be used to diagnosis metal roof fault correctly. e fault of metal roof can be divided into longitudinal deformation, laser ranging sensor fault strain sensor fault, and bolt looseness. With this method, it can not only distinguish the metal roof fault accurately but also effectively distinguish the error data caused by sensor fault and hidden fault like bolt looseness. e metal roof real-time monitoring system and the fault diagnosis algorithm that were proposed in this paper make the metal roof monitoring more intelligent and reduce the security risk of metal roof effectively.

Conclusion
In order to reduce the safety hazards of widely used metal roof enclosure system, this paper introduces a metal roof real-time monitoring system and fault diagnosis algorithm. Based on analysis of causes and types of faults in the metal roof, the distributed multisource heterogeneous sensors with wireless network are used to monitor the state of the metal roof. It makes the monitoring and maintenance of metal roof change from manual inspection to real-time monitoring, which improves accuracy and reduces security risks.
Compared with traditional monitoring system, this system uses the distributed network to collect data from metal roofs with wide span and large area; meanwhile, it uses multisource heterogeneous sensors to ensure the accuracy of monitoring data and find the hidden fault of metal roof, and Zigbee wireless network can reduce the damage of roof and make it easy to install. In fault diagnosis algorithm, not only the trend information of data is considered but also the correlation information is used to improve the accuracy of fault diagnosis and find the hidden fault of metal roof. In the process of optimizing the RBF-SVM algorithm, grid search   method is used to improve the classification accuracy. After the verification by experimental data, the RBF-SVM algorithm we used can achieve the 99% of classification accuracy and recall rate. In the test dataset, 176 of 178 sets of data are correctly classified, which have a high classification accuracy. e research on metal roof real-time monitoring system and fault diagnosis algorithm will promote the development of intelligent monitoring and maintenance of metal roof and reduce the safety risk of it effectively.

Data Availability
e data used to support the findings of this study are included within the article.

Conflicts of Interest
e authors declare that they have no conflicts of interest.