A remote control method for gate group flow based on fuzzy model
Through the remote control method of gate group flow based on the fuzzy model, combined with fuzzy control and PID control, the hysteresis and nonlinearity problems of traditional water resource allocation models are solved, and the precise automatic adjustment and rapid response of gate opening are achieved.
Patent Information
- Application Number
- CN202410996162.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-24
- Publication Date
- 2024-11-15
- Estimated Expiration
- 2044-07-24
AI Technical Summary
The traditional water resource allocation model has lag, nonlinearity and time-varying in the irrigation area, and cannot respond quickly to changes in water resources, resulting in inaccurate adjustment of gate opening and unable to achieve rapid response and intelligent dispatch.
Using the remote control method of gate group flow based on the fuzzy model, the fuzzy control model is constructed, the input variables are comprehensively analyzed, the initial opening of the gate is determined, and the difference information and timing analysis is performed using historical databases and real-time hydrological data, combined with the PID controller to realize Automatic adjustment of gate opening.
It improves the accuracy and regulation efficiency of gate opening, reduces the need for frequent regulation, and can quickly respond to changes in water resources and realizes intelligent scheduling.
Smart Images

Figure CN118521142B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of remote control, and more specifically, to a method for remote control of gate group flow based on a fuzzy model. Background Art
[0002] Water allocation in irrigation areas is affected by many factors, and most irrigation areas are composed of natural rivers and artificial channels with complex canal structures. Traditional water resource allocation models have many inputs and uncertain accuracy, requiring a lot of research and adjustment, and are unable to respond quickly and dispatch quickly. The water resource allocation process is highly lagging, nonlinear, and time-varying, and is a constrained combinatorial optimization problem. In the process of adjusting water resources, the gate opening needs to be adjusted in combination with changes in hydrological data. Faced with hydrological data that is not stored in the historical database, the system cannot intelligently judge the gate opening, and still needs to manually adjust the gate opening, which is unable to respond quickly.
[0003] In order to solve the above defects, a technical solution is now provided. Summary of the invention
[0004] In order to overcome the above-mentioned defects of the prior art, an embodiment of the present invention provides a remote control method for gate group flow based on a fuzzy model, thereby solving the problems raised in the above-mentioned background technology.
[0005] To achieve the above object, the present invention provides the following technical solutions:
[0006] A remote control method for gate group flow based on fuzzy model, comprising the following steps:
[0007] S1: by constructing a fuzzy control model, comprehensively analyzing the input variables in the fuzzy control model, and determining the initial opening of the gate. If the initial opening of the gate can be determined by the fuzzy control model, proceed to step S4;
[0008] S2: Retrieve similar hydrological data from the historical database to determine whether the initial opening of the gate can be adjusted to the gate opening of similar hydrological data in the historical database;
[0009] S3: By analyzing the real-time hydrological data and similar hydrological data in the historical database, the difference information and time series information of the hydrological data are determined, and the results of the comprehensive analysis of the difference information and time series information are used as the basis for judging the initial opening of the gate;
[0010] S4: Adjust the gate opening to the initial opening, and use different gate control methods to adjust the gate opening according to the size between the preset flow rate and the actual flow rate in the PID control.
[0011] In a preferred embodiment, constructing a fuzzy control model includes:
[0012] The fuzzy control model uses a two-dimensional fuzzy controller to determine the initial opening of the gate, takes the water level deviation and the deviation change rate as input variables, and the initial opening as output. It determines the range of the input variable and the input variable quantization factor to ensure that the range of the input variable is correctly mapped to the membership function of the fuzzy set during the fuzzification process.
[0013] The limit values of the input variables are the ranges of the water level deviation and the deviation change rate, and the optimal input variable ranges of the water level deviation and the optimal input variable ranges of the deviation change rate are determined.
[0014] In a preferred embodiment, the comprehensive analysis of the input variables in the fuzzy control model includes:
[0015] The analysis result of the input variable water level deviation is expressed by the hidden safety factor of the water level deviation. The water level deviation is obtained by collecting real-time hydrological data and comparing the preset water level with the real-time water level to obtain the water level deviation. The water level deviation that is not within the optimal input variable range of the water level deviation within a unit time range is obtained, and the hidden safety factor of the water level deviation is determined by formula calculation;
[0016] The analysis result of the input variable deviation change rate is expressed by the deviation change rate hidden safety factor, the differential equation of the water level is constructed by the law of conservation of mass, the deviation change rate is determined according to the differential equation of the water level, the deviation change rate that is not within the optimal input variable range of the deviation change rate within the unit time range is obtained, and the deviation change rate hidden safety factor is determined by formula calculation;
[0017] According to the hidden safety factor of water level deviation and the hidden safety factor of deviation change rate, the control evaluation coefficient of the fuzzy control model is obtained by weighted summation.
[0018] In a preferred embodiment, the initial opening of the gate is determined based on a comprehensive analysis of the input variables in the fuzzy control model, including:
[0019] A control evaluation coefficient threshold is set, and the control evaluation coefficient is compared with the control evaluation coefficient threshold. If the control evaluation coefficient is greater than the control evaluation coefficient threshold, a first signal is generated, and the initial opening of the gate is not determined through the fuzzy control model. If the control evaluation coefficient is less than the control evaluation coefficient threshold, a second signal is generated, and the initial opening of the gate is determined through the fuzzy control model.
[0020] In a preferred embodiment, determining whether the initial opening of the gate can be adjusted to the gate opening of similar hydrological data in the historical database includes:
[0021] When matching hydrological data is directly queried from the historical database, the initial opening of the gate is directly adjusted to the opening in the historical database;
[0022] When no matching hydrological data is found in the historical database, the real-time hydrological data is queried. Whether there is matching hydrological data within the range, if there is no matching hydrological data, the initial opening of the gate is calculated directly using the formula of the flow calculation library;
[0023] If there is matching hydrological data, the corresponding opening value with the smallest difference with the matching hydrological data is taken as the initial opening of the gate, and the difference information and time series information of the real-time hydrological data are comprehensively analyzed to determine whether the corresponding opening value with the smallest difference with the matching hydrological data can be used as the initial opening of the gate.
[0024] In a preferred embodiment, the difference information and time series information of the real-time hydrological data are comprehensively analyzed, including:
[0025] The difference information of the real-time hydrological data indicates the similarity between the real-time hydrological data and the hydrological data stored in the historical database, as well as the similarity between the time periods of the real-time hydrological data;
[0026] The similarity of hydrological data is expressed by the hydrological data similarity coefficient to obtain the real-time hydrological data of the reservoir. The real-time hydrological data includes four types of hydrological data: upstream water level, downstream water level, flow rate, and flow velocity. The hydrological data similarity coefficient is determined by formula calculation;
[0027] The similarity of the time period of the real-time hydrological data is expressed by the time overlap coefficient, and the time point of the real-time hydrological data and the time point corresponding to the matching hydrological data in the historical database are obtained, and the time point of the real-time hydrological data is taken as the current time point, and the time point corresponding to the matching hydrological data in the historical database is taken as the historical current time point;
[0028] Set the time interval, and determine the time series to the current time point and the time series to the historical current time point according to the length of the time interval;
[0029] Construct a DTW distance matrix, where the rows and columns of the matrix correspond to the data points in the time series at the current time point and the time series to the current time point in history, respectively. For each pair of data points in the sequence, calculate the local distance between them. By means of dynamic programming, gradually fill the matrix until the value of the element in the lower right corner of the matrix is obtained. The value of the element in the lower right corner of the DTW distance matrix is used as the time overlap coefficient.
[0030] The temporal information of hydrological data is represented by discrete accumulation coefficients. Real-time hydrological data within a unit time range is collected, and a real-time hydrological data matrix within a unit time range is constructed. The discrete coefficients of different hydrological data are calculated by obtaining the mean and standard deviation of different hydrological data, and the discrete accumulation coefficient is determined by the formula.
[0031] In a preferred embodiment, the result of the comprehensive analysis of the difference information and the timing information is used as the basis for determining the initial opening of the gate, including:
[0032] Through comprehensive analysis of hydrological data similarity coefficient, time overlap coefficient and discrete accumulation coefficient, data comparison and evaluation coefficient is generated;
[0033] A data comparison evaluation coefficient threshold is set, and the data comparison evaluation coefficient is compared with the data comparison evaluation coefficient threshold. If the data comparison evaluation coefficient is greater than the data comparison evaluation coefficient threshold, a third signal is generated, indicating that the gate opening corresponding to the hydrological data in the historical database cannot be used as the initial opening of the gate, and the initial opening of the gate is calculated using the formula of the flow calculation library. If the data comparison evaluation coefficient is less than the data comparison evaluation coefficient threshold, a fourth signal is generated, indicating that the gate opening corresponding to the hydrological data in the historical database can be used as the initial opening of the gate.
[0034] In a preferred embodiment, different gate control methods are used to adjust the gate opening, including:
[0035] The gate is regulated according to its initial opening. After the gate is adjusted to the initial opening, the gate is adjusted by PID. In the gate flow process control, the PID controller algorithm controls according to the proportion (P), integral (I) and differential (D) of the deviation, and the difference between the preset flow and the actual flow is used as the error in PID control;
[0036] The first-level flow deviation threshold, the second-level flow deviation threshold, and the third-level flow deviation threshold are set to realize rapid adjustment of the gate, wherein the first-level flow deviation threshold is greater than the second-level flow deviation threshold, and the second-level flow deviation threshold is greater than the third-level flow deviation threshold;
[0037] When the difference between the preset flow rate and the actual flow rate is greater than the primary flow rate deviation threshold, the PLC controller is used to execute the switch function and adjust the gate opening through the switch;
[0038] When the difference between the preset flow and the actual flow is less than the primary flow deviation threshold, and the difference between the preset flow and the actual flow is greater than the secondary flow deviation threshold, the speed adjustment of the gate is achieved through the integral separation PID adjustment;
[0039] When the difference between the preset flow and the actual flow is less than the secondary flow deviation threshold, and the difference between the preset flow and the actual flow is greater than the tertiary flow deviation threshold, the effect of gradually reducing the motor speed is achieved by adding an integral term.
[0040] Technical effects and advantages of the present invention:
[0041] 1. The present invention conducts a comprehensive analysis on the values of the input variables in the fuzzy control model, limits the conditions for using the fuzzy control model to determine the initial gate opening, helps to ensure that the output of the fuzzy control model is more accurate, and avoids the inability to quickly dispatch the gate due to inaccurate initial gate opening;
[0042] 2. The present invention automatically adjusts the gate by PID method according to the input flow value desired to be adjusted. The PID automatic adjustment system sets the flow target value for each gate of the hub, and automatically adjusts the opening of each gate to distribute water according to the water storage capacity or water inflow, which helps to reduce the frequent adjustment of the gate, improve the accuracy of the gate opening, and improve the control efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] In order to facilitate understanding by those skilled in the art, the present invention is further described below in conjunction with the accompanying drawings;
[0044] Figure 1 The figure is a flow chart of a method for remotely controlling flow of a gate group based on a fuzzy model according to the present invention. DETAILED DESCRIPTION
[0045] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0046] Embodiment 1, Figure 1 A flow chart of a method for remotely controlling the flow of a gate group based on a fuzzy model is provided, which specifically includes the following steps:
[0047] S1: by constructing a fuzzy control model, comprehensively analyzing the input variables in the fuzzy control model, and determining the initial opening of the gate. If the initial opening of the gate can be determined by the fuzzy control model, proceed to step S4;
[0048] S2: Retrieve similar hydrological data from the historical database to determine whether the initial opening of the gate can be adjusted to the gate opening of similar hydrological data in the historical database;
[0049] S3: By analyzing the real-time hydrological data and similar hydrological data in the historical database, the difference information and time series information of the hydrological data are determined, and the results of the comprehensive analysis of the difference information and time series information are used as the basis for judging the initial opening of the gate;
[0050] S4: Adjust the gate opening to the initial opening, and use different gate control methods to adjust the gate opening according to the size between the preset flow rate and the actual flow rate in the PID control.
[0051] In step 1, the fuzzy control model uses a two-dimensional fuzzy controller to determine the initial opening of the gate, taking the water level deviation and the deviation change rate as input variables, and the initial opening as output, to determine the range of the input variables and the input variable quantization factor, ensuring that the range of the input variables is correctly mapped to the membership function of the fuzzy set during the fuzzification process;
[0052] It should be noted that the input variables of a one-dimensional fuzzy controller usually only include the deviation between the controlled variable and the given value. This setting is simple and the inference operation time is short, but the system dynamic performance may not be ideal. The input variables of a two-dimensional fuzzy controller include the deviation between the controlled variable and the given value and the change in the deviation, which can better reflect the dynamic characteristics of the system. Therefore, the control effect is better than that of a one-dimensional fuzzy controller, but correspondingly, the rule set and the inference process may be more complicated. The input variables of a three-dimensional fuzzy controller include the deviation between the controlled variable and the given value, the amount of deviation change, and the rate of change of the deviation, which can achieve more precise control, but have more complex fuzzy control rules and reasoning processes, as well as longer reasoning time.
[0053] The quantization factor includes information such as the division interval of the fuzzy set, the shape and parameters of the membership function. By adjusting the quantization factor, the number, size and shape of the fuzzy set can be controlled, thereby affecting the accuracy and effect of fuzzy reasoning. The selection of the quantization factor needs to be adjusted according to the specific application scenario and problem requirements to achieve the optimal performance of the fuzzy control system.
[0054] The range of input variables is the range of water level deviation and deviation change rate, indicating that the water level deviation and deviation change rate are within the allowable range. Through historical data, the performance of the gate in actual work is analyzed and counted, and a reasonable input variable range is determined based on the existing data distribution. For example, after setting the initial opening, the input variable with less gate opening adjustment is used as a more reasonable input variable to determine the optimal input variable range of water level deviation and the optimal input variable range of deviation change rate. The optimal input variable range of water level deviation and the optimal input variable range of deviation change rate are recorded as: and ;
[0055] It should be noted that in fuzzy control, fuzzy rules are set based on expert knowledge or experience and are used to map fuzzy input to fuzzy output. If the input variable exceeds the range set by the fuzzy rule, it may cause the fuzzy reasoning process to produce uncertain or unreasonable results, thereby affecting the performance and stability of the system. It is necessary to avoid input data that is too large or too small, resulting in inaccurate fuzzy rule matching or unstable control results.
[0056] The analysis result of the input variable water level deviation is represented by the hidden safety factor of the water level deviation. The logic of obtaining the hidden safety factor of the water level deviation is as follows: the water level deviation is obtained by collecting real-time hydrological data and comparing the preset water level with the real-time water level. The water level deviation is marked as: , where n=1, 2, 3...N, N is a positive integer, and n represents the water level deviation collected within a unit time range;
[0057] It should be noted that because the gate usually maintains a certain degree of opening, the water level may change in real time. The water level collected at a certain moment cannot represent the overall situation of the upstream or downstream water levels. It is necessary to wait for the hydrological data to stabilize before determining the water level data.
[0058] The water level deviation that is not within the optimal input variable range of the water level deviation within the unit time range is obtained and marked as: , where i=1, 2, 3…I, I is a positive integer, and i is the number of the water level deviation that is not within the optimal input variable range of the water level deviation within the unit time range;
[0059] Calculate the hidden safety factor of water level deviation using the following formula: ;in, is the hidden safety factor of water level deviation, ;
[0060] It should be noted that the water level usually does not remain constant, especially in the event of rainfall, snowmelt, drainage, etc., the change in water level may be more obvious. Therefore, the water level at each moment in the unit time range may not necessarily meet the optimal input variable range set based on fuzzy rules.
[0061] It can be seen from the formula that the larger the hidden safety factor of the water level deviation is, the more the gap between the preset water level and the real-time water level exceeds the optimal input variable range of the water level deviation. After the current water level deviation is brought into the fuzzy control model as an input variable, the result obtained may be more inaccurate, and the initial opening determined by the fuzzy control model may be more unreasonable.
[0062] When controlling the gate opening in the fuzzy control model, the deviation change rate represents the controlled variable, that is, the change rate between the water level and the expected value, that is, the change rate between the real-time water level and the preset water level. The main function of the deviation change rate is to describe the change trend and rate of the system in the dynamic process. The analysis result of the input variable deviation change rate is expressed by the deviation change rate hidden safety factor. The logic for obtaining the deviation change rate hidden safety factor is: construct the differential equation of the water level through the law of conservation of mass, assuming that the water level is , the water flow rate is , the water flow rate is , then the differential equation of the water level is expressed as: ; where S is the cross-sectional area of the reservoir, Indicates the rate of change of deviation;
[0063] It should be noted that the cross-sectional area of the reservoir is determined through maps or remote sensing images, and then measured and calculated using tools such as the Geographic Information System (GIS). The inlet flow rate can be obtained through hydrological measurements, and the outlet flow rate can be determined based on the orifice flow flow calculation formula or the weir flow flow calculation formula. The differential equation for the water level may actually be more complicated and requires repeated verification by professional staff, so it will not be elaborated here.
[0064] Determine the deviation change rate according to the differential equation of the water level, obtain the deviation change rate that is not within the optimal input variable range of the deviation change rate within the unit time range, and mark it as: , where m=1, 2, 3...M, M is a positive integer, and M is the number of the deviation change rate that is not within the optimal input variable range of the deviation change rate within the unit time range;
[0065] Calculate the hidden safety factor of the deviation change rate using the following formula: ;in, is the hidden safety factor of the deviation change rate, .
[0066] It can be seen from the formula that the larger the hidden safety factor of the deviation change rate, the more likely it is that the fuzzy control system will produce over-adjustment or oscillation, and will not be able to accurately adjust the output to near the expected value, making the control system unstable and unable to achieve the expected control effect.
[0067] According to the hidden safety factor of water level deviation and the hidden safety factor of deviation change rate, the control evaluation coefficient of the fuzzy control model is obtained by weighted summation. The calculation formula of the control evaluation coefficient is: ;in, To control the evaluation coefficient, is the proportional coefficient of the hidden safety factor of water level deviation and the hidden safety factor of deviation change rate, Greater than 0.
[0068] It can be seen from the formula that the larger the hidden safety factor of the water level deviation and the hidden safety factor of the deviation change rate, the larger the control evaluation coefficient, which means that the real-time hydrological data is unstable and may exceed or approach the range of the fuzzy control model. If the water level deviation and the deviation change rate are substituted into the two-dimensional fuzzy controller as input variables at this time, the initial opening obtained may be inaccurate.
[0069] A control evaluation coefficient threshold is set, and the control evaluation coefficient is compared with the control evaluation coefficient threshold. If the control evaluation coefficient is greater than the control evaluation coefficient threshold, a first signal is generated, and the initial opening of the gate is not determined through the fuzzy control model. If the control evaluation coefficient is less than the control evaluation coefficient threshold, a second signal is generated, and the initial opening of the gate is determined through the fuzzy control model.
[0070] This embodiment conducts a comprehensive analysis on the values of the input variables in the fuzzy control model and limits the conditions for using the fuzzy control model to determine the initial gate opening, which helps to ensure that the output of the fuzzy control model is more accurate and avoids the inability to quickly schedule the gate due to inaccurate initial gate opening.
[0071] Embodiment 2. In the above embodiment, the initial opening of the gate is determined by a fuzzy control model. When the fuzzy control model cannot determine the initial opening of the gate, the real-time hydrological data is compared with the data in the historical database to determine the initial opening of the gate. PID adjustment is adopted according to the initial opening of the gate to complete the precise control of the gate.
[0072] In step 2, the real-time hydrological data at the current time point is obtained, and the real-time hydrological data includes gate opening, upstream water level, downstream water level, flow rate, flow rate, etc. Similar hydrological data are retrieved from the historical database to determine whether the initial gate opening can be adjusted to the gate opening of similar hydrological data in the historical database;
[0073] The following situations are used to determine whether the initial gate opening can be adjusted to the gate opening of similar hydrological data in the historical database:
[0074] When matching hydrological data is directly queried from the historical database, the initial opening of the gate is directly adjusted to the opening in the historical database;
[0075] When no matching hydrological data is found in the historical database, the real-time hydrological data is queried. Whether there is matching hydrological data within the range, if there is no matching hydrological data, the initial opening of the gate is calculated directly using the formula of the flow calculation library;
[0076] If there is matching hydrological data, the corresponding opening value with the smallest difference with the matching hydrological data is taken as the initial opening of the gate, and the difference information and time series information of the real-time hydrological data are comprehensively analyzed to determine whether the corresponding opening value with the smallest difference with the matching hydrological data can be used as the initial opening of the gate;
[0077] It should be noted that the historical database includes data recorded during the operation of the gate. As the gate operation time increases, the recorded data in the database increases. The historical database can provide decision makers with a reference to past hydrological conditions. The flow calculation library is a program or software library used to calculate water flow, usually including a series of algorithms and models, which are used to estimate the flow based on hydrological parameters such as water level and water flow velocity, and adjust the gate opening according to the flow.
[0078] The difference information of real-time hydrological data indicates the similarity between the real-time hydrological data and the hydrological data stored in the historical database, as well as the similarity between the time periods of the real-time hydrological data. If the similarity between the real-time hydrological data is high, and the time periods of the real-time water level data and the matching hydrological data in the historical database are highly overlapped, it means that the gate opening used in the historical database can better guide the adjustment of the gate opening.
[0079] The temporal information of real-time hydrological data indicates the degree of change of real-time hydrological data within a unit time range. If the degree of change is high, it indicates that the hydrological situation changes rapidly. At this time, the gate opening is determined by the flow calculation library, and the changes in hydrological conditions are responded to in real time. If the degree of change is low, it indicates that the hydrological situation is relatively stable. The gate is adjusted according to the matching hydrological data recorded in the historical database, because the opening in the historical data may have adapted to similar hydrological conditions.
[0080] The similarity of hydrological data is expressed by the hydrological data similarity coefficient. The logic of obtaining the hydrological data similarity coefficient is as follows: obtain the real-time hydrological data of the reservoir, assuming that there is an upstream water level , downstream water level ,flow , flow rate Four types of hydrological data, and the real-time hydrological data of the reservoir are marked as: , where k = 1, 2, 3, 4, k represents the number of different hydrological data, and the hydrological data stored in the historical database are marked as: ;
[0081] Calculate the similarity coefficient of hydrological data using the following formula: ;in, is the similarity coefficient of hydrological data.
[0082] It can be seen from the formula that the larger the hydrological data similarity coefficient is, the more similar the real-time hydrological data is to the hydrological data stored in the historical database, which means that the effect of using the hydrological data matched by the records in the historical database to adjust the gate opening may be better.
[0083] The similarity of the time period of the real-time hydrological data is represented by the time overlap coefficient. The logic of obtaining the time overlap coefficient is as follows: obtain the time point of the real-time hydrological data and the time point corresponding to the matching hydrological data in the historical database, take the time point of the real-time hydrological data as the current time point, and take the time point corresponding to the matching hydrological data in the historical database as the historical current time point;
[0084] Set the time interval, and determine the time series to the current time point and the time series to the historical current time point according to the length of the time interval;
[0085] It should be noted that the time interval is set by professional staff in order to stretch the time range and help find similar change patterns between different time points, so as to determine the degree of temporal similarity of hydrological data. The current time point and the historical current time point represent the end time point of the time series, and the length of the time series is determined by the time interval.
[0086] Construct a DTW distance matrix. The DTW distance matrix is a two-dimensional matrix created by two time series. The rows and columns of the matrix correspond to the data points in the two time series. For each pair of data points in the sequence, the local distance between them is calculated. Through dynamic programming, the matrix is gradually filled until the value of the lower right corner element of the matrix is obtained, which is the DTW distance of the entire sequence. The value of the lower right corner element of the DTW distance matrix is used as the time overlap coefficient, and the time overlap coefficient is marked as: .
[0087] It should be noted that the dynamic programming algorithm is used to fill the similarity matrix. The dynamic programming algorithm takes into account the distance between each data point and the cumulative distance on the path, and selects the path with the smallest cumulative distance as the best matching path. In the process of filling the similarity matrix, the value of each element can be calculated recursively or iteratively.
[0088] The larger the time overlap coefficient, the lower the similarity between the time series composed of real-time hydrological data and the time series composed of matching hydrological data in the historical database, which means that the effect of using the matching hydrological data recorded in the historical database to adjust the gate opening may be worse.
[0089] The temporal information of hydrological data is represented by discrete accumulation coefficients. The logic of obtaining discrete accumulation coefficients is as follows: collect real-time hydrological data within a unit time range, construct a real-time hydrological data matrix within a unit time range, and mark the real-time hydrological data matrix within a unit time range as: , where j = 1, 2, 3, ... J, J is a positive integer, and j represents the number of times real-time hydrological data are collected within a unit time range;
[0090] Calculate the discrete coefficient of different real-time hydrological data, the calculation formula is: , , , ,in, , , , Respectively represent the upstream water level , downstream water level ,flow , flow rate The dispersion coefficients of the four hydrological data within a unit time range are: , , , They represent the standard deviation of upstream water level, downstream water level, flow rate and flow velocity within a unit time range. , , , They represent the average values of upstream water level, downstream water level, flow rate and flow velocity within a unit time range respectively;
[0091] Among them, the calculation formula for the standard deviation of different real-time hydrological data is: ; The calculation formula for the average value of different real-time hydrological data is: ;
[0092] Calculate the discrete accumulation coefficient, the calculation formula is: ;in, is the discrete accumulation coefficient.
[0093] It can be seen from the formula that the larger the discrete accumulation coefficient is, the higher the fluctuation of the real-time hydrological data is, which means that the effect of using the hydrological data matched by the records in the historical database to adjust the gate opening may be worse.
[0094] In step 3, the difference information and time series information of real-time hydrological data are comprehensively analyzed, and a data analysis model is established through the hydrological data similarity coefficient, time overlap coefficient and discrete accumulation coefficient to generate a data comparison evaluation coefficient. The calculation formula of the data comparison evaluation coefficient is: ;in, is the data comparison evaluation coefficient, , , is the proportional coefficient of the hydrological data similarity coefficient, time overlap coefficient, and discrete accumulation coefficient, , , Greater than 0.
[0095] A data comparison evaluation coefficient threshold is set, and the data comparison evaluation coefficient is compared with the data comparison evaluation coefficient threshold. If the data comparison evaluation coefficient is greater than the data comparison evaluation coefficient threshold, a third signal is generated, indicating that the gate opening corresponding to the hydrological data in the historical database cannot be used as the initial opening of the gate, and the initial opening of the gate is calculated using the formula of the flow calculation library. If the data comparison evaluation coefficient is less than the data comparison evaluation coefficient threshold, a fourth signal is generated, indicating that the gate opening corresponding to the hydrological data in the historical database can be used as the initial opening of the gate.
[0096] In step 4, the gate is regulated according to the initial opening of the gate. After the gate is adjusted to the initial opening, the gate is adjusted by PID. In the gate flow process control, the PID controller algorithm controls according to the proportion (P), integral (I) and differential (D) of the deviation. The difference between the preset flow and the actual flow is used as the error in PID control. The basic expression is: ;in, is the proportional gain, It is inversely related to the proportional opening, that is, the ratio of the allowable flow deviation. The default value is , is the integral time constant, i.e. the system default adjustment time, is the differential time constant, i.e. the system default flow sampling time; is the output signal of the PID controller, It is the difference between the preset flow rate and the actual flow rate;
[0097] Set the first level flow deviation threshold , Secondary flow deviation threshold , Level 3 flow deviation threshold Realize the rapid adjustment of the gate, that is, after the gate is adjusted to the initial opening, calculate the difference between the preset flow and the actual flow. The greater the difference between the preset flow and the actual flow, the greater the deviation between the actual gate opening and the gate opening required by the preset flow. ;
[0098] When the difference between the preset flow rate and the actual flow rate Greater than the first level flow deviation threshold , then use the PLC controller to execute the switch function and adjust the gate opening through the switch;
[0099] When the difference between the preset flow rate and the actual flow rate Less than the first level flow deviation threshold , the difference between the preset flow rate and the actual flow rate Greater than the secondary flow deviation threshold , the speed regulation of the gate is realized by adjusting the integral separation PID;
[0100] When the difference between the preset flow rate and the actual flow rate Less than the secondary flow deviation threshold , the difference between the preset flow rate and the actual flow rate Greater than the third level flow deviation threshold , the integral term is added to achieve the effect of gradually reducing the motor speed. Once the gate reaches the specified position, the motor speed will become 0 to ensure that the gate stops at the target position.
[0101] This embodiment automatically uses PID to adjust the gate according to the input flow value you want to adjust. The PID automatic adjustment system sets the flow target value for each gate of the hub, and automatically adjusts the opening of each gate to distribute water according to the water storage capacity or water inflow. This helps to reduce the frequent adjustment of the gate, improve the accuracy of the gate opening, and improve the control efficiency.
[0102] The above formulas are all dimensionless and numerical calculations. The formula is a formula for the most recent real situation obtained by collecting a large amount of data and performing software simulation. The preset parameters in the formula are set by technicians in this field according to actual conditions.
[0103] The above embodiments can be implemented in whole or in part by software, hardware, firmware or any other combination. When implemented by software, the above embodiments can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions or computer programs. When the computer instructions or computer programs are loaded or executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from one website site, computer, server or data center to another website site, computer, server or data center by wired or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that contains one or more available media sets. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium. The semiconductor medium can be a solid-state hard disk.
[0104] It should be understood that in the various embodiments of the present application, the size of the serial numbers of the above-mentioned processes does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0105] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0106] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0107] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0108] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in the various embodiments of the present application. The aforementioned storage media include: various media that can store program codes, such as USB flash drives, mobile hard disks, read-only memories (ROM), random access memories (RAM), magnetic disks or optical disks.
[0109] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A remote control method for gate group flow based on fuzzy model, Features , including the following steps: S1: by constructing a fuzzy control model, comprehensively analyzing the input variables in the fuzzy control model, and determining the initial opening of the gate. If the initial opening of the gate can be determined by the fuzzy control model, proceed to step S4; S2: Retrieve similar hydrological data from the historical database to determine whether the initial opening of the gate can be adjusted to the gate opening of similar hydrological data in the historical database; S3: By analyzing the real-time hydrological data and similar hydrological data in the historical database, the difference information and time series information of the hydrological data are determined, and the results of the comprehensive analysis of the difference information and time series information are used as the basis for judging the initial opening of the gate; S4: Adjust the gate opening to the initial opening, and use different gate control methods to adjust the gate opening according to the difference between the preset flow rate and the actual flow rate in the PID control; Construct a fuzzy control model, including: The fuzzy control model uses a two-dimensional fuzzy controller to determine the initial opening of the gate, takes the water level deviation and the deviation change rate as input variables, and the initial opening as output. It determines the range of the input variable and the input variable quantization factor to ensure that the range of the input variable is correctly mapped to the membership function of the fuzzy set during the fuzzification process. The limit value of the input variable is the value range of the water level deviation and the deviation change rate, and the optimal input variable range of the water level deviation and the optimal input variable range of the deviation change rate are determined; Comprehensive analysis of input variables in fuzzy control models, including: The analysis result of the input variable water level deviation is expressed by the hidden safety factor of the water level deviation. The water level deviation is obtained by collecting real-time hydrological data and comparing the preset water level with the real-time water level. The water level deviation is marked as: , where n=1, 2, 3...N, N is a positive integer, and n represents the water level deviation collected within a unit time range; the water level deviation that is not within the optimal input variable range of the water level deviation within a unit time range is obtained and marked as: , where i=1, 2, 3…I, I is a positive integer, and i is the number of the water level deviation that is not within the optimal input variable range of the water level deviation within the unit time range; the hidden safety factor of the water level deviation is determined by calculation using the formula: ;in, is the hidden safety factor of water level deviation, , Optimal input variable range for water level deviation; The analysis results of the input variable deviation change rate are expressed by the deviation change rate hidden safety factor, and the differential equation of the water level is constructed by the law of conservation of mass. The deviation change rate is determined according to the differential equation of the water level, and the deviation change rate that is not within the optimal input variable range of the deviation change rate within the unit time range is obtained and marked as: , where m=1, 2, 3...M, M is a positive integer, and M is the number of the deviation change rate that is not within the optimal input variable range of the deviation change rate within the unit time range; the hidden safety factor of the deviation change rate is determined by formula calculation, and the calculation formula is: ;in, is the hidden safety factor of the deviation change rate, , Optimal input variable range for deviation change rate; According to the hidden safety factor of water level deviation and the hidden safety factor of deviation change rate, the control evaluation coefficient of the fuzzy control model is obtained through weighted summation calculation; Based on the comprehensive analysis of the input variables in the fuzzy control model, the initial opening of the gate is determined, including: A control evaluation coefficient threshold is set, and the control evaluation coefficient is compared with the control evaluation coefficient threshold. If the control evaluation coefficient is greater than the control evaluation coefficient threshold, a first signal is generated, and the initial opening of the gate is not determined by the fuzzy control model. If the control evaluation coefficient is less than the control evaluation coefficient threshold, a second signal is generated, and the initial opening of the gate is determined by the fuzzy control model. Determine whether the initial opening of the gate can be adjusted to the gate opening of similar hydrological data in the historical database, including: When matching hydrological data is directly queried from the historical database, the initial opening of the gate is directly adjusted to the opening in the historical database; When no matching hydrological data is found in the historical database, the real-time hydrological data is queried. Whether there is matching hydrological data within the range, if there is no matching hydrological data, the initial opening of the gate is calculated directly using the formula of the flow calculation library; If there is matching hydrological data, the corresponding opening value with the smallest difference with the matching hydrological data is taken as the initial opening of the gate, and the difference information and time series information of the real-time hydrological data are comprehensively analyzed to determine whether the corresponding opening value with the smallest difference with the matching hydrological data can be used as the initial opening of the gate; Comprehensively analyze the difference information and time series information of real-time hydrological data, including: The difference information of the real-time hydrological data indicates the similarity between the real-time hydrological data and the hydrological data stored in the historical database, as well as the similarity between the time periods of the real-time hydrological data; The similarity of the hydrological data is expressed by the hydrological data similarity coefficient to obtain the real-time hydrological data of the reservoir. The real-time hydrological data includes four types of hydrological data: upstream water level, downstream water level, flow rate, and flow velocity. The real-time hydrological data of the reservoir are marked as: , where k = 1, 2, 3, 4, k represents the number of different hydrological data, and the hydrological data stored in the historical database are marked as: ; The hydrological data similarity coefficient is determined by formula calculation, and the calculation formula is: ;in, is the similarity coefficient of hydrological data; The similarity of the time period of the real-time hydrological data is expressed by the time overlap coefficient, and the time point of the real-time hydrological data and the time point corresponding to the matching hydrological data in the historical database are obtained, and the time point of the real-time hydrological data is taken as the current time point, and the time point corresponding to the matching hydrological data in the historical database is taken as the historical current time point; Set the time interval, and determine the time series to the current time point and the time series to the historical current time point according to the length of the time interval; Construct a DTW distance matrix, where the rows and columns of the matrix correspond to the data points in the time series at the current time point and the time series to the current time point in history, respectively. For each pair of data points in the sequence, calculate the local distance between them. By means of dynamic programming, gradually fill the matrix until the value of the element in the lower right corner of the matrix is obtained. The value of the element in the lower right corner of the DTW distance matrix is used as the time overlap coefficient. The temporal information of hydrological data is represented by discrete accumulation coefficients. Real-time hydrological data within a unit time range is collected, a real-time hydrological data matrix within a unit time range is constructed, and the real-time hydrological data matrix within a unit time range is marked as: , where j = 1, 2, 3, ... J, J is a positive integer, and j represents the number of times real-time hydrological data are collected within a unit time range; Calculate the discrete coefficient of different real-time hydrological data, the calculation formula is: , , , ,in, , , , Respectively represent the upstream water level , downstream water level ,flow , flow rate The dispersion coefficients of the four hydrological data within a unit time range are: , , , They represent the standard deviation of upstream water level, downstream water level, flow rate and flow velocity within a unit time range. , , , They represent the average values of upstream water level, downstream water level, flow rate and flow velocity within a unit time range respectively; By obtaining the mean value and standard deviation of different hydrological data, the dispersion coefficient of different hydrological data is calculated, and the dispersion accumulation coefficient is determined by the formula. The calculation formula is: ;in, is the discrete accumulation coefficient; The results of the comprehensive analysis of the difference information and the time series information are used as the basis for determining the initial opening of the gate, including: Through comprehensive analysis of hydrological data similarity coefficient, time overlap coefficient and discrete accumulation coefficient, the data comparison evaluation coefficient is generated. The calculation formula is: ;in, is the data comparison evaluation coefficient, is the time overlap coefficient, , , is the proportional coefficient of the hydrological data similarity coefficient, time overlap coefficient, and discrete accumulation coefficient, , , Greater than 0; A data comparison evaluation coefficient threshold is set, and the data comparison evaluation coefficient is compared with the data comparison evaluation coefficient threshold. If the data comparison evaluation coefficient is greater than the data comparison evaluation coefficient threshold, a third signal is generated, indicating that the gate opening corresponding to the hydrological data in the historical database cannot be used as the initial gate opening, and the initial gate opening is calculated using the formula of the flow calculation library. If the data comparison evaluation coefficient is less than the data comparison evaluation coefficient threshold, a fourth signal is generated, indicating that the gate opening corresponding to the hydrological data in the historical database can be used as the initial gate opening; Different gate control methods are used to adjust the gate opening, including: The gate is regulated according to its initial opening. After the gate is adjusted to the initial opening, the gate is adjusted by PID. In the gate flow process control, the PID controller algorithm that controls according to the deviation ratio P, integral I and differential D takes the difference between the preset flow and the actual flow as the error in PID control. The first-level flow deviation threshold, the second-level flow deviation threshold, and the third-level flow deviation threshold are set to realize rapid adjustment of the gate, wherein the first-level flow deviation threshold is greater than the second-level flow deviation threshold, and the second-level flow deviation threshold is greater than the third-level flow deviation threshold; When the difference between the preset flow rate and the actual flow rate is greater than the primary flow rate deviation threshold, the PLC controller is used to execute the switch function and adjust the gate opening through the switch; When the difference between the preset flow and the actual flow is less than the primary flow deviation threshold, and the difference between the preset flow and the actual flow is greater than the secondary flow deviation threshold, the speed adjustment of the gate is achieved through the integral separation PID adjustment; When the difference between the preset flow and the actual flow is less than the secondary flow deviation threshold, and the difference between the preset flow and the actual flow is greater than the tertiary flow deviation threshold, the effect of gradually reducing the motor speed is achieved by adding an integral term.
