Abstract
Failure of pressurised pipe is a potentially significant hazard to people and the environment. Corrosion is one of the main causes of failures in pipelines. Corrosion is often accompanied by a high degree of uncertainty, since it is a dynamic process, and its rate does not follow a typical mathematical law in a lot of cases. There are various methodologies used to assess risks to pipeline integrity. Probability based models are the most complex, requiring substantial amounts of data for proper development. Fuzzy logic provides an easy way of dealing with complex problems because it can be built with fuzzy models containing vagueness and impreciseness in knowledge representation. A combination of fuzzy logic theory and expert judgement can be used to accomplish the modelling of the probability and severity of consequences. This paper presents the possibility of the use of fuzzy logic to assess the risk of corrosion in natural gas pipelines.
Introduction
There are millions of kilometres of oil and gas transmission pipelines around the world. The pipeline systems must deliver its product in a continuous manner and have low risk of supply failure. Furthermore, the pipeline operators have to achieve an acceptably low risk to the surrounding population.
Pipelines are a safe and reliable mode of transportation. However, pipelines represent large capital cost, and any pipeline failure has significant economic impact due to the cost of repair and the loss of transportation capacity. 1 Transmission pipeline companies spend a large part of their operating budgets to ensure that pipelines run safely and reliably.
The most significant causes of damage and failures in oil and gas transmission pipelines are outside force/third party damage, corrosion and mechanical material failures due to incorrect selection of material, welding process or construction defects. Therefore, most of the failures occur on onshore pipelines, because they cover a much greater area, but failures on offshore lines normally take longer to repair and therefore are more serious in terms of business interruption. 2
Corrosion is probably the greatest challenge facing the oil and gas industry and leads to expensive production interruptions and delays. 3 Corrosion is a chemical or electrochemical process that causes metal loss. It can appear on the internal or external surfaces of the pipe, in the base material, the seam weld, the girth weld and/or the associated heat affected zone. 4 There are many different types of corrosion, including galvanic corrosion, microbiologically induced corrosion, ac corrosion, differential soils, differential aeration and cracking and the most usual corrosion morphology as either general corrosion or localised (pitting) corrosion. 5 Corrosion is a time and local environment within or beside the pipeline dependent mechanism. Some pipelines deteriorate slowly, and in certain cases, pipeline life has been reliably targeted at 70 years or more. Other pipelines that have exhausted their useful life after 1 year of operation have been built.
Corrosion failures can be either leaks or ruptures, with the latter being of primary concern. Failure in gas distribution pipelines in most cases is a leak. Leaks from gas pipelines generally do not cause property damage, because the escaping gas disperses into the atmosphere, and the consequences can be significant in populated areas. However, leaks from a liquid line can contaminate the soil, groundwater or surface water. Conversely, ruptures in a gas pipeline are more likely to cause an explosion and fire, thus resulting in more fatalities and injuries on average. The consequences from both ruptures and leaks in a liquid pipeline can be significant due to the potential for environmental damage. A reduction in the number of corrosion incidents is desirable from both safety and financial standpoints. 6
Risk assessment
The concept of risk is used to assess and evaluate uncertainties associated with an event. Risk can be defined as the potential for loss as a result of system failure. 7 An operator must ensure that all risks associated with the pipeline are as low as is reasonably practicable. Occasionally, an operator will detect, or became aware of, defects in their pipeline. In the past, this may have led to expensive shutdowns, repair and maintenance steps. However, recent years have seen the increasing use of fitness for purpose methods to assess these pipeline defects.
The use of the latest inspection methods and equipment will assist in obtaining the maximum life expectancy from a pipeline, reducing the overall operating costs. Non-destructive tests (NDTs) are performed in a manner that does not affect the future usefulness of the object or material. 8 The NDT allows parts and material to be inspected and measured without damaging them. Because it allows inspection without interfering with a product's final use, NDT provides an excellent balance between quality control and cost effectiveness. 9 Some of these methods are visual and optical testing, penetrating testing, magnetic particle testing, radiography, ultrasonic testing and acoustic emission testing.
If the expected life of a section of pipeline is relatively short, the operator must decide whether recoating and repair would extend the life. 10 Replacing the pipe may then be the best solution. Assessment methods are needed to determine the severity of such defects when they are detected in pipelines. Risk assessment is a process used to determine the likelihood and consequences of a failure due to a potential threat. Risk management generally refers to a programmatic approach that involves identifying potential threats, assessing the risk associated with the threats (in terms of the likelihood and consequences of failure), mitigating the risk and then monitoring the effectiveness of the programme in reducing the risk. Risk assessment requires detailed information on the frequency failure rate of particular components of the pipelines that are uncertain and imprecise. Uncertainty arises when information or knowledge is deficient. There is a close relationship between complexity and uncertainty, and it is said that as complexity increases, certainty decreases. Figure 1 shows the framework for the methodology used in this paper.

Framework for extended methodology
Risk assessment and risk management are processes essential to the successful management of pipeline integrity. 11 These processes provide the foundation for prioritising efforts on the highest risk pipelines and serve as the technical basis for the actions implemented to mitigate the threats to the pipeline. Integrating quality data into the models ensures that the risk models accurately reflect the conditions of and relative risks to the pipeline. These processes must be continually evaluated and improved by utilising the lessons learned from experience, both of the individual operator as well as within the industry. 12
There are various methodologies used to assess risks to pipeline integrity. Common methodologies (presented in order of increasing difficulty in obtaining sufficient data) include the following:
subject matter expert method
relative risk model method
probabilistic based model.
If reliable assessment data are not available and/or no previous, formal risk assessment has been performed on the system, then qualitative risk assessments based on input from subject matter experts may be appropriate.
The relative risk model method 13 is used to assess and prioritise risks by ranking and filtering the available data on the systems, sources of stressors and effects of stressors on the assessment endpoints. It is a semiquantitative means of combining the actions of multiple stressors on multiple assessment endpoints residing in a complex and dynamic system.
Probability based models are the most complex, requiring substantial amounts of data for proper development. 14 Many operators prefer to use probabilistic models since the models can quantify risk. However, care should be taken since often there are not enough actual data to yield meaningful results, and hence, it is necessary to estimate missing data or to follow conservative assumptions. Owing to the insufficient information of operation history of a pipeline, in particular attending the actual size of defects of corrosion that affects the remaining mechanical strength value of the pipeline, it is difficult to evaluate its safety by analytical methods. Probabilistic models can be particularly meaningful when calibrated by the actual incident frequency rates of an operator's system. However, the ‘quantitative’ results must be carefully scrutinised when extrapolated to new situations. All of the individual conditions (risk variables) of a particular pipeline may not be included in the model. Therefore, the ability of the model to define the risk at any particular location along the pipeline should be carefully reviewed for site specific applicability.
The probabilistic approach to the assessment of pipeline corrosion risks deals with many of the uncertainties that are common to the data employed and those with regard to the predictive models that are used. 15 The results from the application of a probabilistic model are generally expressed as the probability of an event occurring times the probable consequences of such an event. The probability rating can then be compared with the overall risk history of the operator's pipeline, level of desired performance and industry accepted rates.
Before any field survey, the corrosion engineer should gather as much information as possible about the pipeline to be studied. This may provide valuable data on corrosion conditions to be expected and should be helpful in planning a survey programme that will yield useful data for design purposes. It is often difficult to estimate the precise failure probability of the components due to insufficient data of the events caused by poor measurements, subjective information and so on. Deterioration modelling is an essential element of the decision making process for rehabilitation or renewal programmes. Different mathematical and statistical techniques have been developed to model pipe deterioration. Therefore, probabilistic models are widely used in infrastructure deterioration modelling.
Fuzzy logic
In many engineering problems, the available information about the probabilities of various risk items is little known or assessed, and hence, information in terms of either measured data or expert knowledge is too imprecise to justify the use of crisp numbers.16,17 Zadeh 18 introduced the term computing with words to explain the notions of reasoning linguistically rather than with numerical quantities. 19 In other words, the main contribution of fuzzy logic to the modelling process is a methodology for computing with words. Fuzzy logic is a general name of ‘fuzzy set analysis’ and ‘possibility theory’, which can work with uncertainty and imprecision and is an efficient tool for applications where no sharp boundaries (or problem definitions) are possible. Fuzzy logic extends binary logic in this context as it recognises the real world phenomena using a certain degree of membership between 0 and 1.
Rather than considering each input parameter as an average value, the approach considers the inputs as a series of probability density functions; the collective use during the assessment of risk yields a risk profile that is quantified on the basis of uncertain data.
The decision makers usually evaluate and describe systems using imprecise terms that may be translated into linguistic variables (e.g. very high, high, very low and low). On the other hand, there is usually some numerical information available for input and output data, although incomplete and uncertain in nature. The strength of fuzzy logic is that it can integrate descriptive (linguistic) knowledge and imprecise numerical data into a fuzzy model and use approximate reasoning algorithms to propagate the uncertainties throughout the decision process. A fuzzy model, as described by Zadeh, contains the following three distinguished features:
linguistic variables instead of, or in addition to, numerical variables
simple relations between the variables in terms of IF–THEN rules
inference mechanism that uses approximate reasoning algorithms to formulate complex relationships.
This approach uses the concept of a pure fuzzy logic system where the fuzzy rule base consists of a collection of fuzzy IF–THEN rules. The fuzzy inference engine uses these fuzzy IF–THEN rules to determine a mapping from fuzzy sets in the input universe of discourse to fuzzy sets in the output universe of discourse based on fuzzy logic principles. 20 Fuzzy logic provides an easy way of dealing with complex problems because it can be built with fuzzy models containing vagueness and impreciseness in knowledge representation. It is suited for applications where the ability to model real world design problems in precise mathematical forms is difficult. This approach differs from the traditional deterministic assessment in that the output yields a curve that shows how the ‘risk’ of failure increases with time. A combination of the fuzzy logic theory and expert judgement can be used to accomplish the modelling of the probability and severity of consequences.
The pipeline operator simply chooses the level of risk that is acceptable and then devises a strategy to deal with those risks. The traditional or deterministic approach merely segments the output risks as either ‘high’, ‘medium’ or ‘low’; a strategy for managing is devised based on the selection of an appropriate time interval to allow a reasonable prospect of detecting deterioration before the pipeline corrosion allowance is exceeded, or no longer complies with code.
Results and discussion
In this case study, the risk assessment using fuzzy logic was performed for a gas pipeline that can suffer stress corrosion cracking (SCC). The SCC is the cracking in a metallic material consequence of the combined influence of tensile stress in mode I and a corrosive environment. The SCC is an insidious type of corrosion since it produces a marked loss of mechanical strength with little metal loss. The damage is not obvious to casual inspection, and stress corrosion cracks can trigger mechanical fast fracture and catastrophic failure of components and structures.21,22 The presence of high concentrations of hydrogen sulphide (H2S) in natural gas creates a corrosive environment. 23
The examination is conducted based on three simple processes, including concentration of hydrogen sulphide (H2S) in natural gas, pipeline mechanical strength and measurement of the thickness loss due to external corrosion. The corresponding data for different inputs are:
concentration of hydrogen sulphide (H2S): 17 mg m−3
mechanical strength (σ): 565 MPa
thickness loss (t): 6%.
Estimated values are evaluated by an expert. In the fuzzy logic model, the universe of discourse is normally divided into several regions that belong to different predicates such as, unacceptable (U), barely acceptable (BA), just acceptable (JA), good (G) and very good (VG). These predicate functions have special shape, height and line style to represent their membership function. In this case, they are triangular.
The input fuzzy set comprises several membership values from different fuzzy inputs. The expression of the membership value is presented in equation (1)

a membership value of μH2S; b membership value of μσ; c membership value of μt
The output is the chance of failure (CF). Where CF is the fuzzy set, cf i is the element in the set, and μ CF(cf i) is the membership function attending equation (2)
The fuzzy inference engine converts the input fuzzy set into output fuzzy set through an inference process that includes rule block formation, rule composition, rule firing, implication and aggregation. Figure 3 presents this sequence.

Rule tables of fuzzy system
Rule block consists of a number of fuzzy rules that are interrelated and normally operate based on certain set criteria. The number of rules is determined in line with the complexity of the associated fuzzy system. A fuzzy rule is composed of two parts, namely, IF part and THEN part. Rules can be displayed in table format, which can easily be searched, in the way presented in Table 1.
Rules generation
As shown in the previous figures, the input crisp values for H2S, σ and t are fuzzified. In this case, the concentration of hydrogen sulphide (H2S) is 5 mg m−3 and cuts the BA predicate at 0·65 and U predicate at 0·35. The pipeline mechanical strength (σ) is 565 MPa and cuts the BA predicate at 0·75 and U predicate at 0·25. The thickness loss (t) is 6% and cuts the JA predicate at 0·8 and BA predicate at 0·2 (as shown in Fig. 2). Therefore, as shown in Table 1, eight rules are generated based on the rule set presented in Fig. 3.
Table 2 shows how the minimum membership function values are chosen for the associated rules.
Composition results of rule of IF part
The eight results are then put into the implication process, which is used to determine the output fuzzy set. The Mamdani operator is used for the implication so that the minimum input membership is copied to the output term. This simple strategy is sufficient for the existing rules. Its basic rule is that the truth of the conclusion cannot be greater than the degree of fulfilling an assumption. The Mamdani operator is selected as the implication operator; in this case to implicate the result of the rules based on equation (3)
. The implication results are shown in Fig. 4.

Implication results
The eight results are fused for aggregation using aggregation operator Union (
) to generate the final fuzzy set.
Defuzzification process is required in order to determine the crisp value. The method of ‘centre of area’ is selected for this case due to its simplicity of use represented by general equation (4)
Data for defuzzification process
The centre of area, calculated using equation (4), is 76·15%, which represents the CF of the asset under examination. These data are very important in order to determine if the pipelines must be refurbished or replaced or a more stringent examination is needed looking for a minimum risk of failure in service.
Conclusions
In this paper, a new methodology of evaluating uncertainty in risk assessment has been presented, based on fuzzy logic, and has been applied to the risk assessment of corrosion in oil and gas pipelines, showing that it can be easily applied in pipeline risk assessment taking into account chemical, mechanical and design variables of pipeline. The fuzzy logic methodology allows the identification, from all uncertain variables, of those that most greatly influence the output, and the rapid evaluation of the effect that changing the values of these variables has on the final result. It enables better assessment of the accident scenarios, proper calculation of the risk index and more appropriate selection of safety measures required to meet risk acceptance criteria. The success of this method depends on the quality of failure data collection as well as on expertise of operators.
It would be interesting that the petrochemical industry be in mind with this method into its protection corrosion measures in order to take account of the potential risk of premature failure to avoid it.
