Introduction

A hydrocarbon production network is the collection of pipes, wells, valves, pumps that take the fluid from the reservoir to the processing facilities (Fig. 1). The layout and characteristics of the network might vary significantly depending on the geographical location of the reservoir (offshore, onshore, remote access), the field development concept, the presence of neighboring fields, among others. It is also possible that the network layout changes with time, e.g., when a neighboring reservoir is discovered, new wells are drilled.

Fig. 1
figure 1

Example of a production network

Typically, most production networks have elements installed to control fluid rates (valves, pumps) and might have several fluid routing alternatives that are applied by opening and closing on–off valves. This usually sends the wells’ fluids through a specific pipeline, pump or compressor, or to a particular separator, among other requirements.

Typically, both in industry and in academia, numerical models are build and converged to analyze the flow performance of production networks. When in the design phase, the model serves to help screening for the most convenient configuration by running sensitivity analysis, foresee operational problems, perform design optimization, among others. In the operational phase, the model supposedly represents with an appropriate accuracy the behavior of the real system and is used to perform troubleshooting, model-based optimization, model predictive control, virtual metering, etc.

The numerical model consists of a set of steady-state conservation equations (mass, momentum and energy in each element) that must be solved simultaneously in an iterative fashion to calculate the operating rates, pressures and temperatures. The pressures at the boundaries (wells and separators) are provided as an input to the model. The near well formation is usually represented with an equation that depicts a downward monotonic relationship between bottomhole pressure and surface flow rate (inflow performance relationship, Whitson 1983). The IPR curve is usually a pseudo-steady-state representation of the deliverability of the formation at a given depletion state of the reservoir (i.e., reservoir pressure).

The process of integrating and converging the conservation equations in all pipe segments to find the flowing rates of oil, gas and water and pressures and temperatures along the system is usually referred to as network solving. This is a more general version of the graphical flow equilibrium method (also commonly known as nodal analysis). A simplified example of the flow equilibrium method is described in “Appendix 2.”

Depending on the degree of connectivity in the network, the producing rate of one well will depend more or less on the rate of the other wells. Some examples of the equations employed, solving algorithms and implementation details are presented in Tian and Adewumi (1993).

Due to the fact that the network model is steady state, the changes associated with reservoir depletion are typically introduced by using the IPR curves that correspond to the time when the analysis is performed. In some cases, the IPRs are determined from well testing and updated periodically in the network model. When running coupled models, the IPR curves are commonly generated in a reservoir simulator and transferred to the network model. An example of this methodology is shown in Fig. 2.

Fig. 2
figure 2

Loose coupling step between reservoir and network models

The network model has to represent with an acceptable accuracy the physical system. Otherwise, any analysis based on the model has limited applicability and usability. Figure 3 shows a simplified scheme designed to close the gap between the output of the model and the measured variables of the real system. The main task of the data assimilation algorithm is to receive the output from sensors and change parameters in the model until the difference between the output of the model and the measured variables is minimized. The parameters in the model are typically properties of the network that have a high uncertainty (e.g., IPRs) or empirical factors employed by the multiphase pressure drop correlations.

Fig. 3
figure 3

Data assimilation process for the network model (adapted from Barros et al. 2015)

This issue is not addressed in the present work (i.e., an assumption is made that the network model has been properly tuned and updated previously).

The data assimilation algorithm might also quality control and process (clean, average, validate, aggregate) the data points that come from the sensors.

In oil and gas companies, the numerical model is typically built in canned commercial software; thus, the user does not have access to the code details or the underlying equations. However, this software (e.g., Schlumberger Ltd 2012) usually has functionality to interact with the network model from other computational routines using automation (e.g., activate and deactivate elements, modify input, run the model and read output). Some applications of this functionality are presented in Rodriguez et al. (2007) (software integration), Liley and Oakley (2007) (automation), Edih et al. (2016) (automatic model population and calibration).

The method described in the present paper computes all possible fluid routing configurations using the graph of the production system. The details of the method are provided in the following sections. The list of all possible routing configurations of a production network could be employed for many useful applications, e.g., identify most convenient routing configurations, evaluating abandoning or drilling wells, decommissioning or installation of separators or pipes, and detect flow problems in the network. A filter could be also applied to the list according to pre-specified criteria to facilitate further analysis of the network (e.g., a specific edge has to be open all the time and remove alternatives where a specific flowline is being used).

A field case has been created to test the method. A computational model in commercial software was manipulated through automation: The connectivity list between elements has been extracted from the model, all routing configurations have been computed, and they have been applied and converged on the computational model.

Description of the method

As with any network-type structure, a convenient way to represent a production network is by employing a graph (Sung et al. 1998). A graph (G) consists in a collection of nodes (V) and edges (E) that are interconnected to a certain degree. In the present work, equipment (wells, separators, junctions, manifolds, pumps, compressors, valves, etc.) is tagged as nodes and pipes (flowlines, connectors) are tagged as edges. The nodes are further classified by type: sources (wells where fluid is entering into the network), internals or sinks (separators, where fluids are leaving the network).

Figure 4a depicts a system of two wells, two flowlines, a junction and a separator. Figure 4b shows a node–edge depiction of the graph, and Fig. 4c shows a list storing the graph information: the name of edges and associated nodes. In computational models, usually each edge and each node have a name assigned beforehand by the modeler.

Fig. 4
figure 4

Reduction in a simple production network (a) to a graph (b), defined with the list (c)

Production systems are converging (commingling) networks of material streams that often resemble a tree (Fig. 5a). The production of individual wells that are relatively close to each other is comingled in a cluster manifold, and the production from the manifolds is often comingled in pipeline junctions and so forth. Very often, there is connectivity (flowlines) between wells and more than one manifold, between junctions and more than one separator, etc. (as shown in Fig. 5b). This additional connectivity is what allows to have different routing options in the production network.

Fig. 5
figure 5

Structure of a production network. No routing options (a). With routing options (b)

The direction of the flow in the network (i.e., in each edge) is given by the solution of the numerical model (after solving the system of equations). However, in some flowlines (typically those connected directly to the wells) there are sometimes non-return valves (check valves) or certain type of equipment (e.g., pumps or compressors) that allow only one preferential flow direction (from the well). This is reason why the graph is both directed and undirected. In the present work, all pipes or connectors coming out of wells have an outwards preferential direction. Similarly, all pipes or connectors coming into a separator have an inwards preferential direction.

Ideally, in a well-designed and hydraulically balanced network, the flow should go smoothly from wells to separators without any cyclic circulation. However, on some occasions, and especially when comingling production from two or more streams with different productivity, there might be back flow in some segments (e.g., from junctions to manifolds in Fig. 5b). In order to keep generality, the graphs are treated as mixed in the present work and with the possibility to have cycles or not. However, in most real-life cases, the graph of the production system will most likely be acyclic, directed and with a tree-like structure.

The method is summarized in the following steps:

  1. 1.

    Extract the adjacency list between elements from the numerical model of the production network.

Extract a list with all elements in the network (name, type and upstream element and downstream element, if a pipe or connector) and separate them in edges and nodes. The node list is ordered alphanumerically, and each node is numbered sequentially. The same is done for the edge list.

Each node is tagged either as a source, internal or sink, and each edge is checked for preferential flow directions.

Please note that the numerical model should include all elements of interest to analyze (i.e., current active and inactive pipes).

  1. 2.

    Compute all feasible connectivity configurations of the production network.

For each source node, a depth-first search is used to find all paths that lead to a sink. This search honors pre-specified edge directions. The result of this first step is a list of paths for each node, where each path is represented by its active edges. This is illustrated in the example below. Note that each source/sink pair may be connected by several paths.

A graph may have disjoint components, i.e., components of the graph which are not in any way connected. For such flow networks, the configuration of one component does not affect the result for other components. The network is therefore also split into its disjoint components in this first step, and each such component is treated independently in the rest of the procedure. To find the disjoint components, each node is initially assigned to a unique component. Then, whenever the recursive path search traverses an edge in the graph, the components of the nodes incident to that edge are joined into one. A disjoint set is used to keep track of the components.

The second step, again for each source, is to find all feasible combinations of its paths, i.e., all edge configurations where the source produces to at least one sink and where no unnecessary edges are active. This is computed by considering all subsets of the path list, of size at least one, combining their edge states through a logical OR operation.

Finally, the third step is to combine the above edge configurations for all of the sources in each disjoint component. Each combination uses one configuration for each source, again with a logical OR operation. The result is a list of configurations for each component of the graph, and these are printed to a file for later use.

Simple example

A simple example is shown in Fig. 6, with two source nodes (1 and 2) and two sink nodes (5 and 6). The first step is illustrated in the table on the right, which shows the result of the depth-first search presenting the status of all edges for all feasible paths. Paths are saved in a matrix where each column corresponds to an edge and each row is a path. A number 1 indicates that the edge is active while 0 indicates that the edge is inactive.

Fig. 6
figure 6

Sample production network and output of the depth-first search (edge connectivity)

The second step is the computation of path combinations for each node. For the example shown above, the total path combinations for source 1 are given in Table 1. These consist of one or both of the paths for source 1.

Table 1 Total path combination for source 1 to the sinks

The third step is the combination over all source nodes, illustrated in Fig. 7. Here, each path combination for Well 1 is combined with each path combination for Well 2 to form a total of nine unique configurations.

Fig. 7
figure 7

Example of combination of paths between two sources

Computational implementation

To avoid redundant computations, the memoization technique is used in the third step described above. This ensures that each combination is generated only once, and the computational cost of the procedure is therefore proportional to the number of combinations generated. Thus, the cost of evaluating each of the combinations is guaranteed to dominate the cost of generating them, and this cost is the limiting factor for the method.

Example case: typical production system of a North Sea field with seven wells

As an application example, the method has been tested in the production network presented in Fig. 8. The system represents a typical production system of a North Sea subsea field where each well has the option to produce to two separators (by opening or closing the valves indicated in the figure). Wells are located in templates that have two manifolds. The number of combinations to evaluate is three (producing to Separator 1, producing to Separator 2, or to both) to the power of 7 (number of wells) 37 = 2187 combinations.

Fig. 8
figure 8

Layout of the production network to analyze

The details of the system are provided in “Appendix 1” for potential verification and benchmarking with other models and programs. The numerical model was built in a commercial simulator (Schlumberger Ltd 2012). Please note that the characteristics (e.g., length, diameter) of the pipes between well–template, template–riser base, riser base–platform have been assumed equal for the four branches. This might cause that some configurations are equivalent due to symmetry, thus giving exactly the same model result. Potential symmetry in the network is, in general, not typical in production systems. For that reason, the possible reduction in the number of cases considering symmetry is not addressed in the present paper.

The computational workflow has been implemented in a commercial software for integrated asset modeling and optimization (Petrostreamz 2013). The first part is depicted in Fig. 9. A script extracts the edge adjacency list from the numerical model of the network (using the automation feature (Schlumberger Ltd 2012) of the black box model) and writes it to a text file. The text file is then used as an input to an .exe file where all routing configurations are computed and written to an output text file. The file contains edge status (0 and 1) organized in columns for each configuration (rows).

Fig. 9
figure 9

Computational workflow implemented to compute all routing configurations where N is total number of configurations and M is total number of edges

The second part of the workflow (shown in Fig. 10) applies each routing configuration sequentially to the numerical model and runs it (using the automation feature (Schlumberger Ltd 2012), and activating and deactivating flowlines) to compute the main parameters of interest (e.g., oil rate, gas rate, water rate). The results are stored for each routing configuration.

Fig. 10
figure 10

Computational workflow implemented to apply to model each routing configuration

Results

All 2187 routing configurations were applied and tested in the numerical model of the production network. The compound run time (that comprises applying the routing configuration in the network model and running it, for all cases) was around 3000 s in a personal portable computing unit (Intel Core i7-4500 CPU). The total water rate is plotted versus the oil rate in Fig. 11 for all cases. The total gas rate is plotted versus the oil rate in Fig. 12 for all cases. A red dot depicts the production of the system for an “intuitive” routing configuration where Wells 1–4 are produced to Separator 1 and Wells 5–7 to Separator 2. This intuitive configuration yields the smallest field oil rate and a very low field gas rate.

Fig. 11
figure 11

Total water production versus oil production for all routing configurations analyzed

Fig. 12
figure 12

Total gas production versus oil production for all routing configurations analyzed

From Figs. 11 and 12, it is possible to observe that an increase in oil production correlates roughly with an increase in gas and water. Some data points of the figures have been bounded by boxes with a tag depicting the percentage of the number of points enclosed by the box when compared the total number of routing configurations analyzed. It is possible to observe that there are not many routing configurations (14%) that yield an oil production close (within 10%) to the maximum (2204 Sm3/d). For the gas, however, there is a significant amount of cases (79%) that yield a production relatively close (within 8%) to the maximum gas flow rate detected (15,178 Sm3/d).

The maximum oil production detected was 2204 Sm3/d, with an associated gas production of 13,617 and 607 Sm3/d of water. The routing configuration that provides these rates is shown in Fig. 13. A red “X” has been placed on the valves that are closed. Please note that due to symmetry, there are 4 equivalent routing configurations that yield the same oil production.

Fig. 13
figure 13

Routing configuration detected that yields maximum oil production

The maximum gas production detected was 15,178 Sm3/d, with an associated oil production of 2133 and 664 Sm3/d of water. The routing configuration that provides these rates is shown in Fig. 14. A red “X” has been placed on the valves that are closed. Please note that due to symmetry, there are two equivalent routing configurations that yield maximum gas production.

Fig. 14
figure 14

Routing configuration detected that yields maximum gas production

Conclusions

The proposed method is a robust and flexible technique to compute all possible routing operating configurations of a production network in a variety of situations that are typically encountered during the life of a petroleum asset.

The method is suitable if a minimally invasive computational implementation is desired and it exploits existing functionality on software used to model hydrocarbon production systems.

Once the connectivity and node list are extracted from the numerical model, the computation of all possible routing operating configurations does not depend at all on any interaction with the model of the production network. This gives the possibility to improve the computational code as much as desired, without depending on the black box simulator. Due to the tree-like structure of the network, and for systems with a small number of wells, there are usually not a large number of combinations to compute; hence, the method should be relatively fast for most cases.

A post-filtering on the list of routing configurations allows to discard operational conditions that are not allowed due to operational directives. They do not have to be hard-coded in the program that computes all possible routing configurations.

The potential of the method has been demonstrated using a sample production network. The best routing configuration to produce maximum oil and gas was detected successfully. For the particular case, there are not many (14%) routing configurations that yield oil rates close (within 10%) to the maximum detected.