Hydraulic system model identification method and device
Through the hydraulic system model identification method of real-time online identification and model update, the problems of fewer hydraulic system model modeling methods and poor model flexibility in the existing technology are solved, and the accurate and adaptive dynamic model identification of the hydraulic system is realized, which improves the flexibility and adaptability of the model.
Patent Information
- Application Number
- CN202210204765.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-03
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2042-03-03
AI Technical Summary
In the prior art, there are fewer models of hydraulic system models, and traditional data-driven system identification technology is offline identification, which cannot adapt to changes in the dynamic characteristics of hydraulic systems in real time, resulting in poor model flexibility and difficulty in applying to various external environments.
It provides a hydraulic system model identification method. By obtaining real-time input and output data, building a hydraulic system model based on the Hammerstein-Wiener model, and using the Naive Bayesian method for real-time online identification and model update, ensuring that model parameters are updated in real time with the changes in the environment.
It realizes accurate and adaptive dynamic model identification of the hydraulic system, improves the flexibility and adaptability of the model, can better match the sensitive characteristics of the hydraulic system to the external environment, and provides a more accurate analysis and controller design data basis.
Smart Images

Figure CN114564801B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of engineering machinery, and in particular to a hydraulic system model identification method and device. Background Art
[0002] For the hydraulic system of construction machinery, it is necessary to obtain its dynamic mathematical model if it is to be analyzed and intelligently controlled. However, due to the complexity of the internal environment of the hydraulic system, the workload of modeling it based on physical mechanisms is extremely large. Therefore, there are few methods for modeling hydraulic systems in the prior art, and simulation software is usually used to achieve this, but intelligent control of the hydraulic system cannot be achieved through simulation software.
[0003] The data-driven modeling method is only based on input and output, and does not require the analysis of complex physical mechanisms. At the same time, it can provide a mathematical model to describe the hydraulic system. Therefore, to achieve intelligent control of the hydraulic system, data-driven system modeling is the first choice. However, the current traditional data-driven system identification technology is offline identification, that is, after collecting a large amount of input and output of the system, a usable mathematical model is established and identified through the historical data to complete the analysis and control of the system. Since the working scene of construction machinery is constantly changing, the dynamic characteristics of the hydraulic system are not static, but change with the changes in the external environment, such as load type, external temperature, etc. Therefore, the mathematical model of offline modeling and identification is less flexible and can only be applied to certain specific external environments, which brings greater difficulty and limitations to the analysis and design of hydraulic systems. Summary of the invention
[0004] In view of the problems existing in the prior art, the present invention provides a hydraulic system model identification method and device.
[0005] The present invention provides a hydraulic system model identification method, comprising:
[0006] Get real-time input and output data of hydraulic system;
[0007] Based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model, the parameters of the hydraulic system model are identified in real time online; wherein the preliminary identification results of the parameters of the hydraulic system model are obtained by performing nonlinear optimization on the hydraulic system model based on the historical input and output data of the hydraulic system;
[0008] The hydraulic system model is updated according to the real-time online identification result.
[0009] According to the hydraulic system model identification method provided by the present invention, the hydraulic system model is constructed based on the Hammerstein-Wiener model; the hydraulic system model includes an input nonlinear unit, a linear transfer function and an output nonlinear unit connected in sequence;
[0010] The input nonlinear unit is used to perform linear transformation on the input of the hydraulic system model;
[0011] The output nonlinear unit is used to perform nonlinear transformation on the output of the linear transfer function;
[0012] The linear transfer function is used to determine the output response of the hydraulic system model.
[0013] According to the hydraulic system model identification method provided by the present invention, the nonlinear optimization of the hydraulic system model based on the historical input and output data of the hydraulic system includes:
[0014] Based on the difference between the actual output data and the predicted output data, a loss function of the hydraulic system model is constructed; wherein the predicted output data is obtained by inputting the historical input and output data into the hydraulic system model;
[0015] The parameters of the hydraulic system model are iteratively solved with the goal of minimizing the loss function to complete the nonlinear optimization of the hydraulic system model.
[0016] According to the hydraulic system model identification method provided by the present invention, the parameters of the hydraulic system model are identified online in real time based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model, including:
[0017] Based on the real-time input and output data and the preliminary identification result, a naive Bayes method is used to perform real-time online identification on the parameters of the linear transfer function.
[0018] According to the hydraulic system model identification method provided by the present invention, based on the real-time input and output data and the preliminary identification result, the parameters of the linear transfer function are identified in real time online using the naive Bayes method, including:
[0019] Determining a priori distribution of parameters of the linear transfer function at a current moment;
[0020] Determining the likelihood of the parameters of the linear transfer function at the current moment based on the real-time input and output data;
[0021] Based on the prior distribution and the likelihood, a posterior distribution of the parameters of the linear transfer function at the current moment is determined to obtain an identification result of the parameters of the linear transfer function at the current moment.
[0022] According to the hydraulic system model identification method provided by the present invention, the determining of the prior distribution of the parameters of the linear transfer function at the current moment includes:
[0023] If the current moment is an initial moment, the prior distribution of the parameters of the linear transfer function at the current moment is determined based on the preliminary identification result; otherwise, the posterior distribution at the previous moment is used as the prior distribution of the parameters of the linear transfer function at the current moment.
[0024] According to the hydraulic system model identification method provided by the present invention, the prior distribution of the parameters of the linear transfer function at the current moment is determined based on the preliminary identification result, including:
[0025] Determining expectations of the parameters of the hydraulic system model based on preliminary identification results of the parameters of the hydraulic system model;
[0026] Based on a preset covariance matrix and expectations of the parameters of the hydraulic system model, a priori distribution of the parameters of the linear transfer function at a current moment is determined.
[0027] The present invention also provides a hydraulic system model identification device, comprising:
[0028] A data acquisition module, used to obtain real-time input and output data of the hydraulic system;
[0029] An online identification module, used for performing real-time online identification of the parameters of the hydraulic system model based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model; wherein the preliminary identification results of the parameters of the hydraulic system model are obtained by performing nonlinear optimization on the hydraulic system model based on the historical input and output data of the hydraulic system;
[0030] The model updating module is used to update the hydraulic system model according to the real-time online identification result.
[0031] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, any of the above-mentioned hydraulic system model identification methods is implemented.
[0032] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the hydraulic system model identification method as described in any one of the above is implemented.
[0033] The hydraulic system model identification method and device provided by the present invention perform real-time online identification of the parameters of the hydraulic system model through the real-time input and output data of the hydraulic system and the preliminary identification results of the parameters of the hydraulic system model, thereby obtaining an accurate and adaptive hydraulic system dynamic model, which can better fit the characteristics of the hydraulic system that is sensitive to the external environment and has good flexibility. The identified hydraulic system model can more accurately analyze the hydraulic system and provide a data basis for the design of the corresponding controller. BRIEF DESCRIPTION OF THE DRAWINGS
[0034] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0035] Figure 1 It is one of the flow charts of the hydraulic system model identification method provided by the present invention;
[0036] Figure 2 It is a structural schematic diagram of the hydraulic system model provided by the present invention;
[0037] Figure 3 This is the second flow chart of the hydraulic system model identification method provided by the present invention;
[0038] Figure 4 It is a schematic diagram of a flow chart of real-time online identification of parameters of a linear transfer function provided by the present invention;
[0039] Figure 5 It is a structural schematic diagram of the hydraulic system model identification device provided by the present invention;
[0040] Figure 6 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION
[0041] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0042] Combine the following Figures 1 to 4 The hydraulic system model identification method of the present invention is described. The hydraulic system model identification method of the present invention is executed by an electronic device such as a computer or the software and / or hardware therein. Figure 1 FIG. 1 is a flow chart of the hydraulic system model identification method of the present invention, as shown in FIG. Figure 1 As shown, the hydraulic system model identification method of the present invention includes:
[0043] S101, obtaining real-time input and output data of the hydraulic system.
[0044] Specifically, the hydraulic system is a hydraulic system of engineering machinery, such as an excavator, a crane, etc. The specific data category of the real-time input and output data of the hydraulic system can be set according to the specific performance of the hydraulic system. For example, for an excavator, the input data in the real-time input and output data represents a handle input signal, and the output data represents the speed and displacement of the hydraulic system.
[0045] S102. Based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model, real-time online identification of the parameters of the hydraulic system model is performed; wherein the preliminary identification results of the parameters of the hydraulic system model are obtained by nonlinearly optimizing the hydraulic system model based on the historical input and output data of the hydraulic system.
[0046] Specifically, since the working scene of the construction machinery is constantly changing, the dynamic characteristics of the hydraulic system are not static, but change with the changes of the external environment, such as the type of load, the external temperature, etc. Therefore, the embodiment of the present invention is based on the preliminary identification results of the parameters of the hydraulic system model, and performs real-time online identification of the parameters of the hydraulic system model through the real-time input and output data of the hydraulic system, which can ensure that the parameters of the hydraulic system model are updated with the real-time input and output data of the hydraulic system.
[0047] In addition, the embodiment of the present invention performs real-time online identification based on the preliminary identification results of the parameters of the hydraulic system model, thereby effectively avoiding falling into a local optimum during the real-time online identification process, further ensuring the effectiveness and accuracy of the real-time online identification results.
[0048] Among them, the hydraulic system model can be pre-built. Since the hydraulic system is a nonlinear system, a nonlinear model can be used to build the hydraulic system model. The specific type of the nonlinear model can be set according to actual needs. For example, it can be a Hammerstein-Wiener (HW) model, volterra model, Hammerstein model, Wiener model, etc.
[0049] The specific method for nonlinear optimization of the hydraulic system model based on the historical input and output data of the hydraulic system can be set according to actual needs. For example, the stochastic gradient descent method and the Gauss-Newton iteration method can be used. By performing nonlinear optimization on the hydraulic system model, the preliminary identification results of the parameters of the hydraulic system model can be obtained. In the historical input and output data (u(k), y(k)), k = 1, 2, ..., N, the input data u(k) can represent the handle input signal, the output data y(k) can represent the speed and displacement of the hydraulic system, and N is the number of historical input and output data.
[0050] S103: updating the hydraulic system model according to the real-time online identification result.
[0051] Specifically, the parameters of the hydraulic system model can be updated according to the real-time online identification results obtained from the real-time input and output data acquired at each moment, so as to realize the real-time update of the hydraulic system model, so that the identified hydraulic system model can be updated in real time with the real-time input and output of the hydraulic system, thereby obtaining a hydraulic system model that changes with the external environment, ensuring the accuracy and adaptability of the identified hydraulic system model, and being able to better fit the characteristics of the hydraulic system that is sensitive to the external environment, so as to solve the problem of the impact of changes in the external environment on the dynamics of the hydraulic system, and having good flexibility. At the same time, the identified hydraulic system model can more accurately analyze the hydraulic system and provide a data basis for the design of the corresponding controller.
[0052] It can be seen that the embodiment of the present invention performs real-time online identification of the parameters of the hydraulic system model through the real-time input and output data of the hydraulic system and the preliminary identification results of the parameters of the hydraulic system model, thereby obtaining an accurate and adaptive hydraulic system dynamic model, which can better fit the characteristics of the hydraulic system that is sensitive to the external environment and has good flexibility. The identified hydraulic system model can more accurately analyze the hydraulic system and provide a data basis for the design of the corresponding controller.
[0053] Based on the above embodiment, the hydraulic system model is constructed based on the Hammerstein-Wiener model; the hydraulic system model includes an input nonlinear unit, a linear transfer function and an output nonlinear unit connected in sequence;
[0054] The input nonlinear unit is used to perform linear transformation on the input of the hydraulic system model;
[0055] The output nonlinear unit is used to perform nonlinear transformation on the output of the linear transfer function;
[0056] The linear transfer function is used to determine the output response of the hydraulic system model.
[0057] Specifically, the Hammerstein-Wiener model has global estimation capabilities for the dynamics of nonlinear systems and is relatively friendly to controller design. Therefore, constructing a hydraulic system model using the Hammerstein-Wiener model can accurately describe the nonlinear dynamic characteristics of the hydraulic system and provide a data basis for controller design.
[0058] The specific structure of the hydraulic system model is as follows: Figure 2 As shown, it includes an input nonlinear unit 210, a linear transfer function 220 and an output nonlinear unit 230 connected in sequence; the input nonlinear unit 210 is used to convert the input of the hydraulic system model from nonlinear to linear, the output nonlinear unit 230 is used to convert the output of the linear transfer function 220 from linear to nonlinear, and the linear transfer function 220 is used to determine the output response of the hydraulic system model, for example, to control the output of the hydraulic system model to delay or advance, so as to accurately describe the nonlinear dynamic characteristics of the hydraulic system.
[0059] The input nonlinear unit 210 and the output nonlinear unit 230 use functions to achieve linear-to-nonlinear or nonlinear-to-linear conversion; the specific function type can be set according to actual needs, for example, it can be a piecewise linear function, a polynomial, a saturation function, a dead zone function, a sigmoid function, a wavelet function, etc. The expression of the linear transfer function 220 is shown in formula (1):
[0060]
[0061] Where B / F is the linear transfer function, b0…b m and a1…a n are the coefficients of the linear transfer function, z is the leading link in the z-transform; m and n are the orders of the linear transfer function, and their values can be set according to actual needs, for example, they can be determined using MATLAB software.
[0062] The working process of the hydraulic system model includes: the input of the hydraulic system model is u, and after passing through the function f of the input nonlinear unit 210, a first intermediate output w=f(u) is obtained, and then a second intermediate output x=B / F·w is obtained after passing through the linear transfer function 220, and finally a final output y=h(x) is obtained after passing through the function h of the output nonlinear unit 230.
[0063] It can be seen that the embodiment of the present invention constructs a hydraulic system model based on the Hammerstein-Wiener model, which includes an input nonlinear unit, a linear transfer function and an output nonlinear unit connected in sequence, which can accurately describe the nonlinear dynamic characteristics of the hydraulic system and provide a data basis for the design of the controller.
[0064] Based on any of the above embodiments, the nonlinear optimization of the hydraulic system model based on the historical input and output data of the hydraulic system includes:
[0065] Based on the difference between the actual output data and the predicted output data, a loss function of the hydraulic system model is constructed; wherein the predicted output data is obtained by inputting the historical input and output data into the hydraulic system model;
[0066] The parameters of the hydraulic system model are iteratively solved with the goal of minimizing the loss function to complete the nonlinear optimization of the hydraulic system model.
[0067] Specifically, the actual output data is the output data y(k) corresponding to the historical input and output data, and the predicted output data is the prediction result obtained by inputting the input data u(k) corresponding to the historical input and output data into the hydraulic system model; the loss function of the hydraulic system model can be constructed according to the square sum of the differences corresponding to each data in the historical input and output data. For example, the loss function J is shown in formula (2):
[0068]
[0069] In the formula, Output data for prediction.
[0070] The smaller the loss function is, the closer the predicted output of the hydraulic system model is to the actual output. At this time, the corresponding parameters of the hydraulic system model can be used as the preliminary identification results.
[0071] The embodiment of the present invention constructs a loss function of the hydraulic system model based on the difference between the actual output data and the predicted output data, and iteratively solves the parameters of the hydraulic system model with the goal of minimizing the loss function. This enables the functions of the input nonlinear unit, the output nonlinear unit, and the parameters of the linear transfer function to be optimized synchronously, thereby providing a data basis for real-time online identification of the hydraulic system model parameters.
[0072] Based on any of the above embodiments, the real-time online identification of the parameters of the hydraulic system model based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model includes:
[0073] Based on the real-time input and output data and the preliminary identification result, a naive Bayes method is used to perform real-time online identification on the parameters of the linear transfer function.
[0074] Specifically, the dynamic characteristics of the hydraulic system are mainly described by linear transfer functions. Therefore, in the process of real-time online identification of the parameters of the hydraulic system model, based on real-time input and output data and preliminary identification results, only the parameters of the linear transfer function are identified in real time online. This effectively reduces the parameters to be identified and improves the identification efficiency while ensuring the accuracy of the identification results.
[0075] In addition, the embodiment of the present invention adopts the naive Bayesian method to perform real-time online identification of the parameters of the linear transfer function, and can obtain the distribution space of the parameters of the linear transfer function, rather than just a parameter value, thereby ensuring the validity of the parameter identification result. At the same time, the naive Bayesian method has a lower error rate, further improving the accuracy of the parameter identification result.
[0076] Based on any of the above embodiments, the real-time online identification of the parameters of the linear transfer function using a naive Bayes method based on the real-time input and output data and the preliminary identification result includes:
[0077] Determining a priori distribution of parameters of the linear transfer function at a current moment;
[0078] Determining the likelihood of the parameters of the linear transfer function at the current moment based on the real-time input and output data;
[0079] Based on the prior distribution and the likelihood, a posterior distribution of the parameters of the linear transfer function at the current moment is determined to obtain an identification result of the parameters of the linear transfer function at the current moment.
[0080] Specifically, in the process of real-time online identification of the parameters of the linear transfer function using the naive Bayes method, first, the prior distribution of the parameters of the linear transfer function at the current moment is determined; the current moment is the moment when the real-time input and output data are collected; the prior distribution of the parameters of the linear transfer function at the current moment, that is, the distribution space of the parameters of the linear transfer function before the parameters are identified based on the real-time input and output data collected at the current moment.
[0081] Secondly, the likelihood of the parameters of the linear transfer function at the current moment is determined based on the real-time input and output data; the likelihood of the parameters of the linear transfer function is that the real-time input and output data (X(t), Y(t)) collected at the current moment is input into the hydraulic system model corresponding to the current moment (the parameters of the hydraulic system model at time t are the parameters estimated at time t-1, that is, θ t-1 ) after the hydraulic system model prediction results The similarity with Y(t); where X(t) and Y(t) are the input data and output data corresponding to the real-time input and output data collected at time t, respectively.
[0082] Again, based on the prior distribution and likelihood of the parameters of the linear transfer function, the posterior distribution of the parameters of the linear transfer function is determined to obtain the distribution space of the parameters of the linear transfer function identified at the current moment, as shown in formula (3):
[0083]
[0084] In the formula, P(θ t |Y(t))、P(θ t-1 ) and P(Y(t)|θ t-1 ) are the posterior distribution, prior distribution and likelihood of the parameters of the linear transfer function at time t (t≥1), respectively; P(Y(t)) is the distribution space of the output data corresponding to the real-time input and output data collected at time t, which is a known quantity.
[0085] It can be seen that the embodiment of the present invention can quickly and accurately determine the posterior distribution of the parameters of the linear transfer function based on the prior distribution and likelihood of the parameters at the current moment, thereby being able to update the hydraulic system model in real time according to the current working environment of the hydraulic system.
[0086] Based on any of the above embodiments, the determining the prior distribution of the parameters of the linear transfer function at the current moment includes:
[0087] If the current moment is an initial moment, the prior distribution of the parameters of the linear transfer function at the current moment is determined based on the preliminary identification result; otherwise, the posterior distribution at the previous moment is used as the prior distribution of the parameters of the linear transfer function at the current moment.
[0088] Specifically, the initial moment is the first moment when real-time input and output data are collected. If the current moment is the initial moment, the prior distribution of the parameters of the linear transfer function at the current moment is determined based on the preliminary identification result; if the current moment is not the initial moment, the posterior distribution of the moment before the current moment is directly used as the prior distribution of the current moment, so that the parameters of the linear transfer function can be iteratively updated according to the collected real-time input and output data, so that the identified hydraulic system model can be consistent with the changes in the working environment of the hydraulic system, and then the hydraulic system can be analyzed more accurately through the identified hydraulic system model, and a data basis is provided for the design of the corresponding controller.
[0089] Based on any of the above embodiments, the determining the prior distribution of the parameters of the linear transfer function at the current moment based on the preliminary identification result includes:
[0090] Determining expectations of the parameters of the hydraulic system model based on preliminary identification results of the parameters of the hydraulic system model;
[0091] Based on a preset covariance matrix and expectations of the parameters of the hydraulic system model, a priori distribution of the parameters of the linear transfer function at a current moment is determined.
[0092] Specifically, the prior distribution of the parameter θ of the linear transfer function can be set as a Gaussian distribution, that is, Among them, μ is the expectation, σ 2 is the variance. The parameter θ of the linear transfer function is the coefficient of the linear transfer function, that is, θ=[b0,b1…b m ,a1,a2,…a n ] T The prior distribution of the parameters of the linear transfer function at the current moment is determined based on the preliminary identification results, that is, the expectation and variance of the Gaussian distribution are determined based on the preliminary identification results.
[0093] In the preliminary identification process, the nonlinear optimization of the hydraulic system model based on the historical input and output data obtains the specific values of the parameters of the hydraulic system model, rather than the distribution space. Therefore, the parameter θ0 of the linear transfer function in the preliminary identification result can be used as the expected μ, and the preset covariance matrix Ω0 can be used as the variance σ 2 , thus obtaining the prior distribution of the parameters of the linear transfer function at the current moment, that is, Among them, the preset covariance matrix Ω0 can be set according to actual needs, for example, it can be set to a unit matrix, and the real-time update of the covariance matrix can be achieved in the process of real-time online identification of the parameters of the hydraulic system model based on real-time input and output data.
[0094] Through the covariance matrix, the propagation of the parameters of the linear transfer function can be effectively captured, thus providing a data basis for the accurate identification of the parameter distribution space of the linear transfer function.
[0095] exist In the case of , the likelihood of the parameters of the linear transfer function at time t (t ≥ 1) is Among them, Σ is the covariance matrix of Y(t), which is related to the accuracy of the sensor that collects Y(t) and is a known quantity.
[0096] Based on naive Bayes inference, the posterior distribution P(θ t The calculation of |Y(t)) is shown in formula (4):
[0097]
[0098] Among them, Ω t ,Ωt-1 are the covariance matrices of the parameters of the linear transfer function at time t and time t-1, respectively.
[0099] Through the posterior distribution P(θ t |Y(t)) can determine the distribution space of the parameters of the linear transfer function. Therefore, the parameters of the linear transfer function can be updated quickly and accurately through the naive Bayes method.
[0100] The hydraulic system of an excavator is taken as an example to explain the hydraulic system model identification method of the present invention in detail. Figure 3 As shown, the method includes:
[0101] S301, acquiring historical input and output data of the hydraulic system based on a database; wherein the historical input and output data include: historical handle input, historical hydraulic system speed, and historical hydraulic system displacement;
[0102] S302, constructing a hydraulic system model based on the Hammerstein-Wiener model, and inputting historical input and output data into the hydraulic system model to perform nonlinear optimization on the hydraulic system model, and obtaining preliminary identification results of parameters of the hydraulic system model, i.e., initial parameters of the hydraulic system model; wherein the hydraulic system model includes an input nonlinear unit, a linear transfer function, and an output nonlinear unit connected in sequence;
[0103] S303, obtaining real-time input and output data of the hydraulic system through sensors; wherein the real-time input and output data include: real-time handle input, real-time hydraulic system speed, and real-time hydraulic system displacement;
[0104] S304, based on the real-time input and output data and the initial parameters of the hydraulic system model, performing real-time online identification on the parameters of the linear transfer function;
[0105] S305: Update the hydraulic system model based on the real-time online identification result.
[0106] In step S304, the specific process of performing real-time online identification of the parameters of the linear transfer function based on the real-time input and output data and the initial parameters of the hydraulic system model is as follows: Figure 4 As shown, including:
[0107] S401, inputting initial parameters of the hydraulic system model;
[0108] S402, determining the prior distribution of the parameters of the linear transfer function at the current moment based on the initial parameters;
[0109] S403, inputting the real-time input and output data at the current moment, and calculating the likelihood of the parameters of the linear transfer function at the current moment based on the real-time input and output data at the current moment;
[0110] S404, calculating the posterior distribution of the parameters of the linear transfer function at the current moment based on the prior distribution and likelihood of the parameters of the linear transfer function at the current moment, and updating the parameters of the linear transfer function based on the posterior distribution;
[0111] S405 , taking the posterior distribution of the parameters of the linear transfer function at the current moment as the prior distribution at the next moment, and taking the next moment as the current moment, and repeating steps S403 to S405 until a preset termination condition is met.
[0112] The hydraulic system model identification device provided by the present invention is described below. The hydraulic system model identification device described below and the hydraulic system model identification method described above can be referred to each other. Figure 5 As shown, the device comprises:
[0113] A data acquisition module 510 is used to acquire real-time input and output data of the hydraulic system;
[0114] An online identification module 520 is used to perform real-time online identification of the parameters of the hydraulic system model based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model; wherein the preliminary identification results of the parameters of the hydraulic system model are obtained by performing nonlinear optimization on the hydraulic system model based on the historical input and output data of the hydraulic system;
[0115] The model updating module 530 is used to update the hydraulic system model according to the real-time online identification result.
[0116] Based on the above embodiment, the hydraulic system model is constructed based on the Hammerstein-Wiener model; the hydraulic system model includes an input nonlinear unit, a linear transfer function and an output nonlinear unit connected in sequence;
[0117] The input nonlinear unit is used to perform linear transformation on the input of the hydraulic system model;
[0118] The output nonlinear unit is used to perform nonlinear transformation on the output of the linear transfer function;
[0119] The linear transfer function is used to determine the output response of the hydraulic system model.
[0120] Based on any of the above embodiments, it also includes a preliminary identification module, and the preliminary identification module is specifically used to:
[0121] Based on the difference between the actual output data and the predicted output data, a loss function of the hydraulic system model is constructed; wherein the predicted output data is obtained by inputting the historical input and output data into the hydraulic system model;
[0122] The parameters of the hydraulic system model are iteratively solved with the goal of minimizing the loss function to complete the nonlinear optimization of the hydraulic system model.
[0123] Based on any of the above embodiments, the online identification module 520 is specifically used for:
[0124] Based on the real-time input and output data and the preliminary identification result, a naive Bayes method is used to perform real-time online identification on the parameters of the linear transfer function.
[0125] Based on any of the above embodiments, the online identification module 520 is specifically used for:
[0126] Determining a priori distribution of parameters of the linear transfer function at a current moment;
[0127] Determining the likelihood of the parameters of the linear transfer function at the current moment based on the real-time input and output data;
[0128] Based on the prior distribution and the likelihood, a posterior distribution of the parameters of the linear transfer function at the current moment is determined to obtain an identification result of the parameters of the linear transfer function at the current moment.
[0129] Based on any of the above embodiments, the online identification module 520 is specifically used for:
[0130] If the current moment is an initial moment, the prior distribution of the parameters of the linear transfer function at the current moment is determined based on the preliminary identification result; otherwise, the posterior distribution at the previous moment is used as the prior distribution of the parameters of the linear transfer function at the current moment.
[0131] Based on any of the above embodiments, the online identification module 520 is specifically used for:
[0132] Determining expectations of the parameters of the hydraulic system model based on preliminary identification results of the parameters of the hydraulic system model;
[0133] Based on a preset covariance matrix and expectations of the parameters of the hydraulic system model, a priori distribution of the parameters of the linear transfer function at a current moment is determined.
[0134] Figure 6 An example of a physical structure diagram of an electronic device is shown in FIG. Figure 6As shown, the electronic device may include: a processor 610, a communications interface 620, a memory 630 and a communications bus 640, wherein the processor 610, the communications interface 620 and the memory 630 communicate with each other via the communications bus 640. The processor 610 may call the logic instructions in the memory 630 to execute the hydraulic system model identification method, the method including: obtaining real-time input and output data of the hydraulic system;
[0135] Based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model, the parameters of the hydraulic system model are identified in real time online; wherein the preliminary identification results of the parameters of the hydraulic system model are obtained by performing nonlinear optimization on the hydraulic system model based on the historical input and output data of the hydraulic system;
[0136] The hydraulic system model is updated according to the real-time online identification result.
[0137] In addition, the logic instructions in the above-mentioned memory 630 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.
[0138] On the other hand, the present invention further provides a computer program product, the computer program product comprising a computer program stored on a non-transitory computer-readable storage medium, the computer program comprising program instructions, when the program instructions are executed by a computer, the computer can execute the hydraulic system model identification method provided by the above methods, the method comprising: obtaining real-time input and output data of the hydraulic system;
[0139] Based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model, the parameters of the hydraulic system model are identified in real time online; wherein the preliminary identification results of the parameters of the hydraulic system model are obtained by performing nonlinear optimization on the hydraulic system model based on the historical input and output data of the hydraulic system;
[0140] The hydraulic system model is updated according to the real-time online identification result.
[0141] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, the computer program being implemented when executed by a processor to perform the above-mentioned hydraulic system model identification method, the method comprising: acquiring real-time input and output data of the hydraulic system;
[0142] Based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model, the parameters of the hydraulic system model are identified in real time online; wherein the preliminary identification results of the parameters of the hydraulic system model are obtained by performing nonlinear optimization on the hydraulic system model based on the historical input and output data of the hydraulic system;
[0143] The hydraulic system model is updated according to the real-time online identification result.
[0144] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.
[0145] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0146] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A hydraulic system model identification method, characterized in that: include: Get real-time input and output data of hydraulic system; Based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model, the parameters of the hydraulic system model are identified in real time online; wherein the preliminary identification results of the parameters of the hydraulic system model are obtained by performing nonlinear optimization on the hydraulic system model based on the historical input and output data of the hydraulic system; According to the real-time online identification result, the hydraulic system model is updated; The hydraulic system model includes a linear transfer function, and the linear transfer function is used to determine the output response of the hydraulic system model; Accordingly, the real-time online identification of the parameters of the hydraulic system model based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model includes: based on the real-time input and output data and the preliminary identification results, using the naive Bayes method to perform real-time online identification of the parameters of the linear transfer function; Based on the real-time input and output data and the preliminary identification result, the naive Bayes method is used to perform real-time online identification on the parameters of the linear transfer function, including: Determining a priori distribution of parameters of the linear transfer function at a current moment; Determining the likelihood of the parameters of the linear transfer function at the current moment based on the real-time input and output data; Determine the posterior distribution of the parameters of the linear transfer function at the current moment based on the prior distribution and the likelihood, so as to obtain an identification result of the parameters of the linear transfer function at the current moment; The determining of the prior distribution of the parameters of the linear transfer function at the current moment comprises: If the current moment is an initial moment, determining the prior distribution of the parameters of the linear transfer function at the current moment based on the preliminary identification result; otherwise, using the posterior distribution at the previous moment as the prior distribution of the parameters of the linear transfer function at the current moment; The determining, based on the preliminary identification result, the prior distribution of the parameters of the linear transfer function at the current moment comprises: Determining expectations of the parameters of the hydraulic system model based on preliminary identification results of the parameters of the hydraulic system model; Based on a preset covariance matrix and expectations of the parameters of the hydraulic system model, a priori distribution of the parameters of the linear transfer function at a current moment is determined.
2. The hydraulic system model identification method according to claim 1, characterized in that: The hydraulic system model is constructed based on the Hammerstein-Wiener model; the hydraulic system model also includes an input nonlinear unit and an output nonlinear unit; wherein the input nonlinear unit, the linear transfer function, and the output nonlinear unit are connected in sequence; The input nonlinear unit is used to perform linear transformation on the input of the hydraulic system model; The output nonlinear unit is used to perform nonlinear transformation on the output of the linear transfer function.
3. The hydraulic system model identification method according to claim 1, characterized in that: The nonlinear optimization of the hydraulic system model based on the historical input and output data of the hydraulic system includes: Based on the difference between the actual output data and the predicted output data, a loss function of the hydraulic system model is constructed; wherein the predicted output data is obtained by inputting the historical input and output data into the hydraulic system model; The parameters of the hydraulic system model are iteratively solved with the goal of minimizing the loss function to complete the nonlinear optimization of the hydraulic system model.
4. A hydraulic system model identification device, characterized in that: include: A data acquisition module, used to obtain real-time input and output data of the hydraulic system; An online identification module, used for performing real-time online identification of the parameters of the hydraulic system model based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model; wherein the preliminary identification results of the parameters of the hydraulic system model are obtained by performing nonlinear optimization on the hydraulic system model based on the historical input and output data of the hydraulic system; A model updating module, used for updating the hydraulic system model according to the real-time online identification result; The hydraulic system model includes a linear transfer function, and the linear transfer function is used to determine the output response of the hydraulic system model; Accordingly, the real-time online identification of the parameters of the hydraulic system model based on the real-time input and output data and the preliminary identification results of the parameters of the hydraulic system model includes: based on the real-time input and output data and the preliminary identification results, using the naive Bayes method to perform real-time online identification of the parameters of the linear transfer function; Based on the real-time input and output data and the preliminary identification result, the naive Bayes method is used to perform real-time online identification on the parameters of the linear transfer function, including: Determining a priori distribution of parameters of the linear transfer function at a current moment; Determining the likelihood of the parameters of the linear transfer function at the current moment based on the real-time input and output data; Determine the posterior distribution of the parameters of the linear transfer function at the current moment based on the prior distribution and the likelihood, so as to obtain an identification result of the parameters of the linear transfer function at the current moment; The determining of the prior distribution of the parameters of the linear transfer function at the current moment comprises: If the current moment is an initial moment, determining the prior distribution of the parameters of the linear transfer function at the current moment based on the preliminary identification result; otherwise, using the posterior distribution at the previous moment as the prior distribution of the parameters of the linear transfer function at the current moment; The determining, based on the preliminary identification result, the prior distribution of the parameters of the linear transfer function at the current moment comprises: Determining expectations of the parameters of the hydraulic system model based on preliminary identification results of the parameters of the hydraulic system model; Based on a preset covariance matrix and expectations of the parameters of the hydraulic system model, a priori distribution of the parameters of the linear transfer function at a current moment is determined.
5. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the hydraulic system model identification method according to any one of claims 1 to 3 is implemented.
6. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the hydraulic system model identification method according to any one of claims 1 to 3 is implemented.
Citation Information
Patent Citations
Method and apparatus for on-line identification of thermal process model
CN109063818A
Online interval identification method for key operation parameters of gas turbine
CN113111456A