Urban fuel peak regulation method and system for producing hydrogen by using solar energy
Through the combination of wavelet decomposition and prediction model, accurate prediction and peak shaving of natural gas consumption are achieved, and the problem of usage deviation in the prior art is solved, economic losses are reduced and supply flexibility is improved.
Patent Information
- Application Number
- CN202411644158.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-18
- Publication Date
- 2025-04-11
AI Technical Summary
The prior art is difficult to effectively solve the problems of natural gas usage prediction and peak shaving, which may cause gas usage deviations and affect economic costs.
By wavelet decomposing the original natural gas usage data, a prediction model is established to predict future usage, the wavelet coefficient is reconstructed to form the predicted value of natural gas usage, and peak shaving is made based on the predicted value, and peak shaving is achieved through natural gas synthesis, storage, photovoltaic hydrogen production and other means.
Accurate prediction and peak shaving of natural gas usage are achieved, reducing gas usage deviations, reducing economic losses, and improving the flexibility of natural gas supply.
Smart Images

Figure CN119800377A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of gas peak shaving technology, and in particular to a city gas peak shaving method and system using solar energy to produce hydrogen. Background Art
[0002] With the marketization of natural gas, downstream users sign natural gas supply contracts with upstream suppliers. The contract has increasingly strict regulations on deviation assessment. In order to avoid economic losses caused by deviation settlement, downstream users can adjust their peak loads on their own to meet the gas volume requirements of the contract. Therefore, providing a solution that facilitates peak load adjustment has become an urgent problem to be solved. Summary of the invention
[0003] The present invention aims to provide a method and system for urban gas peak-shaving by using solar energy to produce hydrogen, which overcomes the above-mentioned problems or at least partially solves the above-mentioned problems.
[0004] To achieve the above object, the technical solution of the present invention is specifically implemented as follows:
[0005] One aspect of the present invention provides a method for urban gas peak load regulation using solar energy to produce hydrogen, comprising:
[0006] Decompose the original natural gas consumption data into high-frequency signals and low-frequency signals of a preset number of layers, and obtain the wavelet coefficients of each decomposed layer;
[0007] Modeling the wavelet coefficients of each layer of the decomposition to obtain a prediction model, and using the prediction model to predict the wavelet coefficients of future usage;
[0008] The wavelet coefficients of each layer decomposed and the wavelet coefficients of the predicted future consumption are reconstructed to form the predicted value of natural gas consumption;
[0009] Performing peak load determination on the predicted natural gas usage value;
[0010] If the predicted value of natural gas consumption is less than or equal to a preset value, a preset proportion of the remaining natural gas in the pipeline network is output to the natural gas synthesis device through a branch line to produce and store natural gas hydrate;
[0011] If the predicted value of natural gas consumption is greater than the preset value, the natural gas hydrate is gasified by a natural gas hydrate gasification device and then input into the pipeline network and / or the natural gas is obtained by electrolyzing water to produce hydrogen by a photovoltaic hydrogen production device and then input into the pipeline network.
[0012] Optionally, the original natural gas consumption data is decomposed into a preset number of layers of high-frequency signals and low-frequency signals, and the wavelet coefficients of each decomposed layer are obtained, including:
[0013] The natural gas usage signal is decomposed into high-frequency signals and low-frequency signals in layers using the Wavedec function in the PyWt wavelet analysis library in Python to obtain high-frequency coefficients and low-frequency coefficients of each layer.
[0014] Optionally, modeling the wavelet coefficients of each layer of the decomposition to obtain a prediction model, and using the prediction model to predict the wavelet coefficients of future usage includes:
[0015] The wavelet coefficients obtained by decomposition are modeled using the autoregressive moving average model in Matlab, and the wavelet coefficients of future usage are predicted.
[0016] Optionally, reconstructing the decomposed wavelet coefficients of each layer and the wavelet coefficients of the predicted future usage to form a natural gas usage prediction value includes:
[0017] The Waverec function in the PyWt wavelet analysis library in Python is used to reconstruct the wavelet coefficients of each decomposed layer and the wavelet coefficients of the predicted future usage to form the natural gas usage prediction value.
[0018] Optionally, the method further comprises:
[0019] The average relative error and the average absolute error between the predicted value of natural gas usage obtained by the autoregressive moving average model and the true value are calculated to verify the accuracy and reliability of the predicted value of natural gas usage.
[0020] Another aspect of the present invention provides a city gas peak load regulation system for producing hydrogen using solar energy, comprising: a gas consumption data prediction and control model, a natural gas synthesis device, a storage device, a natural gas hydrate gasification device and a photovoltaic hydrogen production device, wherein:
[0021] The gas consumption data prediction and control model is used to decompose the original natural gas consumption data into high-frequency signals and low-frequency signals of a preset number of layers to obtain the wavelet coefficients of each decomposed layer; model the wavelet coefficients of each decomposed layer to obtain a prediction model, and use the prediction model to predict the wavelet coefficients of future consumption; reconstruct the wavelet coefficients of each decomposed layer and the wavelet coefficients of the predicted future consumption to form a natural gas consumption prediction value; perform peak shaving judgment on the natural gas consumption prediction value; if the natural gas consumption prediction value is less than or equal to a preset value, control the preset proportion of the natural gas surplus in the pipeline network to be output to the natural gas synthesis device through a branch; if the natural gas consumption prediction value is greater than the preset value, control the natural gas hydrate gasification device to gasify the natural gas hydrate and then input it into the pipeline network and / or control the photovoltaic hydrogen production device to electrolyze water to produce hydrogen to obtain natural gas and input it into the pipeline network;
[0022] The natural gas synthesis device is used to produce natural gas hydrates and send the natural gas hydrates to the storage device for storage;
[0023] The natural gas hydrate gasification device is used to gasify the natural gas hydrate stored in the storage device and then input it into the pipeline network;
[0024] The photovoltaic hydrogen production device is used to produce hydrogen by electrolyzing water and then obtain natural gas which is input into the pipeline network.
[0025] Optionally, the gas consumption data prediction and control model decomposes the original natural gas consumption data into high-frequency signals and low-frequency signals of a preset number of layers in the following manner to obtain the wavelet coefficients of each decomposed layer:
[0026] The natural gas usage signal is decomposed into high-frequency signals and low-frequency signals in layers using the Wavedec function in the PyWt wavelet analysis library in Python to obtain high-frequency coefficients and low-frequency coefficients of each layer.
[0027] Optionally, the gas consumption data prediction and control model models the wavelet coefficients of each layer of the decomposition in the following manner to obtain a prediction model, and uses the prediction model to predict the wavelet coefficients of future consumption:
[0028] The wavelet coefficients obtained by decomposition are modeled using the autoregressive moving average model in Matlab, and the wavelet coefficients of future usage are predicted.
[0029] Optionally, the gas consumption data prediction and control model reconstructs the decomposed wavelet coefficients of each layer and the wavelet coefficients of the predicted future consumption in the following manner to form a natural gas consumption prediction value:
[0030] The Waverec function in the PyWt wavelet analysis library in Python is used to reconstruct the wavelet coefficients of each decomposed layer and the wavelet coefficients of the predicted future usage to form the natural gas usage prediction value.
[0031] Optionally, the gas consumption data prediction and control model is also used to calculate the average relative error and average absolute error between the natural gas consumption prediction value obtained by the autoregressive moving average model and the actual value, so as to verify the accuracy and reliability of the natural gas consumption prediction value.
[0032] Optionally, the system also includes: a photovoltaic power generation device, which is used to provide electrical energy for the city gas peak-shaving system that uses solar energy to produce hydrogen.
[0033] It can be seen that, through the city gas peak-shaving method and system for producing hydrogen using solar energy provided by the present invention, city gas peak-shaving can be carried out based on the predicted natural gas consumption. BRIEF DESCRIPTION OF THE DRAWINGS
[0034] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative work.
[0035] Figure 1 A schematic diagram of the structure of a city gas peak load regulation system for producing hydrogen using solar energy provided by an embodiment of the present invention;
[0036] Figure 2 A flow diagram of a city gas peak load regulation system for producing hydrogen using solar energy provided by an embodiment of the present invention;
[0037] Figure 3 A flow chart of a city gas peak-shaving method for producing hydrogen using solar energy provided by an embodiment of the present invention;
[0038] Figure 4 A flow chart of predicting natural gas usage by wavelet analysis provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0039] The exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided to enable a more thorough understanding of the present disclosure and to fully convey the scope of the present disclosure to those skilled in the art.
[0040] Figure 1 The structure diagram of the city gas peak load regulation system using solar energy to produce hydrogen provided by an embodiment of the present invention is shown. Figure 2 The schematic diagram of the flow of the city gas peak load regulation system using solar energy to produce hydrogen provided by the embodiment of the present invention is shown in FIG. Figure 1 and Figure 2 The city gas peak load regulation system for producing hydrogen using solar energy provided by the embodiment of the present invention comprises:
[0041] Gas consumption data prediction and control model, natural gas synthesis unit, storage unit, natural gas hydrate gasification unit and photovoltaic hydrogen production unit, including:
[0042] The gas consumption data prediction and control model is used to decompose the original natural gas consumption data into high-frequency signals and low-frequency signals of a preset number of layers to obtain the wavelet coefficients of each decomposed layer; model the wavelet coefficients of each decomposed layer to obtain a prediction model, and use the prediction model to predict the wavelet coefficients of future consumption; reconstruct the wavelet coefficients of each decomposed layer and the wavelet coefficients of the predicted future consumption to form a natural gas consumption prediction value; perform peak shaving judgment on the natural gas consumption prediction value; if the natural gas consumption prediction value is less than or equal to a preset value, control the preset proportion of the natural gas surplus in the pipeline network to be output to the natural gas synthesis device through a branch; if the natural gas consumption prediction value is greater than the preset value, control the natural gas hydrate gasification device to gasify the natural gas hydrate and then input it into the pipeline network and / or control the photovoltaic hydrogen production device to electrolyze water to produce hydrogen to obtain natural gas and input it into the pipeline network;
[0043] The natural gas synthesis device is used to produce natural gas hydrates and send the natural gas hydrates to the storage device for storage;
[0044] The natural gas hydrate gasification device is used to gasify the natural gas hydrate stored in the storage device and then input it into the pipeline network;
[0045] The photovoltaic hydrogen production device is used to produce hydrogen by electrolyzing water and then obtain natural gas which is input into the pipeline network.
[0046] As an optional implementation of an embodiment of the present invention, the urban gas peak-shaving system for producing hydrogen using solar energy provided in the embodiment of the present invention also includes: a photovoltaic power generation device, which is used to provide electrical energy for the urban gas peak-shaving system for producing hydrogen using solar energy.
[0047] Specifically, the present invention uses a gas consumption data prediction and control model to predict gas consumption. If the gas consumption is less than the daily gas consumption specified in the contract, 80% of the remaining gas is distributed to the synthesis device through a branch line to produce and store natural gas hydrates. If the gas consumption is greater than the amount specified in the contract, the natural gas hydrate gasification device is started to gasify the hydrate into gaseous methane and input it into the pipeline network, and / or the photovoltaic hydrogen production device is used to electrolyze water to produce hydrogen to obtain natural gas, which is then input into the pipeline network, thereby achieving the purpose of short-term peak regulation.
[0048] When predicting gas consumption, the present invention can first determine the influencing factors. Based on the reference to relevant literature, combined with the characteristics of gas use and daily life experience, the daily maximum and minimum temperatures, wind speeds, weather conditions and other information can be crawled, and the information of whether each day is a working day is obtained according to the date. On this basis, each indicator is processed and a total of 7 daily influencing factors are obtained to determine the relationship between gas consumption.
[0049] Table 1 Daily influencing factors
[0050]
[0051] Secondly, in order to comprehensively consider the changes in the structure and importance of various influencing factors in different regions, the present invention can select a VAR model, construct a model by taking each endogenous variable in the system as a function of the lagged values of all endogenous variables, and establish a vector autoregression model composed of multivariate time series variables to realize the prediction of natural gas consumption.
[0052] The VAR model expression is:
[0053] y t =A1y t-1 +A2y t-2 +…+A p y t-p +Bx t +u t
[0054] In the expression, y t represents the endogenous variable vector with length k at time node t, x t is an exogenous variable vector of length d, p is the lag order; u t is the k-dimensional error vector; A1, A2, …, A p , B is the coefficient matrix to be estimated.
[0055] In the present invention, y t It is an 8-dimensional endogenous variable vector of various influencing factors related to gas; at the same time, it is assumed that the above influencing factors are all endogenous variables, and there are no exogenous variables. The four variables of daytime temperature difference, wind direction, weather conditions and whether it is a working day are all obtained by calculating the original data:
[0056] (1) Daytime temperature difference (x3): obtained by subtracting the daily minimum temperature from the daily maximum temperature, that is, x3 = x1-x2;
[0057] (2) Wind direction (x4): The eight wind directions, such as east, south, west, and north, are represented by discrete variables 1 to 8 respectively;
[0058] (3) Weather conditions (x6): According to statistics, there are too many discrete weather conditions, reaching 29. In order to ensure the interpretability of the variables, the study ranked them according to the degree of perceived quality of different weather conditions, with sunny days being 0 and snowing being 28. The specific variables are shown in Table 2:
[0059] Table 2 Weather condition variable correspondence table
[0060]
[0061]
[0062] (4) Whether it is a working day (x7): A discrete 0,1 variable is used to indicate whether the day is a working day.
[0063] Thirdly, the present invention can perform a stationarity test on the heating and other data of a certain area in a certain place in a certain year (October to March of the following year), determine the lag order, establish an appropriate vector autoregression model, and remove exogenous variables through the Granger causality test.
[0064] After removing the exogenous variables, the remaining endogenous variables are used to repeat the above-mentioned steps such as the stationarity test, and a VAR vector autoregression model is established. The AR root test is used to determine whether the VAR model is stable. Finally, an impulse response analysis is performed on the gas consumption values to observe the impact of different influencing factors on the gas consumption in a certain area in the next day.
[0065] The AR model is constructed as follows:
[0066] Y t =μ+A1Y t-1 +A2Y t-2 +…+A k Y t-k +ε t
[0067] Among them, Y t is an 8-dimensional vector, μ is the intercept term, ε t Represents a random vector with mean 0 and length 8.
[0068] Finally, since the VAR model requires the system to be stable, if the variables in the system are stable, the stable characteristics of the system can be guaranteed. Through the Augment Dickey-Fuller test, it is found that the data of each variable are stable data.
[0069] Table 3 Stability test table
[0070]
[0071] The eighth variable is a 0-1 variable with a deterministic trend and no structural changes. It meets the characteristics of a stationary sequence and does not require a stationary test.
[0072] Based on the city gas peak load regulation system using solar energy to produce hydrogen provided by the embodiment of the present invention, Figure 3 The flowchart of the city gas peak load regulation method using solar energy to produce hydrogen provided by an embodiment of the present invention is shown. Figure 4 A flowchart of predicting natural gas consumption by wavelet analysis provided by an embodiment of the present invention is shown. Figure 3 and Figure 4The method for urban gas peak load regulation using solar energy to produce hydrogen provided by the embodiment of the present invention comprises:
[0073] S1, decomposing the original natural gas consumption data into high-frequency signals and low-frequency signals of a preset number of layers, and obtaining the wavelet coefficients of each decomposed layer.
[0074] As an optional implementation manner of an embodiment of the present invention, the decomposing the original natural gas usage data into a preset number of layers of high-frequency signals and low-frequency signals to obtain the wavelet coefficients of each decomposed layer includes: decomposing the natural gas usage signal into high-frequency signals and low-frequency signals in layers using the Wavedec function in the PyWt wavelet analysis library in Python to obtain high-frequency coefficients and low-frequency coefficients of each layer.
[0075] Specifically, the present invention uses the Wavedec function in the PyWt wavelet analysis library in Python to decompose the natural gas usage signal (raw data) into high-frequency and low-frequency signals in layers, with the number of layers generally being 2 to 6, and obtains the wavelet coefficients of each layer (i.e., low-frequency coefficients and high-frequency coefficients). The low-frequency and high-frequency coefficients respectively divide the original natural gas usage trend into two parts: low-frequency information and high-frequency information. The low-frequency information is the part where the natural gas usage changes slowly, which is the framework outline of the entire trend chart and occupies most of the information; the high-frequency information is the part where the usage changes rapidly, which reflects the detailed information of the image and occupies a small part of the total usage information.
[0076] S2, modeling the wavelet coefficients of each layer of the decomposition to obtain a prediction model, and using the prediction model to predict the wavelet coefficients of future usage.
[0077] As an optional implementation manner of an embodiment of the present invention, the wavelet coefficients of each layer of the decomposition are modeled to obtain a prediction model, and the wavelet coefficients of future usage are predicted using the prediction model, including: using the autoregressive moving average model in Matlab to model the wavelet coefficients obtained by decomposition, and predicting the wavelet coefficients of future usage.
[0078] Specifically, the autoregressive moving average (ARMA) model in Matlab is used to model the wavelet coefficients obtained by decomposition and predict the wavelet coefficients of future usage. The autoregressive moving average model is often chosen when building a model for predictive analysis of linear stationary time series. The basic idea is to combine the autoregressive (AR) model and the moving average (MA) model [1] to make the number of parameters used very small. The autoregressive model expresses the relationship between a variable rt in the time series {rt} and its variables at the previous p moments, which is called the p-order autoregressive model AR(p). The moving average model can be interpreted as the weighted average sum of multiple white noise sequences of the time series, which is called the q-order moving average model MA(q). Therefore, the form of the ARMA model is:
[0079]
[0080] Where: r t ——Natural gas consumption at time t, ψ0——constant, p——autoregressive order, ψ i ——Autoregression coefficient, r t-i ——Natural gas consumption at time ti, a t ——white noise at time t in the white noise sequence, q——moving average order, θ j ——Moving average coefficient, a t-j ——white noise at time tj in the white noise sequence.
[0081] S3, reconstructing the wavelet coefficients of each layer decomposed and the wavelet coefficients of the predicted future usage to form a predicted value of natural gas usage.
[0082] As an optional implementation manner of an embodiment of the present invention, the reconstructing the wavelet coefficients of each decomposed layer and the wavelet coefficients of the predicted future usage to form the natural gas usage prediction value includes: using the Waverec function in the PyWt wavelet analysis library in Python to reconstruct the wavelet coefficients of each decomposed layer and the wavelet coefficients of the predicted future usage to form the natural gas usage prediction value.
[0083] Specifically, the Waverec function in the PyWt wavelet analysis library in Python is used to reconstruct the decomposed and predicted wavelet coefficients to form a natural gas consumption signal. Reconstruction is the inverse process of the first step of wavelet decomposition. Reconstruction relies on the low-frequency and high-frequency coefficients obtained in the second step of coefficient prediction to reconstruct the original signal (natural gas consumption).
[0084] As an optional implementation manner of an embodiment of the present invention, the urban gas peak-shaving method for producing hydrogen using solar energy provided in the embodiment of the present invention also includes: calculating the average relative error and the average absolute error between the natural gas consumption prediction value and the true value obtained by the autoregressive moving average model, and verifying the accuracy and reliability of the natural gas consumption prediction value.
[0085] Specifically, the mean relative error (MAPE) and mean absolute error (MAE) between the predicted value of natural gas consumption obtained by ARMA modeling and the actual value were calculated to verify the accuracy and reliability of the predicted value of natural gas consumption.
[0086] The following is a specific example to illustrate the scheme of predicting natural gas consumption according to the present invention, but the present invention is not limited to this:
[0087] When modeling the natural gas flow and pressure data, the present invention uses data from January 1 of a certain year to June 30 of a certain year, a total of 180 natural days.
[0088] The data of the first 170 days are used as the training set, and the data of the last 10 days are used as the validation set to determine the prediction effect of the model. Taking the prediction of natural gas consumption for one day as an example, the flow and pressure data of the first 170 days are input to predict the natural gas consumption on the 171st day.
[0089] Step 1, wavelet decomposition. Symmetry is an important factor to be considered in the selection of wavelet basis function. Poor symmetry will cause the original signal to have phase shift after reconstruction. Therefore, the present invention finally selects the wavelet function db4 with good symmetry in the selection of wavelet basis function (Waverec is a decomposition function. When decomposing, it is necessary to select a wavelet basis function as an input parameter. This paper selects db4), and the decomposition level is 2.
[0090] When performing wavelet decomposition, it is necessary to obtain wavelet coefficients in order to predict the subsequent coefficients. The natural gas consumption signal source X is decomposed into high-frequency signals D1, D2 and low-frequency signal A2. The natural gas consumption of the previous 160 days is input, and the wavedec function in Python is used to decompose the coefficient sequence corresponding to the signals D1, D2, and A2. Among them:
[0091] The coefficient sequence corresponding to signal A2 is: 5.24, 5.41, 5.13, 5.33, 5.34, 5.09, 5.06, 5.25, 5.18, 5.29, 5.35, 5.22, 3.21, 4.85, 4.69, 4.77, 4.46, 4.56, 4.46, 4.72, 4.83, 4.58, 4.46, 4.38, 4.27, 4.24, 4.31
[0092] The coefficient sequence corresponding to signal D2 is: 0.0113, 0.0273, 0.0474, 0.0395, 0.0447, -0.0201, 0.0558, -0.0154, 0.0459, 0.0282, -0.0267, 0.0126, 0.0598, 0.0446, -0.00579, 0.0206, -0.0311, 0.00582, -0.0323, 0.0398, -0.0168, 0.1400, -0.0336, -0.00343, 7.76×10-5, 0.0138, -0.0148
[0093] The coefficient sequence corresponding to signal D1 is: 0.0091,-0.0268,-0.0079,0.0049,-0.0351,0.0261,0.0190,0.0231,-0.0019,0.0006,-0.0277,-0.0091,-0.0404,0.0086,-0.0141,0.0342,-0.0055,0.0396,-0.0312,0.0426,0.0315,0.0076,-0.0046,0. 0426,-0.0289,-0.0280,0.0683,0.0407,0.0527,-0.0144,-0.0323,-0.0291,0.0138,0.0303,-0.0446,0.019 9,0.0384,-0.0510,-0.0182,0.0159,-0.0239,-0.0109,-0.0225,-0.0075,0.0261,-0.0080,-0.0232e,0.0221
[0094] Step 2, coefficient prediction. After obtaining low-frequency and high-frequency coefficients through wavelet decomposition, ARMA models are established for these low-frequency and high-frequency coefficient sequences to predict the coefficients. Substitute the coefficient sequences of A2, D2 and D1 obtained by the first step into the ARMA model to predict the next coefficient sequence of A2, D2 and D1. The low-frequency and high-frequency coefficients reflect the changing law of the original signal and are the characteristics of the original signal. The predicted values are reconstructed through the predicted values of the low-frequency and high-frequency coefficients.
[0095] The third step is wavelet reconstruction. The coefficient sequences obtained in the first and second steps are reconstructed by wavelet using the Waverec function in the PyWt wavelet analysis library in Python to obtain the natural gas consumption.
[0096] In order to further verify the forecast results, quantify them, and conduct further error analysis, the predicted natural gas futures usage in the last ten days was compared with the actual values. The results are shown in Table 4.
[0097] Table 4 Error analysis
[0098] date Actual dosage Forecast Usage Absolute error Relative error 2019-08-15 2.120 2.064 -0.057 -0.027 2019-08-16 2.092 2.073 -0.019 -0.009 2019-08-19 2.098 2.089 -0.009 -0.004 2019-08-20 2.103 2.079 -0.025 -0.012 2019-08-21 2.064 2.075 0.011 0.006 2019-08-22 2.050 2.078 0.027 0.013 2019-08-23 2.044 2.088 0.045 0.022 2019-08-26 2.117 2.118 0.002 0.001 2019-08-27 2.078 2.121 0.044 0.021 2019-08-28 2.106 2.124 0.018 0.009
[0099] As can be seen from Table 4, the model has a high accuracy in predicting the future consumption of natural gas, with an error within 10%.
[0100] S4, performing peak load determination on the predicted natural gas consumption value;
[0101] S5, if the predicted value of natural gas consumption is less than or equal to a preset value, outputting a preset proportion of the remaining natural gas in the pipeline network to the natural gas synthesis device through a branch line to produce and store natural gas hydrate;
[0102] S6, if the predicted value of natural gas consumption is greater than the preset value, the natural gas hydrate is gasified by a natural gas hydrate gasification device and then input into the pipeline network and / or the natural gas is obtained by electrolyzing water to produce hydrogen by a photovoltaic hydrogen production device and then input into the pipeline network.
[0103] Specifically, after the gas consumption is predicted to obtain the predicted value, if the gas consumption is less than the daily gas consumption specified in the contract, 80% of the remaining gas is distributed to the synthesis device through a branch line to produce and store natural gas hydrates. If the gas consumption is greater than the amount specified in the contract, the natural gas hydrate gasification device is started to gasify the hydrate into gaseous methane and input it into the pipeline network, and / or the photovoltaic hydrogen production device is used to electrolyze water to produce hydrogen to obtain natural gas, which is then input into the pipeline network, thereby achieving the purpose of short-term peak load regulation.
[0104] It can be seen that the urban gas peak-shaving method for producing hydrogen using solar energy provided by the embodiment of the present invention can be used to peak-shave urban gas based on the predicted natural gas consumption.
[0105] The above method is applied when the city gas peak-shaving system using solar energy to produce hydrogen is used for peak-shaving. The following is only a brief description of the functions of each device in the city gas peak-shaving system using solar energy to produce hydrogen. For other matters not covered, please refer to the relevant description in the above-mentioned city gas peak-shaving method using solar energy to produce hydrogen.
[0106] As an optional implementation manner of an embodiment of the present invention, the gas consumption data prediction and control model decomposes the original natural gas consumption data into a preset number of layers of high-frequency signals and low-frequency signals to obtain the wavelet coefficients of each decomposed layer in the following manner: the natural gas consumption signal is decomposed into high-frequency signals and low-frequency signals in layers using the Wavedec function in the PyWt wavelet analysis library in Python to obtain the high-frequency coefficients and low-frequency coefficients of each layer.
[0107] As an optional implementation manner of an embodiment of the present invention, the gas consumption data prediction and control model models the wavelet coefficients of each layer of the decomposition in the following manner to obtain a prediction model, and uses the prediction model to predict the wavelet coefficients of future usage: use the autoregressive moving average model in Matlab to model the wavelet coefficients obtained by decomposition, and predict the wavelet coefficients of future usage.
[0108] As an optional implementation manner of an embodiment of the present invention, the gas consumption data prediction and control model reconstructs the wavelet coefficients of each decomposed layer and the wavelet coefficients of predicted future usage in the following manner to form a natural gas consumption prediction value: the wavelet coefficients of each decomposed layer and the wavelet coefficients of predicted future usage are reconstructed using the Waverec function in the PyWt wavelet analysis library in Python to form the natural gas consumption prediction value.
[0109] As an optional implementation of an embodiment of the present invention, the gas consumption data prediction and control model is also used to calculate the average relative error and the average absolute error between the natural gas consumption prediction value and the true value predicted by the autoregressive moving average model, so as to verify the accuracy and reliability of the natural gas consumption prediction value.
[0110] It can be seen that the city gas peak-shaving system for producing hydrogen using solar energy provided by the embodiment of the present invention can peak-shave city gas based on the predicted natural gas consumption.
[0111] The above are only embodiments of the present application and are not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included within the scope of the claims of the present application.
Claims
1. A method for urban gas peak load regulation using solar energy to produce hydrogen, characterized in that: include: Decompose the original natural gas consumption data into high-frequency signals and low-frequency signals of a preset number of layers, and obtain the wavelet coefficients of each decomposed layer; Modeling the wavelet coefficients of each layer of the decomposition to obtain a prediction model, and using the prediction model to predict the wavelet coefficients of future usage; The wavelet coefficients of each layer decomposed and the wavelet coefficients of the predicted future consumption are reconstructed to form the predicted value of natural gas consumption; Performing peak load determination on the predicted natural gas usage value; If the predicted value of natural gas consumption is less than or equal to a preset value, a preset proportion of the remaining natural gas in the pipeline network is output to the natural gas synthesis device through a branch line to produce and store natural gas hydrate; If the predicted value of natural gas consumption is greater than the preset value, the natural gas hydrate is gasified by a natural gas hydrate gasification device and then input into the pipeline network and / or the natural gas is obtained by electrolyzing water to produce hydrogen by a photovoltaic hydrogen production device and then input into the pipeline network.
2. The method according to claim 1, characterized in that The original natural gas consumption data is decomposed into a preset number of layers of high-frequency signals and low-frequency signals, and the wavelet coefficients of each decomposed layer are obtained, including: The natural gas usage signal is decomposed into high-frequency signals and low-frequency signals in layers using the Wavedec function in the PyWt wavelet analysis library in Python to obtain high-frequency coefficients and low-frequency coefficients of each layer.
3. The method according to claim 2, characterized in that The wavelet coefficients of each layer of the decomposition are modeled to obtain a prediction model, and the wavelet coefficients of the future usage are predicted by using the prediction model, including: The wavelet coefficients obtained by decomposition are modeled using the autoregressive moving average model in Matlab, and the wavelet coefficients of future usage are predicted.
4. The method according to claim 3, characterized in that The step of reconstructing the wavelet coefficients of each layer and the wavelet coefficients of the predicted future usage to form the predicted value of natural gas usage includes: The Waverec function in the PyWt wavelet analysis library in Python is used to reconstruct the wavelet coefficients of each decomposed layer and the wavelet coefficients of the predicted future usage to form the natural gas usage prediction value.
5. The method according to claim 4, characterized in that Also includes: The average relative error and the average absolute error between the predicted value of natural gas usage obtained by the autoregressive moving average model and the true value are calculated to verify the accuracy and reliability of the predicted value of natural gas usage.
6. A city gas peak load regulation system using solar energy to produce hydrogen, characterized in that: include: Gas consumption data prediction and control model, natural gas synthesis unit, storage unit, natural gas hydrate gasification unit and photovoltaic hydrogen production unit, including: The gas consumption data prediction and control model is used to decompose the original natural gas consumption data into high-frequency signals and low-frequency signals of a preset number of layers to obtain the wavelet coefficients of each decomposed layer; model the wavelet coefficients of each decomposed layer to obtain a prediction model, and use the prediction model to predict the wavelet coefficients of future consumption; reconstruct the wavelet coefficients of each decomposed layer and the wavelet coefficients of the predicted future consumption to form a natural gas consumption prediction value; perform peak shaving judgment on the natural gas consumption prediction value; if the natural gas consumption prediction value is less than or equal to a preset value, control the preset proportion of the natural gas surplus in the pipeline network to be output to the natural gas synthesis device through a branch; if the natural gas consumption prediction value is greater than the preset value, control the natural gas hydrate gasification device to gasify the natural gas hydrate and then input it into the pipeline network and / or control the photovoltaic hydrogen production device to electrolyze water to produce hydrogen to obtain natural gas and input it into the pipeline network; The natural gas synthesis device is used to produce natural gas hydrates and send the natural gas hydrates to the storage device for storage; The natural gas hydrate gasification device is used to gasify the natural gas hydrate stored in the storage device and then input it into the pipeline network; The photovoltaic hydrogen production device is used to produce hydrogen by electrolyzing water and then obtain natural gas which is input into the pipeline network.
7. The system according to claim 6, characterized in that The gas consumption data prediction and control model decomposes the original natural gas consumption data into high-frequency signals and low-frequency signals of a preset number of layers in the following manner to obtain the wavelet coefficients of each decomposed layer: The natural gas usage signal is decomposed into high-frequency signals and low-frequency signals in layers using the Wavedec function in the PyWt wavelet analysis library in Python to obtain high-frequency coefficients and low-frequency coefficients of each layer.
8. The system according to claim 7, characterized in that The gas consumption data prediction and control model models the wavelet coefficients of each layer of the decomposition in the following manner to obtain a prediction model, and uses the prediction model to predict the wavelet coefficients of future consumption: The wavelet coefficients obtained by decomposition are modeled using the autoregressive moving average model in Matlab, and the wavelet coefficients of future usage are predicted.
9. The system according to claim 8, characterized in that The gas consumption data prediction and control model reconstructs the wavelet coefficients of each layer of the decomposition and the wavelet coefficients of the predicted future consumption in the following way to form the natural gas consumption prediction value: The Waverec function in the PyWt wavelet analysis library in Python is used to reconstruct the wavelet coefficients of each decomposed layer and the wavelet coefficients of the predicted future usage to form the natural gas usage prediction value.
10. The system according to claim 9, characterized in that The gas consumption data prediction and control model is also used to calculate the average relative error and average absolute error between the natural gas consumption prediction value and the true value predicted by the autoregressive moving average model, so as to verify the accuracy and reliability of the natural gas consumption prediction value.
11. The system according to any one of claims 6 to 10, characterized in that: Also includes: A photovoltaic power generation device is used to provide electrical energy for the city gas peak-shaving system that uses solar energy to produce hydrogen.