An ultrasonic flow measurement method for oil-water two-phase flow based on double-layer sparse modeling
Patent Information
- Application Number
- CN202611173067.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2026-07-07
- Filing Date
- 2026-08-04
- Publication Date
- 2026-10-23
AI Technical Summary
这些异常流速本质上已退化为与总流量无关的随机信号,若直接参与流量积分将引入显著误差
1. 本发明基于脉冲波超声多普勒传感器获得油水两相流流量,具有结构简单、成本低、不干扰流动过程的优点;
Smart Images

Figure CN122961513A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of multiphase flow process parameter measurement, and relates to a method for measuring the total flow rate of oil-water two-phase flow based on the pulse wave ultrasonic Doppler measurement principle and through a two-layer sparse modeling method. Background Technology
[0002] Oil-water two-phase flow is widely present in oil extraction, gathering, transportation, and refining processes, and its accurate online flow monitoring is of crucial strategic and economic significance. On the one hand, real-time, accurate flow monitoring data can objectively characterize oil well production dynamics, providing core data support for capacity evaluation, development system optimization, and reservoir dynamic development and control. On the other hand, in secondary / tertiary oil recovery and smart well development systems, online flow monitoring technology can promptly identify abnormal production conditions such as water hammer disturbances, well water production, and gas lock failures, helping to adjust process parameters in a timely manner and improve oil and gas resource development efficiency and production stability. Simultaneously, high-precision online flow measurement is an important basis for production safety assurance and energy consumption quota control, and also provides fundamental guarantees for the safe and stable operation of surface facilities such as multiphase flow pumps and separators.
[0003] Currently, numerous researchers both domestically and internationally have developed various flow measurement technologies, including differential pressure methods, electrical methods, optical methods, and ultrasonic methods. Among these, the ultrasonic method has advantages such as simple sensor structure, non-invasiveness, minimal interference with flow within pipes, and adaptability to non-transparent media, and has received widespread attention in the field of complex multiphase flow measurement in recent years. Based on different velocity measurement principles, ultrasonic flow measurement methods mainly include the time-of-flight method and the Doppler method. The time-of-flight method utilizes the time difference between the propagation of ultrasonic waves in the fluid's upstream and downstream directions to achieve flow measurement, performing well in uniform single-phase flows. However, when applied to multiphase flows, the propagation path and transmission time of ultrasonic waves are significantly affected by discrete phases such as bubbles, droplets, and solid particles, leading to limited measurement accuracy. The Doppler method utilizes the Doppler effect principle—the frequency shift generated when ultrasonic waves act on discrete phases is proportional to the flow velocity—to achieve flow measurement, demonstrating significant application potential in complex multiphase media scenarios.
[0004] The pulse-wave ultrasonic Doppler method is an important branch of ultrasonic flow measurement. This method measures fluid flow rate using an ultrasonic transducer operating in self-transmitting and self-receiving mode. Specifically, the ultrasonic transducer intermittently emits short ultrasonic pulse beams into the fluid at a certain pulse repetition frequency. When the ultrasonic beam propagates in the fluid, it encounters discrete oil or water droplets, resulting in acoustic phenomena such as reflection and scattering. The echoes generated are received by the same ultrasonic transducer within the pulse transmission interval. Furthermore, based on the travel time characteristics of sound waves and the Doppler principle, the transit time of the sound wave and the frequency offset between the transmitted and received signals are extracted using distance gate technology and spectral analysis methods to reconstruct the velocity distribution of the fluid along the direction of the sound beam. Finally, the flow rate is measured by integrating the velocity profile. The most commonly used integration method is the layered integration method. This method requires dividing the pipe under test into multiple parallel thin layers along the radial direction of the pipe, assuming that the fluid velocity in each layer is equal and ignoring lateral turbulence. Then, the velocity profile is used to determine the velocity at different radial measurement locations, and the total flow rate is obtained by integration. However, in actual flow processes, complex interphase interactions exist between the oil and water phases, and their non-uniform distribution due to density differences leads to unsteady and asymmetric flow fields, making the assumptions of traditional layered integration methods untenable. Furthermore, influenced by the density differences between the oil and water phases, the discrete phases often exhibit spatial aggregation characteristics. During ultrasonic measurements, this can easily lead to weak or even absent echoes in some areas due to missing or insufficient scattering bodies, resulting in abnormal local flow velocities. These anomalies may include: discontinuities in velocity values with adjacent spatial locations, significant jumps; increased variance in the velocity sequence or random noise characteristics in the power spectrum; and non-zero velocities in non-interface regions. These abnormal velocities essentially degenerate into random signals unrelated to the total flow rate, and direct integration of these velocities will introduce significant errors. To address this problem, this invention proposes a pulse-wave ultrasonic Doppler measurement method for oil-water two-phase flow based on dual-layer sparse modeling. By sparsely filtering the measurement spatial location and multidimensional statistical characteristics, the accuracy of flow measurement under asymmetric, non-uniform, complex flow fields and local velocity distortion conditions is improved. Summary of the Invention
[0005] The purpose of this invention is to propose a pulse-wave ultrasonic Doppler measurement method for oil-water two-phase flow based on dual-layer sparse modeling. This method improves flow measurement accuracy under asymmetric, non-uniform, and complex flow fields, as well as local velocity distortion conditions, by adaptively selecting a reliable radial measurement location sensitive to total flow rate and filtering key statistical features within the selected location. The technical solution of this invention is as follows: An ultrasonic measurement method for oil-water two-phase flow based on bilayer sparse modeling includes the following steps: S1, using a pulse wave ultrasonic Doppler testing system to measure the velocity profile of oil-water two-phase flow at different radial measurement positions in the pipeline; S2, extract multidimensional statistical features of flow velocity at different radial measurement locations, and construct a long vector of global input features; S3 utilizes the global input feature long vector to establish the first-layer sparse regression model based on the LASSO algorithm, and defines the radial measurement location importance scoring index based on the regression coefficients to eliminate unreliable physical measurement areas caused by local echo loss or low signal-to-noise ratio, thereby achieving spatial sparsity of measurement and obtaining the optimal measurement location. S4. Utilize the local input features at the preferred measurement location to establish a second-layer sparse regression model, eliminate collinear redundancy between features, achieve feature sparsity, and obtain the optimal feature subset. S5, the total flow rate of oil-water two-phase flow is measured by using the optimal feature subset at the preferred measurement location.
[0006] Furthermore, the method in S1 is as follows: A pulse-wave ultrasonic Doppler testing system is used to test the oil-water two-phase flow under typical flow conditions, obtaining data along the radial direction of the pipeline. Time series of flow velocity profiles at various locations ,in, For radial measurement location index, This represents the total number of radial measurement locations. Indicates the experimental sample index. This represents the total number of experimental samples; For time, Measurement time for each experimental sample.
[0007] Furthermore, the method of S2 is as follows: S21, for the first The velocity profile time series obtained from the experimental samples The mean flow velocity at different radial measurement locations was extracted. ,variance Maximum value Minimum value kurtosis skewness A total of 6 statistical features are used to form a feature matrix. ; S22, using the Z-score normalization method to normalize the feature matrix. Normalization is performed along the column direction, and the normalized matrix is then horizontally flattened and recombined along the row direction to form a one-dimensional global input feature vector. .
[0008] Furthermore, S3 is implemented by the following sub-steps: S31, using a one-dimensional global input feature long vector The actual total flow is the independent variable. Using LASSO as the target variable, a first-order global linear sparse regression model is established based on the LASSO algorithm. The model parameters are determined by solving the following objective function:
[0009] In the formula, For the first The actual flow values of each experimental sample; Indicates the first One-dimensional global input feature long vector of each experimental sample The first in Each feature element Features coefficient, This is the primary intercept term. This is the primary regularization strength parameter; S32, the solution obtained Reorganized into a two-dimensional coefficient matrix based on the number of radial measurement locations and the number of feature categories. ; S33, for the two-dimensional coefficient matrix The absolute values of the row vectors are accumulated to construct the radial measurement position. Importance scoring indicators ; S34, assign importance scores to each radial measurement location. Sort the radial measurement location indices from largest to smallest to obtain the radial measurement location index sequence; S35, based on preset quantity Determine the preferred measurement locations, forming a subset of preferred measurement locations:
[0010] Furthermore, the S4 method is as follows: S41, Input feature vector from one-dimensional global input Extract the feature row vector at the optimal measurement position obtained in step S3 to form a one-dimensional local input feature long vector. ; S42, using a one-dimensional local input feature vector The actual total flow is the independent variable. Using LASSO as the target variable, a first-order local linear sparse regression model is established based on the LASSO algorithm. The model parameters are determined by solving the following objective function:
[0011] In the formula, Indicates the first One-dimensional local input feature long vector of each experimental sample The first in Each feature element Features coefficient, For the secondary intercept term, This is the secondary regularization strength parameter; S43, according to The optimal feature subset is determined by the non-zero states of the coefficients of each term. ;
[0012] S44, utilizing the optimal feature subset selected at the optimal measurement location. And its corresponding non-zero coefficients, let Q be the predicted total flow rate, and establish its inverse mapping model with the total flow rate of the oil-water two-phase flow: .
[0013] Furthermore, the S5 method is as follows: After completing the offline calibration of the model based on the experimental samples collected under typical flow conditions, the obtained model is used for online measurement; during online measurement, the optimal feature subset at the preferred measurement position is extracted from the velocity profile collected in real time by the pulse wave ultrasonic Doppler testing system, and substituted into the total flow inversion mapping model to output the total flow of the oil-water two-phase flow.
[0014] The essential feature of this invention is that it uses flow velocity information (velocity profiles) at different radial measurement positions in a pipeline obtained by a pulse-wave ultrasonic Doppler testing system as the data foundation, and obtains the total flow rate of the oil-water two-phase flow through a two-layer sparse modeling method. The first layer of sparse modeling is mainly used to achieve sparsity of the measurement space, eliminating unreliable physical measurement areas caused by local echo loss or low signal-to-noise ratio, filtering out noise sources, and fundamentally reducing the impact of flow velocity anomalies on flow measurement. The second layer of sparse modeling is mainly used to achieve feature sparsity, eliminating collinear redundancy between statistical features at the optimal measurement position and determining the optimal feature subset required for flow mapping. This method overcomes the problem of low flow measurement accuracy in existing profile-layered integration methods under asymmetric, non-uniform complex flow fields and local velocity distortion conditions. The beneficial effects and advantages of this invention are as follows: 1. This invention obtains the flow rate of oil-water two-phase flow based on a pulse wave ultrasonic Doppler sensor, which has the advantages of simple structure, low cost, and no interference with the flow process; 2. The flow acquisition method of the present invention does not directly rely on the hierarchical integration of the complete velocity profile. Instead, it establishes a mapping relationship between the optimal statistical features and flow rate in the effective measurement space through a two-layer sparse structure. This can reduce the impact of missing local echoes and abnormal velocity measurement points on flow rate calculation, reduce the risk of overfitting caused by high-dimensional features, and make the model have clear physical interpretability.
[0015] 3. This invention establishes a correspondence between sparse regression coefficients and physical radial measurement locations by scoring the importance of radial measurement locations, enabling the optimal measurement location to migrate with the flow pattern distribution characteristics, thus possessing a certain flow field self-diagnosis capability.
[0016] 4. The sparse model parameters of the present invention can be adjusted according to actual working conditions (pipeline size, flow pattern range, oil-water properties, etc.), and have good applicability and scalability. It can achieve high-precision measurement of the total flow rate of oil-water two-phase flow under asymmetric, non-uniform complex flow fields and local velocity distortion conditions. Attached Figure Description
[0017] The following figures illustrate selected embodiments of the present invention and are exemplary rather than exhaustive or limiting, wherein: Figure 1 This is a structural diagram of the pulse wave ultrasonic Doppler testing system in the measurement method of the present invention; Figure 2 This is a schematic diagram illustrating the principle of pulse wave ultrasonic Doppler velocity profile measurement in the measurement method of the present invention; Figure 3 The flowchart shows the LASSO algorithm (Least Absolute Shrinkage and Selection Operator) in the measurement method of this invention. Figure 4 This is a flowchart illustrating the process of obtaining the total flow rate of oil-water two-phase flow using the double-layer sparse modeling method in the measurement method of this invention. Figure 5 These are three typical flow regimes of oil-water two-phase flow in embodiments of the present invention.
[0018] Figure 6 This is a bar chart showing the importance of radial measurement locations under typical flow patterns of oil-water two-phase flow in the measurement method of this invention. Figure 7 This is a bar chart showing the regression coefficients of the characteristics within the optimal location under a typical flow pattern of oil-water two-phase flow in the measurement method of this invention.
[0019] Figure 8 This is a graph showing the measurement results of the total flow rate of the oil-water two-phase flow in the measurement method of the present invention. Detailed Implementation
[0020] The embodiments of the present invention will now be described in detail with reference to the accompanying drawings and tables.
[0021] Figure 1This is a structural diagram of the pulse wave ultrasonic Doppler testing system used in the measurement method of this invention. The pulse wave ultrasonic Doppler testing system used in this invention comprises a sensing device I and an acoustic transceiver II. In the sensing device I, the ultrasonic sensor 0 is installed at an angle at the bottom of a horizontal pipe 1, containing only a single piezoelectric ceramic wafer, and ensuring that the sound wave propagates against the fluid flow direction 2. In the acoustic transceiver II, a signal generator 3 generates a low-voltage drive signal with the required excitation frequency and pulse repetition frequency. This signal is amplified by a power amplifier 4 and then sent to the ultrasonic sensor 0. The electrical signal is converted into an ultrasonic signal through the inverse piezoelectric effect of the piezoelectric ceramic wafer. The generated ultrasonic signal propagates in the fluid being measured, and upon encountering discrete droplets, it undergoes reflection or scattering, generating an echo. This echo is received by the ultrasonic sensor 0, and the acoustic signal is converted back into an electrical signal through the piezoelectric effect of the piezoelectric ceramic wafer, which is then sent to the echo conditioning module 5. The echo conditioning module 5 filters and amplifies the signal before sending it to the profile calculation module 6 to reconstruct the velocity profile, and finally the computer completes the data storage.
[0022] Figure 2 This is a schematic diagram illustrating the principle of pulse-wave ultrasonic Doppler velocity profile measurement in the measurement method of this invention. Since the ultrasonic sensor operates in a self-transmitting and self-receiving mode, it intermittently emits short ultrasonic pulse beams into the fluid at a certain pulse repetition frequency. When this ultrasonic beam propagates in the fluid, it encounters discrete oil droplets, resulting in acoustic phenomena such as reflection and scattering. The resulting echoes are received by the same ultrasonic transducer within the pulse transmission interval. On one hand, based on the travel time characteristics of ultrasonic wave propagation, the measurement depth (radial measurement position) can be accurately located by utilizing the time delay between the received and emitted sound waves and the sound propagation speed. In the formula This refers to the time delay from ultrasonic pulse transmission to echo reception. The speed at which ultrasound propagates in the medium under test. This is the angle between the ultrasonic wave and the horizontal direction. On the other hand, due to the motion of the discrete phase, the resulting echo signal experiences a slight time delay between adjacent transmission cycles, causing a delay at a fixed time after pulse transmission (corresponding to a fixed radial measurement position). There is a phase difference between the echo signals at (location 1) and (location 2), and the derivative of this phase difference is the Doppler frequency shift. Based on the Doppler velocity measurement principle, by Radial measurement position can be obtained Flow velocity at In the formula This refers to the frequency of the emitted sound wave. It should be noted that the resolution of the radial measurement position is related to the number of pulse cycles of the excitation signal. And ultrasonic waves Related, represented as: In an embodiment of the present invention, the frequency of the excitation signal is 1MHz, the number of pulse cycles is 4, and the resolution of the radial measurement position is approximately 3mm.
[0023] Figure 3 This is a flowchart of the LASSO algorithm in the measurement method of this invention. Data preparation stage: Constructing the input feature matrix. X With the output target vector Y and the input feature matrix X Standardization preprocessing is performed to eliminate the impact of dimensional differences on penalty term calculation and ensure fairness in feature selection. Then, [further steps are taken]. K Folded cross-validation: The preprocessed dataset is randomly and equally divided into 10 parts. K Sub-datasets (usually) K (5 or 10 can be selected), and a single dataset is selected sequentially as the validation test set, and the remaining datasets are selected in a loop. K -1 datasets are merged into a training set. On each training set, a least-squares optimization objective function with an L1 penalty is solved to obtain regression coefficients. The one-fold mean squared prediction error is then calculated on the corresponding validation test set. traverse all K Calculate the same regularization parameter after folding corresponding K Average cross-validation error. After completing the full parameter traversal, the optimal regularization parameters are selected from the entire sequence of regularization parameters based on the minimum MSE criterion or the 1-SE standard deviation criterion. Ultimately, the optimal regularization parameters are adopted. By resolving the optimization function using all the preprocessed datasets, the sparse regression coefficients are obtained. With the intercept term, the output is a linear model that can be used for parameter prediction. .
[0024] Figure 4 The flowchart of obtaining the total flow rate of oil-water two-phase flow using the double-layer sparse modeling method in the measurement method of the present invention; The ultrasonic measurement method for oil-water two-phase flow based on LASSO bilayer sparse modeling proposed in this invention patent includes the following steps: Step 1: Using Figure 1 The pulse wave ultrasonic Doppler testing system shown performs dynamic testing of oil-water two-phase flow under typical flow conditions, based on... Figure 2 The pulse wave ultrasonic Doppler velocity profile measurement principle shown obtains the velocity profile along the radial direction of the pipe. Time series of flow velocity profiles at various locations .in, For radial measurement location index, The total number of radial measurement locations depends on the distance resolution of the pulse wave ultrasonic Doppler testing system and the pipe diameter. Indicates the experimental sample index. This represents the total number of experimental samples; For time, Measurement time for each experimental sample.
[0025] In the embodiments of the present invention, three typical oil-water two-phase flow regimes were tested: stratified flow with mixing at the interface (ST&MI), dispersion of oil in water and water (Do / w&w), and water in oil emulsion (w / o). Flow photographs are shown below. Figure 5 As shown in the figure. In the experiment, in addition to obtaining the flow velocity profile time series using a pulse wave ultrasonic Doppler testing system, each dynamic test also required obtaining the real total flow label for model training using a standard single-phase flow meter. .
[0026] Step 2: Under each typical flow regime of oil-water two-phase flow, perform statistical analysis on the obtained velocity profile time series samples to construct a global input feature long vector dataset, which is achieved through the following sub-steps: 1) Under each typical flow regime of oil-water two-phase flow, for the first... The velocity profile time series obtained from the experimental samples The mean flow velocity at different locations was extracted. ,variance Maximum value Minimum value kurtosis skewness There are a total of 6 statistical features, forming a feature matrix. .in, Indicates the first The first experimental sample Flow velocity statistical characteristic row vectors at each radial measurement location .
[0027] 2) For each typical flow regime in oil-water two-phase flow, the characteristic matrix is normalized using the Z-score method. Normalization is performed along the column direction, and the normalized matrix is then horizontally flattened and recombined along the row feature direction to form a one-dimensional global input feature long vector. Each of them It is the normalized first Flow velocity statistical characteristic row vectors at each radial measurement location Therefore, according to the number of data elements in the row vector, we denote... .
[0028] Step 3: Under each typical flow regime of oil-water two-phase flow, establish the first-layer sparse regression model based on the LASSO algorithm to filter radial measurement locations. This is achieved through the following sub-steps: 1) Under each typical flow regime of oil-water two-phase flow, use a one-dimensional global input feature long vector. The actual total flow is the independent variable. For the target variable, based on Figure 3 The LASSO algorithm principle described above establishes a first-order global linear sparse regression model. The model parameters can be determined by solving the following minimized objective function:
[0029] In the formula, For the first The actual flow values of each experimental sample; Indicates the first One-dimensional global input feature long vector of each experimental sample The first in Each feature element Features coefficient, This is the primary intercept term. This is the primary regularization strength parameter.
[0030] 2) The solution obtained Reorganized into a two-dimensional coefficient matrix based on the number of radial measurement locations and the number of feature categories. :
[0031] In the formula, each term Indicates the first At the radial measurement position, the first The coefficients of each feature in the flow linear regression model represent the degree of contribution of that feature to flow calculation.
[0032] 3) For the two-dimensional coefficient matrix The absolute values of the row vectors are accumulated to construct the radial measurement position. Importance scoring indicators :
[0033] 4) Assess the importance of each radial measurement location. Sort from largest to smallest to obtain the radial measurement location index sequence:
[0034] In the formula, This indicates a sorting operation from largest to smallest. The resulting indices are the sorted values. This represents the position index sorted by importance.
[0035] 5) According to the preset quantity Determine the preferred measurement locations, forming a subset of preferred measurement locations: .
[0036] In the formula, It can be a fixed value, or it can be determined through cross-validation, importance thresholds, or online operating condition requirements. In the embodiments of the present invention, The value is set to 3, but the invention is not limited thereto.
[0037] Figure 6 This is a bar chart showing the importance score of radial measurement locations under typical flow patterns in the oil-water two-phase flow of the measurement method of this invention. In the chart, the vertical axis represents the importance score index of the radial measurement location. The horizontal axis represents the radial measurement location number in the velocity profile. The numbers increasing from small to large indicate that the radial measurement location moves radially from the bottom to the top of the pipe. The figure shows that the optimal measurement locations differ significantly depending on the distribution of the discrete phase (ultrasonic scatterer) under different flow patterns in the oil-water two-phase flow. In the ST&MI flow pattern, the oil and water phases are stratified in the horizontal pipe due to their density difference. The less dense oil phase concentrates at the top of the pipe, while the more dense water phase concentrates at the bottom. Simultaneously, complex interfacial wave effects at the oil-water interface cause discrete droplets to be distributed near the interface, making radial measurement locations 5, 6, and 8 highly important in this flow pattern. In the Do / w&w flow pattern, with the increase of interfacial waves and phase shear force, the continuity of the oil phase is disrupted and it transforms into dispersed oil droplets. However, the dynamic force on the oil droplets is insufficient to overcome buoyancy, and the droplets mainly concentrate in the upper part of the pipe, making radial measurement locations 8, 11, and 14 highly important in this flow pattern. In the w / o flow pattern, discrete water droplets are mainly affected by dynamic forces and gravity. The dynamic forces cause the droplets to tend to be evenly distributed in the oil phase, while the gravity causes them to tend to settle at the bottom of the pipe. The two forces counteract each other, resulting in a certain concentration gradient of the droplets dispersed in the continuous oil phase. Therefore, the radial measurement positions 2, 4, and 6 of this new flow pattern are of high importance.
[0038] Step 4: Under each typical flow regime of oil-water two-phase flow, based on Figure 3 The LASSO algorithm establishes a second-layer sparse regression model to filter statistical features at the optimal measurement location, which is achieved through the following sub-steps: 1) Input feature vector from a one-dimensional global source Extract the feature row vector at the optimal measurement position obtained in step (3) to form a one-dimensional local input feature long vector. .in, Each is a row vector containing six statistical features. Therefore, according to the number of data elements in the row vector, we denote... .
[0039] 2) Using a one-dimensional local input feature long vector The actual total flow is the independent variable. Using LASSO as the target variable, a first-order local linear sparse regression model is established based on the LASSO algorithm. The model parameters can be determined by solving the following minimized objective function:
[0040] In the formula, Indicates the first One-dimensional local input feature long vector of each experimental sample The first in Each feature element Features coefficient, For the secondary intercept term, The secondary regularization strength parameter is p=6.
[0041] 3) According to The non-zero states of the coefficients determine the optimal feature subset:
[0042] 4) Utilize the optimal feature subset selected at the optimal measurement location Based on its corresponding non-zero coefficients, an inverse mapping model between it and the total flow rate of the oil-water two-phase flow is established:
[0043] Figure 7 This is a bar chart showing the regression coefficients of characteristics within the optimal location under a typical flow pattern of oil-water two-phase flow in the measurement method of this invention. In the chart, the horizontal axis represents the optimal location, and the vertical axis represents the regression coefficients of different characteristics. The figure reveals that the distribution of characteristic coefficients differs across flow patterns, but overall, the mean coefficient is larger. Taking the ST&MI flow pattern as an example, the second-layer sparse modeling ultimately activates and retains 14 key non-zero features out of 18. Looking at the distribution of characteristic coefficients, radial measurement positions 5 and 6, located slightly below the center of the pipe, show high positive coefficients for their mean velocity characteristics. Conversely, radial measurement position 8, located at the center of the pipe, has its mean characteristic completely suppressed to zero, but exhibits a high negative coefficient for skewness and a high positive coefficient for the maximum value. This indicates that while relying on the mean to estimate the baseline flow rate, the model compensates for the pulsation deviation caused by interface waves through skewness and maximum values.
[0044] Step 5: Using experimental samples from each typical flow regime of the oil-water two-phase flow, the flow measurement model can be established according to steps 1-4 above. The resulting model can then be used for online measurement of the total flow rate of the oil-water two-phase flow. During online measurement, the optimal feature subset is extracted from the velocity profile acquired in real time by the pulse wave ultrasonic Doppler testing system, and substituted into the inversion mapping model of the total flow rate to output the total flow rate of the oil-water two-phase flow. Figure 8 This figure shows the measurement results of the total flow rate of oil-water two-phase flow under different flow patterns using the measurement method of this invention. It can be seen from the figure that the proposed method for obtaining the total flow rate of oil-water two-phase flow based on two-layer sparse modeling exhibits good testing results under all flow patterns, with a very high consistency between the measured values and the reference values. The root mean square error of the flow rate under all flow patterns is calculated to be 0.10 m³ / s. 3 / h.
Claims
1. An ultrasonic measurement method for oil-water two-phase flow based on bilayer sparse modeling, comprising the following steps: S1, using a pulse wave ultrasonic Doppler testing system to measure the velocity profile of oil-water two-phase flow at different radial measurement positions in the pipeline; S2, extract multidimensional statistical features of flow velocity at different radial measurement locations, and construct a long vector of global input features; S3 utilizes the global input feature long vector to establish the first-layer sparse regression model based on the LASSO algorithm, and defines the radial measurement location importance scoring index based on the regression coefficients to eliminate unreliable physical measurement areas caused by local echo loss or low signal-to-noise ratio, thereby achieving spatial sparsity of measurement and obtaining the optimal measurement location. S4. Utilize the local input features at the preferred measurement location to establish a second-layer sparse regression model, eliminate collinear redundancy between features, achieve feature sparsity, and obtain the optimal feature subset. S5, the total flow rate of oil-water two-phase flow is measured by using the optimal feature subset at the preferred measurement location.
2. The ultrasonic measurement method for oil-water two-phase flow rate according to claim 1, characterized in that, The method in S1 is as follows: A pulse-wave ultrasonic Doppler testing system is used to test the oil-water two-phase flow under typical flow conditions, obtaining data along the radial direction of the pipeline. Time series of flow velocity profiles at various locations ,in, For radial measurement location index, This represents the total number of radial measurement locations; Indicates the experimental sample index. This represents the total number of experimental samples; For time, Measurement time for each experimental sample.
3. The ultrasonic measurement method for oil-water two-phase flow rate according to claim 2, characterized in that, The method for S2 is as follows: S21, for the first The velocity profile time series obtained from the experimental samples The mean flow velocity at different radial measurement locations was extracted. ,variance Maximum value Minimum value kurtosis skewness A total of 6 statistical features are used to form a feature matrix. ; S22, using the Z-score normalization method to normalize the feature matrix. Normalization is performed along the column direction, and the normalized matrix is then horizontally flattened and recombined along the row direction to form a one-dimensional global input feature vector. .
4. The ultrasonic measurement method for oil-water two-phase flow rate according to claim 3, characterized in that, S3 is implemented by the following sub-steps: S31, using a one-dimensional global input feature long vector The actual total flow is the independent variable. Using LASSO as the target variable, a first-order global linear sparse regression model is established based on the LASSO algorithm. The model parameters are determined by solving the following minimum objective function: In the formula, For the first The actual flow values of each experimental sample; Indicates the first One-dimensional global input feature long vector of each experimental sample The first in Each feature element Features coefficient, This is the primary intercept term. This is the primary regularization strength parameter; S32, the solution obtained Reorganized into a two-dimensional coefficient matrix based on the number of radial measurement locations and the number of feature categories. ; S33, for the two-dimensional coefficient matrix The absolute values of the row vectors are accumulated to construct the radial measurement position. Importance scoring indicators ; S34, assign importance scores to each radial measurement location. Sort the radial measurement location indices from largest to smallest to obtain the radial measurement location index sequence; S35, based on preset quantity Determine the preferred measurement locations, forming a subset of preferred measurement locations:
5. The ultrasonic measurement method for oil-water two-phase flow rate according to claim 4, characterized in that, The method for S4 is as follows: S41, Input feature vector from one-dimensional global input Extract the feature row vector at the optimal measurement position obtained in step S3 to form a one-dimensional local input feature long vector. ; S42, using a one-dimensional local input feature vector The actual total flow is the independent variable. Using LASSO as the target variable, a first-order local linear sparse regression model is established based on the LASSO algorithm. The model parameters are determined by solving the following minimum objective function: In the formula, Indicates the first One-dimensional local input feature long vector of each experimental sample The first in Each feature element Features coefficient, For the secondary intercept term, This is the secondary regularization strength parameter; S43, according to The optimal feature subset is determined by the non-zero states of the coefficients of each term. ; S44, utilizing the optimal feature subset selected at the optimal measurement location. And its corresponding non-zero coefficients, let Q be the predicted total flow rate, and establish its inverse mapping model with the total flow rate of the oil-water two-phase flow: 。 6. The ultrasonic measurement method for oil-water two-phase flow rate according to claim 1, characterized in that, The S5 method is as follows: After completing the offline calibration of the model based on the experimental samples collected under typical flow conditions, the resulting model is used for online measurement; during online measurement, the optimal feature subset at the preferred measurement position is extracted from the velocity profile collected in real time by the pulse wave ultrasonic Doppler testing system, and substituted into the inversion mapping model of total flow rate to output the total flow rate of the oil-water two-phase flow.