Method and device for determining wax precipitation amount in oil and gas conveying process
By performing multi-phase flash calculation on oil and gas transport fluid, combined with gas-liquid state equation and solid phase activity model, the problem of insufficient prediction accuracy of the liquid-solid phase boundary convergence and high pressure is solved, and the precise prediction and calculation robustness of wax precipitation content is achieved.
Patent Information
- Application Number
- CN202510623908.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-15
- Publication Date
- 2025-08-01
AI Technical Summary
The prior art has poor convergence of the liquid-solid phase boundary during oil and gas transportation, and the prediction accuracy of wax analysis volume under high pressure is not high and the robustness is insufficient.
By conducting a single-phase stability test on the conveying fluid, if it is stable, a wax-containing one-phase stability test is carried out, and if it is unstable, a wax-containing two-phase flash calculation is carried out until the amount of wax is determined, and the calculation accuracy and robustness are improved using the gas-liquid phase state equation and solid phase activity model.
It accurately predicts the changes in wax precipitation content under pressure conditions, improves the convergence and robustness of the calculation, improves the prediction accuracy of wax precipitation amount and the application scope of the model.
Smart Images

Figure CN120405096A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of fluid phase analysis, particularly to the field of fluid phase analysis technology during oil and gas transportation, and specifically relates to a method and device for determining the wax precipitation amount during oil and gas transportation. Background Art
[0002] During oil and gas transportation, when the temperature of the oil and gas pipeline drops below the wax precipitation temperature, solid deposits will form on the pipe wall. To prevent safety hazards caused by wax deposit blockage, it is necessary to determine the starting conditions and deposition amount of wax deposition.
[0003] Currently, with the development of wax precipitation thermodynamics, numerous activity models describing the wax phase have been proposed. Combining with the gas-liquid phase state equation, the prediction accuracy of the wax precipitation temperature and wax precipitation amount under normal pressure has been greatly improved. However, there are still the following key problems to be solved in the existing wax precipitation prediction methods:
[0004] (1) Poor convergence of the liquid-solid phase boundary: As the temperature rises, the solid phase in the system gradually disappears, and the existing flash calculation model does not describe this process continuously enough, and even the Newton-Raphson method may diverge.
[0005] (2) Low prediction robustness: Existing methods are mostly used to calculate a limited number of experimental conditions, and the calculated conditions cannot cover the engineering condition range, and the prediction accuracy under high pressure is not high. Summary of the Invention
[0006] A method and device for determining the wax precipitation amount during oil and gas transportation provided by this application aim to overcome the above technical pain points in the prior art, so as to accurately predict the change of wax precipitation content with temperature during oil and gas transportation, especially under pressurized conditions, and improve the calculation robustness.
[0007] To achieve the above object, in the first aspect, this application provides a method for determining the wax precipitation amount during oil and gas transportation, including:
[0008] Conduct a single-phase stability test on the transported fluid to generate a single-phase stability test result;
[0009] If the system corresponding to the single-phase stability test result is stable, conduct a single-wax-phase stability test on the single-phase stability test result;
[0010] If the system corresponding to the single-wax-phase stability test result is unstable, conduct a two-phase flash calculation of the single-wax-phase to determine the first wax precipitation amount;
[0011] If the system corresponding to the single-phase stability test result is unstable, conduct a gas-liquid two-phase flash calculation on the single-phase stability test result, and conduct a two-phase stability test of the single-wax-phase on the gas-liquid two-phase flash calculation result;
[0012] When the system corresponding to the wax-containing two-phase stability test result is unstable, perform a gas-liquid-wax three-phase flash calculation on the wax-containing two-phase stability test result to determine the second wax precipitation amount.
[0013] In some embodiments of the present invention, the performing a single-phase stability test on the transported fluid includes:
[0014] Determine the mole fraction of the transported fluid;
[0015] According to the mole fraction and a preset gas-liquid equilibrium constant, determine the component content of the first test phase for each preset pressure point and temperature point; wherein, the first test phase is the phase where the transported fluid is located.
[0016] In some embodiments of the present invention, the step of determining whether the system corresponding to the single-phase stability test result is stable includes:
[0017] When the single-phase stability test result converges, determine whether the system corresponding to the single-phase stability test result is stable, and the system corresponding to the single-phase stability test result includes a first test phase and the first test phase.
[0018] In some embodiments of the present invention, performing a wax-containing single-phase stability test on the single-phase stability test result includes:
[0019] Determine a second test phase according to the phase where the transported fluid is located in the single-phase stability test result;
[0020] According to the second test phase and a preset liquid-solid equilibrium constant, determine the component content of the second test phase for each preset pressure point and temperature point.
[0021] In some embodiments of the present invention, the step of determining whether the system corresponding to the wax-containing single-phase stability test result is stable includes:
[0022] When the wax-containing single-phase stability test result converges, determine whether the system corresponding to the wax-containing single-phase stability test result is stable, and the system corresponding to the wax-containing single-phase stability test result includes a second test phase and the second test phase.
[0023] In some embodiments of the present invention, performing a wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result includes:
[0024] Determine a third test phase according to the liquid phase in the gas-liquid two-phase flash calculation result;
[0025] According to the third test phase and a preset liquid-solid equilibrium constant, determine the component content of the third test phase for each preset pressure point and temperature point.
[0026] In some embodiments of the present invention, the step of determining whether the system corresponding to the wax-containing two-phase stability test result is stable includes:
[0027] When the wax-containing two-phase stability test result converges, determine whether the system corresponding to the wax-containing two-phase stability test result is stable. The system corresponding to the wax-containing two-phase stability test result includes a third test phase and the third test phase.
[0028] In a second aspect, the present application provides a device for determining the wax precipitation amount during oil and gas transportation. The device includes:
[0029] A single-phase stability test module for performing a single-phase stability test on the transported fluid to generate a single-phase stability test result;
[0030] A wax-containing single-phase stability test module for performing a wax-containing single-phase stability test on the single-phase stability test result when the system corresponding to the single-phase stability test result is stable;
[0031] A gas-liquid two-phase flash calculation first module for performing a wax-containing two-phase flash calculation on the wax-containing single-phase stability test result to determine the first wax precipitation amount when the system corresponding to the wax-containing single-phase stability test result is unstable;
[0032] A gas-liquid two-phase flash calculation second module for performing a gas-liquid two-phase flash calculation on the single-phase stability test result when the system corresponding to the single-phase stability test result is unstable, and performing a wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result;
[0033] A gas-liquid-wax three-phase flash calculation module for performing a gas-liquid-wax three-phase flash calculation on the wax-containing two-phase stability test result to determine the second wax precipitation amount when the system corresponding to the wax-containing two-phase stability test result is unstable.
[0034] In some embodiments of the present invention, the single-phase stability test module includes:
[0035] A mole fraction determination unit for determining the mole fraction of the transported fluid;
[0036] A component content determination unit of the first test phase for determining the component content of the first test phase for each preset pressure point and temperature point according to the mole fraction and a preset gas-liquid equilibrium constant; wherein, the first test phase is the phase where the transported fluid is located.
[0037] In some embodiments of the present invention, a device for determining the wax precipitation amount during oil and gas transportation further includes:
[0038] The first system stability judgment module is used to judge whether the system corresponding to the single-phase stability test result is stable; the first system stability judgment module includes:
[0039] The first system stability judgment unit is used to judge whether the system corresponding to the single-phase stability test result is stable when the single-phase stability test result converges. The system corresponding to the single-phase stability test result includes the first test phase and the first test phase.
[0040] In some embodiments of the present invention, the wax-containing single-phase stability test module includes:
[0041] The second test phase determination unit is used to determine the second test phase according to the phase where the transported fluid is located in the single-phase stability test result;
[0042] The component content determination unit of the second test phase is used to determine the component content of the second test phase for each preset pressure point and temperature point according to the second test phase and the preset liquid-solid equilibrium constant.
[0043] In some embodiments of the present invention, a device for determining the wax precipitation amount during oil and gas transportation further includes: [[ID=IS=17]]
[0044] The second system stability judgment module is used to judge whether the system corresponding to the wax-containing single-phase stability test result is stable; the second system stability judgment module includes:
[0045] The second system stability judgment unit is used to judge whether the system corresponding to the wax-containing single-phase stability test result is stable when the wax-containing single-phase stability test result converges. The system corresponding to the wax-containing single-phase stability test result includes the second test phase and the second test phase.
[0046] In some embodiments of the present invention, the second gas-liquid two-phase flash calculation module includes:
[0047] The third test phase determination unit is used to determine the third test phase according to the liquid phase in the gas-liquid two-phase flash calculation result;
[0048] The component content determination unit of the third test phase is used to determine the component content of the third test phase for each preset pressure point and temperature point according to the third test phase and the preset liquid-solid equilibrium constant.
[0049] In some embodiments of the present invention, a device for determining the wax precipitation amount during oil and gas transportation further includes:
[0050] The third system stability judgment module is used to judge whether the system corresponding to the wax-containing two-phase stability test result is stable. The third system stability judgment module includes:
[0051] A third system stability determination unit, configured to determine whether the system corresponding to the wax-containing two-phase stability test result is stable if the wax-containing two-phase stability test result converges. The system corresponding to the wax-containing two-phase stability test result includes a third test phase and the third test phase.
[0052] In a third aspect, the present application provides a computer program product, including a computer program / instructions, which when executed by a processor, implement the steps of a method for determining the wax precipitation amount during oil and gas transportation.
[0053] In a fourth aspect, the present application provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, it implements the steps of a method for determining the wax precipitation amount during oil and gas transportation.
[0054] In a fifth aspect, the present application provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements the steps of a method for determining the wax precipitation amount during oil and gas transportation.
[0055] As can be seen from the above description, the embodiments of the present application provide a method and device for determining the wax precipitation amount during oil and gas transportation. The corresponding method includes: first, performing a single-phase stability test on the transported fluid to generate a single-phase stability test result; then, if the system corresponding to the single-phase stability test result is stable, performing a wax-containing single-phase stability test on the single-phase stability test result; if the system corresponding to the wax-containing single-phase stability test result is unstable, performing a wax-containing two-phase flash calculation on the wax-containing single-phase stability test result to determine the first wax precipitation amount; if the system corresponding to the single-phase stability test result is unstable, performing a gas-liquid two-phase flash calculation on the single-phase stability test result, and performing a wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result; finally, if the system corresponding to the wax-containing two-phase stability test result is unstable, performing a gas-liquid-wax three-phase flash calculation on the wax-containing two-phase stability test result to determine the second wax precipitation amount.
[0056] The present invention can accurately predict the change of the wax precipitation content with temperature under a pressurized condition during oil and gas transportation, and improve the calculation robustness. BRIEF DESCRIPTION OF THE DRAWINGS
[0057] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings required for the description of the embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0058] Figure 1Flow schematic of a method for determining the wax precipitation amount during oil and gas transportation provided in an embodiment of the present application Figure 1 ;
[0059] Figure 2 Flow schematic diagram of step 100 of a method for determining the wax precipitation amount during oil and gas transportation provided in an embodiment of the present application;
[0060] Figure 3 Flow schematic of a method for determining the wax precipitation amount during oil and gas transportation provided in an embodiment of the present application Figure 2 ;
[0061] Figure 4 Flow schematic diagram of step 200 of a method for determining the wax precipitation amount during oil and gas transportation provided in an embodiment of the present application;
[0062] Figure 5 Flow schematic of a method for determining the wax precipitation amount during oil and gas transportation provided in an embodiment of the present application Figure 3 ;
[0063] Figure 6 Flow schematic diagram of step 400 of a method for determining the wax precipitation amount during oil and gas transportation provided in an embodiment of the present application;
[0064] Figure 7 Flow schematic of a method for determining the wax precipitation amount during oil and gas transportation provided in an embodiment of the present application Figure 4 ;
[0065] Figure 8 Flow schematic diagram of a method for determining the wax precipitation amount during oil and gas transportation provided in a specific application example of the present application;
[0066] Figure 9 Mind map of a method for determining the wax precipitation amount during oil and gas transportation provided in a specific application example of the present application;
[0067] Figure 10 Flow schematic diagram of wax-containing multiphase flash calculation provided in a specific application example of the present application;
[0068] Figure 11 Flow schematic diagram of wax-containing stability test calculation provided in a specific application example of the present application;
[0069] Figure 12 Schematic diagram of comparison between predicted wax precipitation curve results and experimental data by different methods in a specific application example of the present application (mixture A);
[0070] Figure 13 Schematic diagram of comparison between predicted wax precipitation curve results and experimental data by different methods in a specific application example of the present application (mixture B);
[0071] Figure 14 Schematic diagram of the comparison between the results of predicting the paraffin precipitation curve by different methods and the experimental data provided in the specific application examples of this application (mixture C);
[0072] Figure 15 Schematic diagram of the comparison between the results of predicting the paraffin precipitation curve by different methods and the experimental data provided in the specific application examples of this application (mixture D);
[0073] Figure 16 Schematic diagram of the comparison between the results of predicting the paraffin precipitation amount by different methods under high pressure and the experimental data provided in the specific application examples of this application;
[0074] Figure 17 Schematic diagram of the structure of a device for determining the paraffin precipitation amount during oil and gas transportation provided in the specific application examples of this application;
[0075] Figure 18 Schematic diagram of the structure of the electronic device in the embodiment of this application. Detailed implementation manners
[0076] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of this application. Obviously, the described embodiments are some, but not all, of the embodiments of this application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in this application without creative efforts shall fall within the scope of protection of this application.
[0077] Those skilled in the art should understand that the embodiments of this application can be provided as a method, a system, or a computer program product. Therefore, this application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, this application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0078] It should be noted that the terms "including" and "having" in the specification and claims of this application and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or are inherent to these processes, methods, products, or devices.
[0079] It should be noted that, without conflict, the embodiments in the present application and the features in the embodiments may be combined with each other. The following will describe the present application in detail with reference to the drawings and in combination with the embodiments.
[0080] An embodiment of the present application provides a specific implementation manner of a method for determining the wax precipitation amount during oil and gas transportation. Refer to Figure 1 , and the method specifically includes the following contents:
[0081] Step 100: Conduct a single-phase stability test on the transported fluid to generate a single-phase stability test result;
[0082] Step 200: If the system corresponding to the single-phase stability test result is stable, conduct a stability test on the wax-containing single phase of the single-phase stability test result;
[0083] Step 300: If the system corresponding to the wax-containing single-phase stability test result is unstable, conduct a wax-containing two-phase flash calculation on the wax-containing single-phase stability test result to determine the first wax precipitation amount;
[0084] Step 400: If the system corresponding to the single-phase stability test result is unstable, conduct a gas-liquid two-phase flash calculation on the single-phase stability test result, and conduct a wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result;
[0085] Step 500: If the system corresponding to the wax-containing two-phase stability test result is unstable, conduct a gas-liquid-wax three-phase flash calculation on the wax-containing two-phase stability test result to determine the second wax precipitation amount.
[0086] Regarding step 100, stability analysis refers to judging whether the current system is stable, whether gas, liquid or solid phases will be generated under given pressure and temperature, so as to determine whether to perform flash calculation. The single-phase stability test (also called single-phase stability analysis) in step 100 is used to test the stability of the single-phase system and judge whether new phases need to be generated to make the Gibbs free energy of the system tend to be the minimum.
[0087] Furthermore, stability analysis includes single-phase stability analysis and two-phase stability analysis. According to the principle of minimum Gibbs free energy, the stability of a given fluid component system under fixed pressure and temperature can be tested. If the test result shows that the system is unstable, the system can generate new phases to make the system tend to the state of minimum Gibbs free energy; if the test result shows that the system is stable, the system is stable enough and does not generate new phases. The fluid phase being tested is called the test phase, and the new phase obtained through equilibrium constant calculation is called the test phase, which can provide an initial value for stability analysis.
[0088] For the wax-containing two-phase flash calculation in step 300, the gas-liquid two-phase flash calculation in step 400, and the gas-liquid-wax three-phase flash calculation in step 500, the flash calculation means calculating the phase type of each phase and the content of each phase at a given pressure and temperature; specifically:
[0089] Gas-liquid two-phase flash calculation: That is, the flash calculation of the gas phase and the liquid phase (oil phase).
[0090] The wax-containing flash calculation includes liquid-wax flash calculation and gas-wax flash calculation. The calculation process of the gas-liquid two-phase flash is the same as that of the wax-containing flash calculation, but there are differences in the composition of the two phases and the corresponding fugacity calculation methods (the fugacities of the gas and liquid phases are calculated by the PR equation of state; the fugacity of the wax phase is calculated by the Wilson activity model combined with the Poynting factor). The initial equilibrium constant for the calculation is provided by the single-phase stability test result in step 100.
[0091] Gas-liquid-wax three-phase flash calculation: That is, the flash calculation of the gas phase, the liquid phase, and the wax phase. The initial value of the equilibrium constant required for the calculation is provided by the two-phase stability test result in step 400.
[0092] In addition, for the wax-containing two-phase stability test in step 400, the two-phase stability analysis is used to check the stability of the two-phase equilibrium system and determine whether new phases need to be generated to minimize the Gibbs free energy of the system.
[0093] In some embodiments of the present invention, referring to Figure 2 , the single-phase stability test on the transported fluid in step 100 includes:
[0094] Step 101: Determine the mole fraction of the transported fluid;
[0095] Step 102: Determine the component content of the first test phase for each preset pressure point and temperature point according to the mole fraction and the preset gas-liquid equilibrium constant; wherein, the first test phase is the phase where the transported fluid is located.
[0096] Specifically, under the given pressure p and temperature T conditions, the phase where the transported fluid component n i is located is regarded as the test phase, and the gas-liquid equilibrium constant {K i VL , 1 / K i VL} obtained by using the gas-liquid equilibrium constant correlation formula (Equation 1) is used to calculate the test phase composition, and this composition is used as the initial value for the iterative calculation of the single-phase stability test.
[0097]
[0098] In the formula: K i VLVapor-liquid equilibrium constant; P is the system pressure, kPa; T is the system temperature, K; P ci is the critical pressure of component i, kPa; T ci is the critical temperature of component i, K; ω i is the acentric factor of component i.
[0099] In some embodiments of the present invention, referring to Figure 3 , a method for determining the wax precipitation amount during oil and gas transportation further includes:
[0100] Step 600: Determine whether the system corresponding to the single-phase stability test result is stable; further, step 600 includes:
[0101] When the single-phase stability test result converges, determine whether the system corresponding to the single-phase stability test result is stable. The system corresponding to the single-phase stability test result includes a first test phase and the first test phase.
[0102] Perform a single-phase stability test. After the single-phase stability test result converges, determine whether the system composed of the current test phase and the test phase is stable.
[0103] In some embodiments of the present invention, referring to Figure 4 , perform a wax-containing single-phase stability test on the single-phase stability test result in step 200, including:
[0104] Step 201: Determine a second test phase according to the phase where the transported fluid is located in the single-phase stability test result;
[0105] Step 202: Determine the component content of the second test phase for each preset pressure point and temperature point according to the second test phase and the preset liquid-solid equilibrium constant.
[0106] In steps 201 and 202, perform a wax-containing single-phase stability test (wax-containing single-phase stability analysis) to detect whether the current wax phase will be generated. Consider the phase where the transported fluid component n i is located as the test phase, and use the liquid-solid equilibrium constant K i WL (the calculation method is shown in formula (2)) to calculate the composition of the test phase, and this composition is used as the initial value for the iterative calculation of the wax-containing single-phase stability test.
[0107] Liquid-solid equilibrium constant K i WL :
[0108]
[0109] In the formula: is the fugacity coefficient of liquid-phase component i, and the conversion relationship with fugacity is shown in formula (3); γW i is the activity coefficient of component i in the wax phase; is the fugacity of component i under normal pressure (0.1 MPa) and temperature T in the system, kPa; is the fugacity of component i in the liquid phase, kPa; κ is the ratio of the molar volume of the wax phase to the liquid volume, taken as 0.9; ΔH f,i and ΔH tr,i are the molar heat of fusion and the enthalpy of solid-solid transformation respectively; ΔC p,i is the difference in constant-pressure heat capacity between solid and liquid; T f,i is the melting temperature of the solid phase; R is the gas constant, 8.314 J / (mol K).
[0110]
[0111] In the formula: x i is the mole fraction of component i.
[0112] In some embodiments of the present invention, referring to Figure 5 , a method for determining the wax precipitation amount during oil and gas transportation further includes:
[0113] Step 700: Determine whether the system corresponding to the wax-containing single-phase stability test result is stable; further, Step 700:
[0114] If the wax-containing single-phase stability test result converges, determine whether the system corresponding to the wax-containing single-phase stability test result is stable. The system corresponding to the wax-containing single-phase stability test result includes the second test phase and the second test phase.
[0115] After iterative convergence, determine whether the current system is stable. If the system is stable, the calculation result is a single phase, and there is no wax precipitation phenomenon at this time; if the current system is unstable, perform a wax-containing two-phase flash calculation, and the wax precipitation amount at this pressure and temperature can be obtained after two-phase equilibrium;
[0116] In some embodiments of the present invention, referring to Figure 6 , the wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result in Step 400 includes:
[0117] Step 401: Determine the third test phase according to the liquid phase in the gas-liquid two-phase flash calculation result;
[0118] Step 402: Determine the component content of the third test phase for each preset pressure point and temperature point according to the third test phase and the preset liquid-solid equilibrium constant.
[0119] Perform the wax-containing two-phase stability test to check whether a wax phase will be generated in the liquid phase of the gas-liquid equilibrium system in the gas-liquid two-phase flash calculation results. Use the liquid phase as the test phase, and the liquid-solid equilibrium constant K i WL The calculated composition is used as the test phase and serves as the initial value for the iterative calculation of the wax-containing two-phase stability test.
[0120] In some embodiments of the present invention, refer to Figure 7 , a method for determining the wax precipitation amount during oil and gas transportation further includes:
[0121] Step 800: Determine whether the system corresponding to the wax-containing two-phase stability test result is stable; further, step 800 includes:
[0122] When the wax-containing two-phase stability test result converges, determine whether the system corresponding to the wax-containing two-phase stability test result is stable. The system corresponding to the wax-containing two-phase stability test result includes the third test phase and the third test phase.
[0123] After the iteration of the wax-containing two-phase stability test converges, determine whether the current system (consisting of the third test phase and the third test phase) is stable. If the system is stable, the calculation result is the gas-liquid equilibrium; if the system is unstable, perform the gas-liquid-wax three-phase flash calculation, and the wax precipitation amount at this pressure and temperature is obtained after the three-phase equilibrium.
[0124] As can be seen from the above description, the embodiments of the present application provide a method for determining the wax precipitation amount during oil and gas transportation. Perform a single-phase stability test on the transported fluid to generate a single-phase stability test result; if the single-phase stability test result shows that the system is stable, perform a wax-containing single-phase stability test (wax-containing one-phase stability test). If the wax-containing single-phase stability test result still shows stability, it means that no wax is precipitated. On the contrary, when the wax-containing single-phase stability test result shows instability, perform a wax-containing two-phase flash calculation to determine the wax precipitation amount; if the single-phase stability test result shows instability, first perform a gas-liquid two-phase flash calculation, then perform a wax-containing two-phase stability analysis. Next, determine whether the two-phase system is stable at this time. If the system is stable, it means that no wax is precipitated and the system is in the gas-liquid two-phase state; if the two-phase system is unstable, perform a gas-liquid-wax three-phase flash calculation to determine the wax precipitation amount.
[0125] Specifically, first, input the mole fractions of the fluid components, as well as the pressure and temperature range values to be calculated. For each determined pressure and temperature value, perform a single-phase stability analysis calculation. Calculate the component content of the test phase based on the initial values, and then use the gas and liquid state equations to provide fugacity parameters for the test phase and the trial phase. After iteration until convergence, determine whether the current system is stable. If the system is stable, it indicates that only the gas phase or the liquid phase appears in the system. It is necessary to further use the wax-containing single-phase stability analysis to check whether there is a wax phase in the system, and then determine whether to perform a wax-containing two-phase flash. If the system shows an unstable result after inspection, it indicates that the system contains both the gas phase and the liquid phase. It is necessary to use the wax-containing two-phase stability analysis again to check whether there is a wax phase in the system, and then determine whether to perform a wax-containing two-phase flash or a three-phase flash calculation. The flash calculation can obtain the phase fraction of wax in the phase equilibrium, which is the wax precipitation amount at the pressure and temperature of the system. Traversing and performing the wax-containing flash calculation for the given pressure and temperature range can obtain the wax precipitation curve under the corresponding working conditions.
[0126] The present invention has the following beneficial effects: Based on the gas-liquid phase stability test, the present invention proposes formula (2) to judge whether there is a wax phase. It can improve the convergence at the phase boundary during the flash calculation, making the phase transition more continuous. In addition, the flash calculation provided by the present invention effectively improves the convergence during the liquid-solid phase transition. Introducing the PR equation of the gas-liquid state equation and the Wilson model of the solid-phase activity model effectively improves the prediction accuracy of the wax precipitation amount.
[0127] To further illustrate the present solution, the present application also provides a specific application example of the method for determining the wax precipitation amount during oil and gas transportation. Refer to Figure 8 and Figure 9 , which specifically includes the following contents.
[0128] S1: Set the fluid components and working conditions.
[0129] Set the fluid components and their corresponding molar contents, and the pressure and temperature working condition points.
[0130] S2: Calculate the wax-containing multiphase flash.
[0131] Specifically, refer to Figure 10 , step S2 includes the following steps:
[0132] Step 1: Under the given pressure p and temperature T conditions, regard the phase where the transported fluid component n i is located as the test phase, and use the equilibrium constant correlation formula (formula 1) of the gas-liquid equilibrium to obtain the equilibrium constants {K i VL , 1 / K i VL}Calculate the composition of the test phase, which serves as the initial value for the iterative calculation of the single-phase stability test; perform the single-phase stability test. After the stability test converges, determine whether the current system formed by the test phase and the experimental phase is stable. If the system is determined to be stable, proceed to step two; if the system is unstable, proceed to step three;
[0133] Step two: Perform the stability test of the wax-containing single phase to detect whether a wax phase will be generated. Consider the phase where the transport fluid component n i is located as the test phase, and the equilibrium constant K i WL Calculate the composition of the test phase, which serves as the initial value for the iterative calculation of the wax-containing single-phase stability test. After the iteration converges, determine whether the current system is stable. If the system is stable, the calculation result is a single phase; if the system is unstable, perform the wax-containing two-phase flash calculation, and obtain the wax precipitation amount at this pressure and temperature after the two-phase equilibrium;
[0134] Step three: Perform the gas-liquid two-phase flash calculation. Proceed to step four;
[0135] Step four: Perform the stability test of the wax-containing two phases to check whether a wax phase will be generated in the liquid phase of the gas-liquid equilibrium system in step three. Consider the liquid phase as the test phase, and use the composition calculated by the liquid-solid equilibrium constant K i WL (obtained from formula (2)) as the experimental phase, which serves as the initial value for the iterative calculation of the wax-containing two-phase stability test. After the iteration converges, determine whether the system is stable. If the system is stable, the calculation result is the gas-liquid phase equilibrium; if the current system is unstable, perform the gas-liquid-wax three-phase flash calculation, and obtain the wax precipitation amount at this pressure and temperature after the three-phase equilibrium.
[0136] The gas-liquid fugacity coefficients in formula (2) are calculated by the PR equation of state:
[0137]
[0138] In the formula: a is the attractive term parameter of the mixed phase; b i is the repulsive term parameter of component i; b is the repulsive term parameter of the mixed phase; A and B are both parameters of the compressibility factor equation, A = aP / RT 2 T 2 , B = bP / RT; a ij is the interaction parameter between component i and component j; Z is the compressibility factor.
[0139] The fugacity of the wax phase is calculated by combining the Wilson activity model with the Poynting factor, as shown in formula (5).
[0140]
[0141] In the formula: f L pure,i(T, P) is the fugacity of component i under the conditions of pressure p and temperature T, kPa.
[0142] The solid-phase activity coefficient can be calculated by the Wilson activity model, Equation (6).
[0143]
[0144] In the formula: Λ ij is the energy interaction parameter between component i and component j; x j W is the mole fraction of component j in the wax phase.
[0145] In addition, in the stability analysis calculation method, both the single-phase stability test and the wax-containing two-phase stability test follow the calculation process as Figure 11 shown.
[0146] First, calculate the fugacity coefficient of the test phase according to the given PT conditions and the test phase composition, and determine whether the test phase is a wax phase to calculate different test phase compositions. If the test phase is a wax phase, its composition Y i is calculated using Equation (7), and the fugacity coefficient of this phase is calculated by Equation (5).
[0147] Y i = n i K i WL (7)
[0148] If the test phase is not a wax phase, its composition Y i is calculated using Equation (8), and the fugacity coefficient of this phase is calculated by Equation (4).
[0149] Y i = n i K i VL (8)
[0150] Use the successive iteration method to solve Equation (9) to make it satisfy Equation (10), then the stability analysis calculation converges.
[0151] Y i k+1 = exp{[lnn i + lnφ i (n)] - lnφ i (Y k )} (9)
[0152] ||Y k+1 - Y k || < ε (10)
[0153] Finally, equations (11) and (12) are used to check whether the test phase composition is a trivial solution and the stability of the system, respectively.
[0154]
[0155] In the calculation of the stability analysis of the wax-containing two-phase system, the liquid phase in the gas-liquid equilibrium is selected as the test phase.
[0156] As can be seen from the above description, if the test result of the current system shows instability, it is necessary to increase it to two-phase or even three-phase and then perform flash calculation. According to the principle of material conservation, the flash convergence needs to meet the following conditions.
[0157] Phase equilibrium equation:
[0158]
[0159] Component distribution in each phase:
[0160]
[0161] Flash algorithm convergence residual:
[0162]
[0163] In the formula, f i j is the fugacity of component i in phase j, kPa; φ i j is the fugacity coefficient of component i in phase j; e j is the phase fraction of phase j; x i j is the mole fraction of component i in the mixture in phase j; K i j is defined as the ratio of the mole fraction of component i in phase j to the reference phase NP*, that is, the equilibrium constant of phase j and phase NP*; n i is the molar content of the transported fluid component; r is the residual; here, the indices j and l are the phase state sequence indices, NP* is the reference phase, and NP is the total number of phase states.
[0164] Based on equations (13) to (15) and the corresponding descriptions, the gas-liquid two-phase flash calculation and the gas-liquid-wax three-phase flash calculation can be expressed as the following unified iterative process:
[0165] Step A: Obtain the initial value of the equilibrium constant using the stability analysis method;
[0166] Step B: Solve the phase equilibrium equation, that is, equation (13);
[0167] Step C: Update the composition of each phase using equation (14);
[0168] Step D: Calculate the fugacity and fugacity coefficient of each phase component according to the composition of each phase using Equation (4) or (5).
[0169] Step E: Determine whether the fugacities of each phase are equal according to Equation (15). If the convergence condition is met, jump out of the loop to obtain the phase equilibrium result; if not, update the equilibrium constant using the fugacity coefficient, and return to Step B to continue the iterative calculation until the fugacity convergence condition of Equation (15) is satisfied.
[0170] S3: Generate the paraffin precipitation curve under the corresponding working conditions.
[0171] Specifically, the flash calculation can obtain the paraffin phase fraction in the phase equilibrium, which is the paraffin precipitation amount at the pressure and temperature of the system. Traversing and executing the paraffin-containing flash calculation module for a given pressure and temperature range can obtain the paraffin precipitation curve under the corresponding working conditions.
[0172] S4: Verify the prediction effect of the paraffin precipitation amount.
[0173] In order to verify the prediction effect of the prediction method of the present invention compared with other existing prediction methods, the present invention uses experimental data to conduct prediction comparisons on the above method and other prediction methods. The component contents of the four mixtures used in the paraffin precipitation experiment are shown in Table 1.
[0174] Table 1 Component and content of four mixtures
[0175]
[0176]
[0177] Under atmospheric pressure, the paraffin precipitation curve calculation method proposed by the present invention and the methods proposed by Nasrifar, Fleming, etc. in the literature are respectively calculated and compared in terms of the results, as Figures 12 to 15 shown. The mean absolute error is used as the evaluation index, as shown in Equation (16). The absolute deviation between different calculation methods and experimental data is shown in Table 2.
[0178] Mean absolute error (AAD):
[0179]
[0180] In the formula, wt exp is the experimental data of the paraffin precipitation amount; wt cal is the calculated data of the paraffin precipitation amount; N exp is the number of experimental groups.
[0181] Table 2 Errors between the predicted paraffin precipitation amount results of different methods and experimental data
[0182]
[0183] For mixture D, under high-pressure conditions, the calculation results of the wax precipitation amount change in the method of the present invention are as shown in Figure 16 the following. The comparison of the calculation results of different methods with the experimental data is shown in Table 3.
[0184] Table 3 Errors between the predicted wax precipitation amounts by different methods under high pressure and the experimental data
[0185]
[0186]
[0187] As can be seen from the above description, the specific application example of the present application provides a method for determining the wax precipitation amount during oil and gas transportation, which is mainly divided into two steps: fluid component and condition setting and wax-containing flash calculation. By setting the fluid components and their corresponding molar contents, and the pressure and temperature condition points, the wax-containing flash calculation is performed for each condition point to obtain the corresponding phase equilibrium results. Among them, the phase fraction of the wax phase is the wax precipitation amount, and the curve formed by the pressure or temperature and the corresponding wax precipitation amount is the wax precipitation curve. The present invention has the following beneficial effects:
[0188] (1) Higher wax precipitation prediction accuracy.
[0189] The gas-liquid phase is described by the PR equation, and the solid phase is described by the Wilson equation. In the pressure range of 0.1 MPa - 50 MPa and the temperature range of 256 K - 310 K, the wax precipitation amount prediction accuracy of the method of the present invention is higher than the prediction methods in the tested literature. With the modification of the Poynting factor, the prediction trend of the wax precipitation amount change under high pressure is also more reasonable.
[0190] (2) Effectively handle the convergence problem at the phase boundary.
[0191] According to the stability analysis property, it can be judged whether the current condition system is stable, and then whether a new phase is generated. Using this property, the wax-containing multiphase flash algorithm can effectively improve the convergence at the gas / liquid and liquid / wax phase boundaries, making the transition of different phases with the change of pressure and temperature more continuous.
[0192] (3) The model algorithm has strong robustness.
[0193] In the pressure range of 0.1 MPa - 45 MPa and the temperature range of 250 K - 550 K, after more than 300,000 wax-containing multiphase flash calculations, each condition can converge, and the prediction effect of the wax precipitation point is good.
[0194] (4) The model calculation framework has good scalability.
[0195] The core technical features of the present invention: The gas and liquid phase equations of state and the solid phase activity model can be replaced by other models. For example, the gas-liquid phase equation of state can be replaced by the SRK equation, the CPA equation, etc.; the solid phase activity model can be replaced by the UNIQUAC model, the regular solution model, etc., to adapt to the application scenarios of more complex fluids.
[0196] Based on the same inventive concept, the embodiments of the present application also provide a device for determining the wax precipitation amount during oil and gas transportation, which can be used to implement the methods described in the above embodiments, such as the following embodiments. Since the principle of solving problems by the device for determining the wax precipitation amount during oil and gas transportation is similar to that of the method for determining the wax precipitation amount during oil and gas transportation, the implementation of the device for determining the wax precipitation amount during oil and gas transportation can refer to the implementation of the method for determining the wax precipitation amount during oil and gas transportation, and the repeated parts will not be described again. Hereinafter, the term "unit" or "module" can be a combination of software and / or hardware that can achieve a predetermined function. Although the systems described in the following embodiments are preferably implemented in software, implementation in hardware, or a combination of software and hardware is also possible and contemplated.
[0197] The embodiments of the present application provide a specific implementation manner of a device for determining the wax precipitation amount during oil and gas transportation that can implement the method for determining the wax precipitation amount during oil and gas transportation. Refer to Figure 17 , a device for determining the wax precipitation amount during oil and gas transportation specifically includes the following contents:
[0198] A single-phase stability test module 10, configured to perform a single-phase stability test on the transported fluid to generate a single-phase stability test result;
[0199] A wax-containing single-phase stability test module 20, configured to perform a wax-containing single-phase stability test on the single-phase stability test result when the system corresponding to the single-phase stability test result is stable;
[0200] A first gas-liquid two-phase flash calculation module 30, configured to perform a wax-containing two-phase flash calculation on the wax-containing single-phase stability test result to determine the first wax precipitation amount when the system corresponding to the wax-containing single-phase stability test result is unstable;
[0201] A second gas-liquid two-phase flash calculation module 40, configured to perform a gas-liquid two-phase flash calculation on the single-phase stability test result and perform a wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result when the system corresponding to the single-phase stability test result is unstable;
[0202] A gas-liquid-wax three-phase flash calculation module 50, configured to perform a gas-liquid-wax three-phase flash calculation on the wax-containing two-phase stability test result to determine the second wax precipitation amount when the system corresponding to the wax-containing two-phase stability test result is unstable.
[0203] In some embodiments of the present invention, the single-phase stability test module includes:
[0204] A mole fraction determination unit for determining the mole fraction of the transported fluid;
[0205] A component content determination unit for the first test phase, which is used to determine the component content of the first test phase for each preset pressure point and temperature point according to the mole fraction and a preset gas-liquid equilibrium constant; wherein, the first test phase is the phase where the transported fluid is located.
[0206] In some embodiments of the present invention, a device for determining the wax precipitation amount during oil and gas transportation further includes:
[0207] A first system stability judgment module for judging whether the system corresponding to the single-phase stability test result is stable; the first system stability judgment module includes:
[0208] A first system stability judgment unit for judging whether the system corresponding to the single-phase stability test result is stable when the single-phase stability test result converges, and the system corresponding to the single-phase stability test result includes a first test phase and the first test phase.
[0209] In some embodiments of the present invention, the wax-containing single-phase stability test module includes:
[0210] A second test phase determination unit for determining a second test phase according to the phase where the transported fluid is located in the single-phase stability test result;
[0211] A component content determination unit for the second test phase, which is used to determine the component content of the second test phase for each preset pressure point and temperature point according to the second test phase and a preset liquid-solid equilibrium constant.
[0212] In some embodiments of the present invention, a device for determining the wax precipitation amount during oil and gas transportation further includes:
[0213] A second system stability judgment module for judging whether the system corresponding to the wax-containing single-phase stability test result is stable; the second system stability judgment module includes:
[0214] A second system stability judgment unit for judging whether the system corresponding to the wax-containing single-phase stability test result is stable when the wax-containing single-phase stability test result converges, and the system corresponding to the wax-containing single-phase stability test result includes a second test phase and the second test phase.
[0215] In some embodiments of the present invention, the second gas-liquid two-phase flash calculation module includes:
[0216] A third test phase determination unit, configured to determine a third test phase according to the liquid phase in the gas-liquid two-phase flashing calculation result;
[0217] A component content determination unit of the third test phase, configured to determine the component content of the third test phase for each preset pressure point and temperature point according to the third test phase and a preset liquid-solid equilibrium constant.
[0218] In some embodiments of the present invention, a device for determining the wax precipitation amount during oil and gas transportation further includes:
[0219] A third system stability judgment module, configured to judge whether the system corresponding to the wax-containing two-phase stability test result is stable. The third system stability judgment module includes:
[0220] A third system stability judgment unit, configured to judge whether the system corresponding to the wax-containing two-phase stability test result is stable when the wax-containing two-phase stability test result converges. The system corresponding to the wax-containing two-phase stability test result includes the third test phase and the third test phase.
[0221] Embodiments of the present application also provide a specific implementation manner of an electronic device capable of implementing all steps in the method for determining the wax precipitation amount during oil and gas transportation in the above embodiments. Refer to Figure 18 , and the electronic device specifically includes the following contents:
[0222] A processor 1201, a memory 1202, a communication interface 1203, and a bus 1204;
[0223] Among them, the processor 1201, the memory 1202, and the communication interface 1203 complete mutual communication through the bus 1204; the communication interface 1203 is used to implement information transmission between related devices such as a server-side device, a power measurement device, and a user-side device.
[0224] The processor 1201 is configured to call a computer program in the memory 1202. When the processor executes the computer program, all steps in the method for determining the wax precipitation amount during oil and gas transportation in the above embodiments are implemented. For example, when the processor executes the computer program, the following steps are implemented:
[0225] Step 100: Perform a single-phase stability test on the transported fluid to generate a single-phase stability test result;
[0226] Step 200: If the system corresponding to the single-phase stability test result is stable, perform a wax-containing single-phase stability test on the single-phase stability test result;
[0227] Step 300: When the system corresponding to the wax-containing single-phase stability test result is unstable, perform wax-containing two-phase flash calculation on the wax-containing single-phase stability test result to determine the first wax precipitation amount;
[0228] Step 400: When the system corresponding to the single-phase stability test result is unstable, perform gas-liquid two-phase flash calculation on the single-phase stability test result, and perform wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result;
[0229] Step 500: When the system corresponding to the wax-containing two-phase stability test result is unstable, perform gas-liquid-wax three-phase flash calculation on the wax-containing two-phase stability test result to determine the second wax precipitation amount.
[0230] An embodiment of the present application further provides a computer-readable storage medium capable of implementing all steps in the method for determining wax precipitation amount during oil and gas transportation in the above embodiments. A computer program is stored on the computer-readable storage medium. When the computer program is executed by a processor, all steps in the method for determining wax precipitation amount during oil and gas transportation in the above embodiments are implemented. For example, when the processor executes the computer program, the following steps are implemented:
[0231] Step 100: Perform single-phase stability test on the transported fluid to generate a single-phase stability test result;
[0232] Step 200: When the system corresponding to the single-phase stability test result is stable, perform wax-containing single-phase stability test on the single-phase stability test result;
[0233] Step 300: When the system corresponding to the wax-containing single-phase stability test result is unstable, perform wax-containing two-phase flash calculation on the wax-containing single-phase stability test result to determine the first wax precipitation amount;
[0234] Step 400: When the system corresponding to the single-phase stability test result is unstable, perform gas-liquid two-phase flash calculation on the single-phase stability test result, and perform wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result;
[0235] Step 500: When the system corresponding to the wax-containing two-phase stability test result is unstable, perform gas-liquid-wax three-phase flash calculation on the wax-containing two-phase stability test result to determine the second wax precipitation amount.
[0236] Each embodiment in this specification is described in a progressive manner. The same or similar parts among the embodiments can be referred to each other, and the differences between each embodiment and other embodiments are emphasized. In particular, for the hardware + program type embodiments, since they are basically similar to the method embodiments, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiments.
[0237] The above describes specific embodiments of this specification. Other embodiments are within the scope of the appended claims. In some cases, the acts or steps recited in the claims may be performed in a different order than in the embodiments and still achieve the desired results. Additionally, the processes depicted in the drawings do not necessarily require the particular order or sequential order shown to achieve the desired results. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0238] Although this application provides method operation steps such as in the embodiments or flowcharts, based on routine or non-creative labor, there may be more or fewer operation steps. The order of steps recited in the embodiments is only one way among many orders of step execution and does not represent the only execution order. When the actual device or client product is executing, it may be executed in the order of the method shown in the embodiments or the drawings or in parallel (such as in an environment of parallel processors or multithreaded processing).
[0239] This application is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to the embodiments of this application. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and the combination of flows and / or blocks in the flowcharts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, such that the instructions executed by the processor of the computer or other programmable data processing devices generate a device for implementing the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.
[0240] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing devices to work in a specific manner, such that the instructions stored in the computer-readable memory generate a manufactured article including instruction means that implement the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.
[0241] These computer program instructions can also be loaded onto a computer or other programmable data processing devices, such that a series of operation steps are performed on the computer or other programmable devices to generate a computer-implemented process, and thus the instructions executed on the computer or other programmable devices provide steps for implementing the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.
[0242] In this application, specific embodiments are used to elaborate on the principles and implementation manners of the application. The description of the above embodiments is only used to help understand the method and its core idea of the application; at the same time, for those of ordinary skill in the art, according to the idea of the application, there will be changes in the specific implementation manners and application scopes. In summary, the content of this specification should not be construed as a limitation to the application.
Claims
1. A method for determining the wax precipitation amount during oil and gas transportation, characterized in that, Including: Performing a single-phase stability test on the transported fluid to generate a single-phase stability test result; When the system corresponding to the single-phase stability test result is stable, performing a wax-containing single-phase stability test on the single-phase stability test result; When the system corresponding to the wax-containing single-phase stability test result is unstable, performing a wax-containing two-phase flash calculation on the wax-containing single-phase stability test result to determine the first wax precipitation amount; When the system corresponding to the single-phase stability test result is unstable, performing a gas-liquid two-phase flash calculation on the single-phase stability test result, and performing a wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result; When the system corresponding to the wax-containing two-phase stability test result is unstable, performing a gas-liquid-wax three-phase flash calculation on the wax-containing two-phase stability test result to determine the second wax precipitation amount.
2. The method for determining the wax precipitation amount during oil and gas transportation according to claim 1, wherein The performing a single-phase stability test on the transported fluid includes: Determining the mole fraction of the transported fluid; According to the mole fraction and a preset gas-liquid equilibrium constant, determining the component content of the first test phase for each preset pressure point and temperature point; wherein, the first test phase is the phase where the transported fluid is located.
3. The method for determining the wax precipitation amount during oil and gas transportation according to claim 2, wherein, The step of determining whether the system corresponding to the single-phase stability test result is stable includes: When the single-phase stability test result converges, determining whether the system corresponding to the single-phase stability test result is stable, and the system corresponding to the single-phase stability test result includes a first test phase and the first test phase.
4. The method for determining the wax precipitation amount during oil and gas transportation according to claim 1, characterized in that Performing a wax-containing single-phase stability test on the single-phase stability test result includes: Determining a second test phase according to the phase where the transported fluid is located in the single-phase stability test result; According to the second test phase and a preset liquid-solid equilibrium constant, determining the component content of the second test phase for each preset pressure point and temperature point.
5. The method for determining the wax precipitation amount during oil and gas transportation according to claim 4, wherein The step of determining whether the system corresponding to the wax-containing single-phase stability test result is stable includes: When the wax-containing single-phase stability test result converges, determining whether the system corresponding to the wax-containing single-phase stability test result is stable, and the system corresponding to the wax-containing single-phase stability test result includes a second test phase and the second test phase.
6. The method for determining the wax precipitation amount during oil and gas transportation according to claim 1, wherein Performing a wax-containing two-phase stability test on the gas-liquid two-phase flash calculation result includes: Determining a third test phase according to the liquid phase in the gas-liquid two-phase flash calculation result; According to the third test phase and a preset liquid-solid equilibrium constant, determining the component content of the third test phase for each preset pressure point and temperature point.
7. The method for determining the wax precipitation amount during oil and gas transportation according to claim 6, wherein The step of determining whether the system corresponding to the wax-containing two-phase stability test result is stable includes: When the wax-containing two-phase stability test result converges, determining whether the system corresponding to the wax-containing two-phase stability test result is stable, and the system corresponding to the wax-containing two-phase stability test result includes a third test phase and the third test phase.
8. An apparatus for determining the wax precipitation amount during oil and gas transportation, characterized in that, Including: A single-phase stability test module for performing a single-phase stability test on the transported fluid to generate a single-phase stability test result; A wax-containing single-phase stability test module for performing a wax-containing single-phase stability test on the single-phase stability test result when the system corresponding to the single-phase stability test result is stable; The first module for gas-liquid two-phase flashing calculation is used to perform gas-liquid two-phase flashing calculation on the wax-containing single-phase stability test result to determine the first wax precipitation amount when the system corresponding to the wax-containing single-phase stability test result is unstable; The second module for gas-liquid two-phase flashing calculation is used to perform gas-liquid two-phase flashing calculation on the single-phase stability test result and perform wax-containing two-phase stability test on the gas-liquid two-phase flashing calculation result when the system corresponding to the single-phase stability test result is unstable; The gas-liquid-wax three-phase flashing calculation module is used to perform gas-liquid-wax three-phase flashing calculation on the wax-containing two-phase stability test result to determine the second wax precipitation amount when the system corresponding to the wax-containing two-phase stability test result is unstable.
9. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instructions are executed by a processor, the steps of the method for determining the wax precipitation amount during oil and gas transportation according to any one of claims 1 to 7 are implemented.
10. An electronic device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, the steps of the method for determining the wax precipitation amount during oil and gas transportation according to any one of claims 1 to 7 are implemented.
11. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, the steps of the method for determining the wax precipitation amount during oil and gas transportation according to any one of claims 1 to 7 are implemented.