Energy-saving control method and system based on sample library management composite model

By integrating thermophysical models and data-driven models, a large-sample-space training set for data-driven models is established, which solves the problems of high computational cost and slow training speed of energy system simulation models, and realizes more efficient energy-saving control of energy systems.

CN117706927BActive Publication Date: 2026-07-03XI AN JIAOTONG UNIV

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
XI AN JIAOTONG UNIV
Filing Date
2023-12-13
Publication Date
2026-07-03

AI Technical Summary

Technical Problem

Existing energy system simulation models suffer from high computational costs, limitations of sample space and redundant data in data-driven models, and long historical data collection cycles, resulting in insufficient model accuracy and training speed.

Method used

A method combining thermophysical models and data-driven models is adopted to establish a large-sample-space training set for the data-driven model. By dividing the parameters into grids and removing redundant data, a sample library covering the entire operating range of the system is formed. The data-driven model is trained using the covered sample library, thus optimizing computational cost and training speed.

Benefits of technology

It improves the applicability and training speed of the model, reduces computational costs, broadens the scope of application of the model, improves the accuracy and application cycle of the model, and enhances the realism and accuracy of the model in system simulation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117706927B_ABST
    Figure CN117706927B_ABST
Patent Text Reader

Abstract

An energy-saving control method and system for energy systems based on a composite model managed by a sample library is disclosed. The method includes: fitting model parameters and correcting errors in an energy system thermophysical model using historical operating data; dividing the set of values ​​for each parameter according to the nominal operating range and historical operating intervals to form a parameter grid covering the entire operating range; placing historical operating data into the parameter grid, deleting redundant data from parameter grids containing multiple sets of data, and extracting all missing grids; supplementing the missing grids with data using the corrected energy system thermophysical model; combining the parameter grids from historical operating data and the parameter grids supplemented with data from the energy system thermophysical model to form a sample library covering the entire operating range of the energy system; and using the sample library to train the system simulation data to drive the model, calculating the setpoints of each control parameter and the operating values ​​of other parameters when the system energy consumption is minimized. This invention simultaneously ensures control accuracy and calculation speed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of energy system energy-saving optimization control, specifically relating to an energy system energy-saving control method and system based on a sample library management composite model. Background Technology

[0002] To achieve energy conservation and emission reduction in energy systems, accurate analysis of operational energy consumption in large-scale energy systems such as electricity, heat, industrial refrigeration, and building heating and ventilation is a crucial foundation for assessing the system's operational status, energy efficiency, and energy-saving potential. Establishing system simulation models allows for a deeper description of the inherent laws governing system state changes based on real-time operational data. This enables the calculation and prediction of uncertainties and nonlinear changes in energy consumption, achieving energy-efficient optimization control and improving system energy efficiency.

[0003] Based on computational principles and methods, existing energy system simulation models can be categorized into thermophysical models based on physical principles, data-driven models based on machine learning, and composite dual-drive models that integrate thermophysics and data. Traditional thermophysical models rely on numerous parameters and assumptions. Obtaining these parameters requires experiments under ideal operating conditions, which are often unattainable in actual operation. Therefore, thermophysical models typically fail to capture the uncertainties of the system. With the development of artificial intelligence, data-driven models, built entirely from real-world data, can more accurately reflect the system's true dynamic changes, reducing reliance on parameters and assumptions and improving realism and reliability. This has led to their gradual application in energy system simulation modeling. However, data-driven models are based on a limited sample space; beyond the range of sample parameters, the model cannot provide accurate calculation results, and the completeness and error of the data significantly affect the model's accuracy. Therefore, composite dual-drive models, combining the advantages of thermophysics and data-driven models, have emerged and are also known as digital twin technology. In recent years, some studies have gradually applied digital twin technology to energy system management. For example, the Chinese patent "A simulation method for a secondary loop equipment model integrating machine learning and mechanism model" (publication number: CN 116415394A) uses historical operating data to train a data-driven model and integrates the data-driven model into the thermophysical model of the secondary loop equipment, thereby improving the simulation accuracy of the secondary loop equipment.

[0004] Currently, the fusion of thermophysical models and data-driven models is usually done in series or parallel. In series, the calculation result of one model is used as the input condition for the calculation of another model. In parallel, each model is responsible for a part of the system calculation, and the overall simulation result of the system can be obtained by merging the calculation results of the two models. Therefore, the following limitations exist: (1) High computational cost, as the result can only be obtained after the calculation of two models each time. (2) The problem of data-driven models being limited by the sample space cannot be avoided. The training of data-driven models still relies on single historical data or simulation data. The error of the sample space or thermophysical model has a high impact on the accuracy of system simulation. (3) There is a large amount of redundant data in the field data with the same operating range. The redundant data has a negligible effect on the improvement of model accuracy and will instead cause the problem of excessively long training time. (4) The historical data collection cycle for training data-driven models is long. Expanding the calculation range of data-driven models requires training with a large sample space dataset, which requires a longer running time to collect more historical data. Summary of the Invention

[0005] The purpose of this invention is to address the problems in the prior art by providing an energy-saving control method and system based on a sample library management composite model. This method uses a fusion of thermophysical model and data-driven model to establish a data-driven model training set with a large sample space, improving the scope and quality of the sample library in the dual-drive model, reducing the computational cost of using two models simultaneously, and improving the training speed while broadening the applicability of the data-driven model.

[0006] To achieve the above objectives, the present invention provides the following technical solution:

[0007] An energy-saving control method for energy systems based on a composite model of sample library management, comprising:

[0008] Collect historical operational data of the energy system at the site;

[0009] The model parameters of the pre-built thermophysical model of the energy system are fitted and the error is corrected using historical on-site operation data.

[0010] The set of values ​​for each parameter is divided according to the nominal operating range and the historical operating interval. By arranging and combining the set of values ​​for all parameters, a parameter grid covering the entire operating range is formed.

[0011] Place the historical operational data from the field into the parameter grid, delete redundant data in the parameter grid containing multiple sets of data, and extract all empty grids.

[0012] Data was supplemented for all missing grid cells using a corrected thermophysical model of the energy system.

[0013] By combining the parameter grid of historical on-site operating data and the parameter grid supplemented by data from the energy system thermophysical model, a sample library covering the entire operating range of the energy system is formed.

[0014] By training a pre-established system simulation data-driven model using a sample library covering the entire operating range of the energy system, an energy system model based on the sample library management composite model is obtained.

[0015] By using an energy system model based on a sample library management composite model, the setpoints of each control parameter and the operating values ​​of other parameters are calculated when the system energy consumption is minimized, thereby achieving energy-saving control of the energy system.

[0016] As a preferred approach, after collecting the historical operating data of the energy system at the site, the collected data is preprocessed and features are extracted.

[0017] Preprocessing includes data noise reduction and outlier removal;

[0018] Data denoising: Wavelet thresholding or empirical mode decomposition is used to eliminate sensor noise and reconstruct the signal;

[0019] Outlier removal: Visible outliers are identified and removed using the 3sigma criterion, LOF, or KNN outlier detection methods, while invisible outliers are identified and removed using the quartile method.

[0020] Feature extraction: Use expert experience to judge the features that have the greatest impact on system energy consumption, or use principal component analysis or high correlation filtering to calculate the correlation between each parameter and system energy consumption, and extract key features.

[0021] As a preferred embodiment, the energy system includes any one or more combinations of thermal, electrical, building HVAC, and industrial refrigeration systems;

[0022] The energy system thermophysical model is based on the principles of fluid mechanics, thermodynamics, and heat transfer, and follows the conservation of energy, mass, and momentum. It is built using Simulink, EnergyPlus, Ebsilon software, or a self-programmed model.

[0023] The preprocessed historical on-site operating data was used to fit the model parameters and correct the errors of the energy system thermophysical model.

[0024] As a preferred embodiment, in the step of dividing the set of value points for each parameter according to the nominal operating range and the historical operating interval, and forming a parameter grid covering the entire operating range by arranging and combining the set of value points for all parameters, the nominal operating range of the parameter is defined as the upper and lower limits of the corresponding parameter. All operating intervals of each parameter within the upper and lower limits of the operating range are obtained from the historical operating data on site. The value interval of each parameter is determined according to actual needs to form the set of value points for each parameter.

[0025] Based on the set of n feature parameter values, a feature parameter grid is constructed that includes all combinations of values ​​for each parameter. The number of grid cells, Num_total, is calculated using the following formula:

[0026] Num_total=Π i=1~n Num(i)

[0027] Num(i) = size[Mesh(i)]

[0028] Mesh(i) = linspace(downline) i ,upline i interval i )

[0029] In the formula, n is the number of features contained in the feature dataset; Num(i) is the number of elements in the set of values ​​for the i-th parameter;

[0030] Mesh(i) is the set of values ​​for the i-th parameter; downline i The lower bound of the operating range of the i-th parameter; upline i The interval is the upper limit of the operating range of the i-th parameter; i The interval for the value of the i-th parameter.

[0031] As a preferred embodiment, in the step of obtaining all operating intervals of each parameter within the upper and lower limits from the historical operating data of the field, and determining the value interval of each parameter according to actual needs, the value interval of each parameter is divided into the following four cases based on the operating interval of the historical operating data corresponding to each parameter:

[0032] Each parameter's value interval is determined based on the minimum value of the running interval. At this point, the number of points taken for each parameter is the maximum, and the resulting grid is called the encrypted parameter grid.

[0033] Each parameter's value interval is determined based on the maximum value of the running interval. At this time, the number of points taken for each parameter is minimized, and the resulting grid is called a sparse parameter grid.

[0034] Each parameter's value interval is determined based on the average value of the normal distribution of the running interval. At this time, the number of points for each parameter is moderate, and the resulting grid is called the average parameter grid.

[0035] For each parameter's operating interval, which falls within the range of 0% to 50% of the normal distribution, the minimum value of each parameter's operating interval within that interval is obtained to determine the corresponding interval's value interval. For intervals with a normal distribution ranging from 50% to 80%, the average value of each parameter's operating interval within that interval is calculated to determine the corresponding interval's value interval. For intervals with a normal distribution ranging from 80% to 100%, the maximum value of each parameter's operating interval within that interval is obtained to determine the corresponding interval's value interval. The resulting grid is called the adaptive parameter grid.

[0036] As a preferred approach, when determining the value interval of each parameter according to actual needs, the following principles are followed:

[0037] The encrypted parameter grid contains the most complete sample points, and the model trained after forming a sample library based on the encrypted parameter grid has the highest accuracy, but the computational cost is the highest.

[0038] Sparse parameter grids generate the fewest sample points, which improves computation speed during model training but reduces accuracy.

[0039] The average parameter grid balances model training speed and accuracy;

[0040] The adaptive parametric mesh refines the sampling points in the frequently operating range of each parameter, and reduces the number of meshes in stages in the infrequent operating range. It takes into account the computational accuracy while reducing the model's computation time, but it incurs additional computational costs when meshing.

[0041] As a preferred approach, before the step of putting the historical on-site operating data into the parameter grid, it is determined whether the combination of operating parameters corresponding to each parameter grid conforms to the physical logic of the energy system operation. Parameter grids that do not conform to the physical logic are directly deleted.

[0042] As a preferred approach, in the step of training a pre-established system simulation data-driven model using a sample library covering the entire operating range of the energy system, multiple machine learning algorithms are used to train the sample library covering the entire operating range of the energy system to obtain multiple data-driven system simulation models; a set of model test datasets is randomly selected from the field data, and the calculation errors of the test set on the multiple data-driven system simulation models are compared to select the machine learning method with the highest accuracy.

[0043] As a preferred embodiment, in the step of calculating the setpoints of each control parameter and the operating values ​​of other parameters when the system energy consumption is minimized, an optimization algorithm is used to calculate the setpoints of each control parameter and the operating values ​​of other parameters when the system energy consumption is minimized. The optimization algorithm is selected as follows:

[0044] Determine the number of constrained parameters. If it is a single variable with a clear interval constraint, choose the fminbnd function in MATLAB. If there is no clear interval constraint, choose fminsearch or fminunc. Then assume the initial value X0 and start the calculation.

[0045] When the constrained parameters are multivariable, if each parameter has a clear interval constraint, choose the fmincon function in MATLAB; if there is no clear interval constraint, choose fminsearch or fminunc, and start the calculation after assuming the initial value X0.

[0046] When the number of variables and interval constraints are not considered, choosing a global optimization algorithm without a given initial X0 will result in high computational cost. Choosing a constrained local optimization algorithm will lead to getting stuck in local optima.

[0047] An energy-saving control system based on a sample library management composite model includes:

[0048] The data acquisition module is used to collect historical on-site operating data of the energy system;

[0049] The thermophysical model calibration module is used to fit model parameters and correct errors in a pre-built thermophysical model of an energy system using historical on-site operating data.

[0050] The parameter grid establishment module is used to divide the set of value points for each parameter according to the nominal operating range and the historical operating interval. By arranging and combining the set of value points for all parameters, a parameter grid covering the entire operating range is formed.

[0051] The parameter grid insertion module is used to put historical operational data from the field into the parameter grid, delete redundant data in parameter grids containing multiple sets of data, and extract all empty grids.

[0052] The missing grid filling module is used to fill in data for all missing grids using the corrected energy system thermophysics model;

[0053] The sample library creation module is used to combine the parameter grid of historical on-site operating data and the parameter grid after supplementing the data of the energy system thermophysical model to form a sample library covering the entire operating range of the energy system.

[0054] The data-driven model training module is used to train a pre-established system simulation data-driven model using a sample library covering the entire operating range of the energy system, so as to obtain an energy system model based on the sample library management composite model.

[0055] The model calculation module is used to calculate the set values ​​of each control parameter and the operating values ​​of other parameters when the system energy consumption is minimized by using a composite model based on a sample library to manage the energy system model, thereby achieving energy-saving control of the energy system.

[0056] Compared with the prior art, the present invention has at least the following beneficial effects:

[0057] This invention employs a fusion method of thermophysical model and data-driven model to establish a data-driven model training set with a large sample space. Redundant data in the sample library is reasonably removed, thus improving training speed while broadening the applicability of the data-driven model. The thermophysical model is used in the early stages of system model training, and optimization calculations rely solely on the data-driven model, solving the problem of excessive computational costs caused by using two models simultaneously. This invention creates a sample library covering all possible operating intervals of the system based on real-world data and supplementary data from the thermophysical model, broadening the sample space for model training and effectively improving the model's applicability. The thermophysical model is only used to supplement the model training sample library; in practical applications, system performance simulation and energy-saving calculations are performed solely using the data-driven model trained on the fully covered sample library. Unlike existing series or parallel model fusion methods, this invention completely separates the computational stages of the thermophysical model and the data-driven model, solving the problem of excessive computation time caused by using two models simultaneously. During sample library establishment, redundant data within each operating interval is detected and removed by dividing the parameter grid. Without affecting model accuracy and applicability, the number of model training samples is reasonably reduced, effectively improving model training speed. This invention addresses the drawback of long data collection cycles in traditional data-driven models. Initially, it supplements missing data using a thermophysical model, rapidly establishing a training sample library for the data-driven model. As the system runs longer and more real-world data is acquired, the sample library can be updated, and the model retrained. This allows for continuous improvement of the data-driven model's realism and accuracy in system simulation, resulting in a long applicable model lifecycle. Attached Figure Description

[0058] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of the present invention. For those skilled in the art, other related drawings can be obtained from these drawings without creative effort.

[0059] Figure 1This is a flowchart of an energy system energy-saving control method based on a sample library management composite model, as described in an embodiment of the present invention.

[0060] Figure 2 This is a schematic diagram illustrating the specific grid division method for each parameter in the sample library of this invention.

[0061] Figure 3 This is a schematic diagram of the process flow of an NH3-CO2 cascade refrigeration system for a food quick-freezing warehouse according to an embodiment of the present invention. Detailed Implementation

[0062] 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, and not all embodiments. Based on the embodiments of the present invention, those skilled in the art can obtain other embodiments without creative effort.

[0063] Please see Figure 1 The energy-saving control method for energy systems based on a sample library management composite model, as described in this embodiment of the invention, includes:

[0064] S1. Collect historical on-site operating data of energy systems such as heat, electricity, building HVAC or refrigeration, perform data preprocessing and feature extraction, and establish a feature dataset that is highly correlated with the system's energy consumption, which contains n parameters.

[0065] S2. Based on thermodynamic principles and following the conservation of energy, mass, and momentum, a thermophysical model of the energy system is constructed. The model parameters are fitted and errors are corrected using preprocessed historical datasets to establish a high-precision system simulation thermophysical model.

[0066] S3. Obtain the nominal operating range of each of the n parameters in the feature dataset, defining it as the upper and lower limits of the parameter's operation. Obtain all operating intervals of each parameter within these limits from historical data, and determine the value interval for each parameter according to actual needs, forming a set of value points for each parameter. Based on the set of value points for the n feature parameters, construct a feature parameter grid containing all combinations of parameter value points. The formula for calculating the total number of grid points (Num_total) is as follows:

[0067] Num_total=Π i=1~n Num(i)

[0068] Num(i) = size[Mesh(i)]

[0069] Mesh(i) = linspace(downline) i ,upline i ,intervali )

[0070] In the formula, n is the number of features in the feature dataset; Num(i) is the number of elements in the set of values ​​for the i-th parameter; Mesh(i) is the set of values ​​for the i-th parameter; downline i The lower bound of the operating range of the i-th parameter; upline i The interval is the upper limit of the operating range of the i-th parameter; i Let be the interval between the values ​​of the i-th parameter. Therefore, Mesh(i) is essentially an array divided into columns according to the specified intervals within the upper and lower limits of the i-th parameter.

[0071] S4. Determine whether the combination of operating parameters corresponding to each grid conforms to the physical logic of the system operation. Grids that do not conform to the physical logic are deleted directly.

[0072] S5. Place all parameters in the feature dataset into the established full-coverage parameter grid, determine whether there is historical data in each parameter grid, and mark all missing data points.

[0073] S6. For grids with existing historical data, redundant data is deleted based on the number of historical data sets within the grid. If only one set of historical data exists, it is retained directly; if two sets of historical data exist, one set is randomly retained; if three or more sets of redundant data exist, redundant data is deleted and one set is retained. This ensures that each grid containing historical data has exactly one set of historical data.

[0074] S7. For grids lacking historical data, a set of data needs to be supplemented based on the high-precision system thermophysical model established in step S2.

[0075] S8. Combine grids containing real historical data with grids supplemented by thermophysical model data to form a sample library that can cover the entire operating range of the system.

[0076] S9. Select appropriate machine learning algorithms and parameter grids, use a full-coverage sample library to train a high-precision system simulation data-driven model, and complete the energy system modeling of the base sample library management composite model.

[0077] S10. Select a suitable optimization algorithm to calculate the set values ​​of each control parameter and the operating values ​​of other parameters when the system energy consumption is minimized, so as to realize the energy-saving control of the energy system.

[0078] In one possible implementation, the data preprocessing and feature extraction in step S1 should include at least the following steps:

[0079] Data denoising: Common methods such as wavelet thresholding or empirical mode decomposition are used to eliminate sensor noise and reconstruct the signal;

[0080] Outlier removal: Common outlier detection methods such as 3sigma, LOF, or KNN are used to identify and remove visible outliers, while the quartile method is used to identify and remove invisible outliers.

[0081] Feature extraction: Use expert experience to judge the features that have the greatest impact on system energy consumption, or use common methods such as principal component analysis (PCA) and high correlation filtering to calculate the correlation between each parameter and system energy consumption, and extract key features.

[0082] In one possible implementation, the thermophysical model of the energy system described in step S2 can be built using commercial software such as Simulink, EnergyPlus, or Ebsilon, or a self-programmed model. It is a model based on the physical thermophysics of the energy system and corrections made from real data. Furthermore, the simulation results of the thermophysical model of the energy system should at least include all parameters and system energy consumption contained in the feature dataset.

[0083] like Figure 2 As shown, in one possible implementation, the full-coverage parameter mesh is formed in step S3 as follows:

[0084] First, calculate the running interval in the historical data of each parameter. Based on the historical running interval, the parameter value intervals can be divided into the following four types:

[0085] (1) Each parameter is determined based on the minimum value of the running interval. At this time, the number of points taken for each parameter is the maximum, and the resulting grid is called the encrypted parameter grid.

[0086] (2) The value interval of each parameter is determined based on the maximum value of the running interval. At this time, the number of points for each parameter is minimized, and the resulting grid is called a sparse parameter grid.

[0087] (3) The value interval of each parameter is determined based on the average value of the normal distribution of the running interval. At this time, the number of points for each parameter is moderate, and the resulting grid is called the average parameter grid.

[0088] (4) For each parameter's operating interval where the normal distribution is within the range of 0-50%, obtain the minimum value of each parameter's operating interval within that interval to determine the value interval for that interval; for intervals where the normal distribution is within the range of 50-80%, recalculate the normal distribution average of each parameter's operating interval within that interval to determine the value interval for that interval; for intervals where the normal distribution is within the range of 80-100%, obtain the maximum value of each parameter's operating interval within that interval to determine the value interval for that interval. The resulting mesh is called the adaptive parameter mesh.

[0089] Furthermore, the choice of the four full-coverage grid methods during model training can be determined based on grid properties and actual computational needs. The dense parameter grid has the most complete set of sample points, resulting in the highest model accuracy after training based on a sample library formed from this grid, but it also has the highest computational cost. The sparse parameter grid forms the fewest sample points, significantly improving computational speed during model training, but decreasing accuracy. The average parameter grid balances model training speed and accuracy. The adaptive parameter grid densifies the number of points within the frequently used range of each parameter and progressively reduces the number of grid points within the less frequently used range, considering computational accuracy while reducing model computation time, but it may incur additional computational costs during grid partitioning.

[0090] In one possible implementation, the physical logic that should be followed in step S4 includes at least the three laws of thermodynamics.

[0091] In one possible implementation, when the grid contains three or more historical data points in step S6, the method for deleting redundant data can employ common machine learning algorithms such as KNN or K-means.

[0092] In one possible implementation, the specific method for selecting a suitable machine learning algorithm in step S9 is as follows:

[0093] Multiple data-driven system simulation models are obtained by training a full-coverage sample database with three or more machine learning algorithms. A test dataset can be randomly selected from field data. The computational errors of the test set on the multiple data-driven system simulation models are compared to select the machine learning method with the highest accuracy. Common evaluation metrics such as mean squared error (MSE), root mean square error (RMSE), mean absolute error (MAE), mean absolute percentage error (MAPE), and symmetric mean absolute percentage error (SMAPE) can be used to evaluate computational errors.

[0094] Furthermore, when selecting machine learning algorithms in a data-driven model, the sample library should be standardized before model training to eliminate the impact of differences in feature dimensions on training accuracy.

[0095] In one possible implementation, the specific method for selecting a suitable optimization algorithm in step S10 includes:

[0096] Determine the number of constrained parameters, i.e., control parameters. If it is a single variable with a clear interval constraint, you can choose the fminbnd function in MATLAB. If there is no clear interval constraint, you can choose fminsearch or fminunc. Then assume the initial value X0 and start the calculation.

[0097] When the control parameters are multiple variables, if each parameter has a clear interval constraint, you can choose the fmincon function in MATLAB. If there is no clear interval constraint, you can choose fminsearch or fminunc and start the calculation after assuming the initial value X0.

[0098] Without considering the number of variables or interval constraints, global optimization algorithms such as simulated annealing and genetic algorithms can be chosen, without requiring an initial X0. However, this may result in excessively high computational costs. Choosing constrained local optimization algorithms may lead to getting trapped in local optima.

[0099] by Figure 3 Taking a typical NH3-CO2 cascade refrigeration system for a food quick-freezing warehouse as an example, the energy-saving control method of the present invention based on the sample library management composite model is applied to the system.

[0100] In the NH3-CO2 cascade refrigeration system, the high-temperature stage uses NH3 refrigerant, and the low-temperature stage uses CO2 refrigerant. The high-temperature and low-temperature stages are connected by an intermediate condenser-evaporator, which serves as both the evaporator for the high-temperature stage and the condenser for the low-temperature stage. Both the high-temperature and low-temperature compressors are variable frequency compressors, adjusting the refrigerant flow rate by changing the compressor speed. The high-temperature stage is equipped with an NH3 receiver and an NH3 gas-liquid separator, while the low-temperature stage is equipped with a CO2 receiver and a CO2 tank pump. Therefore, the subcooling at the condenser outlet and the superheat at the evaporator outlet can be disregarded.

[0101] The Coefficient of Performance (COP) is commonly used to evaluate the performance of a negative cascade cooling system, and the calculation formula is as follows:

[0102]

[0103] In the formula, Q represents the system cooling load, and W represents the total system energy consumption. The specific calculation formula is as follows:

[0104] Q = m*(h² - h³)

[0105] In the formula, h2 is Figure 3 The specific enthalpy of CO2 saturated gas corresponding to the low-temperature stage evaporation temperature at measuring point 2; h3 is Figure 3 The specific enthalpy of CO2 saturated liquid corresponding to the condensation temperature of the low-temperature stage at measuring point 3; m is the CO2 mass flow rate.

[0106] W = W CO2 +W NH3 +W pump +W fan +W valve

[0107] In the formula, W CO2 and W HN3For the power consumption of CO2 and NH3 compressors, W pump The power consumption of the fans in the evaporator and condenser, W fan W represents the power consumption of all pumps in the system. valve This represents the power consumption of the expansion valve. Typically, the compressor's power consumption accounts for over 70% of the system's total power consumption. Whether to include the power consumption of the fan, pump, and valves in the system energy consumption calculation can be selected based on actual calculation requirements. In this embodiment, the overall system energy consumption only considers the power consumption W of the CO2 and NH3 compressors. CO2 and W HN3 .

[0108] In summary, the mathematical description of energy-saving control for NH3-CO2 cascade refrigeration systems is the control parameter setpoints corresponding to the highest COP under fixed operating parameters.

[0109] according to Figure 1 The energy-saving control method for energy systems based on a sample library management composite model, as shown, has the following specific calculation steps:

[0110] S1. The system collects data from a total of 16 sensors, including the evaporation temperature, condensation temperature, refrigerant flow rate, compressor speed, and compressor power consumption of both the low-temperature and high-temperature stages; the speed and flow rate of the blast freezer fan; and the flow rate and frequency of the evaporative condenser fan and water pump. The COP is directly affected by the intermediate temperature, i.e., the low-temperature stage condensation temperature, which is achieved by adjusting the speeds of the NH3 and CO2 compressors; the evaporation temperature of the low-temperature stage is determined by the frozen goods; and the ambient temperature limits the condensation temperature of the high-temperature stage.

[0111] All operational data from June to August 2022 were collected at 1-minute intervals. Wavelet thresholding was used for noise reduction, and the 3-sigma criterion and quartile method were used to remove outliers. Based on expert experience, the feature dataset for the NH3-CO2 negative cascade refrigeration system simulation model was selected from 16 sensor features. The dataset should include the following six input parameters: intermediate temperature, low-temperature stage evaporation temperature, high-temperature stage condensation temperature, CO2 compressor speed, NH3 compressor speed, and condenser-evaporator heat exchange temperature difference. The calculated output is the Coefficient of Performance (COP).

[0112] S2. Establish thermophysical models for NH3 and CO2 compressors, and build a semi-empirical model of the compressor using Matlab. Input parameters are suction pressure, discharge pressure, suction temperature, and rotational speed; output parameters are motor power, shaft power, and cooling capacity. COP can be calculated based on the ratio of the cooling capacity of the low-temperature compressor to the sum of the motor powers of the high-temperature and low-temperature compressors in the simulation results. Therefore, the simulation results of the compressor thermophysical model include all input and output parameters of the feature dataset in S1. Fitting of empirical parameters and error correction in the model are performed based on preprocessed historical data.

[0113] S3. Obtain the nominal operating range of each parameter in the feature dataset according to the manufacturer's instructions. Figure 2 The parameter grid division method is shown in Table 1. The minimum, maximum, and mean normal distribution of the running intervals in the historical data of each parameter are analyzed. The normal distribution of the running intervals of each parameter is analyzed. For each parameter's running interval where the normal distribution is within the range of 0-50%, the minimum value of the running interval for each parameter in that interval is obtained to determine the value interval for that interval. For intervals where the normal distribution is within the range of 50-80%, the mean normal distribution of the running intervals for each parameter in that interval is calculated again to determine the value interval for that interval. For intervals where the normal distribution is within the range of 80-100%, the maximum value of the running interval for each parameter in that interval is obtained to determine the value interval for that interval, as shown in Table 2.

[0114] according to Figure 2 As shown, the value intervals were determined according to four operating ranges, and four parameter permutation grids were established. The number of value points for each parameter in the grid and the total number of grids were calculated using the following formula, and the calculation results are shown in Table 3. Since the collected data were historical data under summer operating conditions from June to August, the condensing temperature and intermediate temperature were limited by the ambient temperature, and the compressor usually operated under high load and high speed. Therefore, the historical data did not cover the entire nominal operating range. For operating ranges without historical data, the densified, sparse, average, and adaptive parameter grids were divided using the minimum, maximum, mean, and average values ​​of the historical operating intervals, respectively.

[0115] Num_total=∏ i=1~n Num(i)

[0116] Num(i) = size[Mesh(i)]

[0117] Mesh(i) = linspace(downline) i ,upline i ,interval i )

[0118] In the formula, n is the number of features in the feature dataset; Num(i) is the number of elements in the set of values ​​for the i-th parameter; Mesh(i) is the set of values ​​for the i-th parameter; downline i The lower bound of the operating range of the i-th parameter; upline i The interval is the upper limit of the operating range of the i-th parameter; i Let be the interval between the values ​​of the i-th parameter. Therefore, Mesh(i) is essentially an array divided into columns according to the specified intervals within the upper and lower limits of the i-th parameter.

[0119] Table 1

[0120]

[0121] Table 2

[0122]

[0123] Table 3

[0124]

[0125] S4. Check if the parameter grid conforms to physical logic. For cascade refrigeration systems, the basic physical logic to be followed is that the intermediate temperature should be higher than the evaporation temperature and lower than the condensation temperature, and the high-temperature refrigerant inlet temperature of the condenser-evaporator should be lower than the low-temperature refrigerant outlet temperature. No inverse logic issues were found in the permutations and combinations of parameters in the four fully covered parameter grids established.

[0126] S5. Place historical data into the parameter grid. The grid with missing data is the operating range not included in the historical data. Mark all missing grids.

[0127] S6. For grids with existing historical data, redundant data is removed based on the number of historical data sets within the grid. If only one set of historical data exists, it is retained directly; if two sets of historical data exist, one set is randomly retained; if three or more sets of redundant data exist, the KNN algorithm is used to remove the redundant data before retaining one set. This ensures that each grid containing historical data has exactly one set of historical data.

[0128] S7. For grids lacking historical data, a set of data needs to be supplemented in each grid using the high-precision compressor thermophysical model established in S2.

[0129] S8. A collection of grids containing real historical data and grids supplemented by thermophysical model data is formed to create a sample library that can cover the entire operating range of the system.

[0130] S9. In this embodiment, considering both computational cost and accuracy requirements, a sample library built using an adaptive parameter grid is selected for data-driven model training. This grid can encrypt samples within the range of frequent system operation, while appropriately reducing sampling points within the range of infrequent operation, thus rationally planning the sample library space and improving model training speed. Before model training, the sample library is standardized to eliminate the impact of feature dimension differences on training accuracy. The calculation formula is as follows:

[0131]

[0132] In the formula, Z is the standardized data, X is the original data, μ is the mean of the original data, and σ is the standard deviation of the original data.

[0133] This paper compares the data-driven models of training system simulations using three machine learning algorithms: SVM, BPNN, and decision tree. Mean percentage error (MAPE) and root mean square error (RMSE) are used as error evaluation criteria. The calculation formulas and accuracy requirements are as follows:

[0134]

[0135]

[0136] MAPE ≤ 0.5%, RMSE ≤ 0.5%

[0137] In the formula, Y i Y is the model's predicted value. i ' represents real data, and n represents the number of samples.

[0138] After comparing the accuracy of the three models, the BPNN algorithm was ultimately chosen to build the data-driven model for system simulation.

[0139] S10. The mathematical description of the energy-saving optimization problem of this cascade refrigeration system is as follows: Given a fixed evaporation temperature, condensation temperature, and condenser-evaporator heat exchange temperature difference, with the maximum COP as the optimization objective, and the setpoints of three control parameters—intermediate temperature and compressor speeds at the high and low temperature stages—it is a multivariate problem with interval constraints for finding extreme values. It can be solved using fmincon or a genetic algorithm. To avoid local optima, a genetic algorithm was ultimately chosen for optimization calculation, achieving energy-saving control of the cascade refrigeration system.

[0140] Another embodiment of the present invention proposes an energy-saving control system based on a sample library management composite model, comprising:

[0141] The data acquisition module is used to collect historical on-site operating data of the energy system;

[0142] The thermophysical model calibration module is used to fit model parameters and correct errors in a pre-built thermophysical model of an energy system using historical on-site operating data.

[0143] The parameter grid establishment module is used to divide the set of value points for each parameter according to the nominal operating range and the historical operating interval. By arranging and combining the set of value points for all parameters, a parameter grid covering the entire operating range is formed.

[0144] The parameter grid insertion module is used to put historical operational data from the field into the parameter grid, delete redundant data in parameter grids containing multiple sets of data, and extract all empty grids.

[0145] The missing grid filling module is used to fill in data for all missing grids using the corrected energy system thermophysics model;

[0146] The sample library creation module is used to combine the parameter grid of historical on-site operating data and the parameter grid after supplementing the data of the energy system thermophysical model to form a sample library covering the entire operating range of the energy system.

[0147] The data-driven model training module is used to train a pre-established system simulation data-driven model using a sample library covering the entire operating range of the energy system, so as to obtain an energy system model based on the sample library management composite model.

[0148] The model calculation module is used to calculate the set values ​​of each control parameter and the operating values ​​of other parameters when the system energy consumption is minimized by using a composite model based on a sample library to manage the energy system model, thereby achieving energy-saving control of the energy system.

[0149] Another embodiment of the present invention provides an electronic device, including a memory storing at least one instruction; and a processor executing the instructions stored in the memory to implement the energy-saving control method for an energy system based on a sample library management composite model.

[0150] Another embodiment of the present invention also proposes a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the energy-saving control method for an energy system based on a sample library management composite model.

[0151] For example, the instructions stored in the memory can be divided into one or more modules / units. These modules / units are stored in a computer-readable storage medium and executed by the processor to complete the energy-saving control method for an energy system based on a sample library management composite model according to the present invention. The one or more modules / units can be a series of computer-readable instruction segments capable of performing specific functions, and these instruction segments describe the execution process of the computer program in the server.

[0152] The electronic device may be a smartphone, laptop, PDA, or cloud server, among other computing devices. It may include, but is not limited to, a processor and memory. Those skilled in the art will understand that the electronic device may also include more or fewer components, or combinations of certain components, or different components; for example, it may also include input / output devices, network access devices, buses, etc.

[0153] The processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor.

[0154] The memory can be an internal storage unit of the server, such as a hard drive or RAM. Alternatively, it can be an external storage device, such as a plug-in hard drive, Smart Media Card (SMC), Secure Digital (SD) card, or Flash Card. Furthermore, the memory can include both internal and external storage units. The memory is used to store computer-readable instructions and other programs and data required by the server. It can also be used to temporarily store data that has been output or will be output.

[0155] It should be noted that the information interaction and execution process between the above-mentioned module units are based on the same concept as the method embodiment. For details on their specific functions and technical effects, please refer to the method embodiment section. They will not be repeated here.

[0156] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is merely an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. Furthermore, the specific names of the functional units and modules are only for easy differentiation and are not intended to limit the scope of protection of this application. The specific working process of the units and modules in the above system can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.

[0157] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments of this application can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include at least: any entity or device capable of carrying the computer program code to a photographing device / terminal device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium. Examples include USB flash drives, portable hard drives, magnetic disks, or optical disks.

[0158] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0159] It will be apparent to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above, and that the invention can be implemented in other specific forms without departing from its spirit or essential characteristics. Therefore, the embodiments should be considered illustrative and non-limiting in all respects, and the scope of the invention is defined by the appended claims rather than the foregoing description. Thus, all variations falling within the meaning and scope of equivalents of the claims are intended to be included within the present invention, and no reference numerals in the claims should be construed as limiting the scope of protection involved.

[0160] The above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit them. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. An energy saving control method of an energy system based on a sample library management composite model, characterized by, include: Collect historical operational data of the energy system at the site; The model parameters of the pre-built energy system thermophysical model are fitted and the error is corrected using historical on-site operation data. The set of values ​​for each parameter is divided according to the nominal operating range and the historical operating interval. By arranging and combining the set of values ​​for all parameters, a parameter grid covering the entire operating range is formed. Place the historical operational data from the field into the parameter grid, delete redundant data in the parameter grid containing multiple sets of data, and extract all empty grids. Data was supplemented for all missing grid cells using a corrected thermophysical model of the energy system. By combining the parameter grid of historical on-site operating data and the parameter grid supplemented by data from the energy system thermophysical model, a sample library covering the entire operating range of the energy system is formed. By training a pre-established system simulation data-driven model using a sample library covering the entire operating range of the energy system, an energy system model based on the sample library management composite model is obtained. By using an energy system model based on a sample library management composite model, the set values ​​of each control parameter are calculated when the system energy consumption is minimized, thereby achieving energy-saving control of the energy system. In the step of dividing the set of value points for each parameter according to the nominal operating range and historical operating intervals, and forming a parameter grid covering the entire operating range by arranging and combining the set of value points for all parameters, the nominal operating range of the parameter is defined as the upper and lower limits of the corresponding parameter's operation. All operating intervals of each parameter within the upper and lower limits are obtained from the historical operating data from the field. The value interval of each parameter is determined according to actual needs, forming the set of value points for each parameter. n For each feature parameter, a feature parameter grid is constructed containing all possible combinations of values ​​for each parameter. The number of grid cells is... Num_ total Calculate using the following formula: In the formula, n The number of features contained in the feature dataset; Num ( i ) is the first i The number of elements in the set of parameter value points; Mesh ( i ) is the first i The set of possible values ​​for each parameter; downline i For the first i The lower limit of the operating range of each parameter; upline i For the first i The upper limit of the operating range of each parameter; interval i For the first i The interval between the values ​​of each parameter.

2. The energy-saving control method for an energy system based on a sample library management composite model according to claim 1, characterized in that, After collecting the historical operating data of the energy system, the collected data is preprocessed and features are extracted. Preprocessing includes data noise reduction and outlier removal; Data denoising: Wavelet thresholding or empirical mode decomposition is used to eliminate sensor noise and reconstruct the signal; Outlier removal: Visible outliers are identified and removed using the 3sigma criterion, LOF, or KNN outlier detection methods, while invisible outliers are identified and removed using the quartile method. Feature extraction: Use expert experience to judge the features that have the greatest impact on system energy consumption, or use principal component analysis or high correlation filtering to calculate the correlation between each parameter and system energy consumption, and extract key features.

3. The energy-saving control method for an energy system based on a sample library management composite model according to claim 2, characterized in that, The energy system includes any one or more combinations of thermal, electrical, building HVAC and industrial refrigeration systems; The energy system thermophysical model is based on the principles of fluid mechanics, thermodynamics, and heat transfer, and follows the conservation of energy, mass, and momentum. It is built using Simulink, EnergyPlus, Ebsilon software, or a self-programmed model. The preprocessed historical on-site operating data was used to fit the model parameters and correct the errors of the energy system thermophysical model.

4. The energy-saving control method for an energy system based on a sample library management composite model according to claim 1, characterized in that, In the step of obtaining all operating intervals of each parameter within the upper and lower limits from the historical operating data of the field, and determining the value interval of each parameter according to actual needs, the value interval of each parameter is divided into the following four cases based on the operating interval of the historical operating data corresponding to each parameter: Each parameter's value interval is determined based on the minimum value of the running interval. At this point, the number of points taken for each parameter is the maximum, and the resulting grid is called the encrypted parameter grid. Each parameter's value interval is determined based on the maximum value of the running interval. At this time, the number of points taken for each parameter is minimized, and the resulting grid is called a sparse parameter grid. Each parameter's value interval is determined based on the average value of the normal distribution of the running interval. At this time, the number of points for each parameter is moderate, and the resulting grid is called the average parameter grid. For each parameter's operating interval, which falls within the range of 0% to 50% of the normal distribution, the minimum value of each parameter's operating interval within that interval is obtained to determine the corresponding interval's value interval. For intervals with a normal distribution ranging from 50% to 80%, the average value of each parameter's operating interval within that interval is calculated to determine the corresponding interval's value interval. For intervals with a normal distribution ranging from 80% to 100%, the maximum value of each parameter's operating interval within that interval is obtained to determine the corresponding interval's value interval. The resulting grid is called the adaptive parameter grid.

5. The energy-saving control method for an energy system based on a sample library management composite model according to claim 4, characterized in that, When determining the value interval of each parameter according to actual needs, the following principles shall be followed: The encrypted parameter grid contains the most complete sample points, and the model trained after forming a sample library based on the encrypted parameter grid has the highest accuracy, but the computational cost is the highest. Sparse parameter grids generate the fewest sample points, which improves computation speed during model training but reduces accuracy. The average parameter grid balances model training speed and accuracy; The adaptive parametric mesh refines the sampling points in the frequently operating range of each parameter, and reduces the number of meshes in stages in the infrequent operating range. It takes into account the computational accuracy while reducing the model's computation time, but it incurs additional computational costs when meshing.

6. The energy-saving control method for an energy system based on a sample library management composite model according to claim 1, characterized in that, Before the step of putting the historical operation data into the parameter grid, it is determined whether the combination of operating parameters corresponding to each parameter grid conforms to the physical logic of the energy system operation. Parameter grids that do not conform to the physical logic are directly deleted.

7. The energy-saving control method for an energy system based on a sample library management composite model according to claim 1, characterized in that, In the step of training a pre-established system simulation data-driven model using a sample library covering the entire operating range of the energy system, multiple machine learning algorithms are used to train the sample library covering the entire operating range of the energy system to obtain multiple data-driven system simulation models. The model test dataset is randomly selected from field data. The computational errors of the test set on multiple data-driven system simulation models are compared to select the machine learning method with the highest accuracy.

8. The energy-saving control method for an energy system based on a sample library management composite model according to claim 1, characterized in that, In the step of calculating the set values ​​of each control parameter when the system energy consumption is minimized, the set values ​​of each control parameter when the system energy consumption is minimized are calculated by an optimization algorithm. The optimization algorithm is selected as follows: Determine the number of constrained parameters. If it is a single variable with explicit interval constraints, choose the MATLAB function `fminbnd`. If there are no explicit interval constraints, choose `fminsearch` or `fminunc`, and assume initial values. X Calculations begin after 0; When the constrained parameters are multivariable, if each parameter has a clear interval constraint, choose the MATLAB function `fmincon`; if there is no clear interval constraint, choose `fminsearch` or `fminunc`, and assume initial values. X Calculations begin after 0; When the number of variables and interval constraints are not considered, a global optimization algorithm is selected, with no initial value given. X 0. This can lead to high computational costs, and when choosing a constrained local optimization algorithm, it can result in getting stuck in local optima.

9. An energy-saving control system based on a sample library management composite model, characterized in that, include: The data acquisition module is used to collect historical on-site operating data of the energy system; The thermophysical model calibration module is used to fit model parameters and correct errors in a pre-built thermophysical model of an energy system using historical on-site operating data. The parameter grid establishment module is used to divide the set of value points for each parameter according to the nominal operating range and the historical operating interval. By arranging and combining the set of value points for all parameters, a parameter grid covering the entire operating range is formed. The parameter grid insertion module is used to put historical operational data from the field into the parameter grid, delete redundant data in parameter grids containing multiple sets of data, and extract all empty grids. The missing grid filling module is used to fill in data for all missing grids using the corrected energy system thermophysics model; The sample library creation module is used to combine the parameter grid of historical on-site operating data and the parameter grid after supplementing the data of the energy system thermophysical model to form a sample library covering the entire operating range of the energy system. The data-driven model training module is used to train a pre-established system simulation data-driven model using a sample library covering the entire operating range of the energy system, so as to obtain an energy system model based on the sample library management composite model. The model calculation module is used to calculate the set values ​​of each control parameter when the system energy consumption is minimized by using an energy system model based on a composite model managed by a sample library, thereby achieving energy-saving control of the energy system. The process involves dividing the parameter value set according to the nominal operating range and historical operating intervals, and forming a parameter grid covering the entire operating range by arranging and combining all parameter value sets. In this process, the nominal operating range of the parameter is defined as the upper and lower limits of the corresponding parameter's operation. All operating intervals within these limits are obtained from historical operating data. The value interval of each parameter is determined according to actual needs, forming the value set of each parameter. n For each feature parameter, a feature parameter grid is constructed containing all possible combinations of values ​​for each parameter. The number of grid cells is... Num_total Calculate using the following formula: In the formula, n The number of features contained in the feature dataset; Num ( i ) is the first i The number of elements in the set of parameter value points; Mesh ( i ) is the first i The set of possible values ​​for each parameter; downline i For the first i The lower limit of the operating range of each parameter; upline i For the first i The upper limit of the operating range of each parameter; interval i For the first i The interval between the values ​​of each parameter.