**TECHNICAL SCIENCES**

**Авторы:**

**Тип:**

**Опубликовано:**

**Классификаторы:**

**Язык материала:**

**Ключевые слова:**

**Аннотация (русский):**

Mathematical modeling is widely used in the oil and gas industry, because allows to carry out research of objects and processes without carrying out field experiments. Due to the complexity, explosion and fire hazard of such processes as primary oil preparation, as well as the lack of information on technological parameters, the use of analytical methods for their study is difficult. Therefore, the optimal, and often the only possible way to study them is the construction of simulation models (SM). Simulation modeling of objects of the process under consideration is a complex task, the success of which depends on the methodology used. The article discusses the methodology for constructing an SM multiply connected system using the example of one of the components of the primary oil treatment unit - a furnace for heating the borehole fluid.

**Ключевые слова:**

mathematical modeling, simulation model, difference equations, hierarchy analysis method, oil heating furnace

**Introduction**

In the oil and gas industry, almost all objects and technological processes are fire and explosive, therefore it is not possible to conduct any research directly on them. For these purposes, various mathematical models are used, in particular, simulation modeling (SM), since the use of analytical methods most often turns out to be difficult or impossible due to the high degree of complexity of these systems in terms of structure, functioning, choice of behavior and development.

A system of simulation modeling (SIM) is understood as a set of software tools for creating a simulation model and its simulation (imitation) [1]. Today, there are a large number of different simulation programs with their own unique languages (DYNAMO, GPSS, SLAM, SIMULA, SIMSCRIPT, Petri nets, etc.), which have significant differences only in the area of the graphical interface.

Regardless of the approach chosen, the most important factors in the development of simulation models are the correct task, the correctness of the initial data and the adequacy of the model, which largely depends on the identification method used to determine the parameters of the model based on experimental data.

**Purpose of the study** – development of a methodology for constructing a hierarchical simulation model of a multiply connected system using the example of individual blocks of a primary oil treatment plant (furnace for heating crude oil), which can later be used in a training simulator.

**Materials and methods**

The concept of a mathematical model does not have a strict formal definition [2]. In particular, in [3], a mathematical model is understood as any operator A, which allows setting the output values of the parameters Y of the simulation object based on the corresponding values of the input parameters X. The main requirement for any model is the most adequate reflection of the properties of the modeled object and its relationship with the outside world.

A mathematical model, like any other model, is always only a copy of an object and describes it approximately.

Compared to a natural experiment, the mathematical model (MM) has a number of advantages, in particular, the ability to implement modes that are dangerous or difficult to reproduce in reality, changing the time scale and making forecasts based on multifaceted analysis and identifying general patterns [4]. Also, without MM, it is impossible to implement predictive analytics, the importance of which is constantly growing in the industry.

The development of a simulation model consists in the sequential compilation of models of four levels: conceptual, topological, structural and parametric (fig. 1), each of which solves its own problem.

A conceptual or meaningful model is a description of the object of modeling in verbal form, which provides information about the nature and parameters (characteristics) of elementary phenomena of the object under study, about the type and degree of interaction between them, about the place and meaning of each elementary phenomenon in the overall process of functioning of the object. The conceptual model must be stratified, i.e. divided into separate parts that interact with each other and thus ensure the integrity of the entire object.

Fig. 1. Stages of simulation

This interconnection of individual parts is described at the next, topological level. It is at this topological level that causal relationships between input and output parameters are determined. The model is a directed graph, where the vertices correspond to the input and output parameters, and the arcs correspond to the connections between them.

At the structural level, the relationships between input and output parameters are described in the form of mathematical expressions using algebraic operators. A typical structural model is a system of equations that describe either electrical, thermal, mechanical processes, or information transformation processes.

At the last, fourth level, parametric modeling is carried out, during which various options for the functioning of the object are simulated, depending on the specified parameters of the model elements and the relationships between these parameters.

To determine the parameters of models on the basis of experimental data, a large number of identification methods have been developed [5]. From the point of view of the purpose of this study, of interest are methods that are not demanding on RAM and that allow to analyze data on-line, as well as using difference equations, which are most easily implemented on most industrial microprocessor controllers, as well as in software packages of mathematical modeling.

In this study, it is proposed to use the method of analysis of hierarchies (MAH) at the parametric level, which is one of the rather formalized and classical methods of system analysis used to solve the problem of decision making in conditions of multicriteria [6].

The method is implemented in the following sequence: first, a hierarchical decomposition of the problem into separate tasks is carried out in such a way as to make it easier for a person (an expert) to make decisions for individual tasks based on paired, rather than multi-criteria comparisons, and then priorities are synthesized by mathematical methods.

When choosing the values of the model parameters, the developer faces a similar problem, which consists in obtaining a balanced set of parameters by multiple comparisons of the available parameter values in different modes. The technology underlying the hierarchy analysis method will allow replacing the need for simultaneous comparison of multiple parameters with pairwise comparisons.

To build a simulation model according to the described method, a crude oil heating furnace was used as an example, which is one of the main elements of a primary oil treatment unit in the field.

The technology of primary oil separation consists in heating it to a predetermined temperature in a furnace (fig. 2) and then separating it into three fractions in a separator: oil, gas and water.

Heating of the initial oil and gas mixture, which is supplied through pipeline 5 from an automated group metering unit (AGMU), is carried out in furnace 1 due to the heat of burners 3, in which gaseous fuel mixed with air is burned, supplied through the corresponding pipelines 2 and 4 [7].

Fig. 2. Oil heating process

**Results and discussion**

The block diagram of the P-1 furnace as an object of research can be represented as shown in fig. 3.

Fig. 3. Conditional representation of the furnace as an object of research

The letters in fig. 3 denote the so-called concepts - input and output quantities, which the created model must in a certain way relate to each other: T_{1} – inlet oil temperature in P-1; T_{2} – oil temperature after heating in P-1; T_{3} – flue gas pass temperature in P-1; S_{1} – operation of the first blower; S_{2} – second blower operation; F_{1} – oil flow rate at the inlet in P-1; F_{2} – gas flow rate on burners in P-1; P_{1} – gas pressure on burners in P-1; V_{1} – position of the gas supply valve to the burners in P-1.

Then the conceptual model of the furnace primitive will have the form shown in fig. 4.

Fig. 4. Conceptual model of the furnace

At the next level, a topological model of the furnace is drawn up. At the topological level, causal relationships between input and output parameters are determined. Such a model is a directed graph (fig. 5), in which the vertices correspond to the input and output parameters, and the arcs correspond to the connections between them.

At the structural level, connections between input and output parameters are described in the form of mathematical expressions using algebraic operators:

(1)

where W1 and W2 are aperiodic links of the first order.

Fig. 5. Topological model of the furnace

After conversion to the difference form, we get the recurrent formula:

* *(2)

To use the method of analyzing hierarchies, it is necessary to transform the expression by introducing new variables