Water Supply Pipeline Risk Index Assessment Based on Cohesive Hierarchical Fuzzy Inference System

As populations grow, facilities such as roads, bridges, railways lines, commercial and residential buildings, etc., must be expanded and maintained. There are extensive networks of underground facilities to fulfil the demand, such as water supply pipelines, sewage pipelines, metro structures, etc. Hence, a method to regularly assesses the risk of the underground facility failures is needed to decrease the chance of accidental loss of service or accidents that endanger people and facilities. In the proposed work, a cohesive hierarchical fuzzy inference system (CHFIS) was developed. A novel method is proposed for membership function (MF) determination called the heuristic based membership functions determination (HBMFD) method to determine an appropriate MF set for each fuzzy logic method in CHFIS. The proposed model was developed to decrease the number of rules for the full structure fuzzy inference system with all rule implementation. Four very crucial parameters were considered in the proposed work that are inputs to the proposed CHFIS model in order to calculate the risk of water supply pipelines. In order to fully implement the proposed CHFIS just 85 rules are needed while using the traditional Mamdani fuzzy inference system, 900 rules are required. The novel method greatly reduces implementation time and rule design sets that are extremely time consuming to develop and difficult to maintain.


Introduction
The idea of risk was first given in the field of economy in the last year of the 19th century; nowadays its use is common nearly in all fields.The fields where the concept of risk is frequently used are environmental sciences, natural disasters, architectural engineering and so forth.The risk is the probability of failures; risk and uncertainty are directly correlated with each other.There are a lot of underground facilities, which are severe threats to buildings, railways lines, bridges, roads and so forth.The most important among them are water supply pipelines.Immense research has been carried out by several scientists to propose an efficient risk assessment method for water supply pipelines, in order to avoid human and economic loses.Water supply pipelines are the most essential and more rapid growth is expected in the future, in terms of installation of underground water supply pipelines.These pipes are severe threats to roads, railways, bridges and so forth [1,2].
Numerous factors can cause pipelines failures, such as age, bridges, leakage, depth and height, water temperature and so forth [3][4][5][6].In this paper, we have considered age, depth, length, and height because these are incredibly significant factors and due to which failures may occur to water supply pipelines.As the age of the pipeline increases the probability of failure increases, therefore we have considered this factor in the proposed work.The leakage of the pipeline is also a critical factor that can slowly damage the pipe as well as near buildings, roads and so forth [7].The other two parameters depth and length also contribute to pipeline failures [8].Many authors have proposed different methods in order to assess water supply pipelines.An efficient risk assessment methodology is fundamental to take measures in time to escape from accidents.
Recently, the fuzzy logic (FL) method has grasped the consideration of various scholars and has been widely used in several areas for different purposes [9,10].Fuzzy logic methods have been extensively used for risk index analysis and assessment.Fuzzy inference system (FIS) can be used to solve the problems related to the exact mathematical models.However, conventional fuzzy inference systems are not suitable due to its rules-explosion with every new entry of variables.For a fuzzy model having q input parameters, for each input parameters p MFs are defined.Then, for a full fuzzy inference system q p fuzzy rules are required, such as in [11,12] a fuzzy inference system has been designed where there are 12 input variables and for each variable five MFs are allocated.Hence, the entire number of rules obligatory to completely implement the system are 5 12 .It is particularly difficult for an expert to incorporate that large number of rules with attention.Any abnormality in rule designing can cause casualties of people, wastage of money or both losses.Hence, the minimization of rules in rule-base is an issue of high concern.To overcome the issue of rule-explosion, a solution is to divide the fuzzy inference system in sub-modules in a hierarchical form.In this hierarchical fuzzy logic method, the low-level modules provide fractional solutions; these fractional solutions are then combined in the high-level modules to provide a complete result for a problem.In this way, the number of rules can be reduced significantly as compared to the conventional fuzzy logic (CFL) model [13,14].Exponential increment occurs in rules using CFL models, hence rules-explosion makes designing of rules very hard, and it also increases the computational complexity.The greater number of rules means a greater possibility of errors and also designing is not an easy task because rules need utmost concentration.Hence to overcome the issue of rules-explosion in the CFL model, hierarchical fuzzy logic (HFL) models were designed in the proposed work to assess the water supply pipelines risk index.The focus of some efforts is the development of hardware boards, which are great platforms for expressing creativity in order to make and create novel things for developers.The most famous and initial efforts are the Raspberry Pi [15] and Arduino [16] boards.These boards have their own programming and it very necessary for the user to code in Python and Java because a user has these two options to write code on these boards.
In this paper, a cohesive hierarchical fuzzy inference system (CHFIS) model for water supply pipelines (WSPLs) risk index assessment was proposed.The purpose of the CHFIS model is dimensionality reduction because a large number of rules requires much effort from experts and also increases the probability of errors.The proposed CHFIS model can be applied for risk assessment where the number of input variables are larger because the proposed CHFIS takes fewer rules as compared to the traditional FL models.For MFs determination of each fuzzy logic in the CHFIS we suggested technique names as the heuristic based membership function determination (HBMFD) method in order to determine appropriate MFs to sub-fuzzy logics in CHFIS model.The risk index values of the proposed CHFIS system is represented through LED actuators using different colors.The caretaker can take measures according to the risk index level provided by the proposed model.
The organization of the remaining paper is carried out as: Section 2 represents the related work section, and in Section 3 the proposed work is explained in detail.The implementation, results and discussion are given in Section 4 in detail.The paper conclusion is given in Section 5.

Related Work
Subjective judgments from experts are required to assess water supply pipelines (WSPL) risk.However, experts having prospective knowledge are extremely difficult to find as well time-consuming and expansive.Therefore, the alternative way is to develop an efficient method to assess the water supply risk index.Many efforts have been carried out in this regard since the last few decades, the discussion of some of which are carried out here.
The most used and efficient method for risk assessment and management is fuzzy logic which has been extensively used in numerous fields to assess risks [17].Li et al. [18] suggested a technique to analyze the risk of long-distance water transmission pipelines.The fuzzy concepts were used in the suggested methodology.Tripathy et al. [19] suggested a technique to assess the safety risk index of coal mines.The proposed method was based on the fuzzy reasoning methodology and authors have used the fuzzy logic method despite the availability of other similar techniques.A case study was conducted to validate the applicability of the method.According to the results, fire has a high-risk index as compared to other risk parameters.Chen et al. [20] designed a decision-making approach based on FL for handling supplier chain selection proposed in a supply chain system.Gul et al. [21] applied the fuzzy logic concept in the aluminum industry.Zhao et al. [22] suggested an FL based method to assess risk in green projects.Zhang et al. [23] proposed a fuzzy comprehensive evaluation approach to assess underground risk index.
Different authors have developed different techniques based on hierarchical fuzzy logic (HFL) methods to overcome the rules-explosion problem that existed in the conventional FL method.Fayaz et al. [14] designed a model named as integrated, based on the HFL method for underground risk calculation.The integrated HFL method significantly reduce the rules with a larger number of input variables.Fayaz et al. [17] suggested another method for rule reduction based on HFL and Kalman methods for underground risk index calculation and prediction.Like the integrated HFL method, this method also decreases the number of rules.These two methods are suitable to be applied in a situation where the input variable parameters are greater in number.Chang et al. [24] designed a simple HFL system for rules reduction.In their proposed model, the fuzzification and defuzzification method was removed in order to make it as simple as possible.

Proposed Water Supply Pipeline Risk Index Methodology
The critical issue of traditional FL is rule-explosion when more parameters are added to the system.Two main drawbacks are associated with rules-explosion.First, it increases the computation complexity of the system and second, it is very challenging to design a large number of rules.In this paper, we designed an FL model based on HFL to solve the problems associated with conventional fuzzy logic.The conventional fuzzy logic is shown in Figure 1.The proposed model, named a cohesive model, is illustrated in Figure 2. The proposed model consisted of three layers; input layer, middle layer, and top-level layer.In the input layer, we have four inputs namely depth, length, height and age.The middle layer consisted of the two fuzzy inference systems (FISs) namely FIS_1 and FIS_2.Inputs to the FIS_1 are depth (P 1 ) and length (P 2 ) parameters, and inputs to FIS_2 are age (P 3 ), and leakage (P 4 ).The outputs of FIS_1 and FIS_2 are further inputs to the FIS_3 of the top-level layer.The proposed model dramatically reduces the rules in FIS.Next, we applied the proposed cohesive model to real data supplied by the Electronics and Telecommunications Research Institute (ETRI) organization.The data was gathered from 1989 to 2010 for WSPLs installed at different points in Seoul, South Korea.In the future, we assume that more parameters would be entered into the system.Hence, we have designed the model a way that if more parameters enter into the system, rule-explosion would not occur.
The pseudo code of the proposed CHFIS model is shown in algorithm_1.There are four inputs to the proposed CHFIS model which are presented as P 1 , P 2 , P 3 , and P 4 .The ML, RI, PR, FL, and WSPRI indicate the middle layer, risk index, partial risk, final layer and water supply pipeline risk index, respectively.
In the proposed CHFIS model we used the triangular MFs [25].There is no standard way to determine MFs; hence we also proposed a heuristic based membership function determination (HBMFD) method.In this method, some membership function sets are defined and applied to the historical data.The best results are recorded using root mean absolute error (RMSE).The RMSE formula is given in Equation (1).
where N indicates the entire number of instances, A illustrates real data, and E indicates the estimation values generated by the proposed HBMFD method.
The membership functions set is the value for the next data, considered having the minimum RMSE value.The structure diagram of the proposed membership functions determination method is presented in Figure 3.In the proposed diagram, P 1 and P 2 indicate the depth and length parameters of the FIS_1.Similarly, for FIS_2 and FIS_3 the same proposed method was applied to determine the best membership functions set.The number of rules in Mamdani fuzzy logic relies on input parameters, and MFs defined for input variables.For defining all potential rules of the proposed CHFIS model and CFL model.Equation (2) and Equation ( 3) can be used respectively.

Fuzzy Logic Model
where n indicates the number of input layers (input layer excluded), X represents the number of membership functions in a variable and m indicates the number of fuzzy inference systems in each layer.
In the proposed CHFIS model we defined six MFs for input variable P1 and five for input variable P2 of FIS_1.Similarly, for FIS_2, six and five MFs are defined for input variables P3 and P4 respectively.For output of FIS_1 five MFs, and for FIS_2 five output MFs are defined.The outputs of FIS_1 and FIS_2 are further inputs to FIS_3 and for FIS_3 output, five MFs are defined.Hence by putting these values in Equation ( 2 Hence, it is proved that the proposed CHFIS model brings a reduction in rules while implementing the full structure of FL.The number of rules required to implement the proposed model is much less, as compared to the CFL model.In Table 1 we have made a short comparison of the proposed CHFIS in terms of the required number of rules to implement the full structure FL.The number of rules in Mamdani fuzzy logic relies on input parameters, and MFs defined for input variables.For defining all potential rules of the proposed CHFIS model and CFL model.Equations ( 2) and ( 3) can be used respectively.
where n indicates the number of input layers (input layer excluded), X represents the number of membership functions in a variable and m indicates the number of fuzzy inference systems in each layer.
In the proposed CHFIS model we defined six MFs for input variable P 1 and five for input variable P 2 of FIS_1.Similarly, for FIS_2, six and five MFs are defined for input variables P 3 and P 4 respectively.For output of FIS_1 five MFs, and for FIS_2 five output MFs are defined.The outputs of FIS_1 and FIS_2 are further inputs to FIS_3 and for FIS_3 output, five MFs are defined.Hence by putting these values in Equation (2) as shown below, we require 85 rules to fully implement the proposed CHFIS model.
The number of rules requires to implement the CFL entirely; we require 900 rules as illustrated below by putting the values in Equation ( 3).CR = 6 × 5 × 6 × 5 = 900.Hence, it is proved that the proposed CHFIS model brings a reduction in rules while implementing the full structure of FL.The number of rules required to implement the proposed model is much less, as compared to the CFL model.In Table 1 we have made a short comparison of the proposed CHFIS in terms of the required number of rules to implement the full structure FL.A total of 30 rules were defined in FIS_1, as listed in Table 2. Similarly, 30 rules were defined for FIS_2 in the same manner as listed in Table 3.The linguistic terms NG, N, ND, D, DR and DT were defined to MFs of variable depth which denote near to the ground, normal, near to deep, deep, deeper and deepest.In the same way, the labels assigned to each MFs of variable length are ST, S, M, L and LG which denote shorter, short, medium, long and longer, respectively.The linguistic terms for output variable FIS_1 are defined as VLLR, LLR, MLR, HLR and VHLR which denotes very low-level risk, medium level risk, high-level risk and very high-level risk respectively.Similarly, for input variable probability of leakage of the FIS_2 modules, the linguistic terms, ELP, VLP, LP, MLP, HLP and VHP, EHP were defined.These terms are abbreviations of extremely low probability, very low probability, low probability, medium probability, high probability and very high probability.The labels assigned to the second input variable age of FIS_2 module are OD, O, MA, N and BN which denote older, old, medium age, new and brand new.For the output variable of FIS_2, the same number and linguistic terms of MFs were defined as for output variables of FIS_2.The output of the FIS_1 and FIS_2 are further inputs to FIS_3.The linguistic terms for the output variables of FIS_3 are VLR, LR, MR, HR, and VHR which denote very low risk, low risk, medium risk, high risk and very high risk, accordingly.The rules for FIS_3 are given in Table 4.

Implementation
The implementation of the CHFIS model was carried out in C#, but for visual graphical MFs and rules, we used MATLAB version 7.10.0.499 installed on an Intel (R) Core (TM) i5-3570 CPU@3.40GHz computer system.In this work, we developed a CHFIS model for WSPL risk assessment.The determined MFs for FIS_1 are shown in Figure 4.

Implementation
The implementation of the CHFIS model was carried out in C#, but for visual graphical MFs and rules, we used MATLAB version 7.10.0.499 installed on an Intel (R) Core (TM) i5-3570 CPU@3.40GHz computer system.In this work, we developed a CHFIS model for WSPL risk assessment.The determined MFs for FIS_1 are shown in Figure 4.The rule viewer using the above input and output MFS is illustrated in Figure 5 in order to demonstrate the operation of FIS_1.The input/output MFS for FIS_2 are illustrated in Figure 6. Figure 6a represents the MFs of the input variable leakage probability, and Figure 6b indicates the MFs of the input variable age and Figure 6c indicates MFs of the output variable of FIS_2.The rule viewer using the above input and output MFS is illustrated in Figure 7 in order to demonstrate the operation of FIS_2.The outputs of the FIS_1 and FIS_2 were used as inputs to FIS_3.Same MFs were defined for the input variable FIS_3 as for the output variable of FIS_1.The output membership functions for FIS_1 and FIS_2 are illustrated in Figure 4c and Figure 6c respectively.For the output variable FIS_3, the determined MFs are given in Figure 8.The rule viewer using the above input and output MFS is illustrated in Figure 7 in order to demonstrate the operation of FIS_2.The rule viewer using the above input and output MFS is illustrated in Figure 7 in order to demonstrate the operation of FIS_2.The outputs of the FIS_1 and FIS_2 were used as inputs to FIS_3.Same MFs were defined for the input variable FIS_3 as for the output variable of FIS_1.The output membership functions for FIS_1 and FIS_2 are illustrated in Figure 4c and Figure 6c respectively.For the output variable FIS_3, the determined MFs are given in Figure 8.The outputs of the FIS_1 and FIS_2 were used as inputs to FIS_3.Same MFs were defined for the input variable FIS_3 as for the output variable of FIS_1.The output membership functions for FIS_1 and FIS_2 are illustrated in Figures 4c and 6c respectively.For the output variable FIS_3, the determined MFs are given in Figure 8.The rule viewer using the above input and output MFS is illustrated in Figure 7 in order to demonstrate the operation of FIS_2.The outputs of the FIS_1 and FIS_2 were used as inputs to FIS_3.Same MFs were defined for the input variable FIS_3 as for the output variable of FIS_1.The output membership functions for FIS_1 and FIS_2 are illustrated in Figure 4c and Figure 6c respectively.For the output variable FIS_3, the determined MFs are given in Figure 8.The rule viewer using the above input and output MFS is illustrated in Figure 9 in order to demonstrate the operation of FIS_3.

Results of CHFIS model
In this paper, we applied the CHFIS model on four input parameters namely depth, length, age and leakage probability.Only four parameters were considered for WSPRI because we have real data for these parameters supplied by the Electronics and Telecommunications Research Institute (ETRI) organization.The data was gathered from 1989 to 2010 of WSPLs located at different locations of Seoul, Republic of Korea.The input data for depth, length, age and leakage is given in Figure 10.

Results of CHFIS Model
In this paper, we applied the CHFIS model on four input parameters namely depth, length, age and leakage probability.Only four parameters were considered for WSPRI because we have real data for these parameters supplied by the Electronics and Telecommunications Research Institute (ETRI) organization.The data was gathered from 1989 to 2010 of WSPLs located at different locations of Seoul, Republic of Korea.The input data for depth, length, age and leakage is given in Figure 10. Figure 12 shows the experimental setup for the proposed work.In this setup, Raspberry PI was used as an IoT gateway.It also hosts an IoT server which listens to the requests, processes them and takes action accordingly.For visualization of risk, six LED actuators were used; each of them represents a category of risk.For instance, in Figure 12, the red color LED is turned on which indicates the risk factor is high.The LED light indication can be useful in assessing risk index while deploying it in a real environment where actual lights represent the risk index in some locations.Six LEDs were used for different risk categories.

Conclusions and Future Work
In this paper, we proposed a new model based on the hierarchical structure for water supply pipeline risk index called the cohesive hierarchical fuzzy inference system (CHFIS).In the proposed CHFIS for MFs determination, we used a new method called the heuristic based MFs determination scheme in order to determinate accurate MFs for fuzzy logic modules.We used real data to calculate the risk index values for water supply pipelines risk index assessment.The risk indexes of WSPLs was categorized in different levels.Next, the risk index values calculated by CHF were shown by different LED light colors in order to assist the caretaker in taking measures accordingly.In the future, we would like to design different hierarchical fuzzy logic models and carry out their implementation in order to cover a different aspect of the data and different caretaker demands for the water supply Figure 12 shows the experimental setup for the proposed work.In this setup, Raspberry PI was used as an IoT gateway.It also hosts an IoT server which listens to the requests, processes them and takes action accordingly.For visualization of risk, six LED actuators were used; each of them represents a category of risk.For instance, in Figure 12, the red color LED is turned on which indicates the risk factor is high.The LED light indication can be useful in assessing risk index while deploying it in a real environment where actual lights represent the risk index in some locations.Six LEDs were used for different risk categories.Figure 12 shows the experimental setup for the proposed work.In this setup, Raspberry PI was used as an IoT gateway.It also hosts an IoT server which listens to the requests, processes them and takes action accordingly.For visualization of risk, six LED actuators were used; each of them represents a category of risk.For instance, in Figure 12, the red color LED is turned on which indicates the risk factor is high.The LED light indication can be useful in assessing risk index while deploying it in a real environment where actual lights represent the risk index in some locations.Six LEDs were used for different risk categories.

Conclusions and Future Work
In this paper, we proposed a new model based on the hierarchical structure for water supply pipeline risk index called the cohesive hierarchical fuzzy inference system (CHFIS).In the proposed CHFIS for MFs determination, we used a new method called the heuristic based MFs determination scheme in order to determinate accurate MFs for fuzzy logic modules.We used real data to calculate the risk index values for water supply pipelines risk index assessment.The risk indexes of WSPLs was categorized in different levels.Next, the risk index values calculated by CHF were shown by different LED light colors in order to assist the caretaker in taking measures accordingly.In the future, we would like to design different hierarchical fuzzy logic models and carry out their implementation in order to cover a different aspect of the data and different caretaker demands for the water supply

Conclusions and Future Work
In this paper, we proposed a new model based on the hierarchical structure for water supply pipeline risk index called the cohesive hierarchical fuzzy inference system (CHFIS).In the proposed CHFIS for MFs determination, we used a new method called the heuristic based MFs determination scheme in order to determinate accurate MFs for fuzzy logic modules.We used real data to calculate the risk index values for water supply pipelines risk index assessment.The risk indexes of WSPLs was categorized in different levels.Next, the risk index values calculated by CHF were shown by different LED light colors in order to assist the caretaker in taking measures accordingly.In the future, we would like to design different hierarchical fuzzy logic models and carry out their implementation in order to cover a different aspect of the data and different caretaker demands for the water supply

Figure 9 .
Figure 9. Rule viewer for the output variable of FIS_3.

Figure 9 .
Figure 9. Rule viewer for the output variable of FIS_3.Table 5 overviews the implementation stack of the embedded hardware being used in the experiments.Raspberry PI 3 model B was utilized as a gateway on which Raspbian OS was installed.Furthermore, LEDs with different colors were connected with different general-purpose input/output (GPIO) ports of Raspberry PI to trigger one of them based on the risk index.Vim was used as a terminal editor whereas a full-fledged IDE named as PyCharm was used to access the Raspberry PI terminal remotely.For communication, CoAP protocol was used, and the CoAP server was installed on Raspberry PI to listen to the requests.

Processes 2019, 7 ,Figure 11 .
Figure 11.The real risk index values and the estimated risk index values calculated by the CHFIS method for water supply pipelines (WSPL).

Figure 12 .
Figure 12.The experimental environment for the risk index of CHFIS model.

Figure 11 .
Figure 11.The real risk index values and the estimated risk index values calculated by the CHFIS method for water supply pipelines (WSPL).

Figure 11 .
Figure 11.The real risk index values and the estimated risk index values calculated by the CHFIS method for water supply pipelines (WSPL).

Figure 12 .
Figure 12.The experimental environment for the risk index of CHFIS model.

Figure 12 .
Figure 12.The experimental environment for the risk index of CHFIS model.

Table 1 .
Fuzzy logic with the number of rules.

Table 5 .
Components description of the Raspberry PI.

Table 5 .
Components description of the Raspberry PI.