A Digital Twin-Based Fault Diagnosis Method for Marine Engines
By constructing a digital twin model and combining extended Kalman filtering and the LMS algorithm with a variable step size factor, the problems of low efficiency and low accuracy in marine engine fault diagnosis are solved, achieving efficient and visualized fault diagnosis results.
Patent Information
- Application Number
- CN202210812371.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-11
- Publication Date
- 2025-11-14
- Estimated Expiration
- 2042-07-11
AI Technical Summary
Existing technologies for diagnosing marine engine faults suffer from low efficiency and low accuracy. Furthermore, data sources are limited, noise interference is significant, and data interpretability is poor. Traditional neural networks are prone to overfitting and require long training times.
A fault diagnosis model for marine engines based on digital twins is constructed. By fusing sensor data and fault simulation data, extended Kalman filtering and LMS algorithm with variable step size are used for data processing. The neural network training is optimized by combining cross-entropy loss function to achieve dynamic and visualized fault diagnosis.
It improves the reliability and accuracy of fault diagnosis, enables dynamic and visual diagnosis of multidimensional data, reduces data processing time, and improves training speed and diagnostic efficiency.
Smart Images

Figure CN115329536B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of marine engine technology, and more specifically to a marine engine fault diagnosis method based on digital twins. Background Technology
[0002] In recent years, the concept of digital twins has been applied to the management of the entire lifecycle of intelligent ships. Five-dimensional digital twin models provide guidance for the construction of intelligent ship concepts, blueprint design, manufacturing optimization, health management, intelligent diagnostics, and maintenance processes. Furthermore, after the ship is officially put into service, it is crucial to apply digital twin technology to the specific engines of the intelligent ship to facilitate intelligent operation and maintenance of marine engines. This is a significant innovation in the reapplication of digital twins in marine engines.
[0003] Fault diagnosis technology has evolved from experience-based diagnosis by maintenance personnel using sound, light, heat, and pressure to methods such as analyzing thermodynamic parameters, analyzing fuselage vibration signals, measuring instantaneous speed, and now to data-driven fault diagnosis. After a period of operation, marine engines inevitably experience malfunctions. To reduce property damage and prevent major accidents, an innovative and effective data-driven fault diagnosis method is needed in the later stages of marine engine operation, which is also a core issue in ensuring the healthy operation of the engine.
[0004] Despite the above technical background, the following problems still exist:
[0005] I. Suzhou Kunshan Laishige Industrial Technology Co., Ltd. (Zhou Kai, Wang Chaofeng, Deng Yi, Du Mingli, Ying Haojie, Zhou Xiang. A digital twin system [P]: CN 112507569 A) proposed a framework for constructing digital twins of large-scale systems. However, how to perform digital twin modeling and description of the physical entity of marine engines to achieve high fidelity, multi-dimensionality and virtual-real interaction has become a problem faced in China.
[0006] II. Many shipbuilding enterprises and companies (Feng Jiatian, Yu Cheng, Zhang Xiasheng, He Shenghui, Lin Yuhang, Xiao Yiying. A Data Acquisition and Analysis Method for Ship Manufacturing Equipment [P]: CN 113191916A) mainly collect data on ship equipment and engines through sensors. By improving the acquisition technology of the equipment, the accuracy and rationality of the data can be improved. However, the disadvantages are: small data volume, single data source, large noise interference, and lack of representativeness. There is a need for an innovative method for multi-channel acquisition of marine engine data that can improve the reliability of the data, reduce data noise, and improve the interpretability and intuitiveness of the data.
[0007] III. Power companies and research institutes (Li Rongli, Hu Hongbin, Zhou Lei, Zhang Qian. A Soft Measurement Method for Wind Turbine Speed Based on Principal Component Analysis [P]: CN 112329344 A) use principal component analysis for data preprocessing. However, this method has drawbacks: effective data information is lost after dimensionality reduction, and data interpretability deteriorates. Based on these two points, an innovative data preprocessing method for marine engines is needed that can retain the most effective and representative datasets.
[0008] IV. Traditional deep belief neural networks are used in the monitoring of seismic signals (China University of Mining and Technology, Beijing. Automatic picking method for microseismic signals based on deep belief neural networks [P]: CN201610741484.4.), which are prone to overfitting and excessively long training time. Therefore, in order to solve the problem of overfitting and improve the training speed to find the optimal solution in the shortest time, an optimized neural network is needed to improve the efficiency and accuracy of fault diagnosis of marine engines. Summary of the Invention
[0009] To address the shortcomings of existing technologies, this invention provides a digital twin-based method for diagnosing marine engine faults, which solves the technical problems of low efficiency and accuracy in fault diagnosis in existing technologies.
[0010] This invention provides a method for fault diagnosis of marine engines based on digital twins, the specific steps of which are as follows:
[0011] Step 1: Construct a digital twin model of the ship using the engine's spatial physical model, dynamic performance model, and external environmental parameters.
[0012] Step 2: The sensor-acquired data and fault simulation data are fused using extended Kalman filtering to serve as the training set samples for the marine engine fault diagnosis model;
[0013] Step 3: Construct an engine fault diagnosis model using the LMS algorithm with an added step size variable factor;
[0014] Step 4: Train the engine fault diagnosis model using training set samples to complete the training of the engine fault diagnosis model;
[0015] Step 5: Input real-time sensor data into the engine fault diagnosis model to diagnose engine faults and provide feedback on engine fault type and fault parameters;
[0016] Step 6: Display the feedback engine fault type and fault parameters through the ship's digital twin model.
[0017] Furthermore, in step 3, the formula for the LMS algorithm with a variable step size factor is as follows:
[0018]
[0019] Where e(n) is the instantaneous error at time n; μ(n) is the added step size variable factor.
[0020] Furthermore, in step 3, the formula for the LMS algorithm with a variable step size factor is as follows:
[0021]
[0022] Where μ is a fixed convergence factor to prevent algorithm imbalance; γ is an integer greater than or equal to 1, serving as a variable coefficient.
[0023] Furthermore, in step 3, during the process of constructing the engine fault diagnosis model, the cross-entropy loss function is selected to determine whether the training phase of the engine fault diagnosis model is completed. When the rate of change of the cross-entropy loss function is less than a preset value, the engine fault diagnosis model training is completed.
[0024] Furthermore, the preset value is 0.1.
[0025] The beneficial effects of this invention are:
[0026] I. A method that utilizes data and mathematical models to comprehensively and faithfully depict the traditional physical marine engine model in digital virtual space, upgrading the diagnostic model from a single, data-scarce, and invisible fault diagnosis to a dynamic, visualized, human-computer interactive, and remotely controllable multi-dimensional data diagnostic mode, enabling the digital twin model to continuously iterate and improve accuracy and reliability of fault diagnosis.
[0027] Second, the method of fusing sensor-acquired data with fault mathematical model simulation data solves the errors caused by single data sources and insufficient sensor accuracy. After simplifying the nonlinear problem of the data into a linear problem through extended Kalman filtering, the data is fused and compiled into a training set.
[0028] Third, data preprocessing based on the LMS algorithm model with a variable step size factor offers advantages over traditional Principal Component Analysis (PCA) dimensionality reduction in that it removes noise while retaining more effective data. Furthermore, the addition of a variable step size factor μ and variable coefficient γ significantly reduces preprocessing time and prevents imbalance caused by large variable factors.
[0029] Fourth, a dropout layer with a value of 0.5 is proposed to be added during the back-end fine-tuning phase. Furthermore, the rate of change of the cross-entropy loss function is proposed to replace the traditional mean squared error (MSE) function as an indicator of whether the back-end fine-tuning phase has ended. Through practical testing, after more than 1000 training iterations, the fault diagnosis effectiveness can reach over 95%. Attached Figure Description
[0030] The features and advantages of the invention will be more clearly understood by referring to the accompanying drawings, which are schematic and should not be construed as limiting the invention in any way. In the drawings:
[0031] Figure 1 A schematic diagram illustrating the structure of a digital twin model in a specific embodiment of the present invention;
[0032] Figure 2 A flowchart of a specific embodiment of the present invention. Detailed Implementation
[0033] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0034] The present invention will be further illustrated below with reference to specific embodiments. Those skilled in the art should understand that these embodiments are for illustrative purposes only and are not intended to limit the scope of the invention. Modifications to the present invention in various equivalent forms all fall within the scope defined by the appended claims.
[0035] This invention provides a method for diagnosing marine engine faults based on digital twins, comprising the following steps:
[0036] Step 1: As Figure 1 As shown, a digital twin model of the ship is constructed using the engine's spatial physical model, dynamic performance model, and external environmental parameters. A realistic mapping from physical equipment to the twin is established, and the correlations and mappings between models in multiple dimensions are analyzed. The specific process is as follows:
[0037] Step 11: Analyze each component in the marine engine's DCO turbine exhaust gas recirculation system and cylinder. The DCO turbine exhaust gas recirculation system specifically includes: induced draft fan, control valve, fan blades, heat exchanger, and recirculation cabinet. The internal workpieces and auxiliary parts of the cylinder include: cylinder head, cylinder liner, piston, intake and exhaust valves, spring, crankshaft, connecting rod, crosshead, and piston rod.
[0038] Step 12: Use 3ds Max software to draw the parts as individual components and finally complete the assembly. Draw the parts in 3ds Max based on their dimensional and attribute parameters. Based on the 3D information model of the DCO system and the cylinder as a whole, establish a 3D model of the assembly, and organize the information between the components: assembly relationships, assembly direction parameters, spatial hierarchy, and boundary constraint parameters. Store all the above parameters in 3ds Max for separate processing and management.
[0039] Step 13: After completing the above, set the rigid body properties of the drawn object and then use post-processing such as baking, shading, lighting, and material mapping to restore the parts and components to their physical dimensions at a 1:1 scale, achieving true high fidelity. GPU rendering is performed using shader technology, including materials such as wood, metal, and plastic.
[0040] Step 14: Using the discrete points or coordinate points extracted from the characteristic map of the marine engine test data as sample points, which are closer to the real situation than the idealized combustion equation and waste cycle equation, we then select a suitable function approximation method to reconstruct it into the mathematical model we want. This is the key to constructing the mathematical model of combustion characteristics and the mathematical model of waste cycle of the DCO system.
[0041] Step 15: In Unity 3D, according to step D4, attach a C# script to the typical faulty component to simulate its physical motion under real conditions. Write the mathematical equations for the rotation of the blades of the DCO turbocharger and the changes in the cylinder piston motion in the C# script. Add the gas rendered by Mesh Render and call the gas flow function to simulate the flow process of exhaust and air. Write the mathematical equations for the flow performance.
[0042] Step 16: Not only must a digital twin model of the dual-fuel engine be established, but the environment in which the twin exists must also be modeled. A mathematical model of the environment is established through analysis, thereby constructing a basic twin environment. In Unity 3D software, a skybox is added to describe the external physical environment, making it more realistic.
[0043] Step 2: The sensor-acquired data and fault simulation data are fused using an extended Kalman filter to form the training set samples for the marine engine fault diagnosis model; the specific process is as follows:
[0044] Step 21: Obtain important data such as engine pressure, heat, vibration signals, and noise signals from sensors distributed in various important parts of the ship's engine;
[0045] Step 22: Based on the working characteristics of the ship engine, establish the corresponding mathematical model of the ship engine, and use MATLAB / Simulink simulation to obtain fault state data under the change of mechanism structure;
[0046] Step 23: Based on the Kalman filter, an extended Kalman filter algorithm for nonlinear data is derived. Sensor measurement data is used as observed values, and simulation data as estimated values. The extended Kalman filter algorithm simplifies the nonlinear data into linear data, followed by data fusion. This allows for closed-loop error management, limiting the error to a certain range. Without information fusion, relying solely on estimated data leads to an accumulation of errors over time, resulting in greater uncertainty over longer periods.
[0047] Step 3: Construct an engine fault diagnosis model using the LMS algorithm with a variable step size factor; the formula for the LMS algorithm with a variable step size factor is as follows:
[0048]
[0049] Where e(n) is the instantaneous error at time n; μ(n) is the added step size variable factor;
[0050] To optimize descriptions, etc.
[0051] The formula for the LMS algorithm with a variable step size factor is as follows:
[0052]
[0053] Where μ is a fixed convergence factor to prevent algorithm imbalance; γ is an integer greater than or equal to 1, used as a variable coefficient;
[0054] In the process of constructing the engine fault diagnosis model, the cross-entropy loss function is selected to determine whether the training phase of the engine fault diagnosis model is complete. When the rate of change of the cross-entropy loss function is less than a preset value, the engine fault diagnosis model training is complete. The specific process is as follows:
[0055] Step 31: Use a variable step size method to change its adaptive convergence process. The traditional LMS formula is as follows:
[0056] w(n+1)=w(n)+e(n)x(n)
[0057] w(n) is the filter parameter vector at time n, x(n) is the matrix vector of the signal sample at time n, and e(n) is the instantaneous error value at time n.
[0058] The normalized LMS algorithm with a variable step size factor is as follows:
[0059]
[0060] Let e(n) be the adjustment amount of the iteration coefficient, e(n) be the instantaneous error at time n, and μ(n) be the added step size variable factor.
[0061] The instantaneous error at time n, e(n), is expressed as:
[0062] e(n)=d(n)-x T (n)w(n)
[0063] Step 32: To control the misalignment of the step size factor, we make the following changes to the variable factor μ(n), and the iterative formula is modified as follows:
[0064]
[0065] In the formula, μ is a fixed convergence factor to prevent algorithm imbalance, and γ is a variable coefficient to prevent x from becoming unbalanced. T If (n)x(n) is too small, μ will be adjusted too large. Therefore, a control parameter is set here. Specifically, γ is a variable coefficient greater than 1 to prevent μ from becoming misaligned when the step size changes. When the step size variable factor μ increases, the formula terms increase, ultimately affecting the overall term of w(n+1), which speeds up the step size and thus accelerates the convergence speed. The disadvantage is that it requires better CPU and GPU computing power, resulting in a larger computational load. Therefore, the step size needs to be controlled.
[0066] Step 4: Train the engine fault diagnosis model using training set samples to complete the training of the engine fault diagnosis model; the specific process is as follows:
[0067] Step 41: Normalization of fault training samples. The feature data and fault type data from the obtained historical fault samples of marine engines are preprocessed using feature normalization methods.
[0068] Here, a linear function normalization method is used to perform a linear transformation on the data features and proportionally scale the data. The transformed data falls within the range [0, 1]. The normalization formula is as follows:
[0069]
[0070] Where X max X represents the maximum value of a certain variable in the fault characteristic data. min X represents the minimum value of a certain variable in the fault characteristic data, and X represents the original initial value of this column of data.
[0071] Similarly, each parameter in the fault dataset obtained from the simulation is normalized and converted into a value in the interval [0, 1].
[0072] Step 42: The batch size of training data is set to 8, the activation function of RBM is the Sigmoid function, and the number of pre-training iterations is set to 100. During the fine-tuning phase, the momentum coefficient and learning rate are both set to 0.1, and the Softmax function is used as the activation function for the output layer.
[0073] Step 43: Use the preprocessed data as input to the model to accelerate the training speed of the optimal solution of the training model during the automatic step-size iteration process. When the value of the change rate of the cross-entropy loss function is less than or equal to 0.1, the training phase is considered to be over, and step 5, real-time online fault diagnosis and identification, is performed.
[0074] Step 5: Input real-time sensor data into the engine fault diagnosis model to diagnose engine faults and provide feedback on engine fault type and fault parameters;
[0075] Step 6: Display the feedback engine fault type and fault parameters using the ship's digital twin model. Specifically, client and server programs are created in Unity3D and MATLAB respectively according to the TCP / IP protocol. The fault type and fault parameters diagnosed in MATLAB are displayed in real time in the digital twin model in Unity3D; the specific process is as follows:
[0076] Step 61: Set up a server in MATLAB, and then initialize the server's address and port number to facilitate client addressing and connection, and send fault data and fault type back to the client's Unity3D.
[0077] Step 62: The server starts a new thread and begins listening for connections from the target client (Unity3D software) in the server window;
[0078] Step 63: After the Unity3D server successfully connects to the client, the MATLAB / Simulink server will send a request to the Unity3D client, and organize the requested data into a string format with commas to facilitate encoding by the MATLAB / Simulink server and decoding by the client.
[0079] Step 64: The MATLAB / Simulink server encodes the string and sends it to the Unity3D client. Finally, the client is closed and the server program is terminated. This completes the response and transmission of commands to the Unity3D client.
[0080] Step 65: Create a client in Unity3D and define the software's IP address and port number to facilitate sending commands to the MATLAB / Simulink server and server addressing;
[0081] Step 66: The client machine creates a new thread to receive data from the MATLAB / Simulink server. The Unity3D client machine creates a new socket and defines its type as a stream socket for use with the TCP / IP data communication protocol. The socket is then connected based on the configured MATLAB / Simulink server address and port number.
[0082] Step 67: Determine if the visualization program has ended. If the program has not ended, proceed with the data receiving and decoding process. If the program has ended, proceed with the Unity3D client to close the program. This completes the call and connection to the MATLAB / Simulink server.
[0083] Although embodiments of the invention have been described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of the invention, and such modifications and variations all fall within the scope defined by the appended claims.
Claims
1. A method for fault diagnosis of marine engines based on digital twins, characterized in that, Includes the following steps: Step 1: Construct a digital twin model of the ship using the engine's spatial physical model, dynamic performance model, and external environmental parameters. Step 2: The sensor-acquired data and fault simulation data are fused using extended Kalman filtering to serve as the training set samples for the marine engine fault diagnosis model; Step 3: Construct an engine fault diagnosis model using the LMS algorithm with a variable step size factor. During the model construction process, the cross-entropy loss function is selected to determine whether the training phase of the engine fault diagnosis model is complete. When the rate of change of the cross-entropy loss function is less than a preset value, the engine fault diagnosis model training is complete. The formula for the LMS algorithm with a variable step size factor is as follows: Where μ is a fixed convergence factor to prevent algorithm imbalance; γ is an integer greater than or equal to 1, used as a variable coefficient; e(n) is the instantaneous error at time n; μ(n) is the added step size variable factor; and x(n) is the matrix vector of the signal sample at time n. Step 4: Train the engine fault diagnosis model using training set samples to complete the training of the engine fault diagnosis model; Step 5: Input real-time sensor data into the engine fault diagnosis model to diagnose engine faults and provide feedback on engine fault type and fault parameters; Step 6: Display the feedback engine fault type and fault parameters through the ship's digital twin model.
2. The marine engine fault diagnosis method based on digital twin as described in claim 1, characterized in that, In step 3, the formula for the LMS algorithm with a variable step size factor is as follows: Where e(n) is the instantaneous error at time n; μ(n) is the added step size variable factor.
3. The marine engine fault diagnosis method based on digital twin as described in claim 1, characterized in that, The preset value is 0.1.
Citation Information
Patent Citations
Automatic microseismic signal arrival time picking method based on depth belief neural network
CN106405640A
Fan wind speed soft measurement method based on principal component analysis method
CN112329344A
Digital twinning system
CN112507569A
Data acquisition and analysis method for ship production and manufacturing equipment
CN113191916A
System for diagnosing error conditions of a gas flow control system for turbocharged engines
CN102434291A