Renato de S. Motta1, Silvana M. B. Afonso², Paulo R. M. Lyra³, Ramiro B. Willmersdorf4, Edmundo Q. Andrade5

Copyright 2012, Instituto Brasileiro de Petróleo, Gás e Biocombustíveis - IBP Este Trabalho Técnico foi preparado para apresentação na Rio Oil & Gas Expo and Conference 2012, realizado no período de 17 a 20 de setembro de 2012, no Rio de Janeiro. Este Trabalho Técnico foi selecionado para apresentação pelo Comitê Técnico do evento, seguindo as informações contidas no trabalho completo submetido pelo(s) autor(es). Os organizadores não irão traduzir ou corrigir os textos recebidos. O material conforme, apresentado, não necessariamente reflete as opiniões do Instituto Brasileiro de Petróleo, Gás e Biocombustíveis, Sócios e Representantes. É de conhecimento e aprovação do(s) autor(es) que este Trabalho Técnico seja publicado nos Anais da Rio Oil & Gas Expo and Conference 2012.

The Finite Element Method (FEM) has proved to be a powerful tool to predict the failure pressure of corroded pipes, although the generation of good computational models of pipes with corrosion defects can take several days. This makes the use of computational simulation procedure difficult to apply in practice. A set of computational tools to produce automatically models of pipes with defects, ready to be analyzed with commercial FEM programs, starting from a few parameters that locate and provide the main dimensions of the defects assuming general spatial locations along the pipe, has been developed and validated in previous authors work. Here these defects can be internal or external simultaneously and also be in different sizes. These tools were based on MSC.PATRAN pre and post-processing programs and were written with PCL (Patran Command Language). The program for the automatic generation of models (PIPEFLAW) has a simplified and customized graphical interface, so that an engineer with basic notions of computational simulation with the FEM can generate rapidly models that result in precise and reliable simulations. Some examples of models of pipes with multiple defects of different sizes generated by the PIPEFLAW system and its numerical simulation´s results are shown. The FP numerically obtained with the automatic generated models, will be compared with results obtained by semi-empirical methods (A. C. Benjamin and D. J. S. Cunha, 2007). The obtained results highlight the importance of FP prediction via FEM due to the conservatism of the semi-empirical methods, as well as, to develop new empirical methods. 1. INTRODUCTION During the operation of pipelines, great part of accidents originates from corrosion defects. The accurate prediction of the failure pressure (FP) of pipelines with corrosion defects is one of the most important issues in structural integrity analysis of high pressure pipeline system, including onshore and offshore installations. To avoid human losses, and also economic, social, environmental, and image damages to the company, a huge attention is being given to prevent corrosions as well as its monitoring. Many methods for FP prediction in pipelines with corrosion defect are available, the most widely used are the semi-empirical methods (BS7910, 1999; DNV, 1999) known to be very conservatives (Fu and Batte, 1999; Motta et al., 2009). Some FP prediction methods can provide accurate results, like numerical methods by the FEM, and experimental burst tests. These methodologies can also be used to evaluate and validate the results of the semi-empirical methods (Andrade et al., 2006; Benjamin et al., 2006a, 2006b). However, the FEM modeling and analysis processes require a high specialized engineering and specific software knowledge and experience. Besides that, the modeling process of a single pipeline with idealized corrosion defect could take weeks and is quite repetitive, therefore it is very prone to error. The burst tests, on the other hand, require a specific infrastructure, equipments and material for the manufacturing of the idealized defects in the pipe specimen section. Besides that, the burst tests are time-consuming processes and it cannot be analyzed more than once for the same specimen. In others works, Cabral, (2007b) and Motta, (2010) present and validate a set of computational tools called PIPEFLAW for automatic generation of Finite Element (FE) models of pipelines containing a single idealized corrosion defect or multiple corrosion defects of the same size. The present work concerns to develop extended tools to PIPEFLAW to automatically generate FE pipelines models with multiple defects with different sizes in arbitrary position, located on internal and/or external pipe surface.

______________________________ 1 Master, Civil Engineer - UFPE 2,3,4 Ph.D., Professor – UFPE 5 Master, Civil Engineer – PETROBRAS


The input data is done through a friendly graphical user interface (buttons, menus and data boxes to data capture), where the pipe dimensions, defects dimensions and defect locations, for multiple defect cases, can be given. These tools are based on the MSC.PATRAN pre and post-processing commercial software, the code was written with PCL (Patran Command Language) (PATRAN, 2005). The models generated by PIPEFLAW can be analyzed with different FE analysis software. In this work the new procedure will be described, to automatically generate FE models of pipelines with interacting corrosion defects of different sizes. The first step performed by the PIPEFLAW program is the automatic generation of the geometry and mesh of the defect box. In the next step, by rotation and translation operations, the defectboxes are placed in their proper positions along the pipe. The next step consists in generating the geometry and mesh between the defects. In the preprocess stage, the defects region is divided in several longitudinal slices. The defects longitudinal edges define the slices of the defect region. The defects contained in each slice are computed and the regions between them, called connections, are stored. After this preprocessing stage the solids and finite element mesh of each connection are built. After completed the generation of the defect region, adjacent regions called transition regions are constructed to decrease the mesh density in the regions far from the defects (in which there is no stress concentration). Finally, the remaining regions are built. The models generated can then be analyzed by several softwares that use the Finite Element Method (Crisfield, 1991; Bathe, 1996). In this work, ANSYS (ANSYS, 2004) will be used for non-linear physic and geometric analysis to obtain the failure pressure (FP) value. The FP numerically obtained with the automatic generated models, will be compared with results obtained by semi-empirical methods (A. C. Benjamin and D. J. S. Cunha, 2007). The obtained results highlight the importance of FP prediction via FEM due to the conservatism of the semi-empirical methods, as well as, to develop new empirical methods. 2 PIPEFLAW PROGRAM The PIPEFLAW program includes a set of functions and graphical interface classes implemented in PCL language to generate automatically FE pipe models with corrosion defects following some mesh standards adopted by PETROBRÁS R&D Center (Cabral, 2007). These standard procedures can be modified in the recent versions of the program. The input data for the automatic generation of pipe models is done entirely by graphical user interface (GUI) tools. 3 MODEL GENERATION The steps to automatically generate the entirely model of the pipeline with defects with different dimensions are given below: 1 - Generate a quarter of the defects regions; 2 - Generate the complete defects; 3 - Position of the complete defects on the pipe; 4 - Generate the intersection matrices of the defects; 5 - Generate the connections between the defects; 6 - Generate the adjacent region to the defect (transition region); 7 - Generate the remaining model. As presented above, the first step to build the pipe model with defects in an arbitrary configuration consists in generating each defect box following the procedure described in detail in Cabral (2007). The full defects are then completed (through symmetry operations), providing a box containing the local mesh (Figure 1(a)) for each defect. In the next steps the defect boxes are placed in their final positions by rotation and translation operations, as shown in Figure 1(b).

Rio Oil & Gas Expo and Conference 2012.


Figure 1. Generation of defect mesh boxes on their proper position: (a) isolated defect box and (b) locating the defect boxes along the pipe. To obtain a complete consistent mesh for the whole pipe, compatible with the properly located set of defect mesh boxes, we go through the defects, building solids in the longitudinal (axis z) directions and then generating finite element meshes inside the solids. Each of these solids is created using a developed function whose input data are the four vertices of the solid on the external pipe surface. Those four points can either already exist or can be generated during the process. Some of the important stages required in this process will be described in the next sub-section, but for further details please see Motta et al (2010). 3.1 Longitudinal Intersection – Pre-processing stage To generate the intersection solids for each defect box, a pre-processing procedure is performed to find out which defect boxes interact with each other along the two directions, longitudinal and circumferential. These connections and consequently the entire pre-processing step are used only for the generation of defects region, called colony-box defects. Through the positions (longitudinal and circumferential coordinates) of the centers and the dimensions of each defect, two points, related to circumferential coordinate, are defined: one called initial theta point (ti) and the other called final theta point (tf), i.e. tik = θk - wk/2 and tf k = θk + wk/2 (1) where θk is the circumferential coordinate of the k defect and wk is the width in degrees of the k defect . The theta points divide the pipeline circumference in (2n) segments, where n is the number of defects. In Figure 2 a sketch of the multi-defect configuration presented in Figure 1(b) is presented showing the frontal intersection of each defect box. In this Figure are shown the theta points (initial and final), besides the segments (s1 to s6).

Figure 2. Longitudinal defect boxes frontal interferences. To define the connections it is necessary to verify the defects that project longitudinally on each segment. It is done by ordering the theta point and defining the first segment as the point immediately before the first theta point. The first segment does not have any projected defect. The first theta point is subsequent to the first segment, see Figure 2. From the second segment, each segment is related to a theta point before it, which defines the beginning of the segment. For example, the segment S2 begins after the theta points 1 and it is related to it. From these data we create the initial projections matrices following the steps below. The first segment does not have any projection defect. For each other defect:   Consider initially that the segment have the same defects projections that the anterior segment. Verify if the related theta is a initial or final point o If it is initial, the defect related to the theta point is included in the segment that it begins o Otherwise (final point), the defect related to the point is excluded.

The Table 1 shows the initial projection matrices obtained to the example illustrated in the Figure 2. Each column is related to a segment and each line indicates the defects projected in each segment. After having the defects projecRio Oil & Gas Expo and Conference 2012. 3

tions in each segment (initial projections matrices), the defects of each segment (column of the initial projections matrices) are orientated and grouped according to the longitudinal coordinate. As a result the projections matrices are obtained, as shown in Table 1(b). It is considered “f” (front) or “b” (back) when there is no interference from any defect in the negative or positive z, respectively. That is, moving towards longitudinal direction (positive or negative) we find the end of the colony-box defects. Thus, the first component of each column of the projections matrix, Table 1(a) (referent for each segment) makes a connection with “b”, until the end of the colony-box defects. The intermediate components are successively linked between them, i.e. the first to the second, the second with de third, etc. The last component of each column of the projections matrix makes one connection with “f”, until the end of the colony-box defects. Doing this we obtain the connections matrix, as shown in Table 1(c). This matrix defines the settings for connections to be made. Each component of the connections matrix consists of two numbers that indicate the defects of the connections (defects that have longitudinal projection). For example, in the third segment, the defect 1 makes connection with the end of the colonybox defects (“b”), and a second connection to the defect 2, while the defect 2 makes a connection with the front end of the colony-box defects (“f”). Table 1. Scheme to obtain the Connection Matrix: (a) initial projection matrices, (b) projection matrices (ordered defects) e (c) connection matrices. Seg. 1 Seg. 2 1 (a) Seg. 3 1 2 (b) Seg. 3 1 2 (c) Seg. 3 1, b 1, 2 2, f Seg. 4 1 2 3 Seg. 5 1 3 Seg. 6 1 -

Defect 1 Defect 2 Defect 3

Ordered Defects

Seg. 1 -

Seg. 2 1 -

Seg. 4 1 3 2

Seg. 5 1 3 -

Seg. 6 1 -


Seg. 1 -

Seg. 2 1, b 1, f -

Seg. 4 1, b 1, 3 3, 2 2, f

Seg. 5 1, b 1, 3 3, f -

Seg. 6 1,b 1, f -

3.2 Building the connections between defect boxes The connections are generated considering the intersection matrices created in the pre-processing stage. Accordingly, consider the configuration shown in Figures 1(b) and 2 and Table 1(c), the first connection shown is from defect 1 to “b” (the end of the colony-box defect). The second connection is from defect 1 to “f” (the front edge of the colony-box defect). To this configuration, the solids of the first connection, that connect defect 1 to “f”, are indicated in Figure 3, and circled in red.

Figure 3. First frontal connection of the segment 2 (connecting “1”to “f”).
Rio Oil & Gas Expo and Conference 2012. 4

To generate all the required solids that make the connection between the defect boxes, we need to find out, for each connection, which and where are the existing nodes that will be part of such connection. This operation is necessary in order to generate the solids and meshes. This procedure is carried out based on the intersection matrices. Therefore, the solids are obtained by projecting the four external surface nodes to the internal surface. The creation of extra nodes is required as not always the connections will have all required nodes to define the solids. Depending on which sides it have pre-existing nodes, different procedures to generate the connection are defined. For further details refer to Motta et al (2010). Figure 4 shows the steps to generation the complete defect colony regions, including all required connections, for the configuration described in Figure 1(b) and 3.

Figure 4. Step-by-step model generation. Far from the defect colony region, the mesh does not require the same discretization than the region near the defects, in which there is more stress concentration. Thus, adjacent to the defect colony region the transitions regions are created, in order to reduce the element density. After the number of transition regions necessary to achieve the desired element size, the element size is kept constant. In this application, four surface transitions and one thickness transition were employed. The Figure 5(a) illustrates the defect colony region and the adjacent transition region built. The Figure 5(b) shows the entire pipe model after the automatic generation process is complete.

Rio Oil & Gas Expo and Conference 2012.


Figure 5. Model after the complete process: (a) transitions region and (b) pipe model. 4. GRAPHIC INTERFACE To facilitate the process of geometric modeling and mesh generation, the input data is done through custom graphical interface that is activated in PATRAN program. This graphical interface has windows that shown the representative parameter of the defects, where the data and the configuration of the defect will be inserted by the user. Examples of the graphical interface are exposed in the next section, for more details (Cabral, 2007a).

5. APPLICATIONS 5.1. Example of Multiple External Rectangular Defects with Different Dimensions Here is displayed an example of data input, automatic generation, and nonlinear analysis of a pipeline with multiple rectangular defects of different sizes. For the example, the Table 2 introduces the values of dimensions of the pipe, where De, t and Lp are respectively, the outside diameter, thickness and the length of the pipe. Table 3 presents the values of the parameters of each defect, where L, w, d, FR and TR, are respectively, length (longitudinal dimension), width (circumferential dimension), depth, front fillet and thickness fillet radius of the defects. The input data of the defect positions and dimensions are given by defining the coordinates of two opposite vertices of each defect on the pipe, defined as Xmin, Xmax, Ymin, Ymax, as shown in Figure 7. In case of defects with equal dimensions, it may be provided separately. In such a case, the data related to the positions of defects are provided by cylindrical coordinates of the center of the defects in the pipe and the dimensions data of defects are given through the definition of both the length and width of the defects. The position of each defect is presented in table 4, where Xmin and Xmax are the circumferential positions of the vertices of the defects and Ymin, and Ymax are the longitudinal positions of the vertices of the defects, as illustrated in Figure 7. In addition are presented lθ and Z, which are the circumferential and longitudinal position of the centre of defects, in millimeters. Note that the circumferential position in millimeters, is the planned position of θ in radians, calculated as arc length for the outer radius, i.e.: lθ = θ*De/2 (mm). The positions of the vertices of the defect can be calculated using the position of the defects center and its dimensions. Thus, "Xmin" and "Xmax", are calculated as the circumferential position from the center of defect minus and more, respectively, the half of its width, i. e. Xmin = lθ – w/2 and Xmax = lθ + w/2. The calculation of "Ymin" and "Ymax" is analogous to the previous, however these are referring to longitudinal position and length of the defect, i. e. Ymin = Z L/2 and Ymax = Z + L/2. Table 2. Pipe parameters. De [mm] T [mm] Lp [mm] 500,0 10,0 1500,0 Table 3. Dimensions of defects located at arbitrary positions. L [mm] Def. 1 Def. 2 Def. 3 31 17 33 w [mm] 62 24 26 d [mm] 7 4 5 FR [mm] 3 3 3 TR [mm] 7 7 7

Table 4. Location of defects. Xmin [mm] Def. 1 Def. 2 Def. 3 0 9 28 Xmax [mm] 62 33 54 Ymin [mm] 135 242 184 Ymax [mm] 166 259 217 lθ [mm] 31 21 41 Z [mm] 150.5 250.5 200.5

By selecting "PIPEFLAW - FE Model - Idealized Defect" from the PATRAN menu, as shown in Figure 6, the window illustrated in Figure 7(a) is shown. In this window the defects configuration and pipe parameters related to Table 2, are given. The input data relate to Table 3, essentially, are given in the “Rectangular Defect Parameters” window, shown in Figure 7(b). This window emerges by clicking in “Defect Parameters” button.
Rio Oil & Gas Expo and Conference 2012. 6

Figure 6. PATRAN's main window with menu "PIPEFLAW" added.



Figure 7. PIPEFLAW Windows: (a) to supply of the pipe dimensions and choice of defects configuration and (b) window for the supply of the dimensions of the rectangular defects. The input data related to the defect position/dimension is given in the "Defect Position Parameters" window (Figure 8), that appears by pushing "Defect Position" button (Figure 7(a)) . In this window for each defect the parameters Xmin, Ymin and Xmax, Ymax is given, as are the depth, as shown in Figure 8. The values of Xmin, Xmax, Ymin, Ymax and the depths (d), are provided in Tables 3 and 4.

Rio Oil & Gas Expo and Conference 2012.


Figure 8. Input data window related to defects with different dimensions. The model obtained by the automatic generation process is presented in Figure 9(a), see also Figure 5(b). To illustrate the tool applicability, the result of an analysis via FEM is shown in Figure 9(b). The details of the analysis process were presented in Cabral, (2007).



Figure 9. Generation of a pipe with multiple defects of different sizes: (a) Automatic generated model and (b) analysis results via the FEM. The Table 5 shows the comparison of the failure pressures (FP) obtained numerically and predicted by three semiempirical assessment methods, namely, the American Society of Mechanical Engineers (ASME) B31G method (BS7910, 1999) the RSTRENG effective area method (KIEFNER and VIETH, 1990) and the Det Norske Veritas (DNV) RP-F101 ( DNV,1999). As can be observed, all semi-empirical methods results in very conservative FP values. This work allows the application of the FEM to predict FP in practice and, furthermore, in the investigation of assessments methods, as well as in the conception of new ones.

Rio Oil & Gas Expo and Conference 2012.


Table 5. Failure pressure predictions (MPa). ASME PIPEFLAW Method RSTRENG DNV B31G (FEM) FP (MPa) 18.45 16.39 17.92 24.89

5.2. Other Cases of Multiple Rectangular Defects with Different Dimensions In addition to the case described of three external defects, we present other cases of multiple rectangular defects with different dimensions. Figure 10 illustrate a case of three internal defects, Figure 11 presents a case of four external defects and Figure 12 shows a pipeline case with four defects, where two of those defects are internal and the other two are externals.

Figure 10. Generation of pipe with multiple internal defects with different dimensions.

Figure 11. FE pipeline model with four interacting defects with different dimensions.

Rio Oil & Gas Expo and Conference 2012.



(b) Figure 12. Generation of pipe model with four defects on both external and internal pipe surface: (a) external view and (b) internal view. 6. ACKNOWLEDGEMENTS The authors would like to thanks CAPES, CNPq FACEPE and PETROBRAS for the financial support of various research projects developed in this area by the PADMEC (High Performance Computation in Computational Mechanics) Research Group. 7. REFERENCES ANSYS, 2004. “Ansys Release 9.0 Documentation: Operations Guide(Chapter 3) and Structural Guide (Chapter 8)”. http://www.ansys.com. Aandrade, E.Q., Benjamin, A. C., Machado JR., P. R. S., Pereira, L. C., Jacob, B. P., Carneiro, E. G., Guerreiro, J. N. C., Silva, R. C. C., Noronha JR., D. B., 2006. “Finite element modeling of the failure behavior of pipe lines containing interacting corrosion defects”, 25th International Conference on Offshore Mechanics and Arctic Engineering OMAE 2006. Hamburg, Germany. Bathe, K. J., 1996. Finite Elements Procedures. Editora Prentice-Hall, pp.485-640. Benjamin, A. C., Freire, J. L. F., Vieira, R. D., Andrade, E.Q., 2006a. “Burst test on pipeline containing closely spaced corrosion defects”, 25th International Conference on Offshore Mechanics and Arctic Engineering OMAE 2006. Hamburg, Germany. Benjamin, A. C., and Cunha, D. J. S., 2006b, „„New method for the assessment of colonies of corrosion defects,‟‟ Journal of Pipeline Integrity, Quarter 3, 145–161. BS7910, 1999, Guide on Methods for Assessing the Acceptability of Flaws in Metallic Structures- Annex G: The Assessment of Corrosion in Pipes and Pressure Vessels, British Standard.

Rio Oil & Gas Expo and Conference 2012.


Cabral, H. L. D., Willmersdorf, R.B., Afonso, S.M.B., Lyra, P.R.M., Andrade, E.Q., 2007a, “A GUI-Based Methodology for Automatic Modeling and FE Analysis of Pipelines with Corrosion Defects”, Rio Pipeline Conference & Exposition 2007, IBP1177_07. Cabral, H. L. D., 2007b. Desenvolvimento de ferramentas computacionais para modelagem e análise automática de defeitos de corrosão em dutos, Programa de Pós-Graduação em Engenharia Mecânica, UFPE, Recife, Dissertação de Mestrado, 140f. (in portuguese) Crisfield, M. N., 1991. Non-Linear Finite Element Analysis of Solids and Structures, Editora John Wiley and Sons Ltd, London – England, pp.1-20. DNV, 1999, Recommended Practice DNV RP-F101 Corroded Pipelines, Det Norske Veritas, Norway. Fu, B. and Batte. D., 1999, “An overview on Advanced Methods for the Assessment of Corrosion in Linepipe” Offshore Technology Report – OTO 1999 051, UK. Motta, R. S. M., Afonso, S. M. B, Willmersdorf, R. B., Lyra, P. R. M., Cabral, H. L. D., Andrade, E. Q., 2009. “Automatic geometric modeling, mesh generation and FE analysis for pipelines with idealized defects and arbitrary location”, Rio Pipeline Conference and Exposition 2009, Rio de Janeiro - RJ, Brazil. Motta, R. S. M., Afonso, S. M. B, Willmersdorf, R. B., Lyra, P. R. M., Andrade, E. Q., 2010. “Automatic Modeling and Analysis of Pipelines with Colonies of Corrosion Defects”, CILAMCE 2010, Buenos Aires – Argentina. PATRAN, 2005, Help system: MSC.Patran Library (PCL Manuals) and MSC.Acumen Library (Develop Manuals). http://www.mscsoftware.com.

Rio Oil & Gas Expo and Conference 2012.