Urban lifeline pipeline corrosion risk early warning method based on digital twinning
By establishing a digital state parameter perception module and an artificial intelligence prediction model that integrates physical and numerical space in a multiphase flow underground pipeline, the problems of poor universality and insufficient real-time early warning of the corrosion risk warning model of multiphase flow underground pipelines in the existing technology are solved, and more accurate corrosion risk prediction and pipeline life prediction are achieved, providing a more effective means for pipeline management.
Patent Information
- Application Number
- CN202411876924.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-19
- Publication Date
- 2025-05-02
- Estimated Expiration
- 2044-12-19
AI Technical Summary
In the prior art, the corrosion risk warning research on the full service life of multiphase flow underground pipelines has problems such as poor universality of prediction models and insufficient real-time evaluation and early warning mechanism.
By establishing a highly digital multi-phase flow underground pipeline state parameter perception acquisition module, and integrating physical space, numerical space and artificial intelligence algorithms, an internal and external corrosion rate prediction model is built to realize real-time hierarchical early warning and residual life prediction.
It improves the universality and accuracy of the prediction model, enhances the accuracy of corrosion risk prediction, and realizes real-time corrosion risk warning and residual life prediction of multi-phase flow underground pipeline sections, providing dynamic and active management methods for pipeline maintenance and maintenance.
Smart Images

Figure CN119918130A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of underground pipeline engineering, and in particular to a digital twin-based urban lifeline pipeline corrosion risk early warning method. Background Art
[0002] As a key facility in the city's lifeline project, multiphase underground pipelines are exposed to complex natural environments and changing working conditions for a long time, and are extremely susceptible to corrosion. Corrosion problems can cause gradual damage to the pipeline structure, reduce the pipeline's carrying capacity, and increase the risk of safety accidents such as leakage or even explosion, which poses a serious threat to the environment, personnel safety, and economic interests. At the same time, as the service life of pipelines increases, corrosion becomes more and more obvious, and it is urgent to ensure the stable operation of the pipeline system through risk assessment and anti-corrosion measures. Therefore, studying the corrosion risk of multiphase underground pipelines and accurately assessing their corrosion status and trends are of great practical significance for improving pipeline safety management and extending service life.
[0003] Current research on corrosion risk warning of multiphase flow underground pipelines during their entire service life has problems such as poor universality of prediction models and insufficient real-time assessment and warning mechanisms.
[0004] Chinese invention patent: Announcement number is "CN113919106B", and the name is "Underground pipeline structure safety evaluation method based on augmented reality and digital twins". It discloses an underground pipeline structure safety evaluation method based on augmented reality and digital twins. It uses augmented reality technology to realize the interaction between the pipeline digital twin and the real world, so that the digital twin, the on-site environment and people are fully integrated, so that people can quickly clarify the structural status, pipeline leakage, structural evolution trend, etc. of the underground pipeline with a perspective AR perspective and immersive human-computer interaction, so as to complete the scientific evaluation of the pipeline status on site, improve the efficiency of instant event handling and decision-making, and monitor the structural health status of the underground pipeline network, guide on-site maintenance and repair, improve the efficiency of operation and maintenance work, and stimulate innovative thinking of data fusion. However, this technical solution only considers the structural strength of the underground pipeline and the lagging parameters such as the leakage point to adjust the maintenance plan, and does not predict the remaining life of the underground pipeline, resulting in poor universality of the prediction model and insufficient real-time evaluation and early warning mechanism. Summary of the invention
[0005] In order to solve the problems of poor universality of prediction models, insufficient implementation of evaluation and early warning mechanisms, etc. in the above-mentioned prior art research on early warning of corrosion risks of multiphase flow underground pipelines. The present invention proposes an early warning method for urban lifeline pipeline corrosion risks based on digital twins, which realizes real-time graded early warning and remaining life prediction of multiphase flow underground pipeline corrosion risks by establishing a highly digitalized multiphase flow underground pipeline state parameter perception acquisition module and integrating physical space, numerical space and artificial intelligence algorithms.
[0006] The present invention is achieved through the following technical solution: comprising the following steps:
[0007] S1. Obtain the internal operation parameters of the pipeline, the external environmental parameters of the pipeline and the external corrosion rate data according to the monitoring control system and the detection equipment;
[0008] S2. According to the internal operation parameters of the pipeline obtained by the monitoring and control system, an internal corrosion rate prediction model based on digital-physical fusion and physical-guided neural network is constructed;
[0009] S3, constructing an external corrosion rate prediction model based on a particle swarm optimization algorithm and a relevance vector machine according to the pipeline external environment parameters and external corrosion rate data obtained in step S1;
[0010] S4. Completing and time-aligning the pipeline external corrosion rate data according to the spline interpolation method;
[0011] S5. Based on the Wiener process and elastic-plastic fracture mechanics theory, a pipeline corrosion risk classification early warning method is constructed;
[0012] S6. According to steps S1 to S5, a corrosion risk early warning system for the entire service life of underground pipelines based on digital twins is established.
[0013] As a further preference, the specific steps of step S1 are as follows:
[0014] S11, using the pressure sensor, temperature sensor, flow meter and chromatograph to monitor the internal operating parameters of the pipeline, wherein the internal operating parameters of the pipeline include the pressure distribution data along the pipeline {P'1, P'2, ..., P' n}、Temperature distribution data{T'1,T'2,…,T' n}, medium flow data Q, fluid medium components {S1, S2, ..., S n}; The internal operating parameters of the pipeline are collected through the programmable logic controller (PLC) and the conversion between output signals and digital data is completed. The data is processed by the local control station and transmitted to the system server for storage. Finally, the human-machine interface (HMI) is used to link to the system server and SQL Server database for management;
[0015] S12. Obtain pipeline external environmental parameters and external corrosion rate data based on a variety of detection equipment, wherein the pipeline external environmental parameters include anti-corrosion layer damage point density X1, soil pH value X2, soil moisture content X3, redox potential X4, soil resistivity X5, natural potential X6, stray current X7, cathodic protection rate X8, and soil salt content X9;
[0016] S121. According to the Pearson test method, the density X1 of the damaged points of the anti-corrosion layer is obtained;
[0017] S122, adding deionized water to the dried and sieved soil sample and letting it settle, using a pH meter to measure the pH value of the upper clear liquid to obtain the soil pH value X2;
[0018] S123, obtaining soil moisture content X3 according to the drying method;
[0019] S124, obtaining a redox potential X4 according to a depolarization method;
[0020] S125, according to the equidistant four-point method, obtain the soil resistivity X5;
[0021] S126. According to the surface reference method, the natural potential X6 is obtained;
[0022] S127, according to the pipe-to-ground potential forward offset method, measure the forward offset of the pipe-to-ground potential relative to the natural potential to obtain the stray current X7;
[0023] S128, obtaining a protection potential distribution diagram of the entire pipeline according to a close-interval potential detection method, and then calculating the cathodic protection rate to obtain a cathodic protection rate X8;
[0024] S129, determining the total amount of soluble salt in the soil according to the dry residue weighing method to obtain the soil salt content X9;
[0025] S1210. According to the ultrasonic detection method, the signal reflected from the outer wall of the pipeline is received, and the corrosion depth of the outer wall of the pipeline is obtained through data processing, thereby obtaining the external corrosion rate data X of the pipeline section.
[0026] As a further preference, the specific steps of step S2 are as follows:
[0027] S21. According to the internal operation parameters of the pipeline obtained by the monitoring and control system, a fluid dynamics simulation model integrating mathematics and physics is established to obtain H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, and liquid flow rate M5;
[0028] S211. According to the fluid medium component information, pipe section inlet and outlet temperature, pressure and flow information and pipeline parameter information monitored by the monitoring and control system, a physical space based on the monitoring and control system and the scaled-down test is constructed, a pipe section scaled-down test is established, and a laser Doppler flowmeter LDV and an electrochemical workstation are used in the test to obtain the wall shear stress τ and the corrosion rate M in the pipeline respectively;
[0029] S212, based on the fluid characteristics monitored by the monitoring and control system, the temperature, pressure and flow rate at the inlet and outlet of the pipe section, combined with the pipeline parameter information, preset the wall shear stress as the pipe wall boundary condition, construct a numerical space based on the multiphase flow simulation software OLGA, and establish a numerical simulation model of the pipe section;
[0030] S213, according to the pressure distribution data {P'1, P'2, ..., P' along the pipeline in the physical space obtained in step S11 n}、Temperature distribution data{T'1,T'2,…,T' n} and the wall shear stress τ obtained in step S211, establish the interaction between the physical space and the numerical space, and modify the preset maximum number of iterations N and the wall shear stress τ in the numerical space;
[0031] S214, using genetic algorithm GA to optimize the preset parameters in the numerical space, the target fitness function f k The formula is as follows:
[0032]
[0033] f k =ω1RMSE 1k +ω2RMSE 2k
[0034] Where: n is the total number of monitoring points in the monitoring and control system; P ik is the pressure value in the numerical space at the kth iteration at the ith measuring point; P' i is the pressure value monitored at the i-th measuring point in the physical space monitoring and control system; T ik is the temperature value in the numerical space at the kth iteration at the ith measuring point; T' i is the temperature value monitored at the i-th measuring point in the physical space monitoring and control system; RMSE 1k is the root mean square error between the pressure values in the numerical space and the physical space at the kth iteration; RMSE 2k is the root mean square error between the temperature values in the numerical space and the physical space at the kth iteration; f k is the objective function value at the kth iteration; ω1 and ω2 are weights;
[0035] S215, using the optimal parameters corrected in step S214 to perform fluid dynamics simulation of the multiphase flow pipe section, and obtaining data on factors affecting internal corrosion, including H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, and liquid flow rate M5;
[0036] S22, construct a pipeline internal corrosion rate prediction model based on the physical guided neural network PGNN, and perform data preprocessing on the H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, liquid flow rate M5, corrosion inhibitor injection amount M6 obtained through investigation, and pipeline internal corrosion rate M obtained in step S21, divide them into training set and test set, and add the physical loss term to the loss function, the formula is as follows:
[0037]
[0038] Where: ΔPHY is the physical difference term; n is the total number of samples; M i is the predicted value of the internal corrosion rate of the model on the i-th sample; M' i is the predicted value of the internal corrosion rate of the model on the i-th sample after the modified features; is the actual internal corrosion rate on the i-th sample; λ is the weight of the physical loss term;
[0039] The pipeline internal corrosion rate prediction model based on the physics-guided neural network PGNN was trained and tested, and an internal corrosion rate prediction model based on digital-physics fusion and physics-guided neural network was obtained.
[0040] As a further preference, the specific steps of step S3 are as follows:
[0041] S31, randomly selecting several groups of pipeline external environmental parameters {X1, X2, ..., X9} and corresponding external corrosion rate data X obtained in step S12 and performing data preprocessing as a data set, and dividing it into a training set and a test set;
[0042] S32, selecting Gaussian radial basis function RBF as the kernel function, constructing an RVM regression model, and setting the initial hyperparameter α and kernel function parameter g, and performing preliminary training on the RVM regression model;
[0043] S33, using the particle swarm optimization algorithm PSO, selecting the root mean square error RMSE as the fitness function to optimize the hyperparameter α and the kernel function parameter g;
[0044] S34, select the optimal hyperparameter α and kernel function parameter g to build the RVM model, and use the training set and test set obtained in step S31 to train and test the model, and obtain an external corrosion rate prediction model based on the particle swarm optimization algorithm and the relevance vector machine.
[0045] As a further preference, the specific steps of step S4 are as follows:
[0046] S41. Using Python and its built-in SciPy library, combined with the principle of spline interpolation, write a program that can solve the spline interpolation function and output the corresponding interpolation value, and can automatically update the spline interpolation function according to new data points;
[0047] S42, using the pipeline external environmental parameters {X1, X2, ..., X9} obtained in step S12 as input data, and using the external corrosion rate prediction model based on particle swarm optimization algorithm and relevance vector machine established in step S3 to obtain a number of external corrosion rate data points of the pipe section, forming an external corrosion rate data set {t1:v1, t2:v2, ..., t n :v n};
[0048] S43. Use the spline interpolation method to solve the program, take the external corrosion rate data set of step S42 as the program input, and use the monitoring sampling frequency of the monitoring control system of the same pipe section in step S1 as the standard, and use spline interpolation to complete the time alignment of the internal corrosion rate V1 and the external corrosion rate V2 of the pipe section to form a database of the synergistic effect of the internal corrosion rate and the external corrosion rate.
[0049] As a further preference, the specific steps of step S5 are as follows:
[0050] S51, according to the formula X(t) = X(0) + X(t-1)e -λt +σB(t), formula Y(t)=X(t)+ε=X(0)+X(t-1)e -λt +σB(t)+ε and the formula Construct a nonlinear Wiener corrosion degradation model for underground pipelines with multiphase flow.
[0051] Where: X(t) is the actual performance degradation index; Y(t) is the predicted performance degradation index; λ is the drift coefficient, which characterizes the degradation rate of the pipeline; σ is the diffusion coefficient; B(t) represents the standard Brownian motion; e -λt represents the nonlinear characteristics of the system; ε is the error term; d t is the corrosion depth of the pipeline at time t; d0 is the initial wall thickness of the pipeline;
[0052] S52: Corrosion depth d of the pipe section according to the database of the synergistic effect of the internal corrosion rate and the external corrosion rate obtained in step S43 t Calculate and obtain several corrosion depths d t , the formula is as follows:
[0053]
[0054] Where: V1 is the internal corrosion rate of a pipe section; V2 is the external corrosion rate of a pipe section;
[0055] S53, using the extended Kalman filter algorithm EKF to update the parameters, with the corrosion depths d obtained in step S52 t As input, the drift coefficient η and diffusion coefficient σ in the nonlinear Wiener degradation model are iteratively updated to construct the corrosion degradation model of the pipe section;
[0056] S54, predict the remaining life of the pipe section according to the formula T = inf{t:X(t)>ω, t≥0}, where ω is the failure threshold;
[0057] S55. Construct corrosion risk classification warning for pipe sections:
[0058] The performance degradation index under the maximum allowable corrosion depth is taken as the starting point of the failure stage, and the performance degradation index corresponding to 20% of the maximum allowable corrosion depth is taken as the end point of the normal operation stage and the starting point of the degradation stage. The corrosion risk of the pipe section in the normal operation stage is 1, and no maintenance measures may be taken depending on the specific situation. The corrosion risk of the pipe section in the degradation stage is 2, and certain maintenance measures need to be taken to slow down the degradation rate of the pipe section. The corrosion risk of the pipe section in the failure stage is 3, and necessary maintenance measures must be taken to ensure the normal operation of the pipe section.
[0059] S56. According to the SHAP algorithm, the average absolute SHAP value of each feature used as input in the internal corrosion rate prediction model based on mathematical-physical fusion and physics-guided neural network constructed in step S2 and the external corrosion rate prediction model based on particle swarm optimization algorithm and relevance vector machine constructed in step S3 is obtained.
[0060] As a further preferred embodiment, the specific steps of step S6 are as follows:
[0061] S61, establishing a pipeline state parameter perception and acquisition module;
[0062] S611. Based on the Internet of Things technology and cloud computing, and with the help of data analysis and visualization tools, a digital detection system for external corrosion data of multiphase underground pipelines is constructed to monitor, analyze and generate reports for pipeline external corrosion detection data, and realize the digitization and onlineization of detection data and the automation of data processing;
[0063] S612, establishing an API interface between the digital detection system and the monitoring and control system to achieve data resource sharing between the two, and establishing a pipeline state parameter perception and acquisition module;
[0064] S62, deploy the internal corrosion rate prediction model based on digital-physical fusion and physics-guided neural network constructed in step S2 and the external corrosion rate prediction model based on particle swarm optimization algorithm and relevance vector machine constructed in step S3 to the cloud, and transmit the monitoring and detection data of the pipeline state parameter perception acquisition module to the model interface in combination with the message queue, and set up an automated data preprocessing process to build a corrosion rate reasoning prediction module;
[0065] S63, after the cloud prediction results are output, two post-processing modules are added, one post-processing module performs spline interpolation on the external corrosion rate output at a low frequency, and stores the prediction results of the internal corrosion rate and the external corrosion rate with the same frequency in the cloud database, and the other post-processing module uses the SHAP algorithm to calculate the average absolute SHAP value of each input feature, and stores it in the cloud database accordingly;
[0066] S64, establishing a historical cumulative corrosion depth calculation module, and using the PyMySQL database connection library to configure database connection parameters, establishing a connection with a cloud database and performing calculation processing;
[0067] S65, construct a maximum corrosion depth calculation module for the pipe segment, and integrate it into the corrosion risk classification warning module, call the historical cumulative corrosion depth to calculate the performance degradation index, and calculate the corrosion risk level and the remaining service life of the current pipe segment according to the risk warning principle and degradation model in step S5;
[0068] S66. Use the WebSocket protocol to establish a two-way communication channel between the server and the cloud data and front end, and push the predicted values of internal and external corrosion rates, corrosion depth values, average absolute SHAP values of each input feature, remaining service life of the pipe segment, and corrosion risk level of the pipe segment corresponding to different pipe segments at different times to the front end.
[0069] Compared with the prior art, the present invention has the following beneficial effects:
[0070] 1. The present invention constructs a sensing acquisition module for the state parameters of multiphase underground pipelines, and combines the fusion technology of physical space, numerical space and artificial intelligence to establish a more accurate internal and external corrosion rate prediction model based on the corrosion mechanism. It improves the universality and accuracy of the prediction model, not only enhances the adaptability of the model to a variety of environments and working conditions, but also significantly improves the accuracy of corrosion risk prediction, overcoming the problem of inconsistent effects of existing models when applied in different scenarios.
[0071] 2. The present invention adopts nonlinear Wiener process and elastic-plastic fracture mechanics theory to develop a real-time early warning mechanism for risk based on corrosion depth and establishes a method for predicting remaining life. This early warning mechanism can monitor corrosion risks online and classify them in real time, realizing real-time corrosion risk early warning and remaining life prediction for multiphase flow underground pipeline sections, thus providing a dynamic and active management means for pipeline repair and maintenance.
[0072] 3. The present invention is of great significance for the detection, repair and maintenance of multiphase flow underground pipelines under the risk of corrosion, and also provides ideas for the digital and intelligent management of multiphase flow underground pipelines. BRIEF DESCRIPTION OF THE DRAWINGS
[0073] Figure 1 It is an overall flow chart of the early warning method of the present invention.
[0074] Figure 2 The present invention is a flowchart for constructing an internal corrosion rate prediction model based on digital-physical fusion and physically guided neural network. DETAILED DESCRIPTION
[0075] Advantages and features of the present invention will be illustrated and explained by the following non-limiting description of preferred embodiments thereof, which are given by way of example only with reference to the accompanying drawings.
[0076] like Figure 1 and 2 As shown, the present invention proposes a corrosion risk warning method for urban lifeline pipelines based on digital twins. The method takes digital twins as the core, and establishes an internal and external corrosion rate prediction model of multiphase flow underground pipelines and a pipeline corrosion degradation model by integrating physical space, numerical space and artificial intelligence. It can perform real-time corrosion risk warning and remaining life prediction for different multiphase flow underground pipeline sections, and provide a dynamic and active management means for pipeline maintenance and maintenance. Specifically, the method includes the following steps:
[0077] S1. According to the monitoring control system and detection equipment, the internal operating parameters of the pipeline, the external environmental parameters of the pipeline and the external corrosion rate data are obtained.
[0078] S11, using the pressure sensor, temperature sensor, flow meter and chromatograph to monitor the internal operating parameters of the pipeline, wherein the internal operating parameters of the pipeline include the pressure distribution data along the pipeline {P'1, P'2, ..., P' n}、Temperature distribution data{T'1,T'2,…,T' n}, medium flow data Q, fluid medium components {S1, S2, ..., S nThe internal operating parameters of the pipeline are collected through the programmable logic controller (PLC) and the conversion between output signals and digital data is completed. The data is processed by the local control station and transmitted to the system server for storage. Finally, the human-machine interface (HMI) is used to link to the system server and SQL Server database for management.
[0079] S12. According to a variety of detection equipment, the external environmental parameters of the pipeline and the external corrosion rate data are obtained. The external environmental parameters of the pipeline include the density of damage points of the anti-corrosion layer X1, soil pH value X2, soil moisture content X3, redox potential X4, soil resistivity X5, natural potential X6, stray current X7, cathodic protection rate X8 and soil salinity X9.
[0080] S121. According to the Pearson detection method, the position of the damaged point is determined by using the voltage difference at the damaged point and then calculated to obtain the density X1 of the damaged point of the anti-corrosion layer.
[0081] S122. Add deionized water to the dried and sieved soil sample and let it settle. Use a pH meter to measure the pH value of the upper clear liquid to obtain the soil pH value X2.
[0082] S123. According to the drying method, the soil moisture content X3 is obtained.
[0083] S124. According to the depolarization method, read the potential value of the oxidation-reduction potential meter and convert it to obtain the oxidation-reduction potential X4.
[0084] S125. According to the equidistant four-point method, resistivity is calculated using potential difference and test current to obtain soil resistivity X5.
[0085] S126. According to the ground reference method, use a digital multimeter to measure the potential and obtain the natural potential X6.
[0086] S127. According to the pipe-to-ground potential forward offset method, measure the forward offset of the pipe-to-ground potential relative to the natural potential to obtain the stray current X7.
[0087] S128. Obtain the protection potential distribution diagram of the entire pipeline according to the close-interval potential detection method, and then calculate the cathodic protection rate to obtain the cathodic protection rate X8.
[0088] S129. Determine the total amount of soluble salt in the soil using the dry residue weighing method to obtain the soil salt content X9.
[0089] S1210. According to the ultrasonic detection method, the signal reflected from the outer wall of the pipeline is received, and the corrosion depth of the outer wall of the pipeline is obtained through data processing, thereby obtaining the external corrosion rate data X of the pipeline section.
[0090] This step is mainly aimed at underground pipelines with multiphase flow characteristics such as oil and gas gathering and transportation pipelines, drainage and sewage pipelines in urban lifelines, to sense and obtain the state parameters of urban underground pipelines.
[0091] Firstly, the Supervisory Control And Data Acquisition (SCADA) system is used to sense and acquire the internal operating parameters of the pipeline in real time. The output signals of the on-site physical monitoring equipment such as pressure sensors, temperature sensors, flow meters and chromatographs are collected through the programmable logic controller (PLC) and the conversion between the output signals and digital data is completed. Then, the pressure distribution data {P'1, P'2, ..., P' n}、Temperature distribution data{T'1,T'2,…,T' n}, medium flow data Q, fluid medium components {S1, S2, ..., S n The data and contents of each component are processed by the local control station and transmitted to the system server for storage. Finally, the human-machine interface HMI is used to link to the system server and SQL Server database for management, thus achieving real-time perception of the internal operating parameters of the pipeline.
[0092] Secondly, a variety of detection equipment is used to sense and obtain the external environmental parameters and external corrosion rate data of the pipeline. The external environmental parameters of the pipeline detected in the present invention include the density of the damaged points of the anti-corrosion layer X1, the soil pH value X2, the soil moisture content X3, the redox potential X4, the soil resistivity X5, the natural potential X6, the stray current X7, the cathode protection rate X8, and the soil salt content X9. The corresponding detection methods are Pearson detection method, pH meter measurement method, drying method, depolarization method, equidistant four-point method, surface reference method, pipe-to-ground potential forward offset method, close interval potential detection method, and dry slag weighing method. The external corrosion rate data X is indirectly detected by ultrasonic detection method.
[0093] S2. According to the internal operating parameters of the pipeline obtained by the monitoring and control system, an internal corrosion rate prediction model based on digital-physical fusion and physics-guided neural network is constructed.
[0094] S21. According to the internal operating parameters of the pipeline obtained by the monitoring and control system, a fluid dynamics simulation model integrating mathematics and physics is established to obtain the H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, and liquid flow rate M5.
[0095] S211. Based on the fluid medium component information, pipe section inlet and outlet temperatures, pressure and flow information, and pipeline parameter information monitored by the monitoring and control system, a physical space based on the monitoring and control system and the scaled-down test is constructed, a pipe section scaled-down test is established, and a laser Doppler flowmeter LDV and an electrochemical workstation are used in the test to obtain the wall shear stress τ and the corrosion rate M in the pipeline, respectively.
[0096] S212. Based on the fluid characteristics monitored by the monitoring and control system, the temperature, pressure and flow rate at the inlet and outlet of the pipe section, combined with the pipeline parameter information, the wall shear stress is preset as the pipe wall boundary condition, and a numerical space based on the multiphase flow simulation software OLGA is constructed to establish a numerical simulation model of the pipe section.
[0097] S213, according to the pressure distribution data {P'1, P'2, ..., P' along the pipeline in the physical space obtained in step S11 n}、Temperature distribution data{T'1,T'2,…,T' n} and the wall shear stress τ obtained in step S211, establish the interaction between the physical space and the numerical space, and correct the preset maximum number of iterations N and the wall shear stress τ in the numerical space.
[0098] S214, using genetic algorithm GA to optimize the preset parameters in the numerical space, the target fitness function f k The formula is as follows:
[0099]
[0100] f k =ω1RMSE 1k +ω2RMSE 2k
[0101] Where: n is the total number of monitoring points in the monitoring and control system; P ik is the pressure value in the numerical space at the kth iteration at the ith measuring point; P' i is the pressure value monitored at the i-th measuring point in the physical space monitoring and control system; T ik is the temperature value in the numerical space at the kth iteration at the ith measuring point; T' i is the temperature value monitored at the i-th measuring point in the physical space monitoring and control system; RMSE 1k is the root mean square error between the pressure values in the numerical space and the physical space at the kth iteration; RMSE 2k is the root mean square error between the temperature values in the numerical space and the physical space at the kth iteration; f k is the objective function value at the kth iteration; ω1 and ω2 are weights, both of which are 0.5.
[0102] S215, using the optimal parameters corrected in step S214 to perform fluid dynamics simulation of the multiphase flow pipe section, to obtain data on factors affecting internal corrosion, including H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4 and liquid flow rate M5.
[0103] S22, construct a pipeline internal corrosion rate prediction model based on the physical guided neural network PGNN, and pre-process the H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, liquid flow rate M5, corrosion inhibitor injection amount M6 obtained through investigation, and pipeline internal corrosion rate M obtained in step S21, and divide them into training set and test set in a ratio of 7:3, and add the physical loss term to the loss function. The formula is as follows:
[0104]
[0105] Where: ΔPHY is the physical difference term; n is the total number of samples; M i is the predicted value of the internal corrosion rate of the model on the i-th sample; M' i is the predicted value of the internal corrosion rate of the model on the i-th sample after the modified features; is the actual internal corrosion rate of the i-th sample; λ is the weight of the physical loss term.
[0106] The pipeline internal corrosion rate prediction model based on the physics-guided neural network PGNN was trained and tested, and an internal corrosion rate prediction model based on digital-physics fusion and physics-guided neural network was obtained.
[0107] like Figure 2 As shown in FIG. 1 , it is a flow chart of the construction of the internal corrosion rate prediction model based on digital-physical fusion and physics-guided neural network of the present invention. First, a fluid dynamics simulation method of digital-physical fusion is established: the first step is to construct a physical space based on the monitoring control system and the scaled test, and the scaled test of the pipe section is established based on the fluid medium component information, the inlet and outlet temperature, pressure and flow information of the pipe section and the pipeline parameter information monitored by the monitoring control system, and the laser Doppler flowmeter LDV and the electrochemical workstation are used in the test to respectively measure the wall shear stress τ and the internal corrosion rate M of the pipeline; the second step is to construct a numerical space based on the multiphase flow simulation software OLGA, and the wall shear stress is preset as the boundary condition of the pipe wall based on the fluid characteristics monitored by the monitoring control system, the inlet and outlet temperature, pressure and flow of the pipe section, combined with the pipeline parameter information, and the numerical simulation model of the pipe section is established; the third step is to establish the interaction between the physical space and the numerical space, and based on the pressure distribution data {P'1, P'2, ..., P' n}、Temperature distribution data{T'1,T'2,…,T' n} and the wall shear stress τ to modify the preset maximum number of iterations N and the wall shear stress τ in the numerical space; the fourth step is to use the genetic algorithm GA to optimize the preset parameters in the numerical space, and the target fitness function f k ; Finally, the corrected optimal parameters are used to perform fluid dynamics simulation of the multiphase flow pipe section to obtain H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, and liquid flow rate M5.
[0108] Then, a pipeline internal corrosion rate prediction model based on the physical guided neural network PGNN was established. The H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, liquid flow rate M5, the corrosion inhibitor injection amount M6 obtained through investigation, and the pipeline internal corrosion rate M were preprocessed and divided into training set and test set in a ratio of 7:3. The physical loss term was added to the loss function, and the PGNN was trained and tested to complete the establishment of the internal corrosion rate prediction model.
[0109] S3. According to the pipeline external environment parameters and external corrosion rate data obtained in step S1, an external corrosion rate prediction model based on particle swarm optimization algorithm and relevance vector machine is constructed.
[0110] S31, randomly select several groups obtained in step S12, preferably 100 groups of pipeline external environmental parameters {X1, X2, ..., X9} and corresponding external corrosion rate data X, and perform data preprocessing as a data set, and divide it into a training set and a test set in a ratio of 7:3.
[0111] S32. Select Gaussian radial basis function RBF as the kernel function, construct an RVM regression model, set the initial hyperparameter α and kernel function parameter g, and perform preliminary training on the RVM regression model.
[0112] S33. Using the particle swarm optimization algorithm PSO, the root mean square error RMSE is selected as the fitness function to optimize the hyperparameter α and the kernel function parameter g.
[0113] S34, select the optimal hyperparameter α and kernel function parameter g to build the RVM model, and use the training set and test set obtained in step S31 to train and test the model, and obtain an external corrosion rate prediction model based on the particle swarm optimization algorithm and the relevance vector machine.
[0114] This step mainly includes two aspects, one is the construction of the RVM model, and the other is to use the PSO algorithm to optimize the hyperparameters of the RVM model. These two aspects are explained in detail below.
[0115] (1) Construct the RVM model, select the Gaussian radial basis function RBF as the kernel function, and set the initial hyperparameter α and kernel function parameter g. In step S1, 100 sets of external corrosion influencing factor data {X1, X2, …, X9} and the corresponding external corrosion rate data X are randomly selected and preprocessed as the data set. After that, they are divided into a training set and a test set in a ratio of 7:3 to perform preliminary training of the RVM model to obtain the initial prediction performance of the model.
[0116] (2) The PSO algorithm is used to optimize the hyperparameters of the RVM model. The specific steps are as follows: ① Set the PSO algorithm parameters, particle swarm size m = 15, maximum number of iterations g = 6, inertia weight ω = 0.5, individual learning factor c_1 = 0.5, and group learning factor c_2 = 0.5; ② Initialize the particle position and velocity, randomly generate the initial position of the particle within the definition domain of the hyperparameter α and the kernel function parameter g in the RVM model, and randomly generate the initial velocity of the particle within a reasonable range; ③ Define the fitness function to evaluate the performance of the RVM model corresponding to each particle. In this embodiment, the root mean square error RMSE is selected as the fitness function, and the optimization step is repeated. ④ Calculate the fitness value corresponding to each particle in each iteration of the segment; ④ Update the individual optimal and global optimal positions; ⑤ Update the particle speed and position, and update the particle's velocity vector and position vector based on the individual optimal position and the global optimal position, combined with the inertia weight, individual learning and group learning factors and the speed update formula; ⑥ Check the iteration exit condition, if the fitness value of the next iteration is reduced by less than 3% relative to the previous iteration, stop the iteration; ⑦ Output the optimal hyperparameter α and kernel function parameter g, use the optimal parameters to build the RVM model, use the pipeline external corrosion data set established in step S1 to train and test the RVM model, and complete the establishment of the external corrosion rate prediction model.
[0117] S4. Completing and time-aligning the pipeline external corrosion rate data according to the spline interpolation method.
[0118] S41. Using Python and its built-in SciPy library, combined with the principle of spline interpolation, write a program that can solve the spline interpolation function and output the corresponding interpolation value, and can automatically update the spline interpolation function according to new data points.
[0119] S42, using the pipeline external environmental parameters {X1, X2, ..., X9} obtained in step S12 as input data, and using the external corrosion rate prediction model based on particle swarm optimization algorithm and relevance vector machine established in step S3 to obtain a number of external corrosion rate data points of the pipe section, forming an external corrosion rate data set {t1:v1, t2:v2, ..., t n :v n}.
[0120] S43. Use the spline interpolation method to solve the program, take the external corrosion rate data set of step S42 as the program input, and use the monitoring sampling frequency of the monitoring control system of the same pipe section in step S1 as the standard, and use spline interpolation to complete the time alignment of the internal corrosion rate V1 and the external corrosion rate V2 of the pipe section to form a database of the synergistic effect of the internal corrosion rate and the external corrosion rate.
[0121] This step is mainly to overcome the problem of inconsistent sampling frequencies of the monitoring data of the monitoring control system and the detection data of various detection devices in step S1.
[0122] S5. Based on the Wiener process and elastic-plastic fracture mechanics theory, a pipeline corrosion risk classification and early warning method is constructed.
[0123] In this step, the corrosion degradation of multiphase underground pipelines is regarded as a nonlinear Wiener degradation process, a nonlinear Wiener corrosion degradation model is established for the pipeline, and the extended Kalman filter algorithm is used to update the parameters. The specific implementation process is as follows:
[0124] S51, according to the formula X(t) = X(0) + X(t-1)e -λt +σB(t), formula Y(t)=X(t)+ε=X(0)+X(t-1)e -λt +σB(t)+ε and the formula A nonlinear Wiener corrosion degradation model for underground pipelines with multiphase flow is constructed; where: X(t) is the actual performance degradation index; Y(t) is the predicted performance degradation index; λ is the drift coefficient, which characterizes the degradation rate of the pipeline; σ is the diffusion coefficient; B(t) represents the standard Brownian motion; e -λt represents the nonlinear characteristics of the system; ε is the error term, d t is the corrosion depth of the pipeline at time t; d0 is the initial wall thickness of the pipeline.
[0125] The mathematical expression of the real Wiener degradation process of the pipeline is as follows:
[0126] X(t)=X(0)+X(t-1)e -λt +σB(t)
[0127] As shown, it is assumed that the error term ε between the predicted degradation state and the actual degradation state at any time has a mean of 0 and a variance of The normal distribution of the pipeline section corrosion degradation model is as follows:
[0128] Y(t)=X(t)+ε=X(0)+t(t-1)e -λt +σB(t)+ε
[0129] As shown, the wall thickness degradation is selected as the performance degradation index and its expression is as follows:
[0130]
[0131] shown.
[0132] S52: Corrosion depth d of the pipe section according to the database of the synergistic effect of the internal corrosion rate and the external corrosion rate obtained in step S43 t Calculate and obtain several corrosion depths d t , the formula is as follows:
[0133]
[0134] Wherein: V1 is the internal corrosion rate of a certain pipe section; V2 is the external corrosion rate of a certain pipe section, both of which are obtained in step S43.
[0135] S53, using the extended Kalman filter algorithm EKF to update the parameters, with the corrosion depths d obtained in step S52 t As input, the drift coefficient η and diffusion coefficient σ in the nonlinear Wiener degradation model are iteratively updated to construct the corrosion degradation model of the pipeline section.
[0136] S54. Predict the remaining life of the pipe section according to the formula T=inf{t:X(t)>ω,t≥0}, where ω is the failure threshold.
[0137] Based on the elastic-plastic fracture mechanics theory, according to the limit state operating pressure p of the pipeline max , Matlab is used to iteratively calculate the maximum allowable corrosion depth of the pipe section, and the performance degradation index at the maximum allowable corrosion depth is used as the failure threshold ω of the pipe section. The expression of the remaining life is as follows:
[0138] T=inf{t:X(t)>ω,t≥0}
[0139] Where ω is the failure threshold, which is determined by the maximum allowable corrosion depth of the pipe section.
[0140] S55. Construct corrosion risk classification warning for pipe sections:
[0141] The performance degradation index under the maximum allowable corrosion depth is taken as the starting point of the failure stage, and the performance degradation index corresponding to 20% of the maximum allowable corrosion depth is taken as the end point of the normal operation stage and the starting point of the degradation stage. The corrosion risk of the pipe section in the normal operation stage is 1, and no maintenance measures may be taken depending on the specific situation. The corrosion risk of the pipe section in the degradation stage is 2, and certain maintenance measures need to be taken to slow down the degradation rate of the pipe section. The corrosion risk of the pipe section in the failure stage is 3, and necessary maintenance measures must be taken to ensure the normal operation of the pipe section.
[0142] S56. According to the SHAP algorithm, the average absolute SHAP value of each feature used as input in the internal corrosion rate prediction model based on mathematical-physical fusion and physics-guided neural network constructed in step S2 and the external corrosion rate prediction model based on particle swarm optimization algorithm and relevance vector machine constructed in step S3 is obtained.
[0143] The SHAP algorithm is applied to the internal corrosion rate prediction model and the external corrosion rate prediction model established in step S2 and step S3, respectively. During the prediction, the average marginal contribution of each input feature in all feature sequences, that is, the average absolute SHAP value, is calculated to characterize the importance of each corrosion influencing factor feature and explain the mechanism of the effect of each corrosion influencing factor feature in each sample on the prediction result, so as to guide the detection, repair and maintenance of multiphase flow underground pipelines, making the repair and maintenance strategies more scientific and reasonable.
[0144] S6. According to steps S1 to S5, a corrosion risk early warning system for the entire service life of underground pipelines based on digital twins is established.
[0145] S61. Establish a pipeline state parameter perception and acquisition module.
[0146] S611. Based on the Internet of Things technology and cloud computing, and with the help of data analysis and visualization tools, a digital detection system for the external corrosion data of multiphase underground pipelines is constructed to monitor, analyze and generate reports on the external corrosion detection data of pipelines, thereby realizing the digitization and onlineization of detection data and the automation of data processing.
[0147] S612. Establish an API interface between the digital detection system and the monitoring and control system to achieve data resource sharing between the two and establish a pipeline state parameter perception and acquisition module.
[0148] The perception and acquisition of pipeline state parameters are mainly divided into two parts. The first is to digitize the internal operation parameters of the pipeline monitored by the monitoring and control system, the external environmental parameters of the pipeline detected by various detection equipment, and the external corrosion rate data; the second is to connect the monitoring and control system with various detection equipment. It can be seen that the main steps to establish the pipeline state parameter perception and acquisition module are as follows: ① Based on the Internet of Things technology and cloud computing, and with the help of data analysis and visualization tools, a digital detection system for the external corrosion data of multiphase underground pipelines is constructed to monitor, analyze and generate reports for the external corrosion detection data of pipelines, and realize the digitization, onlineization and automation of data processing of detection data; ② Establish an API interface between the digital detection system and the SCADA system to realize data resource sharing between the two, and then establish a pipeline state parameter perception and acquisition module containing the internal operation monitoring data of the pipeline and the external corrosion detection data.
[0149] S62. Deploy the internal corrosion rate prediction model based on digital-physical fusion and physics-guided neural network constructed in step S2 and the external corrosion rate prediction model based on particle swarm optimization algorithm and correlation vector machine constructed in step S3 to the cloud, and combine with the message queue to transmit the monitoring and detection data of the pipeline state parameter perception acquisition module to the model interface, set up an automated data preprocessing process, and build a corrosion rate reasoning prediction module.
[0150] This step enables the prediction model to receive perception data in real time and make inference predictions.
[0151] S63. After the prediction results are output on the cloud, two post-processing modules are added. One post-processing module performs spline interpolation on the external corrosion rate output at a low frequency, and stores the prediction results of the internal corrosion rate and the external corrosion rate with the same frequency in the cloud database. The other post-processing module uses the SHAP algorithm to calculate the average absolute SHAP value of each input feature, and stores it in the cloud database accordingly.
[0152] S64. Establish a historical cumulative corrosion depth calculation module, and use the PyMySQL database connection library to configure database connection parameters, establish a connection with the cloud database and perform calculation processing.
[0153] S65. Construct a maximum corrosion depth calculation module for the pipe segment and integrate it into the corrosion risk classification warning module. Call the historical cumulative corrosion depth to calculate the performance degradation index and calculate the corrosion risk level and the remaining service life of the current pipe segment according to the risk warning principle and degradation model in step S5.
[0154] S66. Use the WebSocket protocol to establish a two-way communication channel between the server and the cloud data and front end, and push the predicted values of internal and external corrosion rates, corrosion depth values, average absolute SHAP values of each input feature, remaining service life of the pipe segment, and corrosion risk level of the pipe segment corresponding to different pipe segments at different times to the front end.
[0155] Through the above six steps, a digital twin-based urban lifeline pipeline corrosion risk early warning system is constructed to achieve high automation, digitization and online operations from data collection to corrosion risk classification for different pipe sections, thereby guiding the detection, repair and maintenance of multiphase flow underground pipelines under corrosion risks.
[0156] In addition to the above embodiments, the present invention may also have other implementation modes. Any technical solutions formed by equivalent replacement or equivalent transformation shall fall within the protection scope required by the present invention.
Claims
1. A digital twin-based urban lifeline pipeline corrosion risk early warning method, characterized by: The following steps are included: S1. Obtain the internal operation parameters of the pipeline, the external environmental parameters of the pipeline and the external corrosion rate data according to the monitoring control system and the detection equipment; S2. According to the internal operation parameters of the pipeline obtained by the monitoring and control system, an internal corrosion rate prediction model based on digital-physical fusion and physical-guided neural network is constructed; S3, constructing an external corrosion rate prediction model based on a particle swarm optimization algorithm and a relevance vector machine according to the pipeline external environment parameters and external corrosion rate data obtained in step S1; S4. Completing and time-aligning the pipeline external corrosion rate data according to the spline interpolation method; S5. Based on the Wiener process and elastic-plastic fracture mechanics theory, a pipeline corrosion risk classification early warning method is constructed; S6. According to steps S1 to S5, a corrosion risk early warning system for the entire service life of underground pipelines based on digital twins is established.
2. The urban lifeline pipeline corrosion risk early warning method based on digital twin according to claim 1 is characterized by: The specific steps of step S1 are as follows: S11, using the pressure sensor, temperature sensor, flow meter and chromatograph to monitor the internal operating parameters of the pipeline, wherein the internal operating parameters of the pipeline include the pressure distribution data along the pipeline {P'1, P'2, ..., P' n }、Temperature distribution data{T'1,T'2,…,T' n }, medium flow data Q, fluid medium components {S1, S2, ..., S n }; The internal operating parameters of the pipeline are collected through the programmable logic controller (PLC) and the conversion between output signals and digital data is completed. The data is processed by the local control station and transmitted to the system server for storage. Finally, the human-machine interface (HMI) is used to link to the system server and SQL Server database for management; S12. Obtain pipeline external environmental parameters and external corrosion rate data based on a variety of detection equipment, wherein the pipeline external environmental parameters include anti-corrosion layer damage point density X1, soil pH value X2, soil moisture content X3, redox potential X4, soil resistivity X5, natural potential X6, stray current X7, cathodic protection rate X8, and soil salt content X9; S121. According to the Pearson test method, the density X1 of the damaged points of the anti-corrosion layer is obtained; S122, adding deionized water to the dried and sieved soil sample and letting it settle, using a pH meter to measure the pH value of the upper clear liquid to obtain the soil pH value X2; S123, obtaining soil moisture content X3 according to the drying method; S124, obtaining a redox potential X4 according to a depolarization method; S125, according to the equidistant four-point method, obtain the soil resistivity X5; S126. According to the surface reference method, the natural potential X6 is obtained; S1 27. According to the pipe-to-ground potential forward offset method, measure the forward offset of the pipe-to-ground potential relative to the natural potential to obtain the stray current X7; S128, obtaining a protection potential distribution diagram of the entire pipeline according to a close-interval potential detection method, and then calculating the cathodic protection rate to obtain a cathodic protection rate X8; S129, determining the total amount of soluble salt in the soil according to the dry residue weighing method to obtain the soil salt content X9; S1210. According to the ultrasonic detection method, the signal reflected from the outer wall of the pipeline is received, and the corrosion depth of the outer wall of the pipeline is obtained through data processing, thereby obtaining the external corrosion rate data X of the pipeline section.
3. The urban lifeline pipeline corrosion risk early warning method based on digital twin according to claim 2 is characterized by: The specific steps of step S2 are as follows: S21. According to the internal operating parameters of the pipeline obtained by the monitoring and control system, a fluid dynamics simulation model integrating mathematics and physics is established to obtain H2s partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, and liquid flow rate M5; S211. According to the fluid medium component information, pipe section inlet and outlet temperature, pressure and flow information and pipeline parameter information monitored by the monitoring and control system, a physical space based on the monitoring and control system and the scaled-down test is constructed, a pipe section scaled-down test is established, and a laser Doppler flowmeter LDV and an electrochemical workstation are used in the test to obtain the wall shear stress τ and the corrosion rate M in the pipeline respectively; S212, based on the fluid characteristics monitored by the monitoring and control system, the temperature, pressure and flow rate at the inlet and outlet of the pipe section, combined with the pipeline parameter information, preset the wall shear stress as the pipe wall boundary condition, construct a numerical space based on the multiphase flow simulation software OLGA, and establish a numerical simulation model of the pipe section; S213, according to the pressure distribution data {P'1, P'2, ..., P' along the pipeline in the physical space obtained in step S11 n }、Temperature distribution data{T'1,T'2,…,T' n } and the wall shear stress τ obtained in step S211, establish the interaction between the physical space and the numerical space, and modify the preset maximum number of iterations N and the wall shear stress τ in the numerical space; S214, using genetic algorithm GA to optimize the preset parameters in the numerical space, the target fitness function f k The formula is as follows: f k =ω1RMSE 1k +ω2RMSE 2k Where: n is the total number of monitoring points in the monitoring and control system; P ik is the pressure value in the numerical space at the kth iteration at the ith measuring point; P' i is the pressure value monitored at the i-th measuring point in the physical space monitoring and control system; T ik is the temperature value in the numerical space at the kth iteration at the ith measuring point; T' i is the temperature value monitored at the i-th measuring point in the physical space monitoring and control system; RMSE 1k is the root mean square error between the pressure values in the numerical space and the physical space at the kth iteration; RMSE 2k is the root mean square error between the temperature values in the numerical space and the physical space at the kth iteration; f k is the objective function value at the kth iteration; ω1 and ω2 are weights; S215, using the optimal parameters corrected in step S214 to perform fluid dynamics simulation of the multiphase flow pipe section, and obtaining data on factors affecting internal corrosion, including H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, and liquid flow rate M5; S22, construct a pipeline internal corrosion rate prediction model based on the physical guided neural network PGNN, and perform data preprocessing on the H2S partial pressure M1, CO2 partial pressure M2, temperature M3, pH value M4, liquid flow rate M5, corrosion inhibitor injection amount M6 obtained through investigation, and pipeline internal corrosion rate M obtained in step S21, divide them into training set and test set, and add the physical loss term to the loss function, the formula is as follows: Where: ΔPHY is the physical difference term; n is the total number of samples; M i is the predicted value of the internal corrosion rate of the model on the i-th sample; M' i is the predicted value of the internal corrosion rate of the model on the i-th sample after the modified features; is the actual internal corrosion rate on the i-th sample; λ is the weight of the physical loss term; The pipeline internal corrosion rate prediction model based on the physics-guided neural network PGNN was trained and tested, and an internal corrosion rate prediction model based on digital-physics fusion and physics-guided neural network was obtained.
4. The urban lifeline pipeline corrosion risk early warning method based on digital twin according to claim 3 is characterized by: The specific steps of step S3 are as follows: S31, randomly selecting several groups of pipeline external environmental parameters {X1, X2, ..., X9} and corresponding external corrosion rate data X obtained in step S12 and performing data preprocessing as a data set, and dividing it into a training set and a test set; S32, selecting Gaussian radial basis function RBF as the kernel function, constructing an RVM regression model, and setting the initial hyperparameter α and kernel function parameter g, and performing preliminary training on the RVM regression model; S33, using the particle swarm optimization algorithm PSO, selecting the root mean square error RMSE as the fitness function to optimize the hyperparameter α and the kernel function parameter g; S34, select the optimal hyperparameter α and kernel function parameter g to build the RVM model, and use the training set and test set obtained in step S31 to train and test the model, and obtain an external corrosion rate prediction model based on the particle swarm optimization algorithm and the relevance vector machine.
5. The urban lifeline pipeline corrosion risk early warning method based on digital twin according to claim 4 is characterized by: The specific steps of step S4 are as follows: S41. Using Python and its built-in SciPy library, combined with the principle of spline interpolation, write a program that can solve the spline interpolation function and output the corresponding interpolation value, and can automatically update the spline interpolation function according to new data points; S42, using the pipeline external environmental parameters {X1, X2, ..., X9} obtained in step S12 as input data, and using the external corrosion rate prediction model based on particle swarm optimization algorithm and relevance vector machine established in step S3 to obtain a number of external corrosion rate data points of the pipe section, forming an external corrosion rate data set {t1:v1, t2:v2, ..., t n :v n }; S43. Use the spline interpolation method to solve the program, take the external corrosion rate data set of step S42 as the program input, and use the monitoring sampling frequency of the monitoring control system of the same pipe section in step S1 as the standard, and use spline interpolation to complete the time alignment of the internal corrosion rate V1 and the external corrosion rate V2 of the pipe section to form a database of the synergistic effect of the internal corrosion rate and the external corrosion rate.
6. The urban lifeline pipeline corrosion risk early warning method based on digital twin according to claim 5 is characterized by: The specific steps of step S5 are as follows: S51, according to the formula X(t) = X(0) + X(t-1)e -λt +σB(t), formula Y(t)=X(t)+ε=X(0)+X(t-1)e -λt +σB(t)+ε and the formula Construct a nonlinear Wiener corrosion degradation model for underground pipelines with multiphase flow; Where: X(t) is the actual performance degradation index; Y(t) is the predicted performance degradation index; λ is the drift coefficient, which characterizes the degradation rate of the pipeline; σ is the diffusion coefficient; B(t) represents the standard Brownian motion; e -λt Represents the nonlinear characteristics of the system; ε is the error term; d t is the corrosion depth of the pipeline at time t; d0 is the initial wall thickness of the pipeline; S52: Corrosion depth d of the pipe section according to the database of the synergistic effect of the internal corrosion rate and the external corrosion rate obtained in step S43 t Calculate and obtain several corrosion depths d t , the formula is as follows: Where: V1 is the internal corrosion rate of a pipe section; V2 is the external corrosion rate of a pipe section; S53, using the extended Kalman filter algorithm EKF to update the parameters, with the corrosion depths d obtained in step S52 t As input, the drift coefficient η and diffusion coefficient σ in the nonlinear Wiener degradation model are iteratively updated to construct the corrosion degradation model of the pipe section; S54, predict the remaining life of the pipe section according to the formula T = inf{t:X(t)>ω, t≥0}, where ω is the failure threshold; S55. Construct corrosion risk classification warning for pipe sections: The performance degradation index under the maximum allowable corrosion depth is taken as the starting point of the failure stage, and the performance degradation index corresponding to 20% of the maximum allowable corrosion depth is taken as the end point of the normal operation stage and the starting point of the degradation stage. The corrosion risk of the pipe section in the normal operation stage is 1, and no maintenance measures may be taken depending on the specific situation. The corrosion risk of the pipe section in the degradation stage is 2, and certain maintenance measures need to be taken to slow down the degradation rate of the pipe section. The corrosion risk of the pipe section in the failure stage is 3, and necessary maintenance measures must be taken to ensure the normal operation of the pipe section. S56. According to the SHAP algorithm, the average absolute SHAP value of each feature used as input in the internal corrosion rate prediction model based on mathematical-physical fusion and physics-guided neural network constructed in step S2 and the external corrosion rate prediction model based on particle swarm optimization algorithm and relevance vector machine constructed in step S3 is obtained.
7. The urban lifeline pipeline corrosion risk early warning method based on digital twin according to claim 6 is characterized by: The specific steps of step S6 are as follows: S61, establishing a pipeline state parameter perception and acquisition module; S611. Based on the Internet of Things technology and cloud computing, and with the help of data analysis and visualization tools, a digital detection system for external corrosion data of multiphase underground pipelines is constructed to monitor, analyze and generate reports for pipeline external corrosion detection data, and realize the digitization and onlineization of detection data and the automation of data processing; S612, establishing an API interface between the digital detection system and the monitoring and control system to achieve data resource sharing between the two, and establishing a pipeline state parameter perception and acquisition module; S62, deploy the internal corrosion rate prediction model based on digital-physical fusion and physics-guided neural network constructed in step S2 and the external corrosion rate prediction model based on particle swarm optimization algorithm and relevance vector machine constructed in step S3 to the cloud, and transmit the monitoring and detection data of the pipeline state parameter perception acquisition module to the model interface in combination with the message queue, and set up an automated data preprocessing process to build a corrosion rate reasoning prediction module; S63, after the cloud prediction results are output, two post-processing modules are added, one post-processing module performs spline interpolation on the external corrosion rate output at a low frequency, and stores the prediction results of the internal corrosion rate and the external corrosion rate with the same frequency in the cloud database, and the other post-processing module uses the SHAP algorithm to calculate the average absolute SHAP value of each input feature, and stores it in the cloud database accordingly; S64, establishing a historical cumulative corrosion depth calculation module, and using the PyMySQL database connection library to configure database connection parameters, establishing a connection with a cloud database and performing calculation processing; S65, construct a maximum corrosion depth calculation module for the pipe segment, and integrate it into the corrosion risk classification warning module, call the historical cumulative corrosion depth to calculate the performance degradation index, and calculate the corrosion risk level and the remaining service life of the current pipe segment according to the risk warning principle and degradation model in step S5; S66. Use the WebSocket protocol to establish a two-way communication channel between the server and the cloud data and front end, and push the predicted values of internal and external corrosion rates, corrosion depth values, average absolute SHAP values of each input feature, remaining service life of the pipe segment, and corrosion risk level of the pipe segment corresponding to different pipe segments at different times to the front end.
8. The urban lifeline pipeline corrosion risk early warning method based on digital twin according to claim 3 is characterized by: The ratio of dividing the training set and the test set in step S22 is 7:
3.
9. The urban lifeline pipeline corrosion risk early warning method based on digital twin according to claim 3 is characterized by: In step S214, the values of weights ω1 and ω2 are both 0.
5.
10. The urban lifeline pipeline corrosion risk early warning method based on digital twin according to claim 4 is characterized by: In step S31, the number of groups of pipeline external environment parameters is 100, and the ratio of the training set to the test set is 7:3.
Citation Information
Patent Citations
Vibration deformation amount measuring and calculating method of vertical high-rise structure vibration isolation system
CN106682328A
Underground pipeline structure safety evaluation method based on augmented reality and digital twinning
CN113919106A
Slow feed grinding temperature prediction method based on physical guidance neural network
CN117195695A
Composite flexible pipeline monitoring method and system based on digital twinning
CN118821521A
Leakage and corrosion monitoring system for buried pipe
KR102564669B1
Cited By
Thermal power plant atmospheric environment monitoring method and system
CN121208253A
Steam pipeline system health state real-time evaluation and early warning method and related equipment
CN122407988A